org.apache.slide.common
Class SlideToken

java.lang.Object
  |
  +--org.apache.slide.common.SlideToken

public final class SlideToken
extends java.lang.Object

Slide token class.

Author:
Remy Maucherat

Constructor Summary
SlideToken()
          Constructor.
SlideToken(CredentialsToken credentialsToken)
          Constructor.
SlideToken(CredentialsToken credentialsToken, java.util.Hashtable parameters)
          Constructor.
 
Method Summary
 void addLockToken(java.lang.String lockId)
          Add a new lock token to the lock token list.
 void addParameter(java.lang.String parameterName, java.lang.Object parameterValue)
          Add a new parameter to the parameter list.
 boolean checkLockToken(java.lang.String lockToken)
          Checks if the given lock token is present.
 void clearLockTokens()
          Clears the lock token list.
 void clearParameters()
          Clears the parameter list.
 CacheInfoToken getCacheInfoToken()
          Returns the CacheInfo token.
 CredentialsToken getCredentialsToken()
          Returns the credentials token.
 java.util.Enumeration getParameterNames()
          Return parameter list.
 boolean isEnforceLockTokens()
          Use lock tokens in lock resolution ?
 void removeLockToken(java.lang.String lockId)
          Removes a lock token from the lock token list.
 void removeParameter(java.lang.String parameterName)
          Removes a parameter from the parameter list.
 void setCacheInfoToken(CacheInfoToken cacheInfoToken)
          CacheInfo token mutator.
 void setCredentialsToken(CredentialsToken credentialsToken)
          Credentials token mutator.
 void setEnforceLockTokens(boolean enforceLockTokens)
          Enforce lock tokens flag mutator.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SlideToken

public SlideToken(CredentialsToken credentialsToken)
Constructor.
Parameters:
credentials - Credentials stored in this token

SlideToken

public SlideToken()
Constructor.
Parameters:
credentials - Credentials stored in this token

SlideToken

public SlideToken(CredentialsToken credentialsToken,
                  java.util.Hashtable parameters)
Constructor.
Parameters:
credentials - Credentials stored in this token
parameters - Token parameters
Method Detail

getCredentialsToken

public CredentialsToken getCredentialsToken()
Returns the credentials token.
Returns:
String

setCredentialsToken

public void setCredentialsToken(CredentialsToken credentialsToken)
Credentials token mutator.

getCacheInfoToken

public CacheInfoToken getCacheInfoToken()
Returns the CacheInfo token.
Returns:
CacheInfoToken

setCacheInfoToken

public void setCacheInfoToken(CacheInfoToken cacheInfoToken)
CacheInfo token mutator.

isEnforceLockTokens

public boolean isEnforceLockTokens()
Use lock tokens in lock resolution ?
Returns:
boolean

setEnforceLockTokens

public void setEnforceLockTokens(boolean enforceLockTokens)
Enforce lock tokens flag mutator.
Parameters:
enforceLockTokens - New flag value

addLockToken

public void addLockToken(java.lang.String lockId)
Add a new lock token to the lock token list.
Parameters:
lockToken - Lock token to add

removeLockToken

public void removeLockToken(java.lang.String lockId)
Removes a lock token from the lock token list.
Parameters:
lockToken - Lock token to remove

clearLockTokens

public void clearLockTokens()
Clears the lock token list.

checkLockToken

public boolean checkLockToken(java.lang.String lockToken)
Checks if the given lock token is present.
Parameters:
lockToken - Lock token to check
Returns:
boolean True if the given lock token is present

addParameter

public void addParameter(java.lang.String parameterName,
                         java.lang.Object parameterValue)
Add a new parameter to the parameter list.
Parameters:
parameterName - Parameter to add
parameterValue - Parameter value

removeParameter

public void removeParameter(java.lang.String parameterName)
Removes a parameter from the parameter list.
Parameters:
parameterName - Parameter to remove

clearParameters

public void clearParameters()
Clears the parameter list.

getParameterNames

public java.util.Enumeration getParameterNames()
Return parameter list.