Tutorial by Examples: com

It is a good practice to add comments that describe the code. It is helpful for others and even for the coder when returned later. A single line can be commented using the % symbol or using the shortkey Ctrl+R. To uncomment a previously commented line remove the % symbol or use shortkey Crtl+T. W...
(require '[clj-time.core :as t]) (def date1 (t/date-time 2016 12 5)) (def date2 (t/date-time 2016 12 6)) (t/equal? date1 date2) ;; false (t/equal? date1 date1) ;; true (t/before? date1 date2) ;; true (t/before? date2 date1) ;; false (t/after? date1 date2) ;; false (t/after? date2 dat...
Use the GitHub repository to get the entire code: https://github.com/firebase/functions-samples/blob/master/quickstarts/email-users Copy or clone the repository in your computer. Now go to your Firebase Console Create a Firebase Project using the Firebase Console. Enable the Google Provid...
$BucketName = 'trevorrekognition' ### Create a new AWS S3 Bucket New-S3Bucket -BucketName $BucketName ### Upload two different photos of myself to AWS S3 Bucket Write-S3Object -BucketName $BucketName -File myphoto1.jpg Write-S3Object -BucketName $BucketName -File myphoto2.jpg ### Perform...
HTML <div :class="classes"> <input v-model="compValue" type="text" class="form-control" @keydown.enter = 'enter' @keydown.down = 'down' @keydown.up = 'up' @input = "cha...
import React, { Component } from 'react'; import ReactDOM from 'react-dom'; interface AppProps { name: string; } interface AppState { words: string[]; } class App extends Component<AppProps, AppState> { constructor() { super(); this.state = { ...
Consider a company where every employee who is a manager, manages 1 or more employees, and every employee has only 1 manager. This results in two tables: EMPLOYEES EMP_IDFIRST_NAMELAST_NAMEMGR_IDE01JohnnyAppleseedM02E02ErinMacklemoreM01E03ColbyPaperworkM03E04RonSonswanM01 MANAGERS MGR_IDFIRST_N...
Comparisons are functions in clojure. What that means in (2>1) is (> 2 1) in clojure. Here are all the comparison operators in clojure. Greater Than (> 2 1) ;; true (> 1 2) ;; false Less Than (< 2 1) ;; false Greater Than or Equal To (>= 2 1) ;; true (>= 2 ...
Since you need to sort & rename the fields, the best option will be the Sort Component in the Data Flow task (like you mentioned) . If you only want to rename columns, then use the "Derived Column" component. The Sort component should look as follows: In my example, you can see the ...
Installation of a vmod requires an installed version of Varnish Cache, including the development files. Requirements can be found in the Varnish documentation. Source code is built with autotools: sudo apt-get install libvarnishapi-dev || sudo yum install varnish-libs-devel ./bootstrap # If run...
Starting with the following ComboBoxes: <Window x:Class="WPF_Style_Example.ComboBoxWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft....
Pipes supports simple binary communication between a client and a server In this example: a client connects and sends a FirstMessage the server receives and answers DoSomething 0 the client receives and answers DoNothing step 2 and 3 are repeated indefinitely The command data type exchange...
Parsing input is best achieved through larger parser functions that are composed of smaller, single purpose ones. Let's say we wished to parse the following text which represents working hours: Monday: 0800 1600. We could split these into two "tokens": the day name -- "Monday&q...
Inspect ssl certificate openssl x509 -in server.crt -noout -text Generate server key openssl genrsa -out server.key 2048 Generate csr openssl req -out server.csr -key server.key -new
You can detect when your app is launched from an external URL. componentDidMount() { const url = Linking.getInitialURL() .then((url) => { if (url) { console.log('Initial url is: ' + url) } }).catch(err => console.error('An error occurred ', err)) } To enable this...
Here is a list of actions which can be triggered in the Midnight Commander filesystem browsing mode by using function keys on your keyboard. F1 Displays help F2 Opens user menu F3 Displays the contents of the selected file F4 Opens the selected file in the internal file editor F5 Copies th...
Midnight Commander has a built in editor which is started by F4 function key when over the desired file in the browse mode. It can also be invoked in standalone mode by executing mcedit <filename> Here is a list of actions which can be triggered in the edit mode. F1 Displays help F2 Saves ...
In the code below you can see how to add a command to your plugin. MainClass.java package yourpackage; import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.plugin.java.JavaPlugin; public class MainClass extends JavaPlugin { @Override public bool...
Once you have established a connection to Redis you can get and set values using the Jedis connection object: Get String value = jedis.get(myKey); Set jedis.put(myKey, "some value");
To add a component with a selector [prefix]-user-list, run: $ ng g c user-list installing component create src/app/user-list/user-list.component.css create src/app/user-list/user-list.component.html create src/app/user-list/user-list.component.spec.ts create src/app/use...

Page 58 of 65