diff options
Diffstat (limited to 'internal/rpn/operations_interfaces.go')
| -rw-r--r-- | internal/rpn/operations_interfaces.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/internal/rpn/operations_interfaces.go b/internal/rpn/operations_interfaces.go index e659644..f317f8a 100644 --- a/internal/rpn/operations_interfaces.go +++ b/internal/rpn/operations_interfaces.go @@ -152,6 +152,15 @@ type OperationsProvider interface { CustomMetricManager } +// OperatorRegistryProvider defines the methods RPN needs from the operator registry. +// RPN depends on this interface (DIP) rather than the concrete *OperatorRegistry type. +type OperatorRegistryProvider interface { + IsStandardOperator(token string) bool + IsHyperOperator(token string) bool + HandleStandardOperator(stack *Stack, token string) (string, bool, error) + HandleHyperOperator(stack *Stack, token string) (string, bool, error) +} + // Operator implementations are split across focused sub-interfaces // (ArithmeticOperator, LogarithmicOperator, MetricOperator, BooleanOperator, // HyperOperator, StackOperator, VariableOperator, ConstantOperator, |
