|
Oracle Communications Converged Application Server Java API Reference 5.0 E18767-01 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
com.bea.wcp.diameter.Session
public class Session
Base class for Diameter application sessions. Diameter applications extend this class in order to provide application-specific handling of requests or answer messages for the application.
| Constructor Summary | |
|---|---|
Session(Application app)Creates a new client Session for the specified Application. |
|
Session(Application app, java.lang.String id)Creates a new server Session for the specified Application and session id. |
|
| Method Summary | |
|---|---|
XmlBuffer |
appendXml(XmlBuffer xb) |
Request |
createRequest(Command cmd)Creates a new Request for this session. |
Application |
getApplication()Returns the Application for this Session. |
java.lang.Object |
getAttribute(java.lang.String name)Returns the value of the specified session attribute. |
java.lang.String |
getId()Returns the session identifier. |
SessionListener |
getListener()Returns the SessionListener for this session. |
boolean |
isTerminated()Returns true if this session has been terminated. |
protected void |
notifyListener(Message msg)Deliver specified message to session listener. |
protected void |
rcvAnswer(Answer ans)Called when an answer message has been received for this session. |
void |
rcvMessage(Message msg)Called when a new Request or Answer has been received http://news.com.com/2061-10802_3-6160230.html?tag=nefd.aoffor this session. |
protected void |
rcvRequest(Request req)Called when a new request message has been received for this session. |
void |
removeAttribute(java.lang.String name)Removes the session attribute with the specified name. |
void |
setAttribute(java.lang.String name, java.lang.Object value)Sets the new value of a session attribute, replacing any previous value. |
void |
setListener(SessionListener listener)Sets the SessionListener for this session. |
void |
sndMessage(Message msg)Called by the container when a message is about to be sent but before it has been committed. |
void |
terminate()Terminates the session. |
java.lang.String |
toString() |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Session(Application app,
java.lang.String id)
app - the Application for the sessionid - the session idjava.lang.IllegalStateException - if a session with the same id has already been createdpublic Session(Application app)
app - the Application for the session| Method Detail |
|---|
public void setListener(SessionListener listener)
listener - the new SessionListenerpublic SessionListener getListener()
public final java.lang.String getId()
public final Application getApplication()
public void setAttribute(java.lang.String name,
java.lang.Object value)
name - the attribute namevalue - the new attribute valuepublic java.lang.Object getAttribute(java.lang.String name)
name - the attribute namepublic void removeAttribute(java.lang.String name)
name - the attribute namepublic void terminate()
public boolean isTerminated()
public Request createRequest(Command cmd)
cmd - the command for the request
protected void notifyListener(Message msg)
throws DiameterException,
java.io.IOException
msg - the message to be deliveredDiameterExceptionjava.io.IOException
public void rcvMessage(Message msg)
throws DiameterException,
java.io.IOException
msg - the message that has been receivedjava.io.IOException - if an error occured while processing the messageDiameterException
protected void rcvRequest(Request req)
throws DiameterException,
java.io.IOException
req - the request that has been receivedjava.io.IOException - if an error occurred while processing the requestDiameterException
protected void rcvAnswer(Answer ans)
throws DiameterException,
java.io.IOException
ans - the answer message that has been receivedjava.io.IOException - if an error occured while processing the answerDiameterException
public void sndMessage(Message msg)
throws java.io.IOException
msg - the message being sentjava.io.IOException - if an I/O error occurred while sending the messagepublic java.lang.String toString()
toString in class java.lang.Objectpublic XmlBuffer appendXml(XmlBuffer xb)
|
Oracle Communications Converged Application Server Java API Reference 5.0 E18767-01 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||