Tutorial by Examples: ee

This is a client-server example. The process forks and runs client in the parent process and server in the child process: client connects to server and waits until server exits; server accepts connection from client, enables keepalive, and waits any signal. Keepalive is configured using the f...
If a scoped enum is converted to an integral type that is too small to hold its value, the resulting value is unspecified. Example: enum class E { X = 1, Y = 1000, }; // assume 1000 does not fit into a char char c1 = static_cast<char>(E::X); // c1 is 1 char c2 = static_cast<c...
Following are the page life cycle events: PreInit - PreInit is the first event in page life cycle. It checks the IsPostBack property and determines whether the page is a postback. It sets the themes and master pages, creates dynamic controls, and gets and sets profile property values. This event ca...
using System; namespace myProject { public partial class WebForm1 : System.Web.UI.Page { public string PageSteps = string.Empty; //Raised after the start stage is complete and before the initialization stage begins. protected void Page_PreInit(object sender...
Bottom sheets slide up from the bottom of the screen to reveal more content. They were added to the Android Support Library in v25.1.0 version and supports above all the versions. Make sure the following dependency is added to your app's build.gradle file under dependencies: compile 'com.android...
Sometimes conversion of primitive types to boxed types is necessary. To convert the array, it's possible to use streams (in Java 8 and above): Java SE 8 int[] primitiveArray = {1, 2, 3, 4}; Integer[] boxedArray = Arrays.stream(primitiveArray).boxed().toArray(Integer[]::new); With lowe...
Sun / Oracle releases of Java SE come in two forms: JRE and JDK. In simple terms, JREs support running Java applications, and JDKs also support Java development. Java Runtime Environment Java Runtime Environment or JRE distributions consist of the set of libraries and tools needed to run and mana...
Orthogonal to the JRE versus JDK dichotomy, there are two types of Java release that are widely available: The Oracle Hotspot releases are the ones that you download from the Oracle download sites. The OpenJDK releases are the ones that are built (typically by third-party providers) from the Ope...
A JDK installation and a text editor are the bare minimum for Java development. (It is nice to have a text editor that can do Java syntax highlighting, but you can do without.) However for serious development work it is recommended that you also use the following: A Java IDE such as Eclipse, In...
To move to split on left, use <C-w><C-h> To move to split below, use <C-w><C-j> To move to split on right, use <C-w><C-k> To move to split above, use <C-w><C-l>
# Will display task as: # -------- Rebuild -------- # -------- Build -------- FormatTaskName "-------- {0} --------" # will display tasks in yellow colour: # Running Rebuild FormatTaskName { param($taskName) "Running $taskName" - foregroundcolor yellow } ...
The instance_eval method is available on all objects. It evaluates code in the context of the receiver: object = Object.new object.instance_eval do @variable = :value end object.instance_variable_get :@variable # => :value instance_eval sets self to object for the duration of the c...
Many languages feature a with statement that allows programmers to omit the receiver of method calls. with can be easily emulated in Ruby using instance_eval: def with(object, &block) object.instance_eval &block end The with method can be used to seamlessly execute methods on object...
Step 1: Locate your download of Node.js, typically it is installed under C:/program files/nodejs Step 2: Open Visual Studios and navigate to "Tools>Options" Step 3: In the options window navigate to "Projects and Solutions>External Web Tools" Step 4: Add new entry with y...
If Sitecore is setup in a CM-CD enviornment there could be a need to fire events on CD server when CM events are fired. The example could be firing publish:end:remote on CD when content editors done publish on CM. In order to make sure that events are firing the following steps are required to be ...
Python follows PEMDAS rule. PEMDAS stands for Parentheses, Exponents, Multiplication and Division, and Addition and Subtraction. Example: >>> a, b, c, d = 2, 3, 5, 7 >>> a ** (b + c) # parentheses 256 >>> a * b ** c # exponent: same as `a * (b ** c)` 7776 >>...
The instance_eval method is available on all objects. It evaluates code in the context of the receiver: object = Object.new object.instance_eval do @variable = :value end object.instance_variable_get :@variable # => :value instance_eval sets self to object for the duration of the co...
<script type="text/javascript" src="URL" async></script>
This class is called Greeter. Its responsibility is to output a greeting. It has two dependencies. It needs something that will give it the greeting to output, and then it needs a way to output that greeting. Those dependencies are both described as interfaces, IGreetingProvider and IGreetingWriter....
Description: Evaluate expression after user's confirmation. Arguments: ng-confirm-click:(expression) Expression to evaluate when confirmed. ng-confirm-message:(template) Message to be shown in confirm dialog. Code: Directives.directive("ngConfirmClick", ["$parse","...

Page 25 of 54