ilog.server.jsds.adapter
Class IlsGraphDS2IlvGrapherStrategy

java.lang.Object
  |
  +--ilog.server.jsds.adapter.IlsGraphDS2IlvGrapherStrategy
All Implemented Interfaces:
EventListener
Direct Known Subclasses:
IlsGraphDS2IlvGrapherAcceleratorStrategy, IlsGraphDS2IlvGrapherRendererStrategy

public class IlsGraphDS2IlvGrapherStrategy
extends Object
implements EventListener

Base class for graph adapter strategies, enhanced listeners for graph adapters.

Strategies are notified of main events occuring on the attached adapter: creation, deletion, updates from the corresponding data source, events dispatching in the adapter, and setting of the data model and of the graphic component.

Events from the data source are simply notified to the strategy and are generally used to manage user defined properties.
Events dispatching and setting of the data model and of the graphic component are cascaded through all strategies to allow events filtering or data model wrapping.

See Also:
IlsGraphDS2IlvGrapherAdapter

Field Summary
protected  IlsGraphDS2IlvGrapherAdapter _adapter
           
 
Constructor Summary
IlsGraphDS2IlvGrapherStrategy(IlsGraphDS2IlvGrapherAdapter adapter)
          Defines an empty strategy for IlsGraphDS2IlvGrapherAdapter adapters.
 
Method Summary
 void internalDataSourceChange(DataSourceEvent e)
          Called after data source change notification in the adapter.
 void internalDataSourceConnected(DSConnectionEvent e)
          Called after the data source connection event.
 void internalDataSourceDisconnected(DSConnectionEvent e)
          Called after the data source disconnection event.
 void internalLinkAdded(LinkEvent e)
          Called after link added event dispatching in the adapter.
 void internalLinkRemoved(LinkEvent e)
          Called after link removed event dispatching in the adapter.
 void internalLinkUpdated(LinkEvent e)
          Called after link updated event dispatching in the adapter.
 void internalNodeAdded(NodeEvent e)
          Called after node added event dispatching in the adapter.
 void internalNodeRemoved(NodeEvent e)
          Called after node removed event dispatching in the adapter.
 void internalNodeUpdated(NodeEvent e)
          Called after node updated event dispatching in the adapter.
 Component plugComponent(Component component)
          Called before graphic component is connected to the adapter.
 ArrayList postDispatchBatchedEvents(ArrayList events)
          Called before postdispatch events in the adapter.
 ArrayList preDispatchBatchedEvents(ArrayList events)
          Called before predispatch events in the adapter.
 ilog.views.IlvGrapher setModel(ilog.views.IlvGrapher grapher)
          Called before data model setting in the adapter.
 Component unplugComponent(Component component)
          Called before graphic component is disconnected from the adapter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_adapter

protected IlsGraphDS2IlvGrapherAdapter _adapter
Constructor Detail

IlsGraphDS2IlvGrapherStrategy

public IlsGraphDS2IlvGrapherStrategy(IlsGraphDS2IlvGrapherAdapter adapter)
Defines an empty strategy for IlsGraphDS2IlvGrapherAdapter adapters.
Parameters:
adapter - the adapter managing this strategy.
Method Detail

preDispatchBatchedEvents

public ArrayList preDispatchBatchedEvents(ArrayList events)
Called before predispatch events in the adapter. Allow events filtering in returning a modified events list.
Returns:
events unmodified.

postDispatchBatchedEvents

public ArrayList postDispatchBatchedEvents(ArrayList events)
Called before postdispatch events in the adapter. Allow events filtering in returning a modified events list.
Returns:
events unmodified.

internalDataSourceChange

public void internalDataSourceChange(DataSourceEvent e)
Called after data source change notification in the adapter.
Parameters:
e - the data source event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalDataSourceChange(DataSourceEvent)

setModel

public ilog.views.IlvGrapher setModel(ilog.views.IlvGrapher grapher)
Called before data model setting in the adapter. Allow for example data model wrapping.
Parameters:
grapher - the grapher.
Returns:
grapher unmodified.
See Also:
IlsGraphDS2IlvGrapherAdapter.setGrapher(IlvGrapher)

internalLinkAdded

public void internalLinkAdded(LinkEvent e)
Called after link added event dispatching in the adapter.
Parameters:
e - the link event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalLinkAdded(LinkEvent)

internalLinkRemoved

public void internalLinkRemoved(LinkEvent e)
Called after link removed event dispatching in the adapter.
Parameters:
e - the link event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalLinkRemoved(LinkEvent)

internalLinkUpdated

public void internalLinkUpdated(LinkEvent e)
Called after link updated event dispatching in the adapter.
Parameters:
e - the link event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalLinkUpdated(LinkEvent)

internalNodeAdded

public void internalNodeAdded(NodeEvent e)
Called after node added event dispatching in the adapter.
Parameters:
e - the node event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalNodeAdded(NodeEvent)

internalNodeRemoved

public void internalNodeRemoved(NodeEvent e)
Called after node removed event dispatching in the adapter.
Parameters:
e - the node event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalNodeRemoved(NodeEvent)

internalNodeUpdated

public void internalNodeUpdated(NodeEvent e)
Called after node updated event dispatching in the adapter.
Parameters:
e - the node event.
See Also:
IlsGraphDS2IlvGrapherAdapter.internalNodeUpdated(NodeEvent)

internalDataSourceConnected

public void internalDataSourceConnected(DSConnectionEvent e)
Called after the data source connection event.
Parameters:
e - the data source connection event.
See Also:
IlsGraphDS2IlvGrapherAdapter.dataSourceConnected(DSConnectionEvent)

internalDataSourceDisconnected

public void internalDataSourceDisconnected(DSConnectionEvent e)
Called after the data source disconnection event.
Parameters:
e - the data source disconnection event.
See Also:
IlsGraphDS2IlvGrapherAdapter.dataSourceDisconnected(DSConnectionEvent)

plugComponent

public Component plugComponent(Component component)
Called before graphic component is connected to the adapter.
Parameters:
component - generally a JTable instance.
Returns:
component unmodified.
See Also:
IlsGraphDS2IlvGrapherAdapter.plugComponent(Component)

unplugComponent

public Component unplugComponent(Component component)
Called before graphic component is disconnected from the adapter.
Parameters:
component - generally a IlvManagerView instance.
Returns:
component unmodified.
See Also:
IlsGraphDS2IlvGrapherAdapter.unplugComponent(Component)