Tutorial by Examples: and

XML <Deborah> <address>Dark world</address> <master>Babadi</master> <ID>#0</ID> <colour>red</colour> <side>evil</side> </Deborah> XPATH boolean(/Deborah/master/text()) OR string(/Deborah/master...
XML <Dobby> <address>Hogwartz</address> <master></master> <colour>wheatish</colour> <side>all good</side> </Dobby> XPATH boolean(/Dobby/master/text()) OR string(/Dobby/master) != '' OUTPUT false
Whitelisting won't disable the doze mode for your app, but you can do that by using network and hold-wake locks. Whitelisting an Android application programmatically can be done as follows: boolean isIgnoringBatteryOptimizations = pm.isIgnoringBatteryOptimizations(getPackageName()); if(!isIgnorin...
From android 6.0 this permission needs to grant dynamically, <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/> Throwing below permission denied error on 6.0, Caused by: android.view.WindowManager$BadTokenException: Unable to add window android.view.ViewRoo...
foo = frozenset(["bar", 1, "Hello!"]) foo[2] = 7 # ERROR foo.add(3) # ERROR Second line would return an error since frozenset members once created aren't assignable. Third line would return error as frozensets do not support functions that can manipulate members.
GCobol* GnuCOBOL SORT verb example using standard in and standard out identification division. program-id. sorting. environment division. input-output section. file-control. select sort-in assign keyboard organizat...
Installation: In order to use DataProviders, you need junit-dataprovider .jar : Github Direct download Hamcrest-core-1.3.jar : Github Direct download And add both of this .jar to your project. Usage: Add this import to your code: import com.tngtech.java.junit.dataprovider.DataProvider; im...
Flower is a web based tool to monitor Celery. To install Flower, we can use pip as follows: pip install flower To run Flower for proj: celery -A proj flower Now, flower is accessible in: http://localhost:5555
Using webpack, you can bundle your component: $ webpack This will create our output file in build directory. Open the HTML page in a browser to see component in action
To find the largest items in a collection, heapq module has a function called nlargest, we pass it two arguments, the first one is the number of items that we want to retrieve, the second one is the collection name: import heapq numbers = [1, 4, 2, 100, 20, 50, 32, 200, 150, 8] print(heapq.nl...
Let say you want to create css/js file specific to a platform. For that you have to create a merges folder in root folder of you cordova porject. In merges folder create directory for each platform (android/ios..). then in specific platform folder create a css/js folder and put your css/js file spec...
You can use plugman command to install/uninstall custom cordova plugins. To install plugman npm install -g plugman Install plugin command syntax: plugman <install|uninstall> --platform <ios|android|blackberry10|wp8> --project <directory> --plugin <name|url|path> Exa...
Monthwise difference between two dates(timestamp) select ( (DATE_PART('year', AgeonDate) - DATE_PART('year', tmpdate)) * 12 + (DATE_PART('month', AgeonDate) - DATE_PART('month', tmpdate)) ) from dbo."Table1" Yearwise difference between two dates...
Model With EF Core, data access is performed using a model. A model is made up of entity classes and a derived context that represents a session with the database, allowing you to query and save data. You can generate a model from an existing database, hand code a model to match your database, or ...
Android supports fingerprint api from Android 6.0 (Marshmallow) SDK 23 To use this feature in your app, first add the USE_FINGERPRINT permission in your manifest. <uses-permission android:name="android.permission.USE_FINGERPRINT" /> Here the procedure to follow ...
Lunch application for testing override func setUp() { super.setUp() let app = XCUIApplication() app.launch() } Terminating application func testStacOverFlowApp() { app.terminate() }
To generate samples of cryptographically random data: final byte[] sample = new byte[16]; new SecureRandom().nextBytes(sample); System.out.println("Sample: " + DatatypeConverter.printHexBinary(sample)); Produces output similar to: Sample: E4F14CEA2384F70B706B53A6DF8C5EFE Note...
To compute a signature: final PrivateKey privateKey = keyPair.getPrivate(); final byte[] data = "FOO BAR".getBytes(); final Signature signer = Signature.getInstance("SHA1withRSA"); signer.initSign(privateKey); signer.update(data); final byte[] signature = signer.sign();...
After you have a running cluster you can manage it with the kubectl command. Most of the commands you can get with the kubectl --help command, but I show you the most common commands, for manage and getting info about your cluster, nodes, pods, services and labels. For getting information about t...
QGraphics can be used to organize complicated scenes of visual objects into a framework that makes them easier to handle. There are three major types of objects used in this framework QGraphicsView, QGraphicsScene, and QGraphicsItems. QGraphicsItems are the basic visual items that exist in the scen...

Page 111 of 153