Tutorial by Examples

create() write() search() browse() exists() ref() ensure_one()
Let's say you have an academic system. The bounded contexts would be like this: Admission of new undergraduate students Distribution of students on classrooms considering a schedule of the courses and occupation, size and type of classrooms Management of courses, hierarchies and predecessors of...
The invoice number is used to verify the sale for publishers. Many publishers of paid asset or plugin ask for the invoice number upon request of support. The invoice number is also used as a license key to activate some asset or plugin. The invoice number can be found in two place: After you b...
public class DrawRectangle { public static void main(String[] args) { //Load native library System.loadLibrary(Core.NATIVE_LIBRARY_NAME); //image container object Mat goruntuDizisi=new Mat(); //Read image in file system goruntuDizisi=Imgcodecs.imread("C:\\i...
var httpRequest = new XMLHttpRequest(); httpRequest.onreadystatechange = getData; httpRequest.open('GET', 'https://url/to/some.file', true); httpRequest.send(); function getData(){ if (httpRequest.readyState === XMLHttpRequest.DONE) { alert(httpRequest.responseText); } ...
if a directory contain 2 files: $ ls makefile example.txt and makefile contain the following text %.gz: % gzip $< then you can obtain example.txt.gz by typing in the shell $ make -f makefile example.txt.gz the makefile consist of only one rule that instruct make how to create a...
The following utility can be used for auto-completion of commands: $ which aws_completer /usr/bin/aws_completer $ complete -C '/usr/bin/aws_completer' aws For future shell sessions, consider add this to your ~/.bashrc $ echo "complete -C '/usr/bin/aws_completer' aws" >> ~/.b...
Main features of this Makefile : Automatic detection of C sources in specified folders Multiple source folders Multiple corresponding target folders for object and dependency files Automatic rule generation for each target folder Creation of target folders when they don't exist Dependency ma...
Introduction from http://facebook.github.io/react-native/docs/native-modules-ios.html Sometimes an app needs access to platform API, and React Native doesn't have a corresponding module yet. Maybe you want to reuse some existing Objective-C, Swift or C++ code without having to reimplement it in ...
We will see stream objects being returned by modules like fs etc but what if we want to create our own streamable object. To create Stream object we need to use the stream module provided by NodeJs var fs = require("fs"); var stream = require("stream").Writable; ...
In Python: import cv2 image_path= 'd:/contour.png' img = cv2.imread(image_path) #display image before thresholding cv2.imshow('I am an image display window',img) cv2.waitKey(0) #convert image to gray scale - needed for thresholding img_gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY) ...
Consider you want to predict the correct answer for XOR popular problem. You Knew what is XOR(e.g [x0 x1] => y). for example [0 0] => 0, [0 1] => [1] and... #Load Sickit learn data from sklearn.neighbors import KNeighborsClassifier #X is feature vectors, and y is correct label(To train...
DECLARE v_counter NUMBER(2); BEGIN v_counter := 0; LOOP v_counter := v_counter + 1; dbms_output.put_line('Line number' || v_counter); EXIT WHEN v_counter = 10; END LOOP; END;
It is very easy to build a simple C++ project. Here is an example of a SConstruct file that does so: env=Environment() env.Program('hello', Glob('src/*.cpp')) This creates the executable hello composed of all the sources in src with extension cpp.
This example shows more detailed build settings: env=Environment( CPPPATH='/usr/include/boost/', CPPDEFINES=['foo'], LIBS=['bar'], SCONS_CXX_STANDARD='c++11') env.Program('hello', Glob('src/*.cpp')) This builds the executable hello from all the cpp files in src, with the f...
It is a dialog which prompts user to select date using DatePicker. The dialog requires context, initial year, month and day to show the dialog with starting date. When the user selects the date it callbacks via DatePickerDialog.OnDateSetListener. public void showDatePicker(Context context,int init...
A generic schema useful to work with geo-objects like points, linestrings and polygons. Both Mongoose and MongoDB support Geojson. Example of usage in Node/Express: var mongoose = require('mongoose'); var Schema = mongoose.Schema; // Creates a GeoObject Schema. var myGeo= new Schema({ ...
This kind of schema will be useful if you want to keep trace of your items by insertion time or update time. var mongoose = require('mongoose'); var Schema = mongoose.Schema; // Creates a User Schema. var user = new Schema({ name: { type: String }, ...
This is a basic polymer element that show a list of names. <link rel="import" href="../bower_components/polymer/polymer.html"> <dom-module id="basic-list"> <template> <style> </style> <div>Name's list</div&g...
The Binary Search Tree (BST) is a hierarchical data structure with a single pointer to the root node. The Node in the BST generally contains "items" (such as numbers or names) for fast look up. Each node has at-most two children (left and right). Every node is organized by some key data f...

Page 848 of 1336