jxl.biff.formula
Class StringValue

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

class StringValue
extends Operand
implements ParsedThing

A string constant operand in a formula


Field Summary
private  WorkbookSettings settings
          The workbook settings
private  java.lang.String value
          The string value
 
Fields inherited from class jxl.biff.formula.ParseItem
parent
 
Constructor Summary
StringValue(java.lang.String s)
          Constructor used when parsing a string formula
StringValue(WorkbookSettings ws)
          Constructor
 
Method Summary
(package private)  byte[] getBytes()
          Gets the token representation of this item in RPN
 void getString(java.lang.StringBuffer buf)
          Abstract method implementation to get the string equivalent of this token
 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

value

private java.lang.String value
The string value

settings

private WorkbookSettings settings
The workbook settings
Constructor Detail

StringValue

public StringValue(WorkbookSettings ws)
Constructor

StringValue

public StringValue(java.lang.String s)
Constructor used when parsing a string formula
Parameters:
s - the string token, including quote marks
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

getBytes

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

getString

public void getString(java.lang.StringBuffer buf)
Abstract method implementation to get the string equivalent of this token
Overrides:
getString in class ParseItem
Parameters:
buf - the string to append to