|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.extjs.gxt.ui.client.event.BaseObservable
com.extjs.gxt.ui.client.widget.grid.GridView
com.extjs.gxt.ui.client.widget.grid.GroupingView
public class GroupingView
GridView
that groups data based on a GroupingStore
.
Nested Class Summary | |
---|---|
class |
GroupingView.GroupingViewImages
|
Nested classes/interfaces inherited from class com.extjs.gxt.ui.client.widget.grid.GridView |
---|
GridView.GridViewImages |
Field Summary | |
---|---|
protected boolean |
enableGrouping
|
protected boolean |
isUpdating
|
protected java.util.Map<java.lang.String,java.lang.String> |
map
|
Fields inherited from class com.extjs.gxt.ui.client.widget.grid.GridView |
---|
activeHdIndex, autoFill, borderWidth, cm, columnListener, deferEmptyText, ds, el, emptyText, enableHdMenu, enableRowBody, focusEl, focusEnabled, footer, forceFit, grid, header, headerColumnIndex, headerDisabled, images, innerHd, lastViewWidth, listener, mainBody, mainHd, mainWrap, overRow, preventScrollToTopOnRefresh, scroller, scrollOffset, selectable, sortState, splitterWidth, templates, userResized, vbar, viewConfig, widgetList |
Constructor Summary | |
---|---|
GroupingView()
|
Method Summary | |
---|---|
void |
collapseAllGroups()
Collapses all groups. |
protected Menu |
createContextMenu(int colIndex)
|
protected void |
doGroupEnd(java.lang.StringBuilder buf,
GroupColumnData g,
java.util.List<ColumnData> cs,
int colCount)
|
protected void |
doGroupStart(java.lang.StringBuilder buf,
GroupColumnData g,
java.util.List<ColumnData> cs,
int colCount)
|
protected java.lang.String |
doRender(java.util.List<ColumnData> cs,
java.util.List<ModelData> rows,
int startRow,
int colCount,
boolean stripe)
|
void |
expandAllGroups()
Expands all groups. |
protected com.google.gwt.dom.client.Element |
findGroup(com.google.gwt.dom.client.Element el)
|
protected java.lang.String |
getGroup(java.lang.Object value,
ModelData m,
int rowIndex,
int colIndex,
ListStore<ModelData> ds)
|
protected java.lang.String |
getGroupField()
|
protected java.lang.String |
getGroupId(java.lang.String gidPrefix,
java.lang.String groupField,
java.lang.String group)
|
GridGroupRenderer |
getGroupRenderer()
Returns the group renderer. |
protected com.google.gwt.dom.client.Element |
getGroupRow(com.google.gwt.dom.client.Element group,
int rowIndex)
|
protected int |
getGroupRowCount(com.google.gwt.dom.client.Element group)
|
protected com.google.gwt.dom.client.NodeList<com.google.gwt.dom.client.Element> |
getGroupRows(com.google.gwt.dom.client.Element group)
|
com.google.gwt.dom.client.NodeList<com.google.gwt.dom.client.Element> |
getGroups()
Returns the group elements. |
GroupingView.GroupingViewImages |
getImages()
Returns the images used by grid. |
protected com.google.gwt.dom.client.NodeList<com.google.gwt.dom.client.Element> |
getRows()
|
protected void |
init(Grid grid)
Initializes the view. |
void |
initData(ListStore ds,
ColumnModel cm)
Initializes the data. |
protected void |
initTemplates()
|
boolean |
isEnableGroupingMenu()
Returns true if the grouping menu is enabled. |
boolean |
isEnableNoGroups()
Returns true if the user can turn off grouping. |
boolean |
isExpanded(com.google.gwt.dom.client.Element group)
Returns true if the group is expanded. |
boolean |
isShowGroupedColumn()
Returns true if the grouped column is visible. |
boolean |
isStartCollapsed()
Returns true if start collapsed is enabled. |
protected void |
onAdd(ListStore<ModelData> store,
java.util.List<ModelData> models,
int index)
|
protected void |
onGroupSelect(com.google.gwt.dom.client.Element group,
boolean select)
|
protected void |
onMouseDown(GridEvent<ModelData> ge)
|
protected void |
onRemove(ListStore<ModelData> ds,
ModelData m,
int index,
boolean isUpdate)
|
protected void |
onShowGroupsClick(MenuEvent be,
boolean checked)
|
protected void |
refreshRow(int row)
|
protected java.lang.String |
renderRows(int startRow,
int endRow)
|
void |
setEnableGroupingMenu(boolean enableGroupingMenu)
True to enable the grouping entry in the header context menu (defaults to true). |
void |
setEnableNoGroups(boolean enableNoGroups)
True to allow the user to turn off grouping by adding a check item to the header context menu (defaults to true). |
void |
setGroupRenderer(GridGroupRenderer groupRenderer)
Sets the group renderer. |
void |
setShowGroupedColumn(boolean showGroupedColumn)
Sets whether the grouped column is visible (defaults to true). |
void |
setStartCollapsed(boolean startCollapsed)
Sets whether the groups should start collapsed (defaults to false). |
protected void |
templateOnAllColumnWidthsUpdated(java.util.List<java.lang.Integer> ws,
int tw)
|
protected void |
templateOnColumnHiddenUpdated(int col,
boolean hidden,
int tw)
|
protected void |
templateOnColumnWidthUpdated(int col,
int w,
int tw)
|
void |
toggleAllGroups(boolean expanded)
Toggles all groups. |
protected void |
toggleGroup(com.google.gwt.dom.client.Element g,
boolean expanded)
|
Methods inherited from class com.extjs.gxt.ui.client.event.BaseObservable |
---|
addListener, callListener, fireEvent, fireEvent, getFiresEvents, getListeners, hasActiveEvent, hasListeners, hasListeners, removeAllListeners, removeListener, setFiresEvents |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected boolean enableGrouping
protected boolean isUpdating
protected java.util.Map<java.lang.String,java.lang.String> map
Constructor Detail |
---|
public GroupingView()
Method Detail |
---|
public void collapseAllGroups()
public void expandAllGroups()
public GridGroupRenderer getGroupRenderer()
public com.google.gwt.dom.client.NodeList<com.google.gwt.dom.client.Element> getGroups()
public GroupingView.GroupingViewImages getImages()
GridView
getImages
in class GridView
public void initData(ListStore ds, ColumnModel cm)
GridView
initData
in class GridView
ds
- the data storecm
- the column modelpublic boolean isEnableGroupingMenu()
public boolean isEnableNoGroups()
public boolean isExpanded(com.google.gwt.dom.client.Element group)
group
- the group
public boolean isShowGroupedColumn()
public boolean isStartCollapsed()
public void setEnableGroupingMenu(boolean enableGroupingMenu)
enableGroupingMenu
- true to enablepublic void setEnableNoGroups(boolean enableNoGroups)
enableNoGroups
- true to enable turning off groupingpublic void setGroupRenderer(GridGroupRenderer groupRenderer)
groupRenderer
- the group rendererpublic void setShowGroupedColumn(boolean showGroupedColumn)
showGroupedColumn
- true to show the grouped columnpublic void setStartCollapsed(boolean startCollapsed)
startCollapsed
- true to start collapsedpublic void toggleAllGroups(boolean expanded)
expanded
- true to expandprotected Menu createContextMenu(int colIndex)
createContextMenu
in class GridView
protected void doGroupEnd(java.lang.StringBuilder buf, GroupColumnData g, java.util.List<ColumnData> cs, int colCount)
protected void doGroupStart(java.lang.StringBuilder buf, GroupColumnData g, java.util.List<ColumnData> cs, int colCount)
protected java.lang.String doRender(java.util.List<ColumnData> cs, java.util.List<ModelData> rows, int startRow, int colCount, boolean stripe)
doRender
in class GridView
protected com.google.gwt.dom.client.Element findGroup(com.google.gwt.dom.client.Element el)
protected java.lang.String getGroup(java.lang.Object value, ModelData m, int rowIndex, int colIndex, ListStore<ModelData> ds)
protected java.lang.String getGroupField()
protected java.lang.String getGroupId(java.lang.String gidPrefix, java.lang.String groupField, java.lang.String group)
protected com.google.gwt.dom.client.Element getGroupRow(com.google.gwt.dom.client.Element group, int rowIndex)
protected int getGroupRowCount(com.google.gwt.dom.client.Element group)
protected com.google.gwt.dom.client.NodeList<com.google.gwt.dom.client.Element> getGroupRows(com.google.gwt.dom.client.Element group)
protected com.google.gwt.dom.client.NodeList<com.google.gwt.dom.client.Element> getRows()
getRows
in class GridView
protected void init(Grid grid)
GridView
init
in class GridView
grid
- the gridprotected void initTemplates()
initTemplates
in class GridView
protected void onAdd(ListStore<ModelData> store, java.util.List<ModelData> models, int index)
onAdd
in class GridView
protected void onGroupSelect(com.google.gwt.dom.client.Element group, boolean select)
protected void onMouseDown(GridEvent<ModelData> ge)
onMouseDown
in class GridView
protected void onRemove(ListStore<ModelData> ds, ModelData m, int index, boolean isUpdate)
onRemove
in class GridView
protected void onShowGroupsClick(MenuEvent be, boolean checked)
protected void refreshRow(int row)
refreshRow
in class GridView
protected java.lang.String renderRows(int startRow, int endRow)
renderRows
in class GridView
protected void templateOnAllColumnWidthsUpdated(java.util.List<java.lang.Integer> ws, int tw)
templateOnAllColumnWidthsUpdated
in class GridView
protected void templateOnColumnHiddenUpdated(int col, boolean hidden, int tw)
templateOnColumnHiddenUpdated
in class GridView
protected void templateOnColumnWidthUpdated(int col, int w, int tw)
templateOnColumnWidthUpdated
in class GridView
protected void toggleGroup(com.google.gwt.dom.client.Element g, boolean expanded)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |