|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.as400.access.ProfileHandleImplNative
The ProfileHandleImplNative class provides an implementation for behavior delegated by a ProfileHandleCredential object.
Constructor Summary | |
---|---|
ProfileHandleImplNative()
|
Method Summary | |
---|---|
void |
destroy()
Destroy or clear sensitive information maintained by the credential implementation. |
byte[] |
getCurrentHandle()
Generates and returns a profile handle based on the current thread identity. |
int |
getTimeToExpiration()
Returns the number of seconds before the credential is due to expire. |
int |
getVersion()
Returns the version number for the implementation. |
boolean |
isCurrent()
Indicates if the credential is still considered valid for authenticating to associated services or performing related actions. |
void |
refresh()
Updates or extends the validity period for the credential. |
void |
releaseHandle(byte[] handle)
Releases OS resources for the given profile handle. |
void |
setCredential(AS400Credential credential)
Sets the credential delegating behavior to the implementation object. |
void |
setCurrentHandle(byte[] handle)
Sets the current thread identity based on the given profile handle. |
AS400Credential |
swap(boolean genRtnCr)
Attempts to swap the thread identity based on this credential. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ProfileHandleImplNative()
Method Detail |
public void destroy() throws DestroyFailedException
Subsequent requests may result in a NullPointerException.
Subclasses should override as necessary to destroy or clear class-specific data.
destroy
in interface com.ibm.as400.security.auth.AS400CredentialImpl
DestroyFailedException
- If errors occur while destroying or clearing credential implementation data.public byte[] getCurrentHandle() throws RetrieveFailedException
getCurrentHandle
in interface ProfileHandleImpl
RetrieveFailedException
- If errors occur while generating the handle.public int getTimeToExpiration() throws RetrieveFailedException
Subclasses implementing timed credentials must override.
getTimeToExpiration
in interface com.ibm.as400.security.auth.AS400CredentialImpl
RetrieveFailedException
- If errors occur while retrieving timeout information.public int getVersion()
Used to ensure the implementation is valid for specific functions.
getVersion
in interface com.ibm.as400.security.auth.AS400CredentialImpl
public boolean isCurrent()
An exception is not thrown on failure to remain consistent with the Refreshable interface (even though some credential classes currently avoid the dependency established by implementing the interface).
isCurrent
in interface com.ibm.as400.security.auth.AS400CredentialImpl
public void refresh() throws RefreshFailedException
refresh
in interface com.ibm.as400.security.auth.AS400CredentialImpl
RefreshFailedException
- If the refresh attempt fails.public void releaseHandle(byte[] handle) throws DestroyFailedException
handle
- The handle bytes.
DestroyFailedException
- If errors occur while releasing the handle.public void setCredential(AS400Credential credential)
setCredential
in interface com.ibm.as400.security.auth.AS400CredentialImpl
credential
- The associated credential.public void setCurrentHandle(byte[] handle) throws SwapFailedException
handle
- The handle bytes.
SwapFailedException
- If errors occur while generating the handle.public AS400Credential swap(boolean genRtnCr) throws SwapFailedException
swap
in interface com.ibm.as400.security.auth.AS400CredentialImpl
genRtnCr
- Indicates whether a return credential should be generated, even if supported. When appropriate, not generating a return credential can improve performance and avoid potential problems in creating the credential.
SwapFailedException
- If errors occur while swapping thread identity.
SecurityException
- If the caller does not have permission to modify the OS thread identity.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |