public class FileBasedTokenRegistry extends FileBasedSTSOperations implements SecurityTokenRegistry
SecurityTokenRegistry| Modifier and Type | Class and Description |
|---|---|
protected static class |
FileBasedTokenRegistry.TokenHolder |
| Modifier and Type | Field and Description |
|---|---|
protected static String |
FILE_NAME |
protected Map<String,FileBasedTokenRegistry.TokenHolder> |
holders |
protected File |
registryFile |
directory, logger| Constructor and Description |
|---|
FileBasedTokenRegistry() |
FileBasedTokenRegistry(String fileName) |
| Modifier and Type | Method and Description |
|---|---|
void |
addToken(String tokenID,
Object token)
Add a token to the registry with the given id
|
protected void |
flush() |
Object |
getToken(String tokenID)
Given the id, return a token
|
protected void |
read() |
void |
removeToken(String tokenID)
Remove a token given the ID
|
createprotected static final String FILE_NAME
protected File registryFile
protected Map<String,FileBasedTokenRegistry.TokenHolder> holders
public FileBasedTokenRegistry()
public FileBasedTokenRegistry(String fileName)
public void addToken(String tokenID, Object token) throws IOException
SecurityTokenRegistryaddToken in interface SecurityTokenRegistryIOExceptionSecurityTokenRegistry.addToken(java.lang.String,
java.lang.Object)public void removeToken(String tokenID) throws IOException
SecurityTokenRegistryremoveToken in interface SecurityTokenRegistryIOExceptionSecurityTokenRegistry.removeToken(java.lang.String)public Object getToken(String tokenID)
SecurityTokenRegistrygetToken in interface SecurityTokenRegistrySecurityTokenRegistry.getToken(java.lang.String)protected void flush()
throws IOException
IOExceptionprotected void read()
throws IOException
IOExceptionCopyright © 2018 JBoss by Red Hat. All rights reserved.