{"ast":null,"code":"\"use strict\";\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.ServerMsg = void 0;\nconst protobuf_decode_js_1 = require(\"../shared/protobuf_decode.js\");\nexports.ServerMsg = {\n default() {\n return {\n type: \"none\"\n };\n },\n 1(r) {\n return {\n type: \"hello_ok\"\n };\n },\n 2(r) {\n return r.message(HelloErrorMsg);\n },\n 3(r) {\n return r.message(ResponseOkMsg);\n },\n 4(r) {\n return r.message(ResponseErrorMsg);\n }\n};\nconst HelloErrorMsg = {\n default() {\n return {\n type: \"hello_error\",\n error: protobuf_decode_js_1.Error.default()\n };\n },\n 1(r, msg) {\n msg.error = r.message(protobuf_decode_js_1.Error);\n }\n};\nconst ResponseErrorMsg = {\n default() {\n return {\n type: \"response_error\",\n requestId: 0,\n error: protobuf_decode_js_1.Error.default()\n };\n },\n 1(r, msg) {\n msg.requestId = r.int32();\n },\n 2(r, msg) {\n msg.error = r.message(protobuf_decode_js_1.Error);\n }\n};\nconst ResponseOkMsg = {\n default() {\n return {\n type: \"response_ok\",\n requestId: 0,\n response: {\n type: \"none\"\n }\n };\n },\n 1(r, msg) {\n msg.requestId = r.int32();\n },\n 2(r, msg) {\n msg.response = {\n type: \"open_stream\"\n };\n },\n 3(r, msg) {\n msg.response = {\n type: \"close_stream\"\n };\n },\n 4(r, msg) {\n msg.response = r.message(ExecuteResp);\n },\n 5(r, msg) {\n msg.response = r.message(BatchResp);\n },\n 6(r, msg) {\n msg.response = {\n type: \"open_cursor\"\n };\n },\n 7(r, msg) {\n msg.response = {\n type: \"close_cursor\"\n };\n },\n 8(r, msg) {\n msg.response = r.message(FetchCursorResp);\n },\n 9(r, msg) {\n msg.response = {\n type: \"sequence\"\n };\n },\n 10(r, msg) {\n msg.response = r.message(DescribeResp);\n },\n 11(r, msg) {\n msg.response = {\n type: \"store_sql\"\n };\n },\n 12(r, msg) {\n msg.response = {\n type: \"close_sql\"\n };\n },\n 13(r, msg) {\n msg.response = r.message(GetAutocommitResp);\n }\n};\nconst ExecuteResp = {\n default() {\n return {\n type: \"execute\",\n result: protobuf_decode_js_1.StmtResult.default()\n };\n },\n 1(r, msg) {\n msg.result = r.message(protobuf_decode_js_1.StmtResult);\n }\n};\nconst BatchResp = {\n default() {\n return {\n type: \"batch\",\n result: protobuf_decode_js_1.BatchResult.default()\n };\n },\n 1(r, msg) {\n msg.result = r.message(protobuf_decode_js_1.BatchResult);\n }\n};\nconst FetchCursorResp = {\n default() {\n return {\n type: \"fetch_cursor\",\n entries: [],\n done: false\n };\n },\n 1(r, msg) {\n msg.entries.push(r.message(protobuf_decode_js_1.CursorEntry));\n },\n 2(r, msg) {\n msg.done = r.bool();\n }\n};\nconst DescribeResp = {\n default() {\n return {\n type: \"describe\",\n result: protobuf_decode_js_1.DescribeResult.default()\n };\n },\n 1(r, msg) {\n msg.result = r.message(protobuf_decode_js_1.DescribeResult);\n }\n};\nconst GetAutocommitResp = {\n default() {\n return {\n type: \"get_autocommit\",\n isAutocommit: false\n };\n },\n 1(r, msg) {\n msg.isAutocommit = r.bool();\n }\n};","map":{"version":3,"names":["Object","defineProperty","exports","value","ServerMsg","protobuf_decode_js_1","require","default","type","r","message","HelloErrorMsg","ResponseOkMsg","ResponseErrorMsg","error","Error","msg","requestId","int32","response","ExecuteResp","BatchResp","FetchCursorResp","DescribeResp","GetAutocommitResp","result","StmtResult","BatchResult","entries","done","push","CursorEntry","bool","DescribeResult","isAutocommit"],"sources":["/Users/shoofle/Projects/the-forest/node_modules/@libsql/hrana-client/lib-cjs/ws/protobuf_decode.js"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.ServerMsg = void 0;\nconst protobuf_decode_js_1 = require(\"../shared/protobuf_decode.js\");\nexports.ServerMsg = {\n default() { return { type: \"none\" }; },\n 1(r) { return { type: \"hello_ok\" }; },\n 2(r) { return r.message(HelloErrorMsg); },\n 3(r) { return r.message(ResponseOkMsg); },\n 4(r) { return r.message(ResponseErrorMsg); },\n};\nconst HelloErrorMsg = {\n default() { return { type: \"hello_error\", error: protobuf_decode_js_1.Error.default() }; },\n 1(r, msg) { msg.error = r.message(protobuf_decode_js_1.Error); },\n};\nconst ResponseErrorMsg = {\n default() { return { type: \"response_error\", requestId: 0, error: protobuf_decode_js_1.Error.default() }; },\n 1(r, msg) { msg.requestId = r.int32(); },\n 2(r, msg) { msg.error = r.message(protobuf_decode_js_1.Error); },\n};\nconst ResponseOkMsg = {\n default() {\n return {\n type: \"response_ok\",\n requestId: 0,\n response: { type: \"none\" },\n };\n },\n 1(r, msg) { msg.requestId = r.int32(); },\n 2(r, msg) { msg.response = { type: \"open_stream\" }; },\n 3(r, msg) { msg.response = { type: \"close_stream\" }; },\n 4(r, msg) { msg.response = r.message(ExecuteResp); },\n 5(r, msg) { msg.response = r.message(BatchResp); },\n 6(r, msg) { msg.response = { type: \"open_cursor\" }; },\n 7(r, msg) { msg.response = { type: \"close_cursor\" }; },\n 8(r, msg) { msg.response = r.message(FetchCursorResp); },\n 9(r, msg) { msg.response = { type: \"sequence\" }; },\n 10(r, msg) { msg.response = r.message(DescribeResp); },\n 11(r, msg) { msg.response = { type: \"store_sql\" }; },\n 12(r, msg) { msg.response = { type: \"close_sql\" }; },\n 13(r, msg) { msg.response = r.message(GetAutocommitResp); },\n};\nconst ExecuteResp = {\n default() { return { type: \"execute\", result: protobuf_decode_js_1.StmtResult.default() }; },\n 1(r, msg) { msg.result = r.message(protobuf_decode_js_1.StmtResult); },\n};\nconst BatchResp = {\n default() { return { type: \"batch\", result: protobuf_decode_js_1.BatchResult.default() }; },\n 1(r, msg) { msg.result = r.message(protobuf_decode_js_1.BatchResult); },\n};\nconst FetchCursorResp = {\n default() { return { type: \"fetch_cursor\", entries: [], done: false }; },\n 1(r, msg) { msg.entries.push(r.message(protobuf_decode_js_1.CursorEntry)); },\n 2(r, msg) { msg.done = r.bool(); },\n};\nconst DescribeResp = {\n default() { return { type: \"describe\", result: protobuf_decode_js_1.DescribeResult.default() }; },\n 1(r, msg) { msg.result = r.message(protobuf_decode_js_1.DescribeResult); },\n};\nconst GetAutocommitResp = {\n default() { return { type: \"get_autocommit\", isAutocommit: false }; },\n 1(r, msg) { msg.isAutocommit = r.bool(); },\n};\n"],"mappings":"AAAA,YAAY;;AACZA,MAAM,CAACC,cAAc,CAACC,OAAO,EAAE,YAAY,EAAE;EAAEC,KAAK,EAAE;AAAK,CAAC,CAAC;AAC7DD,OAAO,CAACE,SAAS,GAAG,KAAK,CAAC;AAC1B,MAAMC,oBAAoB,GAAGC,OAAO,CAAC,8BAA8B,CAAC;AACpEJ,OAAO,CAACE,SAAS,GAAG;EAChBG,OAAOA,CAAA,EAAG;IAAE,OAAO;MAAEC,IAAI,EAAE;IAAO,CAAC;EAAE,CAAC;EACtC,CAAC,CAACC,CAAC,EAAE;IAAE,OAAO;MAAED,IAAI,EAAE;IAAW,CAAC;EAAE,CAAC;EACrC,CAAC,CAACC,CAAC,EAAE;IAAE,OAAOA,CAAC,CAACC,OAAO,CAACC,aAAa,CAAC;EAAE,CAAC;EACzC,CAAC,CAACF,CAAC,EAAE;IAAE,OAAOA,CAAC,CAACC,OAAO,CAACE,aAAa,CAAC;EAAE,CAAC;EACzC,CAAC,CAACH,CAAC,EAAE;IAAE,OAAOA,CAAC,CAACC,OAAO,CAACG,gBAAgB,CAAC;EAAE;AAC/C,CAAC;AACD,MAAMF,aAAa,GAAG;EAClBJ,OAAOA,CAAA,EAAG;IAAE,OAAO;MAAEC,IAAI,EAAE,aAAa;MAAEM,KAAK,EAAET,oBAAoB,CAACU,KAAK,CAACR,OAAO,CAAC;IAAE,CAAC;EAAE,CAAC;EAC1F,CAAC,CAACE,CAAC,EAAEO,GAAG,EAAE;IAAEA,GAAG,CAACF,KAAK,GAAGL,CAAC,CAACC,OAAO,CAACL,oBAAoB,CAACU,KAAK,CAAC;EAAE;AACnE,CAAC;AACD,MAAMF,gBAAgB,GAAG;EACrBN,OAAOA,CAAA,EAAG;IAAE,OAAO;MAAEC,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