wt.sandbox
Class SandboxServiceUndoCheckoutEvent

java.lang.Object
  extended bywt.events.KeyedEvent
      extended bywt.sandbox.SandboxServiceMultiEvent
          extended bywt.sandbox.SandboxServiceUndoCheckoutEvent
All Implemented Interfaces:
Cloneable, Serializable

public class SandboxServiceUndoCheckoutEvent
extends SandboxServiceMultiEvent
implements Serializable

Encapusulates SandboxService event/occurence data which occur upon sandbox undo-check-out.

The target object of the event is a WTSet of the working copies when the event type is PRE_SB_UNDO_CHECKOUT_EVENT, whereas it is a WTCollection of the resulting original copies when the event type is POST_SB_UNDO_CHECKOUT_EVENT. Except where attempting to treat many service events generically, it is recommended that the more specific methods provided on this class be used in preference to getEventTarget(), however.

Supported API: false

Extendable: false

See Also:
Serialized Form

Field Summary
private static String CLASSNAME
           
static String POST_SB_UNDO_CHECKOUT_EVENT
          Event type indicating state immediately prior to end of undo sandbox check out transaction block

Supported API: false
static String PRE_SB_UNDO_CHECKOUT_EVENT
          Event type indicating state immediately prior to undo sandbox check out but within transaction block thereof

Supported API: false
private static String RESOURCE
           
private  boolean sharingOriginalToSandbox
           
private  WTValuedMap workingToOriginalRefMap
           
 
Fields inherited from class wt.sandbox.SandboxServiceMultiEvent
 
Fields inherited from class wt.events.KeyedEvent
 
Constructor Summary
private SandboxServiceUndoCheckoutEvent(String eventType, WTValuedMap workingToOriginalRefMap, boolean sharingOriginalToSandbox)
           
 
Method Summary
(package private) static void firePostUndoCheckOutEvent(ManagerService managerService, WTValuedMap workingToOriginalRefMap, boolean sharingOriginalToSandbox)
           
(package private) static void firePreUndoCheckOutEvent(ManagerService managerService, WTValuedMap workingToOriginalRefMap, boolean sharingOriginalToSandbox)
           
private static void fireUndoCheckOutEvent(ManagerService managerService, WTValuedMap workingToOriginalRefMap, boolean sharingOriginalToSandbox, boolean preEvent)
           
static String generateEventKey(String eventType)
          Generate an appropriate event key for this class given an event type.
 WTCollection getOriginalCopies()
          Gets collection of original copies.
 WTSet getWorkingCopies()
          Gets set of sandbox working copies.
 WTValuedMap getWorkingToOriginalCopyMap()
          Gets map from sandbox working copies to originals.
 boolean isSharingOriginalToSandbox()
          Returns true if undo checkout operation is sharing / will share original copies back sandbox container

Supported API: false
 
Methods inherited from class wt.sandbox.SandboxServiceMultiEvent
getEventTarget, toMultiObjectEvent, toSingleObjectEvents
 
Methods inherited from class wt.events.KeyedEvent
generateEventKey, generateEventKey, getConceptualClassname, getEventKey, getEventType, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

PRE_SB_UNDO_CHECKOUT_EVENT

public static final String PRE_SB_UNDO_CHECKOUT_EVENT
Event type indicating state immediately prior to undo sandbox check out but within transaction block thereof

Supported API: false

See Also:
Constant Field Values

POST_SB_UNDO_CHECKOUT_EVENT

public static final String POST_SB_UNDO_CHECKOUT_EVENT
Event type indicating state immediately prior to end of undo sandbox check out transaction block

Supported API: false

See Also:
Constant Field Values

workingToOriginalRefMap

private WTValuedMap workingToOriginalRefMap

sharingOriginalToSandbox

private boolean sharingOriginalToSandbox
Constructor Detail

SandboxServiceUndoCheckoutEvent

private SandboxServiceUndoCheckoutEvent(String eventType,
                                        WTValuedMap workingToOriginalRefMap,
                                        boolean sharingOriginalToSandbox)
Method Detail

getWorkingToOriginalCopyMap

public WTValuedMap getWorkingToOriginalCopyMap()
Gets map from sandbox working copies to originals.

Supported API: false

Returns:
WTValuedMap

getOriginalCopies

public WTCollection getOriginalCopies()
Gets collection of original copies.

Supported API: false

Returns:
WTCollection

getWorkingCopies

public WTSet getWorkingCopies()
Gets set of sandbox working copies.

Supported API: false

Returns:
WTSet

isSharingOriginalToSandbox

public boolean isSharingOriginalToSandbox()
Returns true if undo checkout operation is sharing / will share original copies back sandbox container

Supported API: false

Returns:
boolean

generateEventKey

public static String generateEventKey(String eventType)
Generate an appropriate event key for this class given an event type.

Supported API: false

Parameters:
eventType - the event type
Returns:
String

firePreUndoCheckOutEvent

static void firePreUndoCheckOutEvent(ManagerService managerService,
                                     WTValuedMap workingToOriginalRefMap,
                                     boolean sharingOriginalToSandbox)
                              throws WTException
Throws:
WTException

firePostUndoCheckOutEvent

static void firePostUndoCheckOutEvent(ManagerService managerService,
                                      WTValuedMap workingToOriginalRefMap,
                                      boolean sharingOriginalToSandbox)
                               throws WTException
Throws:
WTException

fireUndoCheckOutEvent

private static void fireUndoCheckOutEvent(ManagerService managerService,
                                          WTValuedMap workingToOriginalRefMap,
                                          boolean sharingOriginalToSandbox,
                                          boolean preEvent)
                                   throws WTException
Throws:
WTException