net.sourceforge.jeval.function
Interface Function

All Known Implementing Classes:
Abs, Acos, Asin, Atan, Atan2, Ceil, CharAt, CompareTo, CompareToIgnoreCase, Concat, Cos, EndsWith, Equals, EqualsIgnoreCase, Eval, Exp, Floor, IEEEremainder, IndexOf, LastIndexOf, Length, Log, Max, Min, Pow, Random, Replace, Rint, Round, Sin, Sqrt, StartsWith, Substring, Tan, ToDegrees, ToLowerCase, ToRadians, ToUpperCase, Trim

public interface Function

A function that can be specified in an expression.


Method Summary
 java.lang.String execute(Evaluator evaluator, java.lang.String arguments)
          Executes the function for the specified argument.
 java.lang.String getName()
          Returns the name of the function.
 

Method Detail

getName

java.lang.String getName()
Returns the name of the function.

Returns:
The name of this function class.

execute

java.lang.String execute(Evaluator evaluator,
                         java.lang.String arguments)
                         throws FunctionException
Executes the function for the specified argument. This method is called internally by Evaluator.

Parameters:
evaluator - An instance of Evaluator.
arguments - The arguments that will be evaluated by the function. It is up to the function implementation to break the string into one or more arguments.
Returns:
The value of the evaluated argument.
Throws:
FunctionException - Thrown if the argument(s) are not valid for this function.


Copyright (C) 2002-2007 Robert Breidecker.