程序包 weka.gui.beans

类 BeanConnection

java.lang.Object
weka.gui.beans.BeanConnection
所有已实现的接口:
Serializable

public class BeanConnection extends Object implements Serializable
Class for encapsulating a connection between two beans. Also maintains a list of all connections
版本:
$Revision: 7059 $
作者:
Mark Hall
另请参阅:
  • 字段详细资料

    • CONNECTIONS

      public static Vector CONNECTIONS
      The list of connections
  • 构造器详细资料

    • BeanConnection

      public BeanConnection(BeanInstance source, BeanInstance target, EventSetDescriptor esd)
      Creates a new BeanConnection instance.
      参数:
      source - the source bean
      target - the target bean
      esd - the EventSetDescriptor for the connection be displayed
  • 方法详细资料

    • reset

      public static void reset()
      Reset the list of connections
    • getConnections

      public static Vector getConnections()
      Returns the list of connections
      返回:
      the list of connections
    • setConnections

      public static void setConnections(Vector connections)
      Describe setConnections method here.
      参数:
      connections - a Vector value
    • associatedConnections

      public static Vector associatedConnections(Vector subFlow)
      Returns a vector of BeanConnections associated with the supplied vector of BeanInstances, i.e. all connections that exist between those BeanInstances in the subFlow.
      参数:
      subFlow - a Vector of BeanInstances
      返回:
      a Vector of BeanConnections
    • inputs

      public static Vector inputs(Vector subset)
      Returns a vector of BeanInstances that can be considered as inputs (or the left-hand side of a sub-flow)
      参数:
      subset - the sub-flow to examine
      返回:
      a Vector of inputs to the sub-flow
    • outputs

      public static Vector outputs(Vector subset)
      Returns a vector of BeanInstances that can be considered as outputs (or the right-hand side of a sub-flow)
      参数:
      subset - the sub-flow to examine
      返回:
      a Vector of outputs of the sub-flow
    • paintConnections

      public static void paintConnections(Graphics gx)
      Renders the connections and their names on the supplied graphics context
      参数:
      gx - a Graphics value
    • getClosestConnections

      public static Vector getClosestConnections(Point pt, int delta)
      Return a list of connections within some delta of a point
      参数:
      pt - the point at which to look for connections
      delta - connections have to be within this delta of the point
      返回:
      a list of connections
    • 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.
      参数:
      instance - the bean to remove connections to/from
    • doMetaConnection

      public static void doMetaConnection(BeanInstance source, BeanInstance target, EventSetDescriptor esd, JComponent displayComponent)
    • setHidden

      public void setHidden(boolean hidden)
      Make this connection invisible on the display
      参数:
      hidden - true to make the connection invisible
    • isHidden

      public boolean isHidden()
      Returns true if this connection is invisible
      返回:
      true if connection is invisible
    • remove

      public void remove()
      Remove this connection
    • getSource

      public BeanInstance getSource()
      returns the source BeanInstance for this connection
      返回:
      a BeanInstance value
    • getTarget

      public BeanInstance getTarget()
      Returns the target BeanInstance for this connection
      返回:
      a BeanInstance value
    • getEventName

      public String getEventName()
      Returns the name of the event for this conncetion
      返回:
      the name of the event for this connection