Class WorkflowEnumerator
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.ametys.plugins.ugc.enumerator.WorkflowEnumerator
-
- All Implemented Interfaces:
Enumerator<String>,Contextualizable,LogEnabled,Serviceable
public class WorkflowEnumerator extends AbstractLogEnabled implements Enumerator<String>, Contextualizable, Serviceable
Enumeratorfor workflow enumeration
-
-
Field Summary
Fields Modifier and Type Field Description private static String__PREFIX_FILEprotected Context_contextThe cocoon contextprotected SourceResolver_srcResolverthe source resolverprotected WorkflowHelper_workflowHelperThe workflow helper
-
Constructor Summary
Constructors Constructor Description WorkflowEnumerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private Map<String,I18nizableText>_getThemes()protected Map<String,I18nizableText>_getWorkflows()Retrieves the workflows begin by 'workflow-ugc'voidcontextualize(Context context)I18nizableTextgetEntry(String value)Retrieves a single label from a value.Map<String,I18nizableText>getTypedEntries()Provides the enumerated values with their optional label.voidservice(ServiceManager manager)-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ametys.runtime.model.Enumerator
getConfiguration
-
-
-
-
Field Detail
-
__PREFIX_FILE
private static final String __PREFIX_FILE
- See Also:
- Constant Field Values
-
_srcResolver
protected SourceResolver _srcResolver
the source resolver
-
_workflowHelper
protected WorkflowHelper _workflowHelper
The workflow helper
-
-
Constructor Detail
-
WorkflowEnumerator
public WorkflowEnumerator()
-
-
Method Detail
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualizein interfaceContextualizable- Throws:
ContextException
-
service
public void service(ServiceManager manager) throws ServiceException
- Specified by:
servicein interfaceServiceable- Throws:
ServiceException
-
getTypedEntries
public Map<String,I18nizableText> getTypedEntries() throws Exception
Description copied from interface:EnumeratorProvides the enumerated values with their optional label.- Specified by:
getTypedEntriesin interfaceEnumerator<String>- Returns:
- the enumerated values and their label.
- Throws:
Exception- if an error occurs. TODO NEWATTRIBUTEAPI: rename this method whenEnumeratorwill be removed
-
getEntry
public I18nizableText getEntry(String value) throws Exception
Description copied from interface:EnumeratorRetrieves a single label from a value.- Specified by:
getEntryin interfaceEnumerator<String>- Parameters:
value- the value.- Returns:
- the label or
nullif not found. - Throws:
Exception- if an error occurs.
-
_getThemes
private Map<String,I18nizableText> _getThemes()
-
_getWorkflows
protected Map<String,I18nizableText> _getWorkflows()
Retrieves the workflows begin by 'workflow-ugc'- Returns:
- The map of workflows
-
-