Class DccAddressVarHandler

  • public class DccAddressVarHandler
    extends java.lang.Object
    Encapulates DCC address handling logic in one place

    Expects one or more of the variables called:

    • primaryAddr - Short Address
    • extendAddr - Long Address
    • addMode - Address Format (an Enum variable to select)
    and handles the cases where:
    • All three are present - the normal advanced decoder case
    • Short Address is present and Long Address is not
    • Long Address is present and Short Address is not
    At least one of Short Address and Long Address must be present!