Tutorial by Examples

Like iOS where you use @IBOutlet and @IBAction, here you could use them too. Let's say we have a button which when clicked changes the label's text to something else. To get started: Add a WKInterfaceLabel and a WKInterfaceLabel to the InterfaceController. Ctrl-Drag from the WKInterfaceL...
Many watchOS apps (like Activity) have several pages which you could simply scroll between them, which is a very good way to use Apple Watch. To create a page based navigation, Ctrl-Drag from one controller to another, and select "next page", as shown in the following picture:
Many watchOS apps (like Workout, Weather, Music, etc) have a main WKInterfaceTable or a set of buttons which are hooked up to another controller, similar to the navigation on iOS. This is called hierarchical view structure. To connect a button, Ctrl-Drag from the button to a controller, and select ...
Using the previous example of calculating the factorial of an integer, put in the hash table all values of factorial calculated inside the recursion, that do not appear in the table. As in the article about memoization, we declare a function f that accepts a function parameter fact and a integer pa...
Consider a company where every employee who is a manager, manages 1 or more employees, and every employee has only 1 manager. This results in two tables: EMPLOYEES EMP_IDFIRST_NAMELAST_NAMEMGR_IDE01JohnnyAppleseedM02E02ErinMacklemoreM01E03ColbyPaperworkM03E04RonSonswanM01 MANAGERS MGR_IDFIRST_N...
SELECT e.emp_id , e.first_name , e.last_name FROM employees e INNER JOIN managers m ON m.mgr_id = e.mgr_id WHERE m.mgr_id = 'M01' ; Results in: EMP_IDFIRST_NAMELAST_NAMEE02ErinMacklemoreE04RonSonswan Ultimately, for every manager we query for, we will see 1 or more employees returned.
Consult the above example tables when looking at this example. SELECT m.mgr_id , m.first_name , m.last_name FROM managers m INNER JOIN employees e ON e.mgr_id = m.mgr_id WHERE e.emp_id = 'E03' ; MGR_IDFIRST_NAMELAST_NAMEM03BarrelJones As this is the inverse of the above example, we know that for ...
You finished your app, tested on debug mode and it is working perfect. Now, you want to prepare it to publish in the Google Play Store. Xamarin documentation provides good informations in here: https://developer.xamarin.com/guides/android/deployment,_testing,_and_metrics/publishing_an_application/...
One of the common ways to parametrize your performance scripts is to use a CSV file. The best example of CSV input files usage is a login process. If you want to test your application across different users, you need to provide a list of user credentials. Let’s assume that we have a login request t...
Another way to parametrize your performance scripts is to use database data through JDBC. JDBC is an application programming interface that defines how a client can access a database. First of all, download the JDBC driver to your database (refer to the database vendor). For example, mysql driver c...
If you need to execute a repeating sequence of the same action with different parameters, use the ‘Parameterized Controller’ 3rd party plugin from JMeter-Plugins project. You need to install this plugin first by following installation procedure. Let’s assume that we want to parameterize the login ...
Introduction Put simply, these are variables that are available in all scope in your scripts. This means that there is no need to pass them as parameters in your functions, or store them outside a block of code to have them available in different scopes. What's a superglobal?? If you're thinki...
See this example here. import React, { Component } from 'react'; import { Text, View, StyleSheet, Button, Modal } from 'react-native'; import { Constants } from 'expo'; export default class App extends Component { state = { modalVisible: false, }; _handleButtonPress = () =&gt...
Consider next example: public interface A { default void foo() { System.out.println("A.foo"); } } public interface B { default void foo() { System.out.println("B.foo"); } } Here are two interfaces declaring default method foo with the same signature. If you wi...
package main import ( "fmt" "time" log "github.com/Sirupsen/logrus" mgo "gopkg.in/mgo.v2" "gopkg.in/mgo.v2/bson" ) var mongoConn *mgo.Session type MongoDB_Conn struct { Host string `json:"Host"` ...
It is quite easy to call a CGI-Script via GET. First you will need the encoded url of the script. Then you add a question mark ? followed by variables. Every variable should have two sections seperated by =. First section should be always a unique name for each variable, while the second part h...
Using Request Method POST in combination with SSL makes datatransfer more secure. In addition... Most of the encoding and decoding is not needed any more The URL will be visible to any one and needs to be url encoded. The data will be send separately and therefor should be secured via SSL The...
here is a sample web.config in order to have both http and https support. <?xml version="1.0" encoding="utf-8"?> <configuration> <appSettings> <add key="aspnet:UseTaskFriendlySynchronizationContext" value="true" /> </a...
public class RecyclerTouchListener implements RecyclerView.OnItemTouchListener { private GestureDetector gestureDetector; private RecyclerTouchListener.ClickListener clickListener; public RecyclerTouchListener(Context context, final RecyclerView recyclerView, final RecyclerTouchL...
Multiple database connections, of any type, can be defined inside the database configuration file (likely app/config/database.php). For instance, to pull data from 2 MySQL databases define them both separately: <?php return array( 'default' => 'mysql', 'connections' => array...

Page 1205 of 1336