Jive API (4.5.7.0) Core Javadocs

com.jivesoftware.base
Interface AuthToken

All Superinterfaces:
java.io.Serializable

public interface AuthToken
extends java.io.Serializable

Proves that a user has successfully logged in. The existence of an AuthToken object indicates that a person has logged in correctly and has authentication to act as the user associated with the authentication. An instance of this object can be obtained from the AuthFactory and must be passed in to to get an instance of JiveContext.

In the case of using the core application services through a web interface, the expected behavior is to have a user login and then store the AuthToken object in their session. In some app servers, all objects put in the session must be serializable. The default AuthToken implementation obeys this rule, but ensure that custom AuthToken classes do as well.

See Also:
AuthFactory

Method Summary
 long getUserID()
          Returns the userID associated with this AuthToken.
 boolean isAnonymous()
          Returns true if this AuthToken is the anonymous auth token.
 

Method Detail

getUserID

long getUserID()
Returns the userID associated with this AuthToken.

Returns:
the userID associated with this AuthToken.

isAnonymous

boolean isAnonymous()
Returns true if this AuthToken is the anonymous auth token.

Returns:
true if this token is the anonymous AuthToken.

Jive Product Page

Copyright © 1999-2007 Jive Software.