@sentio/sdk-bundle 4.1.0-rc.3 → 4.2.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{0x1-DsRLSNfp.js → 0x1-CxjK7WJe.js} +4 -4
- package/dist/{0x1-DsRLSNfp.js.map → 0x1-CxjK7WJe.js.map} +1 -1
- package/dist/aptos/builtin/0x1.js +1 -1
- package/dist/aptos/builtin/0x3.js +2 -2
- package/dist/aptos/builtin/0x4.js +2 -2
- package/dist/aptos/builtin/index.js +1 -1
- package/dist/aptos/ext/index.js +2 -2
- package/dist/aptos/index.js +2 -2
- package/dist/{aptos-Bkm5LunO.js → aptos-SxoSnw0E.js} +5 -6
- package/dist/{aptos-Bkm5LunO.js.map → aptos-SxoSnw0E.js.map} +1 -1
- package/dist/{coin-DcELdVP_.js → coin-COPlhTta.js} +3 -3
- package/dist/{coin-DcELdVP_.js.map → coin-COPlhTta.js.map} +1 -1
- package/dist/{coin-BDJBo_lb.js → coin-q8Sm__yo.js} +3 -3
- package/dist/{coin-BDJBo_lb.js.map → coin-q8Sm__yo.js.map} +1 -1
- package/dist/core/index.js +1 -1
- package/dist/{core-BElsJ1pw.js → core-DUPgecQ_.js} +3 -3
- package/dist/core-DUPgecQ_.js.map +1 -0
- package/dist/{decode-worker-C7q_r8x3.js → decode-worker-DWPnMAj8.js} +2 -2
- package/dist/{decode-worker-C7q_r8x3.js.map → decode-worker-DWPnMAj8.js.map} +1 -1
- package/dist/eth/abi-decoder/decode-worker.js +1 -1
- package/dist/eth/builtin/eacaggregatorproxy.js +1 -1
- package/dist/eth/builtin/erc1155.js +3 -3
- package/dist/eth/builtin/erc20.js +1 -1
- package/dist/eth/builtin/erc721.js +1 -1
- package/dist/eth/builtin/index.js +1 -1
- package/dist/eth/builtin/weth9.js +3 -3
- package/dist/eth/index.js +2 -2
- package/dist/fuel/index.js +1 -1
- package/dist/{fuel-C9Y84R8S.js → fuel-CEx3LV5U.js} +3 -4
- package/dist/{fuel-C9Y84R8S.js.map → fuel-CEx3LV5U.js.map} +1 -1
- package/dist/{handler-register-DU3CwNoM.js → handler-register-BI6hAdDh.js} +2 -2
- package/dist/{handler-register-DU3CwNoM.js.map → handler-register-BI6hAdDh.js.map} +1 -1
- package/dist/index.js +1 -1
- package/dist/iota/builtin/0x1.js +3 -3
- package/dist/iota/builtin/0x2.js +3 -3
- package/dist/iota/builtin/0x3.js +3 -3
- package/dist/iota/ext/index.js +1 -1
- package/dist/iota/index.js +3 -3
- package/dist/move/index.js +1 -1
- package/dist/{move-BHEDP8e5.js → move-BuzfbmGq.js} +2 -2
- package/dist/{move-BHEDP8e5.js.map → move-BuzfbmGq.js.map} +1 -1
- package/dist/solana/builtin/index.js +1 -1
- package/dist/solana/index.js +1 -1
- package/dist/{solana-CjV1K7WR.js → solana-BC0uJEJ-.js} +2 -2
- package/dist/{solana-CjV1K7WR.js.map → solana-BC0uJEJ-.js.map} +1 -1
- package/dist/store/index.js +1 -1
- package/dist/sui/builtin/0x1.js +1 -1
- package/dist/sui/builtin/0x2.js +4 -4
- package/dist/sui/builtin/0x3.js +4 -4
- package/dist/sui/builtin/index.js +1 -1
- package/dist/sui/ext/index.js +1 -1
- package/dist/sui/index.js +3 -3
- package/dist/{sui-DCf9ZKVa.js → sui-Bu13HeOq.js} +6 -10
- package/dist/sui-Bu13HeOq.js.map +1 -0
- package/dist/testing/index.js +12 -9
- package/dist/testing/index.js.map +1 -1
- package/dist/utils/index.js +1 -1
- package/dist/{utils-D3qk3_rF.js → utils-mQf0fx8l.js} +4 -5
- package/dist/{utils-D3qk3_rF.js.map → utils-mQf0fx8l.js.map} +1 -1
- package/package.json +2 -2
- package/dist/core-BElsJ1pw.js.map +0 -1
- package/dist/sui-DCf9ZKVa.js.map +0 -1
package/dist/move/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { A as structQname, C as accountTypeString, D as moduleQname, E as isValidMoveAddress, O as moduleQnameForType, S as accountAddressString, T as isFrameworkAccount, _ as matchType, a as ObjectChangeHandler, b as SPLITTER, c as TransactionIntervalHandler, d as ChainAdapter, f as AccountModulesImportInfo, g as TypeDescriptor, h as BUILTIN_TYPES, i as EventHandler, j as upperFirst, k as normalizeToJSName, l as InternalMoveFunctionVisibility, m as ANY_TYPE, n as MoveContext, o as ResourceChangeHandler, p as AccountRegister, r as CallHandler, s as ResourceIntervalHandler, t as MoveAccountContext, u as AbstractMoveCoder, v as parseMoveType, w as camel, x as VECTOR_STR, y as vectorType } from "../move-
|
|
1
|
+
import { A as structQname, C as accountTypeString, D as moduleQname, E as isValidMoveAddress, O as moduleQnameForType, S as accountAddressString, T as isFrameworkAccount, _ as matchType, a as ObjectChangeHandler, b as SPLITTER, c as TransactionIntervalHandler, d as ChainAdapter, f as AccountModulesImportInfo, g as TypeDescriptor, h as BUILTIN_TYPES, i as EventHandler, j as upperFirst, k as normalizeToJSName, l as InternalMoveFunctionVisibility, m as ANY_TYPE, n as MoveContext, o as ResourceChangeHandler, p as AccountRegister, r as CallHandler, s as ResourceIntervalHandler, t as MoveAccountContext, u as AbstractMoveCoder, v as parseMoveType, w as camel, x as VECTOR_STR, y as vectorType } from "../move-BuzfbmGq.js";
|
|
2
2
|
|
|
3
3
|
export { ANY_TYPE, AbstractMoveCoder, AccountModulesImportInfo, AccountRegister, BUILTIN_TYPES, CallHandler, ChainAdapter, EventHandler, InternalMoveFunctionVisibility, MoveAccountContext, MoveContext, ObjectChangeHandler, ResourceChangeHandler, ResourceIntervalHandler, SPLITTER, TransactionIntervalHandler, TypeDescriptor, VECTOR_STR, accountAddressString, accountTypeString, camel, isFrameworkAccount, isValidMoveAddress, matchType, moduleQname, moduleQnameForType, normalizeToJSName, parseMoveType, structQname, upperFirst, vectorType };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as __name } from "./bignumber-DddanwOv.js";
|
|
2
|
-
import { o as BaseContext } from "./core-
|
|
2
|
+
import { o as BaseContext } from "./core-DUPgecQ_.js";
|
|
3
3
|
|
|
4
4
|
//#region ../../node_modules/.pnpm/radash@12.1.1/node_modules/radash/dist/esm/string.mjs
|
|
5
5
|
const capitalize = (str) => {
|
|
@@ -733,4 +733,4 @@ var MoveAccountContext = class extends BaseContext {
|
|
|
733
733
|
|
|
734
734
|
//#endregion
|
|
735
735
|
export { structQname as A, accountTypeString as C, moduleQname as D, isValidMoveAddress as E, moduleQnameForType as O, accountAddressString as S, isFrameworkAccount as T, matchType as _, ObjectChangeHandler as a, SPLITTER as b, TransactionIntervalHandler as c, ChainAdapter as d, AccountModulesImportInfo as f, TypeDescriptor as g, BUILTIN_TYPES as h, EventHandler as i, upperFirst as j, normalizeToJSName as k, InternalMoveFunctionVisibility as l, ANY_TYPE as m, MoveContext as n, ResourceChangeHandler as o, AccountRegister as p, CallHandler as r, ResourceIntervalHandler as s, MoveAccountContext as t, AbstractMoveCoder as u, parseMoveType as v, camel as w, VECTOR_STR as x, vectorType as y };
|
|
736
|
-
//# sourceMappingURL=move-
|
|
736
|
+
//# sourceMappingURL=move-BuzfbmGq.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"move-BHEDP8e5.js","names":["camel","camelRadash"],"sources":["../../../node_modules/.pnpm/radash@12.1.1/node_modules/radash/dist/esm/string.mjs","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/utils.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/types.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/account.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/chain-adapter.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/abstract-move-coder.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/internal-models.js","../src/move/filter.ts","../src/move/move-context.ts"],"sourcesContent":["const capitalize = (str) => {\n if (!str || str.length === 0)\n return \"\";\n const lower = str.toLowerCase();\n return lower.substring(0, 1).toUpperCase() + lower.substring(1, lower.length);\n};\nconst camel = (str) => {\n const parts = str?.replace(/([A-Z])+/g, capitalize)?.split(/(?=[A-Z])|[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n if (parts.length === 1)\n return parts[0];\n return parts.reduce((acc, part) => {\n return `${acc}${part.charAt(0).toUpperCase()}${part.slice(1)}`;\n });\n};\nconst snake = (str, options) => {\n const parts = str?.replace(/([A-Z])+/g, capitalize).split(/(?=[A-Z])|[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n if (parts.length === 1)\n return parts[0];\n const result = parts.reduce((acc, part) => {\n return `${acc}_${part.toLowerCase()}`;\n });\n return options?.splitOnNumber === false ? result : result.replace(/([A-Za-z]{1}[0-9]{1})/, (val) => `${val[0]}_${val[1]}`);\n};\nconst dash = (str) => {\n const parts = str?.replace(/([A-Z])+/g, capitalize)?.split(/(?=[A-Z])|[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n if (parts.length === 1)\n return parts[0];\n return parts.reduce((acc, part) => {\n return `${acc}-${part.toLowerCase()}`;\n });\n};\nconst pascal = (str) => {\n const parts = str?.split(/[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n return parts.map((str2) => str2.charAt(0).toUpperCase() + str2.slice(1)).join(\"\");\n};\nconst title = (str) => {\n if (!str)\n return \"\";\n return str.split(/(?=[A-Z])|[\\.\\-\\s_]/).map((s) => s.trim()).filter((s) => !!s).map((s) => capitalize(s.toLowerCase())).join(\" \");\n};\nconst template = (str, data, regex = /\\{\\{(.+?)\\}\\}/g) => {\n return Array.from(str.matchAll(regex)).reduce((acc, match) => {\n return acc.replace(match[0], data[match[1]]);\n }, str);\n};\nconst trim = (str, charsToTrim = \" \") => {\n if (!str)\n return \"\";\n const toTrim = charsToTrim.replace(/[\\W]{1}/g, \"\\\\$&\");\n const regex = new RegExp(`^[${toTrim}]+|[${toTrim}]+$`, \"g\");\n return str.replace(regex, \"\");\n};\n\nexport { camel, capitalize, dash, pascal, snake, template, title, trim };\n//# sourceMappingURL=string.mjs.map\n","import { camel as camelRadash } from 'radash';\nexport const SPLITTER = '::';\nexport const VECTOR_STR = 'vector';\nexport function isFrameworkAccount(account) {\n const n = parseInt(account, 16);\n if (Number.isNaN(n)) {\n return false;\n }\n return n >= 0 && n < 16;\n}\n// strip any lead 0\nexport function accountTypeString(account) {\n const withoutPrefix = account.toLowerCase().replace(/^(0x)/, '');\n return '0x' + withoutPrefix.replace(/^0*/, '');\n}\nconst MOVE_ADDRESS_LENGTH = 32;\nfunction isHex(value) {\n return /^(0x|0X)?[a-fA-F0-9]+$/.test(value);\n}\nfunction getHexByteLength(value) {\n return /^(0x|0X)/.test(value) ? (value.length - 2) / 2 : value.length / 2;\n}\nexport function isValidMoveAddress(value) {\n return isHex(value) && getHexByteLength(value) <= MOVE_ADDRESS_LENGTH;\n}\n// Get full address with 32 bytes\nexport function accountAddressString(account) {\n if (!isValidMoveAddress(account)) {\n throw Error('Not valid move address');\n }\n const address = account.toLowerCase().replace(/^(0x)/, '');\n return `0x${address.padStart(MOVE_ADDRESS_LENGTH * 2, '0')}`;\n}\n// https://github.com/microsoft/TypeScript/issues/2536\nconst KEYWORDS = new Set([\n 'break',\n 'case',\n 'catch',\n 'class',\n 'const',\n 'continue',\n 'debugger',\n 'default',\n 'delete',\n 'do',\n 'else',\n 'enum',\n 'export',\n 'extends',\n 'false',\n 'finally',\n 'for',\n 'function',\n 'if',\n 'import',\n 'in',\n 'instanceof',\n 'new',\n 'null',\n 'return',\n 'super',\n 'switch',\n 'this',\n 'throw',\n 'true',\n 'try',\n 'typeof',\n 'var',\n 'void',\n 'while',\n 'with',\n 'as',\n 'implements',\n 'interface',\n 'let',\n 'package',\n 'private',\n 'protected',\n 'public',\n 'static',\n 'yield',\n 'any',\n 'boolean',\n 'constructor',\n 'declare',\n // 'get',\n 'module',\n // 'require',\n 'number',\n // 'set',\n 'string',\n 'symbol',\n 'type',\n 'from',\n // 'of',\n 'async',\n 'await',\n 'bigint',\n 'object',\n 'volatile',\n 'namespace',\n 'arguments'\n]);\nexport function normalizeToJSName(name) {\n if (KEYWORDS.has(name)) {\n return name + '$';\n }\n return name;\n}\nexport function moduleQnameForType(type) {\n const parts = type.split(SPLITTER).slice(0, 2);\n return [parts[0], parts[1]];\n}\nexport function moduleQname(module) {\n return accountTypeString(module.address) + SPLITTER + module.name;\n}\nexport function structQname(module, struct) {\n return [accountTypeString(module.address), module.name, struct.name].join(SPLITTER);\n}\nexport function upperFirst(str) {\n return str.charAt(0).toUpperCase() + str.slice(1);\n}\nexport function camel(str) {\n const base = camelRadash(str);\n return str.endsWith('_') ? base + '_' : base;\n}\n//# sourceMappingURL=utils.js.map","import { accountTypeString, SPLITTER, VECTOR_STR } from './utils.js';\nexport class TypeDescriptor {\n qname;\n reference;\n mutable;\n typeArgs;\n constructor(symbol, typeParams) {\n this.qname = symbol;\n this.reference = false;\n this.mutable = false;\n this.typeArgs = typeParams || [];\n }\n apply(...typeArgs) {\n const newObj = this.clone();\n newObj.typeArgs = typeArgs;\n return newObj;\n }\n clone() {\n const newObj = new TypeDescriptor(this.qname, this.typeArgs);\n newObj.reference = this.reference;\n newObj.mutable = this.mutable;\n return newObj;\n }\n // compare qname without consider case for system type\n compareQname(t) {\n let t1 = this.qname;\n if (BUILTIN_TYPES_SET.has(this.qname.toLowerCase())) {\n t1 = this.qname.toLowerCase();\n }\n let t2 = t.qname;\n if (BUILTIN_TYPES_SET.has(t.qname.toLowerCase())) {\n t2 = t.qname;\n }\n return t1 === t2;\n }\n getSignature() {\n if (this.typeArgs.length > 0) {\n return this.qname + '<' + this.typeArgs.map((t) => t.getSignature()).join(', ') + '>';\n }\n return this.qname;\n }\n // Make U8, U16, etc => u8, u16\n getNormalizedSignature() {\n let qname = this.qname;\n switch (qname) {\n case 'U8':\n case 'U16':\n case 'U32':\n case 'U64':\n case 'U128':\n case 'U256':\n case 'Vector':\n case 'Bool':\n case 'Address':\n qname = qname.toLowerCase();\n }\n if (this.typeArgs.length > 0) {\n return qname + '<' + this.typeArgs.map((t) => t.getNormalizedSignature()).join(', ') + '>';\n }\n return qname;\n }\n // Replace T0, T1 with more concrete type\n applyTypeArgs(ctx) {\n const replace = ctx.get(this.qname);\n if (replace) {\n return replace;\n }\n if (ctx.size === 0 || this.typeArgs.length === 0) {\n return this;\n }\n const typeArgs = [];\n for (const arg of this.typeArgs) {\n const replace = ctx.get(arg.qname);\n if (replace) {\n typeArgs.push(replace);\n }\n else {\n typeArgs.push(arg.applyTypeArgs(ctx));\n }\n }\n return new TypeDescriptor(this.qname, typeArgs);\n }\n // all depended types including itself, not include system type\n dependedTypes() {\n if (this.qname.startsWith('&')) {\n console.error('Not expected &');\n return [];\n }\n // Handle closure/lambda types: |&mut T1|T2 or |T1, T2|T3\n if (this.qname.startsWith('|')) {\n // Closure types are function types, not module dependencies\n // The actual type dependencies are in the typeArgs if any\n const types = new Set();\n for (const param of this.typeArgs) {\n param.dependedTypes().forEach((t) => types.add(t));\n }\n return Array.from(types);\n }\n if (this.isVector()) {\n return this.typeArgs[0].dependedTypes();\n }\n if (BUILTIN_TYPES_SET.has(this.qname.toLowerCase())) {\n return [];\n }\n switch (this.qname) {\n case 'signer':\n case '0x1::string::String':\n return [];\n }\n // Type parameters are not depended\n if (this.qname.indexOf(SPLITTER) == -1) {\n if (this.qname.startsWith('T')) {\n return [];\n }\n }\n const types = new Set();\n for (const param of this.typeArgs) {\n param.dependedTypes().forEach((t) => types.add(t));\n }\n types.add(this.qname);\n return Array.from(types);\n }\n isVector() {\n return this.qname.toLowerCase() === VECTOR_STR;\n }\n existAnyType() {\n if (this.qname === 'any') {\n return true;\n }\n for (const param of this.typeArgs) {\n if (param.existAnyType()) {\n return true;\n }\n }\n return false;\n }\n name() {\n const parts = this.qname.split(SPLITTER);\n return parts[parts.length - 1];\n }\n module() {\n const parts = this.qname.split(SPLITTER);\n return parts[parts.length - 2];\n }\n}\nexport function parseMoveType(type) {\n if (type === undefined) {\n console.log('');\n }\n // Aptos SDK 7+ exposes Move closure / function-value types in ABIs as\n // `|param1, param2, ...| ret`. Parse them specially — the inner params and\n // return type are nested and recursively parsed; the descriptor's qname is\n // the sentinel `|fn|` (other code in this file branches on qname.startsWith('|')).\n const closure = tryParseClosure(type);\n if (closure) {\n return closure;\n }\n const stack = [new TypeDescriptor('')];\n let buffer = [];\n // xxx:asdf<g1<a,<c,d>>, b, g2<a,b>, e>\n for (let i = 0; i < type.length; i++) {\n const ch = type[i];\n if (ch === ' ') {\n continue;\n }\n if (ch === '<') {\n // const symbol = type.slice(symbolStart, i)\n // symbolStart =\n const symbol = buffer.join('');\n buffer = [];\n stack[stack.length - 1].qname = symbol;\n adjustType(stack[stack.length - 1]);\n stack.push(new TypeDescriptor(''));\n continue;\n }\n if (ch === '>' || ch === ',') {\n const typeParam = stack.pop();\n if (!typeParam) {\n throw Error('Unexpected stack size');\n }\n if (buffer.length > 0) {\n typeParam.qname = buffer.join('');\n buffer = [];\n }\n adjustType(typeParam);\n stack[stack.length - 1].typeArgs.push(typeParam);\n if (ch === ',') {\n stack.push(new TypeDescriptor(''));\n }\n continue;\n }\n buffer.push(ch);\n }\n if (buffer.length > 0) {\n stack[stack.length - 1].qname = buffer.join('');\n }\n adjustType(stack[stack.length - 1]);\n const res = stack.pop();\n if (!res || stack.length > 0) {\n throw Error('Unexpected stack size');\n }\n return res;\n}\n// Parse `|param1, param2, ...| return_type` (Aptos Move closure / function-value\n// types exposed by SDK 7+). Returns undefined if the input is not a closure.\n// Commas and the closing `|` are matched at angle-bracket depth 0.\nfunction tryParseClosure(type) {\n let i = 0;\n while (i < type.length && type[i] === ' ')\n i++;\n if (type[i] !== '|')\n return undefined;\n let depth = 0;\n let close = -1;\n for (let j = i + 1; j < type.length; j++) {\n const ch = type[j];\n if (ch === '<')\n depth++;\n else if (ch === '>')\n depth--;\n else if (ch === '|' && depth === 0) {\n close = j;\n break;\n }\n }\n if (close < 0)\n return undefined;\n const inner = type.slice(i + 1, close);\n const ret = type.slice(close + 1).trim();\n const paramTypes = [];\n if (inner.trim().length > 0) {\n let depth2 = 0;\n let start = 0;\n for (let k = 0; k <= inner.length; k++) {\n const ch = inner[k];\n if (k === inner.length || (ch === ',' && depth2 === 0)) {\n const piece = inner.slice(start, k).trim();\n if (piece.length > 0)\n paramTypes.push(parseMoveType(piece));\n start = k + 1;\n }\n else if (ch === '<')\n depth2++;\n else if (ch === '>')\n depth2--;\n }\n }\n const typeArgs = paramTypes.slice();\n if (ret.length > 0)\n typeArgs.push(parseMoveType(ret));\n return new TypeDescriptor('|fn|', typeArgs);\n}\nfunction adjustType(type) {\n if (type.qname.startsWith('&')) {\n type.reference = true;\n type.qname = type.qname.slice(1);\n }\n if (type.qname.startsWith('mut')) {\n type.mutable = true;\n type.qname = type.qname.slice(3);\n }\n const parts = type.qname.split(SPLITTER);\n if (parts.length > 1) {\n const [account, module, name] = parts;\n type.qname = [accountTypeString(account), module, name].join(SPLITTER);\n }\n}\nexport const ANY_TYPE = new TypeDescriptor('any');\nexport function vectorType(t = ANY_TYPE) {\n return BUILTIN_TYPES.VECTOR_TYPE_ANY.apply(t);\n}\nexport const BUILTIN_TYPES = {\n ADDRESS_TYPE: new TypeDescriptor('address'),\n VECTOR_TYPE_ANY: new TypeDescriptor('vector'),\n VECTOR_TYPE: vectorType,\n BOOL_TYPE: new TypeDescriptor('bool'),\n U8_TYPE: new TypeDescriptor('u8'),\n U16_TYPE: new TypeDescriptor('u16'),\n U32_TYPE: new TypeDescriptor('u32'),\n U64_TYPE: new TypeDescriptor('u64'),\n U128_TYPE: new TypeDescriptor('u128'),\n U256_TYPE: new TypeDescriptor('u256')\n};\nconst BUILTIN_TYPES_SET = new Set(Object.values(BUILTIN_TYPES).flatMap((t) => {\n if (typeof t === 'object') {\n return [t.qname.toLowerCase()];\n }\n return [];\n}));\n/**\n *\n * @param matcher\n * @param type\n */\nexport function matchType(matcher, type) {\n if (matcher.qname === 'any') {\n return true;\n }\n if (!matcher.compareQname(type)) {\n return false;\n }\n for (const [idx, matcherTarg] of matcher.typeArgs.entries()) {\n const targ = type.typeArgs[idx];\n if (!matchType(matcherTarg, targ)) {\n return false;\n }\n }\n return true;\n}\n//# sourceMappingURL=types.js.map","import { moduleQname, moduleQnameForType } from './utils.js';\nexport class AccountModulesImportInfo {\n // account to module\n imports;\n account;\n moduleName;\n constructor(account, tsModuleName) {\n this.account = account;\n this.moduleName = tsModuleName;\n this.imports = new Map();\n }\n addImport(account, module) {\n if (account === this.account) {\n return;\n }\n let accountModules = this.imports.get(account);\n if (!accountModules) {\n accountModules = new Set();\n this.imports.set(account, accountModules);\n }\n accountModules.add(module);\n }\n}\nexport class AccountRegister {\n accountImports = new Map();\n pendingAccounts = new Set();\n register(module, tsModuleName) {\n const currentModuleFqn = moduleQname(module);\n let accountModuleImports = this.accountImports.get(module.address);\n if (!accountModuleImports) {\n accountModuleImports = new AccountModulesImportInfo(module.address, tsModuleName);\n this.accountImports.set(module.address, accountModuleImports);\n // the account has already be processed, delete pending task\n this.pendingAccounts.delete(module.address);\n }\n this.registerStruct(module, accountModuleImports);\n this.registerFunctions(module, accountModuleImports);\n this.accountImports.set(currentModuleFqn, accountModuleImports);\n return accountModuleImports;\n }\n registerFunctions(module, accountModuleImports) {\n for (const func of module.exposedFunctions) {\n // if (!func.isEntry) {\n // continue\n // }\n for (const param of func.params.concat(func.return)) {\n for (const type of param.dependedTypes()) {\n const [account, module] = moduleQnameForType(type);\n accountModuleImports.addImport(account, module);\n if (!this.accountImports.has(account)) {\n this.pendingAccounts.add(account);\n }\n }\n }\n }\n }\n registerStruct(module, accountModuleImports) {\n for (const struct of module.structs) {\n for (const field of struct.fields) {\n for (const type of field.type.dependedTypes()) {\n const [account, module] = moduleQnameForType(type);\n accountModuleImports.addImport(account, module);\n if (!this.accountImports.has(account)) {\n this.pendingAccounts.add(account);\n }\n }\n }\n }\n }\n}\n//# sourceMappingURL=account.js.map","export class ChainAdapter {\n}\n//# sourceMappingURL=chain-adapter.js.map","import { accountTypeString, moduleQname, SPLITTER, VECTOR_STR } from './utils.js';\nimport { matchType, parseMoveType } from './types.js';\nexport class AbstractMoveCoder {\n moduleMapping = new Map();\n accounts = new Set();\n typeMapping = new Map();\n enumMapping = new Map();\n funcMapping = new Map();\n // network: string\n adapter;\n constructor(adapter) {\n this.adapter = adapter;\n }\n contains(account, name) {\n return this.moduleMapping.has(moduleQname({ address: account, name }));\n }\n loadInternal(module, address) {\n const account = module.address;\n const declareAccount = accountTypeString(address);\n this._loadInternal(module, account);\n if (account !== declareAccount) {\n this._loadInternal(module, declareAccount);\n }\n }\n _loadInternal(module, account) {\n if (this.contains(account, module.name)) {\n return;\n }\n this.moduleMapping.set(moduleQname({ address: account, name: module.name }), module);\n for (const enumType of module.enums) {\n const key = [account, module.name, enumType.name].join(SPLITTER);\n this.enumMapping.set(key, enumType);\n }\n for (const struct of module.structs) {\n // TODO move to util\n const key = [account, module.name, struct.name].join(SPLITTER);\n this.typeMapping.set(key, struct);\n }\n for (const func of module.exposedFunctions) {\n // if (!func.isEntry) {\n // continue\n // }\n const key = [account, module.name, func.name].join(SPLITTER);\n this.funcMapping.set(key, func);\n }\n }\n decodeBigInt(data) {\n if (Array.isArray(data)) {\n throw new Error('data is in byte array');\n // Only sui function need this, strange\n // const bytes = data as number[]\n // return bytesToBigInt(new Uint8Array(bytes.slice().reverse()))\n }\n return BigInt(data);\n }\n requestMap = new Map();\n async getMoveStruct(type) {\n const [account_, module, typeName] = type.split(SPLITTER);\n const account = accountTypeString(account_);\n type = [account, module, typeName].join(SPLITTER);\n let struct = this.typeMapping.get(type);\n if (struct) {\n return struct;\n }\n if (this.accounts.has(account)) {\n throw new Error('Failed to load struct ' + type + ' for imported account');\n }\n let resp = this.requestMap.get(account);\n if (!resp) {\n resp = this.adapter.fetchModules(account).then((modules) => {\n for (const m of modules) {\n this.load(m, account);\n }\n });\n this.requestMap.set(account, resp);\n }\n await resp;\n struct = this.typeMapping.get(type);\n if (struct) {\n return struct;\n }\n throw new Error('Failed to load function ' + type + ' type are not imported anywhere');\n }\n async maybeGetMoveEnum(type) {\n const [account_, module, typeName] = type.split(SPLITTER);\n const account = accountTypeString(account_);\n type = [account, module, typeName].join(SPLITTER);\n let enumType = this.enumMapping.get(type);\n if (enumType) {\n return enumType;\n }\n if (this.accounts.has(account)) {\n return undefined;\n }\n let resp = this.requestMap.get(account);\n if (!resp) {\n resp = this.adapter.fetchModules(account).then((modules) => {\n for (const m of modules) {\n this.load(m, account);\n }\n });\n this.requestMap.set(account, resp);\n }\n await resp;\n enumType = this.enumMapping.get(type);\n if (enumType) {\n return enumType;\n }\n return undefined;\n }\n async getMoveFunction(type) {\n const [account_, module, typeName] = type.split(SPLITTER);\n const account = accountTypeString(account_);\n type = [account, module, typeName].join(SPLITTER);\n let func = this.funcMapping.get(type);\n if (func) {\n return func;\n }\n if (this.accounts.has(account)) {\n throw new Error('Failed to load function ' + type + ' for imported account');\n }\n let resp = this.requestMap.get(account);\n if (!resp) {\n resp = this.adapter\n .fetchModules(account)\n .then((modules) => {\n for (const m of modules) {\n this.load(m, account);\n }\n })\n .catch((e) => {\n this.requestMap.delete(account);\n });\n this.requestMap.set(account, resp);\n }\n await resp;\n func = this.funcMapping.get(type);\n if (func) {\n return func;\n }\n throw new Error('Failed to load function ' + type + ' type are not imported anywhere');\n }\n async decode(data, type) {\n // process simple type\n if (type.reference) {\n return data;\n }\n switch (type.qname) {\n case 'signer': // TODO check this, aptos only\n case 'address':\n case 'Address':\n case '0x1::string::String':\n case 'bool':\n case 'Bool':\n case 'u8':\n case 'U8':\n case 'u16':\n case 'U16':\n case 'u32':\n case 'U32':\n return data;\n case 'u64':\n case 'U64':\n case 'u128':\n case 'U128':\n case 'u256':\n case 'U256':\n return this.decodeBigInt(data);\n }\n // process vector\n if (type.qname.toLowerCase() === VECTOR_STR) {\n // vector<u8> as hex string\n if (type.typeArgs[0].qname === 'u8' || type.typeArgs[0].qname === 'U8') {\n return data;\n }\n const res = [];\n for (const entry of data) {\n res.push(await this.decode(entry, type.typeArgs[0]));\n }\n return res;\n }\n // try enum type first\n const enumType = await this.maybeGetMoveEnum(type.qname);\n if (enumType) {\n return data;\n }\n // Process complex type\n const struct = await this.getMoveStruct(type.qname);\n const typeCtx = new Map();\n for (const [idx, typeArg] of type.typeArgs.entries()) {\n typeCtx.set('T' + idx, typeArg);\n }\n const typedData = {};\n for (const field of struct.fields) {\n let filedType = field.type;\n filedType = filedType.applyTypeArgs(typeCtx);\n const fieldValue = this.adapter.getData(data)[field.name];\n const value = await this.decode(fieldValue, filedType);\n typedData[field.name] = value;\n }\n return typedData;\n }\n async decodeArray(entries, types, strict = true) {\n const entriesDecoded = [];\n for (const [idx, arg] of entries.entries()) {\n // TODO consider apply payload.type_arguments, but this might be hard since we don't code gen for them\n const argType = types[idx];\n try {\n if (!strict && arg === undefined) {\n entriesDecoded.push(arg);\n }\n else {\n entriesDecoded.push(await this.decode(arg, argType));\n }\n }\n catch (e) {\n throw Error('Decoding error for ' + JSON.stringify(arg) + 'using type' + argType + String(e));\n }\n }\n return entriesDecoded;\n }\n encode(data) {\n if (data === undefined || data === null) {\n return undefined;\n }\n if (typeof data === 'bigint') {\n return data.toString();\n }\n if (Array.isArray(data)) {\n return this.encodeArray(data);\n }\n for (const [key, value] of Object.entries(data)) {\n if (!value) {\n continue;\n }\n if (typeof value === 'bigint') {\n data[key] = value.toString();\n }\n }\n return data;\n }\n encodeArray(entriesDecoded) {\n const entries = [];\n for (const [idx, arg] of entriesDecoded.entries()) {\n entries.push(this.encode(arg));\n }\n return entries;\n }\n async decodeCallResult(res, func) {\n const f = await this.getMoveFunction(func);\n return this.decodeArray(res, f.return);\n }\n async filterAndDecodeStruct(typeMatcher, structsWithTags) {\n if (!structsWithTags) {\n return [];\n }\n // const typeMatcherDescriptor = parseMoveType(typeMatcher)\n const results = [];\n for (const resource of structsWithTags) {\n const resourceType = this.adapter.getType(resource);\n const resourceTypeDescriptor = parseMoveType(resourceType);\n if (!matchType(typeMatcher, resourceTypeDescriptor)) {\n continue;\n }\n const result = await this.decodedStruct(resource);\n if (result) {\n results.push(result);\n }\n else {\n console.error('decoding error');\n }\n }\n return results;\n }\n async decodedStruct(typeStruct) {\n const typeDescriptor = parseMoveType(this.adapter.getType(typeStruct));\n const typeArguments = typeDescriptor.typeArgs.map((t) => t.getSignature());\n let dataTyped = undefined;\n try {\n dataTyped = await this.decode(typeStruct, typeDescriptor);\n }\n catch (e) {\n throw Error('Decoding error for struct' + JSON.stringify(typeStruct) + String(e));\n // return undefined\n }\n return {\n ...typeStruct,\n data_decoded: dataTyped,\n type_arguments: typeArguments\n };\n }\n async decodeType(typeStruct, type) {\n if (typeStruct === null || typeStruct == undefined) {\n return typeStruct;\n }\n if (typeof typeStruct === 'object') {\n if ('type' in typeStruct) {\n const typeInStruct = parseMoveType(typeStruct.type.toString() || '');\n if (!matchType(type, typeInStruct)) {\n return undefined;\n }\n type = typeInStruct;\n }\n }\n return await this.decode(typeStruct, type);\n }\n}\n//# sourceMappingURL=abstract-move-coder.js.map","export var InternalMoveFunctionVisibility;\n(function (InternalMoveFunctionVisibility) {\n InternalMoveFunctionVisibility[\"PRIVATE\"] = \"private\";\n InternalMoveFunctionVisibility[\"PUBLIC\"] = \"public\";\n InternalMoveFunctionVisibility[\"FRIEND\"] = \"friend\";\n})(InternalMoveFunctionVisibility || (InternalMoveFunctionVisibility = {}));\n//# sourceMappingURL=internal-models.js.map","// TODO extends ArgumentsFilter\nimport type {\n Data_AptCall,\n Data_AptResource,\n HandleInterval,\n MoveAccountFetchConfig,\n MoveFetchConfig,\n ProcessResult\n} from '@sentio/protos'\n\nexport interface EventFilter {\n type: string\n account?: string\n eventAccount?: string\n}\n\nexport interface FunctionNameAndCallFilter extends CallFilter {\n function: string\n}\n\nexport interface TransactionFilter {\n includeFailed?: boolean\n publicKeyPrefix?: string\n fromAndToAddress?: { from: string; to: string }\n}\n\n// TODO extends ArgumentsFilter\nexport interface CallFilter extends TransactionFilter {\n typeArguments?: string[]\n}\n\nexport interface ArgumentsFilter {\n arguments?: string[]\n}\n\nexport class EventHandler<T> {\n filters: EventFilter[]\n handlerName: string\n handler: (event: T) => Promise<ProcessResult>\n fetchConfig: MoveFetchConfig\n partitionHandler?: (event: T) => Promise<string | undefined>\n}\n\nexport class CallHandler<T> {\n filters: FunctionNameAndCallFilter[]\n handlerName: string\n handler: (call: T) => Promise<ProcessResult>\n fetchConfig: MoveFetchConfig\n partitionHandler?: (call: T) => Promise<string | undefined>\n}\n\nexport class ObjectChangeHandler<T> {\n handlerName: string\n handler: (call: T) => Promise<ProcessResult>\n type: string | string[]\n}\n\nexport class ResourceChangeHandler<T> {\n handlerName: string\n handler: (call: T) => Promise<ProcessResult>\n type: string | string[]\n partitionHandler?: (call: T) => Promise<string | undefined>\n}\n\nexport class ResourceIntervalHandler {\n type?: string | string[]\n versionInterval?: HandleInterval\n timeIntervalInMinutes?: HandleInterval\n handler: (resource: Data_AptResource) => Promise<ProcessResult>\n handlerName: string\n fetchConfig: MoveAccountFetchConfig\n partitionHandler?: (resource: Data_AptResource) => Promise<string | undefined>\n}\n\nexport class TransactionIntervalHandler {\n versionInterval?: HandleInterval\n timeIntervalInMinutes?: HandleInterval\n handler: (tx: Data_AptCall) => Promise<ProcessResult>\n handlerName: string\n fetchConfig: MoveFetchConfig\n partitionHandler?: (tx: Data_AptCall) => Promise<string | undefined>\n}\n","import { BaseContext } from '../core/index.js'\nimport { AbstractMoveCoder } from '@typemove/move'\n\nexport abstract class MoveContext<Network, ModuleType, StructType> extends BaseContext {\n address: string\n coder: AbstractMoveCoder<ModuleType, StructType>\n network: Network\n\n abstract getTimestamp(): number\n}\n\nexport abstract class MoveAccountContext<Network, ModuleType, StructType> extends BaseContext {\n address: string\n coder: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EACzE,IAAI,YAAY;EAChB,IAAI;GACA,YAAY,MAAM,KAAK,OAAO,YAAY,cAAc;EAC5D,SACO,GAAG;GACN,MAAM,MAAM,8BAA8B,KAAK,UAAU,UAAU,IAAI,OAAO,CAAC,CAAC;EAEpF;EACA,OAAO;GACH,GAAG;GACH,cAAc;GACd,gBAAgB;EACpB;CACJ;CACA,MAAM,WAAW,YAAY,MAAM;EAC/B,IAAI,eAAe,QAAQ,cAAc,QACrC,OAAO;EAEX,IAAI,OAAO,eAAe,UACtB;OAAI,UAAU,YAAY;IACtB,MAAM,eAAe,cAAc,WAAW,KAAK,SAAS,KAAK,EAAE;IACnE,IAAI,CAAC,UAAU,MAAM,YAAY,GAC7B;IAEJ,OAAO;GACX;;EAEJ,OAAO,MAAM,KAAK,OAAO,YAAY,IAAI;CAC7C;AACJ;;;;AClTA,IAAW;CACV,SAAU,gCAAgC;CACvC,+BAA+B,aAAa;CAC5C,+BAA+B,YAAY;CAC3C,+BAA+B,YAAY;AAC/C,EAAC,CAAE,mCAAmC,iCAAiC,CAAC,EAAE;;;;AC8B1E,IAAa,eAAb,MAA6B;CAC3B;CACA;CACA;CACA;CACA;AACF;AAEA,IAAa,cAAb,MAA4B;CAC1B;CACA;CACA;CACA;CACA;AACF;AAEA,IAAa,sBAAb,MAAoC;CAClC;CACA;CACA;AACF;AAEA,IAAa,wBAAb,MAAsC;CACpC;CACA;CACA;CACA;AACF;AAEA,IAAa,0BAAb,MAAqC;CACnC;CACA;CACA;CACA;CACA;CACA;CACA;AACF;AAEA,IAAa,6BAAb,MAAwC;CACtC;CACA;CACA;CACA;CACA;CACA;AACF;;;;AC9EA,IAAsB,cAAtB,cAA2E,YAAY;CACrF;CACA;CACA;AAGF;AAEA,IAAsB,qBAAtB,cAAkF,YAAY;CAC5F;CACA;CACA;AAGF"}
|
|
1
|
+
{"version":3,"file":"move-BuzfbmGq.js","names":["camel","camelRadash"],"sources":["../../../node_modules/.pnpm/radash@12.1.1/node_modules/radash/dist/esm/string.mjs","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/utils.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/types.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/account.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/chain-adapter.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/abstract-move-coder.js","../../../node_modules/.pnpm/@typemove+move@2.0.4/node_modules/@typemove/move/dist/esm/internal-models.js","../src/move/filter.ts","../src/move/move-context.ts"],"sourcesContent":["const capitalize = (str) => {\n if (!str || str.length === 0)\n return \"\";\n const lower = str.toLowerCase();\n return lower.substring(0, 1).toUpperCase() + lower.substring(1, lower.length);\n};\nconst camel = (str) => {\n const parts = str?.replace(/([A-Z])+/g, capitalize)?.split(/(?=[A-Z])|[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n if (parts.length === 1)\n return parts[0];\n return parts.reduce((acc, part) => {\n return `${acc}${part.charAt(0).toUpperCase()}${part.slice(1)}`;\n });\n};\nconst snake = (str, options) => {\n const parts = str?.replace(/([A-Z])+/g, capitalize).split(/(?=[A-Z])|[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n if (parts.length === 1)\n return parts[0];\n const result = parts.reduce((acc, part) => {\n return `${acc}_${part.toLowerCase()}`;\n });\n return options?.splitOnNumber === false ? result : result.replace(/([A-Za-z]{1}[0-9]{1})/, (val) => `${val[0]}_${val[1]}`);\n};\nconst dash = (str) => {\n const parts = str?.replace(/([A-Z])+/g, capitalize)?.split(/(?=[A-Z])|[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n if (parts.length === 1)\n return parts[0];\n return parts.reduce((acc, part) => {\n return `${acc}-${part.toLowerCase()}`;\n });\n};\nconst pascal = (str) => {\n const parts = str?.split(/[\\.\\-\\s_]/).map((x) => x.toLowerCase()) ?? [];\n if (parts.length === 0)\n return \"\";\n return parts.map((str2) => str2.charAt(0).toUpperCase() + str2.slice(1)).join(\"\");\n};\nconst title = (str) => {\n if (!str)\n return \"\";\n return str.split(/(?=[A-Z])|[\\.\\-\\s_]/).map((s) => s.trim()).filter((s) => !!s).map((s) => capitalize(s.toLowerCase())).join(\" \");\n};\nconst template = (str, data, regex = /\\{\\{(.+?)\\}\\}/g) => {\n return Array.from(str.matchAll(regex)).reduce((acc, match) => {\n return acc.replace(match[0], data[match[1]]);\n }, str);\n};\nconst trim = (str, charsToTrim = \" \") => {\n if (!str)\n return \"\";\n const toTrim = charsToTrim.replace(/[\\W]{1}/g, \"\\\\$&\");\n const regex = new RegExp(`^[${toTrim}]+|[${toTrim}]+$`, \"g\");\n return str.replace(regex, \"\");\n};\n\nexport { camel, capitalize, dash, pascal, snake, template, title, trim };\n//# sourceMappingURL=string.mjs.map\n","import { camel as camelRadash } from 'radash';\nexport const SPLITTER = '::';\nexport const VECTOR_STR = 'vector';\nexport function isFrameworkAccount(account) {\n const n = parseInt(account, 16);\n if (Number.isNaN(n)) {\n return false;\n }\n return n >= 0 && n < 16;\n}\n// strip any lead 0\nexport function accountTypeString(account) {\n const withoutPrefix = account.toLowerCase().replace(/^(0x)/, '');\n return '0x' + withoutPrefix.replace(/^0*/, '');\n}\nconst MOVE_ADDRESS_LENGTH = 32;\nfunction isHex(value) {\n return /^(0x|0X)?[a-fA-F0-9]+$/.test(value);\n}\nfunction getHexByteLength(value) {\n return /^(0x|0X)/.test(value) ? (value.length - 2) / 2 : value.length / 2;\n}\nexport function isValidMoveAddress(value) {\n return isHex(value) && getHexByteLength(value) <= MOVE_ADDRESS_LENGTH;\n}\n// Get full address with 32 bytes\nexport function accountAddressString(account) {\n if (!isValidMoveAddress(account)) {\n throw Error('Not valid move address');\n }\n const address = account.toLowerCase().replace(/^(0x)/, '');\n return `0x${address.padStart(MOVE_ADDRESS_LENGTH * 2, '0')}`;\n}\n// https://github.com/microsoft/TypeScript/issues/2536\nconst KEYWORDS = new Set([\n 'break',\n 'case',\n 'catch',\n 'class',\n 'const',\n 'continue',\n 'debugger',\n 'default',\n 'delete',\n 'do',\n 'else',\n 'enum',\n 'export',\n 'extends',\n 'false',\n 'finally',\n 'for',\n 'function',\n 'if',\n 'import',\n 'in',\n 'instanceof',\n 'new',\n 'null',\n 'return',\n 'super',\n 'switch',\n 'this',\n 'throw',\n 'true',\n 'try',\n 'typeof',\n 'var',\n 'void',\n 'while',\n 'with',\n 'as',\n 'implements',\n 'interface',\n 'let',\n 'package',\n 'private',\n 'protected',\n 'public',\n 'static',\n 'yield',\n 'any',\n 'boolean',\n 'constructor',\n 'declare',\n // 'get',\n 'module',\n // 'require',\n 'number',\n // 'set',\n 'string',\n 'symbol',\n 'type',\n 'from',\n // 'of',\n 'async',\n 'await',\n 'bigint',\n 'object',\n 'volatile',\n 'namespace',\n 'arguments'\n]);\nexport function normalizeToJSName(name) {\n if (KEYWORDS.has(name)) {\n return name + '$';\n }\n return name;\n}\nexport function moduleQnameForType(type) {\n const parts = type.split(SPLITTER).slice(0, 2);\n return [parts[0], parts[1]];\n}\nexport function moduleQname(module) {\n return accountTypeString(module.address) + SPLITTER + module.name;\n}\nexport function structQname(module, struct) {\n return [accountTypeString(module.address), module.name, struct.name].join(SPLITTER);\n}\nexport function upperFirst(str) {\n return str.charAt(0).toUpperCase() + str.slice(1);\n}\nexport function camel(str) {\n const base = camelRadash(str);\n return str.endsWith('_') ? base + '_' : base;\n}\n//# sourceMappingURL=utils.js.map","import { accountTypeString, SPLITTER, VECTOR_STR } from './utils.js';\nexport class TypeDescriptor {\n qname;\n reference;\n mutable;\n typeArgs;\n constructor(symbol, typeParams) {\n this.qname = symbol;\n this.reference = false;\n this.mutable = false;\n this.typeArgs = typeParams || [];\n }\n apply(...typeArgs) {\n const newObj = this.clone();\n newObj.typeArgs = typeArgs;\n return newObj;\n }\n clone() {\n const newObj = new TypeDescriptor(this.qname, this.typeArgs);\n newObj.reference = this.reference;\n newObj.mutable = this.mutable;\n return newObj;\n }\n // compare qname without consider case for system type\n compareQname(t) {\n let t1 = this.qname;\n if (BUILTIN_TYPES_SET.has(this.qname.toLowerCase())) {\n t1 = this.qname.toLowerCase();\n }\n let t2 = t.qname;\n if (BUILTIN_TYPES_SET.has(t.qname.toLowerCase())) {\n t2 = t.qname;\n }\n return t1 === t2;\n }\n getSignature() {\n if (this.typeArgs.length > 0) {\n return this.qname + '<' + this.typeArgs.map((t) => t.getSignature()).join(', ') + '>';\n }\n return this.qname;\n }\n // Make U8, U16, etc => u8, u16\n getNormalizedSignature() {\n let qname = this.qname;\n switch (qname) {\n case 'U8':\n case 'U16':\n case 'U32':\n case 'U64':\n case 'U128':\n case 'U256':\n case 'Vector':\n case 'Bool':\n case 'Address':\n qname = qname.toLowerCase();\n }\n if (this.typeArgs.length > 0) {\n return qname + '<' + this.typeArgs.map((t) => t.getNormalizedSignature()).join(', ') + '>';\n }\n return qname;\n }\n // Replace T0, T1 with more concrete type\n applyTypeArgs(ctx) {\n const replace = ctx.get(this.qname);\n if (replace) {\n return replace;\n }\n if (ctx.size === 0 || this.typeArgs.length === 0) {\n return this;\n }\n const typeArgs = [];\n for (const arg of this.typeArgs) {\n const replace = ctx.get(arg.qname);\n if (replace) {\n typeArgs.push(replace);\n }\n else {\n typeArgs.push(arg.applyTypeArgs(ctx));\n }\n }\n return new TypeDescriptor(this.qname, typeArgs);\n }\n // all depended types including itself, not include system type\n dependedTypes() {\n if (this.qname.startsWith('&')) {\n console.error('Not expected &');\n return [];\n }\n // Handle closure/lambda types: |&mut T1|T2 or |T1, T2|T3\n if (this.qname.startsWith('|')) {\n // Closure types are function types, not module dependencies\n // The actual type dependencies are in the typeArgs if any\n const types = new Set();\n for (const param of this.typeArgs) {\n param.dependedTypes().forEach((t) => types.add(t));\n }\n return Array.from(types);\n }\n if (this.isVector()) {\n return this.typeArgs[0].dependedTypes();\n }\n if (BUILTIN_TYPES_SET.has(this.qname.toLowerCase())) {\n return [];\n }\n switch (this.qname) {\n case 'signer':\n case '0x1::string::String':\n return [];\n }\n // Type parameters are not depended\n if (this.qname.indexOf(SPLITTER) == -1) {\n if (this.qname.startsWith('T')) {\n return [];\n }\n }\n const types = new Set();\n for (const param of this.typeArgs) {\n param.dependedTypes().forEach((t) => types.add(t));\n }\n types.add(this.qname);\n return Array.from(types);\n }\n isVector() {\n return this.qname.toLowerCase() === VECTOR_STR;\n }\n existAnyType() {\n if (this.qname === 'any') {\n return true;\n }\n for (const param of this.typeArgs) {\n if (param.existAnyType()) {\n return true;\n }\n }\n return false;\n }\n name() {\n const parts = this.qname.split(SPLITTER);\n return parts[parts.length - 1];\n }\n module() {\n const parts = this.qname.split(SPLITTER);\n return parts[parts.length - 2];\n }\n}\nexport function parseMoveType(type) {\n if (type === undefined) {\n console.log('');\n }\n // Aptos SDK 7+ exposes Move closure / function-value types in ABIs as\n // `|param1, param2, ...| ret`. Parse them specially — the inner params and\n // return type are nested and recursively parsed; the descriptor's qname is\n // the sentinel `|fn|` (other code in this file branches on qname.startsWith('|')).\n const closure = tryParseClosure(type);\n if (closure) {\n return closure;\n }\n const stack = [new TypeDescriptor('')];\n let buffer = [];\n // xxx:asdf<g1<a,<c,d>>, b, g2<a,b>, e>\n for (let i = 0; i < type.length; i++) {\n const ch = type[i];\n if (ch === ' ') {\n continue;\n }\n if (ch === '<') {\n // const symbol = type.slice(symbolStart, i)\n // symbolStart =\n const symbol = buffer.join('');\n buffer = [];\n stack[stack.length - 1].qname = symbol;\n adjustType(stack[stack.length - 1]);\n stack.push(new TypeDescriptor(''));\n continue;\n }\n if (ch === '>' || ch === ',') {\n const typeParam = stack.pop();\n if (!typeParam) {\n throw Error('Unexpected stack size');\n }\n if (buffer.length > 0) {\n typeParam.qname = buffer.join('');\n buffer = [];\n }\n adjustType(typeParam);\n stack[stack.length - 1].typeArgs.push(typeParam);\n if (ch === ',') {\n stack.push(new TypeDescriptor(''));\n }\n continue;\n }\n buffer.push(ch);\n }\n if (buffer.length > 0) {\n stack[stack.length - 1].qname = buffer.join('');\n }\n adjustType(stack[stack.length - 1]);\n const res = stack.pop();\n if (!res || stack.length > 0) {\n throw Error('Unexpected stack size');\n }\n return res;\n}\n// Parse `|param1, param2, ...| return_type` (Aptos Move closure / function-value\n// types exposed by SDK 7+). Returns undefined if the input is not a closure.\n// Commas and the closing `|` are matched at angle-bracket depth 0.\nfunction tryParseClosure(type) {\n let i = 0;\n while (i < type.length && type[i] === ' ')\n i++;\n if (type[i] !== '|')\n return undefined;\n let depth = 0;\n let close = -1;\n for (let j = i + 1; j < type.length; j++) {\n const ch = type[j];\n if (ch === '<')\n depth++;\n else if (ch === '>')\n depth--;\n else if (ch === '|' && depth === 0) {\n close = j;\n break;\n }\n }\n if (close < 0)\n return undefined;\n const inner = type.slice(i + 1, close);\n const ret = type.slice(close + 1).trim();\n const paramTypes = [];\n if (inner.trim().length > 0) {\n let depth2 = 0;\n let start = 0;\n for (let k = 0; k <= inner.length; k++) {\n const ch = inner[k];\n if (k === inner.length || (ch === ',' && depth2 === 0)) {\n const piece = inner.slice(start, k).trim();\n if (piece.length > 0)\n paramTypes.push(parseMoveType(piece));\n start = k + 1;\n }\n else if (ch === '<')\n depth2++;\n else if (ch === '>')\n depth2--;\n }\n }\n const typeArgs = paramTypes.slice();\n if (ret.length > 0)\n typeArgs.push(parseMoveType(ret));\n return new TypeDescriptor('|fn|', typeArgs);\n}\nfunction adjustType(type) {\n if (type.qname.startsWith('&')) {\n type.reference = true;\n type.qname = type.qname.slice(1);\n }\n if (type.qname.startsWith('mut')) {\n type.mutable = true;\n type.qname = type.qname.slice(3);\n }\n const parts = type.qname.split(SPLITTER);\n if (parts.length > 1) {\n const [account, module, name] = parts;\n type.qname = [accountTypeString(account), module, name].join(SPLITTER);\n }\n}\nexport const ANY_TYPE = new TypeDescriptor('any');\nexport function vectorType(t = ANY_TYPE) {\n return BUILTIN_TYPES.VECTOR_TYPE_ANY.apply(t);\n}\nexport const BUILTIN_TYPES = {\n ADDRESS_TYPE: new TypeDescriptor('address'),\n VECTOR_TYPE_ANY: new TypeDescriptor('vector'),\n VECTOR_TYPE: vectorType,\n BOOL_TYPE: new TypeDescriptor('bool'),\n U8_TYPE: new TypeDescriptor('u8'),\n U16_TYPE: new TypeDescriptor('u16'),\n U32_TYPE: new TypeDescriptor('u32'),\n U64_TYPE: new TypeDescriptor('u64'),\n U128_TYPE: new TypeDescriptor('u128'),\n U256_TYPE: new TypeDescriptor('u256')\n};\nconst BUILTIN_TYPES_SET = new Set(Object.values(BUILTIN_TYPES).flatMap((t) => {\n if (typeof t === 'object') {\n return [t.qname.toLowerCase()];\n }\n return [];\n}));\n/**\n *\n * @param matcher\n * @param type\n */\nexport function matchType(matcher, type) {\n if (matcher.qname === 'any') {\n return true;\n }\n if (!matcher.compareQname(type)) {\n return false;\n }\n for (const [idx, matcherTarg] of matcher.typeArgs.entries()) {\n const targ = type.typeArgs[idx];\n if (!matchType(matcherTarg, targ)) {\n return false;\n }\n }\n return true;\n}\n//# sourceMappingURL=types.js.map","import { moduleQname, moduleQnameForType } from './utils.js';\nexport class AccountModulesImportInfo {\n // account to module\n imports;\n account;\n moduleName;\n constructor(account, tsModuleName) {\n this.account = account;\n this.moduleName = tsModuleName;\n this.imports = new Map();\n }\n addImport(account, module) {\n if (account === this.account) {\n return;\n }\n let accountModules = this.imports.get(account);\n if (!accountModules) {\n accountModules = new Set();\n this.imports.set(account, accountModules);\n }\n accountModules.add(module);\n }\n}\nexport class AccountRegister {\n accountImports = new Map();\n pendingAccounts = new Set();\n register(module, tsModuleName) {\n const currentModuleFqn = moduleQname(module);\n let accountModuleImports = this.accountImports.get(module.address);\n if (!accountModuleImports) {\n accountModuleImports = new AccountModulesImportInfo(module.address, tsModuleName);\n this.accountImports.set(module.address, accountModuleImports);\n // the account has already be processed, delete pending task\n this.pendingAccounts.delete(module.address);\n }\n this.registerStruct(module, accountModuleImports);\n this.registerFunctions(module, accountModuleImports);\n this.accountImports.set(currentModuleFqn, accountModuleImports);\n return accountModuleImports;\n }\n registerFunctions(module, accountModuleImports) {\n for (const func of module.exposedFunctions) {\n // if (!func.isEntry) {\n // continue\n // }\n for (const param of func.params.concat(func.return)) {\n for (const type of param.dependedTypes()) {\n const [account, module] = moduleQnameForType(type);\n accountModuleImports.addImport(account, module);\n if (!this.accountImports.has(account)) {\n this.pendingAccounts.add(account);\n }\n }\n }\n }\n }\n registerStruct(module, accountModuleImports) {\n for (const struct of module.structs) {\n for (const field of struct.fields) {\n for (const type of field.type.dependedTypes()) {\n const [account, module] = moduleQnameForType(type);\n accountModuleImports.addImport(account, module);\n if (!this.accountImports.has(account)) {\n this.pendingAccounts.add(account);\n }\n }\n }\n }\n }\n}\n//# sourceMappingURL=account.js.map","export class ChainAdapter {\n}\n//# sourceMappingURL=chain-adapter.js.map","import { accountTypeString, moduleQname, SPLITTER, VECTOR_STR } from './utils.js';\nimport { matchType, parseMoveType } from './types.js';\nexport class AbstractMoveCoder {\n moduleMapping = new Map();\n accounts = new Set();\n typeMapping = new Map();\n enumMapping = new Map();\n funcMapping = new Map();\n // network: string\n adapter;\n constructor(adapter) {\n this.adapter = adapter;\n }\n contains(account, name) {\n return this.moduleMapping.has(moduleQname({ address: account, name }));\n }\n loadInternal(module, address) {\n const account = module.address;\n const declareAccount = accountTypeString(address);\n this._loadInternal(module, account);\n if (account !== declareAccount) {\n this._loadInternal(module, declareAccount);\n }\n }\n _loadInternal(module, account) {\n if (this.contains(account, module.name)) {\n return;\n }\n this.moduleMapping.set(moduleQname({ address: account, name: module.name }), module);\n for (const enumType of module.enums) {\n const key = [account, module.name, enumType.name].join(SPLITTER);\n this.enumMapping.set(key, enumType);\n }\n for (const struct of module.structs) {\n // TODO move to util\n const key = [account, module.name, struct.name].join(SPLITTER);\n this.typeMapping.set(key, struct);\n }\n for (const func of module.exposedFunctions) {\n // if (!func.isEntry) {\n // continue\n // }\n const key = [account, module.name, func.name].join(SPLITTER);\n this.funcMapping.set(key, func);\n }\n }\n decodeBigInt(data) {\n if (Array.isArray(data)) {\n throw new Error('data is in byte array');\n // Only sui function need this, strange\n // const bytes = data as number[]\n // return bytesToBigInt(new Uint8Array(bytes.slice().reverse()))\n }\n return BigInt(data);\n }\n requestMap = new Map();\n async getMoveStruct(type) {\n const [account_, module, typeName] = type.split(SPLITTER);\n const account = accountTypeString(account_);\n type = [account, module, typeName].join(SPLITTER);\n let struct = this.typeMapping.get(type);\n if (struct) {\n return struct;\n }\n if (this.accounts.has(account)) {\n throw new Error('Failed to load struct ' + type + ' for imported account');\n }\n let resp = this.requestMap.get(account);\n if (!resp) {\n resp = this.adapter.fetchModules(account).then((modules) => {\n for (const m of modules) {\n this.load(m, account);\n }\n });\n this.requestMap.set(account, resp);\n }\n await resp;\n struct = this.typeMapping.get(type);\n if (struct) {\n return struct;\n }\n throw new Error('Failed to load function ' + type + ' type are not imported anywhere');\n }\n async maybeGetMoveEnum(type) {\n const [account_, module, typeName] = type.split(SPLITTER);\n const account = accountTypeString(account_);\n type = [account, module, typeName].join(SPLITTER);\n let enumType = this.enumMapping.get(type);\n if (enumType) {\n return enumType;\n }\n if (this.accounts.has(account)) {\n return undefined;\n }\n let resp = this.requestMap.get(account);\n if (!resp) {\n resp = this.adapter.fetchModules(account).then((modules) => {\n for (const m of modules) {\n this.load(m, account);\n }\n });\n this.requestMap.set(account, resp);\n }\n await resp;\n enumType = this.enumMapping.get(type);\n if (enumType) {\n return enumType;\n }\n return undefined;\n }\n async getMoveFunction(type) {\n const [account_, module, typeName] = type.split(SPLITTER);\n const account = accountTypeString(account_);\n type = [account, module, typeName].join(SPLITTER);\n let func = this.funcMapping.get(type);\n if (func) {\n return func;\n }\n if (this.accounts.has(account)) {\n throw new Error('Failed to load function ' + type + ' for imported account');\n }\n let resp = this.requestMap.get(account);\n if (!resp) {\n resp = this.adapter\n .fetchModules(account)\n .then((modules) => {\n for (const m of modules) {\n this.load(m, account);\n }\n })\n .catch((e) => {\n this.requestMap.delete(account);\n });\n this.requestMap.set(account, resp);\n }\n await resp;\n func = this.funcMapping.get(type);\n if (func) {\n return func;\n }\n throw new Error('Failed to load function ' + type + ' type are not imported anywhere');\n }\n async decode(data, type) {\n // process simple type\n if (type.reference) {\n return data;\n }\n switch (type.qname) {\n case 'signer': // TODO check this, aptos only\n case 'address':\n case 'Address':\n case '0x1::string::String':\n case 'bool':\n case 'Bool':\n case 'u8':\n case 'U8':\n case 'u16':\n case 'U16':\n case 'u32':\n case 'U32':\n return data;\n case 'u64':\n case 'U64':\n case 'u128':\n case 'U128':\n case 'u256':\n case 'U256':\n return this.decodeBigInt(data);\n }\n // process vector\n if (type.qname.toLowerCase() === VECTOR_STR) {\n // vector<u8> as hex string\n if (type.typeArgs[0].qname === 'u8' || type.typeArgs[0].qname === 'U8') {\n return data;\n }\n const res = [];\n for (const entry of data) {\n res.push(await this.decode(entry, type.typeArgs[0]));\n }\n return res;\n }\n // try enum type first\n const enumType = await this.maybeGetMoveEnum(type.qname);\n if (enumType) {\n return data;\n }\n // Process complex type\n const struct = await this.getMoveStruct(type.qname);\n const typeCtx = new Map();\n for (const [idx, typeArg] of type.typeArgs.entries()) {\n typeCtx.set('T' + idx, typeArg);\n }\n const typedData = {};\n for (const field of struct.fields) {\n let filedType = field.type;\n filedType = filedType.applyTypeArgs(typeCtx);\n const fieldValue = this.adapter.getData(data)[field.name];\n const value = await this.decode(fieldValue, filedType);\n typedData[field.name] = value;\n }\n return typedData;\n }\n async decodeArray(entries, types, strict = true) {\n const entriesDecoded = [];\n for (const [idx, arg] of entries.entries()) {\n // TODO consider apply payload.type_arguments, but this might be hard since we don't code gen for them\n const argType = types[idx];\n try {\n if (!strict && arg === undefined) {\n entriesDecoded.push(arg);\n }\n else {\n entriesDecoded.push(await this.decode(arg, argType));\n }\n }\n catch (e) {\n throw Error('Decoding error for ' + JSON.stringify(arg) + 'using type' + argType + String(e));\n }\n }\n return entriesDecoded;\n }\n encode(data) {\n if (data === undefined || data === null) {\n return undefined;\n }\n if (typeof data === 'bigint') {\n return data.toString();\n }\n if (Array.isArray(data)) {\n return this.encodeArray(data);\n }\n for (const [key, value] of Object.entries(data)) {\n if (!value) {\n continue;\n }\n if (typeof value === 'bigint') {\n data[key] = value.toString();\n }\n }\n return data;\n }\n encodeArray(entriesDecoded) {\n const entries = [];\n for (const [idx, arg] of entriesDecoded.entries()) {\n entries.push(this.encode(arg));\n }\n return entries;\n }\n async decodeCallResult(res, func) {\n const f = await this.getMoveFunction(func);\n return this.decodeArray(res, f.return);\n }\n async filterAndDecodeStruct(typeMatcher, structsWithTags) {\n if (!structsWithTags) {\n return [];\n }\n // const typeMatcherDescriptor = parseMoveType(typeMatcher)\n const results = [];\n for (const resource of structsWithTags) {\n const resourceType = this.adapter.getType(resource);\n const resourceTypeDescriptor = parseMoveType(resourceType);\n if (!matchType(typeMatcher, resourceTypeDescriptor)) {\n continue;\n }\n const result = await this.decodedStruct(resource);\n if (result) {\n results.push(result);\n }\n else {\n console.error('decoding error');\n }\n }\n return results;\n }\n async decodedStruct(typeStruct) {\n const typeDescriptor = parseMoveType(this.adapter.getType(typeStruct));\n const typeArguments = typeDescriptor.typeArgs.map((t) => t.getSignature());\n let dataTyped = undefined;\n try {\n dataTyped = await this.decode(typeStruct, typeDescriptor);\n }\n catch (e) {\n throw Error('Decoding error for struct' + JSON.stringify(typeStruct) + String(e));\n // return undefined\n }\n return {\n ...typeStruct,\n data_decoded: dataTyped,\n type_arguments: typeArguments\n };\n }\n async decodeType(typeStruct, type) {\n if (typeStruct === null || typeStruct == undefined) {\n return typeStruct;\n }\n if (typeof typeStruct === 'object') {\n if ('type' in typeStruct) {\n const typeInStruct = parseMoveType(typeStruct.type.toString() || '');\n if (!matchType(type, typeInStruct)) {\n return undefined;\n }\n type = typeInStruct;\n }\n }\n return await this.decode(typeStruct, type);\n }\n}\n//# sourceMappingURL=abstract-move-coder.js.map","export var InternalMoveFunctionVisibility;\n(function (InternalMoveFunctionVisibility) {\n InternalMoveFunctionVisibility[\"PRIVATE\"] = \"private\";\n InternalMoveFunctionVisibility[\"PUBLIC\"] = \"public\";\n InternalMoveFunctionVisibility[\"FRIEND\"] = \"friend\";\n})(InternalMoveFunctionVisibility || (InternalMoveFunctionVisibility = {}));\n//# sourceMappingURL=internal-models.js.map","// TODO extends ArgumentsFilter\nimport type {\n Data_AptCall,\n Data_AptResource,\n HandleInterval,\n MoveAccountFetchConfig,\n MoveFetchConfig,\n ProcessResult\n} from '@sentio/protos'\n\nexport interface EventFilter {\n type: string\n account?: string\n eventAccount?: string\n}\n\nexport interface FunctionNameAndCallFilter extends CallFilter {\n function: string\n}\n\nexport interface TransactionFilter {\n includeFailed?: boolean\n publicKeyPrefix?: string\n fromAndToAddress?: { from: string; to: string }\n}\n\n// TODO extends ArgumentsFilter\nexport interface CallFilter extends TransactionFilter {\n typeArguments?: string[]\n}\n\nexport interface ArgumentsFilter {\n arguments?: string[]\n}\n\nexport class EventHandler<T> {\n filters: EventFilter[]\n handlerName: string\n handler: (event: T) => Promise<ProcessResult>\n fetchConfig: MoveFetchConfig\n partitionHandler?: (event: T) => Promise<string | undefined>\n}\n\nexport class CallHandler<T> {\n filters: FunctionNameAndCallFilter[]\n handlerName: string\n handler: (call: T) => Promise<ProcessResult>\n fetchConfig: MoveFetchConfig\n partitionHandler?: (call: T) => Promise<string | undefined>\n}\n\nexport class ObjectChangeHandler<T> {\n handlerName: string\n handler: (call: T) => Promise<ProcessResult>\n type: string | string[]\n}\n\nexport class ResourceChangeHandler<T> {\n handlerName: string\n handler: (call: T) => Promise<ProcessResult>\n type: string | string[]\n partitionHandler?: (call: T) => Promise<string | undefined>\n}\n\nexport class ResourceIntervalHandler {\n type?: string | string[]\n versionInterval?: HandleInterval\n timeIntervalInMinutes?: HandleInterval\n handler: (resource: Data_AptResource) => Promise<ProcessResult>\n handlerName: string\n fetchConfig: MoveAccountFetchConfig\n partitionHandler?: (resource: Data_AptResource) => Promise<string | undefined>\n}\n\nexport class TransactionIntervalHandler {\n versionInterval?: HandleInterval\n timeIntervalInMinutes?: HandleInterval\n handler: (tx: Data_AptCall) => Promise<ProcessResult>\n handlerName: string\n fetchConfig: MoveFetchConfig\n partitionHandler?: (tx: Data_AptCall) => Promise<string | undefined>\n}\n","import { BaseContext } from '../core/index.js'\nimport { AbstractMoveCoder } from '@typemove/move'\n\nexport abstract class MoveContext<Network, ModuleType, StructType> extends BaseContext {\n address: string\n coder: AbstractMoveCoder<ModuleType, StructType>\n network: Network\n\n abstract getTimestamp(): number\n}\n\nexport abstract class MoveAccountContext<Network, ModuleType, StructType> extends BaseContext {\n address: string\n coder: AbstractMoveCoder<ModuleType, StructType>\n network: Network\n\n abstract getTimestamp(): number\n}\n"],"x_google_ignoreList":[0,1,2,3,4,5,6],"mappings":";;;;AAAA,MAAM,cAAc,QAAQ;CAC1B,IAAI,CAAC,OAAO,IAAI,WAAW,GACzB,OAAO;CACT,MAAM,QAAQ,IAAI,YAAY;CAC9B,OAAO,MAAM,UAAU,GAAG,CAAC,CAAC,CAAC,YAAY,IAAI,MAAM,UAAU,GAAG,MAAM,MAAM;AAC9E;AACA,MAAMA,kCAAS,QAAQ;CACrB,MAAM,QAAQ,KAAK,QAAQ,aAAa,UAAU,CAAC,EAAE,MAAM,qBAAqB,CAAC,CAAC,KAAK,MAAM,EAAE,YAAY,CAAC,KAAK,CAAC;CAClH,IAAI,MAAM,WAAW,GACnB,OAAO;CACT,IAAI,MAAM,WAAW,GACnB,OAAO,MAAM;CACf,OAAO,MAAM,QAAQ,KAAK,SAAS;EACjC,OAAO,GAAG,MAAM,KAAK,OAAO,CAAC,CAAC,CAAC,YAAY,IAAI,KAAK,MAAM,CAAC;CAC7D,CAAC;AACH;;;;ACdA,MAAa,WAAW;AACxB,MAAa,aAAa;AAC1B,SAAgB,mBAAmB,SAAS;CACxC,MAAM,IAAI,SAAS,SAAS,EAAE;CAC9B,IAAI,OAAO,MAA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,MAAoC;CAClC;CACA;CACA;AACF;AAEA,IAAa,wBAAb,MAAsC;CACpC;CACA;CACA;CACA;AACF;AAEA,IAAa,0BAAb,MAAqC;CACnC;CACA;CACA;CACA;CACA;CACA;CACA;AACF;AAEA,IAAa,6BAAb,MAAwC;CACtC;CACA;CACA;CACA;CACA;CACA;AACF;;;;AC9EA,IAAsB,cAAtB,cAA2E,YAAY;CACrF;CACA;CACA;AAGF;AAEA,IAAsB,qBAAtB,cAAkF,YAAY;CAC5F;CACA;CACA;AAGF"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as __name } from "../../bignumber-DddanwOv.js";
|
|
2
|
-
import { a as SolanaBaseProcessor } from "../../solana-
|
|
2
|
+
import { a as SolanaBaseProcessor } from "../../solana-BC0uJEJ-.js";
|
|
3
3
|
|
|
4
4
|
//#region src/solana/builtin/spl-token-processor.ts
|
|
5
5
|
var SPLTokenProcessor = class SPLTokenProcessor extends SolanaBaseProcessor {
|
package/dist/solana/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as SolanaBaseProcessor, c as SolanaContext, i as SolanaPlugin, n as SolanaBindOptions, o as SolanaGlobalProcessor, r as SolanaFetchConfig, s as SolanaProcessorState, t as import_cjs } from "../solana-
|
|
1
|
+
import { a as SolanaBaseProcessor, c as SolanaContext, i as SolanaPlugin, n as SolanaBindOptions, o as SolanaGlobalProcessor, r as SolanaFetchConfig, s as SolanaProcessorState, t as import_cjs } from "../solana-BC0uJEJ-.js";
|
|
2
2
|
|
|
3
3
|
var BorshInstructionCoder = import_cjs.BorshInstructionCoder;
|
|
4
4
|
export { BorshInstructionCoder, SolanaBaseProcessor, SolanaBindOptions, SolanaContext, SolanaFetchConfig, SolanaGlobalProcessor, SolanaPlugin, SolanaProcessorState };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as __name, i as __exportAll, n as __commonJSMin, o as __require, r as __esmMin, s as __toCommonJS } from "./bignumber-DddanwOv.js";
|
|
2
|
-
import { $n as OnIntervalConfigSchema, An as HandlerType, Ct as ContractConfigSchema, F as Code, Nn as InstructionHandlerConfigSchema, P as ConnectError, Z as normalizeLabels, gt as require_bn, kn as HandleIntervalSchema, o as BaseContext, ot as require_node_ponyfill, r as ALL_ADDRESS, st as require_lib$2, ui as create, yr as RecordMetaDataSchema } from "./core-
|
|
2
|
+
import { $n as OnIntervalConfigSchema, An as HandlerType, Ct as ContractConfigSchema, F as Code, Nn as InstructionHandlerConfigSchema, P as ConnectError, Z as normalizeLabels, gt as require_bn, kn as HandleIntervalSchema, o as BaseContext, ot as require_node_ponyfill, r as ALL_ADDRESS, st as require_lib$2, ui as create, yr as RecordMetaDataSchema } from "./core-DUPgecQ_.js";
|
|
3
3
|
import "./index.js";
|
|
4
4
|
import { t as require_eventemitter3$1 } from "./eventemitter3-kmMEesfv.js";
|
|
5
5
|
import { r as proxyProcessor, t as getHandlerName } from "./metrics-CPjJrL1y.js";
|
|
@@ -42114,4 +42114,4 @@ var import_cjs = require_cjs();
|
|
|
42114
42114
|
|
|
42115
42115
|
//#endregion
|
|
42116
42116
|
export { SolanaBaseProcessor as a, SolanaContext as c, SolanaPlugin as i, SolanaBindOptions as n, SolanaGlobalProcessor as o, SolanaFetchConfig as r, SolanaProcessorState as s, import_cjs as t };
|
|
42117
|
-
//# sourceMappingURL=solana-
|
|
42117
|
+
//# sourceMappingURL=solana-BC0uJEJ-.js.map
|