Interface OptimizingTriggerCreator
- 
- All Known Implementing Classes:
- OptimizingTriggerCreatorImpl
 
 public interface OptimizingTriggerCreatorAdds recompute triggers to objects in an optimized way: - The triggers are set to a given time in future (e.g. 1 minute from now). - If more requests to create triggers to the same object come before that time comes (minus some safety margin, e.g. 2 seconds), their creation is skipped. Currently we deal only with the recompute triggers. Other types can be added as necessary. The deduplication currently assumes the requests are of the same kind (i.e. either name-based or OID-based).
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description booleancreateForNamedObject(@NotNull Class<? extends ObjectType> type, @NotNull String name)Creates a trigger for the object with the given name.booleancreateForNamedUser(@NotNull String name)Creates a trigger for the user with the given name.booleancreateForObject(@NotNull Class<? extends ObjectType> type, @NotNull String oid)Creates a trigger to the user with the given OID.
 
- 
- 
- 
Method Detail- 
createForNamedUserboolean createForNamedUser(@NotNull @NotNull String name) throws SchemaException, ObjectAlreadyExistsException, ObjectNotFoundExceptionCreates a trigger for the user with the given name.- Returns:
- true if the trigger was really added; false if it already existed or could not be added (Note that if the object cannot be found by the name, currently no exception is reported.)
- Throws:
- SchemaException
- ObjectAlreadyExistsException
- ObjectNotFoundException
 
 - 
createForNamedObjectboolean createForNamedObject(@NotNull @NotNull Class<? extends ObjectType> type, @NotNull @NotNull String name) throws ObjectAlreadyExistsException, ObjectNotFoundException, SchemaExceptionCreates a trigger for the object with the given name.- Returns:
- true if the trigger was really added; false if it already existed or could not be added (Note that if the object cannot be found by the name, currently no exception is reported.)
- Throws:
- ObjectAlreadyExistsException
- ObjectNotFoundException
- SchemaException
 
 - 
createForObjectboolean createForObject(@NotNull @NotNull Class<? extends ObjectType> type, @NotNull @NotNull String oid) throws ObjectAlreadyExistsException, ObjectNotFoundException, SchemaExceptionCreates a trigger to the user with the given OID.- Returns:
- true if the trigger was really added; false if it already existed or could not be added
- Throws:
- ObjectAlreadyExistsException
- ObjectNotFoundException
- SchemaException
 
 
- 
 
-