UNPKG

@sequeljs/ast

Version:

A SQL AST manager for JavaScript

44 lines 1.43 kB
import Addition from '../nodes/Addition'; import BitwiseAnd from '../nodes/BitwiseAnd'; import BitwiseNot from '../nodes/BitwiseNot'; import BitwiseOr from '../nodes/BitwiseOr'; import BitwiseShiftLeft from '../nodes/BitwiseShiftLeft'; import BitwiseShiftRight from '../nodes/BitwiseShiftRight'; import BitwiseXor from '../nodes/BitwiseXor'; import Division from '../nodes/Division'; import Grouping from '../nodes/Grouping'; import Multiplication from '../nodes/Multiplication'; import Subtraction from '../nodes/Subtraction'; export default class Math { add(other) { return new Grouping(new Addition(this, other)); } bitwiseAnd(other) { return new Grouping(new BitwiseAnd(this, other)); } bitwiseNot() { return new BitwiseNot(this); } bitwiseOr(other) { return new Grouping(new BitwiseOr(this, other)); } bitwiseShiftLeft(other) { return new Grouping(new BitwiseShiftLeft(this, other)); } bitwiseShiftRight(other) { return new Grouping(new BitwiseShiftRight(this, other)); } bitwiseXor(other) { return new Grouping(new BitwiseXor(this, other)); } divide(other) { return new Division(this, other); } multiply(other) { return new Multiplication(this, other); } subtract(other) { return new Grouping(new Subtraction(this, other)); } } //# sourceMappingURL=Math.js.map