Class IVEnumArray

java.lang.Object
org.yamcs.studio.data.vtype.IVMetadata
org.yamcs.studio.data.vtype.IVEnumArray
All Implemented Interfaces:
Alarm, Array, Enum, Time, VEnumArray, VType

public class IVEnumArray extends IVMetadata implements VEnumArray
  • Constructor Details

  • Method Details

    • getLabels

      public List<String> getLabels()
      Description copied from interface: Enum
      All the possible labels. Never null.
      Specified by:
      getLabels in interface Enum
      Returns:
      the possible values
    • getData

      public List<String> getData()
      Description copied from interface: Array
      Return the object containing the array data.

      This method will either return a List or a ListNumber depending of the array type. A collection is returned, instead of an array, so that the type implementation can be immutable or can at least try to prevent modifications. ListNumber has also several advantages over the Java arrays, including the ability to iterate the list regardless of numeric type.

      If a numeric array is actually needed, refer to CollectionNumbers.

      Specified by:
      getData in interface Array
      Specified by:
      getData in interface VEnumArray
      Returns:
      the array data
    • getIndexes

      public ListInt getIndexes()
      Description copied from interface: VEnumArray
      Returns the indexes instead of the labels.
      Specified by:
      getIndexes in interface VEnumArray
      Returns:
      an array of indexes
    • getSizes

      public ListInt getSizes()
      Description copied from interface: Array
      The shape of the multidimensional array.

      The size of the returned list will be the number of the dimension of the array. Each number represents the size of each dimension. The total number of elements in the array is therefore the product of all the numbers in the list returned.

      Specified by:
      getSizes in interface Array
      Returns:
      the dimension sizes
    • toString

      public String toString()
      Overrides:
      toString in class Object