AeroGear developer release

Yesterday we released a new version of the AeroGear library! Highlights are a more fluent API to create pipes,stores and authModules. Another milestone was the usage of using the previously discussed configuration objects!

Get it from the CocoaPods repo!

New way to create a AGPipe:

// NSURL object:
NSURL* serverURL = [NSURL URLWithString:@""];

// create the 'todo' pipeline, which points to the baseURL of the REST application
AGPipeline* todo = [AGPipeline pipeline:serverURL];

// Add a REST pipe for the 'projects' endpoint
id<AGPipe> projects = [pipeline pipe:^(id<AGPipeConfig> config) {
    [config name:@"projects"];
    [config type:@"REST"];

New way to create a AGStore:

// create the datamanager
AGDataManager* dm = [AGDataManager manager];
// add a new (default) store object:
id<AGStore> myStore = [dm store:^(id<AGStoreConfig> config) {
    [config name:@"tasks"];
    [config TYPE:@"MEMORY"];

New way to create a AGAuthenticationModule:

// create an authenticator object
AGAuthenticator* authenticator = [AGAuthenticator authenticator];

// add a new auth module and the required 'base url':
NSURL* baseURL = [NSURL URLWithString:@""];
id<AGAuthenticationModule> myMod = [authenticator auth:^(id<AGAuthConfig> config) {
    [config name:@"authMod"];
    [config baseURL:baseURL];

As always, feedback and JIRAs are welcome!



Posted in aerogear

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: