Tutorial by Examples

For this example, we want to make sure that any Employee who is marked as a Project Resource also has an appropriate Labor Cost defined. // 1.0, Revealing Module pattern var myNamespace = myNamespace || {}; myNamespace.example = (function () { /** * User Event 1.0 example detailing...
After the record gets stored in the database, we want to inspect what was changed on the record. We'll do this inspection by comparing values between the old and new record instances. // 1.0, Revealing Module pattern var myNamespace = myNamespace || {}; myNamespace.example = (function () { ...
// 1.0 // Revealing Module pattern, structures 1.0 similar to 2.0 var myNamespace = myNamespace || {}; myNamespace.example = (function () { /** @appliedtorecord employee */ var exports = {}; function beforeLoad(type, form, request) { showBonusEligibility(form); ...
// 1.0 // Utilize the type argument and raw Strings to filter your // execution by the action function beforeLoad(type, form, request) { // Don't do anything on APPROVE // Note that `type` is an Object, so we must use ==, not === if (type == "approve") { return...
In SuiteScript 1.0, we retrieve the current execution context using nlapiGetContext().getExecutionContext(), then we compare the result to the appropriate raw Strings. // 1.0 in Revealing Module pattern var myNamespace = myNamespace || {}; myNamespace.example = (function () { var exports =...
The STDIN stream in Julia refers to standard input. This can represent either user input, for interactive command-line programs, or input from a file or pipeline that has been redirected into the program. The readline function, when not provided any arguments, will read data from STDIN until a newl...
Reading numbers from standard input is a combination of reading strings and parsing such strings as numbers. The parse function is used to parse a string into the desired number type: julia> parse(Int, "17") 17 julia> parse(Float32, "-3e6") -3.0f6 The format expec...
Reading strings or bytes Files can be opened for reading using the open function, which is often used together with do block syntax: open("myfile") do f for (i, line) in enumerate(eachline(f)) print("Line $i: $line") end end Suppose myfile exists and its ...
public class MyClass { public void foo() { Logger logger = Bukkit.getLogger(); logger.info("A log message"); logger.log(Level.INFO, "Another message"); logger.fine("A fine message"); // logging an exception try { ...
Java Logging Api has 7 levels. The levels in descending order are: SEVERE (highest value) WARNING INFO CONFIG FINE FINER FINEST (lowest value) The default level is INFO (but this depends on the system and used a virtual machine). Note: There are also levels OFF (can be used to turn log...
Detailed instructions on getting iOS 10 set up or installed.
Sometimes we need to collect data from google spreadsheets. We can use gspread and oauth2client libraries to collect data from google spreadsheets. Here is a example to collect data: Code: from __future__ import print_function import gspread from oauth2client.client import SignedJwtAssertionCred...
Apart from CSS, model, and binding selectors, protractor can also locate elements using xpath View <ul> <li><a href='http://www.google.com'>Go to google</a></li> </ul> Code var googleLink= element(by.xpath('//ul/li/a')); expect(element.getText()).to.event...
XPath selectors can be used to select elements with specific attributes, such as class, id, title etc. By Class View: <div class="HakunaMatata"> Hakuna Matata </div> Code: var theLionKing= element(by.xpath('//div[@class="HakunaMatata"]')); expect(theLionKing.g...
lib.pagetitle = TEXT lib.pagetitle.data = page : title
$productCollection = Mage::getModel('catalog/product')->getCollection(); Selecting the specific Attribute $productCollection->addAttributeToSelect(array('name', 'product_url', 'small_image')); Selecting the All Attributes $productCollection->addAttributeToSelect('*'); Add Filter ...
Elastic Beanstalk (EB) is essentially a hybrid between Golden AMIs and CloudFormation, while vastly simplifying the learning curve of Puppet or Chef. An Elastic Beanstalk deployment is broken down into two components: Application and Environment. Application Consider this your top-level groupin...
Blue/Green deployment is a release technique that reduces downtime and risk by running two identical production environments (one called "Blue", the other called "Green"). At any one time, only one of the environments is serving live traffic, while the other is sitting idle. Whe...
A Deque is a "double ended queue" which means that a elements can be added at the front or the tail of the queue. The queue only can add elements to the tail of a queue. The Deque inherits the Queue interface which means the regular methods remain, however the Deque interface offers addit...
Powershell supports standard conditional logic operators, much like many programming languages. These allow certain functions or commands to be run under particular circumstances. With an if the commands inside the brackets ({}) are only executed if the conditions inside the if(()) are met $test =...

Page 964 of 1336