|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.xml.ws.rx.rm.runtime.sequence.AbstractSequence
public abstract class AbstractSequence
Provides abstract sequence implementation common to both - inbound and outbound sequence
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.sun.xml.ws.rx.rm.runtime.sequence.Sequence |
|---|
Sequence.AckRange, Sequence.IncompleteSequenceBehavior, Sequence.State |
| Field Summary | |
|---|---|
protected SequenceData |
data
|
| Fields inherited from interface com.sun.xml.ws.rx.rm.runtime.sequence.Sequence |
|---|
MAX_MESSAGE_ID, MIN_MESSAGE_ID, NO_EXPIRY, UNSPECIFIED_MESSAGE_ID |
| Method Summary | |
|---|---|
void |
clearAckRequestedFlag()
This method should be called to clear the AckRequested flag, which indicates that any pending requests for acknowledgement of all message identifiers registered with this sequence were satisfied. |
void |
close()
Closes the sequence. |
boolean |
equals(Object obj)
|
List<Sequence.AckRange> |
getAcknowledgedMessageNumbers()
Provides a collection of ranges of message numbers acknowledged with the sequence |
String |
getBoundSecurityTokenReferenceId()
Provides information on a security session to which this sequence is bound to. |
SequenceData |
getData()
|
DeliveryQueue |
getDeliveryQueue()
Updates a delivery queue for this sequence with any unacknowledged messages that should be sent and returns the delivery queue instance. |
String |
getId()
Returns unique identifier of the sequence |
long |
getLastActivityTime()
Provides information on the last activity time of this sequence. |
long |
getLastMessageNumber()
Provides information on the message number of the last message registered on this sequence |
Sequence.State |
getState()
Provides information on the state of the message sequence |
int |
hashCode()
|
boolean |
hasUnacknowledgedMessages()
The method may be called to determine whether the sequence has some unacknowledged messages or not |
boolean |
isAcknowledged(long messageNumber)
Is this message number acknowledged with the sequence? |
boolean |
isAckRequested()
Provides information on the actual AckRequested flag status |
boolean |
isClosed()
Provides information on the sequence closed status. |
boolean |
isExpired()
Provides information on the sequence expiration status. |
boolean |
isFailedOver(long messageNumber)
Determines whether a given message number is registered as received, unacknowledged and failed over. |
boolean |
isStandaloneAcknowledgementRequestSchedulable(long delayPeriod)
Determines whether a standalone acnowledgement request can be scheduled or not based on the #hasPendingAcknowledgements() value, last acknowledgement request time
(see Sequence.updateLastAcknowledgementRequestTime()) and delayPeriod
parameter. |
void |
preDestroy()
The method is called during the sequence termination to allow sequence object to release its allocated resources |
ApplicationMessage |
retrieveMessage(String correlationId)
Retrieves a message stored within the sequence under the provided correlationId
if avalable. |
void |
setAckRequestedFlag()
This method should be called to set the AckRequested flag, which indicates a pending request for acknowledgement of all message identifiers registered with this sequence. |
void |
updateLastAcknowledgementRequestTime()
Updates information on when was the last acknowledgement request for this sequence sent to current time. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.sun.xml.ws.rx.rm.runtime.sequence.Sequence |
|---|
acknowledgeMessageNumber, acknowledgeMessageNumbers, registerMessage |
| Field Detail |
|---|
protected final SequenceData data
| Method Detail |
|---|
public String getId()
Sequence
getId in interface Sequencepublic String getBoundSecurityTokenReferenceId()
Sequence
getBoundSecurityTokenReferenceId in interface Sequencepublic long getLastMessageNumber()
Sequence
getLastMessageNumber in interface Sequencepublic List<Sequence.AckRange> getAcknowledgedMessageNumbers()
Sequence
getAcknowledgedMessageNumbers in interface Sequencepublic boolean isAcknowledged(long messageNumber)
Sequence
isAcknowledged in interface SequencemessageNumber - in a sequence
public boolean hasUnacknowledgedMessages()
Sequence
hasUnacknowledgedMessages in interface Sequencetrue if the sequence has any unacknowledged message identifiers, false otherwisepublic Sequence.State getState()
Sequence
getState in interface Sequencepublic void setAckRequestedFlag()
Sequence
setAckRequestedFlag in interface Sequencepublic void clearAckRequestedFlag()
Sequence
clearAckRequestedFlag in interface Sequencepublic boolean isAckRequested()
Sequence
isAckRequested in interface Sequencetrue if the AckRequested flag is set, false otherwisepublic boolean isFailedOver(long messageNumber)
Sequence
isFailedOver in interface SequencemessageNumber - message number to be tested
true if the message number is registered as received, unacknowledged
and failed over, false otherwisepublic void updateLastAcknowledgementRequestTime()
Sequence
updateLastAcknowledgementRequestTime in interface Sequencepublic long getLastActivityTime()
SequenceSequence.acknowledgeMessageNumber(long)Sequence.acknowledgeMessageNumbers(java.util.List)Sequence.clearAckRequestedFlag()Sequence.close()Sequence.registerMessage(ApplicationMessage, boolean)Sequence.retrieveMessage(java.lang.String)Sequence.setAckRequestedFlag()Sequence.updateLastAcknowledgementRequestTime()
getLastActivityTime in interface Sequencepublic boolean isStandaloneAcknowledgementRequestSchedulable(long delayPeriod)
Sequence#hasPendingAcknowledgements() value, last acknowledgement request time
(see Sequence.updateLastAcknowledgementRequestTime()) and delayPeriod
parameter.
Returns true if the sequence has any pending acknowledgements is set and last
acknowledgement request time is older than delay period substracted from the current time.
Returns false otherwise.
isStandaloneAcknowledgementRequestSchedulable in interface SequencedelayPeriod - delay period that should pass since the last acknowledgement request
before an autonomous acnowledgement request is sent.
true or false depending on whetherpublic void close()
Sequence
Once this method is called, any subsequent calls to the #getNextMessageId() method will
result in a IllegalStateException being raised. It is however still possible to accept message identifier
acknowledgements, as well as retrieve any other information on the sequence.
close in interface Sequencepublic boolean isClosed()
Sequence
isClosed in interface Sequencetrue if the sequence has been closed, false otherwisepublic boolean isExpired()
Sequence
isExpired in interface Sequencetrue if the sequence has already expired, false otherwisepublic void preDestroy()
Sequence
preDestroy in interface Sequencepublic SequenceData getData()
public ApplicationMessage retrieveMessage(String correlationId)
SequencecorrelationId
if avalable. May return null if no stored message under given correlationId
is available.
Availability of the message depends on the message identifier acknowledgement.
Message, if stored (see Sequence.registerMessage(com.sun.xml.ws.rx.rm.runtime.ApplicationMessage, boolean)
remains available for retrieval until it is acknowledged. Once the message identifier
associated with the stored message has been acknowledged, availability of the
stored message is no longer guaranteed and stored message becomes eligible for
garbage collection (if stored in memory) or removal.
Note however, that message MAY still be available even after it has been acknowledged.
Thus it is NOT safe to use this method as a test of a message acknowledgement.
retrieveMessage in interface SequencecorrelationId - correlation identifier of the stored ApplicationMessage
null otherwise.public DeliveryQueue getDeliveryQueue()
Sequence
getDeliveryQueue in interface Sequencepublic boolean equals(Object obj)
equals in class Objectpublic int hashCode()
hashCode in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||