Tutorial by Examples: al

Throwable has two direct subclasses, Exception and Error. While it's possible to create a new class that extends Throwable directly, this is inadvisable as many applications assume only Exception and Error exist. More to the point there is no practical benefit to directly subclassing Throwable, as ...
A namespace can be given an alias (i.e., another name for the same namespace) using the namespace identifier = syntax. Members of the aliased namespace can be accessed by qualifying them with the name of the alias. In the following example, the nested namespace AReallyLongName::AnotherReallyLongNam...
Detailed instructions on getting apache-zookeeper set up or installed.
You can install ImageMagick from source or Binary. In case of Windows Binary Download executable binary file. And simply click on the appropriate version and it will launch itself and follow the wizard. You can type the following command to find out whether ImageMagick is successfully installed o...
Detailed instructions on getting mongodb-query set up or installed.
var="hello" function foo(){ echo $var } foo Will obviously output "hello", but this works the other way around too: function foo() { var="hello" } foo echo $var Will also output "hello"
function foo() { local var var="hello" } foo echo $var Will output nothing, as var is a variable local to the function foo, and its value is not visible from outside of it.
Calculating the power of a given number can be done recursively as well. Given a base number n and exponent e, we need to make sure to split the problem in chunks by decreasing the exponent e. Theoretical Example: 2² = 2x2 2³ = 2x2x2 or, 2³ = 2² x 2In there lies the secret of our recursive al...
Creating a project in scala is very similar to creating one in java. Here is what the entry class should look like: package com.example.myplugin; //{$TopLevelDomain}.{$Domain}.{$PluginName} import org.bukkit.plugin.java.JavaPlugin import org.bukkit.command.CommandSender import org.bukkit.comma...
SET FOREIGN_KEY_CHECKS=0; TRUNCATE `sales_payment_transaction`; TRUNCATE `sales_flat_creditmemo`; TRUNCATE `sales_flat_creditmemo_comment`; TRUNCATE `sales_flat_creditmemo_grid`; TRUNCATE `sales_flat_creditmemo_item`; TRUNCATE `sales_flat_order`; TRUNCATE `sales_flat_order_address`; TRUNCA...
Custom attribute in sales related tables like: sales_flat_quote, sales_flat_order_item, sales_flat_order, etc table In your installation file sql/some_setup/mysql-install-0.1.0.php: <?php $installer = $this; $installer->startSetup(); $installer->addAttribute('quote', 'custom_field'...
Since a signal handler will be called by the kernel using the C calling convention, we must tell the compiler to use the C calling convention when compiling the function. volatile sig_atomic_t death_signal = 0; extern "C" void cleanup(int signum) { death_signal = signum; } int mai...
This simple function can be used to get value from exactly one field one record query result Public Function getDataScalar(ssql As String) openConnection() Try Dim q As New MySqlCommand q.Connection = db q.CommandText = ssql getDataScalar = q.Execut...
import sys from PyQt4.QtCore import * from PyQt4.QtGui import * def window(): app = QApplication(sys.argv) win = QDialog() b1 = QPushButton(win) b1.setText("Button1") b1.move(50,20) b1.clicked.connect(b1_clicked) b2 = QPushButton(win) b2.setText(&quot...
Note: Angular CLI versions are under rapid development. This documentation targets for the latest version. Prerequisites To execute and work with the latest version, Angular CLI and the project have dependencies that require node v6.9.0 or higher. Setup Make sure that a node version is insta...
Detailed instructions on getting adobe-analytics set up or installed.
Detailed instructions on getting webview set up or installed.
After going through the Basic Setup example, you may find yourself repeating most part of it in every single Scala Gradle project. Smells like boilerplate code... What if, instead of applying the Scala plugin offered by Gradle, you could apply your own Scala plugin, which would be responsible for h...
In your activity layout activity_main.xml specify WebView component as following: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" ...

Page 232 of 269