001package jmri.jmrix.dcc4pc;
002
003/**
004 * Define interface for sending and receiving messages to the DCC4PC computer
005 * interface device.
006 *
007 * @author Kevin Dickerson Copyright 2012
008 * @author Bob Jacobsen Copyright (C) 2001
009 * 
010 */
011public interface Dcc4PcInterface {
012
013    void addDcc4PcListener(Dcc4PcListener l);
014
015    void removeDcc4PcListener(Dcc4PcListener l);
016
017    /**
018     * Test operational status of interface.
019     *
020     * @return true if interface implementation is operational.
021     */
022    boolean status();
023
024    /**
025     * Send a message through the interface.
026     *
027     * @param m Message to be sent.
028     * @param l Listener to be notified of reply.
029     */
030    void sendDcc4PcMessage(Dcc4PcMessage m, Dcc4PcListener l);
031}