Package org.nuiton.topia.replication
Class TopiaReplicationOperationProvider
java.lang.Object
org.nuiton.topia.replication.TopiaReplicationOperationProvider
public class TopiaReplicationOperationProvider
extends java.lang.Object
Provider of
TopiaReplicationOperation.- Since:
- 2.4.3
- Author:
- tchemit <chemit@codelutin.com>
-
Field Summary
Fields Modifier and Type Field Description protected TopiaReplicationOperation[]operationsAll available operations detected via aServiceLoaderon contractTopiaReplicationOperation. -
Constructor Summary
Constructors Constructor Description TopiaReplicationOperationProvider() -
Method Summary
Modifier and Type Method Description TopiaReplicationOperationgetOperation(java.lang.Class<? extends TopiaReplicationOperation> operationClass)Obtains the instanciated (and initialized) operation of the given type.TopiaReplicationOperationgetOperation(ReplicationOperationDef operationDef)Obtains the instanciated (and initialized) operation of the given operation definition.TopiaReplicationOperation[]getOperations()Obtains allTopiaReplicationOperationavailable viaServiceLoader.TopiaReplicationOperationUndoablegetUndoableOperation(ReplicationOperationDef operationDef)
-
Field Details
-
operations
All available operations detected via aServiceLoaderon contractTopiaReplicationOperation.
-
-
Constructor Details
-
TopiaReplicationOperationProvider
public TopiaReplicationOperationProvider()
-
-
Method Details
-
getOperations
Obtains allTopiaReplicationOperationavailable viaServiceLoader. Ifoperationsis null, then load operations, otherwise just return the already computed result.- Returns:
- the array of all available operations
-
getOperation
public TopiaReplicationOperation getOperation(java.lang.Class<? extends TopiaReplicationOperation> operationClass)Obtains the instanciated (and initialized) operation of the given type.- Parameters:
operationClass- type of searched operation- Returns:
- the found operation, or
nullif not found.
-
getOperation
Obtains the instanciated (and initialized) operation of the given operation definition.- Parameters:
operationDef- operation definition of searched operation- Returns:
- the found operation, or
nullif not found.
-
getUndoableOperation
public TopiaReplicationOperationUndoable getUndoableOperation(ReplicationOperationDef operationDef) throws java.lang.IllegalArgumentException- Throws:
java.lang.IllegalArgumentException
-