the-forest/client/node_modules/.cache/babel-loader/a6569f125b1a9af4df9ab5c48b7508646d0f86256b11baa007d5e80065036190.json

1 line
14 KiB
JSON
Raw Normal View History

2024-09-17 20:35:18 -04:00
{"ast":null,"code":"export const Error = {\n default() {\n return {\n message: \"\",\n code: undefined\n };\n },\n 1(r, msg) {\n msg.message = r.string();\n },\n 2(r, msg) {\n msg.code = r.string();\n }\n};\nexport const StmtResult = {\n default() {\n return {\n cols: [],\n rows: [],\n affectedRowCount: 0,\n lastInsertRowid: undefined\n };\n },\n 1(r, msg) {\n msg.cols.push(r.message(Col));\n },\n 2(r, msg) {\n msg.rows.push(r.message(Row));\n },\n 3(r, msg) {\n msg.affectedRowCount = Number(r.uint64());\n },\n 4(r, msg) {\n msg.lastInsertRowid = r.sint64();\n }\n};\nconst Col = {\n default() {\n return {\n name: undefined,\n decltype: undefined\n };\n },\n 1(r, msg) {\n msg.name = r.string();\n },\n 2(r, msg) {\n msg.decltype = r.string();\n }\n};\nconst Row = {\n default() {\n return [];\n },\n 1(r, msg) {\n msg.push(r.message(Value));\n }\n};\nexport const BatchResult = {\n default() {\n return {\n stepResults: new Map(),\n stepErrors: new Map()\n };\n },\n 1(r, msg) {\n const [key, value] = r.message(BatchResultStepResult);\n msg.stepResults.set(key, value);\n },\n 2(r, msg) {\n const [key, value] = r.message(BatchResultStepError);\n msg.stepErrors.set(key, value);\n }\n};\nconst BatchResultStepResult = {\n default() {\n return [0, StmtResult.default()];\n },\n 1(r, msg) {\n msg[0] = r.uint32();\n },\n 2(r, msg) {\n msg[1] = r.message(StmtResult);\n }\n};\nconst BatchResultStepError = {\n default() {\n return [0, Error.default()];\n },\n 1(r, msg) {\n msg[0] = r.uint32();\n },\n 2(r, msg) {\n msg[1] = r.message(Error);\n }\n};\nexport const CursorEntry = {\n default() {\n return {\n type: \"none\"\n };\n },\n 1(r) {\n return r.message(StepBeginEntry);\n },\n 2(r) {\n return r.message(StepEndEntry);\n },\n 3(r) {\n return r.message(StepErrorEntry);\n },\n 4(r) {\n return {\n type: \"row\",\n row: r.message(Row)\n };\n },\n 5(r) {\n return {\n type: \"error\",\n error: r.message(Error)\n };\n }\n};\nconst StepBeginEntry = {\n default() {\n return {\n type: \"step_begin\",\n step: 0,\n cols: []\n };\n },\n 1(r, msg) {\n msg.step = r.uint32();\n },\n 2(r, msg) {\n msg.cols.push(r.message(Col));\n }\n};\nconst StepEndEntry = {\n default() {\n return {\n type: \"step_end\",\n affectedRowCount: 0,\n lastInsertRowid: undefined\n };\n },\n 1(r, msg) {\n msg.affectedRowCount = r.uint32();\n },\n 2(r, msg) {\n msg.lastInsertRowid = r.uint64();\n }\n};\nconst StepErrorEntry = {\n default() {\n return {\n type: \"step_error\",\n step: 0,\n error: Error.default()\n };\n },\n 1(r, msg) {\n msg.step = r.uint32();\n },\n 2(r, msg) {\n msg.error = r.message(Error);\n }\n};\nexport const DescribeResult = {\n default() {\n return {\n params: [],\n cols: [],\n isExplain: false,\n isReadonly: false\n };\n },\n 1(r, msg) {\n msg.params.push(r.message(DescribeParam));\n },\n 2(r, msg) {\n msg.cols.push(r.message(DescribeCol));\n },\n 3(r, msg) {\n msg.isExplain = r.bool();\n },\n 4(r, msg) {\n msg.isReadonly = r.bool();\n }\n};\nconst DescribeParam = {\n default() {\n return {\n name: undefined\n };\n },\n 1(r, msg) {\n msg.name = r.string();\n }\n};\nconst DescribeCol = {\n default() {\n return {\n name: \"\",\n decltype: undefined\n };\n },\n 1(r, msg) {\n msg.name = r.string();\n },\n 2(r, msg) {\n msg.decltype = r.string();\n }\n};\nconst Value = {\n default() {\n return undefined;\n },\n 1(r) {\n return null;\n },\n 2(r) {\n return r.sint64();\n },\n 3(r) {\n return r.double();\n },\n 4(r) {\n return r.string();\n },\n 5(r) {\n return r.bytes();\n }\n};","map":{"version":3,"names":["Error","default","message","code","undefined","r","msg","string","StmtResult","cols","rows","affe