Package org.apache.cxf.ws.rm
Class SourceSequence
java.lang.Object
org.apache.cxf.ws.rm.AbstractSequence
org.apache.cxf.ws.rm.SourceSequence
-
Field Summary
Fields inherited from class org.apache.cxf.ws.rm.AbstractSequence
acknowledgement, id -
Constructor Summary
ConstructorsConstructorDescriptionSourceSequence(Identifier i, Date e, Identifier oi, long cmn, boolean lm, ProtocolVariation pv) SourceSequence(Identifier i, Date e, Identifier oi, ProtocolVariation pv) -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns true if a last message had been sent for this sequence and if all messages for this sequence have been acknowledged.longReturns the source associated with this source sequence.org.apache.cxf.ws.addressing.EndpointReferenceTypebooleanbooleanneedAcknowledge(long num) Returns true if any messages other than the number supplied are waiting for acknowledgment.longnextMessageNumber(Identifier inSeqId, long inMsgNumber, boolean last) Returns the next message number and increases the message number.booleanofferedBy(Identifier sid) Returns true if this sequence was constructed from an offer for an inbound sequence includes in the CreateSequenceRequest in response to which the sequence with the specified identifier was created.voidUsed by the RM source to cache received acknowledgements for this sequence.voidsetExpires(Expires ex) voidsetTarget(org.apache.cxf.ws.addressing.EndpointReferenceType to) The target for the sequence is the first non-anonymous address that a message is sent to as part of this sequence.Methods inherited from class org.apache.cxf.ws.rm.AbstractSequence
equals, getIdentifier, getProtocol, hashCode, identifierEquals, isAcknowledged, toString
-
Constructor Details
-
SourceSequence
-
SourceSequence
-
SourceSequence
public SourceSequence(Identifier i, Date e, Identifier oi, long cmn, boolean lm, ProtocolVariation pv)
-
-
Method Details
-
getCurrentMessageNr
public long getCurrentMessageNr()- Returns:
- the message number assigned to the most recent outgoing application message.
-
isLastMessage
public boolean isLastMessage()- Returns:
- true if the last message had been sent for this sequence.
-
getOfferingSequenceIdentifier
- Returns:
- the identifier of the sequence that was created on behalf of the CreateSequence request that included this sequence as an offer
-
getEndpointIdentifier
- Returns:
- the identifier of the rm source
-
getExpires
- Returns:
- the expiry data of this sequence
-
offeredBy
Returns true if this sequence was constructed from an offer for an inbound sequence includes in the CreateSequenceRequest in response to which the sequence with the specified identifier was created.- Parameters:
sid- the sequence identifier- Returns:
- true if the sequence was constructed from an offer.
-
needAcknowledge
public boolean needAcknowledge(long num) Returns true if any messages other than the number supplied are waiting for acknowledgment.- Parameters:
num- message number to check- Returns:
- true if all messages have been acknowledged.
-
allAcknowledged
public boolean allAcknowledged()Returns true if a last message had been sent for this sequence and if all messages for this sequence have been acknowledged.- Returns:
- true if all messages have been acknowledged.
-
setAcknowledged
Used by the RM source to cache received acknowledgements for this sequence.- Parameters:
ack- an acknowledgement for this sequence- Throws:
RMException
-
getSource
Returns the source associated with this source sequence.- Returns:
- the source.
-
setExpires
-
nextMessageNumber
Returns the next message number and increases the message number. The parameters, if not null, indicate that this message is being sent as a response to the message with the specified message number in the sequence specified by the by the identifier, and are used to decide if this message should be the last in this sequence.- Returns:
- the next message number.
-
setTarget
public void setTarget(org.apache.cxf.ws.addressing.EndpointReferenceType to) The target for the sequence is the first non-anonymous address that a message is sent to as part of this sequence. It is subsequently used for as the target of out-of-band protocol messages related to that sequence that originate from the sequnce source (i.e. TerminateSequence and LastMessage, but not AckRequested or SequenceAcknowledgement as these are orignate from the sequence destination).- Parameters:
to-
-
getTarget
public org.apache.cxf.ws.addressing.EndpointReferenceType getTarget()
-