public class Dimension extends Object
This record contains the range address of the used area in the current sheet.
| 限定符和类型 | 字段和说明 |
|---|---|
short |
firstColumn |
int |
firstRow |
short |
lastColumn |
int |
lastRow |
| 构造器和说明 |
|---|
Dimension(int firstRow,
short firstColumn) |
Dimension(int firstRow,
short firstColumn,
int lastRow,
short lastColumn) |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
checkRange(int r,
int c)
Determine whether the specified coordinates are within the
Dimension |
boolean |
equals(Object o) |
short |
getFirstColumn()
Returns the index to first used column, the min value is 1
|
int |
getFirstRow()
Returns the index to first used row, the min value is 1
|
short |
getLastColumn()
Returns the index to last used column, the max value
is 16,384 in office 2007 or later and 256 in office 2003
|
int |
getLastRow()
Returns the index to last used row, the max value
is 1,048,576 in office 2007 or later and 65,536 in office 2003
|
static Dimension |
of(String range)
Create
Dimension from a range string |
String |
toString() |
public final int firstRow
public final int lastRow
public final short firstColumn
public final short lastColumn
public Dimension(int firstRow,
short firstColumn)
public Dimension(int firstRow,
short firstColumn,
int lastRow,
short lastColumn)
public static Dimension of(String range)
Dimension from a range stringrange - range string like A2:B2Dimension entrypublic int getFirstRow()
public int getLastRow()
public short getFirstColumn()
public short getLastColumn()
public boolean checkRange(int r,
int c)
Dimensionr - row numberc - column numberDimensionCopyright © 2022. All rights reserved.