Class SimpleWorksheet
- java.lang.Object
-
- com.nuix.superutilities.reporting.SimpleWorksheet
-
public class SimpleWorksheet extends java.lang.ObjectWrapper class around Aspose Cells Worksheet object which simplifies some of the more common operations.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidappendRow(java.util.List<? extends java.lang.Object> rowValues)voidappendRow(java.util.List<java.lang.Object> rowValues, com.aspose.cells.Style defaultStyle)voidautoFitColumns()voidautoFitRow(int row)voideachCell(int startRow, int endRow, int startCol, int endCol, java.util.function.Consumer<com.aspose.cells.Cell> activity)com.aspose.cells.WorksheetgetAsposeWorksheet()Gets the underlying Aspose Cells Worksheet object.com.aspose.cells.CellgetCell(int row, int col)Gets a particular Cell object from this work sheet.intgetCurrentRow()com.aspose.cells.StylegetStyle(int row, int col)Gets the style of a particular cell in this work sheetjava.lang.ObjectgetValue(int row, int col)Gets the value of a particular cell in this work sheetvoidmergeCols(int row, int col, int colCount)Merges a series of cells horizontallyvoidsetCurrentRow(int currentRow)voidsetStyle(int row, int col, com.aspose.cells.Style style)Sets the style of of a particular cell in this work sheetvoidsetValue(int row, int col, java.lang.Object value)Sets the value of a particular cell in this work sheet
-
-
-
Method Detail
-
getAsposeWorksheet
public com.aspose.cells.Worksheet getAsposeWorksheet()
Gets the underlying Aspose Cells Worksheet object.- Returns:
- The underlying Aspose Cells Worksheet object.
-
getCell
public com.aspose.cells.Cell getCell(int row, int col)Gets a particular Cell object from this work sheet.- Parameters:
row- The 0 based row indexcol- The 0 based column index- Returns:
- The underlying Aspose Cells Cell object at the given indices
-
getValue
public java.lang.Object getValue(int row, int col)Gets the value of a particular cell in this work sheet- Parameters:
row- The 0 based row indexcol- The 0 based column index- Returns:
- The value of the cell at the given indices
-
setValue
public void setValue(int row, int col, java.lang.Object value)Sets the value of a particular cell in this work sheet- Parameters:
row- The 0 based row indexcol- The 0 based column indexvalue- The value to assign to the cell at the given indices
-
setStyle
public void setStyle(int row, int col, com.aspose.cells.Style style)Sets the style of of a particular cell in this work sheet- Parameters:
row- The 0 based row indexcol- The 0 based column indexstyle- The Style to apply to the cell at the given indices
-
getStyle
public com.aspose.cells.Style getStyle(int row, int col)Gets the style of a particular cell in this work sheet- Parameters:
row- The 0 based row indexcol- The 0 based column index- Returns:
- The Style of the cell at the given indices
-
mergeCols
public void mergeCols(int row, int col, int colCount)Merges a series of cells horizontally- Parameters:
row- The 0 based row indexcol- The 0 based column index of the first column in the merged group of cells.colCount- How many cells total to merge, so if you want the 2 cells following the first cell specified by the indices, provide a value of 3.
-
autoFitColumns
public void autoFitColumns() throws java.lang.Exception- Throws:
java.lang.Exception
-
autoFitRow
public void autoFitRow(int row) throws java.lang.Exception- Throws:
java.lang.Exception
-
appendRow
public void appendRow(java.util.List<? extends java.lang.Object> rowValues)
-
appendRow
public void appendRow(java.util.List<java.lang.Object> rowValues, com.aspose.cells.Style defaultStyle)
-
eachCell
public void eachCell(int startRow, int endRow, int startCol, int endCol, java.util.function.Consumer<com.aspose.cells.Cell> activity)
-
getCurrentRow
public int getCurrentRow()
-
setCurrentRow
public void setCurrentRow(int currentRow)
-
-