這是 Will 保哥在【微軟技術關卡破解日】的演講簡報,探索 ASP.NET MVC 5.0 與 ASP.NET MVC 5.1 的各種新功能增強,包括如何從 ASP.NET MVC 4 升級至 ASP.NET MVC 5 等實戰主題。
Will 保哥的技術交流中心
https://www.facebook.com/will.fans
1. ASP.NET Web API 2內建兩個強大的功能,批次處理與使用OAuth 2.0進行社交登入,本場次將會完整解析這兩個不為人知的功能。
2. ASP.NET Web API 2發行之後,很快速又提供2.1版的更新,在最新的Web API 2.1.2中提供一些很棒的新功能與改善,我會為各位完整介紹Web API 2.1.2的新功能。
3. 開發Web API服務卡卡的?本場次會介紹一些「好工具」,「好工具」能帶我們上天堂,我將深入介紹「好工具」協助各位在開發與測試的路上一路順暢。
Vlog02 [eng sub]什麼是controller和如何在asp.net核心中創建controller?-what is controller ...SernHao TV
您好,我是SernHao Tv 的Sern Hao, 今天我想要跟您分享的是"關於ASP.Net Core 里的 Controller"。
Hi, I'm Sern Hao from SernHao Tv, the topic I want to share with you is "About Controller in ASP.Net Core".
在這裡,我將深入淺出的為您解說幾個關於ASP.Net Core 裡的 Controller 的幾個要點:
1)什麼是Controller?
- 是在MVC裡的一個互動的Class。
- 在MVC裡,View是用來顯示資訊。 Model是用來鏈接資料庫。而Controller則是負責在View與Model之間接收和傳遞數據。
- 連接Model (或數據)和View。
2) Controller的基本用法。 (demo)
- Controller 處理 Http-Post (route data) and Http-Get (query-string)
- 接收從View得到的用戶輸入的資料,然後給予特定的反應。
- 執行business rule和functions。
3) 如何在ASP.Net Core裡創建 Controller。 (demo)
- 在影片裡,我會講解有關Controller如何被創建,以及一些主要的用途。
- 同時也會帶過Controller在ASP.net Core 裡的生命週期。
- 默認模板: "{controller=Home}/{action=Index}/{id?}") 【“/[Controller]/[ActionName]/[Parameters]”】
- 在 Solution Explorer里, 在“Controllers”的文件夹点击右键 , “Add” , “New Item...“ , 选择”MVC Controller Class“
- “Index”是在“Controller”上默認調用的方法,
附加的:
1) ASP.Net Core 是個.Net Framework,它使用.Net Framework 4.6. .Net Core 也可以算是C# 和MVC 1- 6 系列的一個很大的進步。而這裡的ASP.Net Core 會使用的開發工具是visual studio 2015。
2)在Visual Studio 2015中,您可以在更改程序並保存代碼後通過刷新瀏覽器以達到重新運行應用程序,而不用進行debugging(Ctrl + F5)。
希望我的解说能帮到您。
----------------------------------------------------------------------------
如果您喜欢我的影片,或是我的影片对您有所帮助,
请帮忙点击”喜欢“或“分享”给需要的人哦~
-------------------------------------------------------------------------------------------
如果您对影片有什么建议,或是想看到什么科技与程序编写的教学,
请”留言”给我哦~
-------------------------------------------------------------------------------------------
如果您还想接受到更多关于科技与程序编写的教学,
也请帮忙”订阅“我哦~
----------------------------------------------------------------------------
Hi, how are you? I'm Sern Hao from SernHao Tv, the topic I want to share with you is "About Controller in ASP.Net Core".
Here, I will explain in simple terms for you to explain a few on the ASP.Net Core about Controller in a few key points:
1) What is the Controller?
- is an interactive Class in the MVC.
- In MVC, View is used to display information. Model is used to link the database. The Controller is responsible for receiving and transferring data between View a
這是 Will 保哥在【微軟技術關卡破解日】的演講簡報,探索 ASP.NET MVC 5.0 與 ASP.NET MVC 5.1 的各種新功能增強,包括如何從 ASP.NET MVC 4 升級至 ASP.NET MVC 5 等實戰主題。
Will 保哥的技術交流中心
https://www.facebook.com/will.fans
1. ASP.NET Web API 2內建兩個強大的功能,批次處理與使用OAuth 2.0進行社交登入,本場次將會完整解析這兩個不為人知的功能。
2. ASP.NET Web API 2發行之後,很快速又提供2.1版的更新,在最新的Web API 2.1.2中提供一些很棒的新功能與改善,我會為各位完整介紹Web API 2.1.2的新功能。
3. 開發Web API服務卡卡的?本場次會介紹一些「好工具」,「好工具」能帶我們上天堂,我將深入介紹「好工具」協助各位在開發與測試的路上一路順暢。
Vlog02 [eng sub]什麼是controller和如何在asp.net核心中創建controller?-what is controller ...SernHao TV
您好,我是SernHao Tv 的Sern Hao, 今天我想要跟您分享的是"關於ASP.Net Core 里的 Controller"。
Hi, I'm Sern Hao from SernHao Tv, the topic I want to share with you is "About Controller in ASP.Net Core".
在這裡,我將深入淺出的為您解說幾個關於ASP.Net Core 裡的 Controller 的幾個要點:
1)什麼是Controller?
- 是在MVC裡的一個互動的Class。
- 在MVC裡,View是用來顯示資訊。 Model是用來鏈接資料庫。而Controller則是負責在View與Model之間接收和傳遞數據。
- 連接Model (或數據)和View。
2) Controller的基本用法。 (demo)
- Controller 處理 Http-Post (route data) and Http-Get (query-string)
- 接收從View得到的用戶輸入的資料,然後給予特定的反應。
- 執行business rule和functions。
3) 如何在ASP.Net Core裡創建 Controller。 (demo)
- 在影片裡,我會講解有關Controller如何被創建,以及一些主要的用途。
- 同時也會帶過Controller在ASP.net Core 裡的生命週期。
- 默認模板: "{controller=Home}/{action=Index}/{id?}") 【“/[Controller]/[ActionName]/[Parameters]”】
- 在 Solution Explorer里, 在“Controllers”的文件夹点击右键 , “Add” , “New Item...“ , 选择”MVC Controller Class“
- “Index”是在“Controller”上默認調用的方法,
附加的:
1) ASP.Net Core 是個.Net Framework,它使用.Net Framework 4.6. .Net Core 也可以算是C# 和MVC 1- 6 系列的一個很大的進步。而這裡的ASP.Net Core 會使用的開發工具是visual studio 2015。
2)在Visual Studio 2015中,您可以在更改程序並保存代碼後通過刷新瀏覽器以達到重新運行應用程序,而不用進行debugging(Ctrl + F5)。
希望我的解说能帮到您。
----------------------------------------------------------------------------
如果您喜欢我的影片,或是我的影片对您有所帮助,
请帮忙点击”喜欢“或“分享”给需要的人哦~
-------------------------------------------------------------------------------------------
如果您对影片有什么建议,或是想看到什么科技与程序编写的教学,
请”留言”给我哦~
-------------------------------------------------------------------------------------------
如果您还想接受到更多关于科技与程序编写的教学,
也请帮忙”订阅“我哦~
----------------------------------------------------------------------------
Hi, how are you? I'm Sern Hao from SernHao Tv, the topic I want to share with you is "About Controller in ASP.Net Core".
Here, I will explain in simple terms for you to explain a few on the ASP.Net Core about Controller in a few key points:
1) What is the Controller?
- is an interactive Class in the MVC.
- In MVC, View is used to display information. Model is used to link the database. The Controller is responsible for receiving and transferring data between View a
Introduce twMVC
list text here ASP.NET MVC 可以吃嗎?
ASP.NET MVC 的成功案例
什麼是 MVC
MVC 概觀
ASP.NET MVC 對物件導向的潛移默化
View 簡介
View Engine
HTML Helper
Partial View
Razer Helper 小技巧
ASP.NET MVC 就快進入4了,您跟上了嗎? 如何將現有的 MVC3 如何升級到MVC4呢?無痛升級系列。以及ASP.NET MVC4 新增功能介紹。
課程內容:
ASP.NET MVC 3 升級到 ASP.NET MVC4 的示範與常見問題說明
Basic Project & Empty Project Template
從無到有,建置ASP.NET MVC4 Web API應用程式、How to self-host a web API
Display Modes
View Switcher
Bundling and Minification
Task Support for Asynchronous Controllers
Mobile Project Template
Developing Serverless application with Microsoft Azure and Cognitive ServicesJeff Chu
Introduction to Serverless computing, how to develop application with Microsoft Azure Functions and Logic Apps, plus Cognitive Service Text Semantic analysis.
The document discusses Microsoft's .NET conference and platform. It highlights that .NET Core 2.0 has been released and is available for download. It promotes .NET as being able to build any application for any platform and develop with any programming language. It also emphasizes that .NET sees large growth in active developers and popularity. Additionally, it provides statistics on customer success with .NET and shows how .NET powers a variety of applications and services.
Microsoft Azure IoT 手把手實作 @ K.NET by Maduka (2017-8-12)Jeff Chu
A hands-on lab exercise for Microsoft Azure IoT, help students to learn how to use IoT hub, SQL Database, Stream Analytics services to build their IoT solution.
Developing serverless applications with azure functionsJeff Chu
This document discusses developing serverless applications with Azure Functions. Azure Functions allow processing of events using small, isolated pieces of code called functions. Functions can be triggered by events from other Azure services and external sources. Functions are easy to develop, scale automatically, and only charge for the time spent processing events.
The document discusses new features in C# 7.0 including tuples, pattern matching, out variables, and more. It provides code examples demonstrating how to use tuples to return multiple values from functions, type patterns to match types in switch statements, and when conditions to add additional checks to case statements. The examples show enhanced control flow options in C# with these new features.
The document discusses containers and how they compare to virtual machines. It explains that containers provide operating system-level virtualization where the kernel is shared among containers, unlike virtual machines which virtualize hardware. This allows containers to have faster startup and be more resource efficient. The document then provides steps for setting up a container environment on Windows and details how to build, run, distribute, and update container images.
This document discusses Microsoft Azure's support for Linux and Java workloads. It provides an overview of pre-built Linux virtual machine images on Azure including popular distributions like Oracle Linux and Windows Server. It also outlines options for deploying Java applications on Azure infrastructure services, platform services, and using common Java APIs and tools across deployment models. Customer quotes are provided praising Azure's scalability and cost benefits compared to on-premise Linux servers.
6. Web Form 的角度…
• MVC 應用程式沒有控制項。
• ASP.NET Web Form 有一堆控制項。
• 必須聽命於控制項。
• MVC 的職責分明。
• ASP.NET Web Form 的職責混合 (Page_Load Only…)
• 要付出很多的心血才能職責分明。
• MVC 不好學。
• 其實是因為積習難改。
7. 什麼是 ASP.NET MVC?
• 以 ASP.NET 技術實作的 MVC Pattern。
• 2007 年底開始研發,2009 年才釋出首版。
• 最新版為 5.0。
• 職責分明
• Model, View, Controller,之間互不相依。
• 比 Web Form 更高的彈性。
• 相容於現有的 ASP.NET 基本功能。
• 可客製化程度更高。
8. 為什麼要用 ASP.NET MVC?
• 習慣取代配置 (Convention over Configuration)。
• 依規則配置程式即可。
• 輕量化:
• 拋棄肥大的 ViewState。
• 套版時比 Web Form 更快更輕鬆。
• 強型別的支援 (coding by Intellisense)。
• 物件導向的強化:
• 職責分明。
• 更具彈性。
• 可測試。
28. One ASP.NET
• 未來只會有一個 ASP.NET Core Service
• 不論是 Web Form, MVC, Web API, SPA 等都以同一個基
礎發展。
• 所有 ASP.NET 內的核心功能,Web Form, MVC, Web API,
SPA 等都支援,不分類型。
• Visual Studio 內的範本更乾淨。
• 開發人員可基於 ASP.NET Core Service 開發新服務類型。
29. OWIN (Open Web Interface for .NET)
• One ASP.NET 的基石。
• 中間層軟體的規格 (Middleware)。
• 定義向上 (framework) 的介面。
• 定義向下 (host) 的功能。
• 微軟的 OWIN 實作:Katana Project。
• Web API 2 和 ASP.NET Identity 的基礎之一。
• 可支援 IIS hosting 或 Self-hosting 能力。
• NuGet-enabled。
30. MVC 5 Scaffolding
• 翻譯成 “支架”。
• 所有 ASP.NET MVC 該有的元件都能在此找到。
• 簡化新增 Controller 和 View 的流程。
• 支援 Model scaffolding,自動產生相應欄位。
• 在 Web Form 應用程式中加入 MVC 功能。
• 最小相依。
• 完全相依。
34. Web API 2
• Web API 是類似 MVC 架構的 RESTful API 實作應用。
• 一樣有 Controller,但繼承自 ApiController。
• 一樣使用 ASP.NET Routing。
• 需要加入 Web API Package (NuGet)。
• 支援更豐富的 HTTP 訊息處理能力。
• Web API 2 支援了…
• 屬性路由 (attribute routing)。
• CORS 的支援。
• 更多… (可參考 What’s New in Visual Studio 2013)。
35. demo
• 基本的 Web API
• Web API Attribute Routing
• Web API CORS
36. ASP.NET Identity
• 全新的 ASP.NET 內建驗證與授權機制。
• 以 Entity Framework Code-First 方式編寫。
• 允許自訂欄位。
• 這是 ASP.NET Membership 被罵最慘的項目之一…
• 支援不同的驗證方式 (Windows, Forms, ADFS)。
• 支援 OAuth
• Facebook, Google, Microsoft Account, Twitter
• 由 OWIN 所內建。
39. 總結
• ASP.NET MVC 是未來中大型應用程式的主流
• 不會也沒必要取代 Web Form。
• 但它的彈性比 Web Form 強太多了。
• MVC 5, Web API 2 等讓實作 MVC / Web API 的應
用程式有了更多的選擇。
• ASP.NET Identity 提供了全新的會員管理架構,並支
援多種驗證方法。
40. References
• ASP.NET MVC: http://asp.net/mvc
• ASP.NET Web API: http://asp.net/web-api
• What’s new in Visual Studio 2013:
http://www.asp.net/visualstudio/overview/2013/release-notes
• MSDN 台灣部落格上有許多的精采文章。
• twMVC: http://mvc.tw
41. 學習 MVC,你可以選擇…
• 由 6 位 MVP 合作執筆。
• 其中三位是 twMVC 社群
創始人。
• 台灣唯一有介紹 Web
API 且內容超過 200 頁
的中文書。
• 台灣最暢銷的 ASP.NET
MVC 中文書。