Class AbstractSegmentBody

    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.SortedSet<java.lang.Comparable>[] axisValueSets  
    • Constructor Summary

      Constructors 
      Constructor Description
      AbstractSegmentBody​(java.util.List<Pair<java.util.SortedSet<java.lang.Comparable>,​java.lang.Boolean>> axes)  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.SortedSet<java.lang.Comparable>[] getAxisValueSets()
      Returns the cached axis value sets to be used as an initializer for the segment's axis.
      protected int getEffectiveSize()
      Returns the amount of non-null elements.
      boolean[] getNullAxisFlags()
      Returns an array of boolean values which identify which axis of the cached segment contained null values.
      java.util.BitSet getNullValueIndicators()
      Returns a bit-set indicating whether values are null.
      protected abstract java.lang.Object getObject​(int i)  
      protected abstract int getSize()
      Returns the overall amount of stored elements, including those, that are considered to be null.
      java.lang.Object getValueArray()
      Returns an array of values.
      java.util.Map<CellKey,​java.lang.Object> getValueMap()
      Converts contents of this segment into a cellkey/value map.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • axisValueSets

        protected final java.util.SortedSet<java.lang.Comparable>[] axisValueSets
    • Constructor Detail

      • AbstractSegmentBody

        public AbstractSegmentBody​(java.util.List<Pair<java.util.SortedSet<java.lang.Comparable>,​java.lang.Boolean>> axes)
    • Method Detail

      • getAxisValueSets

        public java.util.SortedSet<java.lang.Comparable>[] getAxisValueSets()
        Description copied from interface: SegmentBody
        Returns the cached axis value sets to be used as an initializer for the segment's axis.
        Specified by:
        getAxisValueSets in interface SegmentBody
        Returns:
        An array of SortedSets which was cached previously.
      • getNullAxisFlags

        public boolean[] getNullAxisFlags()
        Description copied from interface: SegmentBody
        Returns an array of boolean values which identify which axis of the cached segment contained null values.
        Specified by:
        getNullAxisFlags in interface SegmentBody
        Returns:
        An array of boolean values.
      • getValueMap

        public java.util.Map<CellKey,​java.lang.Object> getValueMap()
        Description copied from interface: SegmentBody
        Converts contents of this segment into a cellkey/value map. Use only for sparse segments.
        Specified by:
        getValueMap in interface SegmentBody
        Returns:
        Map containing cell values keyed by their coordinates
      • getValueArray

        public java.lang.Object getValueArray()
        Description copied from interface: SegmentBody
        Returns an array of values.

        Use only for dense segments.

        Specified by:
        getValueArray in interface SegmentBody
        Returns:
        An array of values
      • getNullValueIndicators

        public java.util.BitSet getNullValueIndicators()
        Description copied from interface: SegmentBody
        Returns a bit-set indicating whether values are null. The ordinals in the bit-set correspond to the indexes in the array returned from SegmentBody.getValueArray().

        Use only for dense segments of native values.

        Specified by:
        getNullValueIndicators in interface SegmentBody
        Returns:
        Indicators
      • getSize

        protected abstract int getSize()
        Returns the overall amount of stored elements, including those, that are considered to be null.
        Returns:
        the size of stored data
      • getEffectiveSize

        protected int getEffectiveSize()
        Returns the amount of non-null elements. This amount is equal to number of elements that getValueMap().entrySet().iterator() is returned. By default the method executes getSize().
        Returns:
        the effective size of stored data
      • getObject

        protected abstract java.lang.Object getObject​(int i)