Tutorial by Examples: al

Google Cloud Project Google Cloud Datastore is a NoSQL Database as a Service (DBaaS) that provides developers with a scalable replicated database that is fully managed by Google. For its initial setup you need to either have an existing Google Cloud Platform (GCP) project, or create a new one. Clo...
The Dictionary allows getting a unique set of values very simply. Consider the following function: Function Unique(values As Variant) As Variant() 'Put all the values as keys into a dictionary Dim dict As New Scripting.Dictionary Dim val As Variant For Each val In values ...
To run macros and maintain the security Office applications provide against malicious code, it is necessary to digitally sign the VBAProject.OTM from the VBA editor > Tools > Digital Signature. Office comes with a utility to create a self-signed digital certificate that you can employ on th...
TypeScript Angular 2 Component import {Component, OnInit, ViewChild, Renderer} from '@angular/core'; import {SuiTransition} from "ng2-semantic-ui/components/transition/transition"; @Component({ selector: 'app-home', templateUrl: './home.component.html', styleUrls: ['./home.co...
The Data.Functor module contains two combinators, <$ and $>, which ignore all of the values contained in a functor, replacing them all with a single constant value. infixl 4 <$, $> <$ :: Functor f => a -> f b -> f a (<$) = fmap . const $> :: Functor f => f a ...
If you installed Node using the default directory, while in the global mode, NPM installs packages into /usr/local/lib/node_modules. If you type the following in the shell, NPM will search for, download, and install the latest version of the package named sax inside the directory /usr/local/lib/node...
Detailed instructions on getting travis-ci set up or installed.
Lists as arguments are just another variable: def func(myList): for item in myList: print(item) and can be passed in the function call itself: func([1,2,3,5,7]) 1 2 3 5 7 Or as a variable: aList = ['a','b','c','d'] func(aList) a b c d
One way to avoid deep nesting (as recommended above) is to generate the collection actions scoped under the parent, so as to get a sense of the hierarchy, but to not nest the member actions. In other words, to only build routes with the minimal amount of information to uniquely identify the resource...
Example Controller action use Symfony\Component\HttpFoundation\Request; public function exampleAction(Request $request) { /* * First you need object ready for validation. * You can create new object or load it from database. * You need to add some constraints for this obj...
Usually we are not using second parameter in select([$select = '*'[, $escape = NULL]]) in CodeIgniter. If you set it to FALSE, CodeIgniter will not try to protect your field or table names. In the following example, we are going to select the datetime type field by formatting it using sql query an...
LibGDX is a free, open-source game-development library developed in Java. It's goals are to allow users to develop cross-platform games that run on desktop, Android, iOS, and web browsers. Write code once, deploy it to any of the major platforms.
#ifndef MYCOMPAREFILEDIALOG_H #define MYCOMPAREFILEDIALOG_H #include <QtWidgets/QDialog> class MyCompareFileDialog : public QDialog { Q_OBJECT public: MyCompareFileDialog(QWidget *parent = 0); ~MyCompareFileDialog(); }; #endif // MYCOMPAREFILEDIALOG_H
#include "MyCompareFileDialog.h" #include <QLabel> MyCompareFileDialog::MyCompareFileDialog(QWidget *parent) : QDialog(parent) { setWindowTitle("Compare Files"); setWindowFlags(Qt::Dialog); setWindowModality(Qt::WindowModal); resize(300, 100); ...
Despite you can write a binary number in C++14 like: int number =0b0001'0101; // ==21 here comes a famous example with a self-made implementation for binary numbers: Note: The whole template expanding program is running at compile time. template< char FIRST, char... REST > struct binary {...
Lastly, we have the Bundle Installation script type, which provides several events that allow us to interact with the installation, update, and uninstallation of a particular bundle. This is a rarely-encountered script type, but important to be aware of nonetheless. The Bundle Installation includes...
In order to get the total number of commits that each developer or contributor has made on a repository, you can simply use the git shortlog: git shortlog -s which provides the author names and number of commits by each one. Additionally, if you want to have the results calculated on all branch...
Let say you want to build your API to comply jsonapi.org specification and the result should look like: { "article": { "id": "305", "type": "articles", "attributes": { "title": "Asking Alexandria&q...
Connecting to Cassandra is very similar to connecting to other datasources. With Cassandra, credentials are not required. String cassandraIPAddress = "127.0.0.1"; String cassandraKeyspace = "myKeyspace"; String username = "foo"; String password = "bar"; ...
Nested serializers by default don't support create and update. To support this without duplicating DRF create/update logic, it is important to remove the nested data from validated_data before delegating to super: # an ordinary serializer class UserProfileSerializer(serializers.ModelSerializer): ...

Page 201 of 269