UNPKG

redis-orm-node

Version:

`redis-orm` is a lightweight Object-Relational Mapping (ORM) library for Node.js.

17 lines (16 loc) 568 B
import { PrimitiveValue } from "./common"; export declare class Operator<S extends KeysOperatorTypes = KeysOperatorTypes> { readonly value: OperatorTypes[S]; readonly type: S; readonly "@instanceof": symbol; constructor(value: OperatorTypes[S], type: S); } export type KeysOperatorTypes = keyof OperatorTypes; export type OperatorTypes = { equal: PrimitiveValue; not: PrimitiveValue | Operator<"equal"> | Operator<"like">; like: PrimitiveValue; }; export type Operators<T = { [key in KeysOperatorTypes]: Operator<key>; }> = T[keyof T];