Tutorial by Examples: and

HBase Standalone is a mode which allow you to get rid of HDFS and to test HBase before deploying in a cluster, It is not production oriented. Installing HBase in standalone is extremely simple. First you have to download the HBase archive named hbase-X.X.X-bin.tar.gz available on one of the apache ...
If you only need a given resource for a specific control, you can make it more local by adding it to this specific control, instead of the window. It works exactly the same way, the only difference being that you can now only access from inside the scope of the control where you put it: <StackPa...
This is an example for how to handle dynamic key for response. Here A and B are dynamic keys it can be anything Response { "response": [ { "A": [ { "name": "Tango" }, { "name": "P...
You can use the $q.all function to call a .then method after an array of promises has been successfully resolved and fetch the data they resolved with. Example: JS: $scope.data = [] $q.all([ $http.get("data.json"), $http.get("more-data.json"), ]).then(funct...
Ubuntu Below are detailed instructions to install Caffe, pycaffe as well as its dependencies, on Ubuntu 14.04 x64 or 14.10 x64. Execute the following script, e.g. "bash compile_caffe_ubuntu_14.sh" (~30 to 60 minutes on a new Ubuntu). # This script installs Caffe and pycaffe. # CPU onl...
If you want to provide a URL out of convenience for your user but map it directly to another one you're already using. Use a redirect: # config/routes.rb TestApp::Application.routes.draw do get 'courses/:course_name' => redirect('/courses/%{course_name}/lessons'), :as => "course&quot...
The basic math operations are performed mainly on numbers or on vectors (lists of numbers). 1. Using single numbers We can simple enter the numbers concatenated with + for adding and - for subtracting: > 3 + 4.5 # [1] 7.5 > 3 + 4.5 + 2 # [1] 9.5 > 3 + 4.5 + 2 - 3.8 # [1] 5.7 >...
There are two possible ways to pass a value type by reference: ref and out. The difference is that by passing it with ref the value must be initialized but not when passing it with out. Using out ensures that the variable has a value after the method call: public void ByRef(ref int value) { C...
For example, types for SI units have been standardized in the F# core library, in Microsoft.FSharp.Data.UnitSystems.SI. Open the appropriate sub-namespace, UnitNames or UnitSymbols, to use them. Or, if only a few SI units are required, they can be imported with type aliases: /// Seconds, the SI uni...
All values in Rust have exactly one owner. The owner is responsible for dropping that value when it goes out of scope, and is the only one who may move the ownership of the value. The owner of a value may give away references to it by letting other pieces of code borrow that value. At any given time...
All values in Rust have a lifetime. A value's lifetime spans the segment of code from the value is introduced to where it is moved, or the end of the containing scope { let x = String::from("hello"); // + // ... : let y = S...
Most of the questions around ownership come up when writing functions. When you specify the types of a function's arguments, you may choose how that value is passed in. If you only need read-only access, you can take an immutable reference: fn foo(x: &String) { // foo is only authorized to...
Some Rust types implement the Copy trait. Types that are Copy can be moved without owning the value in question. This is because the contents of the value can simply be copied byte-for-byte in memory to produce a new, identical value. Most primitives in Rust (bool, usize, f64, etc.) are Copy. let x...
jQuery datepicker has two options to allow displaying dropdowns for month and year selection. These options make navigation through large timeframes easier. <input type="text" id="datepicker"> <script> $("#datepicker").datepicker({ changeMont...
The Math.max() function returns the largest of zero or more numbers. Math.max(4, 12); // 12 Math.max(-1, -15); // -1 The Math.min() function returns the smallest of zero or more numbers. Math.min(4, 12); // 4 Math.min(-1, -15); // -15 Getting maximum and minimum from an array: var ...
attr() gets/sets the HTML attribute using the DOM functions getAttribute() and setAttribute(). prop() works by setting the DOM property without changing the attribute. In many cases the two are interchangeable, but occasionally one is needed over the other. To set a checkbox as checked: $('#tosAcc...
Standard properties Depending on the type of the property, there are up to 3 methods for a single property. Let <property> denote the name of a property and <Property> the name of the property with an uppercase first letter. And let T be the type of the property; for primitive wrappers ...
Summary: MVVM is an architectural pattern that is represented by three distinct components, the Model, View and ViewModel. In order to understand these three layers, it is necessary to briefly define each, followed by an explanation of how they work together. Model is the layer that drives the bus...
Dedicated Workers A dedicated web worker is only accessible by the script that called it. Main application: var worker = new Worker('worker.js'); worker.addEventListener('message', function(msg) { console.log('Result from the worker:', msg.data); }); worker.postMessage([2,3]); worker.j...
In HBase, data are stored in tables with columns. Columns are regrouped in column families, which can be for example "personal" or "professional", each of these containing specific informations. To create a table, you need to use the Admin Object, create it using : Admin admin ...

Page 66 of 153