Class SpazBasicAuth
SpazBasicAuth
Defined in: spazauth.js.
Constructor Attributes | Constructor Name and Description |
---|---|
Construct a new basic authentication object. |
Method Attributes | Method Name and Description |
---|---|
authorize(username, password, onComplete)
Set username and password of account to access service. |
|
load(pickle)
Load basic auth credentials from a serialized string |
|
save()
Save basic auth credentials into a serialized string |
|
Returns the authentication header |
Method Detail
{Boolean} authorize(username, password, onComplete)
Set username and password of account to access service.
- Parameters:
- {string} username
- {string} password
- {function} onComplete Optional
- a callback to fire when complete. Currently just passed TRUE all the time; for compatibility with oAuth need for callbacks
- Returns:
- {Boolean} true. ALWAYS returns true!
{boolean} load(pickle)
Load basic auth credentials from a serialized string
- Parameters:
- {string} pickle
- the serialized data string returned by save()
- Returns:
- {boolean} true if successfully loaded