org.jdiameter.client.impl.app.sh
Class ShClientSessionImpl
java.lang.Object
org.jdiameter.common.impl.app.AppSessionImpl
org.jdiameter.common.impl.app.sh.ShSession
org.jdiameter.client.impl.app.sh.ShClientSessionImpl
- All Implemented Interfaces:
- AppSession, StateMachine, BaseSession, EventListener<Request,Answer>, NetworkReqListener, ClientShSession
public class ShClientSessionImpl
- extends ShSession
- implements ClientShSession, EventListener<Request,Answer>, NetworkReqListener
Basic implementation of ShClientSession - can be one time - for UDR,PUR and
constant for SNR-PNR pair, in case when SNA contains response code from range
different than 2001-2004(success codes) user is responsible for maintaing
state - releasing etc, same goes if result code is contained
Experimental-Result AVP
If ShSession moves to ShSessionState.TERMINATED - it means that no further
messages can be received via it and it should be discarded.
- Author:
- Bartosz Baranowski , Alexandre Mendonca
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
sendAndStateLock
protected java.util.concurrent.locks.Lock sendAndStateLock
factory
protected transient IShMessageFactory factory
listener
protected transient ClientShSessionListener listener
sessionData
protected IShClientSessionData sessionData
ShClientSessionImpl
public ShClientSessionImpl(IShClientSessionData sessionData,
IShMessageFactory fct,
ISessionFactory sf,
ClientShSessionListener lst)
processRequest
public Answer processRequest(Request request)
- Specified by:
processRequest in interface NetworkReqListener
getState
public <E> E getState(java.lang.Class<E> stateType)
- Specified by:
getState in interface StateMachine
handleEvent
public boolean handleEvent(StateEvent event)
throws InternalException,
OverloadException
- Specified by:
handleEvent in interface StateMachine
- Throws:
InternalException
OverloadException
sendProfileUpdateRequest
public void sendProfileUpdateRequest(ProfileUpdateRequest request)
throws InternalException,
IllegalDiameterStateException,
RouteException,
OverloadException
- Specified by:
sendProfileUpdateRequest in interface ClientShSession
- Throws:
InternalException
IllegalDiameterStateException
RouteException
OverloadException
sendPushNotificationAnswer
public void sendPushNotificationAnswer(PushNotificationAnswer answer)
throws InternalException,
IllegalDiameterStateException,
RouteException,
OverloadException
- Specified by:
sendPushNotificationAnswer in interface ClientShSession
- Throws:
InternalException
IllegalDiameterStateException
RouteException
OverloadException
sendSubscribeNotificationsRequest
public void sendSubscribeNotificationsRequest(SubscribeNotificationsRequest request)
throws InternalException,
IllegalDiameterStateException,
RouteException,
OverloadException
- Specified by:
sendSubscribeNotificationsRequest in interface ClientShSession
- Throws:
InternalException
IllegalDiameterStateException
RouteException
OverloadException
sendUserDataRequest
public void sendUserDataRequest(UserDataRequest request)
throws InternalException,
IllegalDiameterStateException,
RouteException,
OverloadException
- Specified by:
sendUserDataRequest in interface ClientShSession
- Throws:
InternalException
IllegalDiameterStateException
RouteException
OverloadException
send
protected void send(org.jdiameter.client.impl.app.sh.Event.Type type,
AppEvent request,
AppEvent answer)
throws InternalException
- Throws:
InternalException
receivedSuccessMessage
public void receivedSuccessMessage(Request request,
Answer answer)
- Specified by:
receivedSuccessMessage in interface EventListener<Request,Answer>
timeoutExpired
public void timeoutExpired(Request request)
- Specified by:
timeoutExpired in interface EventListener<Request,Answer>
release
public void release()
- Specified by:
release in interface BaseSession- Overrides:
release in class ShSession
isStateless
public boolean isStateless()
- Specified by:
isStateless in interface AppSession
isReplicable
public boolean isReplicable()
- Specified by:
isReplicable in interface BaseSession- Overrides:
isReplicable in class AppSessionImpl
onTimer
public void onTimer(java.lang.String timerName)
- Specified by:
onTimer in class AppSessionImpl
Copyright © 2014. All Rights Reserved.