ArithmeticRepository

public abstract class ArithmeticRepository
Derive from this class to provide custom arithmetic operator methods. Add any number of public, *static* methods which represent either binary operator logic, or unary/binary/ternary arithmetic function logic and decorate them with the appropriate Arithmetic.OperatorAttribute or Arithmetic.FunctionAttribute respectively.

Methods

UndefinedException

#
protected static Exception UndefinedException(Binary fn, Type a, Type b)
Create an exception expressing an undefined binary function.
fn (Arithmetic.Binary)Function.
a (Type)First operand type.
b (Type)Second operand type.

UndefinedException

#
protected static Exception UndefinedException(Operation op, Type a, Type b)
Create an exception expressing an undefined operation.
op (Arithmetic.Operation)Operation.
a (Type)First operand type.
b (Type)Second operand type.

UndefinedException

#
protected static Exception UndefinedException(string name, params Type[] types)
Create an exception expressing an undefined operation.
name (string)Name of operation.
types (params Type[])Collection of relevant types.

UndefinedException

#
protected static Exception UndefinedException(Ternary fn, Type a, Type b, Type c)
Create an exception expressing an undefined ternary function.
fn (Arithmetic.Ternary)Function.
a (Type)First operand type.
b (Type)Second operand type.
c (Type)Third operand type.

UndefinedException

#
protected static Exception UndefinedException(Unary fn, Type a)
Create an exception expressing an undefined unary function.
fn (Arithmetic.Unary)Function.
a (Type)First operand type.