public interface ProxyBranch
| Modifier and Type | Method and Description |
|---|---|
void |
cancel()
Cancels this branch and all the child branches if recursion is enabled and sends a CANCEL to the proxied INVITEs.
|
void |
cancel(String[] protocol,
int[] reasonCode,
String[] reasonText)
This overloaded method of cancel() provides a way to specify the reason
for cancelling this Proxy by including the appropriate Reason headers [RFC 3326].
|
boolean |
getAddToPath()
Returns true if subsequent invocations of startProxy() will add a Path header to the proxied request, false otherwise.
|
SipURI |
getPathURI()
Returns a SipURI that the application can use to add parameters to the Path header.
|
Proxy |
getProxy() |
int |
getProxyBranchTimeout()
Returns the current value of the search timeout associated with this ProxyBranch object.
|
boolean |
getRecordRoute()
Returns true if subsequent invocations of proxyTo(URI) will add a Record-Route header to the proxied request, false otherwise.
|
SipURI |
getRecordRouteURI()
Returns a SipURI that the application can use to add parameters to the Record-Route header.
|
boolean |
getRecurse()
Returns true if this proxy branch object is set to recurse, or false otherwise.
|
List<ProxyBranch> |
getRecursedProxyBranches()
Receipt of a 3xx class redirect response on a branch can result in recursed branches if the proxy or the branch has recursion enabled.
|
SipServletRequest |
getRequest()
Returns the request associated with this branch.
|
SipServletResponse |
getResponse()
Returns the last response received on this branch.
|
boolean |
isStarted()
The branch can be created using
and may be started at a later time by using
.
|
void |
setAddToPath(boolean p)
Specifies whether this branch should include a Path header for the REGISTER request
for this servlet container or not.
|
void |
setOutboundInterface(InetAddress address)
In multi-homed environment this method can be used to select the outbound interface
and port number to use for proxy branches.
|
void |
setOutboundInterface(InetSocketAddress address)
In multi-homed environment this method can be used to select the outbound interface
and port number to use for proxy branches.
|
void |
setProxyBranchTimeout(int seconds)
Sets the search timeout value for this ProxyBranch object.
|
void |
setRecordRoute(boolean rr)
Specifies whether this branch should include a Record-Route header for this servlet engine or not.
|
void |
setRecurse(boolean recurse)
Specifies whether the servlet engine will automatically recurse or not.
|
void cancel()
IllegalStateException - if the transaction has already been completed and it has no child branchesvoid cancel(String[] protocol, int[] reasonCode, String[] reasonText)
protocol - describes the source of the 'cause' field in the Reason header field.reasonCode - corresponds to the 'cause' field. For eg, if protocol is SIP,
the reasonCode would be the status code of the response which caused the cancelreasonText - describes the reason for cancelling the Proxy.boolean getAddToPath()
SipURI getPathURI()
IllegalStateException - if addToPath is not enabledProxy getProxy()
int getProxyBranchTimeout()
boolean getRecordRoute()
boolean getRecurse()
SipURI getRecordRouteURI()
List<ProxyBranch> getRecursedProxyBranches()
SipServletRequest getRequest()
SipServletResponse getResponse()
boolean isStarted()
void setRecordRoute(boolean rr)
rr - if true the engine will record-route, otherwise it won'tIllegalStateException - if the proxy has already been startedvoid setRecurse(boolean recurse)
recurse - if true enables recursion, otherwise disables itvoid setAddToPath(boolean p)
p - if true the container will add Path headervoid setOutboundInterface(InetAddress address)
address - the socket address representing the outbound interface to use when forwarding requests with this proxyNullPointerException - on null addressIllegalArgumentException - if the address is not understood by the container as one of its outbound interfacevoid setOutboundInterface(InetSocketAddress address)
address - the address which represents the outbound interfaceNullPointerException - on null addressIllegalArgumentException - if the address is not understood by the container as one of its outbound interfaceIllegalStateException - if this method is called on an invalidated sessionvoid setProxyBranchTimeout(int seconds)
Copyright © 2014. All Rights Reserved.