org.obe.xpdl.model.activity
Class Activity

java.lang.Object
  extended byorg.obe.util.AbstractBean
      extended byorg.obe.xpdl.model.misc.AbstractWFElement
          extended byorg.obe.xpdl.model.activity.Activity
All Implemented Interfaces:
java.beans.beancontext.BeanContextChild, CalendarRef, java.io.Serializable

public final class Activity
extends AbstractWFElement
implements CalendarRef

Models an XPDL activity definition.

See Also:
Serialized Form

Field Summary
static java.lang.String AFFERENT_TRANSITION
           
static java.lang.String ASSIGNMENT_STRATEGY
           
static java.lang.String BLOCK_ACTIVITY
           
static java.lang.String BOUNDS
           
static java.lang.String CALENDAR
           
static java.lang.String COMPLETION_STRATEGY
           
static java.lang.String DEADLINE
           
static java.lang.String DOCUMENTATION
           
static java.lang.String EFFERENT_TRANSITION
           
static java.lang.String FINISH_MODE
           
static java.lang.String ICON
           
static java.lang.String IMPLEMENTATION
           
static java.lang.String LIMIT
           
static java.lang.String PERFORMER
           
static java.lang.String PRIORITY
           
static java.lang.String ROUTE
           
static java.lang.String SIMULATION_INFORMATION
           
static java.lang.String START_MODE
           
static java.lang.String TOOL_MODE
           
static java.lang.String TRANSITION_RESTRICTION
           
 
Constructor Summary
Activity()
           
Activity(java.lang.String id, java.lang.String name, WorkflowProcess workflowProcess)
          Construct a new Activity with the given ID and name.
 
Method Summary
 void accept(PackageVisitor visitor)
           
 void add(Deadline deadline)
           
 void add(TransitionRestriction restriction)
           
 java.util.Map getAfferentTransitions()
           
 AssignmentStrategyDef getAssignmentStrategy()
          Returns the work item assignment strategy for this activity.
 BlockActivity getBlockActivity()
           
 java.awt.Rectangle getBounds()
           
 java.lang.String getCalendar()
          Returns the business calendar name.
 java.lang.String getCompletionStrategy()
          Returns the completion strategy for this activity.
 Deadline[] getDeadline()
          Gets the activity deadlines.
 Deadline getDeadline(int i)
          Gets an activity deadline.
 java.net.URL getDocumentation()
          Get the URL for the documentation for the activity.
 java.util.Map getEfferentTransitions()
           
 AutomationMode getFinishMode()
          Get the finish mode for the activity.
 java.net.URL getIcon()
          Get the URL for the icon for the activity.
 Implementation getImplementation()
          Get the implementation object for the activity.
 Duration getLimit()
          Get the time limit allowed for the execution of the activity.
 java.lang.String getPerformer()
          Get the ID of the activity performer.
 java.lang.String getPriority()
          Get the priority of the activity.
 Route getRoute()
          Get the Route object for the activity.
 SimulationInformation getSimulationInformation()
          Get the SimulationInformation for the activity.
 AutomationMode getStartMode()
          Get the start mode for the activity.
 ToolMode getToolMode()
          Returns the tool invocation mode.
 TransitionRestriction[] getTransitionRestriction()
          Get a List of transition restrictions for transitions which connect to this activity.
 TransitionRestriction getTransitionRestriction(int i)
           
 WorkflowProcess getWorkflowProcess()
          Get the WorkflowProcess in which this activity is declared.
 boolean isExitActivity()
           
 boolean isStartActivity()
           
 void remove(Deadline deadline)
           
 void remove(TransitionRestriction restriction)
           
 void setAssignmentStrategy(AssignmentStrategyDef strategy)
          Sets the activity assignment strategy.
 void setBlockActivity(BlockActivity blockActivity)
           
 void setBounds(java.awt.Rectangle bounds)
           
 void setCalendar(java.lang.String calendar)
          Sets the business calendar name.
 void setCompletionStrategy(java.lang.String strategy)
          Sets the completion strategy for this activity.
 void setDeadline(Deadline[] deadlines)
          Sets the activity deadlines.
 void setDeadline(int i, Deadline deadline)
          Sets an activity deadline.
 void setDocumentation(java.net.URL documentation)
          Get the URL for the documentation for the activity.
 void setFinishMode(AutomationMode finishMode)
          Set the finish mode for the activity.
 void setIcon(java.net.URL icon)
          Set the URL for the icon for the activity.
 void setImplementation(Implementation implementation)
          Set the implementation object for the activity.
 void setLimit(Duration limit)
          Set the time limit allowed for the execution of the activity.
 void setPerformer(java.lang.String performer)
          Set the ID of the activity performer.
 void setPriority(java.lang.String priority)
          Set the priority of the activity.
 void setRoute(Route route)
          Set the Route object for the activity.
 void setSimulationInformation(SimulationInformation simulationInformation)
          Set the SimulationInformation for the activity.
 void setStartMode(AutomationMode startMode)
          Set the start mode for the activity.
 void setToolMode(ToolMode toolMode)
          Sets the tool invocation mode.
 void setTransitionRestriction(int i, TransitionRestriction restriction)
           
 void setTransitionRestriction(TransitionRestriction[] restrictions)
           
 java.lang.String toString()
           
 
Methods inherited from class org.obe.xpdl.model.misc.AbstractWFElement
createExtendedAttributes, equals, getDescription, getExtendedAttributes, getId, getName, hashCode, setDescription, setExtendedAttributes, setId, setName
 
Methods inherited from class org.obe.util.AbstractBean
add, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, clear, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, get, get, getBeanContext, getListModel, hasChangeListeners, hasVetoListeners, remove, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener, set, set, setBeanContext
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

BOUNDS

public static final java.lang.String BOUNDS
See Also:
Constant Field Values

LIMIT

public static final java.lang.String LIMIT
See Also:
Constant Field Values

IMPLEMENTATION

public static final java.lang.String IMPLEMENTATION
See Also:
Constant Field Values

ROUTE

public static final java.lang.String ROUTE
See Also:
Constant Field Values

BLOCK_ACTIVITY

public static final java.lang.String BLOCK_ACTIVITY
See Also:
Constant Field Values

PERFORMER

public static final java.lang.String PERFORMER
See Also:
Constant Field Values

START_MODE

public static final java.lang.String START_MODE
See Also:
Constant Field Values

FINISH_MODE

public static final java.lang.String FINISH_MODE
See Also:
Constant Field Values

TOOL_MODE

public static final java.lang.String TOOL_MODE
See Also:
Constant Field Values

ASSIGNMENT_STRATEGY

public static final java.lang.String ASSIGNMENT_STRATEGY
See Also:
Constant Field Values

COMPLETION_STRATEGY

public static final java.lang.String COMPLETION_STRATEGY
See Also:
Constant Field Values

CALENDAR

public static final java.lang.String CALENDAR
See Also:
Constant Field Values

PRIORITY

public static final java.lang.String PRIORITY
See Also:
Constant Field Values

DEADLINE

public static final java.lang.String DEADLINE
See Also:
Constant Field Values

SIMULATION_INFORMATION

public static final java.lang.String SIMULATION_INFORMATION
See Also:
Constant Field Values

DOCUMENTATION

public static final java.lang.String DOCUMENTATION
See Also:
Constant Field Values

ICON

public static final java.lang.String ICON
See Also:
Constant Field Values

TRANSITION_RESTRICTION

public static final java.lang.String TRANSITION_RESTRICTION
See Also:
Constant Field Values

AFFERENT_TRANSITION

public static final java.lang.String AFFERENT_TRANSITION
See Also:
Constant Field Values

EFFERENT_TRANSITION

public static final java.lang.String EFFERENT_TRANSITION
See Also:
Constant Field Values
Constructor Detail

Activity

public Activity()

Activity

public Activity(java.lang.String id,
                java.lang.String name,
                WorkflowProcess workflowProcess)
Construct a new Activity with the given ID and name.

Parameters:
id - The Activity ID
name - The Activity name
Method Detail

accept

public void accept(PackageVisitor visitor)

getBounds

public java.awt.Rectangle getBounds()

setBounds

public void setBounds(java.awt.Rectangle bounds)

getWorkflowProcess

public WorkflowProcess getWorkflowProcess()
Get the WorkflowProcess in which this activity is declared.

Returns:
The WorkflowProcess

getLimit

public Duration getLimit()
Get the time limit allowed for the execution of the activity.

Returns:
The time limit

setLimit

public void setLimit(Duration limit)
Set the time limit allowed for the execution of the activity.

Parameters:
limit - The time limit

getImplementation

public Implementation getImplementation()
Get the implementation object for the activity. If this method returns null then the getRoute() must return a valid Route object.

Returns:
The Implementation object

setImplementation

public void setImplementation(Implementation implementation)
Set the implementation object for the activity.

Parameters:
implementation - The new Implementation object

getRoute

public Route getRoute()
Get the Route object for the activity. If the getImplementation() method returns null then this method must return a valid Route object.

Returns:
The Route object

setRoute

public void setRoute(Route route)
Set the Route object for the activity.

Parameters:
route - The new Route object

getBlockActivity

public BlockActivity getBlockActivity()

setBlockActivity

public void setBlockActivity(BlockActivity blockActivity)

getPerformer

public java.lang.String getPerformer()
Get the ID of the activity performer.

Returns:
The ID of the performer

setPerformer

public void setPerformer(java.lang.String performer)
Set the ID of the activity performer.

Parameters:
performer - The ID of the performer

getStartMode

public AutomationMode getStartMode()
Get the start mode for the activity. The start mode is used to determine if the activity should start automatically or manually. The default value is AutomationMode.AUTOMATIC.

Returns:
The start mode

setStartMode

public void setStartMode(AutomationMode startMode)
Set the start mode for the activity. The start mode is used to determine if the activity should start automatically or manually.

Parameters:
startMode - The new start mode

getFinishMode

public AutomationMode getFinishMode()
Get the finish mode for the activity. The finish mode is used to determine if the activity should complete automatically or manually. The default value is AutomationMode.AUTOMATIC.

Returns:
The finish mode

setFinishMode

public void setFinishMode(AutomationMode finishMode)
Set the finish mode for the activity. The finish mode is used to determine if the activity should complete automatically or manually.

Parameters:
finishMode - The new finish mode

getToolMode

public ToolMode getToolMode()
Returns the tool invocation mode.

Returns:
The tool invocation mode.

setToolMode

public void setToolMode(ToolMode toolMode)
Sets the tool invocation mode.

Parameters:
toolMode - The tool invocation mode.

getAssignmentStrategy

public AssignmentStrategyDef getAssignmentStrategy()
Returns the work item assignment strategy for this activity.

Returns:
Assignment strategy definition, which must have a matching implementation registered in the AssignmentStrategyRepository.

setAssignmentStrategy

public void setAssignmentStrategy(AssignmentStrategyDef strategy)
Sets the activity assignment strategy.

Parameters:
strategy - Assignment strategy definition, which must have a matching implementation registered in the AssignmentStrategyRepository.

getCompletionStrategy

public java.lang.String getCompletionStrategy()
Returns the completion strategy for this activity.

Returns:
Activity completion strategy tag name, which must have a matching implementation in the ???Repository.

setCompletionStrategy

public void setCompletionStrategy(java.lang.String strategy)
Sets the completion strategy for this activity.

Parameters:
strategy - Activity completion strategy tag name, which must have a matching implementation in the ???Repository.

getPriority

public java.lang.String getPriority()
Get the priority of the activity.

Returns:
The priority

setPriority

public void setPriority(java.lang.String priority)
Set the priority of the activity.

Parameters:
priority - The new priority

getCalendar

public java.lang.String getCalendar()
Returns the business calendar name.

Specified by:
getCalendar in interface CalendarRef
Returns:
The business calendar tag name, which must have a matching entry in the OBE Calendar Factory.

setCalendar

public void setCalendar(java.lang.String calendar)
Sets the business calendar name.

Specified by:
setCalendar in interface CalendarRef
Parameters:
calendar - The business calendar tag name, which must have a matching entry in the OBE Calendar Factory.

add

public void add(Deadline deadline)
         throws java.beans.PropertyVetoException
Throws:
java.beans.PropertyVetoException

remove

public void remove(Deadline deadline)
            throws java.beans.PropertyVetoException
Throws:
java.beans.PropertyVetoException

getDeadline

public Deadline[] getDeadline()
Gets the activity deadlines.

Returns:
The deadline

getDeadline

public Deadline getDeadline(int i)
Gets an activity deadline.

Parameters:
i - The deadline index.
Returns:
The deadline

setDeadline

public void setDeadline(Deadline[] deadlines)
                 throws java.beans.PropertyVetoException
Sets the activity deadlines.

Parameters:
deadlines -
Throws:
java.beans.PropertyVetoException

setDeadline

public void setDeadline(int i,
                        Deadline deadline)
                 throws java.beans.PropertyVetoException
Sets an activity deadline.

Parameters:
i - The deadline index.
deadline -
Throws:
java.beans.PropertyVetoException

getSimulationInformation

public SimulationInformation getSimulationInformation()
Get the SimulationInformation for the activity. This information can be used to make estimations for the execution time of an activity which can then be used to test a workflow definition timing.

Returns:
The SimulationInformation

setSimulationInformation

public void setSimulationInformation(SimulationInformation simulationInformation)
Set the SimulationInformation for the activity.

Parameters:
simulationInformation - The new SimulationInformation

getDocumentation

public java.net.URL getDocumentation()
Get the URL for the documentation for the activity. This URL should point to documentation which can be used by developers, administrators and other users to understand what the activity does.

Returns:
The URL for the activity documentation

setDocumentation

public void setDocumentation(java.net.URL documentation)
Get the URL for the documentation for the activity.

Parameters:
documentation - The new URL for the activity documentation

getIcon

public java.net.URL getIcon()
Get the URL for the icon for the activity. The icon is used to represent the activity in a graphical representatioin of the workflow process.

Returns:
The URL for the activity's icon

setIcon

public void setIcon(java.net.URL icon)
Set the URL for the icon for the activity.

Parameters:
icon - The new URL for the activity's icon

add

public void add(TransitionRestriction restriction)
         throws java.beans.PropertyVetoException
Throws:
java.beans.PropertyVetoException

remove

public void remove(TransitionRestriction restriction)
            throws java.beans.PropertyVetoException
Throws:
java.beans.PropertyVetoException

getTransitionRestriction

public TransitionRestriction[] getTransitionRestriction()
Get a List of transition restrictions for transitions which connect to this activity.

Returns:
a List of transition restrictions

getTransitionRestriction

public TransitionRestriction getTransitionRestriction(int i)

setTransitionRestriction

public void setTransitionRestriction(TransitionRestriction[] restrictions)
                              throws java.beans.PropertyVetoException
Throws:
java.beans.PropertyVetoException

setTransitionRestriction

public void setTransitionRestriction(int i,
                                     TransitionRestriction restriction)
                              throws java.beans.PropertyVetoException
Throws:
java.beans.PropertyVetoException

getAfferentTransitions

public java.util.Map getAfferentTransitions()

getEfferentTransitions

public java.util.Map getEfferentTransitions()

toString

public java.lang.String toString()
Overrides:
toString in class AbstractWFElement

isExitActivity

public boolean isExitActivity()

isStartActivity

public boolean isStartActivity()


SourceForge.net Logo OBE-1.0 Copyright (C) 2002-2006 Adrian Price. All Rights Reserved.