Class TagCreator
- java.lang.Object
-
- com.adobe.acs.commons.mcp.ProcessDefinition
-
- com.adobe.acs.commons.mcp.impl.processes.TagCreator
-
- All Implemented Interfaces:
FormProcessor,Serializable
public class TagCreator extends ProcessDefinition implements Serializable
Creates cq:Tags based on a well defined Excel document.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTagCreator.ReportRowSatusstatic classTagCreator.TagBuilderprotected static classTagCreator.TagRootResolverprotected static classTagCreator.TagsLocation
-
Field Summary
Fields Modifier and Type Field Description InputStreamexcelFileTagCreator.TagBuilderfallbackstatic StringNAMETagCreator.TagBuilderprimary
-
Constructor Summary
Constructors Constructor Description TagCreator(Map<String,ResourceDefinitionBuilder> resourceDefinitionBuilders)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbuildProcess(ProcessInstance instance, org.apache.sling.api.resource.ResourceResolver rr)voidimportTags(ActionManager manager)Perform the tag creation based on the successfully parsed values in parseTags(..).voidinit()voidparseTags(ActionManager manager)Parses the input Excel file and creates a list of TagDefinition objects to process.voidstoreReport(ProcessInstance instance, org.apache.sling.api.resource.ResourceResolver rr)-
Methods inherited from class com.adobe.acs.commons.mcp.ProcessDefinition
getName, setName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.adobe.acs.commons.mcp.form.FormProcessor
parseInputs
-
-
-
-
Field Detail
-
NAME
public static final String NAME
- See Also:
- Constant Field Values
-
excelFile
public transient InputStream excelFile
-
primary
public TagCreator.TagBuilder primary
-
fallback
public TagCreator.TagBuilder fallback
-
-
Constructor Detail
-
TagCreator
public TagCreator(Map<String,ResourceDefinitionBuilder> resourceDefinitionBuilders)
-
-
Method Detail
-
init
public void init() throws javax.jcr.RepositoryException- Specified by:
initin interfaceFormProcessor- Throws:
javax.jcr.RepositoryException
-
buildProcess
public void buildProcess(ProcessInstance instance, org.apache.sling.api.resource.ResourceResolver rr) throws org.apache.sling.api.resource.LoginException, javax.jcr.RepositoryException
- Specified by:
buildProcessin classProcessDefinition- Throws:
org.apache.sling.api.resource.LoginExceptionjavax.jcr.RepositoryException
-
parseTags
public void parseTags(ActionManager manager) throws Exception
Parses the input Excel file and creates a list of TagDefinition objects to process.- Parameters:
manager- the action manager- Throws:
IOExceptionException
-
importTags
public void importTags(ActionManager manager)
Perform the tag creation based on the successfully parsed values in parseTags(..).- Parameters:
manager- the action manager
-
storeReport
public void storeReport(ProcessInstance instance, org.apache.sling.api.resource.ResourceResolver rr) throws javax.jcr.RepositoryException, org.apache.sling.api.resource.PersistenceException
- Specified by:
storeReportin classProcessDefinition- Throws:
javax.jcr.RepositoryExceptionorg.apache.sling.api.resource.PersistenceException
-
-