Tutorial by Examples: and

When using async queries, you can execute multiple queries at the same time, but not on the same context. If the execution time of one query is 10s, the time for the bad example will be 20s, while the time for the good example will be 10s. Bad Example IEnumerable<TResult1> result1; IEnumera...
These operators have the usual precedence in C++: AND before OR. // You can drive with a foreign license for up to 60 days bool can_drive = has_domestic_license || has_foreign_license && num_days <= 60; This code is equivalent to the following: // You can drive with a foreign licens...
Passing a pointer argument to a T* parameter, if possible, is better than passing it to a const T* parameter. struct Base {}; struct Derived : Base {}; void f(Base* pb); void f(const Base* pb); void f(const Derived* pd); void f(bool b); Base b; f(&b); // f(Base*) is better than f(const...
An object pointer (including void*) or function pointer can be converted to an integer type using reinterpret_cast. This will only compile if the destination type is long enough. The result is implementation-defined and typically yields the numeric address of the byte in memory that the pointer poin...
Highcharts.setOptions({ lang: { loading: 'Загрузка...', months: ['Январь', 'Февраль', 'Март', 'Апрель', 'Май', 'Июнь', 'Июль', 'Август', 'Сентябрь', 'Октябрь', 'Ноябрь', 'Декабрь'], weekdays: ['Воскресенье', 'Понедельник', 'Вторник', 'Среда', 'Четверг', 'П...
Highcharts.setOptions({ lang: { decimalPoint: ',', thousandsSep: '.', loading: 'Daten werden geladen...', months: ['Januar', 'Februar', 'März', 'April', 'Mai', 'Juni', 'Juli', 'August', 'September', 'Oktober', 'November', 'Dezember'], ...
Highcharts.setOptions({ lang: { loading: 'Betöltés...', months: ['január', 'február', 'március', 'április', 'május','június', 'július', 'augusztus', 'szeptember', 'október', 'november', 'december'], shortMonths: ['jan', 'febr', 'márc', 'ápr', 'má...
Highcharts.setOptions({ lang: { loading: 'Sto caricando...', months: ['Gennaio', 'Febbraio', 'Marzo', 'Aprile', 'Maggio', 'Giugno', 'Luglio', 'Agosto', 'Settembre', 'Ottobre', 'Novembre', 'Dicembre'], weekdays: ['Domenica', 'Lunedì', 'Martedì', 'Mercoledì'...
Highcharts.setOptions({ lang: { contextButtonTitle: "Menú contextual del diagrama", decimalPoint: ",", downloadJPEG: "Desa com a imatge JPEG", downloadPDF: "Desa com a document PDF", downloa...
You might want to use it when parsing DateTimes from different cultures (languages), following example parses Dutch date. DateTime dateResult; var dutchDateString = "31 oktober 1999 04:20"; var dutchCulture = CultureInfo.CreateSpecificCulture("nl-NL"); DateTime.TryParse(dutch...
The format of the struct statement is this: struct [structure tag] { member definition; member definition; ... member definition; } [one or more structure variables]; Example: declare the ThreeFloats structure: typedef struct { float x, y, z; } ThreeFloats; @inter...
// long form String sayHello(String name){ "Hello, ${name ? name : 'stranger'}." } // elvis String sayHello(String name){ "Hello, ${name ?: 'stranger'}." } Notice that the "elvis" format omits the "true" term because the original comparison...
This example shows the process from designing the shape you want to drawing it on a view. A specific shap is used but the concepts you learn can be applied to any shape. How to draw a Bézier path in a custom view These are the main steps: Design the outline of the shape you want. Divide the ou...
Useful information The very beginning of the text field text: let startPosition: UITextPosition = textView.beginningOfDocument The very end of the text field text: let endPosition: UITextPosition = textView.endOfDocument The currently selected range: let selectedRange: UITextRange? = textV...
In some cases we need to apply functions to a set of ND-arrays. Let's look at this simple example. A(:,:,1) = [1 2; 4 5]; A(:,:,2) = [11 22; 44 55]; B(:,:,1) = [7 8; 1 2]; B(:,:,2) = [77 88; 11 22]; A = ans(:,:,1) = 1 2 4 5 ans(:,:,2) = 11 22 44 55 >&...
In MATLAB, we can set new default custom orders, such as a colour order and a line style order. That means new orders will be applied to any figure that is created after these settings have been applied. The new settings remains until MATLAB session is closed or new settings has been made. Default ...
Add below dependencies to your build.gradle // Facebook login compile 'com.facebook.android:facebook-android-sdk:4.21.1' Add below helper class to your utility package: /** * Created by Andy * An utility for Facebook */ public class FacebookSignInHelper { private static final...
It is sometimes useful to create random Strings, maybe as Session-ID for a web-service or an initial password after registration for an application. This can be easily achieved using Streams. First we need to initialize a random number generator. To enhance security for the generated Strings, it i...
PhpStorm already ships with a lot of predefined language schemes that are based on common code style guidelines and standards like PSR-2. There is kind of a hidden feature in the code style settings pages where you can import these standards and set them as your current configuration. To do so simp...
This solution uses the ora:tokenize XQuery function that is available from Oracle 11. Sample Data: CREATE TABLE table_name ( id, list ) AS SELECT 1, 'a,b,c,d' FROM DUAL UNION ALL -- Multiple items in the list SELECT 2, 'e' FROM DUAL UNION ALL -- Single item in the list SELECT 3, NULL ...

Page 58 of 153