Tutorial by Examples: l

workflow DoSomeWork { parallel { Get-Process -ComputerName server01 Get-Process -ComputerName server02 Get-Process -ComputerName server03 } } One of the unique features of PowerShell Workflow is the ability to define a block of activities as parallel. To use this feature, us...
The find and replace feature in Atom works in two ways, one operates locally only on the file you are in, and the other on a set of files or directories. To open the find and replace tool for a single file, press Ctrl+F (For Mac OS use ⌘+F). Enter in the first blank the string you are searching for...
using Newtonsoft.Json; var obj = new Person { Name = "Joe Smith", Age = 21 }; var serializedJson = JsonConvert.SerializeObject(obj); This results in this JSON: {"Name":"Joe Smith","Age":21}
var json = "{\"Name\":\"Joe Smith\",\"Age\":21}"; var person = JsonConvert.DeserializeObject<Person>(json); This yields a Person object with Name "Joe Smith" and Age 21.
This assumes you have installed both Eclipse and SBT. Install the SBT plugin for Eclipse from the Eclipse marketplace. In the command line switch directory to the root directory of the project. $ cd ~/home/sample/project Execute sbt, which will load the project. $ sbt Compile t...
type ProjectIdType = ProjectId String getProject : ProjectIdType -> Cmd Msg getProject (ProjectId id) = Http.get <| "/projects/" ++ id
Occasionally we see StackOverflow Java questions (and C or C++ questions) that ask what something like this: i += a[i++] + b[i--]; evaluates to ... for some known initial states of i, a and b. Generally speaking: for Java the answer is always specified1, but non-obvious, and often difficult ...
Let A and B be two matrices of same dimension. The operators +,-,/,*,^ when used with matrices of same dimension perform the required operations on the corresponding elements of the matrices and return a new matrix of the same dimension. These operations are usually referred to as element-wise opera...
Sometimes one would like to pass names of columns from a data frame to a function. They may be provided as strings and used in a function using [[. Let's take a look at the following example, which prints to R console basic stats of selected variables: basic.stats <- function(dset, vars){ f...
NLTK has by default a bunch of words that it considers to be stop words. It can be accessed via the NLTK corpus with: from nltk.corpus import stopwords To check the list of stop words stored for english language : stop_words = set(stopwords.words("english")) print(stop_words) Exam...
Minimum skeleton mynamespace.myaddon | The container-directory of the add-on. setup.py | Register this directory to the Python-interpreter of | the ZOPE-instance. mynamespace | The namespace-directory of the add-on. __init__.p...
Preamble TL;TR: For illustration-purposes the lines of this document beginning with 'TL;TR:' are followed by commandline refering to Plone-helper-scripts of the egg 'adi.devgen'. If you execute the command given after 'TL;TR:', it will create all the files explained of the following chapter. Th...
Example: s = "Hello" # s is a string Then we find out something about s. Lets begin: So you want to know what is the class of s at run time? irb(main):055:0* s.class => String Ohh, good. But what are the methods of s? irb(main):002:0> s.methods => [:unicode_normalize,...
1. What is MVVM? The Model View ViewModel (MVVM) pattern is a design pattern most commonly used for creating user interfaces. It is derived from the the popular "Model View Controller" (MVC) pattern. The major advantage of MVVM is that it separates: The internal representation of the a...
Docker is supported on the following 64-bit versions of Ubuntu Linux: Ubuntu Xenial 16.04 (LTS) Ubuntu Wily 15.10 Ubuntu Trusty 14.04 (LTS) Ubuntu Precise 12.04 (LTS) A couple of notes: The following instructions involve installation using Docker packages only, and this ensures obtaining...
Haskell Wiki has an example of a non-parametric parameter of a type function: type family Inspect x type instance Inspect Age = Int type instance Inspect Int = Bool Here x is non-parametric because to determine the outcome of applying Inspect to a type argument, the type function must insp...
An example of a parametric parameter of a type function: data List a = Nil | Cons a (List a) type family DoNotInspect x type instance DoNotInspect x = List x Here x is parametric because to determine the outcome of applying DoNotInspect to a type argument, the type function do not need to in...
A phantom type parameter has a phantom role. Phantom roles cannot be declared explicitly.
The example I'm going to discuss assumes you have a Docker installation that works in your system and a basic understanding of how to work with Node.js . If you are aware of how you must work with Docker , it should be evident that Node.js framework need not be installed on your system, rather we wo...
StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder() .detectDiskWrites() .penaltyLog() //Logs a message to LogCat .build())

Page 701 of 861