Class DeleteOnQueryResultHandler
- java.lang.Object
-
- org.forgerock.openam.cts.impl.queue.DeleteOnQueryResultHandler
-
- All Implemented Interfaces:
ResultHandler<Collection<PartialToken>,CoreTokenException>
public class DeleteOnQueryResultHandler extends Object implements ResultHandler<Collection<PartialToken>,CoreTokenException>
This is aResultHandlerimplementation that grabs the results of a Partial Query and for each token found performs an asynchronous delete operation. This can come in handy if there is a need to find tokens based on secondary storage keys or other arbitrary information and the matching tokens needs to be deleted right away.
-
-
Constructor Summary
Constructors Constructor Description DeleteOnQueryResultHandler(TaskDispatcher taskDispatcher, ResultHandlerFactory resultHandlerFactory, Debug debug)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Collection<PartialToken>getResults()Get the results from the ResultHandler.voidprocessError(Exception exception)voidprocessResults(Collection<PartialToken> results)
-
-
-
Constructor Detail
-
DeleteOnQueryResultHandler
@Inject public DeleteOnQueryResultHandler(TaskDispatcher taskDispatcher, ResultHandlerFactory resultHandlerFactory, Debug debug)
-
-
Method Detail
-
getResults
public Collection<PartialToken> getResults()
Description copied from interface:ResultHandlerGet the results from the ResultHandler.- Specified by:
getResultsin interfaceResultHandler<Collection<PartialToken>,CoreTokenException>- Returns:
- A possibly null, result of type T.
-
processResults
public void processResults(Collection<PartialToken> results)
- Specified by:
processResultsin interfaceResultHandler<Collection<PartialToken>,CoreTokenException>- Parameters:
results- The result to store in this ResultHandler.
-
processError
public void processError(Exception exception)
- Specified by:
processErrorin interfaceResultHandler<Collection<PartialToken>,CoreTokenException>- Parameters:
exception- The error to store in this result handler.
-
-