import { Expression, GenBinding } from "./types.js"; type CallbackRet = { genBindings?: GenBinding[]; doNotAddParentesis?: boolean; value: Expression; }; type Callback = (...args: Expression[]) => CallbackRet; export declare const FunctionMap: Map; export declare const defaultFunctions: { /** * Returns the absolute value of a number (the value without regard to whether it is positive or negative). For example, the absolute value of -5 is the same as the absolute value of 5. * @param number * @returns */ abs: (number: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; /** * Returns the negative absolute value of a number (the value without regard to whether it is positive or negative). For example, the absolute value of 5 is the same as the negative absolute value of -5. * @param number * @returns */ negabs: (number: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; /** * Generate a new binding for expression * @param expression * @returns */ new: (expression: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; sqrt: (input: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; cache_value: (cache_binding: string, override_binding: string, is_read: string) => { value: string; }; vector_length: (x: string, y: string, z: string) => { genBindings: GenBinding[]; value: string; }; strlen: (str: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; not_contains: (source_str: string, contains_str: string) => { value: string; }; contains: (source_str: string, contains_str: string) => { value: string; }; starts_with: (source_str: string, start_str: string) => { value: string; genBindings?: undefined; } | { genBindings: { source: string; target: `#${string}`; }[]; value: string; }; str_slice: (str: string, start: string, end: string) => { genBindings: GenBinding[]; value: string; }; bs: (input_binding: string) => { doNotAddParentesis: true; value: `#${string}`; }; vs: (input_variable: string) => { doNotAddParentesis: true; value: `$${string}`; }; /** * Return a translatable string * @param key * @returns */ translatable: (key: string) => { genBindings: never[]; value: string; }; /** * Return a binary of int32 number in string * @param value * @param bait * @returns */ /** * Generate value bindings * @param value * @param bait * @returns */ bind: (value: string, bait: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; /** * Return a int of float number, because string in JSON-UI cannot read it. * @param input * @returns */ int: (input: string) => { genBindings: { source: string; target: `#${string}`; }[]; value: `#${string}`; }; }; export {};