org.enhydra.shark
Class WfExecutionObjectImpl

java.lang.Object
  extended by org.enhydra.shark.WfExecutionObjectImpl
All Implemented Interfaces:
PersistenceInterface, WfExecutionObjectInternal
Direct Known Subclasses:
WfActivityImpl, WfProcessImpl

public abstract class WfExecutionObjectImpl
extends java.lang.Object
implements WfExecutionObjectInternal

WfExecutionObjectImpl - Workflow Execution Object implementation The WfProcessImpl and WfActivityImpl classes are extended from this class.

Author:
Sasa Bojanic, Vladimir Puskas

Field Summary
protected  java.lang.String description
           
protected  java.lang.String key
           
protected  WfStateEventAuditInternal lastStateEventAudit
           
protected  long lastStateTime
           
protected  long limitTime
           
protected  java.lang.String name
           
protected  short priority
           
protected  java.lang.String state
           
 
Constructor Summary
WfExecutionObjectImpl()
           
 
Method Summary
abstract  void abort(WMSessionHandle shandle)
           
 void calculateLimit(WMSessionHandle shandle)
           
protected abstract  void checkReadOnly()
           
 java.lang.String description(WMSessionHandle shandle)
           
protected  java.util.Map duplicateContext(java.util.Map m)
           
abstract  long getCreationTime(WMSessionHandle shandle)
           
 long getLimitTime(WMSessionHandle shandle)
           
abstract  long getStartTime(WMSessionHandle shandle)
           
protected abstract  org.enhydra.shark.xpdl.XMLCollectionElement getXPDLObject(WMSessionHandle shandle)
           
 java.lang.String key(WMSessionHandle shandle)
           
 UtcT last_state_time(WMSessionHandle shandle)
           
 java.lang.String name(WMSessionHandle shandle)
           
 short priority(WMSessionHandle shandle)
           
 java.util.Map process_context(WMSessionHandle shandle)
           
abstract  void resume(WMSessionHandle shandle)
           
 void set_description(WMSessionHandle shandle, java.lang.String new_value)
           
 void set_name(WMSessionHandle shandle, java.lang.String new_value)
           
 void set_priority(WMSessionHandle shandle, short new_value)
           
abstract  void set_process_context(WMSessionHandle shandle, java.util.Map new_value)
           
 void setLimitTime(WMSessionHandle shandle, long newLimit)
           
 java.lang.String state(WMSessionHandle shandle)
           
abstract  void suspend(WMSessionHandle shandle)
           
abstract  void terminate(WMSessionHandle shandle)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.enhydra.shark.api.internal.working.WfExecutionObjectInternal
getContext
 
Methods inherited from interface org.enhydra.shark.api.internal.working.PersistenceInterface
delete, persist
 

Field Detail

state

protected java.lang.String state

name

protected java.lang.String name

key

protected java.lang.String key

description

protected java.lang.String description

priority

protected short priority

lastStateTime

protected long lastStateTime

limitTime

protected long limitTime

lastStateEventAudit

protected WfStateEventAuditInternal lastStateEventAudit
Constructor Detail

WfExecutionObjectImpl

public WfExecutionObjectImpl()
Method Detail

state

public java.lang.String state(WMSessionHandle shandle)
                       throws java.lang.Exception
Specified by:
state in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

name

public java.lang.String name(WMSessionHandle shandle)
                      throws java.lang.Exception
Specified by:
name in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

set_name

public void set_name(WMSessionHandle shandle,
                     java.lang.String new_value)
              throws java.lang.Exception
Specified by:
set_name in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

key

public java.lang.String key(WMSessionHandle shandle)
                     throws java.lang.Exception
Specified by:
key in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

description

public java.lang.String description(WMSessionHandle shandle)
                             throws java.lang.Exception
Specified by:
description in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

set_description

public void set_description(WMSessionHandle shandle,
                            java.lang.String new_value)
                     throws java.lang.Exception
Specified by:
set_description in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

process_context

public java.util.Map process_context(WMSessionHandle shandle)
                              throws java.lang.Exception
Specified by:
process_context in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

duplicateContext

protected java.util.Map duplicateContext(java.util.Map m)
                                  throws java.lang.Exception
Throws:
java.lang.Exception

set_process_context

public abstract void set_process_context(WMSessionHandle shandle,
                                         java.util.Map new_value)
                                  throws java.lang.Exception,
                                         InvalidData,
                                         UpdateNotAllowed
Specified by:
set_process_context in interface WfExecutionObjectInternal
Throws:
java.lang.Exception
InvalidData
UpdateNotAllowed

priority

public short priority(WMSessionHandle shandle)
               throws java.lang.Exception
Specified by:
priority in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

set_priority

public void set_priority(WMSessionHandle shandle,
                         short new_value)
                  throws java.lang.Exception
Specified by:
set_priority in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

calculateLimit

public void calculateLimit(WMSessionHandle shandle)
                    throws java.lang.Exception
Specified by:
calculateLimit in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

getCreationTime

public abstract long getCreationTime(WMSessionHandle shandle)
                              throws java.lang.Exception
Specified by:
getCreationTime in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

getStartTime

public abstract long getStartTime(WMSessionHandle shandle)
                           throws java.lang.Exception
Specified by:
getStartTime in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

last_state_time

public UtcT last_state_time(WMSessionHandle shandle)
                     throws java.lang.Exception
Specified by:
last_state_time in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

setLimitTime

public void setLimitTime(WMSessionHandle shandle,
                         long newLimit)
                  throws java.lang.Exception
Specified by:
setLimitTime in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

getLimitTime

public long getLimitTime(WMSessionHandle shandle)
                  throws java.lang.Exception
Specified by:
getLimitTime in interface WfExecutionObjectInternal
Throws:
java.lang.Exception

resume

public abstract void resume(WMSessionHandle shandle)
                     throws java.lang.Exception,
                            CannotResume,
                            NotSuspended
Specified by:
resume in interface WfExecutionObjectInternal
Throws:
java.lang.Exception
CannotResume
NotSuspended

suspend

public abstract void suspend(WMSessionHandle shandle)
                      throws java.lang.Exception,
                             CannotSuspend,
                             NotRunning,
                             AlreadySuspended
Specified by:
suspend in interface WfExecutionObjectInternal
Throws:
java.lang.Exception
CannotSuspend
NotRunning
AlreadySuspended

terminate

public abstract void terminate(WMSessionHandle shandle)
                        throws java.lang.Exception,
                               CannotStop,
                               NotRunning
Specified by:
terminate in interface WfExecutionObjectInternal
Throws:
java.lang.Exception
CannotStop
NotRunning

abort

public abstract void abort(WMSessionHandle shandle)
                    throws java.lang.Exception,
                           CannotStop,
                           NotRunning
Specified by:
abort in interface WfExecutionObjectInternal
Throws:
java.lang.Exception
CannotStop
NotRunning

getXPDLObject

protected abstract org.enhydra.shark.xpdl.XMLCollectionElement getXPDLObject(WMSessionHandle shandle)
                                                                      throws java.lang.Exception
Throws:
java.lang.Exception

checkReadOnly

protected abstract void checkReadOnly()
                               throws java.lang.Exception
Throws:
java.lang.Exception