JHPcte
Class PcteNotificationHandler

java.lang.Object
  |
  +--JHPcte.PcteNotificationHandler
All Implemented Interfaces:
java.lang.Runnable

public class PcteNotificationHandler
extends java.lang.Object
implements java.lang.Runnable

Receives notification event desciptions from the JHPcte server and forwards them to the corresponding process. The NotificationHandler is executed in a thread controlled by the PcteProcess.


Field Summary
protected  boolean closing_connection
           
protected  JHPcte.NotifierEventSource eventSource
           
protected  PcteEventDescription notificationDescr
           
protected  JHPcte.PcteServerConnection notifyConn
           
protected  PcteProcess process
           
 
Constructor Summary
PcteNotificationHandler(PcteProcess process, JHPcte.PcteServerConnection notifyConn)
          Creates a notification handler.
 
Method Summary
 void close()
          close the connection
protected  void finalize()
          clean up
 PcteEventDescription getDescription()
          return the Pcte event description
 JHPcte.NotifierEventSource getEventSource()
          return the component event listeners can connect to
protected  PcteAclEntry[] receiveACL()
          receive the acl of an object
protected  PcteAttributeValue receiveAttributeValue()
          receive an attribute value via the notification socket connection
protected  PcteEventDescription receiveNotificationDescription()
           
 void run()
          Listens at the notification socket.
 void start()
           
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

process

protected PcteProcess process

notifyConn

protected JHPcte.PcteServerConnection notifyConn

notificationDescr

protected PcteEventDescription notificationDescr

eventSource

protected JHPcte.NotifierEventSource eventSource

closing_connection

protected boolean closing_connection
Constructor Detail

PcteNotificationHandler

public PcteNotificationHandler(PcteProcess process,
                               JHPcte.PcteServerConnection notifyConn)
Creates a notification handler.
Parameters:
process - the corresponding PcteProcess
notifyConn - PcteServerConnection for notification event descriptions
Method Detail

finalize

protected void finalize()
clean up
Overrides:
finalize in class java.lang.Object

close

public void close()
close the connection

start

public void start()

run

public void run()
Listens at the notification socket. In case of notification, the event description sent by the server is forwarded to the corresponding process.
Specified by:
run in interface java.lang.Runnable

getDescription

public PcteEventDescription getDescription()
return the Pcte event description

getEventSource

public JHPcte.NotifierEventSource getEventSource()
return the component event listeners can connect to

receiveNotificationDescription

protected PcteEventDescription receiveNotificationDescription()
                                                       throws PcteException

receiveAttributeValue

protected PcteAttributeValue receiveAttributeValue()
                                            throws PcteException
receive an attribute value via the notification socket connection

receiveACL

protected PcteAclEntry[] receiveACL()
                             throws PcteException
receive the acl of an object