Package mondrian.rolap.agg
Class GroupingSetsList
- java.lang.Object
-
- mondrian.rolap.agg.GroupingSetsList
-
final class GroupingSetsList extends java.lang.Object
Class for using GROUP BY GROUPING SETS sql query.For example, suppose we have the 3 grouping sets (a, b, c), (a, b) and (b, c).
- detailed grouping set -> (a, b, c)
- rolled-up grouping sets -> (a, b), (b, c)
- rollup columns -> c, a (c for (a, b) and a for (b, c))
- rollup columns bitkey ->
(a, b, c) grouping set represented as 0, 0, 0
(a, b) grouping set represented as 0, 0, 1
(b, c) grouping set represented as 1, 0, 0
- Since:
- 24 May 2007
- Author:
- Thiyagu
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
GroupingSetsList.Cohort
Collection ofSegmentDataset
that have the same dimensionality and identical axis values.
-
Constructor Summary
Constructors Constructor Description GroupingSetsList(java.util.List<GroupingSet> groupingSets)
Creates a GroupingSetsList.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
findGroupingFunctionIndex(int columnIndex)
SegmentAxis[]
getDefaultAxes()
RolapStar.Column[]
getDefaultColumns()
protected GroupingSet
getDefaultGroupingSet()
BitKey
getDefaultLevelBitKey()
BitKey
getDefaultMeasureBitKey()
StarColumnPredicate[]
getDefaultPredicates()
java.util.List<Segment>
getDefaultSegments()
int
getGroupingBitKeyIndex()
(package private) java.util.List<RolapStar.Column[]>
getGroupingColumnsList(java.util.List<GroupingSet> groupingSets)
java.util.List<GroupingSet>
getGroupingSets()
java.util.List<RolapStar.Column[]>
getGroupingSetsColumns()
java.util.List<RolapStar.Column>
getRollupColumns()
java.util.List<BitKey>
getRollupColumnsBitKeyList()
java.util.List<GroupingSet>
getRollupGroupingSets()
RolapStar
getStar()
boolean
useGroupingSets()
-
-
-
Constructor Detail
-
GroupingSetsList
public GroupingSetsList(java.util.List<GroupingSet> groupingSets)
Creates a GroupingSetsList.First element of the groupingSets list should be the detailed grouping set (default grouping set), followed by grouping sets which can be rolled-up.
- Parameters:
groupingSets
- List of groups of columns
-
-
Method Detail
-
getGroupingColumnsList
java.util.List<RolapStar.Column[]> getGroupingColumnsList(java.util.List<GroupingSet> groupingSets)
-
getGroupingBitKeyIndex
public int getGroupingBitKeyIndex()
-
getRollupColumns
public java.util.List<RolapStar.Column> getRollupColumns()
-
getGroupingSetsColumns
public java.util.List<RolapStar.Column[]> getGroupingSetsColumns()
-
getRollupColumnsBitKeyList
public java.util.List<BitKey> getRollupColumnsBitKeyList()
-
useGroupingSets
public boolean useGroupingSets()
-
findGroupingFunctionIndex
public int findGroupingFunctionIndex(int columnIndex)
-
getDefaultAxes
public SegmentAxis[] getDefaultAxes()
-
getDefaultPredicates
public StarColumnPredicate[] getDefaultPredicates()
-
getDefaultGroupingSet
protected GroupingSet getDefaultGroupingSet()
-
getDefaultColumns
public RolapStar.Column[] getDefaultColumns()
-
getDefaultSegments
public java.util.List<Segment> getDefaultSegments()
-
getDefaultLevelBitKey
public BitKey getDefaultLevelBitKey()
-
getDefaultMeasureBitKey
public BitKey getDefaultMeasureBitKey()
-
getStar
public RolapStar getStar()
-
getGroupingSets
public java.util.List<GroupingSet> getGroupingSets()
-
getRollupGroupingSets
public java.util.List<GroupingSet> getRollupGroupingSets()
-
-