examples.tls
Class MyRouter
java.lang.Object
examples.tls.MyRouter
- All Implemented Interfaces:
- Router
public class MyRouter
- extends Object
- implements Router
Method Summary |
Hop |
getNextHop(Request request)
Gets the next Hop from this Router for the specified request, this
method may return null if a default route is not defined. |
ListIterator |
getNextHops(Request sipRequest)
Always send requests to the default route location. |
Hop |
getOutboundProxy()
Gets the Outbound Proxy parameter of this Router, this method may return
null if no outbound proxy is defined. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
myStack
protected SipStack myStack
defaultRoute
protected HopImpl defaultRoute
MyRouter
public MyRouter(SipStack sipStack,
String nextHop)
getNextHops
public ListIterator getNextHops(Request sipRequest)
- Always send requests to the default route location.
- Specified by:
getNextHops
in interface Router
getOutboundProxy
public Hop getOutboundProxy()
- Description copied from interface:
Router
- Gets the Outbound Proxy parameter of this Router, this method may return
null if no outbound proxy is defined.
- Specified by:
getOutboundProxy
in interface Router
- Returns:
- the Outbound Proxy of this Router.
- See Also:
Hop
getNextHop
public Hop getNextHop(Request request)
throws SipException
- Description copied from interface:
Router
- Gets the next Hop from this Router for the specified request, this
method may return
null
if a default route is not defined.
- Specified by:
getNextHop
in interface Router
- Returns:
- the next Hop from this Router for the Request.
- Throws:
SipException
- when there is something wrong with the request- See Also:
Hop
Copyright © 2012. All Rights Reserved.