com. kelvinluck. flashr. core. FlashrResponseEvent

Class to hold all the information that is dispatched as an event from Flashr when there is a response to a request.  These events are caught by FlashrResponse which decodes them and calls the relevant method on itself.

Licence

This code and documentation is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 2.0.  http://creativecommons.org/licenses/by-nc-sa/2.0/

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Version

0.5.0

Author

Kelvin Luck < kelvin at kelvinluck dot com >

Project Website

http://flashr.kelvinluck.com/

Subversion Id

$Id: FlashrResponseEvent.as 72 2006-09-01 00:33:02Z kluck $

Summary
com. kelvinluck. flashr. core. FlashrResponseEventClass to hold all the information that is dispatched as an event from Flashr when there is a response to a request.
statusThe status of the response.
requestThe FlashrRequest that led to this response.
typeThe type of this event (always onAPIResponse)
errorMessageContains an error message where status != Flashr.STATUS_OK
dataA plain object used to pass the additional data that is required to decypher responses.
FlashrResponseEventConstructor
toString

status

request

var request: FlashrRequest

The FlashrRequest that led to this response.

type

var type: String

The type of this event (always onAPIResponse)

errorMessage

var errorMessage: String

Contains an error message where status != Flashr.STATUS_OK

data

var data: Object

A plain object used to pass the additional data that is required to decypher responses.

FlashrResponseEvent

function FlashrResponseEvent(request: FlashrRequest)

Constructor

toString

public function toString():String
Flashr is an ActionScript 2 wrapper for the Flickr API.
var status: Number
The status of the response.
var request: FlashrRequest
The FlashrRequest that led to this response.
Class to hold information about requests to the Flickr API through Flashr
var type: String
The type of this event (always onAPIResponse)
var errorMessage: String
Contains an error message where status != Flashr.STATUS_OK
public static var STATUS_OK: Number
There was no errors and valid XML was returned.
var data: Object
A plain object used to pass the additional data that is required to decypher responses.
function FlashrResponseEvent(request: FlashrRequest)
Constructor
public function toString():String
Class to define a listener for responses from the FlickrAPI.
public static var STATUS_BUSY: Number
The API is already waiting for the response to a method call so cannot make another call
public static var STATUS_ERROR_CONNECTING: Number
Could not connect to the server (e.g.
public static var STATUS_INVALID_XML: Number
The XML returned by the server wasn’t in a rsp / tag.
public static var STATUS_USER_NOT_LOGGED_IN: Number
The user wasn’t logged in and tried to access a method that requires authentication (returned from flickr.com)
public static var STATUS_INVALID_API_KEY: Number
The API key sent to flickr was invalid (returned from flickr.com)