All Packages  Class Hierarchy  This Package  Previous  Next  Index  WEKA's home

Class weka.gui.beans.BeanConnection

java.lang.Object
    |
    +----weka.gui.beans.BeanConnection

public class BeanConnection
extends java.lang.Object
implements java.io.Serializable
Class for encapsulating a connection between two beans. Also maintains a list of all connections

Version:
$Revision: 1.2 $
Author:
Mark Hall

Variable Index

 o CONNECTIONS
The list of connections

Constructor Index

 o BeanConnection(BeanInstance, BeanInstance, EventSetDescriptor)
Creates a new BeanConnection instance.

Method Index

 o getClosestConnections(Point, int)
Return a list of connections within some delta of a point
 o getConnections()
Returns the list of connections
 o paintConnections(Graphics)
Renders the connections and their names on the supplied graphics context
 o remove()
Remove this connection
 o removeConnections(BeanInstance)
Remove all connections for a bean.
 o reset()
Reset the list of connections
 o setConnections(Vector)
Describe setConnections method here.

Field Detail

 o CONNECTIONS
public static java.util.Vector CONNECTIONS
          The list of connections

Constructor Detail

 o BeanConnection
public BeanConnection(BeanInstance source,
                      BeanInstance target,
                      java.beans.EventSetDescriptor esd)
          Creates a new BeanConnection instance.
Parameters:
source - the source bean
target - the target bean
esd - the EventSetDescriptor for the connection

Method Detail

 o reset
public static void reset()
          Reset the list of connections
 o getConnections
public static java.util.Vector getConnections()
          Returns the list of connections
Returns:
the list of connections
 o setConnections
public static void setConnections(java.util.Vector connections)
          Describe setConnections method here.
Parameters:
connections - a Vector value
 o paintConnections
public static void paintConnections(java.awt.Graphics gx)
          Renders the connections and their names on the supplied graphics context
Parameters:
gx - a Graphics value
 o getClosestConnections
public static java.util.Vector getClosestConnections(java.awt.Point pt,
                                           int delta)
          Return a list of connections within some delta of a point
Parameters:
pt - the point at which to look for connections
delta - connections have to be within this delta of the point
Returns:
a list of connections
 o removeConnections
public static void removeConnections(BeanInstance instance)
          Remove all connections for a bean. If the bean is a target for receiving events then it gets deregistered from the corresonding source bean. If the bean is a source of events then all targets implementing BeanCommon are notified via their disconnectionNotification methods that the source (and hence the connection) is going away.
Parameters:
instance - the bean to remove connections to/from
 o remove
public void remove()
          Remove this connection

All Packages  Class Hierarchy  This Package  Previous  Next  Index  WEKA's home