Package org.h2.command.query
Class SelectGroups.Grouped
java.lang.Object
org.h2.command.query.SelectGroups
org.h2.command.query.SelectGroups.Grouped
- Enclosing class:
SelectGroups
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ValueRowKey into groupByData that produces currentGroupByExprData.Cursor fornext()method.Map of group-by key to group-by expression data e.g.private final int[]Fields inherited from class org.h2.command.query.SelectGroups
currentGroupByExprData, currentGroupRowId, expressions, session -
Constructor Summary
ConstructorsConstructorDescriptionGrouped(SessionLocal session, ArrayList<Expression> expressions, int[] groupIndex) -
Method Summary
Modifier and TypeMethodDescriptionvoiddone()Invoked after all source rows are evaluated.next()Returns the key of the next group.voidInvoked for each source row to evaluate group key and setup all necessary data for aggregates.voidremove()Removes the data for the current key.voidreset()Resets this group data for reuse.voidResets this group data for reuse in lazy mode.(package private) voidUpdate group-by data specified by implementation.Methods inherited from class org.h2.command.query.SelectGroups
createRow, getCurrentGroupExprData, getCurrentGroupRowId, getInstance, getWindowExprData, isCurrentGroup, nextLazyGroup, nextLazyRow, setCurrentGroupExprData, setWindowExprData
-
Field Details
-
groupIndex
private final int[] groupIndex -
groupByData
Map of group-by key to group-by expression data e.g. AggregateData -
currentGroupsKey
Key into groupByData that produces currentGroupByExprData. Not used in lazy mode. -
cursor
Cursor fornext()method.
-
-
Constructor Details
-
Grouped
Grouped(SessionLocal session, ArrayList<Expression> expressions, int[] groupIndex)
-
-
Method Details
-
reset
public void reset()Description copied from class:SelectGroupsResets this group data for reuse.- Overrides:
resetin classSelectGroups
-
nextSource
public void nextSource()Description copied from class:SelectGroupsInvoked for each source row to evaluate group key and setup all necessary data for aggregates.- Specified by:
nextSourcein classSelectGroups
-
updateCurrentGroupExprData
void updateCurrentGroupExprData()Description copied from class:SelectGroupsUpdate group-by data specified by implementation.- Specified by:
updateCurrentGroupExprDatain classSelectGroups
-
done
public void done()Description copied from class:SelectGroupsInvoked after all source rows are evaluated.- Overrides:
donein classSelectGroups
-
next
Description copied from class:SelectGroupsReturns the key of the next group.- Specified by:
nextin classSelectGroups- Returns:
- the key of the next group, or null
-
remove
public void remove()Description copied from class:SelectGroupsRemoves the data for the current key.- Overrides:
removein classSelectGroups- See Also:
-
resetLazy
public void resetLazy()Description copied from class:SelectGroupsResets this group data for reuse in lazy mode.- Overrides:
resetLazyin classSelectGroups
-