Wildfire 3.2.4 Javadoc

org.jivesoftware.wildfire.http
Class HttpSession.HttpVirtualConnection

java.lang.Object
  extended by org.jivesoftware.wildfire.net.VirtualConnection
      extended by org.jivesoftware.wildfire.http.HttpSession.HttpVirtualConnection
All Implemented Interfaces:
Connection
Enclosing class:
HttpSession

public static class HttpSession.HttpVirtualConnection
extends VirtualConnection

A virtual server connection relates to a http session which its self can relate to many http connections.


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.jivesoftware.wildfire.Connection
Connection.CompressionPolicy, Connection.TLSPolicy
 
Field Summary
 
Fields inherited from class org.jivesoftware.wildfire.net.VirtualConnection
session
 
Constructor Summary
HttpSession.HttpVirtualConnection(InetAddress address)
           
 
Method Summary
 void closeVirtualConnection()
          Closes the virtual connection.
 void deliver(Packet packet)
          Delivers the packet to this connection without checking the recipient.
 void deliverRawText(String text)
          Delivers raw text to this connection.
 InetAddress getInetAddress()
          Returns the InetAddress describing the connection.
 void systemShutdown()
          Notification message indicating that the server is being shutdown.
 
Methods inherited from class org.jivesoftware.wildfire.net.VirtualConnection
close, getCompressionPolicy, getLanguage, getMajorXMPPVersion, getMinorXMPPVersion, getPacketDeliverer, getTlsPolicy, init, isClosed, isCompressed, isFlashClient, isSecure, registerCloseListener, removeCloseListener, setCompressionPolicy, setFlashClient, setLanaguage, setTlsPolicy, setXMPPVersion, startCompression, startTLS, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpSession.HttpVirtualConnection

public HttpSession.HttpVirtualConnection(InetAddress address)
Method Detail

closeVirtualConnection

public void closeVirtualConnection()
Description copied from class: VirtualConnection
Closes the virtual connection. Subsclasses should indicate what closing a virtual connection means. At this point the session has a CLOSED state.

Specified by:
closeVirtualConnection in class VirtualConnection

getInetAddress

public InetAddress getInetAddress()
Description copied from interface: Connection
Returns the InetAddress describing the connection.

Returns:
the InetAddress describing the underlying connection properties.

systemShutdown

public void systemShutdown()
Description copied from interface: Connection
Notification message indicating that the server is being shutdown. Implementors should send a stream error whose condition is system-shutdown before closing the connection.


deliver

public void deliver(Packet packet)
             throws UnauthorizedException
Description copied from interface: Connection
Delivers the packet to this connection without checking the recipient. The method essentially calls socket.send(packet.getWriteBuffer()).

Parameters:
packet - the packet to deliver.
Throws:
UnauthorizedException - if a permission error was detected.

deliverRawText

public void deliverRawText(String text)
Description copied from interface: Connection
Delivers raw text to this connection. This is a very low level way for sending XML stanzas to the client. This method should not be used unless you have very good reasons for not using Connection.deliver(org.xmpp.packet.Packet).

This method avoids having to get the writer of this connection and mess directly with the writer. Therefore, this method ensures a correct delivery of the stanza even if other threads were sending data concurrently.

Parameters:
text - the XML stanzas represented kept in a String.

Wildfire 3.2.4 Javadoc

Copyright © 2003-2007 Jive Software.