Tutorial by Examples: st

# General syntax: # grep(<pattern>, <character vector>) mystring <- c('The number 5', 'The number 8', '1 is the loneliest number', 'Company, 3 is', 'Git SSH tag is [email protected]', 'My personal site is w...
This configuration lets' you run your total spec files in two browser instances in parallel. It helps reduce the overall test execution time. Change the maxInstances based on your need. Note: Make sure your tests are independent. var config = {}; var timeout = 120000; config.framework = 'jasmi...
/* save the file in 'pages/loginPage' var LoginPage = function(){ }; /*Application object properties*/ LoginPage.prototype = Object.create({}, { userName: { get: function() { return browser.driver.findElement(By.id('userid')); } }, userPass: { ...
Registering blocks is done from your main mod class, or a ModBlocks class method invoked from the main mod class during preInit. Block myBlock = new CustomBlock(); string registryname = "my_block"; block.setRegistryName(registryname); block.setUnlocalizedName(block.getRegistryName().to...
Create a file called hello.html with the following content: <!doctype html> <html> <head> <script src="//cdnjs.cloudflare.com/ajax/libs/dygraph/2.0.0/dygraph.js"></script> <link rel="stylesheet" href="https://cdnjs.cloudflare.com...
To illustrate this, here is a function that has 3 different "wrong" behaviors the parameter is completely stupid: we use a user-defined expression the parameter has a typo: we use Oracle standard NO_DATA_FOUND error another, but not handled case Feel free to adapt it to your standa...
Dim lo as ListObject Dim MyRange as Range Set lo = Sheet1.ListObjects(1) 'or Set lo = Sheet1.ListObjects("Table1") 'or Set lo = MyRange.ListObject
Dim lo as ListObject Dim lr as ListRow Dim lc as ListColumn Set lr = lo.ListRows.Add Set lr = lo.ListRows(5) For Each lr in lo.ListRows lr.Range.ClearContents lr.Range(1, lo.ListColumns("Some Column").Index).Value = 8 Next Set lc = lo.ListColumns.Add Set lc = lo.Lis...
You can un-register individual events, entire listener classes or all events registered by your plugin or even by other plugins! Un-register specific event Each event class has the getHandlerList() static method, call that and then you can use .unregister() method. PlayerInteractEvent.getHandlerL...
This example is a quick setup of Angular and how to generate a quick example project. Prerequisites: Node.js 6.9.0 or greater. npm v3 or greater or yarn. Typings v1 or greater. Open a terminal and run the commands one by one: npm install -g typings or yarn global add typings npm install -...
In contrast to the other types of workspaces, the VisualStudioWorkspace, cannot be created manually. It can be accessed when building a Visual Studio extension. When inside your extension package project, go to [YourVSPackage]Package.cs file. There you can acquire the workspace in two ways: protec...
Swift: let services = [CBUUID(string: SERVICE1_UUID), CBUUID(string: SERVICE2_UUID)] centralManager.scanForPeripherals(withServices: services, options: nil) Objective C: NSArray *services = @[[CBUUID UUIDWithString:SERVICE1_UUID], [CBUUID UUIDWithString:SERVICE2_UUID]]; [centralManager scanFo...
Swift: var centralManager:CBCentralManager! centralManager = CBCentralManager(delegate: self, queue: nil) Objective C: @property (nonatomic, strong) CBCentralManager *centralManager; centralManager = [[CBCentralManager alloc] initWithDelegate:self queue:nil];
Swift: var centralManager:CBCentralManager! centralManager = CBCentralManager(delegate: self, queue: nil, options: [CBCentralManagerOptionRestoreIdentifierKey : "com.companyname.appname.central"]) Objective C: @property (nonatomic, strong) CBCentralManager *centralManager; self....
<div class="container"> <div class="row" id="features-strip"> <div class="col s12 l4"> <h1>Feature 1</h1> <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Doloribus, unde facere tempore vero...
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.98.2/css/materialize.min.css"> <style media="screen"> .sidebar { height: 100vh; } </style> <div class="row"> <div class...
If you are using Bootstrap Modal then be sure that Model tabindex=-1 is removed. $('#targetId').select2({ width: '100%', dropdownParent: $("#myModal") })
Prerequisite This guide assumes you have already used BuildTools and have run the Spigot server at least once. It also assumes that you have the Spigot-API jar file which we will use. 1) Start Eclipse; you may change the workspace location if desired. 2) Create a new Project Set the project na...
Replace operator: The -replace operator replaces a pattern in an input value using a regular expression. This operator uses two arguments (separated by a comma): a regular expression pattern and its replacement value (which is optional and an empty string by default). "The rain in Seattle&quo...
var syntaxRoot = await document.GetSyntaxRootAsync(); var semanticModel = await document.GetSemanticModelAsync(); var sampleMethodInvocation = syntaxRoot .DescendantNodes() .OfType<InvocationExpressionSyntax>() .First(); var sampleMethodSymbol = semanticModel.GetSymbolI...

Page 336 of 369