Log4j 1.0.1

pl.psnc.expres.broker.notification.handler
Class AbstractNotificationHandler

java.lang.Object
  extended by pl.psnc.expres.broker.notification.handler.AbstractNotificationHandler
Direct Known Subclasses:
CdsNotificationHandler, CnNotificationHandler, TnNotificationHandler

public abstract class AbstractNotificationHandler
extends java.lang.Object

AbstractNotificationHandler class - abstract notification handler class. This class is parent class for all notification handlers.

Author:
Dominik Stoklosa (~osa~)
Email address
osa@man.poznan.pl

Constructor Summary
AbstractNotificationHandler(pl.psnc.expres.model.experiment.VlbiExperiment vlbiExperiment, pl.psnc.expres.remote.protocol.notification.Notification notification)
          Creates a new instance of AbstractNotificationHandler
 
Method Summary
protected  void debugState()
          Prints state information and sender
protected  java.lang.String getCallBackLocation()
          Get location of callback service - vlbi broker notification service
 pl.psnc.expres.remote.protocol.ChunkInfo getChunkInfo()
          Get value of field: chunkInfo
 pl.psnc.expres.remote.protocol.MessageHeader getMHeader()
          Get value of field: mHeader
 pl.psnc.expres.remote.protocol.notification.Notification getNotification()
          Get value of field: notification
 java.lang.String getSenderLocation()
          Get location of a message sender
 pl.psnc.expres.remote.protocol.notification.State getState()
          Get value of field: state
 pl.psnc.expres.model.experiment.VlbiExperiment getVlbiExperiment()
          Get value of field: vlbiExperiment
abstract  void handle()
          Handles notification event
protected  void handleExperimentEnd()
          Handles experiment end event: notifies all observer
protected  void handleOk()
           
protected  void saveState(CorrelationJobValue corJob, pl.psnc.expres.remote.protocol.notification.State state)
          Save correlation state for the given translation node
 void setChunkInfo(pl.psnc.expres.remote.protocol.ChunkInfo chunkInfo)
          Set value of field: chunkInfo
 void setMHeader(pl.psnc.expres.remote.protocol.MessageHeader header)
          Set value of field: mHeader
 void setState(pl.psnc.expres.remote.protocol.notification.State state)
          Set value of field: state
 void setVlbiExperiment(pl.psnc.expres.model.experiment.VlbiExperiment vlbiExperiment)
          Set value of field: vlbiExperiment
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractNotificationHandler

public AbstractNotificationHandler(pl.psnc.expres.model.experiment.VlbiExperiment vlbiExperiment,
                                   pl.psnc.expres.remote.protocol.notification.Notification notification)
Creates a new instance of AbstractNotificationHandler

Parameters:
vlbiExperiment - vlbi experiment instance
notification - instance of Notification
Method Detail

debugState

protected void debugState()
Prints state information and sender


handleOk

protected void handleOk()

saveState

protected void saveState(CorrelationJobValue corJob,
                         pl.psnc.expres.remote.protocol.notification.State state)
Save correlation state for the given translation node

Parameters:
corJob - correlation job instance
state - state to store

getCallBackLocation

protected java.lang.String getCallBackLocation()
                                        throws pl.psnc.vlab.exception.ResourceNotFoundException
Get location of callback service - vlbi broker notification service

Returns:
location of callback service - vlbi broker notification service
Throws:
pl.psnc.vlab.exception.ResourceNotFoundException - thrown when configuration object cannot be found

handleExperimentEnd

protected void handleExperimentEnd()
                            throws pl.psnc.expres.exception.RemoteException
Handles experiment end event: notifies all observer

Throws:
pl.psnc.expres.exception.RemoteException

getChunkInfo

public pl.psnc.expres.remote.protocol.ChunkInfo getChunkInfo()
Get value of field: chunkInfo

Returns:
the chunkInfo

getMHeader

public pl.psnc.expres.remote.protocol.MessageHeader getMHeader()
Get value of field: mHeader

Returns:
the mHeader

getNotification

public pl.psnc.expres.remote.protocol.notification.Notification getNotification()
Get value of field: notification

Returns:
the notification

getSenderLocation

public java.lang.String getSenderLocation()
Get location of a message sender

Returns:
location of a message sender

getState

public pl.psnc.expres.remote.protocol.notification.State getState()
Get value of field: state

Returns:
the state

getVlbiExperiment

public pl.psnc.expres.model.experiment.VlbiExperiment getVlbiExperiment()
Get value of field: vlbiExperiment

Returns:
the vlbiExperiment

handle

public abstract void handle()
Handles notification event


setChunkInfo

public void setChunkInfo(pl.psnc.expres.remote.protocol.ChunkInfo chunkInfo)
Set value of field: chunkInfo

Parameters:
chunkInfo - the chunkInfo to set

setMHeader

public void setMHeader(pl.psnc.expres.remote.protocol.MessageHeader header)
Set value of field: mHeader

Parameters:
header - the mHeader to set

setState

public void setState(pl.psnc.expres.remote.protocol.notification.State state)
Set value of field: state

Parameters:
state - the state to set

setVlbiExperiment

public void setVlbiExperiment(pl.psnc.expres.model.experiment.VlbiExperiment vlbiExperiment)
Set value of field: vlbiExperiment

Parameters:
vlbiExperiment - the vlbiExperiment to set

Log4j 1.0.1

Dominik Stoklosa Copyright 2007-2009 by PSNC