Class AggregateDataType

    • Method Detail

      • getTypeAsString

        public String getTypeAsString()
        Description copied from interface: DataType
        String which represents the type. This string will be presented to the users of the system.
        Specified by:
        getTypeAsString in interface DataType
        Returns:
      • getMember

        public Member getMember​(String name)
        Returns a member on the given name. If no such member is present return null
        Parameters:
        name - the name of the member to be returned
        Returns:
        the member with the given name
      • getMemberList

        public List<Member> getMemberList()
      • getValueType

        public Yamcs.Value.Type getValueType()
        Description copied from interface: DataType
        Return the expected Value type of an engineering value conforming to this XTCE data type
        Specified by:
        getValueType in interface DataType
        Returns:
      • getMember

        public Member getMember​(String[] path)
        Returns a member in a hierarchical aggregate. It is equivalent with a chained call of getMember(String):
         getMember(path[0]).getMember(path[1])...getMember(path[n])
         
        assuming that all the elements on the path exist.
        Parameters:
        path - - the path to be traversed. Its length has to be at least 1 - otherwise an IllegalArgumentException will be thrown.
        Returns:
        the member obtained by traversing the path or null if not such member exist.
      • getMemberNames

        public AggregateMemberNames getMemberNames()
        Returns:
        the (unique) object encoding the member names
      • numMembers

        public int numMembers()
      • getMember

        public Member getMember​(int idx)
      • parseString

        public Map<String,​Object> parseString​(String initialValue)
        Parse the initial value as a JSON string.

        This allows to specify only partially the values, the rest are copied from the member initial value or the type definition (an exception is thrown if there is any member for which the value cannot be determined).

        Specified by:
        parseString in interface DataType
        Parameters:
        initialValue -
        Returns:
        a map containing the values for all members.
        Throws:
        IllegalArgumentException - if the string cannot be parsed or if values cannot be determined for all members