Skip to content

Instantly share code, notes, and snippets.

View elm4ward's full-sized avatar

Elmar Kretzer elm4ward

View GitHub Profile
@elm4ward
elm4ward / gist:3838469
Created October 5, 2012 07:00 — forked from matzew/gist:3833597
Usage of AGAuthenticationManager and AGAuthenticationModule for signup/signin/signout
// create an auth manager object
AGAuthenticationManager* authMgr = [AGAuthenticationManager manager];
// add a new auth module and the required 'base url':
NSURL* baseURL = [NSURL URLWithString:@"https://todoauth-aerogear.rhcloud.com/todo-server"];
id<AGAuthenticationModule> myMod = [authMgr add:@"authMod" baseURL:baseURL];
// ====================================
@elm4ward
elm4ward / dsltest.swift
Last active September 1, 2016 10:47 — forked from marcpalmer/dsltest.swift
Example of using Swift property change observation to bind models to arguments passed to DSL closures
import UIKit
enum GraphicsCommand {
case setColour(colour: UInt32)
case moveTo(x: Float, y: Float)
case lineTo(x: Float, y: Float)
}