Tutorial by Examples: o

https://sourceforge.net/projects/log4cplus/ updates/bug fixes - last release was Jan. 2016 user can select select different LogLevels – TRACE, DEBUG, INFO, WARN, ERROR, and FATAL hierarchical Loggers supports multi–threaded applications but is not safe to be used from asynchronous signals’ ha...
https://sourceforge.net/projects/log4cpp/ bug fixes are about once a year, last release was April 2015 supports multi-threaded applications •no clear documentation exist is licensed under the GNU Lesser General Public License (LGPL) as of version 0.2.1, before that have been released under the...
val foo : Int by lazy { 1 + 1 } println(foo) The example prints 2.
var foo : Int by Delegates.observable("1") { property, oldValue, newValue -> println("${property.name} was changed from $oldValue to $newValue") } foo = 2 The example prints foo was changed from 1 to 2
val map = mapOf("foo" to 1) val foo : String by map println(foo) The example prints 1
class MyDelegate { operator fun getValue(owner: Any?, property: KProperty<*>): String { return "Delegated value" } } val foo : String by MyDelegate() println(foo) The example prints Delegated value
This module can be used to : Create a new element. Delete an element from HTML document. Place element in HTML document. Iinitialisation To be able to use the dom-construct module we need to load it as fallow : require(["dojo/dom-construct"], function(domConstruct){...
interface Foo { fun example() } class Bar { fun example() { println("Hello, world!") } } class Baz(b : Bar) : Foo by b Baz(Bar()).example() The example prints Hello, world!
val a = Array(3) { i -> i * 2 } // creates an Array<Int> of size 3 containing [0, 2, 4]
General-purpose stopwatch for timing how long a function takes to run: object Benchmark { fun realtime(body: () -> Unit): Duration { val start = Instant.now() try { body() } finally { val end = Instant.now() return Duration.b...
This module provides function that allows you to manipulate CSS classes of DOM elements. Initialization To be able to use the dom-class module we need to load it as fallow : require(["dojo/dom-class"], function(domClass){ // Write code here }); contains() This function check...
<View style={[(this.props.isTrue) ? styles.bgcolorBlack : styles.bgColorWhite]}> If the value of isTrue is true then it will have black background color otherwise white.
PGSQL> SELECT COALESCE(NULL, NULL, 'HELLO WORLD'); coalesce -------- 'HELLO WORLD'
PGSQL> SELECT COALESCE(NULL, NULL, 'first non null', null, null, 'second non null'); coalesce -------- 'first non null'
<Image style={[this.props.imageStyle]} source={this.props.imagePath ? this.props.imagePath : require('../theme/images/resource.png')} /> If the path is available in imagePath then it will be assigned to source else the default image path will be assigned.
let imagePath = require("../../assets/list.png"); <Image style={{height: 50, width: 50}} source={imagePath} /> From external resource: <Image style={{height: 50, width: 50}} source={{uri: userData.image}} />
Installation pip install Flask-SQLAlchemy Simple Model class User(db.Model): id = db.Column(db.Integer, primary_key=True) name = db.Column(db.String(80)) email = db.Column(db.String(120), unique=True) The code example above shows a simple Flask-SQLAlchemy model, we can add an ...
As mentioned here, the old-school method to run another script is by using temporary files. Simple echo it into a file and then run it(and remove it optionally). Here's the basic concept: @echo off echo //A JS Comment > TempJS.js echo //Add your code>>TempJS.js cscript //nologo //e...
from flask_wtf import FlaskForm from wtforms import StringField, IntegerField from wtforms.validators import DataRequired class MyForm(FlaskForm): name = StringField('name', validators=[DataRequired()]) age = InterField('age', validators=[DataRequired()]) To render the template you...
The rotate(r) method of the 2D context rotates the canvas by the specified amount r of radians around the origin. HTML <canvas id="canvas" width=240 height=240 style="background-color:#808080;"> </canvas> <button type="button" onclick="rotate_c...

Page 1000 of 1038