Class CCInbandInfo

  • All Implemented Interfaces:
    DataObject, Serializable

    public class CCInbandInfo
    extends AbstractFieldsObject
    API for CC-DataTypes.InbandInfo. Generated from the following ASN.1 type definition.
     InbandInfo ::=
         SEQUENCE {
             messageID           MessageID,
             numberOfRepetitions INTEGER (1..127) OPTIONAL,
             duration            INTEGER (0..32767) OPTIONAL,
             interval            INTEGER (0..32767) OPTIONAL
         }
     

    Used as field type by CCInformationToSend.

    See Also:
    Serialized Form
    • Constructor Detail

      • CCInbandInfo

        public CCInbandInfo()
        Constructs an object with uninitialised state.
    • Method Detail

      • copyOf

        public static CCInbandInfo copyOf​(CCInbandInfo from)
        Creates a new object of this type, cloning the values of common fields from the given object of any subclass of the same base type.
        Parameters:
        from - the object from which to copy
        Returns:
        CCInbandInfo
      • getDuration

        public int getDuration()
        Gets the value of the field duration.
        Returns:
        value of field duration
      • getFieldAccessors

        public static FieldAccessor[] getFieldAccessors()
        Gets a new array of the accessors for fields of this type.
        Returns:
        FieldAccessor[]
      • getFieldsMap

        public Map<String,​Object> getFieldsMap​(boolean withAbsents)
        Gets a Map from field-name to field-value. For a field of primitive type, the field-value is boxed. For an absent optional field, the field-value is AbstractFieldsObject.FIELD_ABSENT. For an unitialised mandatory field, the field-value is AbstractFieldsObject.FIELD_UNINITIALISED.
        Specified by:
        getFieldsMap in class AbstractFieldsObject
        Parameters:
        withAbsents - whether to put absent optional fields into Map
        Returns:
        Map from field-name to field-value
      • getInterval

        public int getInterval()
        Gets the value of the field interval.
        Returns:
        value of field interval
      • getMessageID

        public CCMessageID getMessageID()
        Gets the value of the field messageID.
        Returns:
        value of field messageID, or null if not present
      • getNumberOfRepetitions

        public int getNumberOfRepetitions()
        Gets the value of the field numberOfRepetitions.
        Returns:
        value of field numberOfRepetitions
      • hasDuration

        public boolean hasDuration()
        Tests whether the field duration has a value.
        Returns:
        whether the field duration has a value
      • hasInterval

        public boolean hasInterval()
        Tests whether the field interval has a value.
        Returns:
        whether the field interval has a value
      • hasMessageID

        public boolean hasMessageID()
        Tests whether the field messageID has a value.
        Returns:
        whether the field messageID has a value
      • hasNumberOfRepetitions

        public boolean hasNumberOfRepetitions()
        Tests whether the field numberOfRepetitions has a value.
        Returns:
        whether the field numberOfRepetitions has a value
      • setDuration

        public CCInbandInfo setDuration​(int value)
                                 throws IllegalStateException
        Sets the value of the field duration and marks the field as present.
        Parameters:
        value - the new value for the field
        Returns:
        this
        Throws:
        IllegalStateException - if this instance has been marked as read-only
      • setDurationPresent

        public CCInbandInfo setDurationPresent​(boolean flag)
                                        throws IllegalStateException
        Sets the presence or absence of the optional field duration.
        Parameters:
        flag - either true if the field should be marked as present or false if the field should be marked as absent
        Returns:
        this
        Throws:
        IllegalStateException - if this instance has been marked as read-only
      • setInterval

        public CCInbandInfo setInterval​(int value)
                                 throws IllegalStateException
        Sets the value of the field interval and marks the field as present.
        Parameters:
        value - the new value for the field
        Returns:
        this
        Throws:
        IllegalStateException - if this instance has been marked as read-only
      • setIntervalPresent

        public CCInbandInfo setIntervalPresent​(boolean flag)
                                        throws IllegalStateException
        Sets the presence or absence of the optional field interval.
        Parameters:
        flag - either true if the field should be marked as present or false if the field should be marked as absent
        Returns:
        this
        Throws:
        IllegalStateException - if this instance has been marked as read-only
      • setNumberOfRepetitions

        public CCInbandInfo setNumberOfRepetitions​(int value)
                                            throws IllegalStateException
        Sets the value of the field numberOfRepetitions and marks the field as present.
        Parameters:
        value - the new value for the field
        Returns:
        this
        Throws:
        IllegalStateException - if this instance has been marked as read-only
      • setNumberOfRepetitionsPresent

        public CCInbandInfo setNumberOfRepetitionsPresent​(boolean flag)
                                                   throws IllegalStateException
        Sets the presence or absence of the optional field numberOfRepetitions.
        Parameters:
        flag - either true if the field should be marked as present or false if the field should be marked as absent
        Returns:
        this
        Throws:
        IllegalStateException - if this instance has been marked as read-only