Class TokenBlobStrategy
- java.lang.Object
-
- org.forgerock.openam.cts.utils.blob.TokenBlobStrategy
-
public class TokenBlobStrategy extends Object
Responsible for selecting the appropriate algorithm for dealing with Token binary objects prior to them being stored in the data store.
-
-
Constructor Summary
Constructors Constructor Description TokenBlobStrategy(TokenStrategyFactory factory, CoreTokenConfig config)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte[]
perform(byte[] data)
Perform the strategy on the byte array.byte[]
reverse(byte[] data)
Performs the reverse strategy on the byte array.
-
-
-
Constructor Detail
-
TokenBlobStrategy
@Inject public TokenBlobStrategy(TokenStrategyFactory factory, CoreTokenConfig config)
-
-
Method Detail
-
perform
public byte[] perform(byte[] data) throws TokenStrategyFailedException
Perform the strategy on the byte array.- Parameters:
data
- A possibly null byte[] to perform the strategy on.- Returns:
- A modified copy of the byte[] or null if data was null.
- Throws:
TokenStrategyFailedException
- If an error occurred whilst processing the Token.
-
reverse
public byte[] reverse(byte[] data) throws TokenStrategyFailedException
Performs the reverse strategy on the byte array.- Parameters:
data
- A possibly null byte[] to perform the reverse strategy on.- Returns:
- A modified copy of the byte[] or null if data was null.
- Throws:
TokenStrategyFailedException
- If an error occurred whilst processing the Token.
-
-