jxl.biff.formula
Class CellReference3d

java.lang.Object
  |
  +--jxl.biff.formula.ParseItem
        |
        +--jxl.biff.formula.Operand
              |
              +--jxl.biff.formula.CellReference3d
All Implemented Interfaces:
ParsedThing

class CellReference3d
extends Operand
implements ParsedThing

A 3d cell reference in a formula


Field Summary
private  int column
          The column reference
private  boolean columnRelative
          Indicates whether the column reference is relative or absolute
private  Cell relativeTo
          The cell containing the formula.
private  int row
          The row reference
private  boolean rowRelative
          Indicates whether the row reference is relative or absolute
private  int sheet
          The sheet which the reference is present on
private  ExternalSheet workbook
          A handle to the container of the external sheets ie.
 
Fields inherited from class jxl.biff.formula.ParseItem
parent
 
Constructor Summary
CellReference3d(Cell rt, ExternalSheet w)
          Constructor
CellReference3d(java.lang.String s, ExternalSheet w)
          Constructs this object from a string
 
Method Summary
(package private)  byte[] getBytes()
          Gets the token representation of this item in RPN
 int getColumn()
          Accessor for the column
 int getRow()
          Accessor for the row
 void getString(java.lang.StringBuffer buf)
          Gets the string version of this cell reference
 int read(byte[] data, int pos)
          Reads the ptg data from the array starting at the specified position
 
Methods inherited from class jxl.biff.formula.ParseItem
setParent
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

columnRelative

private boolean columnRelative
Indicates whether the column reference is relative or absolute

rowRelative

private boolean rowRelative
Indicates whether the row reference is relative or absolute

column

private int column
The column reference

row

private int row
The row reference

relativeTo

private Cell relativeTo
The cell containing the formula. Stored in order to determine relative cell values

sheet

private int sheet
The sheet which the reference is present on

workbook

private ExternalSheet workbook
A handle to the container of the external sheets ie. the workbook
Constructor Detail

CellReference3d

public CellReference3d(Cell rt,
                       ExternalSheet w)
Constructor
Parameters:
the - cell containing the formula
the - list of external sheets

CellReference3d

public CellReference3d(java.lang.String s,
                       ExternalSheet w)
                throws FormulaException
Constructs this object from a string
Parameters:
s - the string
w - the external sheet
Throws:
FormulaException -  
Method Detail

read

public int read(byte[] data,
                int pos)
Reads the ptg data from the array starting at the specified position
Specified by:
read in interface ParsedThing
Parameters:
data - the RPN array
pos - the current position in the array, excluding the ptg identifier
Returns:
the number of bytes read

getColumn

public int getColumn()
Accessor for the column
Returns:
the column number

getRow

public int getRow()
Accessor for the row
Returns:
the row number

getString

public void getString(java.lang.StringBuffer buf)
Gets the string version of this cell reference
Overrides:
getString in class ParseItem
Parameters:
buf - the buffer to append to

getBytes

byte[] getBytes()
Gets the token representation of this item in RPN
Overrides:
getBytes in class ParseItem
Returns:
the bytes applicable to this formula