Class PlantUMLSVGReader
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.reading.AbstractReader
org.ametys.plugins.workflow.readers.AbstractPlantUMLSVGReader
org.ametys.plugins.workflow.readers.PlantUMLSVGReader
- All Implemented Interfaces:
Poolable,Recyclable,Component,LogEnabled,Serviceable,Reader,SitemapModelComponent,SitemapOutputComponent
Serialize PlantUML state diagram
-
Field Summary
Fields inherited from class org.ametys.plugins.workflow.readers.AbstractPlantUMLSVGReader
__MAIN_STEP_NODE_COLOR, _i18nHelper, _i18nUtils, _jsonUtils, _workflowRightHelper, _workflowSessionHelper, _workflowStepDAO, _workflowTransitionDAOFields inherited from class org.apache.cocoon.reading.AbstractReader
objectModel, out, parameters, resolver, source -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String_createState(com.opensymphony.workflow.loader.WorkflowDescriptor workflow, com.opensymphony.workflow.loader.StepDescriptor step) Create new state in diagramprotected String_createTransition(com.opensymphony.workflow.loader.WorkflowDescriptor workflow, com.opensymphony.workflow.loader.StepDescriptor step, com.opensymphony.workflow.loader.ActionDescriptor transition) Create a new transition between two states in diagramprotected String_getPlantUMLGraphContent(Request request, com.opensymphony.workflow.loader.WorkflowDescriptor workflowDescriptor) Get the plantUML diagram bodyprotected StringGet plantUML style for current diagramprotected StringGet the diagram typeprotected String_getTransitionArrow(String incomingState, String outgoingState, String label, String iconPath, String jsFunction, String linkTooltip, boolean isDashed) Get the transition arrow between 2 statesMethods inherited from class org.ametys.plugins.workflow.readers.AbstractPlantUMLSVGReader
_getActionLabel, _getActionTooltip, _getJsFunction, _getPlantUMLContent, _getStepNodeLabel, _getStepTooltip, _getStringWithEscapedSpace, _setContextInRequestAttributes, _setPlantUMLProperties, generate, serviceMethods inherited from class org.apache.cocoon.reading.AbstractReader
getLastModified, getMimeType, recycle, setOutputStream, setup, shouldSetContentLengthMethods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Constructor Details
-
PlantUMLSVGReader
public PlantUMLSVGReader()
-
-
Method Details
-
_getPlantUMLType
Description copied from class:AbstractPlantUMLSVGReaderGet the diagram type- Specified by:
_getPlantUMLTypein classAbstractPlantUMLSVGReader- Returns:
- the diagram type
-
_getPlantUMLStyle
Description copied from class:AbstractPlantUMLSVGReaderGet plantUML style for current diagram- Specified by:
_getPlantUMLStylein classAbstractPlantUMLSVGReader- Returns:
- the style as string
-
_getPlantUMLGraphContent
protected String _getPlantUMLGraphContent(Request request, com.opensymphony.workflow.loader.WorkflowDescriptor workflowDescriptor) Description copied from class:AbstractPlantUMLSVGReaderGet the plantUML diagram body- Specified by:
_getPlantUMLGraphContentin classAbstractPlantUMLSVGReader- Parameters:
request- the requestworkflowDescriptor- descriptor of current workflow- Returns:
- the diagram body as string
-
_getTransitionArrow
protected String _getTransitionArrow(String incomingState, String outgoingState, String label, String iconPath, String jsFunction, String linkTooltip, boolean isDashed) Get the transition arrow between 2 states- Parameters:
incomingState- state's id before transitionoutgoingState- state's id after transitionlabel- the transition's labeliconPath- the transition's icon pathjsFunction- the js function for sending current transition as selectionlinkTooltip- the transition link's tooltipisDashed- true if the arrow must be dashed- Returns:
- the transition arrow content
-
_createState
protected String _createState(com.opensymphony.workflow.loader.WorkflowDescriptor workflow, com.opensymphony.workflow.loader.StepDescriptor step) Create new state in diagram- Parameters:
workflow- unique id of current workflowstep- a step of the workflow- Returns:
- a string defining a plantUML state
-
_createTransition
protected String _createTransition(com.opensymphony.workflow.loader.WorkflowDescriptor workflow, com.opensymphony.workflow.loader.StepDescriptor step, com.opensymphony.workflow.loader.ActionDescriptor transition) Create a new transition between two states in diagram- Parameters:
workflow- unique id of current workflowstep- the initial step of this transitiontransition- the current action- Returns:
- a string defining a plantUML transition
-