Class AbstractMemory

    • Constructor Detail

      • AbstractMemory

        public AbstractMemory​(java.lang.String systemName)
      • AbstractMemory

        public AbstractMemory​(java.lang.String systemName,
                              java.lang.String userName)
    • Method Detail

      • getBeanType

        public java.lang.String getBeanType()
        Description copied from interface: NamedBean
        For instances in the code where we are dealing with just a bean and a message needs to be passed to the user or in a log.
        Specified by:
        getBeanType in interface NamedBean
        a string of the bean type, eg Turnout, Sensor etc
      • getValue

        public java.lang.Object getValue()
        Description copied from interface: Memory
        Get the stored value. The type of this depends on what was stored...
        Specified by:
        getValue in interface Memory
        the stored value
      • setValue

        public void setValue​(java.lang.Object v)
        Provide a general method for updating the report.
        Specified by:
        setValue in interface Memory
        v - the value to store
      • compareSystemNameSuffix

        public int compareSystemNameSuffix​(@Nonnull
                                           java.lang.String suffix1,
                                           java.lang.String suffix2,
                                           NamedBean n)
        Compare the suffix of this NamedBean's name with the suffix of the argument NamedBean's name for the NamedBean.compareTo(jmri.NamedBean) operation. This is intended to be a system-specific comparison that understands the various formats, etc. By default, does an alphanumeric-by-chunks comparison. Do a string comparison.
        Specified by:
        compareSystemNameSuffix in interface NamedBean
        compareSystemNameSuffix in class AbstractNamedBean
        suffix1 - The suffix for the 1st bean in the comparison
        suffix2 - The suffix for the 2nd bean in the comparison
        n - The other (second) NamedBean in the comparison
        -1,0,+1 for ordering if the names are well-formed; may not provide proper ordering if the names are not well-formed.