Tutorial by Examples: c

Azure Webjobs run on an Azure App Service. If we scale our App Service horizontally (add new instances), each instance will have its own JobHost. Note that this only applies to WebJobs running in Continuous mode. On-demand and scheduled WebJobs are not affected by horizontal scaling, they always ru...
extern crate serde; extern crate serde_json; #[macro_use] extern crate serde_derive; #[derive(Serialize)] struct Person { #[serde(rename="firstName")] first_name: String, #[serde(rename="lastName")] last_name: String, } fn main() { let person = ...
If you created an empty project, or you still don't have mvc configured in your application, you can add dependency: "Microsoft.AspNetCore.Mvc": "1.0.1" To your project.json file under "dependencies". And register MVC middleware in your Startup class: public void ...
Meteor Tool To check the installed version of the Meteor tool, just run the following command outside of any Meteor projects: meteor --version To get a list of all official (recommended) Meteor releases, run: meteor show METEOR Meteor Projects If you want to check the project version of Me...
The Meteor Tool will notify you when a newer release is available. To update Meteor projects to the latest release, execute the following command inside a Meteor project: meteor update In case you want to update your Meteor project to a specific Meteor release, run the following command inside ...
<!DOCTYPE html> <html> <head> <title>My Leaflet Map</title> <link rel="stylesheet" href="//unpkg.com/[email protected]/dist/leaflet.css" /> <style type="text/css"> #map { height: 500px; ...
Using escaped brackets, you can define a capturing group in a pattern that can be backreferenced in the substitution string with \1: $ echo Hello world! | sed 's/\(Hello\) world!/\1 sed/' Hello sed With multiple groups: $ echo one two three | sed 's/\(one\) \(two\) \(three\)/\3 \2 \1/' three ...
<form asp-action="create" asp-controller="Home"> <!--Your form elements goes here--> </form>
<form asp-action="create" asp-controller="Home" asp-route-returnurl="dashboard" asp-route-from="google"> <!--Your form elements goes here--> </form> This will generate the below markup <form action=&qu...
Assuming your view is strongly typed to a view model like this public class CreateProduct { public IEnumerable<SelectListItem> Categories { set; get; } public int SelectedCategory { set; get; } } And in your GET action method, you are creating an object of this view model,...
Machine code is term for the data in particular native machine format, which are directly processed by the machine - usually by the processor called CPU (Central Processing Unit). Common computer architecture (von Neumann architecture) consist of general purpose processor (CPU), general purpose mem...
Extension methods enable you to simplify your interface definitions by only including core required functionality in the interface itself and allowing you to define convenience methods and overloads as extension methods. Interfaces with fewer methods are easier to implement in new classes. Keeping o...
An interface is a definition of a contract between the user of the interface and the class that implement it. One way to think of an interface is as a declaration that an object can perform certain functions. Let's say that we define an interface IShape to represent different type of shapes, we exp...
Pass a native python dictionary mapping strings to strings to create(). Catalog.objects.create(name='Library of Congress', titles_to_authors={ 'Using HStoreField with Django': 'CrazyPython and la communidad', 'Flabbergeists and thingamajigs': 'La Artista Fooista', 'Pro Git': 'Scott C...
Pass a dict object to field_name__contains as a keyword argument. Catalog.objects.filter(titles__contains={ 'Pro Git': 'Scott Chacon and Ben Straub'}) Equivalent to the SQL operator `@>`.
Imagine that a system want to detect apples and oranges in a basket of fruits. System can pick a fruit, extract some property of it (e.g weight of that fruit). Suppose System has a Teacher! that teaches the system which objects are apples and which are oranges. This is an example of a supervised cl...
5 With ES5+, the Object.create function can be used to create an Object with any other Object as it's prototype. const anyObj = { hello() { console.log(`this.foo is ${this.foo}`); }, }; let objWithProto = Object.create(anyObj); objWithProto.foo = 'bar'; objWithProto.hell...
wikipedia definition: Command pattern is a behavioral design pattern in which an object is used to encapsulate all information needed to perform an action or trigger an event at a later time UML diagram from dofactory: Basic components and workflow: Command declares an interface for abst...
Describes ranges of symbols You can enumerate symbols explicitly /[abc]/ # 'a' or 'b' or 'c' Or use ranges /[a-z]/ # from 'a' to 'z' It is possible to combine ranges and single symbols /[a-cz]/ # 'a' or 'b' or 'c' or 'z' Leading dash (-) is treated as charachter /[-a-c]/ # '-' or 'a' o...
Unions are a specialized struct within which all members occupy overlapping memory. union U { int a; short b; float c; }; U u; //Address of a and b will be equal (void*)&u.a == (void*)&u.b; (void*)&u.a == (void*)&u.c; //Assigning to any union member changes ...

Page 207 of 826