import '../polifils/array-find-last.js'; import type { StrictOmit } from 'ts-gems'; import { type Validator } from 'valgen'; import type { ComplexType } from '../document/index.js'; import { ResponsiveMap } from '../helpers/index.js'; import { OpraSchema } from '../schema/index.js'; import { ComparisonExpression, type ComparisonOperator, Expression } from './ast/index.js'; export declare namespace FilterRules { interface Options { caseSensitive?: boolean; } interface Rule { operators?: ComparisonOperator[]; /** * A line about what this field means, printed under the rule by the * reference page. The name `HttpOperation.Entity.Filter`'s own options * use, and the one that reaches the exported schema - `set` keeps * whatever it is handed, so this was already stored and already * serialized while the type said nothing about it. */ notes?: string; /** The same slot under its older name, for a rule built directly * rather than through the decorator. */ description?: string; prepare?: (args: ComparisonExpression.PrepareArgs) => any; mappedField?: string; } } export declare class FilterRules { protected _rules: ResponsiveMap; protected _decoderCache: WeakMap>; constructor(rules?: Record, options?: FilterRules.Options); set(fieldName: string, options?: Partial> & { operators?: ComparisonOperator[] | string; }): void; normalizeFilter(filter: OpraSchema.Field.QualifiedName | Expression, currentType?: ComplexType, scope?: string | '*'): Expression | undefined; protected normalizeFilterAst(ast: Expression, stack: Expression[], currentType?: ComplexType, scope?: string | '*'): Expression | undefined; toJSON(): Record; [Symbol.iterator](): IterableIterator<[string, FilterRules.Rule]>; }