public interface Session extends BaseSession, Wrapper
| Modifier and Type | Method and Description |
|---|---|
Request |
createRequest(int commandCode,
ApplicationId appId,
String destRealm)
Returns a new Request object with the specified command code, applicationId, realm
and predefined system avps.
|
Request |
createRequest(int commandCode,
ApplicationId appId,
String destRealm,
String destHost)
Returns a new Request object with the specified command code, applicationId, realm, host
and predefined system avps.
|
Request |
createRequest(Request prevRequest)
Returns a new Request object base on previous request.(header is copied)
|
Future<Message> |
send(Message message)
Sends and wait response message with default timeout
|
void |
send(Message message,
EventListener<Request,Answer> listener)
Sends and wait response message with default timeout
|
void |
send(Message message,
EventListener<Request,Answer> listener,
long timeOut,
TimeUnit timeUnit)
Sends and wait response message with defined timeout
|
Future<Message> |
send(Message message,
long timeOut,
TimeUnit timeUnit)
Sends and wait response message with defined timeout
|
void |
setRequestListener(NetworkReqListener listener)
Set session request listener
|
getCreationTime, getLastAccessedTime, getSessionId, isAppSession, isReplicable, isValid, releaseisWrapperFor, unwrapvoid setRequestListener(NetworkReqListener listener)
listener - session request listenerRequest createRequest(int commandCode, ApplicationId appId, String destRealm)
commandCode - code of messageappId - applicationId of destination applicationdestRealm - name of destination RealmRequest createRequest(int commandCode, ApplicationId appId, String destRealm, String destHost)
commandCode - code of messageappId - applicationId of destination applicationdestRealm - name of destination RealmdestHost - name of destination HostRequest createRequest(Request prevRequest)
prevRequest - previous request (header is copied)void send(Message message, EventListener<Request,Answer> listener) throws InternalException, IllegalDiameterStateException, RouteException, OverloadException
message - request/answer diameter messagelistener - event listenerInternalException - The InternalException signals that internal error is occurred.IllegalDiameterStateException - The IllegalStateException signals that session has incorrect state (invalid).RouteException - The NoRouteException signals that no route exist for a given realm.OverloadException - The OverloadException signals that destination host is overloaded.void send(Message message, EventListener<Request,Answer> listener, long timeOut, TimeUnit timeUnit) throws InternalException, IllegalDiameterStateException, RouteException, OverloadException
message - request/answer diameter messagelistener - event listenertimeOut - value of timeouttimeUnit - type of timeOut valueInternalException - The InternalException signals that internal error is occurred.IllegalDiameterStateException - The IllegalStateException signals that session has incorrect state (invalid).RouteException - The NoRouteException signals that no route exist for a given realm.OverloadException - The OverloadException signals that destination host is overloaded.Future<Message> send(Message message) throws InternalException, IllegalDiameterStateException, RouteException, OverloadException
message - request/answer diameter messageInternalException - The InternalException signals that internal error is occurred.IllegalDiameterStateException - The IllegalStateException signals that session has incorrect state (invalid).RouteException - The NoRouteException signals that no route exist for a given realm.OverloadException - The OverloadException signals that destination host is overloaded.Future<Message> send(Message message, long timeOut, TimeUnit timeUnit) throws InternalException, IllegalDiameterStateException, RouteException, OverloadException
message - request/answer diameter messagetimeOut - value of timeouttimeUnit - type of timeOut valueInternalException - The InternalException signals that internal error is occurred.IllegalDiameterStateException - The IllegalStateException signals that session has incorrect state (invalid).RouteException - The NoRouteException signals that no route exist for a given realm.OverloadException - The OverloadException signals that destination host is overloaded.Copyright © 2016. All Rights Reserved.