public interface ForkingContext extends AttributeStore
SipSession
derived from the another. A ForkingContext
links all of such SipSession
siblings.
A forking context will have one to many valid SipSessions associated with it.SipSession.getForkingContext()
Modifier and Type | Method and Description |
---|---|
SipServletRequest |
createRequest(String method)
Creates a new request with a new derived session on this
ForkingContext . |
Set<SipSession> |
getSipSessions()
An immutable
Set of SipSession objects which are derived sessions on the same forking context. |
boolean |
isValid()
A forking context will be valid as long as atleast one
SipSession is valid. |
void |
terminateDialogs(AutomaticProcessingListener listener,
SipSession... exclude)
Terminates dialogs of all
SipSession objects in this forking context. |
clearAttributes, getAttribute, getAttributeNameSet, removeAttribute, setAttribute
Set<SipSession> getSipSessions()
Set
of SipSession
objects which are derived sessions on the same forking context.
Set
should maintain the order in which the dialogs are established in the container.Set
of the SipSession
objects.IllegalStateException
- if this method is invoked on an invalid forking context.void terminateDialogs(AutomaticProcessingListener listener, SipSession... exclude)
SipSession
objects in this forking context.
Equivalent to invoking Session.terminateDialog
on all SipSession
objects
obtained from getSipSessions
method. The container will also terminate all derived sessions
that belong to the same ForkingContext, created after executing this method. This method does not
terminate dialogs that belong to a proxy application.listener
- Instance of AutomaticProcessingListener
.exclude
- List of SipSession
objects that will be excluded from terminating.IllegalStateException
- if this method is invoked on an invalid forking context or the dialogs belong
to a proxy application.AutomaticProcessingListener
boolean isValid()
SipSession
is valid.SipSessions
objects in this forking context is valid.SipServletRequest createRequest(String method)
ForkingContext
. This method may only be used to create the
requests that establish a new forked dialog. At the time of writing
this, NOTIFY method as specified by RFC 6665 is the only method that
establish a new forked dialog.method
- the SIP method of the new requestIllegalArgumentException
- if method
does not establish a new forked
dialog.IllegalStateException
- If the forking context represents proxy sessions.Copyright © 1996-2015, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.