OSMQ
v2.0.1

osmq.clients
Class ClientStream

java.lang.Object
  extended byosmq.util.ExceptionListenerBase
      extended byosmq.util.ExceptionListenerImpl
          extended byosmq.net.SocketStreamFilter
              extended byosmq.clients.ClientStream
All Implemented Interfaces:
ExceptionListener

public class ClientStream
extends SocketStreamFilter

A ClientStream identifies itself and its role to the remote service when it connects.


Field Summary
static java.lang.String ROLE_COMMAND
           
static java.lang.String ROLE_PUBLISHER
           
static java.lang.String ROLE_RECOVERY
           
static java.lang.String ROLE_SUBSCRIBER
           
static java.lang.String ROLE_TOPIC_CHG
           
 
Method Summary
 void authenticate()
           
static SocketStreamFilter createStream(RemoteService es, ExceptionListener listener, java.lang.String role, ClientIdentifier ci)
           
 ClientIdentifier getClientIdentifier()
           
 java.lang.String getRole()
           
 void setClientIdentifier(ClientIdentifier identifier)
           
 void setRole(java.lang.String role)
           
 
Methods inherited from class osmq.net.SocketStreamFilter
close, flush, getInetAddress, getWrittenCount, isOpen, println, printlnCounted, readBytes, readln, setSocket, setSocket, writeBytes, writeBytesCounted, writeNull
 
Methods inherited from class osmq.util.ExceptionListenerImpl
onException
 
Methods inherited from class osmq.util.ExceptionListenerBase
getExceptionListener, setExceptionListener
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ROLE_PUBLISHER

public static final java.lang.String ROLE_PUBLISHER
See Also:
Constant Field Values

ROLE_SUBSCRIBER

public static final java.lang.String ROLE_SUBSCRIBER
See Also:
Constant Field Values

ROLE_TOPIC_CHG

public static final java.lang.String ROLE_TOPIC_CHG
See Also:
Constant Field Values

ROLE_COMMAND

public static final java.lang.String ROLE_COMMAND
See Also:
Constant Field Values

ROLE_RECOVERY

public static final java.lang.String ROLE_RECOVERY
See Also:
Constant Field Values
Method Detail

setClientIdentifier

public void setClientIdentifier(ClientIdentifier identifier)

getClientIdentifier

public ClientIdentifier getClientIdentifier()

setRole

public void setRole(java.lang.String role)

getRole

public java.lang.String getRole()

authenticate

public void authenticate()
                  throws java.io.IOException
Throws:
java.io.IOException

createStream

public static SocketStreamFilter createStream(RemoteService es,
                                              ExceptionListener listener,
                                              java.lang.String role,
                                              ClientIdentifier ci)
                                       throws java.io.IOException
Throws:
java.io.IOException

(c) 2000 - 2003 MQue Systems
All Rights Reserved