org.apache.poi.hssf.record.formula
Class NumberPtg

java.lang.Object
  |
  +--org.apache.poi.hssf.record.formula.Ptg
        |
        +--org.apache.poi.hssf.record.formula.NumberPtg

public class NumberPtg
extends Ptg

Number Stores a floating point value in a formula value stored in a 8 byte field using IEEE notation

Author:
Avik Sengupta

Field Summary
static byte sid
           
static int SIZE
           
 
Constructor Summary
  NumberPtg(byte[] data, int offset)
          Create a NumberPtg from a byte array read from disk
protected NumberPtg(java.lang.String value)
          Create a NumberPtg from a string representation of the number Number format is not checked, it is expected to be validated in the parser that calls this method.
 
Method Summary
 int getSize()
           
 double getValue()
           
 void setValue(double value)
           
 java.lang.String toFormulaString()
          return a string representation of this token alone
 void writeBytes(byte[] array, int offset)
          write this Ptg to a byte array
 
Methods inherited from class org.apache.poi.hssf.record.formula.Ptg
createPtg, getBytes, toDebugString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SIZE

public static final int SIZE

sid

public static final byte sid
Constructor Detail

NumberPtg

public NumberPtg(byte[] data,
                 int offset)
Create a NumberPtg from a byte array read from disk

NumberPtg

protected NumberPtg(java.lang.String value)
Create a NumberPtg from a string representation of the number Number format is not checked, it is expected to be validated in the parser that calls this method.
Parameters:
value - : String representation of a floating point number
Method Detail

setValue

public void setValue(double value)

getValue

public double getValue()

writeBytes

public void writeBytes(byte[] array,
                       int offset)
Description copied from class: Ptg
write this Ptg to a byte array
Overrides:
writeBytes in class Ptg

getSize

public int getSize()
Overrides:
getSize in class Ptg

toFormulaString

public java.lang.String toFormulaString()
Description copied from class: Ptg
return a string representation of this token alone
Overrides:
toFormulaString in class Ptg

jakarta-poi 1.6.0-dev

Copyright © 2002 Apache jakarta-poi project. All Rights Reserved.