Tutorial by Examples: ti

Detailed instructions on getting lxml set up or installed.
Defining the base class: open class BaseClass { val x = 10 } Defining the derived class: class DerivedClass: BaseClass() { fun foo() { println("x is equal to " + x) } } Using the subclass: fun main(args: Array<String>) { val derivedClass = Deri...
Defining the base class: open class Person { fun jump() { println("Jumping...") } } Defining the derived class: class Ninja: Person() { fun sneak() { println("Sneaking around...") } } The Ninja has access to all of the methods in Pe...
Detailed instructions on getting titanium set up or installed.
Prepare First create a "message.properties" file in Resources/Files/. Example: ############## # Test message.properties ############## label.age=Enter your age: validate.error.reqired.age=Sorry, but you have to give away the secret of your age ... Next, connect the resource with y...
Detailed instructions on getting cdi set up or installed.
Sometimes your webpage needs a automatic redirect. For example, to redirect to example.com after 5 seconds: <meta http-equiv="refresh" content="5;url=https://www.example.com/" /> This is line will send you to the designated website (in this case example.com after 5 sec...
PostScript is a Turing-complete general programming language, designed and developed by Adobe Systems. Many of the ideas which blossomed in PostScript had been cultivated in projects for Xerox and Evans & Sutherland. Its main real-world application historically is as a page description language...
IProgress<T> can be used to report progress of some procedure to another procedure. This example shows how you can create a basic method that reports its progress. void Main() { IProgress<int> p = new Progress<int>(progress => { Console.WriteLine("Runni...
CREATE TABLE menagerie.bird ( bird_id INT NOT NULL AUTO_INCREMENT, species VARCHAR(300) DEFAULT NULL COMMENT 'You can include genus, but never subspecies.', INDEX idx_species (species) COMMENT 'We must search on species often.', PRIMARY KEY (bird_id) ) ENGINE=InnoDB COMMENT 'Thi...
Emacs' documentation uses a consistent notation for all key bindings, which is explained here: Key chords A "key chord" is obtained by pressing two or more keys simultaneously. Key chords are denoted by separating all keys by dashes (-). They usually involve modifier keys, which are put ...
Create example table Employee: CREATE TABLE Employee ( Id INT, EmpName VARCHAR(25), EmpGender VARCHAR(6), EmpDeptId INT ) Creates stored procedure that checks whether the values passed in stored procedure are not null or non empty and perform insert operation in Employee ta...
Uname is the short name for unix name. Just type uname in console to get information about your operating system. uname [OPTION] If no OPTION is specified, uname assumes the -s option. -a or --all - Prints all information, omitting -p and -i if the information is unknown. Example: > unam...
To run the unit tests for a package, use the Pkg.test function. For a package named MyPackage, the command would be julia> Pkg.test("MyPackage") An expected output would be similar to INFO: Computing test dependencies for MyPackage... INFO: Installing BaseTestNext v0.2.2 INFO: Te...
Unit tests are declared in the test/runtests.jl file in a package. Typically, this file begins using MyModule using Base.Test The basic unit of testing is the @test macro. This macro is like an assertion of sorts. Any boolean expression can be tested in the @test macro: @test 1 + 1 == 2 @test...
0.5.0 In version v0.5, test sets are built into the standard library Base.Test module, and you don't have to do anything special (besides using Base.Test) to use them. 0.4.0 Test sets are not part of Julia v0.4's Base.Test library. Instead, you have to REQUIRE the BaseTestNext module, and add u...
Exceptions encountered while running a test will fail the test, and if the test is not in a test set, terminate the test engine. Usually, this is a good thing, because in most situations exceptions are not the desired result. But sometimes, one wants to test specifically that a certain exception is ...
What's the deal with the following? julia> @test 0.1 + 0.2 == 0.3 Test Failed Expression: 0.1 + 0.2 == 0.3 Evaluated: 0.30000000000000004 == 0.3 ERROR: There was an error during testing in record(::Base.Test.FallbackTestSet, ::Base.Test.Fail) at ./test.jl:397 in do_test(::Base.Test....
Powershell allows multiple assignment of variables and treats almost everything like an array or list. This means that instead of doing something like this: $input = "foo.bar.baz" $parts = $input.Split(".") $foo = $parts[0] $bar = $parts[1] $baz = $parts[2] You can simply...
IIS / .NET version Requirements: See here SignalR 2+ Install the NuGet package Microsoft.AspNet.SignalR (this is the whole SignalR solution) and it will ask you to install any dependencies for other packages. Accept the terms and install them as well. Now that we've got the .dlls and clie...

Page 293 of 505