|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IReservation
IReservation defines the the core API for a Shirako
reservation. Most of the methods described in the interface allow the
programmer to inspect the state of the reservation, access some of its core
objects, and wait for the occurrence of a particular event.
| Field Summary | |
|---|---|
static int |
CategoryAll
Unspecified reservation category. |
static int |
CategoryAuthority
Site authority-side reservations. |
static int |
CategoryBroker
Broker-side reservations. |
static int |
CategoryClient
Client-side reservations. |
static java.lang.String |
PropertyClass
Serialization property name: reservation class name. |
static java.lang.String |
PropertyID
Serialization property name: reservation identifier. |
| Method Summary | |
|---|---|
void |
awaitActive()
Waits for this reservation to become active. |
void |
awaitClosed()
Waits for the reservation to close. |
void |
awaitTicketed()
Waits for this reservation to be ticketed. |
void |
clearDirty()
Marks that the reservation has no uncommitted updates and state transitions. |
IActor |
getActor()
Returns the actor in control of the reservation. |
int |
getCategory()
Returns the reservation category. |
long |
getCloseTime()
Returns the time the reservation is scheduled to be closed. |
int |
getPendingState()
Returns the current pending reservation state |
java.lang.String |
getPendingStateName()
Returns the name of the current pending reservation state |
ReservationState |
getPreviousReservationState()
Returns the previous composite reservation state. |
ReservationID |
getReservationID()
Returns the reservation identifier. |
ReservationState |
getReservationState()
Returns the current composite reservation state. |
Slice |
getSlice()
Returns the slice the reservation belongs to. |
int |
getState()
Returns the current reservation state. |
java.lang.String |
getStateName()
Returns the name of the current reservation state. |
boolean |
hasUncommittedTransition()
Checks if the reservation has uncommitted state transitions. |
boolean |
isDirty()
Checks if the reservation has uncommitted updates. |
void |
registerListener(IStateChangeListener l)
Registers a listener. |
void |
setCloseTime(long closeTime)
Returns the time the reservation is scheduled to be closed. |
void |
setDirty()
Marks the reservation as containing uncommitted updates. |
void |
setSlice(Slice slice)
Sets the slice the reservation belongs to. |
void |
unregisterListener(IStateChangeListener l)
Unregisters the listener. |
| Methods inherited from interface orca.shirako.api.ISerialize |
|---|
reset, save, save |
| Methods inherited from interface orca.shirako.api.IRecover |
|---|
revisit |
| Methods inherited from interface orca.shirako.api.IReservationStatus |
|---|
isActive, isActiveTicketed, isClosed, isClosing, isExpired, isExpired, isExtended, isExtendingLease, isExtendingTicket, isFailed, isNascent, isNoPending, isPriming, isRedeeming, isTerminal, isTicketed, isTicketing, setExpired |
| Field Detail |
|---|
static final int CategoryAll
static final int CategoryClient
static final int CategoryBroker
static final int CategoryAuthority
static final java.lang.String PropertyID
static final java.lang.String PropertyClass
| Method Detail |
|---|
void awaitActive()
throws java.lang.InterruptedException
java.lang.InterruptedException
void awaitClosed()
throws java.lang.InterruptedException
java.lang.InterruptedException
void awaitTicketed()
throws java.lang.InterruptedException
java.lang.InterruptedExceptionvoid registerListener(IStateChangeListener l)
l - listener objectvoid unregisterListener(IStateChangeListener l)
l - listenerIActor getActor()
Slice getSlice()
void setSlice(Slice slice)
slice - slice the reservation belongs toint getCategory()
ReservationID getReservationID()
int getState()
java.lang.String getStateName()
int getPendingState()
java.lang.String getPendingStateName()
ReservationState getReservationState()
ReservationState getPreviousReservationState()
boolean isDirty()
boolean hasUncommittedTransition()
void clearDirty()
void setDirty()
long getCloseTime()
void setCloseTime(long closeTime)
the - time the reservation is scheduled to be closed
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||