|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.iisc.jwc.jsheet.Range
Range contains a reference to the top, left, bottom, and right cell references and the sheet index that represents a range in a sheet.
Field Summary | |
int |
bottom
The bottom reference for this range. |
static short |
CURRENT_SHEET
The current sheet is specified in Range. |
int |
left
The left reference for this range. |
static short |
NO_SHEET
No sheet has been specified in Range. |
int |
right
The right reference for this range. |
short |
sheetIdx
The sheet index reference (defaults to CURRENT_SHEET or -2). |
int |
top
The top reference for this range. |
Constructor Summary | |
Range()
Constructs a new Range. |
|
Range(Cell upperLeft,
Cell lowerRight)
Constructs a new Range. |
|
Range(Cell upperLeft,
Cell lowerRight,
short sheetIndex)
Constructs a new Range with the sheetIndex explicitly set. |
|
Range(com.iisc.jwc.orb.CRange range)
For internal use only! |
|
Range(com.iisc.jwc.orb.CRange range,
short sheetIdx)
For internal use only! |
|
Range(int top,
int left,
int bottom,
int right)
Constructs a new Range. |
|
Range(int top,
int left,
int bottom,
int right,
short sheetIdx)
Constructs a new Range. |
|
Range(java.lang.String rangeRef)
Parses the string and constructs a Range. |
Method Summary | |
com.iisc.jwc.orb.CRange |
asCRange()
For internal use only! |
java.lang.Object |
clone()
Returns a copy of this range. |
boolean |
contains(Cell cell)
Returns true if the specifed Cell is within this Range. |
boolean |
equals(java.lang.Object range)
Returns true if the object values are equal. |
short |
getSheetIndex()
Returns the sheet index for the range. |
boolean |
isValid()
Returns true if the top, left, bottom, right and references are valid. |
void |
setSheetIndex(short index)
Sets a new sheet index for this range. |
void |
setValue(int top,
int left,
int bottom,
int right)
Set new values for the range. |
void |
setValueUsingCRange(com.iisc.jwc.orb.CRange range)
For internal use only! |
void |
setValueUsingString(java.lang.String rangeString)
Parses the string and creates the equivalent range. |
Range[] |
subtract(Range range)
Subtracts the specified range from this range; returns a range of possible ranges composed of the difference between the two. |
java.lang.String |
toString()
Returns a String representation of this object. |
Methods inherited from class java.lang.Object |
getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public int bottom
public static short CURRENT_SHEET
public int left
public static short NO_SHEET
public int right
public short sheetIdx
public int top
Constructor Detail |
public Range()
public Range(Cell upperLeft, Cell lowerRight)
upperLeft
- the cell reference containing the upper left cell.lowerRight
- the cell reference containing the lower right cell.public Range(Cell upperLeft, Cell lowerRight, short sheetIndex)
upperLeft
- the cell reference containing the upper left cell.lowerRight
- the cell reference containing the lower right cell.public Range(com.iisc.jwc.orb.CRange range)
range
- for internal use only!public Range(com.iisc.jwc.orb.CRange range, short sheetIdx)
range
- for internal use only!sheetIdx
- for internal use only!public Range(int top, int left, int bottom, int right)
top
- the top row.left
- the left column.bottom
- the bottom row.right
- the right column.public Range(int top, int left, int bottom, int right, short sheetIdx)
top
- the top row.left
- the left column.bottom
- the bottom row.right
- the right column.sheetIdx
- the sheet index, zero based.public Range(java.lang.String rangeRef) throws JSException
rangeRef
- the string to parse.
JSException
- If an invalid range reference.setValueUsingString(java.lang.String)
Method Detail |
public com.iisc.jwc.orb.CRange asCRange()
public java.lang.Object clone()
public boolean contains(Cell cell)
true
if the specifed Cell is within this Range.
cell
- the Cell object.
public boolean equals(java.lang.Object range)
true
if the object values are equal.
range
- object to test.
public short getSheetIndex()
public boolean isValid()
true
if the top, left, bottom, right and references are valid.
public void setSheetIndex(short index)
index
- a valid sheet index for the book, zero based.public void setValue(int top, int left, int bottom, int right)
top
- the top row.left
- the left column.bottom
- the bottom row.right
- the right column.public void setValueUsingCRange(com.iisc.jwc.orb.CRange range)
range
- for internal use only!public void setValueUsingString(java.lang.String rangeString) throws JSException
rangeString
- the string to parse.
JSException
- If an invalid range reference.public Range[] subtract(Range range)
range
- the range to subtract.
public java.lang.String toString()
|
Email JSheet Support | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |