Home Reference Source Test Repository
public class | source

LoginManager

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public
public
public

user: *

Method Summary

Public Methods
public

Check to see if there are new notications from thorntree.

public

checkStatus(): jQuery.Deferred

Check to see if the user is currently logged in.

public

error()

public

getNotifications(): jQuery.Deferred

Retrieve Thorntree notifications

public

Update the user's notifications with data from Luna

public

Set up an interval to check for Luna notification updates.

public

statusFetched(user: Object): *

Callback from checking the user's login status. If the user is not logged in, it will publish a user with a null id. Will check for user notifications if the user is logged in.

public
public

Public Constructors

public constructor source

Public Members

public feedUrl: string source

public pollInterval: * source

public statusUrl: string source

public user: * source

Public Methods

public checkNotifications(data: Object) source

Check to see if there are new notications from thorntree. If there are, it will update the user's messages and activity.

Params:

NameTypeAttributeDescription
data Object

Notification data from thorntree

public checkStatus(): jQuery.Deferred source

Check to see if the user is currently logged in.

Return:

jQuery.Deferred

public error() source

public getNotifications(): jQuery.Deferred source

Retrieve Thorntree notifications

Return:

jQuery.Deferred

A jQuery promise

public notificationsFetched(data: Object) source

Update the user's notifications with data from Luna

Params:

NameTypeAttributeDescription
data Object

The new data

public pollForUpdates() source

Set up an interval to check for Luna notification updates.

public statusFetched(user: Object): * source

Callback from checking the user's login status. If the user is not logged in, it will publish a user with a null id. Will check for user notifications if the user is logged in.

Params:

NameTypeAttributeDescription
user Object

User login information

Return:

*

public updateNotifications(): * source

Return:

*

public updateStatus(): * source

Return:

*