001package jmri.jmrix.xpa;
002
003/**
004 * Define interface for sending and receiving messages from an XpressNet System
005 * using an XPA and a modem.
006 *
007 * @author Paul Bender Copyright (C) 2004
008 */
009public interface XpaInterface {
010
011    void addXpaListener(XpaListener l);
012
013    void removeXpaListener(XpaListener l);
014
015    /**
016     * Test operational status of interface.
017     *
018     * @return true if the interface implementation is operational.
019     */
020    boolean status();
021
022    /**
023     * Send a message through the interface.
024     *
025     * @param m Message to be sent.
026     * @param l Listener to be notified of reply.
027     */
028    void sendXpaMessage(XpaMessage m, XpaListener l);
029}