.NET Core 2.0 By Example
上QQ阅读APP看书,第一时间看更新

What this book covers

Chapter 1, Getting Starteddiscusses all the prerequisites required for all the examples in this book, for example, setting up an Ubuntu VM using VirtualBox and through Hyper-V on Windows, and installing .NET Core 2.0 and tools. We will also be introduced to F# and its features in brief, see how F# is different from other object-oriented programming languages, and look at the differences between C# and F#. We will also create a simple sample application using F#, in order to get familiar with the F# syntax.

Chapter 2, Native Libraries in .NET Coredemonstrates what the ncurses library is and how to extend the console capabilities of .NET Core by implementing the ncurses native library on Linux, and also how to interoperate with existing native and Mono libraries. We will build a sample native library and application that implements this new sample library.

Chapter 3, Building Our First .NET Core Game – Tic-Tac-Toeillustrates .NET Core using an example game app, Tic-Tac-Toe. We will be introduced to SignalR Core and learn how it can be used to develop a real-time web application. Instead of using a monochromatic X and O, players can use their images to play the game. With this example game app, we will get an overview of the code (classes, interfaces, models, and so on) and will learn about compiling, building, and testing the application, which applies to .NET Core in general.

Chapter 4, Let's Chat Web Applicationintroduces web development with ASP.NET Core. This is done through a simple chat application, Let's Chat, on Windows. We also cover project setup, application architecture and its description, SignalR Core, Dependency Injection, configuration, logging, and more. We will also get familiar with the fundamentals of the features of ASP.NET Core, which are introduced while developing the components of the application.

Chapter 5, Developing the Let's Chat Web Application, demonstrates numerous examples and code snippets in order to fundamentals and features of ASP.NET Core. By the end of this chapter, the Let's Chat application will be ready for use. We will also get acquainted with testing, hosting, security, and the performance aspects of web development.

Chapter 6, Testing and Deploying – The Let's Chat Web Applicationexplains the .NET Core deployment model. We will deploy the Let's Chat application. We will be introduced to Docker containers. We will also develop and deploy a ASP.NET Core-based chat bot and integrate it with the Let's Chat application.

Chapter 7, To the Cloudteaches you what the cloud is and why the modern-day developer should be conversant with cloud technologies. We will get started with Azure, and make ourselves aware of the Azure management portal. We will learn to create a VM from the portal and see that it is automated using PowerShell or other languages using the Azure SDK. We will then manage the VM using PowerShell and see how to start and stop it. We will also learn how to create a web app in Azure from Visual Studio 2017 itself and learn how to publish profiles. Finally, we will have an overview of App Services, and take a quick look at Azure storage.

Chapter 8, Movie Booking Web Appdiscusses Entity Framework (EF) and Entity Framework Core. We will learn about the features of and differences between the two. We will also learn that we should use EF Core only if EF cannot be used or there is a pressing cross-platform requirement to use EF Core. We will learn how to perform CRUD operations using EF Core by creating a simple app. We will then develop a simple movie booking app and learn how to deploy it using Visual Studio. We will also see how we can monitor our web app by enabling Application Insights.

Chapter 9, Microservices with .NET Core, gives an overview of the microservice architecture and how it is an extension of SOA and overcomes the limitations of traditional monolithic apps. We will learn about the important architectural differences between ASP.NET and ASP.NET Core. We will look at tips to keep in mind while developing ASP.NET Core 2.0 applications, due to the architectural differences. We will then discuss handy information, steps, and tips to improve the performance of ASP.NET Core apps, a few tips on Azure as well, and then a new experimental project of the ASP.NET Core team, which is called Blazor. We'll wrap up the chapter with a discussion on the .NET Core 2.1 roadmap and the features expected in this new version.

Chapter 10, Functional Programming with F#discusses functional programming and its features, such as higher-order functions, purity, lazy evaluation, and currying. We will learn about F# basics, such as classes, let and do bindings, generic type parameters, properties in F#, how to write functions and lambda expressions in F#, and exception handling. Also, we'll look at different types of data providers in F# and how different types of data parser work. We will also learn about querying SQL Server vNext with F#.