public class SheetContextNoImpl extends InheritableStyleConfiguration<SheetContext> implements SheetContext
| Constructor and Description |
|---|
SheetContextNoImpl(SheetContext parent,
WorkbookContext workbook) |
| Modifier and Type | Method and Description |
|---|---|
RowContext |
currentRow()
Retrieve current row, i.e.
|
SheetContext |
endConditionalBlock()
Designates end of a conditional block.
|
SheetContext |
fitOnPagesByHeight(int pages) |
SheetContext |
fitOnPagesByWidth(int pages) |
Configuration |
getConfiguration()
Get workbook wide configuration.
|
org.apache.poi.ss.usermodel.Sheet |
getNativeSheet()
Retrieve POI sheet referred to by current
SheetContext
Please refrain from using the exposed HSSFSheet directly unless you need functionality of POI not provided by SheetContext. |
SheetContext |
hideGrid()
Hide grid lines for current sheet.
|
SheetContext |
mergeCells(int startColumn,
int endColumn)
Merge cells of the current row starting from column number
startColumn and ending with a column endColumn. |
RowContext |
nextConditionalRow(boolean condition)
Create row in current position within the sheet and process all the configurations on it only if condition evaluates to true.
|
RowContext |
nextRow()
Create subsequent row and place current row pointer on it.
|
SheetContext |
setColumnWidth(int columnNumber,
int width)
Set column width.
|
SheetContext |
setColumnWidths(int... multipliers)
Set widths for subsequent columns starting from the first one.
|
SheetContext |
setDefaultRowIndent(int indent)
Set sheet-wide indentation.
|
SheetContext |
skipRow()
Move current row pointer to the next position within the sheet.
|
SheetContext |
skipRows(int offset)
Move current row pointer by
offset rows within the sheet. |
ColumnTotalsDataRange |
startColumnTotalsDataRangeFromNextRow() |
SheetContext |
startConditionalBlock(boolean condition)
Demarcates start of a conditional block and defines execution condition.
|
SheetContext |
stepOneRowBack() |
getDateStyle, getHeaderStyle, getNumberStyle, getPercentageStyle, getStyleConfiguration, getTextStyle, getTotalStyle, setDateStyle, setHeaderStyle, setNumberStyle, setPercentageStyle, setStyleConfiguration, setTextStyle, setTotalStyleclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetDateStyle, getHeaderStyle, getNumberStyle, getPercentageStyle, getTextStyle, getTotalStylegetStyleConfiguration, setDateStyle, setHeaderStyle, setNumberStyle, setPercentageStyle, setStyleConfiguration, setTextStyle, setTotalStylepublic SheetContextNoImpl(SheetContext parent, WorkbookContext workbook)
public RowContext nextRow()
RowNavigationnextRow in interface RowNavigation<SheetContext,RowContext>public RowContext nextConditionalRow(boolean condition)
RowConditionnextConditionalRow in interface RowCondition<RowContext>condition - execution conditionpublic RowContext currentRow()
RowNavigationRowNavigation.nextRow() and RowCondition.nextConditionalRow(boolean)) within current sheet.
Is not affected by RowNavigation.skipRow() or RowNavigation.skipRows(int).currentRow in interface RowNavigation<SheetContext,RowContext>RowContextpublic SheetContext skipRow()
RowNavigationRowNavigation.nextRow() or RowCondition.nextConditionalRow(boolean).skipRow in interface RowNavigation<SheetContext,RowContext>SheetContextpublic SheetContext skipRows(int offset)
RowNavigationoffset rows within the sheet.
Doesn't involve actual row creation but just the position in which the next row will be created with RowNavigation.nextRow() or RowCondition.nextConditionalRow(boolean).skipRows in interface RowNavigation<SheetContext,RowContext>offset - number of rows to move pointer bySheetContextpublic SheetContext stepOneRowBack()
stepOneRowBack in interface RowNavigation<SheetContext,RowContext>public SheetContext startConditionalBlock(boolean condition)
BlockConditionstartConditionalBlock in interface BlockCondition<SheetContext>condition - execution conditionpublic SheetContext endConditionalBlock()
BlockConditionendConditionalBlock in interface BlockCondition<SheetContext>public org.apache.poi.ss.usermodel.Sheet getNativeSheet()
SheetContextSheetContext
Please refrain from using the exposed HSSFSheet directly unless you need functionality of POI not provided by SheetContext.getNativeSheet in interface SheetContextHSSFSheetpublic SheetContext setColumnWidth(int columnNumber, int width)
SheetConfigurationsetColumnWidth in interface SheetConfiguration<SheetContext>columnNumber - index of the column to set width forwidth - width in units, subject to multiplication - see Configuration.getColumnWidthBaseValue()public SheetContext setColumnWidths(int... multipliers)
SheetConfigurationsetColumnWidths in interface SheetConfiguration<SheetContext>multipliers - each width in units, subject to multiplication - see Configuration.getColumnWidthBaseValue()public SheetContext mergeCells(int startColumn, int endColumn)
SheetContextstartColumn and ending with a column endColumn.
In most cases using RowContext.mergeCells(int) is supposed to be more convenient.mergeCells in interface SheetContextstartColumn - index of the first column participating in a merged cellendColumn - index of the last column participating in a merged cellpublic SheetContext hideGrid()
SheetConfigurationhideGrid in interface SheetConfiguration<SheetContext>public SheetContext setDefaultRowIndent(int indent)
SheetConfigurationRowContext which in due order affects all the cell navigation and output operations.
Shifts position set by CellNavigation.cellAt(int).
Default: 0.setDefaultRowIndent in interface SheetConfiguration<SheetContext>indent - indentation in number of cellspublic SheetContext fitOnPagesByWidth(int pages)
fitOnPagesByWidth in interface SheetConfiguration<SheetContext>public SheetContext fitOnPagesByHeight(int pages)
fitOnPagesByHeight in interface SheetConfiguration<SheetContext>public Configuration getConfiguration()
ConfigurationProvidergetConfiguration in interface ConfigurationProviderpublic ColumnTotalsDataRange startColumnTotalsDataRangeFromNextRow()
startColumnTotalsDataRangeFromNextRow in interface ColumnTotalsDataRangeSourceCopyright © 2014. All rights reserved.