Logo Search packages:      
Sourcecode: wims version File versions  Download package

SharpTools::Formula Class Reference

List of all members.

Detailed Description

This is the class for formula processing.

The major public interfaces are:

  1. Constructors
  2. Number evaluate(TableModel table, int row, int col)
  3. String toString()
  4. TreeSet getDependency()

See also:



Hua Zhong <huaz@cs.columbia.edu>

Definition at line 32 of file Formula.java.

Public Member Functions

TreeSet getDependency ()
boolean isBad ()
boolean needsRecalc ()
void setNeedsRecalc (boolean needs)
String toString ()

Static Public Member Functions

static Number evaluate (SharpTableModel table, LinkedList postfix, int row, int col) throws ParserException
static Number evaluate (SharpTableModel table, int row, int col) throws ParserException
static String fixRelAddr (String oldFormula, int rowOffset, int colOffset)
static Function getFuncHandler (String fname)
static boolean isSafe (Formula formula, int rowOff, int colOff)
static final CellPoint parseAddress (String s)
static void registerFunctions ()

Package Functions

 Formula (Formula formula, int row, int col) throws ParserException
 Formula (String input, int row, int col) throws ParserException
 Formula (String input, int row, int col, ParserException e)

Private Member Functions

LinkedList convertParams (final LinkedList tokens) throws ParserException
TreeSet createDependency (LinkedList tokens)
Number evaluate (SharpTableModel table) throws ParserException
String getCellString ()
void throwError (Object s) throws ParserException
LinkedList tokenize (String input) throws ParserException
LinkedList toPostfix (LinkedList tokens) throws ParserException

Static Private Member Functions

static Number calc (char op, Number op1, Number op2)
static Number evalFunction (SharpTableModel table, Node node, int row, int col) throws ParserException
static final String getCellString (int row, int col)
static int getPriority (Node node)
static int getPriority (char op)
static void register (String funcName, Function func)
final static String translateColumn (int column)
final static int translateColumn (String column)
final static String translateRow (int row)
final static int translateRow (String row)

Private Attributes

int col
TreeSet dependency
ParserException error
String formulaString
boolean needsRecalc
LinkedList postfix
int row

Static Private Attributes

static HashMap funcTable

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index