Source code: com/hartmath/mapping/ConstantNumericEvaluator.java
1 /*
2 * --- formatted by Jindent 2.0b2, (www.c-lab.de/~jindent) ---
3 */
4 package com.hartmath.mapping;
5 import com.hartmath.expression.HObject;
6 import com.hartmath.expression.HFunction;
7
8 /**
9 * Interface that represents a function evaluation object. FunctionEvaluator is
10 * used as an interface for built-in functions, which are associated with a
11 * symbol.
12 *
13 *@author Klaus Hartlage <A HREF="mailto:khartlage@t-online.de">
14 * khartlage@t-online.de</A>
15 *@created 31. Juli 2001
16 *@see HSymbol
17 *@version %I%, %G%
18 */
19 public class ConstantNumericEvaluator implements FunctionEvaluator {
20 HObject numericValue;
21
22
23 /**
24 * Constructor for the ConstantNumericEvaluator object
25 *
26 *@param nVal Description of Parameter
27 */
28 public ConstantNumericEvaluator(HObject nVal) {
29 numericValue = nVal;
30 }
31
32
33 /**
34 * Gets the numericValue attribute of the ConstantNumericEvaluator object
35 *
36 *@return The numericValue value
37 */
38 public HObject getNumericValue() {
39 return numericValue;
40 }
41
42
43 /**
44 * Evaluate the given function if possible.
45 *
46 *@param fun function, which should be evaluated
47 *@return <c>null</c> if the function could not be evaluated; the
48 * evaluated object otherwise
49 */
50 public HObject evaluate(HFunction fun) {
51 return null;
52 }
53 }
54
55
56 /*
57 * --- formatting done in "Sun Java Convention" style on 06-18-1999 ---
58 */