001package jmri;
002
003/**
004 * This interface specifies that an object provides a report value suitable
005 * for display in an on-screen reporter.
006 * <br>
007 * <hr>
008 * This file is part of JMRI.
009 * <p>
010 * JMRI is free software; you can redistribute it and/or modify it under the
011 * terms of version 2 of the GNU General Public License as published by the Free
012 * Software Foundation. See the "COPYING" file for a copy of this license.
013 * <p>
014 * JMRI is distributed in the hope that it will be useful, but WITHOUT ANY
015 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
016 * A PARTICULAR PURPOSE. See the GNU General Public License for more details.
017 *
018 * @author Paul Bender Copyright (C) 2019
019 * @see jmri.Reporter
020 * @since 4.15.3
021 */
022public interface Reportable {
023
024     /**
025      * Provide a string representation of the object, possibly including state
026      * information, suitable for display in an on-screen reporter. A default 
027      * implementation provided here calls toString(), which may not be 
028      * appropriate in all cases. 
029      *
030      * @return a report string representing the Object.
031      */
032     default String toReportString(){
033        return toString();
034     }
035
036}