Class SessionSupport

java.lang.Object
edu.cmu.tetrad.session.SessionSupport

public class SessionSupport extends Object
Handles firing of SessionSupport events to listeners.
Author:
josephramsey
  • Constructor Details

    • SessionSupport

      public SessionSupport(Object source)
      Constructs a new session support object for the given source object. The source object will be stamped on all fired events.
  • Method Details

    • addSessionListener

      public void addSessionListener(SessionListener l)
      Adds a listener for SessionEvents.
    • removeSessionListener

      public void removeSessionListener(SessionListener l)
      Removes a listener for SessionEvents.
    • fireNodeAdded

      public void fireNodeAdded(SessionNode node)
      Fires an event indicating that a session node has been added to the session.
    • fireNodeRemoved

      public void fireNodeRemoved(SessionNode node)
      Fires an event indicating that a sesison node has been removed from the session.
    • fireParentAdded

      public void fireParentAdded(SessionNode parent, SessionNode child)
      Fires an event indicating that a parent has been added from the given parent to the given child session node in the session.
    • fireParentRemoved

      public void fireParentRemoved(SessionNode parent, SessionNode child)
      Fires an event indicating that a parent has been removed from the given parent to the given child session node in the session.
    • fireModelCreated

      public void fireModelCreated(SessionNode node)
      Fires an event indicating that a new model has been created for the given session node in the session.
    • fireModelDestroyed

      public void fireModelDestroyed(SessionNode node)
      Fires an event indicating that the model for the given session node in the session has been destroyed.
    • fireModelUnclear

      public void fireModelUnclear(SessionNode node)
      Fires an event indicating that the model for the given session node in the session has been destroyed.
    • fireRepetitionChanged

      public void fireRepetitionChanged(SessionNode node)
      Fires an event indicating that the model for the given session node in the session has been destroyed.
    • fireExecutionStarted

      public void fireExecutionStarted()
      Fires an event indicating that an new execution of a node has begun.
    • fireAddingEdge

      public void fireAddingEdge()
      Fires an event indicating that an edge is about to be added.
    • fireSessionEvent

      public void fireSessionEvent(SessionEvent event)
      Fires a session event. Calls the correct method on the listener for the type of session event it is. All event fired with this session support are stamped with the source object of this session support.
    • fireSessionEvent

      public void fireSessionEvent(SessionEvent event, boolean restamp)
      Fires a session event. Calls the correct method on the listener for the type of session event it is. Events are restamped with the source object of this session support if restamp is true.
      Parameters:
      event - the session event to fire.
      restamp - true iff the source of this event should be set to the source of this SessionSupport object.