public class SheetUtil
extends java.lang.Object
Constructor and Description |
---|
SheetUtil() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
base64Random16Bytes() |
static boolean |
containsCell(CellRangeAddress cr,
int rowIx,
int colIx) |
static java.lang.String |
encryptPassword(java.lang.String password,
java.lang.String hashAlg,
java.lang.String salt64,
int spinCount)
see [MS_OFFCRYPTO].pdf 2.4.2.4
|
static double |
getCellWidth(Cell cell,
int defaultCharWidth,
DataFormatter formatter,
boolean useMergedCells)
Compute width of a single cell
|
static double |
getColumnWidth(Sheet sheet,
int column,
boolean useMergedCells)
Compute width of a column and return the result
|
static double |
getColumnWidth(Sheet sheet,
int column,
boolean useMergedCells,
int firstRow,
int lastRow)
Compute width of a column based on a subset of the rows and return the result
|
public static double getCellWidth(Cell cell, int defaultCharWidth, DataFormatter formatter, boolean useMergedCells)
cell
- the cell whose width is to be calculateddefaultCharWidth
- the width of a single characterformatter
- formatter used to prepare the text to be measureduseMergedCells
- whether to use merged cellspublic static double getColumnWidth(Sheet sheet, int column, boolean useMergedCells)
sheet
- the sheet to calculatecolumn
- 0-based index of the columnuseMergedCells
- whether to use merged cellspublic static double getColumnWidth(Sheet sheet, int column, boolean useMergedCells, int firstRow, int lastRow)
sheet
- the sheet to calculatecolumn
- 0-based index of the columnuseMergedCells
- whether to use merged cellsfirstRow
- 0-based index of the first row to consider (inclusive)lastRow
- 0-based index of the last row to consider (inclusive)public static boolean containsCell(CellRangeAddress cr, int rowIx, int colIx)
public static java.lang.String base64Random16Bytes()
public static java.lang.String encryptPassword(java.lang.String password, java.lang.String hashAlg, java.lang.String salt64, int spinCount)
Copyright © 2005-2010 Potix Corporation. All Rights Reserved.