@redis/json
Advanced tools
| import { CommandParser } from '@redis/client/dist/lib/client/parser'; | ||
| import { RedisArgument, ArrayReply, NullReply, BlobStringReply } from '@redis/client/dist/lib/RESP/types'; | ||
| export interface RedisArrPopOptions { | ||
| import { JsonReviver } from '@redis/client/dist/lib/commands/generic-transformers'; | ||
| export type RedisArrPopOptions = { | ||
| reviver?: JsonReviver; | ||
| } & ({ | ||
| path?: never; | ||
| index?: never; | ||
| } | { | ||
| path: RedisArgument; | ||
| index?: number; | ||
| } | ||
| }); | ||
| declare const _default: { | ||
| readonly IS_READ_ONLY: false; | ||
| readonly parseCommand: (this: void, parser: CommandParser, key: RedisArgument, options?: RedisArrPopOptions) => void; | ||
| readonly transformReply: (this: void, reply: NullReply | BlobStringReply | ArrayReply<NullReply | BlobStringReply>) => string | number | boolean | Date | { | ||
| readonly transformReply: (this: void, reply: NullReply | BlobStringReply | ArrayReply<NullReply | BlobStringReply>, reviver?: JsonReviver) => string | number | boolean | Date | { | ||
| [key: string]: import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON; | ||
@@ -12,0 +18,0 @@ [key: number]: import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON; |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"ARRPOP.d.ts","sourceRoot":"","sources":["../../../lib/commands/ARRPOP.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,SAAS,EAAE,eAAe,EAAwB,MAAM,mCAAmC,CAAC;AAGhI,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,aAAa,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;;;gDAIsB,aAAa,OAAO,aAAa,YAAY,kBAAkB;iDAY9D,SAAS,GAAG,eAAe,GAAG,WAAW,SAAS,GAAG,eAAe,CAAC;;;;;AAd7F,wBAmB6B"} | ||
| {"version":3,"file":"ARRPOP.d.ts","sourceRoot":"","sources":["../../../lib/commands/ARRPOP.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,SAAS,EAAE,eAAe,EAAwB,MAAM,mCAAmC,CAAC;AAChI,OAAO,EAA6C,WAAW,EAAE,MAAM,sDAAsD,CAAC;AAE9H,MAAM,MAAM,kBAAkB,GAAG;IAC/B,OAAO,CAAC,EAAE,WAAW,CAAC;CACvB,GAAG,CACA;IAAE,IAAI,CAAC,EAAE,KAAK,CAAC;IAAC,KAAK,CAAC,EAAE,KAAK,CAAA;CAAE,GAC/B;IAAE,IAAI,EAAE,aAAa,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAC1C,CAAC;;;gDAIqB,aAAa,OAAO,aAAa,YAAY,kBAAkB;iDAgB9D,SAAS,GAAG,eAAe,GAAG,WAAW,SAAS,GAAG,eAAe,CAAC,YAAY,WAAW;;;;;AAlBpH,wBAuB6B"} |
@@ -10,14 +10,17 @@ "use strict"; | ||
| if (options) { | ||
| parser.push(options.path); | ||
| if (options.index !== undefined) { | ||
| parser.push(options.index.toString()); | ||
| if (options.path !== undefined) { | ||
| parser.push(options.path); | ||
| if (options.index !== undefined) { | ||
| parser.push(options.index.toString()); | ||
| } | ||
| } | ||
| parser.preserve = options.reviver; | ||
| } | ||
| }, | ||
| transformReply(reply) { | ||
| transformReply(reply, reviver) { | ||
| return (0, generic_transformers_1.isArrayReply)(reply) ? | ||
| reply.map(item => (0, generic_transformers_1.transformRedisJsonNullReply)(item)) : | ||
| (0, generic_transformers_1.transformRedisJsonNullReply)(reply); | ||
| reply.map(item => (0, generic_transformers_1.transformRedisJsonNullReply)(item, reviver)) : | ||
| (0, generic_transformers_1.transformRedisJsonNullReply)(reply, reviver); | ||
| } | ||
| }; | ||
| //# sourceMappingURL=ARRPOP.js.map |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"ARRPOP.js","sourceRoot":"","sources":["../../../lib/commands/ARRPOP.ts"],"names":[],"mappings":";;AAEA,+FAAiH;AAOjH,kBAAe;IACb,YAAY,EAAE,KAAK;IACnB,YAAY,CAAC,MAAqB,EAAE,GAAkB,EAAE,OAA4B;QAClF,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QAC3B,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QAEpB,IAAI,OAAO,EAAE,CAAC;YACZ,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;YAE1B,IAAI,OAAO,CAAC,KAAK,KAAK,SAAS,EAAE,CAAC;gBAChC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;YACxC,CAAC;QACH,CAAC;IACH,CAAC;IACD,cAAc,CAAC,KAA4E;QACzF,OAAO,IAAA,mCAAY,EAAC,KAAK,CAAC,CAAC,CAAC;YACzB,KAA8C,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,IAAA,kDAA2B,EAAC,IAAI,CAAC,CAAC,CAAC,CAAC;YAChG,IAAA,kDAA2B,EAAC,KAAK,CAAC,CAAC;IACvC,CAAC;CACyB,CAAC","sourcesContent":["import { CommandParser } from '@redis/client/dist/lib/client/parser';\nimport { RedisArgument, ArrayReply, NullReply, BlobStringReply, Command, UnwrapReply } from '@redis/client/dist/lib/RESP/types';\nimport { isArrayReply, transformRedisJsonNullReply } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport interface RedisArrPopOptions {\n path: RedisArgument;\n index?: number;\n}\n\nexport default {\n IS_READ_ONLY: false,\n parseCommand(parser: CommandParser, key: RedisArgument, options?: RedisArrPopOptions) {\n parser.push('JSON.ARRPOP');\n parser.pushKey(key);\n\n if (options) {\n parser.push(options.path);\n\n if (options.index !== undefined) {\n parser.push(options.index.toString());\n }\n }\n },\n transformReply(reply: NullReply | BlobStringReply | ArrayReply<NullReply | BlobStringReply>) {\n return isArrayReply(reply) ?\n (reply as unknown as UnwrapReply<typeof reply>).map(item => transformRedisJsonNullReply(item)) :\n transformRedisJsonNullReply(reply);\n }\n} as const satisfies Command;\n\n"]} | ||
| {"version":3,"file":"ARRPOP.js","sourceRoot":"","sources":["../../../lib/commands/ARRPOP.ts"],"names":[],"mappings":";;AAEA,+FAA8H;AAS9H,kBAAe;IACb,YAAY,EAAE,KAAK;IACnB,YAAY,CAAC,MAAqB,EAAE,GAAkB,EAAE,OAA4B;QAClF,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QAC3B,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QAEpB,IAAI,OAAO,EAAE,CAAC;YACZ,IAAI,OAAO,CAAC,IAAI,KAAK,SAAS,EAAE,CAAC;gBAC/B,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;gBAE1B,IAAI,OAAO,CAAC,KAAK,KAAK,SAAS,EAAE,CAAC;oBAChC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;gBACxC,CAAC;YACH,CAAC;YAED,MAAM,CAAC,QAAQ,GAAG,OAAO,CAAC,OAAO,CAAC;QACpC,CAAC;IACH,CAAC;IACD,cAAc,CAAC,KAA4E,EAAE,OAAqB;QAChH,OAAO,IAAA,mCAAY,EAAC,KAAK,CAAC,CAAC,CAAC;YACzB,KAA8C,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,IAAA,kDAA2B,EAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC;YACzG,IAAA,kDAA2B,EAAC,KAAK,EAAE,OAAO,CAAC,CAAC;IAChD,CAAC;CACyB,CAAC","sourcesContent":["import { CommandParser } from '@redis/client/dist/lib/client/parser';\nimport { RedisArgument, ArrayReply, NullReply, BlobStringReply, Command, UnwrapReply } from '@redis/client/dist/lib/RESP/types';\nimport { isArrayReply, transformRedisJsonNullReply, JsonReviver } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport type RedisArrPopOptions = {\n reviver?: JsonReviver;\n} & (\n | { path?: never; index?: never }\n | { path: RedisArgument; index?: number }\n);\n\nexport default {\n IS_READ_ONLY: false,\n parseCommand(parser: CommandParser, key: RedisArgument, options?: RedisArrPopOptions) {\n parser.push('JSON.ARRPOP');\n parser.pushKey(key);\n\n if (options) {\n if (options.path !== undefined) {\n parser.push(options.path);\n\n if (options.index !== undefined) {\n parser.push(options.index.toString());\n }\n }\n\n parser.preserve = options.reviver;\n }\n },\n transformReply(reply: NullReply | BlobStringReply | ArrayReply<NullReply | BlobStringReply>, reviver?: JsonReviver) {\n return isArrayReply(reply) ?\n (reply as unknown as UnwrapReply<typeof reply>).map(item => transformRedisJsonNullReply(item, reviver)) :\n transformRedisJsonNullReply(reply, reviver);\n }\n} as const satisfies Command;\n\n"]} |
| import { CommandParser } from '@redis/client/dist/lib/client/parser'; | ||
| import { RedisArgument } from '@redis/client/dist/lib/RESP/types'; | ||
| import { RedisVariadicArgument, transformRedisJsonNullReply } from '@redis/client/dist/lib/commands/generic-transformers'; | ||
| import { RedisVariadicArgument, transformRedisJsonNullReply, JsonReviver } from '@redis/client/dist/lib/commands/generic-transformers'; | ||
| export interface JsonGetOptions { | ||
| path?: RedisVariadicArgument; | ||
| reviver?: JsonReviver; | ||
| } | ||
@@ -7,0 +8,0 @@ declare const _default: { |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"GET.d.ts","sourceRoot":"","sources":["../../../lib/commands/GET.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAW,MAAM,mCAAmC,CAAC;AAC3E,OAAO,EAAE,qBAAqB,EAAE,2BAA2B,EAAE,MAAM,sDAAsD,CAAC;AAE1H,MAAM,WAAW,cAAc;IAC7B,IAAI,CAAC,EAAE,qBAAqB,CAAC;CAC9B;;;gDAKW,aAAa,OAChB,aAAa,YACR,cAAc;;;AAL5B,wBAc6B"} | ||
| {"version":3,"file":"GET.d.ts","sourceRoot":"","sources":["../../../lib/commands/GET.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAW,MAAM,mCAAmC,CAAC;AAC3E,OAAO,EAAE,qBAAqB,EAAE,2BAA2B,EAAE,WAAW,EAAE,MAAM,sDAAsD,CAAC;AAEvI,MAAM,WAAW,cAAc;IAC7B,IAAI,CAAC,EAAE,qBAAqB,CAAC;IAC7B,OAAO,CAAC,EAAE,WAAW,CAAA;CACtB;;;gDAKW,aAAa,OAChB,aAAa,YACR,cAAc;;;AAL5B,wBAe6B"} |
@@ -12,2 +12,3 @@ "use strict"; | ||
| } | ||
| parser.preserve = options?.reviver; | ||
| }, | ||
@@ -14,0 +15,0 @@ transformReply: generic_transformers_1.transformRedisJsonNullReply |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"GET.js","sourceRoot":"","sources":["../../../lib/commands/GET.ts"],"names":[],"mappings":";;AAEA,+FAA0H;AAM1H,kBAAe;IACb,YAAY,EAAE,KAAK;IACnB,YAAY,CACV,MAAqB,EACrB,GAAkB,EAClB,OAAwB;QAExB,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACxB,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QACpB,IAAI,OAAO,EAAE,IAAI,KAAK,SAAS,EAAE,CAAC;YAChC,MAAM,CAAC,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QACpC,CAAC;IACH,CAAC;IACD,cAAc,EAAE,kDAA2B;CACjB,CAAC","sourcesContent":["import { CommandParser } from '@redis/client/dist/lib/client/parser';\nimport { RedisArgument, Command } from '@redis/client/dist/lib/RESP/types';\nimport { RedisVariadicArgument, transformRedisJsonNullReply } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport interface JsonGetOptions {\n path?: RedisVariadicArgument;\n}\n\nexport default {\n IS_READ_ONLY: false,\n parseCommand(\n parser: CommandParser,\n key: RedisArgument,\n options?: JsonGetOptions\n ) {\n parser.push('JSON.GET');\n parser.pushKey(key);\n if (options?.path !== undefined) {\n parser.pushVariadic(options.path);\n }\n },\n transformReply: transformRedisJsonNullReply\n} as const satisfies Command;"]} | ||
| {"version":3,"file":"GET.js","sourceRoot":"","sources":["../../../lib/commands/GET.ts"],"names":[],"mappings":";;AAEA,+FAAuI;AAOvI,kBAAe;IACb,YAAY,EAAE,KAAK;IACnB,YAAY,CACV,MAAqB,EACrB,GAAkB,EAClB,OAAwB;QAExB,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACxB,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QACpB,IAAI,OAAO,EAAE,IAAI,KAAK,SAAS,EAAE,CAAC;YAChC,MAAM,CAAC,YAAY,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QACpC,CAAC;QACD,MAAM,CAAC,QAAQ,GAAG,OAAO,EAAE,OAAO,CAAC;IACrC,CAAC;IACD,cAAc,EAAE,kDAA2B;CACjB,CAAC","sourcesContent":["import { CommandParser } from '@redis/client/dist/lib/client/parser';\nimport { RedisArgument, Command } from '@redis/client/dist/lib/RESP/types';\nimport { RedisVariadicArgument, transformRedisJsonNullReply, JsonReviver } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport interface JsonGetOptions {\n path?: RedisVariadicArgument;\n reviver?: JsonReviver\n}\n\nexport default {\n IS_READ_ONLY: false,\n parseCommand(\n parser: CommandParser,\n key: RedisArgument,\n options?: JsonGetOptions\n ) {\n parser.push('JSON.GET');\n parser.pushKey(key);\n if (options?.path !== undefined) {\n parser.pushVariadic(options.path);\n }\n parser.preserve = options?.reviver;\n },\n transformReply: transformRedisJsonNullReply\n} as const satisfies Command;"]} |
@@ -128,2 +128,3 @@ export type { RedisJSON } from '@redis/client/dist/lib/commands/generic-transformers'; | ||
| * @param options.index - Optional index to pop from. Default is -1 (last element) | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -133,3 +134,3 @@ ARRPOP: { | ||
| readonly parseCommand: (this: void, parser: import("@redis/client/dist/lib/client/parser").CommandParser, key: import("@redis/client/dist/lib/RESP/types").RedisArgument, options?: import("./ARRPOP").RedisArrPopOptions | undefined) => void; | ||
| readonly transformReply: (this: void, reply: import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string> | import("@redis/client/dist/lib/RESP/types").ArrayReply<import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>>) => string | number | boolean | Date | { | ||
| readonly transformReply: (this: void, reply: import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string> | import("@redis/client/dist/lib/RESP/types").ArrayReply<import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>>, reviver?: ((this: any, key: string, value: any) => any) | undefined) => string | number | boolean | Date | { | ||
| [key: string]: import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON; | ||
@@ -147,2 +148,3 @@ [key: number]: import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON; | ||
| * @param options.index - Optional index to pop from. Default is -1 (last element) | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -152,3 +154,3 @@ arrPop: { | ||
| readonly parseCommand: (this: void, parser: import("@redis/client/dist/lib/client/parser").CommandParser, key: import("@redis/client/dist/lib/RESP/types").RedisArgument, options?: import("./ARRPOP").RedisArrPopOptions | undefined) => void; | ||
| readonly transformReply: (this: void, reply: import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string> | import("@redis/client/dist/lib/RESP/types").ArrayReply<import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>>) => string | number | boolean | Date | { | ||
| readonly transformReply: (this: void, reply: import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string> | import("@redis/client/dist/lib/RESP/types").ArrayReply<import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>>, reviver?: ((this: any, key: string, value: any) => any) | undefined) => string | number | boolean | Date | { | ||
| [key: string]: import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON; | ||
@@ -297,2 +299,3 @@ [key: number]: import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON; | ||
| * @param options.path - Path(s) to the value(s) to retrieve | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -311,2 +314,3 @@ GET: { | ||
| * @param options.path - Path(s) to the value(s) to retrieve | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -350,7 +354,8 @@ get: { | ||
| * @param path - Path to retrieve from each document | ||
| * @param reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
| MGET: { | ||
| readonly IS_READ_ONLY: true; | ||
| readonly parseCommand: (this: void, parser: import("@redis/client/dist/lib/client/parser").CommandParser, keys: import("@redis/client/dist/lib/RESP/types").RedisArgument[], path: import("@redis/client/dist/lib/RESP/types").RedisArgument) => void; | ||
| readonly transformReply: (this: void, reply: (import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>)[]) => (import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON | import("@redis/client/dist/lib/RESP/types").NullReply)[]; | ||
| readonly parseCommand: (this: void, parser: import("@redis/client/dist/lib/client/parser").CommandParser, keys: import("@redis/client/dist/lib/RESP/types").RedisArgument[], path: import("@redis/client/dist/lib/RESP/types").RedisArgument, reviver?: ((this: any, key: string, value: any) => any) | undefined) => void; | ||
| readonly transformReply: (this: void, reply: (import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>)[], reviver?: ((this: any, key: string, value: any) => any) | undefined) => (import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON | import("@redis/client/dist/lib/RESP/types").NullReply)[]; | ||
| }; | ||
@@ -363,7 +368,8 @@ /** | ||
| * @param path - Path to retrieve from each document | ||
| * @param reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
| mGet: { | ||
| readonly IS_READ_ONLY: true; | ||
| readonly parseCommand: (this: void, parser: import("@redis/client/dist/lib/client/parser").CommandParser, keys: import("@redis/client/dist/lib/RESP/types").RedisArgument[], path: import("@redis/client/dist/lib/RESP/types").RedisArgument) => void; | ||
| readonly transformReply: (this: void, reply: (import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>)[]) => (import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON | import("@redis/client/dist/lib/RESP/types").NullReply)[]; | ||
| readonly parseCommand: (this: void, parser: import("@redis/client/dist/lib/client/parser").CommandParser, keys: import("@redis/client/dist/lib/RESP/types").RedisArgument[], path: import("@redis/client/dist/lib/RESP/types").RedisArgument, reviver?: ((this: any, key: string, value: any) => any) | undefined) => void; | ||
| readonly transformReply: (this: void, reply: (import("@redis/client/dist/lib/RESP/types").NullReply | import("@redis/client/dist/lib/RESP/types").BlobStringReply<string>)[], reviver?: ((this: any, key: string, value: any) => any) | undefined) => (import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON | import("@redis/client/dist/lib/RESP/types").NullReply)[]; | ||
| }; | ||
@@ -370,0 +376,0 @@ /** |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/commands/index.ts"],"names":[],"mappings":"AA0BA,YAAY,EAAE,SAAS,EAAE,MAAM,sDAAsD,CAAC;AACtF,OAAO,EAAE,0BAA0B,EAAE,uBAAuB,EAAE,2BAA2B,EAAE,MAAM,sDA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G;;;;;;IAEH;;;;;;;;OAQG;;;;;;IAEH;;;;;;;;OAQG;;;;;;IAEH;;;;;;;OAOG;;;;;;IAEH;;;;;;;OAOG;;;;;;IAEH;;;;;;OAMG;;;;;;IAEH;;;;;;OAMG;;;;;;IAEH;;;;;;;OAOG;;;;;;;;;IAEH;;;;;;;OAOG;;;;;;;;;;AA7bL,wBA+bE"} |
@@ -128,2 +128,3 @@ "use strict"; | ||
| * @param options.index - Optional index to pop from. Default is -1 (last element) | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -139,2 +140,3 @@ ARRPOP: ARRPOP_1.default, | ||
| * @param options.index - Optional index to pop from. Default is -1 (last element) | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -241,2 +243,3 @@ arrPop: ARRPOP_1.default, | ||
| * @param options.path - Path(s) to the value(s) to retrieve | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -251,2 +254,3 @@ GET: GET_1.default, | ||
| * @param options.path - Path(s) to the value(s) to retrieve | ||
| * @param options.reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -278,2 +282,3 @@ get: GET_1.default, | ||
| * @param path - Path to retrieve from each document | ||
| * @param reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -287,2 +292,3 @@ MGET: MGET_1.default, | ||
| * @param path - Path to retrieve from each document | ||
| * @param reviver - An optional reviver function to call when parsing the reply from Redis | ||
| */ | ||
@@ -289,0 +295,0 @@ mGet: MGET_1.default, |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/commands/index.ts"],"names":[],"mappings":";;;;;;AAAA,4DAAoC;AACpC,0DAAkC;AAClC,4DAAoC;AACpC,sDAA8B;AAC9B,sDAA8B;AAC9B,wDAAgC;AAChC,oDAA4B;AAC5B,kEAA0C;AAC1C,gDAAwB;AACxB,sDAA8B;AA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G;IACH;;;;;;;OAOG;IACH,GAAG,EAAE,aAAG;IACR;;;;;;;OAOG;IACH,KAAK,EAAL,eAAK;IACL;;;;;;;OAOG;IACH,KAAK,EAAE,eAAK;IACZ;;;;;;OAMG;IACH,IAAI,EAAJ,cAAI;IACJ;;;;;;OAMG;IACH,IAAI,EAAE,cAAI;IACV;;;;;;;;OAQG;IACH,IAAI,EAAJ,cAAI;IACJ;;;;;;;;OAQG;IACH,IAAI,EAAE,cAAI;IACV;;;;;;;OAOG;IACH,SAAS,EAAT,mBAAS;IACT;;;;;;;OAOG;IACH,SAAS,EAAE,mBAAS;IACpB;;;;;;;OAOG;IACH,SAAS,EAAT,mBAAS;IACT;;;;;;;OAOG;IACH,SAAS,EAAE,mBAAS;IACpB;;;;;;;OAOG;IACH,OAAO,EAAP,iBAAO;IACP;;;;;;;OAOG;IACH,OAAO,EAAE,iBAAO;IAChB;;;;;;;OAOG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;;OAOG;IACH,MAAM,EAAE,gBAAM;IACd,QAAQ;IACR,cAAc;IACd;;;;;;;;;;;OAWG;IACH,GAAG,EAAH,aAAG;IACH;;;;;;;;;;;OAWG;IACH,GAAG,EAAE,aAAG;IACR;;;;;;;;OAQG;IACH,SAAS,EAAT,mBAAS;IACT;;;;;;;;OAQG;IACH,SAAS,EAAE,mBAAS;IACpB;;;;;;;OAOG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;;OAOG;IACH,MAAM,EAAE,gBAAM;IACd;;;;;;OAMG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;OAMG;IACH,MAAM,EAAE,gBAAM;IACd;;;;;;;OAOG;IACH,IAAI,EAAJ,cAAI;IACJ;;;;;;;OAOG;IACH,IAAI,EAAE,cAAI;CACX,CAAC","sourcesContent":["import ARRAPPEND from './ARRAPPEND';\nimport ARRINDEX from './ARRINDEX';\nimport ARRINSERT from './ARRINSERT';\nimport ARRLEN from './ARRLEN';\nimport ARRPOP from './ARRPOP';\nimport ARRTRIM from './ARRTRIM';\nimport CLEAR from './CLEAR';\nimport DEBUG_MEMORY from './DEBUG_MEMORY';\nimport DEL from './DEL';\nimport FORGET from './FORGET';\nimport GET from './GET';\nimport MERGE from './MERGE';\nimport MGET from './MGET';\nimport MSET from './MSET';\nimport NUMINCRBY from './NUMINCRBY';\nimport NUMMULTBY from './NUMMULTBY';\nimport OBJKEYS from './OBJKEYS';\nimport OBJLEN from './OBJLEN';\n// import RESP from './RESP';\nimport SET from './SET';\nimport STRAPPEND from './STRAPPEND';\nimport STRLEN from './STRLEN';\nimport TOGGLE from './TOGGLE';\nimport TYPE from './TYPE';\n\n// Re-export helper types and functions from client package\nexport type { RedisJSON } from '@redis/client/dist/lib/commands/generic-transformers';\nexport { transformRedisJsonArgument, transformRedisJsonReply, transformRedisJsonNullReply } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport default {\n /**\n * Appends one or more values to the end of an array in a JSON document.\n * Returns the new array length after append, or null if the path does not exist.\n *\n * @param key - The key to append to\n * @param path - Path to the array in the JSON document\n * @param json - The first value to append\n * @param jsons - Additional values to append\n */\n ARRAPPEND,\n /**\n * Appends one or more values to the end of an array in a JSON document.\n * Returns the new array length after append, or null if the path does not exist.\n *\n * @param key - The key to append to\n * @param path - Path to the array in the JSON document\n * @param json - The first value to append\n * @param jsons - Additional values to append\n */\n arrAppend: ARRAPPEND,\n /**\n * Returns the index of the first occurrence of a value in a JSON array.\n * If the specified value is not found, it returns -1, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param json - The value to search for\n * @param options - Optional range parameters for the search\n * @param options.range.start - Starting index for the search\n * @param options.range.stop - Optional ending index for the search\n */\n ARRINDEX,\n /**\n * Returns the index of the first occurrence of a value in a JSON array.\n * If the specified value is not found, it returns -1, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param json - The value to search for\n * @param options - Optional range parameters for the search\n * @param options.range.start - Starting index for the search\n * @param options.range.stop - Optional ending index for the search\n */\n arrIndex: ARRINDEX,\n /**\n * Inserts one or more values into an array at the specified index.\n * Returns the new array length after insert, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param index - The position where to insert the values\n * @param json - The first value to insert\n * @param jsons - Additional values to insert\n */\n ARRINSERT,\n /**\n * Inserts one or more values into an array at the specified index.\n * Returns the new array length after insert, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param index - The position where to insert the values\n * @param json - The first value to insert\n * @param jsons - Additional values to insert\n */\n arrInsert: ARRINSERT,\n /**\n * Returns the length of an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n */\n ARRLEN,\n /**\n * Returns the length of an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n */\n arrLen: ARRLEN,\n /**\n * Removes and returns an element from an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n * @param options.index - Optional index to pop from. Default is -1 (last element)\n */\n ARRPOP,\n /**\n * Removes and returns an element from an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n * @param options.index - Optional index to pop from. Default is -1 (last element)\n */\n arrPop: ARRPOP,\n /**\n * Trims an array in a JSON document to include only elements within the specified range.\n * Returns the new array length after trimming, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param start - Starting index (inclusive)\n * @param stop - Ending index (inclusive)\n */\n ARRTRIM,\n /**\n * Trims an array in a JSON document to include only elements within the specified range.\n * Returns the new array length after trimming, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param start - Starting index (inclusive)\n * @param stop - Ending index (inclusive)\n */\n arrTrim: ARRTRIM,\n /**\n * Clears container values (arrays/objects) in a JSON document.\n * Returns the number of values cleared (0 or 1), or null if the path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the container to clear\n */\n CLEAR,\n /**\n * Clears container values (arrays/objects) in a JSON document.\n * Returns the number of values cleared (0 or 1), or null if the path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the container to clear\n */\n clear: CLEAR,\n /**\n * Reports memory usage details for a JSON document value.\n * Returns size in bytes of the value, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to examine\n */\n DEBUG_MEMORY,\n /**\n * Reports memory usage details for a JSON document value.\n * Returns size in bytes of the value, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to examine\n */\n debugMemory: DEBUG_MEMORY,\n /**\n * Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n DEL,\n /**\n * Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n del: DEL,\n /**\n * Alias for JSON.DEL - Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n FORGET,\n /**\n * Alias for JSON.DEL - Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n forget: FORGET,\n /**\n * Gets values from a JSON document.\n * Returns the value at the specified path, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path(s) to the value(s) to retrieve\n */\n GET,\n /**\n * Gets values from a JSON document.\n * Returns the value at the specified path, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path(s) to the value(s) to retrieve\n */\n get: GET,\n /**\n * Merges a given JSON value into a JSON document.\n * Returns OK on success, or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to merge into\n * @param value - JSON value to merge\n */\n MERGE,\n /**\n * Merges a given JSON value into a JSON document.\n * Returns OK on success, or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to merge into\n * @param value - JSON value to merge\n */\n merge: MERGE,\n /**\n * Gets values at a specific path from multiple JSON documents.\n * Returns an array of values at the path from each key, null for missing keys/paths.\n *\n * @param keys - Array of keys containing JSON documents\n * @param path - Path to retrieve from each document\n */\n MGET,\n /**\n * Gets values at a specific path from multiple JSON documents.\n * Returns an array of values at the path from each key, null for missing keys/paths.\n *\n * @param keys - Array of keys containing JSON documents\n * @param path - Path to retrieve from each document\n */\n mGet: MGET,\n /**\n * Sets multiple JSON values in multiple documents.\n * Returns OK on success.\n *\n * @param items - Array of objects containing key, path, and value to set\n * @param items[].key - The key containing the JSON document\n * @param items[].path - Path in the document to set\n * @param items[].value - JSON value to set at the path\n */\n MSET,\n /**\n * Sets multiple JSON values in multiple documents.\n * Returns OK on success.\n *\n * @param items - Array of objects containing key, path, and value to set\n * @param items[].key - The key containing the JSON document\n * @param items[].path - Path in the document to set\n * @param items[].value - JSON value to set at the path\n */\n mSet: MSET,\n /**\n * Increments a numeric value stored in a JSON document by a given number.\n * Returns the value after increment, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to increment by\n */\n NUMINCRBY,\n /**\n * Increments a numeric value stored in a JSON document by a given number.\n * Returns the value after increment, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to increment by\n */\n numIncrBy: NUMINCRBY,\n /**\n * Multiplies a numeric value stored in a JSON document by a given number.\n * Returns the value after multiplication, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to multiply by\n */\n NUMMULTBY,\n /**\n * Multiplies a numeric value stored in a JSON document by a given number.\n * Returns the value after multiplication, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to multiply by\n */\n numMultBy: NUMMULTBY,\n /**\n * Returns the keys in the object stored in a JSON document.\n * Returns array of keys, array of arrays for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n OBJKEYS,\n /**\n * Returns the keys in the object stored in a JSON document.\n * Returns array of keys, array of arrays for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n objKeys: OBJKEYS,\n /**\n * Returns the number of keys in the object stored in a JSON document.\n * Returns length of object, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n OBJLEN,\n /**\n * Returns the number of keys in the object stored in a JSON document.\n * Returns length of object, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n objLen: OBJLEN,\n // RESP,\n // resp: RESP,\n /**\n * Sets a JSON value at a specific path in a JSON document.\n * Returns OK on success, or null if condition (NX/XX) is not met.\n *\n * @param key - The key containing the JSON document\n * @param path - Path in the document to set\n * @param json - JSON value to set at the path\n * @param options - Optional parameters\n * @param options.condition - Set condition: NX (only if doesn't exist) or XX (only if exists)\n * @deprecated options.NX - Use options.condition instead\n * @deprecated options.XX - Use options.condition instead\n */\n SET,\n /**\n * Sets a JSON value at a specific path in a JSON document.\n * Returns OK on success, or null if condition (NX/XX) is not met.\n *\n * @param key - The key containing the JSON document\n * @param path - Path in the document to set\n * @param json - JSON value to set at the path\n * @param options - Optional parameters\n * @param options.condition - Set condition: NX (only if doesn't exist) or XX (only if exists)\n * @deprecated options.NX - Use options.condition instead\n * @deprecated options.XX - Use options.condition instead\n */\n set: SET,\n /**\n * Appends a string to a string value stored in a JSON document.\n * Returns new string length after append, or null if the path doesn't exist or value is not a string.\n *\n * @param key - The key containing the JSON document\n * @param append - String to append\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n STRAPPEND,\n /**\n * Appends a string to a string value stored in a JSON document.\n * Returns new string length after append, or null if the path doesn't exist or value is not a string.\n *\n * @param key - The key containing the JSON document\n * @param append - String to append\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n strAppend: STRAPPEND,\n /**\n * Returns the length of a string value stored in a JSON document.\n * Returns string length, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n STRLEN,\n /**\n * Returns the length of a string value stored in a JSON document.\n * Returns string length, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n strLen: STRLEN,\n /**\n * Toggles a boolean value stored in a JSON document.\n * Returns 1 if value was toggled to true, 0 if toggled to false, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the boolean value\n */\n TOGGLE,\n /**\n * Toggles a boolean value stored in a JSON document.\n * Returns 1 if value was toggled to true, 0 if toggled to false, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the boolean value\n */\n toggle: TOGGLE,\n /**\n * Returns the type of JSON value at a specific path in a JSON document.\n * Returns the type as a string, array of types for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to examine\n */\n TYPE,\n /**\n * Returns the type of JSON value at a specific path in a JSON document.\n * Returns the type as a string, array of types for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to examine\n */\n type: TYPE\n};\n"]} | ||
| {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../lib/commands/index.ts"],"names":[],"mappings":";;;;;;AAAA,4DAAoC;AACpC,0DAAkC;AAClC,4DAAoC;AACpC,sDAA8B;AAC9B,sDAA8B;AAC9B,wDAAgC;AAChC,oDAA4B;AAC5B,kEAA0C;AAC1C,gDAAwB;AACxB,sDAA8B;AAC9B,gDAAwB;AACxB,oDAA4B;AAC5B,kDAA0B;AAC1B,kDAA0B;AAC1B,4DAAoC;AACpC,4DAAoC;AACpC,wDAAgC;AAChC,sDAA8B;AAC9B,6BAA6B;AAC7B,gDAAwB;AACxB,4DAAoC;AACpC,sDAA8B;AAC9B,sDAA8B;AAC9B,kDAA0B;AAI1B,6FAAwJ;AAA/I,kIAAA,0BAA0B,OAAA;AAAE,+HAAA,uBAAuB,OAAA;AAAE,mIAAA,2BAA2B,OAAA;AAEzF,kBAAe;IACb;;;;;;;;OAQG;IACH,SAAS,EAAT,mBAAS;IACT;;;;;;;;OAQG;IACH,SAAS,EAAE,mBAAS;IACpB;;;;;;;;;;OAUG;IACH,QAAQ,EAAR,kBAAQ;IACR;;;;;;;;;;OAUG;IACH,QAAQ,EAAE,kBAAQ;IAClB;;;;;;;;;OASG;IACH,SAAS,EAAT,mBAAS;IACT;;;;;;;;;OASG;IACH,SAAS,EAAE,mBAAS;IACpB;;;;;;;OAOG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;;OAOG;IACH,MAAM,EAAE,gBAAM;IACd;;;;;;;;;OASG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;;;;OASG;IACH,MAAM,EAAE,gBAAM;IACd;;;;;;;;OAQ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AAT,mBAAS;IACT;;;;;;;;OAQG;IACH,SAAS,EAAE,mBAAS;IACpB;;;;;;;OAOG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;;OAOG;IACH,MAAM,EAAE,gBAAM;IACd;;;;;;OAMG;IACH,MAAM,EAAN,gBAAM;IACN;;;;;;OAMG;IACH,MAAM,EAAE,gBAAM;IACd;;;;;;;OAOG;IACH,IAAI,EAAJ,cAAI;IACJ;;;;;;;OAOG;IACH,IAAI,EAAE,cAAI;CACX,CAAC","sourcesContent":["import ARRAPPEND from './ARRAPPEND';\nimport ARRINDEX from './ARRINDEX';\nimport ARRINSERT from './ARRINSERT';\nimport ARRLEN from './ARRLEN';\nimport ARRPOP from './ARRPOP';\nimport ARRTRIM from './ARRTRIM';\nimport CLEAR from './CLEAR';\nimport DEBUG_MEMORY from './DEBUG_MEMORY';\nimport DEL from './DEL';\nimport FORGET from './FORGET';\nimport GET from './GET';\nimport MERGE from './MERGE';\nimport MGET from './MGET';\nimport MSET from './MSET';\nimport NUMINCRBY from './NUMINCRBY';\nimport NUMMULTBY from './NUMMULTBY';\nimport OBJKEYS from './OBJKEYS';\nimport OBJLEN from './OBJLEN';\n// import RESP from './RESP';\nimport SET from './SET';\nimport STRAPPEND from './STRAPPEND';\nimport STRLEN from './STRLEN';\nimport TOGGLE from './TOGGLE';\nimport TYPE from './TYPE';\n\n// Re-export helper types and functions from client package\nexport type { RedisJSON } from '@redis/client/dist/lib/commands/generic-transformers';\nexport { transformRedisJsonArgument, transformRedisJsonReply, transformRedisJsonNullReply } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport default {\n /**\n * Appends one or more values to the end of an array in a JSON document.\n * Returns the new array length after append, or null if the path does not exist.\n *\n * @param key - The key to append to\n * @param path - Path to the array in the JSON document\n * @param json - The first value to append\n * @param jsons - Additional values to append\n */\n ARRAPPEND,\n /**\n * Appends one or more values to the end of an array in a JSON document.\n * Returns the new array length after append, or null if the path does not exist.\n *\n * @param key - The key to append to\n * @param path - Path to the array in the JSON document\n * @param json - The first value to append\n * @param jsons - Additional values to append\n */\n arrAppend: ARRAPPEND,\n /**\n * Returns the index of the first occurrence of a value in a JSON array.\n * If the specified value is not found, it returns -1, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param json - The value to search for\n * @param options - Optional range parameters for the search\n * @param options.range.start - Starting index for the search\n * @param options.range.stop - Optional ending index for the search\n */\n ARRINDEX,\n /**\n * Returns the index of the first occurrence of a value in a JSON array.\n * If the specified value is not found, it returns -1, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param json - The value to search for\n * @param options - Optional range parameters for the search\n * @param options.range.start - Starting index for the search\n * @param options.range.stop - Optional ending index for the search\n */\n arrIndex: ARRINDEX,\n /**\n * Inserts one or more values into an array at the specified index.\n * Returns the new array length after insert, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param index - The position where to insert the values\n * @param json - The first value to insert\n * @param jsons - Additional values to insert\n */\n ARRINSERT,\n /**\n * Inserts one or more values into an array at the specified index.\n * Returns the new array length after insert, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param index - The position where to insert the values\n * @param json - The first value to insert\n * @param jsons - Additional values to insert\n */\n arrInsert: ARRINSERT,\n /**\n * Returns the length of an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n */\n ARRLEN,\n /**\n * Returns the length of an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n */\n arrLen: ARRLEN,\n /**\n * Removes and returns an element from an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n * @param options.index - Optional index to pop from. Default is -1 (last element)\n * @param options.reviver - An optional reviver function to call when parsing the reply from Redis\n */\n ARRPOP,\n /**\n * Removes and returns an element from an array in a JSON document.\n * Returns null if the path does not exist or the value is not an array.\n *\n * @param key - The key containing the array\n * @param options - Optional parameters\n * @param options.path - Path to the array in the JSON document\n * @param options.index - Optional index to pop from. Default is -1 (last element)\n * @param options.reviver - An optional reviver function to call when parsing the reply from Redis\n */\n arrPop: ARRPOP,\n /**\n * Trims an array in a JSON document to include only elements within the specified range.\n * Returns the new array length after trimming, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param start - Starting index (inclusive)\n * @param stop - Ending index (inclusive)\n */\n ARRTRIM,\n /**\n * Trims an array in a JSON document to include only elements within the specified range.\n * Returns the new array length after trimming, or null if the path does not exist.\n *\n * @param key - The key containing the array\n * @param path - Path to the array in the JSON document\n * @param start - Starting index (inclusive)\n * @param stop - Ending index (inclusive)\n */\n arrTrim: ARRTRIM,\n /**\n * Clears container values (arrays/objects) in a JSON document.\n * Returns the number of values cleared (0 or 1), or null if the path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the container to clear\n */\n CLEAR,\n /**\n * Clears container values (arrays/objects) in a JSON document.\n * Returns the number of values cleared (0 or 1), or null if the path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the container to clear\n */\n clear: CLEAR,\n /**\n * Reports memory usage details for a JSON document value.\n * Returns size in bytes of the value, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to examine\n */\n DEBUG_MEMORY,\n /**\n * Reports memory usage details for a JSON document value.\n * Returns size in bytes of the value, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to examine\n */\n debugMemory: DEBUG_MEMORY,\n /**\n * Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n DEL,\n /**\n * Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n del: DEL,\n /**\n * Alias for JSON.DEL - Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n FORGET,\n /**\n * Alias for JSON.DEL - Deletes a value from a JSON document.\n * Returns the number of paths deleted (0 or 1), or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the value to delete\n */\n forget: FORGET,\n /**\n * Gets values from a JSON document.\n * Returns the value at the specified path, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path(s) to the value(s) to retrieve\n * @param options.reviver - An optional reviver function to call when parsing the reply from Redis\n */\n GET,\n /**\n * Gets values from a JSON document.\n * Returns the value at the specified path, or null if the key or path does not exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path(s) to the value(s) to retrieve\n * @param options.reviver - An optional reviver function to call when parsing the reply from Redis\n */\n get: GET,\n /**\n * Merges a given JSON value into a JSON document.\n * Returns OK on success, or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to merge into\n * @param value - JSON value to merge\n */\n MERGE,\n /**\n * Merges a given JSON value into a JSON document.\n * Returns OK on success, or null if the key does not exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to merge into\n * @param value - JSON value to merge\n */\n merge: MERGE,\n /**\n * Gets values at a specific path from multiple JSON documents.\n * Returns an array of values at the path from each key, null for missing keys/paths.\n *\n * @param keys - Array of keys containing JSON documents\n * @param path - Path to retrieve from each document\n * @param reviver - An optional reviver function to call when parsing the reply from Redis\n */\n MGET,\n /**\n * Gets values at a specific path from multiple JSON documents.\n * Returns an array of values at the path from each key, null for missing keys/paths.\n *\n * @param keys - Array of keys containing JSON documents\n * @param path - Path to retrieve from each document\n * @param reviver - An optional reviver function to call when parsing the reply from Redis\n */\n mGet: MGET,\n /**\n * Sets multiple JSON values in multiple documents.\n * Returns OK on success.\n *\n * @param items - Array of objects containing key, path, and value to set\n * @param items[].key - The key containing the JSON document\n * @param items[].path - Path in the document to set\n * @param items[].value - JSON value to set at the path\n */\n MSET,\n /**\n * Sets multiple JSON values in multiple documents.\n * Returns OK on success.\n *\n * @param items - Array of objects containing key, path, and value to set\n * @param items[].key - The key containing the JSON document\n * @param items[].path - Path in the document to set\n * @param items[].value - JSON value to set at the path\n */\n mSet: MSET,\n /**\n * Increments a numeric value stored in a JSON document by a given number.\n * Returns the value after increment, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to increment by\n */\n NUMINCRBY,\n /**\n * Increments a numeric value stored in a JSON document by a given number.\n * Returns the value after increment, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to increment by\n */\n numIncrBy: NUMINCRBY,\n /**\n * Multiplies a numeric value stored in a JSON document by a given number.\n * Returns the value after multiplication, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to multiply by\n */\n NUMMULTBY,\n /**\n * Multiplies a numeric value stored in a JSON document by a given number.\n * Returns the value after multiplication, or null if the key/path doesn't exist or value is not numeric.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the numeric value\n * @param by - Amount to multiply by\n */\n numMultBy: NUMMULTBY,\n /**\n * Returns the keys in the object stored in a JSON document.\n * Returns array of keys, array of arrays for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n OBJKEYS,\n /**\n * Returns the keys in the object stored in a JSON document.\n * Returns array of keys, array of arrays for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n objKeys: OBJKEYS,\n /**\n * Returns the number of keys in the object stored in a JSON document.\n * Returns length of object, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n OBJLEN,\n /**\n * Returns the number of keys in the object stored in a JSON document.\n * Returns length of object, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the object to examine\n */\n objLen: OBJLEN,\n // RESP,\n // resp: RESP,\n /**\n * Sets a JSON value at a specific path in a JSON document.\n * Returns OK on success, or null if condition (NX/XX) is not met.\n *\n * @param key - The key containing the JSON document\n * @param path - Path in the document to set\n * @param json - JSON value to set at the path\n * @param options - Optional parameters\n * @param options.condition - Set condition: NX (only if doesn't exist) or XX (only if exists)\n * @deprecated options.NX - Use options.condition instead\n * @deprecated options.XX - Use options.condition instead\n */\n SET,\n /**\n * Sets a JSON value at a specific path in a JSON document.\n * Returns OK on success, or null if condition (NX/XX) is not met.\n *\n * @param key - The key containing the JSON document\n * @param path - Path in the document to set\n * @param json - JSON value to set at the path\n * @param options - Optional parameters\n * @param options.condition - Set condition: NX (only if doesn't exist) or XX (only if exists)\n * @deprecated options.NX - Use options.condition instead\n * @deprecated options.XX - Use options.condition instead\n */\n set: SET,\n /**\n * Appends a string to a string value stored in a JSON document.\n * Returns new string length after append, or null if the path doesn't exist or value is not a string.\n *\n * @param key - The key containing the JSON document\n * @param append - String to append\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n STRAPPEND,\n /**\n * Appends a string to a string value stored in a JSON document.\n * Returns new string length after append, or null if the path doesn't exist or value is not a string.\n *\n * @param key - The key containing the JSON document\n * @param append - String to append\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n strAppend: STRAPPEND,\n /**\n * Returns the length of a string value stored in a JSON document.\n * Returns string length, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n STRLEN,\n /**\n * Returns the length of a string value stored in a JSON document.\n * Returns string length, array of lengths for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to the string value\n */\n strLen: STRLEN,\n /**\n * Toggles a boolean value stored in a JSON document.\n * Returns 1 if value was toggled to true, 0 if toggled to false, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the boolean value\n */\n TOGGLE,\n /**\n * Toggles a boolean value stored in a JSON document.\n * Returns 1 if value was toggled to true, 0 if toggled to false, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param path - Path to the boolean value\n */\n toggle: TOGGLE,\n /**\n * Returns the type of JSON value at a specific path in a JSON document.\n * Returns the type as a string, array of types for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to examine\n */\n TYPE,\n /**\n * Returns the type of JSON value at a specific path in a JSON document.\n * Returns the type as a string, array of types for multiple paths, or null if path doesn't exist.\n *\n * @param key - The key containing the JSON document\n * @param options - Optional parameters\n * @param options.path - Path to examine\n */\n type: TYPE\n};\n"]} |
| import { CommandParser } from '@redis/client/dist/lib/client/parser'; | ||
| import { RedisArgument, UnwrapReply, ArrayReply, NullReply, BlobStringReply } from '@redis/client/dist/lib/RESP/types'; | ||
| import { JsonReviver } from '@redis/client/dist/lib/commands/generic-transformers'; | ||
| declare const _default: { | ||
| readonly IS_READ_ONLY: true; | ||
| readonly parseCommand: (this: void, parser: CommandParser, keys: Array<RedisArgument>, path: RedisArgument) => void; | ||
| readonly transformReply: (this: void, reply: UnwrapReply<ArrayReply<NullReply | BlobStringReply>>) => (import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON | NullReply)[]; | ||
| readonly parseCommand: (this: void, parser: CommandParser, keys: Array<RedisArgument>, path: RedisArgument, reviver?: JsonReviver) => void; | ||
| readonly transformReply: (this: void, reply: UnwrapReply<ArrayReply<NullReply | BlobStringReply>>, reviver?: JsonReviver) => (import("@redis/client/dist/lib/commands/generic-transformers").RedisJSON | NullReply)[]; | ||
| }; | ||
| export default _default; | ||
| //# sourceMappingURL=MGET.d.ts.map |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"MGET.d.ts","sourceRoot":"","sources":["../../../lib/commands/MGET.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,eAAe,EAAW,MAAM,mCAAmC,CAAC;;;gDAKzG,aAAa,QAAQ,MAAM,aAAa,CAAC,QAAQ,aAAa;iDAK7D,YAAY,WAAW,SAAS,GAAG,eAAe,CAAC,CAAC;;AAP5E,wBAU6B"} | ||
| {"version":3,"file":"MGET.d.ts","sourceRoot":"","sources":["../../../lib/commands/MGET.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EACH,aAAa,EACb,WAAW,EACX,UAAU,EACV,SAAS,EACT,eAAe,EAElB,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAEH,WAAW,EACd,MAAM,sDAAsD,CAAC;;;gDAK9C,aAAa,QACf,MAAM,aAAa,CAAC,QACpB,aAAa,YACT,WAAW;iDAOH,YAAY,WAAW,SAAS,GAAG,eAAe,CAAC,CAAC,YAAY,WAAW;;AAbrG,wBAgB6B"} |
@@ -6,11 +6,12 @@ "use strict"; | ||
| IS_READ_ONLY: true, | ||
| parseCommand(parser, keys, path) { | ||
| parseCommand(parser, keys, path, reviver) { | ||
| parser.push('JSON.MGET'); | ||
| parser.pushKeys(keys); | ||
| parser.push(path); | ||
| parser.preserve = reviver; | ||
| }, | ||
| transformReply(reply) { | ||
| return reply.map(json => (0, generic_transformers_1.transformRedisJsonNullReply)(json)); | ||
| } | ||
| transformReply(reply, reviver) { | ||
| return reply.map((json) => (0, generic_transformers_1.transformRedisJsonNullReply)(json, reviver)); | ||
| }, | ||
| }; | ||
| //# sourceMappingURL=MGET.js.map |
@@ -1,1 +0,1 @@ | ||
| {"version":3,"file":"MGET.js","sourceRoot":"","sources":["../../../lib/commands/MGET.ts"],"names":[],"mappings":";;AAEA,+FAAmG;AAEnG,kBAAe;IACb,YAAY,EAAE,IAAI;IAClB,YAAY,CAAC,MAAqB,EAAE,IAA0B,EAAE,IAAmB;QACjF,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;QACzB,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACtB,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACpB,CAAC;IACD,cAAc,CAAC,KAA2D;QACxE,OAAO,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE,CAAC,IAAA,kDAA2B,EAAC,IAAI,CAAC,CAAC,CAAA;IAC7D,CAAC;CACyB,CAAC","sourcesContent":["import { CommandParser } from '@redis/client/dist/lib/client/parser';\nimport { RedisArgument, UnwrapReply, ArrayReply, NullReply, BlobStringReply, Command } from '@redis/client/dist/lib/RESP/types';\nimport { transformRedisJsonNullReply } from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport default {\n IS_READ_ONLY: true,\n parseCommand(parser: CommandParser, keys: Array<RedisArgument>, path: RedisArgument) {\n parser.push('JSON.MGET');\n parser.pushKeys(keys);\n parser.push(path);\n },\n transformReply(reply: UnwrapReply<ArrayReply<NullReply | BlobStringReply>>) {\n return reply.map(json => transformRedisJsonNullReply(json))\n }\n} as const satisfies Command;\n"]} | ||
| {"version":3,"file":"MGET.js","sourceRoot":"","sources":["../../../lib/commands/MGET.ts"],"names":[],"mappings":";;AASA,+FAG8D;AAE9D,kBAAe;IACX,YAAY,EAAE,IAAI;IAClB,YAAY,CACR,MAAqB,EACrB,IAA0B,EAC1B,IAAmB,EACnB,OAAqB;QAErB,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;QACzB,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACtB,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAClB,MAAM,CAAC,QAAQ,GAAG,OAAO,CAAC;IAC9B,CAAC;IACD,cAAc,CAAC,KAA2D,EAAE,OAAqB;QAC7F,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAA,kDAA2B,EAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC;IAC3E,CAAC;CACuB,CAAC","sourcesContent":["import { CommandParser } from '@redis/client/dist/lib/client/parser';\nimport {\n RedisArgument,\n UnwrapReply,\n ArrayReply,\n NullReply,\n BlobStringReply,\n Command,\n} from '@redis/client/dist/lib/RESP/types';\nimport {\n transformRedisJsonNullReply,\n JsonReviver,\n} from '@redis/client/dist/lib/commands/generic-transformers';\n\nexport default {\n IS_READ_ONLY: true,\n parseCommand(\n parser: CommandParser,\n keys: Array<RedisArgument>,\n path: RedisArgument,\n reviver?: JsonReviver,\n ) {\n parser.push('JSON.MGET');\n parser.pushKeys(keys);\n parser.push(path);\n parser.preserve = reviver;\n },\n transformReply(reply: UnwrapReply<ArrayReply<NullReply | BlobStringReply>>, reviver?: JsonReviver) {\n return reply.map((json) => transformRedisJsonNullReply(json, reviver));\n },\n} as const satisfies Command;\n"]} |
+2
-2
| { | ||
| "name": "@redis/json", | ||
| "version": "6.1.0", | ||
| "version": "6.2.0-beta.0", | ||
| "license": "MIT", | ||
@@ -16,3 +16,3 @@ "main": "./dist/lib/index.js", | ||
| "peerDependencies": { | ||
| "@redis/client": "^6.1.0" | ||
| "@redis/client": "^6.2.0-beta.0" | ||
| }, | ||
@@ -19,0 +19,0 @@ "devDependencies": { |
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
165488
2.43%1833
1.5%1
Infinity%