org.shiftone.bigcalc
Class StdContext

java.lang.Object
  extended byorg.shiftone.bigcalc.StdContext
All Implemented Interfaces:
Context

public class StdContext
extends java.lang.Object
implements Context

This is the out-of-the-box context. Feel free to implement your own.

Version:
$Revision: 1.6 $
Author:
$Author: jeffdrost $

Constructor Summary
StdContext()
           
 
Method Summary
 void clearAllValues()
           
 Context createScope()
           
 Function getFunction(java.lang.String name)
           
 int getRoundingMode()
           
 int getScale()
           
 java.lang.Object getValue(java.lang.String name)
           
 void setFunction(java.lang.String name, Function function)
           
 void setRoundingMode(int roundingMode)
           
 void setScale(int scale)
           
 void setValue(java.lang.String name, double o)
           
 void setValue(java.lang.String name, long o)
           
 void setValue(java.lang.String name, java.lang.Object o)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StdContext

public StdContext()
Method Detail

getValue

public java.lang.Object getValue(java.lang.String name)
Specified by:
getValue in interface Context

setValue

public void setValue(java.lang.String name,
                     java.lang.Object o)
Specified by:
setValue in interface Context

setValue

public void setValue(java.lang.String name,
                     long o)

setValue

public void setValue(java.lang.String name,
                     double o)

clearAllValues

public void clearAllValues()

createScope

public Context createScope()
Specified by:
createScope in interface Context

getFunction

public Function getFunction(java.lang.String name)
Specified by:
getFunction in interface Context

setFunction

public void setFunction(java.lang.String name,
                        Function function)

getScale

public int getScale()
Specified by:
getScale in interface Context

setScale

public void setScale(int scale)

getRoundingMode

public int getRoundingMode()
Specified by:
getRoundingMode in interface Context

setRoundingMode

public void setRoundingMode(int roundingMode)