Package io.keikai.model.impl
Class PivotFieldImpl
java.lang.Object
io.keikai.model.impl.PivotFieldImpl
- All Implemented Interfaces:
SPivotField,Serializable
Default implementation of
SPivotField.- Since:
- 7.0.0
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.keikai.model.SPivotField
SPivotField.Axis, SPivotField.SortType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddItem(SPivotItem item) Adds an item to this field.getAxis()Returns the axis this field is placed on.intReturns the index into the pivot cache fields that this field references.getItems()Returns the items in this field.getName()Returns the display name of this field.Returns the sort type for items.booleanReturns whether this field uses compact display.booleanisItemHidden(int itemIndex) Returns whether the item at the given index is hidden.booleanReturns whether this field uses outline display.booleanReturns whether all items are shown (including those with no data).booleanReturns whether subtotals are shown at the top.voidsetAxis(SPivotField.Axis axis) Sets the axis for this field.voidsetCompact(boolean compact) Sets compact display mode.voidsetItemHidden(int itemIndex, boolean hidden) Sets the hidden state for the item at the given index.voidsetOutline(boolean outline) Sets outline display mode.voidsetShowAll(boolean showAll) voidSets the sort type for items.voidsetSubtotalTop(boolean top) Sets whether subtotals are shown at the top.
-
Constructor Details
-
PivotFieldImpl
-
-
Method Details
-
getName
Description copied from interface:SPivotFieldReturns the display name of this field.- Specified by:
getNamein interfaceSPivotField- Returns:
- the field name
-
getCacheFieldIndex
public int getCacheFieldIndex()Description copied from interface:SPivotFieldReturns the index into the pivot cache fields that this field references.- Specified by:
getCacheFieldIndexin interfaceSPivotField- Returns:
- the cache field index
-
getAxis
Description copied from interface:SPivotFieldReturns the axis this field is placed on.- Specified by:
getAxisin interfaceSPivotField- Returns:
- the axis
-
setAxis
Description copied from interface:SPivotFieldSets the axis for this field.- Specified by:
setAxisin interfaceSPivotField- Parameters:
axis- the axis
-
getSortType
Description copied from interface:SPivotFieldReturns the sort type for items.- Specified by:
getSortTypein interfaceSPivotField- Returns:
- the sort type
-
setSortType
Description copied from interface:SPivotFieldSets the sort type for items.- Specified by:
setSortTypein interfaceSPivotField- Parameters:
sort- the sort type
-
isCompact
public boolean isCompact()Description copied from interface:SPivotFieldReturns whether this field uses compact display.- Specified by:
isCompactin interfaceSPivotField- Returns:
- true if compact
-
setCompact
public void setCompact(boolean compact) Description copied from interface:SPivotFieldSets compact display mode.- Specified by:
setCompactin interfaceSPivotField- Parameters:
compact- true for compact
-
isOutline
public boolean isOutline()Description copied from interface:SPivotFieldReturns whether this field uses outline display.- Specified by:
isOutlinein interfaceSPivotField- Returns:
- true if outline
-
setOutline
public void setOutline(boolean outline) Description copied from interface:SPivotFieldSets outline display mode.- Specified by:
setOutlinein interfaceSPivotField- Parameters:
outline- true for outline
-
isSubtotalTop
public boolean isSubtotalTop()Description copied from interface:SPivotFieldReturns whether subtotals are shown at the top.- Specified by:
isSubtotalTopin interfaceSPivotField- Returns:
- true if subtotals at top
-
setSubtotalTop
public void setSubtotalTop(boolean top) Description copied from interface:SPivotFieldSets whether subtotals are shown at the top.- Specified by:
setSubtotalTopin interfaceSPivotField- Parameters:
top- true for subtotals at top
-
isShowAll
public boolean isShowAll()Description copied from interface:SPivotFieldReturns whether all items are shown (including those with no data).- Specified by:
isShowAllin interfaceSPivotField- Returns:
- true if showing all items
-
setShowAll
public void setShowAll(boolean showAll) -
getItems
Description copied from interface:SPivotFieldReturns the items in this field.- Specified by:
getItemsin interfaceSPivotField- Returns:
- list of pivot items
-
addItem
Adds an item to this field.- Parameters:
item- the item to add
-
isItemHidden
public boolean isItemHidden(int itemIndex) Description copied from interface:SPivotFieldReturns whether the item at the given index is hidden.- Specified by:
isItemHiddenin interfaceSPivotField- Parameters:
itemIndex- zero-based item index- Returns:
- true if hidden
-
setItemHidden
public void setItemHidden(int itemIndex, boolean hidden) Description copied from interface:SPivotFieldSets the hidden state for the item at the given index.- Specified by:
setItemHiddenin interfaceSPivotField- Parameters:
itemIndex- zero-based item indexhidden- true to hide
-