Package mondrian.rolap.agg
Class SparseSegmentBody
- java.lang.Object
-
- mondrian.rolap.agg.AbstractSegmentBody
-
- mondrian.rolap.agg.SparseSegmentBody
-
- All Implemented Interfaces:
Serializable,SegmentBody
class SparseSegmentBody extends AbstractSegmentBody
Implementation of a segment body which stores the data of a sparse segment data set into a dense array of java objects.- Author:
- LBoudreau
-
-
Field Summary
Fields Modifier and Type Field Description (package private) Object[]data(package private) CellKey[]keys-
Fields inherited from class mondrian.rolap.agg.AbstractSegmentBody
axisValueSets
-
-
Constructor Summary
Constructors Constructor Description SparseSegmentBody(Map<CellKey,Object> dataToSave, List<Pair<SortedSet<Comparable>,Boolean>> axes)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ObjectgetObject(int i)protected intgetSize()Returns the overall amount of stored elements, including those, that are considered to be null.Map<CellKey,Object>getValueMap()Converts contents of this segment into a cellkey/value map.-
Methods inherited from class mondrian.rolap.agg.AbstractSegmentBody
getAxisValueSets, getEffectiveSize, getNullAxisFlags, getNullValueIndicators, getValueArray
-
-
-
-
Method Detail
-
getSize
protected int getSize()
Description copied from class:AbstractSegmentBodyReturns the overall amount of stored elements, including those, that are considered to be null.- Specified by:
getSizein classAbstractSegmentBody- Returns:
- the size of stored data
-
getObject
protected Object getObject(int i)
- Specified by:
getObjectin classAbstractSegmentBody
-
getValueMap
public Map<CellKey,Object> getValueMap()
Description copied from interface:SegmentBodyConverts contents of this segment into a cellkey/value map. Use only for sparse segments.- Specified by:
getValueMapin interfaceSegmentBody- Overrides:
getValueMapin classAbstractSegmentBody- Returns:
- Map containing cell values keyed by their coordinates
-
-