com.ptc.windchill.uwgm.proesrv.action
Class UwgmAction

java.lang.Object
  extended bycom.ptc.windchill.uwgm.proesrv.action.UwgmAction
Direct Known Subclasses:
AbstractRenameAction, ModelCheckAction, UwgmWorkspaceAction, WorkspaceCreateAction, WorkspaceDeleteAction

public abstract class UwgmAction
extends Object

super abstract class for all Uwgm actions


Field Summary
private  RequestContext context
          Action (request) context
private  boolean executeSucceded
          internal flag to protect data for unexecuted actions
private static Log log
          logging
private  List warnings
          collection of Warnings (wt.conflict.InfoElement, with wt.conflict.MesgCategory = WARNING
 
Constructor Summary
protected UwgmAction(RequestContext context)
          constructor to use from implementations
 
Method Summary
protected  void addWarning(InfoElement warning)
           
protected  void checkExecutionSuccess()
          throws action execution, throws IllegalArgumentException if action failed or has not been executed at all
 void execute()
           
protected abstract  void executeAction()
          executes action (should be overwritten by implementation action subclasses)
protected  RequestContext getContext()
           
 InfoElement[] getWarnings()
          returns List of warning InfoMessages
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

warnings

private final List warnings
collection of Warnings (wt.conflict.InfoElement, with wt.conflict.MesgCategory = WARNING


context

private final RequestContext context
Action (request) context


executeSucceded

private boolean executeSucceded
internal flag to protect data for unexecuted actions


log

private static Log log
logging

Constructor Detail

UwgmAction

protected UwgmAction(RequestContext context)
constructor to use from implementations

Parameters:
context - RequestContext
Method Detail

executeAction

protected abstract void executeAction()
                               throws UwgmConflictException,
                                      UwgmErrorException
executes action (should be overwritten by implementation action subclasses)

Throws:
UwgmConflictException
UwgmErrorException

execute

public final void execute()
                   throws UwgmConflictException,
                          UwgmErrorException
Throws:
UwgmConflictException
UwgmErrorException

getWarnings

public final InfoElement[] getWarnings()
returns List of warning InfoMessages

Returns:
List

checkExecutionSuccess

protected void checkExecutionSuccess()
throws action execution, throws IllegalArgumentException if action failed or has not been executed at all


addWarning

protected void addWarning(InfoElement warning)

getContext

protected final RequestContext getContext()