ist.palcom.contingency.manager.events
Class ContingencyEvent

java.lang.Object
  extended by ist.palcom.collections.Link
      extended by ist.palcom.palcomthreads.Event
          extended by ist.palcom.contingency.manager.events.ContingencyEvent
All Implemented Interfaces:
java.lang.Cloneable
Direct Known Subclasses:
DeviceNAEvent, ServiceNAEvent

public abstract class ContingencyEvent
extends Event
implements java.lang.Cloneable


Nested Class Summary
static class ContingencyEvent.ContingencyState
          Possible states the contingency event can be in.
 
Field Summary
protected  PRDData decl
          The declaration of this resource used by the assembly manager.
static java.lang.String EVENT_TYPE
          Type of the event.
protected  PRDData info
          The description of this resource used by the resource manager.
protected  URN urn
          A URN of the resource that is subject of this contingency event.
 
Constructor Summary
ContingencyEvent(PalcomThread requester, URN urn, PRDData decl, boolean shouldKeep, ContingencyEvent.ContingencyState state)
           
 
Method Summary
 boolean eventShouldBeKept()
           
 PRDData getDecl()
           
 java.lang.String getEventType()
           
 PRDData getInfo()
           
 PalcomThread getRequester()
           
 ContingencyEvent.ContingencyState getState()
           
 URN getURN()
           
abstract  void rebind(URN newURN)
          Rebind the event to another resource.
 void setDecl(PRDData decl)
           
 void setInfo(PRDData info)
           
 void setShouldBeKept(boolean keep)
           
 void setState(ContingencyEvent.ContingencyState state)
           
 
Methods inherited from class ist.palcom.collections.Link
getNext, getPrev
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EVENT_TYPE

public static final java.lang.String EVENT_TYPE
Type of the event.

See Also:
Constant Field Values

urn

protected URN urn
A URN of the resource that is subject of this contingency event.


decl

protected PRDData decl
The declaration of this resource used by the assembly manager.


info

protected PRDData info
The description of this resource used by the resource manager.

Constructor Detail

ContingencyEvent

public ContingencyEvent(PalcomThread requester,
                        URN urn,
                        PRDData decl,
                        boolean shouldKeep,
                        ContingencyEvent.ContingencyState state)
Method Detail

getRequester

public PalcomThread getRequester()

getEventType

public java.lang.String getEventType()

eventShouldBeKept

public boolean eventShouldBeKept()

setShouldBeKept

public void setShouldBeKept(boolean keep)

getURN

public URN getURN()

getInfo

public PRDData getInfo()

setInfo

public void setInfo(PRDData info)

getDecl

public PRDData getDecl()

setDecl

public void setDecl(PRDData decl)

getState

public ContingencyEvent.ContingencyState getState()

setState

public void setState(ContingencyEvent.ContingencyState state)

rebind

public abstract void rebind(URN newURN)
Rebind the event to another resource. (Used when reconnecting the monitored assembly from the former resource to an alternate one specified by the new urn.

Parameters:
newURN - - A URN of the new resource this contingency will be monitored on.