Skip to content

This is a static ActionScript 3.0 Class for interacting with the Parse REST API

Notifications You must be signed in to change notification settings

camdagr8/AS3-Parse-Class

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 

Repository files navigation

AS3 Parse Class

This is a static ActionScript 3.0 Class for interacting with the Parse REST API. It's primary usage is via an AIR application.

Dependencies

This class requires the top level JSON Class http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/JSON.html

Language Version

ActionScript 3.0

Runtime Version

Flash Player 11, AIR 3.0

Usage

Using this class is fairly straight forward but I've included a few usage examples to help you on your way. Crack open the source and look at each static method to get a better understanding of the parameters required for usage.

/**
 * Parse.Post(className:String, parameters:Object, success:Function, error:Function);
 */
Parse.Post('Scores', {gamerId: 'camdagr8', score: 1337},
	function (resp) {
		trace(JSON.stringify(resp));
	},
	function (err) {
		trace(err); 
	}
);

/**
 * Parse.Get(className:String, parameters:Object, where:Object, success:Function, error:Function);
 */
Parse.Get('Scores', {count: 1}, {gamerId: 'camdagr8'},
	function (resp) {
		trace(JSON.stringify(resp));
	},
	function (err) {
		trace(err);
	}
);

/**
 * Parse.User.Get(objectId:String, success:Function, error:Function);
 */
Parse.User.Get('cAKgPVSYpD',
	function (resp) {
		trace(JSON.stringify(resp));
	},
	function (err) {
		trace(err);
	}
);

/**
 * Parse.SignIn(userName:String, password:String, success:Function, error:Function);
 */
Parse.SignIn('camdagr8', 'Pwnzj004LYF',
	function (resp) {
		trace(JSON.stringify(resp));
	},
	function (err) {
		trace(err);
	}
);

About

This is a static ActionScript 3.0 Class for interacting with the Parse REST API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published