001package jmri.managers;
002
003import javax.annotation.Nonnull;
004import jmri.Manager;
005import jmri.Meter;
006import jmri.MeterManager;
007import jmri.SystemConnectionMemo;
008
009/**
010 * Default implementation of a MeterManager.
011 *
012 * @author Dave Duchamp      Copyright (C) 2004
013 * @author Daniel Bergqvist  Copyright (C) 2020
014 */
015public class AbstractMeterManager extends AbstractManager<Meter>
016        implements MeterManager {
017
018    /**
019     * Create a new MeterManager instance.
020     * 
021     * @param memo the system connection
022     */
023    public AbstractMeterManager(SystemConnectionMemo memo) {
024        super(memo);
025    }
026
027    /** {@inheritDoc} */
028    @Override
029    public int getXMLOrder() {
030        return Manager.METERS;
031    }
032
033    /**
034     * {@inheritDoc}
035     */
036    @Override
037    public char typeLetter() {
038        return 'V';
039    }
040
041    /**
042     * Get bean type handled.
043     *
044     * @return a string for the type of object handled by this manager
045     */
046    @Override
047    @Nonnull
048    public String getBeanTypeHandled(boolean plural) {
049        return Bundle.getMessage(plural ? "BeanNameMeters" : "BeanNameMeter");
050    }
051
052    /**
053     * {@inheritDoc}
054     */
055    @Override
056    public Class<Meter> getNamedBeanClass() {
057        return Meter.class;
058    }
059
060//    private final static Logger log = LoggerFactory.getLogger(AbstractMeterManager.class);
061
062}