org.apache.rahas
Interface TokenStorage

All Known Implementing Classes:
SimpleTokenStore

public interface TokenStorage

The storage interface to store security tokens and manipulate them


Field Summary
static java.lang.String TOKEN_STORAGE_KEY
           
 
Method Summary
 void add(Token token)
          Add the given token to the list.
 Token[] getCancelledTokens()
          Return the list of CANCELLED tokens
 Token[] getExpiredTokens()
          Return the list of EXPIRED tokens.
 Token[] getRenewedTokens()
          Return the list of RENEWED tokens.
 Token getToken(java.lang.String id)
          Returns the Token of the given id
 java.lang.String[] getTokenIdentifiers()
          Return the list of all token identifiers.
 Token[] getValidTokens()
          Return the list of ISSUED and RENEWED tokens.
 void update(Token token)
          Update an existing token.
 

Field Detail

TOKEN_STORAGE_KEY

static final java.lang.String TOKEN_STORAGE_KEY
See Also:
Constant Field Values
Method Detail

add

void add(Token token)
         throws TrustException
Add the given token to the list.

Parameters:
token - The token to be added
Throws:
TrustException

update

void update(Token token)
            throws TrustException
Update an existing token.

Parameters:
token -
Throws:
TrustException

getTokenIdentifiers

java.lang.String[] getTokenIdentifiers()
                                       throws TrustException
Return the list of all token identifiers.

Returns:
As array of token identifiers
Throws:
TrustException

getExpiredTokens

Token[] getExpiredTokens()
                         throws TrustException
Return the list of EXPIRED tokens. If there are no EXPIRED tokens null will be returned

Returns:
An array of expired Tokens
Throws:
TrustException

getValidTokens

Token[] getValidTokens()
                       throws TrustException
Return the list of ISSUED and RENEWED tokens.

Returns:
An array of ISSUED and RENEWED Tokens.
Throws:
TrustException

getRenewedTokens

Token[] getRenewedTokens()
                         throws TrustException
Return the list of RENEWED tokens.

Returns:
An array of RENEWED Tokens
Throws:
TrustException

getCancelledTokens

Token[] getCancelledTokens()
                           throws TrustException
Return the list of CANCELLED tokens

Returns:
An array of CANCELLED Tokens
Throws:
TrustException

getToken

Token getToken(java.lang.String id)
               throws TrustException
Returns the Token of the given id

Parameters:
id -
Returns:
The requested Token identified by the give id
Throws:
TrustException