org.jdiameter.server.impl.app.auth
Class ServerAuthSessionImpl

java.lang.Object
  extended by org.jdiameter.common.impl.app.AppSessionImpl
      extended by org.jdiameter.common.impl.app.auth.AppAuthSessionImpl
          extended by org.jdiameter.server.impl.app.auth.ServerAuthSessionImpl
All Implemented Interfaces:
java.io.Serializable, org.jdiameter.api.app.AppSession, org.jdiameter.api.app.StateMachine, org.jdiameter.api.auth.ServerAuthSession, org.jdiameter.api.EventListener<org.jdiameter.api.Request,org.jdiameter.api.Answer>, org.jdiameter.api.NetworkReqListener

public class ServerAuthSessionImpl
extends AppAuthSessionImpl
implements org.jdiameter.api.auth.ServerAuthSession, org.jdiameter.api.EventListener<org.jdiameter.api.Request,org.jdiameter.api.Answer>, org.jdiameter.api.NetworkReqListener

See Also:
Serialized Form

Field Summary
protected  IServerAuthActionContext context
           
protected  IAuthMessageFactory factory
           
protected  org.jdiameter.api.auth.ServerAuthSessionListener listener
           
protected static org.apache.log4j.Logger logger
           
protected  ServerAuthSessionState state
           
protected  boolean stateless
           
protected  java.util.concurrent.ScheduledFuture tsTask
           
protected  long tsTimeout
           
 
Fields inherited from class org.jdiameter.common.impl.app.auth.AppAuthSessionImpl
scheduler, stateListeners
 
Fields inherited from class org.jdiameter.common.impl.app.AppSessionImpl
appId, session
 
Constructor Summary
ServerAuthSessionImpl(org.jdiameter.api.Session session, org.jdiameter.api.Request initialRequest, org.jdiameter.api.auth.ServerAuthSessionListener lst, IAuthMessageFactory fct, long tsTimeout, boolean stateless, org.jdiameter.api.app.StateChangeListener... scListeners)
           
 
Method Summary
<E> E
getState(java.lang.Class<E> eClass)
           
 boolean handleEvent(org.jdiameter.api.app.StateEvent event)
           
 boolean handleEventForStatefullSession(org.jdiameter.api.app.StateEvent event)
           
 boolean handleEventForStatelessSession(org.jdiameter.api.app.StateEvent event)
           
 boolean isStateless()
           
 org.jdiameter.api.Answer processRequest(org.jdiameter.api.Request request)
           
 void receivedSuccessMessage(org.jdiameter.api.Request request, org.jdiameter.api.Answer answer)
           
protected  void send(org.jdiameter.server.impl.app.auth.Event.Type type, org.jdiameter.api.app.AppEvent event)
           
 void sendAbortSessionRequest(org.jdiameter.api.auth.events.AbortSessionRequest abortSessionRequest)
           
 void sendAuthAnswer(org.jdiameter.api.app.AppAnswerEvent appAnswerEvent)
           
 void sendReAuthRequest(org.jdiameter.api.auth.events.ReAuthRequest reAuthRequest)
           
 void sendSessionTerminationAnswer(org.jdiameter.api.auth.events.SessionTermAnswer sessionTermAnswer)
           
protected  void setState(ServerAuthSessionState newState)
           
 void timeoutExpired(org.jdiameter.api.Request request)
           
 
Methods inherited from class org.jdiameter.common.impl.app.auth.AppAuthSessionImpl
addStateChangeNotification, release, removeStateChangeNotification
 
Methods inherited from class org.jdiameter.common.impl.app.AppSessionImpl
getCreationTime, getLastAccessedTime, getSessionAppId, getSessions, isValid
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jdiameter.api.app.AppSession
getCreationTime, getLastAccessedTime, getSessionAppId, getSessions, isValid, release
 
Methods inherited from interface org.jdiameter.api.app.StateMachine
addStateChangeNotification, removeStateChangeNotification
 

Field Detail

logger

protected static final org.apache.log4j.Logger logger

state

protected ServerAuthSessionState state

stateless

protected boolean stateless

tsTimeout

protected long tsTimeout

tsTask

protected java.util.concurrent.ScheduledFuture tsTask

factory

protected IAuthMessageFactory factory

context

protected IServerAuthActionContext context

listener

protected org.jdiameter.api.auth.ServerAuthSessionListener listener
Constructor Detail

ServerAuthSessionImpl

public ServerAuthSessionImpl(org.jdiameter.api.Session session,
                             org.jdiameter.api.Request initialRequest,
                             org.jdiameter.api.auth.ServerAuthSessionListener lst,
                             IAuthMessageFactory fct,
                             long tsTimeout,
                             boolean stateless,
                             org.jdiameter.api.app.StateChangeListener... scListeners)
Method Detail

sendAuthAnswer

public void sendAuthAnswer(org.jdiameter.api.app.AppAnswerEvent appAnswerEvent)
                    throws org.jdiameter.api.InternalException,
                           org.jdiameter.api.IllegalDiameterStateException,
                           org.jdiameter.api.RouteException,
                           org.jdiameter.api.OverloadException
Specified by:
sendAuthAnswer in interface org.jdiameter.api.auth.ServerAuthSession
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.IllegalDiameterStateException
org.jdiameter.api.RouteException
org.jdiameter.api.OverloadException

sendReAuthRequest

public void sendReAuthRequest(org.jdiameter.api.auth.events.ReAuthRequest reAuthRequest)
                       throws org.jdiameter.api.InternalException,
                              org.jdiameter.api.IllegalDiameterStateException,
                              org.jdiameter.api.RouteException,
                              org.jdiameter.api.OverloadException
Specified by:
sendReAuthRequest in interface org.jdiameter.api.auth.ServerAuthSession
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.IllegalDiameterStateException
org.jdiameter.api.RouteException
org.jdiameter.api.OverloadException

sendAbortSessionRequest

public void sendAbortSessionRequest(org.jdiameter.api.auth.events.AbortSessionRequest abortSessionRequest)
                             throws org.jdiameter.api.InternalException,
                                    org.jdiameter.api.IllegalDiameterStateException,
                                    org.jdiameter.api.RouteException,
                                    org.jdiameter.api.OverloadException
Specified by:
sendAbortSessionRequest in interface org.jdiameter.api.auth.ServerAuthSession
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.IllegalDiameterStateException
org.jdiameter.api.RouteException
org.jdiameter.api.OverloadException

sendSessionTerminationAnswer

public void sendSessionTerminationAnswer(org.jdiameter.api.auth.events.SessionTermAnswer sessionTermAnswer)
                                  throws org.jdiameter.api.InternalException,
                                         org.jdiameter.api.IllegalDiameterStateException,
                                         org.jdiameter.api.RouteException,
                                         org.jdiameter.api.OverloadException
Specified by:
sendSessionTerminationAnswer in interface org.jdiameter.api.auth.ServerAuthSession
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.IllegalDiameterStateException
org.jdiameter.api.RouteException
org.jdiameter.api.OverloadException

send

protected void send(org.jdiameter.server.impl.app.auth.Event.Type type,
                    org.jdiameter.api.app.AppEvent event)
             throws org.jdiameter.api.InternalException
Throws:
org.jdiameter.api.InternalException

isStateless

public boolean isStateless()
Specified by:
isStateless in interface org.jdiameter.api.app.AppSession

setState

protected void setState(ServerAuthSessionState newState)

getState

public <E> E getState(java.lang.Class<E> eClass)
Specified by:
getState in interface org.jdiameter.api.app.StateMachine

handleEvent

public boolean handleEvent(org.jdiameter.api.app.StateEvent event)
                    throws org.jdiameter.api.InternalException,
                           org.jdiameter.api.OverloadException
Specified by:
handleEvent in interface org.jdiameter.api.app.StateMachine
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.OverloadException

handleEventForStatelessSession

public boolean handleEventForStatelessSession(org.jdiameter.api.app.StateEvent event)
                                       throws org.jdiameter.api.InternalException,
                                              org.jdiameter.api.OverloadException
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.OverloadException

handleEventForStatefullSession

public boolean handleEventForStatefullSession(org.jdiameter.api.app.StateEvent event)
                                       throws org.jdiameter.api.InternalException,
                                              org.jdiameter.api.OverloadException
Throws:
org.jdiameter.api.InternalException
org.jdiameter.api.OverloadException

receivedSuccessMessage

public void receivedSuccessMessage(org.jdiameter.api.Request request,
                                   org.jdiameter.api.Answer answer)
Specified by:
receivedSuccessMessage in interface org.jdiameter.api.EventListener<org.jdiameter.api.Request,org.jdiameter.api.Answer>

timeoutExpired

public void timeoutExpired(org.jdiameter.api.Request request)
Specified by:
timeoutExpired in interface org.jdiameter.api.EventListener<org.jdiameter.api.Request,org.jdiameter.api.Answer>

processRequest

public org.jdiameter.api.Answer processRequest(org.jdiameter.api.Request request)
Specified by:
processRequest in interface org.jdiameter.api.NetworkReqListener


Copyright © 2008. All Rights Reserved.