Enum SMSTPDU.Type

  • All Implemented Interfaces:
    Serializable, Comparable<SMSTPDU.Type>
    Enclosing class:
    SMSTPDU

    public static enum SMSTPDU.Type
    extends Enum<SMSTPDU.Type>
    Enumeration of PDU types.

    Each enumeration value has an associated TP-MTI value, but MTI values are not unique. There are 8 defined types of message, plus some reserved combinations, but only 2 bits to fit TP-MTI into. To work out which message type applies, the context of the PDU (i.e. type of relay-layer message) must be known.

    Reserved MTI/message combinations are represented by the SMS_RESERVED value.

    • Enum Constant Detail

      • SMS_SUBMIT

        public static final SMSTPDU.Type SMS_SUBMIT
        RP-MO-DATA relay-layer message, SMS-SUBMIT PDU, represented by SMSSubmit
      • SMS_COMMAND

        public static final SMSTPDU.Type SMS_COMMAND
        RP-MO-DATA relay-layer message, SMS-COMMAND PDU, represented by SMSCommand
      • SMS_DELIVER

        public static final SMSTPDU.Type SMS_DELIVER
        RP-MT-DATA relay-layer message, SMS-DELIVER PDU, represented by SMSDeliver
      • SMS_STATUS_REPORT

        public static final SMSTPDU.Type SMS_STATUS_REPORT
        RP-MT-DATA relay-layer message, SMS-STATUS-REPORT PDU, represented by SMSStatusReport
      • SMS_DELIVER_REPORT_ACK

        public static final SMSTPDU.Type SMS_DELIVER_REPORT_ACK
        RP-ACK relay-layer message, SMS-DELIVER-REPORT PDU, represented by SMSDeliverReportAck
      • SMS_SUBMIT_REPORT_ACK

        public static final SMSTPDU.Type SMS_SUBMIT_REPORT_ACK
        RP-ACK relay-layer message, SMS-SUBMIT-REPORT PDU, represented by SMSSubmitReportAck
      • SMS_DELIVER_REPORT_ERROR

        public static final SMSTPDU.Type SMS_DELIVER_REPORT_ERROR
        RP-ERROR relay-layer message, SMS-DELIVER-REPORT PDU, represented by SMSDeliverReportError
      • SMS_SUBMIT_REPORT_ERROR

        public static final SMSTPDU.Type SMS_SUBMIT_REPORT_ERROR
        RP-ERROR relay-layer message, SMS-SUBMIT-REPORT PDU, represented by SMSSubmitReportError
      • SMS_RESERVED

        public static final SMSTPDU.Type SMS_RESERVED
        Undefined/reserved MTI value for a given relay-layer message type, represented by SMSReserved
    • Method Detail

      • values

        public static SMSTPDU.Type[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (SMSTPDU.Type c : SMSTPDU.Type.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static SMSTPDU.Type valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • getMTI

        public int getMTI()
        Get the TP-MTI value for this message type. TP-MTI values are not unique across all message types!
        Returns:
        the TP-MTI value, or -1 if this is the SMS_RESERVED enumeration instance