javax.infobus
Class InfoBusDataProducerProxy

java.lang.Object
  |
  +--javax.infobus.InfoBusDataProducerProxy

public class InfoBusDataProducerProxy
extends java.lang.Object
implements InfoBusDataProducer

This proxy class serves as an event listener on behalf of a parent class that creates the Object. The proxy simply delegates the events it receives to the parent for all handling. The purpose for the proxy class is to protect the parent class from malicious components on the bus.

Events and data items each return a reference to the event listener of the InfoBus component that created them for identification purposes. If the event listener were registered as the same class as the member, the receiver of an event could introspect the member class and, for example, force the source of the event off the bus by calling setInfoBus(null). The proxy has nothing interesting that could be used to disrupt the application, and using it to handle events isolates the parent class from such disruptions.


Constructor Summary
InfoBusDataProducerProxy(InfoBusDataProducer parent)
          The constructor is called by the Producer to create an InfoBusDataProducerProxy.
 
Method Summary
 void dataItemRequested(InfoBusItemRequestedEvent ire)
          This method simply delegates the handling of the event to its parent class.
 void propertyChange(java.beans.PropertyChangeEvent pce)
          This method simply delegates the handling of the event to its parent class.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InfoBusDataProducerProxy

public InfoBusDataProducerProxy(InfoBusDataProducer parent)
The constructor is called by the Producer to create an InfoBusDataProducerProxy.
Parameters:
parent - is a reference to the Object that will handle InfoBusItemRequestedEvents and PropertyChangeEvents received by the producer proxy listener.
Method Detail

dataItemRequested

public void dataItemRequested(InfoBusItemRequestedEvent ire)
This method simply delegates the handling of the event to its parent class.
Specified by:
dataItemRequested in interface InfoBusDataProducer
Parameters:
ire - the InfoBusItemRequestedEvent to be passed.

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent pce)
This method simply delegates the handling of the event to its parent class.
Parameters:
pce - the PropertyChangeEvent to be passed.