Class FormProcessorRegistry
- java.lang.Object
-
- org.alfresco.repo.forms.processor.FormProcessorRegistry
-
public class FormProcessorRegistry extends java.lang.ObjectHolds a FormProcessor implementation for each of the types of form that can be processed. By default a node, type, task, and workflow form processor are available.Given an item the registry selects the relevant form processor, the match is performed via pattern matching on the supplied string.
- Author:
- Gavin Cornwell
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<FormProcessor>processors
-
Constructor Summary
Constructors Constructor Description FormProcessorRegistry()Constructs the registry
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddProcessor(FormProcessor processor)Registers a form processorFormProcessorgetApplicableFormProcessor(Item item)Returns a FormProcessor for the provided item.
-
-
-
Field Detail
-
processors
protected java.util.List<FormProcessor> processors
-
-
Method Detail
-
addProcessor
public void addProcessor(FormProcessor processor)
Registers a form processor- Parameters:
processor- The FormProcessor to regsiter
-
getApplicableFormProcessor
public FormProcessor getApplicableFormProcessor(Item item)
Returns a FormProcessor for the provided item.Each registered processors is asked if it is applicable for the given item, the first processor to positively respond that is also active is selected and returned.
- Parameters:
item- The item to find a form processor for- Returns:
- An applicable FormProcessor
-
-