Package ucar.ma2

Class StructureMembers


  • public final class StructureMembers
    extends Object
    A Collection of members contained in a StructureData. TODO make immutable
    • Constructor Detail

      • StructureMembers

        @Deprecated
        public StructureMembers​(String name)
        Deprecated.
        use Builder
      • StructureMembers

        @Deprecated
        public StructureMembers​(StructureMembers from)
        Deprecated.
        use toBuilder().build(false) to make a copy with no data
    • Method Detail

      • getName

        public String getName()
        Get the StructureMembers' name.
      • hideMember

        @Deprecated
        public int hideMember​(StructureMembers.Member m)
        Deprecated.
        use Builder
        Remove the given member
        Parameters:
        m - member
        Returns:
        position that it used to occupy, or -1 if not found
      • getStructureSize

        public int getStructureSize()
        Get the total size of the Structure in bytes.
        Returns:
        the total size of the Structure in bytes.
      • setStructureSize

        @Deprecated
        public void setStructureSize​(int structureSize)
        Deprecated.
        use Builder
        Set the total size of the Structure in bytes.
      • getMembers

        public com.google.common.collect.ImmutableList<StructureMembers.Member> getMembers()
        Get the list of Member objects.
      • getMemberNames

        public com.google.common.collect.ImmutableList<String> getMemberNames()
        Get the names of the members.
      • getMember

        public StructureMembers.Member getMember​(int index)
        Get the index-th member
        Parameters:
        index - of member
        Returns:
        Member
      • toBuilder

        public StructureMembers.Builder toBuilder​(boolean wantsData)
        Turn into a mutable Builder. Can use toBuilder().build(wantsData) to copy.