001package jmri.jmrit.symbolicprog;
002
003/**
004 * Define capability to watch other things and "Qualify" CVs and Variables.
005 *
006 * @author Bob Jacobsen Copyright (C) 2014
007 *
008 */
009public interface Qualifier {
010
011    /**
012     * Process the current value and do whatever is needed.
013     */
014    void update();
015
016    /**
017     * Check whether this Qualifier is currently in the OK, qualified-to-act
018     * state.
019     *
020     * @return true if this Qualifier is currently saying OK
021     */
022    boolean currentDesiredState();
023
024    /**
025     * Drive the available or not state of the qualified object.
026     * <p>
027     * Subclasses implement this to control a specific type of qualified object,
028     * like a Variable or Pane.
029     * @param enable true to drive, else false.
030     */
031    void setWatchedAvailable(boolean enable);
032
033}