// Copyright (c) 2020 Shellyl_N and Authors // license: ISC // https://github.com/shellyln import { ResolverContext, FieldResultType, QueryFuncInfo, PreparedConditionOperand, PreparedCondition, PreparedFnCall } from '../types'; export interface CondOp1CacheValue { isField: boolean, isDateOrDatetime: boolean, op: PreparedConditionOperand, op2FieldResultType: FieldResultType, fnInfo: QueryFuncInfo | null, fn: (fieldNameMap: Map, ctx: Omit, cache: CondOp1CacheValue, record: any) => any, } export interface MemoizedValue { value: any, } export const condOp1FnCache = new WeakMap(); export const condOp2ValueCache = new WeakMap(); export const nestedFnInfoCache = new WeakMap(); export const memoizedFnCache = new WeakMap();