call method
Executes function with the given input value.
engine is a BallCallable that lets this handler compose other
ball functions (user-defined or from other handlers) without holding
a direct engine reference:
final sub = engine('std', 'subtract',
{'left': highPrice, 'right': lowPrice});
Throws BallRuntimeError when function is not supported.
Implementation
@override
FutureOr<Object?> call(String function, Object? input, BallCallable engine) {
final composed = _composedDispatch[function];
if (composed != null) return composed(input, engine);
final handler = _dispatch[function];
if (handler == null) {
throw BallRuntimeError('Unknown std function: "$function"');
}
return handler(input);
}