Tutorial by Examples

ghci> :set -XOverloadedStrings ghci> import Data.Text as T isInfixOf :: Text -> Text -> Bool checks whether a Text is contained anywhere within another Text. ghci> "rum" `T.isInfixOf` "crumble" True isPrefixOf :: Text -> Text -> Bool checks whether a...
LocalTime is an immutable class and thread-safe, used to represent time, often viewed as hour-min-sec. Time is represented to nanosecond precision. For example, the value "13:45.30.123456789" can be stored in a LocalTime. This class does not store or represent a date or time-zone. Instead...
If you find these steps unfamiliar, consider starting here instead. Note these steps come from Stack Overflow Documentation. django-admin startproject myproject cd myproject python manage.py startapp myapp myproject/settings.py Install the app INSTALLED_APPS = [ 'django.contrib.admin', ...
First we need to make a ViewModel. Make a new folder /Models/Account, and add the file MemberLoginViewModel.cs to the folder. using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.Linq; using System.Web; namespace MyCMS.Models.Account { ...
Then make a view in the folder /Views/MacroPartials/Account @model MyCMS.Models.Account.MemberLoginViewModel @using MyCMS.Controllers.Account @if (User.Identity.IsAuthenticated) { <p>Logged in as: @User.Identity.Name</p> using (Html.BeginUmbracoForm<MemberLogin...
Make a new controller in the folder /Controllers/Account. Name the file MemberLoginSurfaceController.cs using MyCMS.Models.Account; using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; using System.Web.Security; namespace MyCMS.Controll...
To render your new component in a view, you cust call: @Html.Action("MemberLoginForm", "MemberLoginSurface")
{-# LANGUAGE OverloadedStrings #-} import qualified Data.Text as T myText :: T.Text myText = "mississippi" Characters at specific indices can be returned by the index function. ghci> T.index myText 2 's' The findIndex function takes a function of type (Char -> Bool) ...
Processing provides method ellipse in order to draw ellipse. This code draws a white circle which has radius of 25 pixels. void setup() { size(500, 500); background(0); fill(255); noStroke(); } void draw() { ellipse(225, 225, 50, 50); } The signature of method ellip...
Git config allows you to customize how git works. It is commonly used to set your name and email or favorite editor or how merges should be done. To see the current configuration. $ git config --list ... core.editor=vim credential.helper=osxkeychain ... To edit the config: $ git config &lt...
Diamond problem is a common problem occurred in Object Oriented Programming, while using multiple-inheritance. Consider the case where class C, is inherited from class A and class B. Suppose that both class A and class B have a method called foo(). Then when we are calling the method foo(), compil...
Inheritance is one of the main concepts in Object Oriented Programming (OOP). Using inheritance, we can model a problem properly and we can reduce the number of lines we have to write. Let's see inheritance using a popular example. Consider you have to model animal kingdom (Simplified animal kingdo...
If you find managing QThreads and low-level primitives like mutexes or semaphores too complex, Qt Concurrent namespace is what you are looking for. It includes classes which allow more high-level thread management. Let's look at Concurrent Run. QtConcurrent::run() allows to run function in a new th...
Polymorphism is one of the basic concepts in OOP (Object Oriented Programming). Main idea of the polymorphism is that an object have the ability to take on different forms. To achieve that (polymorphism), we have two main approaches. Method overloading Occures when there are two or more meth...
Method overloading is the way of using polymorphism inside a class. We can have two or more methods inside the same class, with different input parameters. Difference of input parameters can be either: Number of parameters Type of parameters (Data type) Order of the parameters Let's take a ...
Abstraction is one of the main concepts in Object Oriented Programming (OOP). This is the process of hiding the implementation details for the outsiders while showing only essential details. In another words, Abstraction is a technique to arrange the complexity of a program. There are two basic typ...
For Umbraco 7 the requirements are IIS 7 or higher Database, one of the following: SQL CE, SQL Server 2008 or higher or MySQL with support for case insensitive queries) ASP.NET 4.5 or 4.5.1. Full-Trust Ability to set file/folder permissions for the user that "owns" the Application P...
follow below step to add FCM in your swift Project 1- If you don't have an Xcode project yet, create one now. Create a Podfile if you don't have one: $ cd your-project directory $ pod init 2- Add the pods that you want to install. You can include a Pod in your Podfile like this: pod 'Fir...
Download the files from our.umbraco.org/download and unzip them in a folder. Set up web server hosting the folder you chose. Although IIS is a requirement for production sites, it runs fine for development in IIS Express. Set up file permissions for the folder. For development server it is okey ...
Check for updates to the Nuget package manager. In Visual Studio: Tools > Extensions and Updates > Updates > Visual Studio Gallery. Install if availalbe Create a new web application with template "ASP.NET Web Application with an Empty template" on .NET Framework 4.5.1 Open the...

Page 975 of 1336