com.ptc.windchill.uwgm.proesrv.cache
Class RequestCacheAdapter

java.lang.Object
  extended bycom.ptc.windchill.uwgm.proesrv.cache.RequestCacheAdapter
Direct Known Subclasses:
ContainerRequestCacheAdapter, CreateBaselineCacheAdapter, FindIterationsRequestCacheAdapter, FolderRequestCacheAdapter, IterationRequestCacheAdapter, RenameInstructionCacheAdapter, WorkspaceRequestCacheAdapter

public abstract class RequestCacheAdapter
extends Object

super class for RequestCacheAdapter implementations subclasses must overwrite validateRequestData(RequestContext requestContext, UwgmRequest uwgmRequest)


Field Summary
private  boolean valid
           
 
Constructor Summary
RequestCacheAdapter()
           
 
Method Summary
protected  void checkCacheData()
          throws IllegalStateException if the RequestCacheAdapter data have NOT been validated
 boolean isValid()
          helper method to check whether the RequestCacheAdapter data have been validated already
protected  void setValid()
          sets valid flag to TRUE.
 void validate(RequestContext requestContext, com.ptc.windchill.uwgm.soap.uwgm.UwgmRequest uwgmRequest)
          validates request data should be called for RequestCache implementations in validate()
protected abstract  void validateRequestData(RequestContext requestContext, com.ptc.windchill.uwgm.soap.uwgm.UwgmRequest uwgmRequest)
          abstract validateRequestData method to be overwritten by RequestCacheAdapter implementations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

valid

private boolean valid
Constructor Detail

RequestCacheAdapter

public RequestCacheAdapter()
Method Detail

isValid

public boolean isValid()
helper method to check whether the RequestCacheAdapter data have been validated already


setValid

protected void setValid()
sets valid flag to TRUE. To be used from validateXXX helper methods


validate

public final void validate(RequestContext requestContext,
                           com.ptc.windchill.uwgm.soap.uwgm.UwgmRequest uwgmRequest)
                    throws RequestValidationException,
                           UwgmErrorException
validates request data should be called for RequestCache implementations in validate()

Parameters:
requestContext - RequestContext
uwgmRequest - UwgmRequest
Throws:
RequestValidationException
UwgmErrorException

validateRequestData

protected abstract void validateRequestData(RequestContext requestContext,
                                            com.ptc.windchill.uwgm.soap.uwgm.UwgmRequest uwgmRequest)
                                     throws RequestValidationException,
                                            UwgmErrorException
abstract validateRequestData method to be overwritten by RequestCacheAdapter implementations

Parameters:
requestContext - RequestContext
uwgmRequest - UwgmRequest
Throws:
RequestValidationException
UwgmErrorException

checkCacheData

protected void checkCacheData()
throws IllegalStateException if the RequestCacheAdapter data have NOT been validated

should be called in all RequestCacheAdapter implementation getXXX() methods