Connection Manager 3.4.4 Javadoc

org.jivesoftware.multiplexer
Class ClientSession

java.lang.Object
  extended by org.jivesoftware.multiplexer.Session
      extended by org.jivesoftware.multiplexer.ClientSession

public class ClientSession
extends Session

Session that represents a client to server connection.

Author:
Gaston Dombiak

Field Summary
 
Fields inherited from class org.jivesoftware.multiplexer.Session
CHARSET, conn, idFactory, MAJOR_VERSION, MINOR_VERSION, status, STATUS_AUTHENTICATED, STATUS_CLOSED, STATUS_CONNECTED, STATUS_STREAMING
 
Constructor Summary
ClientSession(java.lang.String serverName, Connection connection, java.lang.String streamID)
           
 
Method Summary
 void close()
          Indicate the server that the session has been closed.
 void close(boolean systemStopped)
          Closes the client connection.
static Session createSession(java.lang.String serverName, org.xmlpull.v1.XmlPullParser xpp, Connection connection)
           
 void deliver(org.dom4j.Element stanza)
          Delivers a stanza sent by the server to the client.
 java.lang.String getAvailableStreamFeatures()
          Returns a text with the available stream features.
 boolean isClosed()
           
 
Methods inherited from class org.jivesoftware.multiplexer.Session
addSession, closeAll, decodeVersion, getCreationDate, getServerName, getSession, getStatus, getStreamID, removeSession, setStatus, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClientSession

public ClientSession(java.lang.String serverName,
                     Connection connection,
                     java.lang.String streamID)
Method Detail

createSession

public static Session createSession(java.lang.String serverName,
                                    org.xmlpull.v1.XmlPullParser xpp,
                                    Connection connection)
                             throws org.xmlpull.v1.XmlPullParserException
Throws:
org.xmlpull.v1.XmlPullParserException

getAvailableStreamFeatures

public java.lang.String getAvailableStreamFeatures()
Description copied from class: Session
Returns a text with the available stream features. Each subclass may return different values depending whether the session has been authenticated or not.

Specified by:
getAvailableStreamFeatures in class Session
Returns:
a text with the available stream features or null to add nothing.

deliver

public void deliver(org.dom4j.Element stanza)
Delivers a stanza sent by the server to the client.

Specified by:
deliver in class Session
Parameters:
stanza - the stanza sent by the server.

close

public void close()
Description copied from class: Session
Indicate the server that the session has been closed. Do nothing if the session was the one that originated the close action.

Specified by:
close in class Session

close

public void close(boolean systemStopped)
Closes the client connection. The systemStopped parameter indicates if the client connection is being closed because the server is shutting down or unavailable or if it is because the connection manager is being shutdown.

Specified by:
close in class Session
Parameters:
systemStopped - true when the server is no longer available or the connection manager is being shutdown.

isClosed

public boolean isClosed()
Specified by:
isClosed in class Session

Connection Manager 3.4.4 Javadoc

Copyright © 2003-2006 Jive Software.