Class ChainTypeImpl
- java.lang.Object
-
- org.nuxeo.ecm.automation.core.impl.ChainTypeImpl
-
- All Implemented Interfaces:
OperationType
public class ChainTypeImpl extends Object implements OperationType
- Since:
- 5.7.2 Operation Type Implementation for a chain
-
-
Field Summary
Fields Modifier and Type Field Description protected OperationChain
chain
protected String
contributingComponent
The contribution fragment name.protected OperationChainContribution
contribution
The operation chain XMAP contributionprotected InvokableMethod[]
methods
Invocable methods.protected static Method
runMethod
protected AutomationService
service
The service that registered the operation.
-
Constructor Summary
Constructors Constructor Description ChainTypeImpl(AutomationService service, OperationChain chain, OperationChainContribution contribution)
Deprecated.since 11.1, see other constructorChainTypeImpl(AutomationService service, OperationChain chain, OperationChainContribution contribution, String contributingComponent)
-
Method Summary
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.nuxeo.ecm.automation.OperationType
getInputType
-
-
-
-
Field Detail
-
chain
protected OperationChain chain
-
service
protected AutomationService service
The service that registered the operation.
-
methods
protected InvokableMethod[] methods
Invocable methods.
-
contributingComponent
protected String contributingComponent
The contribution fragment name.
-
contribution
protected OperationChainContribution contribution
The operation chain XMAP contribution
-
runMethod
protected static final Method runMethod
-
-
Constructor Detail
-
ChainTypeImpl
@Deprecated public ChainTypeImpl(AutomationService service, OperationChain chain, OperationChainContribution contribution)
Deprecated.since 11.1, see other constructor
-
ChainTypeImpl
public ChainTypeImpl(AutomationService service, OperationChain chain, OperationChainContribution contribution, String contributingComponent)
- Since:
- 11.1
-
-
Method Detail
-
getChain
public OperationChain getChain()
-
newInstance
public Object newInstance(OperationContext ctx, Map<String,Object> args) throws OperationException
- Specified by:
newInstance
in interfaceOperationType
- Throws:
OperationException
-
getService
public AutomationService getService()
Description copied from interface:OperationType
Gets the service that registered that type.- Specified by:
getService
in interfaceOperationType
-
getId
public String getId()
- Specified by:
getId
in interfaceOperationType
-
getAliases
public String[] getAliases()
Description copied from interface:OperationType
The operation ID Aliases array.- Specified by:
getAliases
in interfaceOperationType
-
getType
public Class<?> getType()
- Specified by:
getType
in interfaceOperationType
-
getDocumentation
public OperationDocumentation getDocumentation() throws OperationException
- Specified by:
getDocumentation
in interfaceOperationType
- Throws:
OperationException
-
getSignature
protected ArrayList<String> getSignature(OperationChainContribution.Operation[] operations) throws OperationException
- Parameters:
operations
- operations listing that chain contains.- Returns:
- the chain signature.
- Throws:
OperationException
- Since:
- 5.7.2
-
getChainOutput
protected Class<?> getChainOutput(Class<?> chainInput, OperationChainContribution.Operation[] operations) throws OperationException
- Throws:
OperationException
- Since:
- 5.7.2
-
getOperationOutput
public Class<?> getOperationOutput(Class<?> input, OperationType operationType)
- Since:
- 5.7.2
-
getTopMethod
protected InvokableMethod getTopMethod(InvokableMethod[] methods)
- Since:
- 5.7.2 Define the top priority method to take into account for chain operations signature.
-
getContributingComponent
public String getContributingComponent()
Description copied from interface:OperationType
Gets the name of the component that contributed the operation.- Specified by:
getContributingComponent
in interfaceOperationType
-
getMethodsMatchingInput
public InvokableMethod[] getMethodsMatchingInput(Class<?> in)
- Specified by:
getMethodsMatchingInput
in interfaceOperationType
-
loadRunMethod
protected static Method loadRunMethod()
-
getParamDocumentationType
protected String getParamDocumentationType(Class<?> type, boolean isIterable)
- Since:
- 5.7.2
-
getContribution
public OperationChainContribution getContribution()
-
getMethods
public List<InvokableMethod> getMethods()
- Specified by:
getMethods
in interfaceOperationType
- Since:
- 5.7.2
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfaceOperationType
- Overrides:
hashCode
in classObject
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in interfaceOperationType
- Overrides:
equals
in classObject
-
typeof
public static ChainTypeImpl typeof(OperationChain chain, boolean replace)
-
isEnabled
public boolean isEnabled()
- Specified by:
isEnabled
in interfaceOperationType
-
clone
public ChainTypeImpl clone()
- Specified by:
clone
in interfaceOperationType
- Overrides:
clone
in classObject
-
merge
public void merge(OperationType other)
- Specified by:
merge
in interfaceOperationType
-
-