protected abstract class FunctionCalculatorImpl.FixedFunction extends Object implements FunctionCalculatorImpl.Function
| Modifier | Constructor and Description |
|---|---|
protected |
FixedFunction(String name,
int arguments)
Constructor.
|
protected |
FixedFunction(String name,
int minArguments,
int maxArguments)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract Number |
call(FunctionCalculatorImpl.Functions functions,
List<Number> arguments)
Call the function.
|
Number |
call(List<Number> arguments)
Call the function.
|
protected void |
validate(List<Number> arguments)
Validate the number of arguments.
|
protected FixedFunction(String name, int arguments)
name - The function's name.arguments - The number of arguments that the function takes.protected FixedFunction(String name, int minArguments, int maxArguments)
name - The function's name.minArguments - The minimum number of arguments that the function takes.maxArguments - The maximum number of arguments that the function takes.protected void validate(List<Number> arguments) throws ParseException
arguments - The function's arguments.ParseException - In case of incorrect number of arguments.public final Number call(List<Number> arguments) throws ParseException
FunctionCalculatorImpl.Functioncall in interface FunctionCalculatorImpl.Functionarguments - The function's arguments.ParseException - In case the arguments are invalid.protected abstract Number call(FunctionCalculatorImpl.Functions functions, List<Number> arguments)
functions - The function implementations.arguments - The function's argument(s).Copyright © 2025. All rights reserved.