Tutorial by Examples: comp

Navigator works for both IOS and android. import React, { Component } from 'react'; import { Text, Navigator, TouchableHighlight } from 'react-native'; export default class NavAllDay extends Component { render() { return ( <Navigator initialRoute={{ title: 'Awesome Sc...
For iterating more than two lists simultaneously within list comprehension, one may use zip() as: >>> list_1 = [1, 2, 3 , 4] >>> list_2 = ['a', 'b', 'c', 'd'] >>> list_3 = ['6', '7', '8', '9'] # Two lists >>> [(i, j) for i, j in zip(list_1, list_2)] [(1, '...
The example builds a string from the name of the parent record, the name of this record, and the memo of this record. {createdfrom} || ' ' || {name} || ' ' || {memo}
The following example combines several of the techniques covered here. It puts a hyperlink in a custom formatted column which, when clicked, opens the sales order record associated with a row. The hyperlink is designed to open the record in a new window or tab when clicked, and to display a tooltip ...
Comparator cmp = [ compare:{ a, b -> a <=> b } ] as Comparator def col = [ 'aa', 'aa', 'nn', '00' ] SortedSet sorted = new TreeSet( cmp ) sorted.addAll col assert '[00, aa, nn]' == sorted.toString()
To enable SSH create a file called ssh in the /boot directory of your SD card. Identify the drive letter associated with your SD card. Open a command prompt (press Win+R on your keyboard to open the Run window. Then, type cmd) Enter the following at the command prompt (replacing Drive...
bcadd vs float+float var_dump('10' + '-9.99'); // float(0.0099999999999998) var_dump(10 + -9.99); // float(0.0099999999999998) var_dump(10.00 + -9.99); // float(0.0099999999999998) var_dump(bcadd('10', '-9.99', 20)); // string(22) "0.01000000000000000000&q...
The Assets folder is the most common place to store your GLSL-ES shader files. To use them in your OpenGL ES application you need to load them to a string in the first place. This functions creates a string from the asset file: private String loadStringFromAssetFile(Context myContext, String filePa...
The traditional GLSL compilation model involves compiling code for a shader stage into a shader object, then linking multiple shader objects (covering all of the stages you want to use) into a single program object. Since 4.2, program objects can be created that have only one shader stage. This met...
If Errorlevel 1 ( Echo Errorlevel is 1 or higher REM The phrase "1 or higher" is used because If Errorlevel 1 statement means: REM If %Errorlevel% GEQ 1 REM Not If %Errorlevel% EQU 1 ) ...
This is a unit test of a component that has Store as a dependency. Here, we are creating a new class called MockStore that is injected into our component instead of the usual Store. import { Injectable } from '@angular/core'; import { TestBed, async} from '@angular/core/testing'; import { AppComp...
This is a unit test of a component that has Store as a dependency. Here, we are able to use a store with the default "initial state" while preventing it from actually dispatching actions when store.dispatch() is called. import {TestBed, async} from '@angular/core/testing'; import {AppCom...
import React, { Component } from 'react'; import { WebView } from 'react-native'; class MyWeb extends Component { render() { return ( <WebView source={{uri: 'https://github.com/facebook/react-native'}} style={{marginTop: 20}} /> ); } } ...
P( glasses | reading ) = Count( reading glasses ) / Count( reading ) We count the sequences reading glasses and glasses from corpus and compute the probability.
The component code is given as below. import { Component } from '@angular/core'; @Component({ selector: 'my-app', template: '<h1>{{title}}</h1>' }) export class MyAppComponent{ title = 'welcome'; } For angular testing, angular provide its testing utilities along with t...
There are standard functions built in for comparing equality, inequality etc. NameSymbolAlternativeExampleEqual=EQi = jNot equal<>NEi <> jLess than<LTi < jless than or equal<=LEi <= jGreater than>=GTi > jGreater than or equal≥=GEi >= j The symbol can be exchanged w...
service I created post service with postRequest method. import {Injectable} from '@angular/core'; import {Http, Headers, Response} from "@angular/http"; import {PostModel} from "./PostModel"; import 'rxjs/add/operator/map'; import {Observable} from "rxjs"; ...
@Component({ selector: 'main-component', template: '<example-component *ngFor="let hero of heroes" [hero]="hero"></example-component>' }) @Component({ selector: 'example-component', t...
just use your cmd: You can use the ng generate (or just ng g) command to generate Angular components: Component: ng g component my-new-component Directive: ng g directive my-new-directive Pipe: ng g pipe my-new-pipe Service: ng g service my-new-service Class: ng g class my-new-classt...
Hello friends before start code we have need to declare dependency for access firebase ui component, so here is the dependency which you can put it in your gradel other wise you can add dependency as jar also. compile 'com.firebaseui:firebase-ui-database:0.4.0' Then after we are querying in fire...

Page 27 of 34