This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var myAlertView = UIAlertView() | |
myAlertView.title = "Test" | |
myAlertView.message = "Hello, world!" | |
myAlertView.addButtonWithTitle("Dismiss") | |
myAlertView.show() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Step 1: Enable capabilities "background fetch" | |
Step2 : Setup AppDelegate.swift | |
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { | |
let settings = UIUserNotificationSettings(forTypes: UIUserNotificationType.Alert, categories: nil) | |
UIApplication.sharedApplication().registerUserNotificationSettings(settings) | |
UIApplication.sharedApplication().setMinimumBackgroundFetchInterval(UIApplicationBackgroundFetchIntervalMinimum) | |
return true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ellipse(200, 50, 100, 100); | |
ellipse(200, 200, 200, 200); | |
line(10, 100, 100, 200); | |
//ellipse(200, 300, 50, 50); | |
ellipse(180, 40, 10, 10); //eye | |
ellipse(215, 40, 10, 10); | |
line(400, 100, 300, 200); | |
line(115, 250, 70, 400); | |
line(285, 250, 370, 400); | |
ellipse(200, 80, 40, 10); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function wordcount(paragraph) { | |
var totalSpaces = 0; | |
var letter; | |
for (var i = 0; i < paragraph.length; i++) { | |
letter = paragraph.substr(i, 1); | |
if (letter === ' ') { | |
totalSpaces = totalSpaces + 1; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Canvas = require('canvas') | |
, Image = Canvas.Image | |
, canvas = new Canvas(200, 200) | |
, ctx = canvas.getContext('2d'); | |
ctx.font = '30px Impact'; | |
ctx.rotate(.1); | |
ctx.fillText("Awesome!", 50, 100); | |
var te = ctx.measureText('Awesome!'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
var Canvas = require('canvas') | |
, Image = Canvas.Image | |
, canvas = new Canvas(400, 600) | |
, ctx = canvas.getContext('2d'); | |
var te = ctx.measureText('Awesome!'); | |
ctx.strokeStyle = 'rgba(0,0,0,0.5)'; | |
ctx.beginPath(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
created | |
deleted | |
forced | |
base_ref | |
compare | |
****************************** | |
commits.0 | |
****************************** | |
commits.0.distinct |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var util = require('util'); | |
var async = require('async'); | |
function FeatureStrategy(values) { | |
this._values = values; | |
this._strategyId; | |
} | |
FeatureStrategy.prototype.resolve = function (context) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mvn archetype:generate -DgroupId=com.rameshrm -DartifactId=service-client -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** Runnable w/a Private Variable **/ | |
package com.api.specs; | |
/** | |
* Hello world! | |
* | |
*/ | |
public class App { | |
public static void main(String[] args) { |
OlderNewer