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

java.lang.Object
  |
  +--org.apache.poi.hssf.record.formula.Ptg
        |
        +--org.apache.poi.hssf.record.formula.OperationPtg
              |
              +--org.apache.poi.hssf.record.formula.AbstractFunctionPtg
Direct Known Subclasses:
FuncPtg, FuncVarPtg

public abstract class AbstractFunctionPtg
extends OperationPtg

This class provides the base functionality for Excel sheet functions There are two kinds of function Ptgs - tFunc and tFuncVar Therefore, this class will have ONLY two subclasses

Author:
Avik Sengupta, Andrew C. Oliver (acoliver at apache dot org)

Field Summary
protected  byte field_1_num_args
           
protected  short field_2_fnc_index
           
protected static java.lang.Object[][] functionData
           
protected  byte[] paramClass
           
protected  byte returnClass
           
 
Fields inherited from class org.apache.poi.hssf.record.formula.OperationPtg
TYPE_BINARY, TYPE_FUNCTION, TYPE_UNARY
 
Fields inherited from class org.apache.poi.hssf.record.formula.Ptg
CLASS_ARRAY, CLASS_REF, CLASS_VALUE, ptgClass
 
Constructor Summary
AbstractFunctionPtg()
           
 
Method Summary
 byte getDefaultOperandClass()
           
 short getFunctionIndex()
           
 java.lang.String getName()
           
 byte getParameterClass(int index)
           
 int getSize()
           
 int getType()
           
protected  short lookupIndex(java.lang.String name)
           
 java.lang.String toFormulaString(SheetReferences refs)
          return a string representation of this token alone
 java.lang.String toFormulaString(java.lang.String[] operands)
          returns a string representation of the operations the length of the input array should equal the number returned by
 java.lang.String toString()
           
abstract  void writeBytes(byte[] array, int offset)
          write this Ptg to a byte array
 
Methods inherited from class org.apache.poi.hssf.record.formula.OperationPtg
getNumberOfOperands
 
Methods inherited from class org.apache.poi.hssf.record.formula.Ptg
clone, createPtg, getBytes, getPtgClass, setClass, toDebugString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

functionData

protected static java.lang.Object[][] functionData

returnClass

protected byte returnClass

paramClass

protected byte[] paramClass

field_1_num_args

protected byte field_1_num_args

field_2_fnc_index

protected short field_2_fnc_index
Constructor Detail

AbstractFunctionPtg

public AbstractFunctionPtg()
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getType

public int getType()
Specified by:
getType in class OperationPtg

getFunctionIndex

public short getFunctionIndex()

getName

public java.lang.String getName()

toFormulaString

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

Specified by:
toFormulaString in class Ptg

toFormulaString

public java.lang.String toFormulaString(java.lang.String[] operands)
Description copied from class: OperationPtg
returns a string representation of the operations the length of the input array should equal the number returned by

Specified by:
toFormulaString in class OperationPtg
See Also:
OperationPtg.getNumberOfOperands()

writeBytes

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

Specified by:
writeBytes in class Ptg

getSize

public int getSize()
Specified by:
getSize in class Ptg

lookupIndex

protected short lookupIndex(java.lang.String name)

getDefaultOperandClass

public byte getDefaultOperandClass()
Overrides:
getDefaultOperandClass in class OperationPtg

getParameterClass

public byte getParameterClass(int index)

jakarta-poi 1.10.0-dev

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