org.norther.tammi.spray.template
Interface FlowFilter

All Superinterfaces:
AccessController, Filter, KeyFilter, SecureFilter, SecureKeyFilter
All Known Implementing Classes:
DefaultFlowFilter

public interface FlowFilter
extends SecureKeyFilter

FlowFilter provides control over a series of templates forming a step by step process of validated user input and output. Flows are named containers of steps, which define step templates, actions executed before and after processing the step and variables to maintain the data content of the step.

Flows are identified by a unique name. Steps are indexed within the enclosing flow starting from 1. Allowed routes between flows and steps are defined by BitSet of (n+1)*(n+1) matrix, where n is the number of steps in a flow. Index 0 is reserved for defining access to step into and out from the flow.

The syntax 'flow name'-'step-index' refers to separate steps. The flow name should not contain dashes to avoid confusion. Note that the index part may consists of more than one index separated by dots (.) to form a path to a specific step.

The syntax /'flow-name' refers to the root flow, */'flow-name' to the named step of the current flow and **/'flow-name' to any named steps in the current flow hierarchy.

Steps can be protected with an access controller. Permissions for a step are granted using its name as a resource.

Author:
Ilkka Priha

Method Summary
 boolean addFlowName(String name)
          Adds a named flow if absent.
 void addStepName(String name, int index, String step)
          Adds a new step to the named flow.
 void clearContextAttributes()
          Clears all global context attributes.
 void clearFlows()
          Clears all flows.
 void clearSteps(String name)
          Clears all steps from the named flow.
 boolean containsContextAttribute(String name)
          Checks the named global context attribute.
 boolean containsFlow(String name)
          Checks the named flow.
 boolean containsStep(String name, int index)
          Checks the indexed step.
 Map contextAttributeMap()
          Returns a map of global context attributes.
 Variable createVariable(String type)
          Creates a new variable MBean instance of the specified type.
 boolean executeActions(FlowStep step, StepFlowContext context, ServletRequest request, ServletResponse response, FilterChain chain)
          Executes actions of the specified step in the given flow context.
 Set flowNameSet()
          Returns a read-only set of flow names.
 Object getContextAttribute(String name)
          Gets the named global context attribute.
 StepFlowContext getCurrentContext(ServletRequest request, ServletResponse response, FilterChain chain)
          Gets the step flow context of the specified request.
 String getDefaultActionName()
          Gets the name of the default action applied to flows without a flow specific action.
 String[] getDefaultActionNames()
          Gets the names of the default actions applied to flows without flow specific templates.
 FlowStep getDefaultFlow()
          Gets the default flow.
 String getDefaultFlowName()
          Gets the name of the default flow.
 String getDefaultLabel()
          Gets the default flow label.
 String getDefaultProperty(String property)
          Gets the named default property.
 String getDefaultTemplatePath()
          Gets the path of the default template applied to flows without a flow or specific template.
 String[] getDefaultTemplatePaths()
          Gets the paths of the default templates applied to flows without flow specific templates.
 String getDefaultTransition(String state)
          Gets the default transition of the named state.
 String getDefaultVariableType()
          Gets the type of the default variable applied to flows without a flow specific variable.
 String[] getDefaultVariableTypes()
          Gets the types of the default variables applied to flows without flow specific variables.
 FlowStep getFlow(String name)
          Gets the named flow.
 String getFlowActionName(String name)
          Gets the name of the action applied to the named flow.
 String[] getFlowActionNames(String name)
          Gets the names of the actions applied to the named flow.
 String getFlowLabel(String name)
          Gets the label of the named flow.
 String getFlowName(String path)
          Gets the flow part of the flow step path.
 String[] getFlowNames()
          Gets the names of all flows.
 String getFlowProperty(String name, String property)
          Gets the named property of the named flow.
 String getFlowTemplatePath(String name)
          Gets the pathname of the template applied to the named flow.
 String[] getFlowTemplatePaths(String name)
          Gets the paths of the templates applied to the named flow.
 String getFlowTransition(String name, String state)
          Gets the transition of the named flow.
 String getFlowVariableType(String name)
          Gets the type of the variable applied to the named flow.
 String[] getFlowVariableTypes(String name)
          Gets the types of the variables applied to the named flow.
 int getPropertyIndex(String property)
          Gets the index of the named property within this filter.
 int getPropertyIndex(String property, boolean add)
          Gets and optionally adds the index of the named property within this filter.
 StepMatrix getRouteMatrix(String name)
          Gets the matrix defining enabled routes for flow steps.
 int getStateIndex(String state)
          Gets the index of the named state within this filter.
 int getStateIndex(String state, boolean add)
          Gets and optionally adds the index of the named state within this filter.
 int getStepCount(String name)
          Gets the number of steps in the named flow.
 int getStepIndex(String path, int index)
          Gets the index part of the flow step path.
 String getStepName(String name)
          Gets the name of the step of the named flow or step.
 String getStepName(String name, int index)
          Gets the name of the step of the named flow.
 String[] getStepNames(String name)
          Gets the step names of the named flow.
 String getStepPath(String name, int index)
          Gets the path to the indexed step of the named flow.
 ObjectName getTaskLoaderName()
          Gets the the task loader to be applied by contexts of this filter.
 ObjectName getVariableRegistryName()
          Gets the the variable registry to be applied by contexts of this filter.
 int indexOfStep(String name, String step)
          Return the index of the named step of the named flow.
 boolean isDefaultState(String state)
          Checks whether the named state is set by default.
 boolean isFlowState(String name, String state)
          Checks whether the named state is set for the named flow.
 boolean isRestrictedRoutes()
          Checks whether step routes of flows of this filter are restricted by a route matrix.
 List propertyNameList()
          Returns a read-only list of names of known properties within this filter.
 void removeContextAttribute(String name)
          Removes the named global context attribute.
 void removeFlow(String name)
          Removes the named flow.
 void removeStep(String name, int index)
          Removes the indexed step from the named flow.
 void setContextAttribute(String name, Object value)
          Sets the named global context attribute.
 void setDefaultActionName(String task)
          Sets the name of the default action applied to to flows without a flow specific action.
 void setDefaultActionNames(String[] tasks)
          Sets the names of the default actions applied to flows without flow specific templates.
 void setDefaultFlowName(String name)
          Sets the name of the default flow.
 void setDefaultLabel(String label)
          Sets the label of the named flow.
 void setDefaultProperties(String[] properties)
          Sets the named default properties as consecutive pairs of names and values.
 void setDefaultProperty(String property, String value)
          Sets the named default property.
 void setDefaultState(String state, boolean flag)
          Sets whether the named state is set by default.
 void setDefaultStates(String[] states)
          Sets the named states on by default.
 void setDefaultTemplatePath(String path)
          Sets the path of the default template applied to flows without a flow specific template.
 void setDefaultTemplatePaths(String[] paths)
          Sets the paths of the default templates applied to flows without flow specific templates.
 void setDefaultTransition(String state, String value)
          Sets the default transition of the named state.
 void setDefaultTransitions(String[] transitions)
          Sets the default transitions as consecutive pairs of states and values.
 void setDefaultVariableType(String type)
          Sets the type of the default variable applied to flows without a flow specific variable.
 void setDefaultVariableTypes(String[] types)
          Sets the types of the default variables applied to flows without flow specific variables.
 void setFlowActionName(String name, String task)
          Sets the name of the action applied to the named flow.
 void setFlowActionNames(String name, String[] tasks)
          Sets the names of the actions applied to the named flow.
 void setFlowLabel(String name, String label)
          Sets the label of the named flow.
 void setFlowName(String name)
          Sets or replaces a named flow if absent.
 void setFlowNames(String[] names)
          Sets the names of absent flows.
 void setFlowProperties(String name, String[] properties)
          Sets the named properties of the named flow as consecutive pairs of names and values.
 void setFlowProperty(String name, String property, String value)
          Sets the named property of the named flow.
 void setFlowState(String name, String state, boolean flag)
          Sets whether the named state is set for the named flow.
 void setFlowStates(String name, String[] states)
          Sets the named states of the named flow.
 void setFlowTemplatePath(String name, String path)
          Sets the path of the template applied to the named flow.
 void setFlowTemplatePaths(String name, String[] paths)
          Sets the paths of the templates applied to the named flow.
 void setFlowTransition(String name, String state, String flow)
          Sets the transition of the named flow.
 void setFlowTransitions(String name, String[] transitions)
          Sets the transitions of the named flow as consecutive pairs of states and values.
 void setFlowVariableType(String name, String type)
          Sets the type of the variable applied to the named flow.
 void setFlowVariableTypes(String name, String[] types)
          Sets the types of the variables applied to the named flow.
 void setRestrictedRoutes(boolean flag)
          Sets whether step routes of flows of this filter are restricted by a route matrix.
 void setRouteArray(String name, String array)
          Sets the matrix defining enabled routes for flow steps as a string.
 void setRouteMatrix(String name, StepMatrix matrix)
          Sets the matrix defining enabled routes for flow steps.
 void setRoutesEnabled(String name, boolean flag)
          Sets the matrix defining enabled routes for flow steps as a boolean.
 void setStepName(String name, int index, String step)
          Sets the name of the step of the named flow.
 void setStepName(String name, String step)
          Sets the name of the step applied of the named flow or step.
 void setStepNames(String name, String[] steps)
          Sets the step names of the named flow.
 void setTaskLoaderName(ObjectName loader)
          Sets the task loader to be applied by contexts of this filter.
 void setVariableRegistryName(ObjectName registry)
          Sets the variable registry to be applied by contexts this filter.
 List stateNameList()
          Returns a read-only list of names of known states within this filter.
 
Methods inherited from interface org.norther.tammi.spray.filter.SecureFilter
checkPermission, checkPermission, checkPermission
 
Methods inherited from interface org.norther.tammi.core.security.AccessController
addAllowedPermission, addDeniedPermission, allowedPermissions, allowedRoleSet, checkPermission, checkPermission, checkPermission, clearAllowedPermissions, clearDeniedPermissions, deniedPermissions, deniedRoleSet, getPermissibleRoles, getPermissibleRoles, getPermissibleRoles, isProtected, removeAllowedPermissions, removeDeniedPermissions, setAllowedPermissions, setDeniedPermissions
 
Methods inherited from interface javax.servlet.Filter
destroy, doFilter, init
 
Methods inherited from interface org.norther.tammi.spray.filter.KeyFilter
getKey, getKeyValue, getKeyValues, isLinkedKey, setKey, setLinkedKey
 
Methods inherited from interface javax.servlet.Filter
destroy, doFilter, init
 

Method Detail

getFlowName

String getFlowName(String path)
Gets the flow part of the flow step path.

Parameters:
path - the flow step path.
Returns:
the flow name without a step index.

getStepIndex

int getStepIndex(String path,
                 int index)
Gets the index part of the flow step path.

Parameters:
path - the flow step path.
index - the default index.
Returns:
the defined index or the default one if not included.
Throws:
NumberFormatException - for an invalid indexed path.

getStepPath

String getStepPath(String name,
                   int index)
Gets the path to the indexed step of the named flow.

Parameters:
name - the flow step name.
index - the step index.
Returns:
the path to the specified step.

getDefaultFlowName

String getDefaultFlowName()
Gets the name of the default flow.

Returns:
the name of the flow or null.

setDefaultFlowName

void setDefaultFlowName(String name)
Sets the name of the default flow.

Parameters:
name - the name of the flow.

getDefaultFlow

FlowStep getDefaultFlow()
Gets the default flow.

Returns:
the read-only default flow.

getDefaultLabel

String getDefaultLabel()
Gets the default flow label.

Returns:
the label of the flow or null.

setDefaultLabel

void setDefaultLabel(String label)
Sets the label of the named flow.

Parameters:
label - the label of the flow.

getDefaultTemplatePath

String getDefaultTemplatePath()
Gets the path of the default template applied to flows without a flow or specific template.

Note that if several templates are defined, the first one is returned.

Returns:
the path of the template or null.

setDefaultTemplatePath

void setDefaultTemplatePath(String path)
Sets the path of the default template applied to flows without a flow specific template.

Note that all previously defined templates are replaced with the new one.

Parameters:
path - the path of the template.

getDefaultTemplatePaths

String[] getDefaultTemplatePaths()
Gets the paths of the default templates applied to flows without flow specific templates.

Returns:
the paths of the templates or null.

setDefaultTemplatePaths

void setDefaultTemplatePaths(String[] paths)
Sets the paths of the default templates applied to flows without flow specific templates. New templates are added after existing ones.

Parameters:
paths - the paths of the templates.

getDefaultVariableType

String getDefaultVariableType()
Gets the type of the default variable applied to flows without a flow specific variable.

Note that if several variables are defined, the first one is returned.

Returns:
the type of the variable or null.

setDefaultVariableType

void setDefaultVariableType(String type)
Sets the type of the default variable applied to flows without a flow specific variable.

Note that all previously defined variables are replaced with the new one.

Parameters:
type - the type of the variable.

getDefaultVariableTypes

String[] getDefaultVariableTypes()
Gets the types of the default variables applied to flows without flow specific variables.

Returns:
the types of the variables or null.

setDefaultVariableTypes

void setDefaultVariableTypes(String[] types)
Sets the types of the default variables applied to flows without flow specific variables. New variables are added after existing ones.

Parameters:
types - the types of the variables.

getDefaultActionName

String getDefaultActionName()
Gets the name of the default action applied to flows without a flow specific action.

Note that if several actions are defined, the first one is returned.

Returns:
the name of the action or null.

setDefaultActionName

void setDefaultActionName(String task)
Sets the name of the default action applied to to flows without a flow specific action.

Note that all previously defined actions are replaced with the new one.

Parameters:
task - the name of the action.

getDefaultActionNames

String[] getDefaultActionNames()
Gets the names of the default actions applied to flows without flow specific templates.

Returns:
the names of the actions or null.

setDefaultActionNames

void setDefaultActionNames(String[] tasks)
Sets the names of the default actions applied to flows without flow specific templates. New actions are added after existing ones.

Parameters:
tasks - the names of the actions.

isDefaultState

boolean isDefaultState(String state)
Checks whether the named state is set by default.

Parameters:
state - the name of the state.
Returns:
true if the state is on, false otherwise.

setDefaultState

void setDefaultState(String state,
                     boolean flag)
Sets whether the named state is set by default.

Parameters:
state - the name of the state.
flag - true if the state is on, false otherwise.

setDefaultStates

void setDefaultStates(String[] states)
Sets the named states on by default.

Parameters:
states - the names of the states.

getStateIndex

int getStateIndex(String state)
Gets the index of the named state within this filter.

Parameters:
state - the name of the state.
Returns:
the index of the state or -1.

getStateIndex

int getStateIndex(String state,
                  boolean add)
Gets and optionally adds the index of the named state within this filter.

Parameters:
state - the name of the state.
add - true to add a missing state.
Returns:
the index of the state or -1.

stateNameList

List stateNameList()
Returns a read-only list of names of known states within this filter.

Returns:
a list of state names in the state index order.

getDefaultProperty

String getDefaultProperty(String property)
Gets the named default property.

Parameters:
property - the name of the property.
Returns:
the value of the property or null.

setDefaultProperty

void setDefaultProperty(String property,
                        String value)
Sets the named default property.

Parameters:
property - the name of the property.
value - the value of the property.

setDefaultProperties

void setDefaultProperties(String[] properties)
Sets the named default properties as consecutive pairs of names and values.

Parameters:
properties - the names and values of the properties.

getPropertyIndex

int getPropertyIndex(String property)
Gets the index of the named property within this filter.

Parameters:
property - the name of the property.
Returns:
the index of the property or -1.

getPropertyIndex

int getPropertyIndex(String property,
                     boolean add)
Gets and optionally adds the index of the named property within this filter.

Parameters:
property - the property of the property.
add - true to add a missing property.
Returns:
the index of the state or -1.

propertyNameList

List propertyNameList()
Returns a read-only list of names of known properties within this filter.

Returns:
a list of property names in the property index order.

getDefaultTransition

String getDefaultTransition(String state)
Gets the default transition of the named state.

Parameters:
state - the name of the state.
Returns:
the value of the transition or null.

setDefaultTransition

void setDefaultTransition(String state,
                          String value)
Sets the default transition of the named state.

Parameters:
state - the name of the state.
value - the value of the transition or null.

setDefaultTransitions

void setDefaultTransitions(String[] transitions)
Sets the default transitions as consecutive pairs of states and values.

Parameters:
transitions - the states and values of the transitions.

isRestrictedRoutes

boolean isRestrictedRoutes()
Checks whether step routes of flows of this filter are restricted by a route matrix.

Returns:
true if restricted, false otherwise.

setRestrictedRoutes

void setRestrictedRoutes(boolean flag)
Sets whether step routes of flows of this filter are restricted by a route matrix.

Parameters:
flag - true if restricted, false otherwise.

getFlow

FlowStep getFlow(String name)
Gets the named flow.

Parameters:
name - the name of the flow.
Returns:
a clone of the named flow or null.

containsFlow

boolean containsFlow(String name)
Checks the named flow.

Parameters:
name - the name of the flow.
Returns:
true if the flow exists, false otherwise.

removeFlow

void removeFlow(String name)
Removes the named flow.

Parameters:
name - the name of the flow.

clearFlows

void clearFlows()
Clears all flows.


setFlowName

void setFlowName(String name)
Sets or replaces a named flow if absent.

Parameters:
name - the name of the flow.

addFlowName

boolean addFlowName(String name)
Adds a named flow if absent.

Parameters:
name - the name of the flow.
Returns:
true id added, false otherwise.

getFlowNames

String[] getFlowNames()
Gets the names of all flows.

Returns:
the names of the flows.

setFlowNames

void setFlowNames(String[] names)
Sets the names of absent flows.

Parameters:
names - the names of the flows.

flowNameSet

Set flowNameSet()
Returns a read-only set of flow names.

Returns:
a set of flow names.

containsStep

boolean containsStep(String name,
                     int index)
Checks the indexed step.

Parameters:
name - the name of the flow.
index - the index of the step.
Returns:
true if the step exists, false otherwise.

indexOfStep

int indexOfStep(String name,
                String step)
Return the index of the named step of the named flow.

Parameters:
name - the name of the flow.
step - the name of the step.
Returns:
the index of the step or -1 if not found.

removeStep

void removeStep(String name,
                int index)
Removes the indexed step from the named flow.

Parameters:
name - the name of the flow.
index - the index of the step.
Throws:
IndexOutOfBoundsException - if wrong index.

clearSteps

void clearSteps(String name)
Clears all steps from the named flow.

Parameters:
name - the name of the flow.

getStepName

String getStepName(String name)
Gets the name of the step of the named flow or step.

Note that if several steps are defined, the first one is returned.

Parameters:
name - the name of the flow.
Returns:
the name of the step or null.
Throws:
NumberFormatException - for an invalid indexed name.

setStepName

void setStepName(String name,
                 String step)
Sets the name of the step applied of the named flow or step.

Note that all previously defined steps are replaced with the new one.

Parameters:
name - the name of the flow.
step - the name of the step.
Throws:
NullPointerException - if the flow is not found.
NumberFormatException - for an invalid indexed name.
IllegalArgumentException - for an invalid step name.

getStepName

String getStepName(String name,
                   int index)
Gets the name of the step of the named flow.

Parameters:
name - the name of the flow.
index - the index of the step.
Returns:
the name of the step or null.
Throws:
IndexOutOfBoundsException - if wrong index.

setStepName

void setStepName(String name,
                 int index,
                 String step)
Sets the name of the step of the named flow.

Parameters:
name - the name of the flow.
index - the index of the step.
step - the name of the step.
Throws:
IndexOutOfBoundsException - if wrong index.
IllegalArgumentException - for an invalid step name.
NullPointerException - for a null name or if the flow is not found.

addStepName

void addStepName(String name,
                 int index,
                 String step)
Adds a new step to the named flow.

Parameters:
name - the name of the flow.
index - the index of the step.
step - the name of the step.
Throws:
IndexOutOfBoundsException - if wrong index.
IllegalArgumentException - for an invalid step name.
NullPointerException - for a null name or if the flow is not found.

getStepNames

String[] getStepNames(String name)
Gets the step names of the named flow.

Parameters:
name - the name of the flow.
Returns:
an array of step names or null.

setStepNames

void setStepNames(String name,
                  String[] steps)
Sets the step names of the named flow.

Parameters:
name - the name of the flow.
steps - an array of step names.
Throws:
IllegalArgumentException - for an invalid step name.
NullPointerException - for null names or if the flow is not found.

getStepCount

int getStepCount(String name)
Gets the number of steps in the named flow.

Parameters:
name - the name of the flow.
Returns:
the number of steps.

getRouteMatrix

StepMatrix getRouteMatrix(String name)
Gets the matrix defining enabled routes for flow steps. The size of the matrix is (n+1)*(n+1) where n is the step count.

Parameters:
name - the name of the flow.
Returns:
the step matrix or null.

setRouteMatrix

void setRouteMatrix(String name,
                    StepMatrix matrix)
Sets the matrix defining enabled routes for flow steps. The size of the matrix is (n+1)*(n+1) where n is the step count.

Parameters:
name - the name of the flow.
matrix - the step matrix.
Throws:
NullPointerException - if the flow is not found.

setRouteArray

void setRouteArray(String name,
                   String array)
Sets the matrix defining enabled routes for flow steps as a string. Chars 0 and '0' are considered as disabled routes, all other chars as enabled routes.

Parameters:
name - the name of the flow.
array - a string of size (n+1)*(n+1) where n is the step count.
Throws:
NullPointerException - if the flow is not found.

setRoutesEnabled

void setRoutesEnabled(String name,
                      boolean flag)
Sets the matrix defining enabled routes for flow steps as a boolean. True enables all routes and false disables them.

Parameters:
name - the name of the flow.
flag - true to enable routes, false to disable.
Throws:
NullPointerException - if the flow is not found.

getFlowLabel

String getFlowLabel(String name)
Gets the label of the named flow.

Parameters:
name - the name of the flow.
Returns:
the label of the flow or null.

setFlowLabel

void setFlowLabel(String name,
                  String label)
Sets the label of the named flow.

Parameters:
name - the name of the flow.
label - the label of the flow.
Throws:
NullPointerException - if the flow is not found.

getFlowTemplatePath

String getFlowTemplatePath(String name)
Gets the pathname of the template applied to the named flow.

Note that if several templates are defined, the first one is returned.

Parameters:
name - the name of the flow.
Returns:
the pathname of the template or null.

setFlowTemplatePath

void setFlowTemplatePath(String name,
                         String path)
Sets the path of the template applied to the named flow.

Note that all previously defined templates are replaced with the new one.

Parameters:
name - the name of the flow.
path - the path of the template.
Throws:
NullPointerException - if the flow is not found.

getFlowTemplatePaths

String[] getFlowTemplatePaths(String name)
Gets the paths of the templates applied to the named flow.

Parameters:
name - the name of the flow.
Returns:
the paths of the templates or null.

setFlowTemplatePaths

void setFlowTemplatePaths(String name,
                          String[] paths)
Sets the paths of the templates applied to the named flow.

Parameters:
name - the name of the flow.
paths - the paths of the templates.
Throws:
NullPointerException - if the flow is not found.

getFlowVariableType

String getFlowVariableType(String name)
Gets the type of the variable applied to the named flow.

Note that if several variables are defined, the first one is returned.

Parameters:
name - the name of the flow.
Returns:
the type of the variable or null.

setFlowVariableType

void setFlowVariableType(String name,
                         String type)
Sets the type of the variable applied to the named flow.

Note that all previously defined variables are replaced with the new one.

Parameters:
name - the name of the flow.
type - the type of the variable.
Throws:
NullPointerException - if the flow is not found.

getFlowVariableTypes

String[] getFlowVariableTypes(String name)
Gets the types of the variables applied to the named flow.

Parameters:
name - the name of the flow.
Returns:
the types of the variables or null.

setFlowVariableTypes

void setFlowVariableTypes(String name,
                          String[] types)
Sets the types of the variables applied to the named flow.

Parameters:
name - the name of the flow.
types - the types of the variables.
Throws:
NullPointerException - if the flow is not found.

getFlowActionName

String getFlowActionName(String name)
Gets the name of the action applied to the named flow.

Note that if several actions are defined, the first one is returned.

Parameters:
name - the name of the flow.
Returns:
the name of the action or null.

setFlowActionName

void setFlowActionName(String name,
                       String task)
Sets the name of the action applied to the named flow.

Note that all previously defined actions are replaced with the new one.

Parameters:
name - the name of the flow.
task - the name of the action.
Throws:
NullPointerException - if the flow is not found.

getFlowActionNames

String[] getFlowActionNames(String name)
Gets the names of the actions applied to the named flow.

Parameters:
name - the name of the flow.
Returns:
the names of the actions or null.

setFlowActionNames

void setFlowActionNames(String name,
                        String[] tasks)
Sets the names of the actions applied to the named flow.

Parameters:
name - the name of the flow.
tasks - the names of the actions.
Throws:
NullPointerException - if the flow is not found.

isFlowState

boolean isFlowState(String name,
                    String state)
Checks whether the named state is set for the named flow.

Parameters:
name - the name of the flow.
state - the name of the state.
Returns:
true if the state is on, false otherwise.

setFlowState

void setFlowState(String name,
                  String state,
                  boolean flag)
Sets whether the named state is set for the named flow.

Parameters:
name - the name of the flow.
state - the name of the state.
flag - true if the state is on, false otherwise.
Throws:
NullPointerException - if the flow is not f