@sravankumar02/sdk-core 1.0.0
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/LICENSE +11 -0
- package/README.md +94 -0
- package/out/abi/argSerializer.d.ts +45 -0
- package/out/abi/argSerializer.js +171 -0
- package/out/abi/argSerializer.js.map +1 -0
- package/out/abi/argumentErrorContext.d.ts +12 -0
- package/out/abi/argumentErrorContext.js +34 -0
- package/out/abi/argumentErrorContext.js.map +1 -0
- package/out/abi/code.d.ts +23 -0
- package/out/abi/code.js +41 -0
- package/out/abi/code.js.map +1 -0
- package/out/abi/codec/address.d.ts +24 -0
- package/out/abi/codec/address.js +41 -0
- package/out/abi/codec/address.js.map +1 -0
- package/out/abi/codec/arrayVec.d.ts +11 -0
- package/out/abi/codec/arrayVec.js +39 -0
- package/out/abi/codec/arrayVec.js.map +1 -0
- package/out/abi/codec/binary.d.ts +30 -0
- package/out/abi/codec/binary.js +134 -0
- package/out/abi/codec/binary.js.map +1 -0
- package/out/abi/codec/binaryCodecUtils.d.ts +6 -0
- package/out/abi/codec/binaryCodecUtils.js +35 -0
- package/out/abi/codec/binaryCodecUtils.js.map +1 -0
- package/out/abi/codec/boolean.d.ts +13 -0
- package/out/abi/codec/boolean.js +57 -0
- package/out/abi/codec/boolean.js.map +1 -0
- package/out/abi/codec/bytes.d.ts +11 -0
- package/out/abi/codec/bytes.js +30 -0
- package/out/abi/codec/bytes.js.map +1 -0
- package/out/abi/codec/codemetadata.d.ts +8 -0
- package/out/abi/codec/codemetadata.js +23 -0
- package/out/abi/codec/codemetadata.js.map +1 -0
- package/out/abi/codec/constants.d.ts +1 -0
- package/out/abi/codec/constants.js +5 -0
- package/out/abi/codec/constants.js.map +1 -0
- package/out/abi/codec/enum.d.ts +13 -0
- package/out/abi/codec/enum.js +49 -0
- package/out/abi/codec/enum.js.map +1 -0
- package/out/abi/codec/explicit-enum.d.ts +10 -0
- package/out/abi/codec/explicit-enum.js +30 -0
- package/out/abi/codec/explicit-enum.js.map +1 -0
- package/out/abi/codec/fields.d.ts +9 -0
- package/out/abi/codec/fields.js +31 -0
- package/out/abi/codec/fields.js.map +1 -0
- package/out/abi/codec/h256.d.ts +24 -0
- package/out/abi/codec/h256.js +39 -0
- package/out/abi/codec/h256.js.map +1 -0
- package/out/abi/codec/index.d.ts +6 -0
- package/out/abi/codec/index.js +19 -0
- package/out/abi/codec/index.js.map +1 -0
- package/out/abi/codec/list.d.ts +14 -0
- package/out/abi/codec/list.js +67 -0
- package/out/abi/codec/list.js.map +1 -0
- package/out/abi/codec/managedDecimal.d.ts +11 -0
- package/out/abi/codec/managedDecimal.js +53 -0
- package/out/abi/codec/managedDecimal.js.map +1 -0
- package/out/abi/codec/managedDecimalSigned.d.ts +11 -0
- package/out/abi/codec/managedDecimalSigned.js +53 -0
- package/out/abi/codec/managedDecimalSigned.js.map +1 -0
- package/out/abi/codec/nothing.d.ts +8 -0
- package/out/abi/codec/nothing.js +20 -0
- package/out/abi/codec/nothing.js.map +1 -0
- package/out/abi/codec/numerical.d.ts +13 -0
- package/out/abi/codec/numerical.js +122 -0
- package/out/abi/codec/numerical.js.map +1 -0
- package/out/abi/codec/option.d.ts +14 -0
- package/out/abi/codec/option.js +66 -0
- package/out/abi/codec/option.js.map +1 -0
- package/out/abi/codec/primitive.d.ts +20 -0
- package/out/abi/codec/primitive.js +81 -0
- package/out/abi/codec/primitive.js.map +1 -0
- package/out/abi/codec/string.d.ts +9 -0
- package/out/abi/codec/string.js +28 -0
- package/out/abi/codec/string.js.map +1 -0
- package/out/abi/codec/struct.d.ts +11 -0
- package/out/abi/codec/struct.js +30 -0
- package/out/abi/codec/struct.js.map +1 -0
- package/out/abi/codec/tokenIdentifier.d.ts +9 -0
- package/out/abi/codec/tokenIdentifier.js +28 -0
- package/out/abi/codec/tokenIdentifier.js.map +1 -0
- package/out/abi/codec/tuple.d.ts +11 -0
- package/out/abi/codec/tuple.js +23 -0
- package/out/abi/codec/tuple.js.map +1 -0
- package/out/abi/codec/utils.d.ts +20 -0
- package/out/abi/codec/utils.js +69 -0
- package/out/abi/codec/utils.js.map +1 -0
- package/out/abi/function.d.ts +24 -0
- package/out/abi/function.js +56 -0
- package/out/abi/function.js.map +1 -0
- package/out/abi/index.d.ts +12 -0
- package/out/abi/index.js +25 -0
- package/out/abi/index.js.map +1 -0
- package/out/abi/interaction.d.ts +67 -0
- package/out/abi/interaction.js +146 -0
- package/out/abi/interaction.js.map +1 -0
- package/out/abi/interface.d.ts +85 -0
- package/out/abi/interface.js +3 -0
- package/out/abi/interface.js.map +1 -0
- package/out/abi/nativeSerializer.d.ts +27 -0
- package/out/abi/nativeSerializer.js +343 -0
- package/out/abi/nativeSerializer.js.map +1 -0
- package/out/abi/query.d.ts +18 -0
- package/out/abi/query.js +19 -0
- package/out/abi/query.js.map +1 -0
- package/out/abi/returnCode.d.ts +26 -0
- package/out/abi/returnCode.js +45 -0
- package/out/abi/returnCode.js.map +1 -0
- package/out/abi/smartContract.d.ts +74 -0
- package/out/abi/smartContract.js +208 -0
- package/out/abi/smartContract.js.map +1 -0
- package/out/abi/typeFormula.d.ts +7 -0
- package/out/abi/typeFormula.js +20 -0
- package/out/abi/typeFormula.js.map +1 -0
- package/out/abi/typeFormulaParser.d.ts +14 -0
- package/out/abi/typeFormulaParser.js +126 -0
- package/out/abi/typeFormulaParser.js.map +1 -0
- package/out/abi/typesystem/abi.d.ts +64 -0
- package/out/abi/typesystem/abi.js +208 -0
- package/out/abi/typesystem/abi.js.map +1 -0
- package/out/abi/typesystem/address.d.ts +23 -0
- package/out/abi/typesystem/address.js +41 -0
- package/out/abi/typesystem/address.js.map +1 -0
- package/out/abi/typesystem/algebraic.d.ts +24 -0
- package/out/abi/typesystem/algebraic.js +59 -0
- package/out/abi/typesystem/algebraic.js.map +1 -0
- package/out/abi/typesystem/boolean.d.ts +24 -0
- package/out/abi/typesystem/boolean.js +46 -0
- package/out/abi/typesystem/boolean.js.map +1 -0
- package/out/abi/typesystem/bytes.d.ts +28 -0
- package/out/abi/typesystem/bytes.js +58 -0
- package/out/abi/typesystem/bytes.js.map +1 -0
- package/out/abi/typesystem/codeMetadata.d.ts +11 -0
- package/out/abi/typesystem/codeMetadata.js +24 -0
- package/out/abi/typesystem/codeMetadata.js.map +1 -0
- package/out/abi/typesystem/collections.d.ts +9 -0
- package/out/abi/typesystem/collections.js +32 -0
- package/out/abi/typesystem/collections.js.map +1 -0
- package/out/abi/typesystem/composite.d.ts +16 -0
- package/out/abi/typesystem/composite.js +53 -0
- package/out/abi/typesystem/composite.js.map +1 -0
- package/out/abi/typesystem/endpoint.d.ts +41 -0
- package/out/abi/typesystem/endpoint.js +78 -0
- package/out/abi/typesystem/endpoint.js.map +1 -0
- package/out/abi/typesystem/enum.d.ts +51 -0
- package/out/abi/typesystem/enum.js +137 -0
- package/out/abi/typesystem/enum.js.map +1 -0
- package/out/abi/typesystem/event.d.ts +25 -0
- package/out/abi/typesystem/event.js +36 -0
- package/out/abi/typesystem/event.js.map +1 -0
- package/out/abi/typesystem/explicit-enum.d.ts +33 -0
- package/out/abi/typesystem/explicit-enum.js +63 -0
- package/out/abi/typesystem/explicit-enum.js.map +1 -0
- package/out/abi/typesystem/factory.d.ts +4 -0
- package/out/abi/typesystem/factory.js +19 -0
- package/out/abi/typesystem/factory.js.map +1 -0
- package/out/abi/typesystem/fields.d.ts +24 -0
- package/out/abi/typesystem/fields.js +90 -0
- package/out/abi/typesystem/fields.js.map +1 -0
- package/out/abi/typesystem/generic.d.ts +47 -0
- package/out/abi/typesystem/generic.js +120 -0
- package/out/abi/typesystem/generic.js.map +1 -0
- package/out/abi/typesystem/genericArray.d.ts +17 -0
- package/out/abi/typesystem/genericArray.js +44 -0
- package/out/abi/typesystem/genericArray.js.map +1 -0
- package/out/abi/typesystem/h256.d.ts +18 -0
- package/out/abi/typesystem/h256.js +35 -0
- package/out/abi/typesystem/h256.js.map +1 -0
- package/out/abi/typesystem/index.d.ts +33 -0
- package/out/abi/typesystem/index.js +46 -0
- package/out/abi/typesystem/index.js.map +1 -0
- package/out/abi/typesystem/managedDecimal.d.ts +26 -0
- package/out/abi/typesystem/managedDecimal.js +62 -0
- package/out/abi/typesystem/managedDecimal.js.map +1 -0
- package/out/abi/typesystem/managedDecimalSigned.d.ts +26 -0
- package/out/abi/typesystem/managedDecimalSigned.js +62 -0
- package/out/abi/typesystem/managedDecimalSigned.js.map +1 -0
- package/out/abi/typesystem/matchers.d.ts +51 -0
- package/out/abi/typesystem/matchers.js +185 -0
- package/out/abi/typesystem/matchers.js.map +1 -0
- package/out/abi/typesystem/nothing.d.ts +13 -0
- package/out/abi/typesystem/nothing.js +31 -0
- package/out/abi/typesystem/nothing.js.map +1 -0
- package/out/abi/typesystem/numerical.d.ts +130 -0
- package/out/abi/typesystem/numerical.js +286 -0
- package/out/abi/typesystem/numerical.js.map +1 -0
- package/out/abi/typesystem/string.d.ts +26 -0
- package/out/abi/typesystem/string.js +51 -0
- package/out/abi/typesystem/string.js.map +1 -0
- package/out/abi/typesystem/struct.d.ts +30 -0
- package/out/abi/typesystem/struct.js +78 -0
- package/out/abi/typesystem/struct.js.map +1 -0
- package/out/abi/typesystem/tokenIdentifier.d.ts +21 -0
- package/out/abi/typesystem/tokenIdentifier.js +51 -0
- package/out/abi/typesystem/tokenIdentifier.js.map +1 -0
- package/out/abi/typesystem/tuple.d.ts +16 -0
- package/out/abi/typesystem/tuple.js +71 -0
- package/out/abi/typesystem/tuple.js.map +1 -0
- package/out/abi/typesystem/typeExpressionParser.d.ts +8 -0
- package/out/abi/typesystem/typeExpressionParser.js +30 -0
- package/out/abi/typesystem/typeExpressionParser.js.map +1 -0
- package/out/abi/typesystem/typeMapper.d.ts +20 -0
- package/out/abi/typesystem/typeMapper.js +215 -0
- package/out/abi/typesystem/typeMapper.js.map +1 -0
- package/out/abi/typesystem/types.d.ts +129 -0
- package/out/abi/typesystem/types.js +285 -0
- package/out/abi/typesystem/types.js.map +1 -0
- package/out/abi/typesystem/variadic.d.ts +35 -0
- package/out/abi/typesystem/variadic.js +81 -0
- package/out/abi/typesystem/variadic.js.map +1 -0
- package/out/accountManagement/accountController.d.ts +18 -0
- package/out/accountManagement/accountController.js +54 -0
- package/out/accountManagement/accountController.js.map +1 -0
- package/out/accountManagement/accountTransactionsFactory.d.ts +27 -0
- package/out/accountManagement/accountTransactionsFactory.js +78 -0
- package/out/accountManagement/accountTransactionsFactory.js.map +1 -0
- package/out/accountManagement/index.d.ts +3 -0
- package/out/accountManagement/index.js +16 -0
- package/out/accountManagement/index.js.map +1 -0
- package/out/accountManagement/resources.d.ts +8 -0
- package/out/accountManagement/resources.js +3 -0
- package/out/accountManagement/resources.js.map +1 -0
- package/out/accounts/account.d.ts +94 -0
- package/out/accounts/account.js +154 -0
- package/out/accounts/account.js.map +1 -0
- package/out/accounts/index.d.ts +1 -0
- package/out/accounts/index.js +14 -0
- package/out/accounts/index.js.map +1 -0
- package/out/core/address.d.ts +105 -0
- package/out/core/address.js +313 -0
- package/out/core/address.js.map +1 -0
- package/out/core/asyncTimer.d.ts +27 -0
- package/out/core/asyncTimer.js +91 -0
- package/out/core/asyncTimer.js.map +1 -0
- package/out/core/baseController.d.ts +16 -0
- package/out/core/baseController.js +34 -0
- package/out/core/baseController.js.map +1 -0
- package/out/core/codeMetadata.d.ts +74 -0
- package/out/core/codeMetadata.js +146 -0
- package/out/core/codeMetadata.js.map +1 -0
- package/out/core/compatibility.d.ts +10 -0
- package/out/core/compatibility.js +22 -0
- package/out/core/compatibility.js.map +1 -0
- package/out/core/config.d.ts +15 -0
- package/out/core/config.js +20 -0
- package/out/core/config.js.map +1 -0
- package/out/core/constants.d.ts +28 -0
- package/out/core/constants.js +32 -0
- package/out/core/constants.js.map +1 -0
- package/out/core/errors.d.ts +279 -0
- package/out/core/errors.js +437 -0
- package/out/core/errors.js.map +1 -0
- package/out/core/globals.d.ts +0 -0
- package/out/core/globals.js +5 -0
- package/out/core/globals.js.map +1 -0
- package/out/core/index.d.ts +21 -0
- package/out/core/index.js +35 -0
- package/out/core/index.js.map +1 -0
- package/out/core/interfaces.d.ts +40 -0
- package/out/core/interfaces.js +3 -0
- package/out/core/interfaces.js.map +1 -0
- package/out/core/logger.d.ts +17 -0
- package/out/core/logger.js +50 -0
- package/out/core/logger.js.map +1 -0
- package/out/core/message.d.ts +57 -0
- package/out/core/message.js +71 -0
- package/out/core/message.js.map +1 -0
- package/out/core/networkParams.d.ts +57 -0
- package/out/core/networkParams.js +112 -0
- package/out/core/networkParams.js.map +1 -0
- package/out/core/reflection.d.ts +1 -0
- package/out/core/reflection.js +14 -0
- package/out/core/reflection.js.map +1 -0
- package/out/core/signature.d.ts +17 -0
- package/out/core/signature.js +82 -0
- package/out/core/signature.js.map +1 -0
- package/out/core/smartContractQuery.d.ts +35 -0
- package/out/core/smartContractQuery.js +34 -0
- package/out/core/smartContractQuery.js.map +1 -0
- package/out/core/tokenTransfersDataBuilder.d.ts +10 -0
- package/out/core/tokenTransfersDataBuilder.js +44 -0
- package/out/core/tokenTransfersDataBuilder.js.map +1 -0
- package/out/core/tokens.d.ts +130 -0
- package/out/core/tokens.js +287 -0
- package/out/core/tokens.js.map +1 -0
- package/out/core/transaction.d.ts +263 -0
- package/out/core/transaction.js +323 -0
- package/out/core/transaction.js.map +1 -0
- package/out/core/transactionBuilder.d.ts +32 -0
- package/out/core/transactionBuilder.js +45 -0
- package/out/core/transactionBuilder.js.map +1 -0
- package/out/core/transactionComputer.d.ts +51 -0
- package/out/core/transactionComputer.js +163 -0
- package/out/core/transactionComputer.js.map +1 -0
- package/out/core/transactionEvents.d.ts +17 -0
- package/out/core/transactionEvents.js +27 -0
- package/out/core/transactionEvents.js.map +1 -0
- package/out/core/transactionLogs.d.ts +11 -0
- package/out/core/transactionLogs.js +38 -0
- package/out/core/transactionLogs.js.map +1 -0
- package/out/core/transactionOnNetwork.d.ts +40 -0
- package/out/core/transactionOnNetwork.js +164 -0
- package/out/core/transactionOnNetwork.js.map +1 -0
- package/out/core/transactionStatus.d.ts +45 -0
- package/out/core/transactionStatus.js +71 -0
- package/out/core/transactionStatus.js.map +1 -0
- package/out/core/transactionWatcher.d.ts +48 -0
- package/out/core/transactionWatcher.js +148 -0
- package/out/core/transactionWatcher.js.map +1 -0
- package/out/core/transactionsFactoryConfig.d.ts +54 -0
- package/out/core/transactionsFactoryConfig.js +66 -0
- package/out/core/transactionsFactoryConfig.js.map +1 -0
- package/out/core/utils.codec.d.ts +8 -0
- package/out/core/utils.codec.js +75 -0
- package/out/core/utils.codec.js.map +1 -0
- package/out/core/utils.d.ts +20 -0
- package/out/core/utils.js +86 -0
- package/out/core/utils.js.map +1 -0
- package/out/delegation/delegationController.d.ts +37 -0
- package/out/delegation/delegationController.js +215 -0
- package/out/delegation/delegationController.js.map +1 -0
- package/out/delegation/delegationTransactionsFactory.d.ts +48 -0
- package/out/delegation/delegationTransactionsFactory.js +311 -0
- package/out/delegation/delegationTransactionsFactory.js.map +1 -0
- package/out/delegation/delegationTransactionsOutcomeParser.d.ts +10 -0
- package/out/delegation/delegationTransactionsOutcomeParser.js +35 -0
- package/out/delegation/delegationTransactionsOutcomeParser.js.map +1 -0
- package/out/delegation/index.d.ts +4 -0
- package/out/delegation/index.js +17 -0
- package/out/delegation/index.js.map +1 -0
- package/out/delegation/resources.d.ts +38 -0
- package/out/delegation/resources.js +3 -0
- package/out/delegation/resources.js.map +1 -0
- package/out/entrypoints/config.d.ts +29 -0
- package/out/entrypoints/config.js +36 -0
- package/out/entrypoints/config.js.map +1 -0
- package/out/entrypoints/entrypoints.d.ts +92 -0
- package/out/entrypoints/entrypoints.js +203 -0
- package/out/entrypoints/entrypoints.js.map +1 -0
- package/out/entrypoints/index.d.ts +2 -0
- package/out/entrypoints/index.js +15 -0
- package/out/entrypoints/index.js.map +1 -0
- package/out/governance/governanceController.d.ts +33 -0
- package/out/governance/governanceController.js +205 -0
- package/out/governance/governanceController.js.map +1 -0
- package/out/governance/governanceTransactionsFactory.d.ts +16 -0
- package/out/governance/governanceTransactionsFactory.js +99 -0
- package/out/governance/governanceTransactionsFactory.js.map +1 -0
- package/out/governance/governanceTransactionsOutcomeParser.d.ts +15 -0
- package/out/governance/governanceTransactionsOutcomeParser.js +99 -0
- package/out/governance/governanceTransactionsOutcomeParser.js.map +1 -0
- package/out/governance/index.d.ts +4 -0
- package/out/governance/index.js +17 -0
- package/out/governance/index.js.map +1 -0
- package/out/governance/resources.d.ts +82 -0
- package/out/governance/resources.js +11 -0
- package/out/governance/resources.js.map +1 -0
- package/out/index.d.ts +19 -0
- package/out/index.js +32 -0
- package/out/index.js.map +1 -0
- package/out/multisig/index.d.ts +3 -0
- package/out/multisig/index.js +16 -0
- package/out/multisig/index.js.map +1 -0
- package/out/multisig/multisigController.d.ts +221 -0
- package/out/multisig/multisigController.js +540 -0
- package/out/multisig/multisigController.js.map +1 -0
- package/out/multisig/multisigTransactionsFactory.d.ts +110 -0
- package/out/multisig/multisigTransactionsFactory.js +355 -0
- package/out/multisig/multisigTransactionsFactory.js.map +1 -0
- package/out/multisig/multisigTransactionsOutcomeParser.d.ts +31 -0
- package/out/multisig/multisigTransactionsOutcomeParser.js +41 -0
- package/out/multisig/multisigTransactionsOutcomeParser.js.map +1 -0
- package/out/multisig/proposeTransferExecuteContractInput.d.ts +32 -0
- package/out/multisig/proposeTransferExecuteContractInput.js +65 -0
- package/out/multisig/proposeTransferExecuteContractInput.js.map +1 -0
- package/out/multisig/resources.d.ts +182 -0
- package/out/multisig/resources.js +125 -0
- package/out/multisig/resources.js.map +1 -0
- package/out/networkProviders/accountAwaiter.d.ts +35 -0
- package/out/networkProviders/accountAwaiter.js +67 -0
- package/out/networkProviders/accountAwaiter.js.map +1 -0
- package/out/networkProviders/accounts.d.ts +55 -0
- package/out/networkProviders/accounts.js +154 -0
- package/out/networkProviders/accounts.js.map +1 -0
- package/out/networkProviders/apiNetworkProvider.d.ts +48 -0
- package/out/networkProviders/apiNetworkProvider.js +235 -0
- package/out/networkProviders/apiNetworkProvider.js.map +1 -0
- package/out/networkProviders/blocks.d.ts +48 -0
- package/out/networkProviders/blocks.js +76 -0
- package/out/networkProviders/blocks.js.map +1 -0
- package/out/networkProviders/config.d.ts +6 -0
- package/out/networkProviders/config.js +18 -0
- package/out/networkProviders/config.js.map +1 -0
- package/out/networkProviders/constants.d.ts +9 -0
- package/out/networkProviders/constants.js +16 -0
- package/out/networkProviders/constants.js.map +1 -0
- package/out/networkProviders/contractQueryRequest.d.ts +6 -0
- package/out/networkProviders/contractQueryRequest.js +20 -0
- package/out/networkProviders/contractQueryRequest.js.map +1 -0
- package/out/networkProviders/index.d.ts +11 -0
- package/out/networkProviders/index.js +28 -0
- package/out/networkProviders/index.js.map +1 -0
- package/out/networkProviders/interface.d.ts +110 -0
- package/out/networkProviders/interface.js +3 -0
- package/out/networkProviders/interface.js.map +1 -0
- package/out/networkProviders/networkConfig.d.ts +48 -0
- package/out/networkProviders/networkConfig.js +41 -0
- package/out/networkProviders/networkConfig.js.map +1 -0
- package/out/networkProviders/networkProviderConfig.d.ts +4 -0
- package/out/networkProviders/networkProviderConfig.js +3 -0
- package/out/networkProviders/networkProviderConfig.js.map +1 -0
- package/out/networkProviders/networkStatus.d.ts +31 -0
- package/out/networkProviders/networkStatus.js +31 -0
- package/out/networkProviders/networkStatus.js.map +1 -0
- package/out/networkProviders/proxyNetworkProvider.d.ts +51 -0
- package/out/networkProviders/proxyNetworkProvider.js +261 -0
- package/out/networkProviders/proxyNetworkProvider.js.map +1 -0
- package/out/networkProviders/resources.d.ts +12 -0
- package/out/networkProviders/resources.js +29 -0
- package/out/networkProviders/resources.js.map +1 -0
- package/out/networkProviders/tokenDefinitions.d.ts +49 -0
- package/out/networkProviders/tokenDefinitions.js +152 -0
- package/out/networkProviders/tokenDefinitions.js.map +1 -0
- package/out/networkProviders/tokens.d.ts +40 -0
- package/out/networkProviders/tokens.js +106 -0
- package/out/networkProviders/tokens.js.map +1 -0
- package/out/networkProviders/userAgent.d.ts +2 -0
- package/out/networkProviders/userAgent.js +30 -0
- package/out/networkProviders/userAgent.js.map +1 -0
- package/out/proto/compiled.d.ts +2 -0
- package/out/proto/compiled.js +719 -0
- package/out/proto/compiled.js.map +1 -0
- package/out/proto/index.d.ts +5 -0
- package/out/proto/index.js +18 -0
- package/out/proto/index.js.map +1 -0
- package/out/proto/serializer.d.ts +22 -0
- package/out/proto/serializer.js +114 -0
- package/out/proto/serializer.js.map +1 -0
- package/out/smartContracts/index.d.ts +4 -0
- package/out/smartContracts/index.js +17 -0
- package/out/smartContracts/index.js.map +1 -0
- package/out/smartContracts/resources.d.ts +38 -0
- package/out/smartContracts/resources.js +3 -0
- package/out/smartContracts/resources.js.map +1 -0
- package/out/smartContracts/smartContractController.d.ts +32 -0
- package/out/smartContracts/smartContractController.js +128 -0
- package/out/smartContracts/smartContractController.js.map +1 -0
- package/out/smartContracts/smartContractTransactionsFactory.d.ts +42 -0
- package/out/smartContracts/smartContractTransactionsFactory.js +165 -0
- package/out/smartContracts/smartContractTransactionsFactory.js.map +1 -0
- package/out/smartContracts/smartContractTransactionsOutcomeParser.d.ts +28 -0
- package/out/smartContracts/smartContractTransactionsOutcomeParser.js +189 -0
- package/out/smartContracts/smartContractTransactionsOutcomeParser.js.map +1 -0
- package/out/tokenManagement/index.d.ts +4 -0
- package/out/tokenManagement/index.js +17 -0
- package/out/tokenManagement/index.js.map +1 -0
- package/out/tokenManagement/resources.d.ts +220 -0
- package/out/tokenManagement/resources.js +3 -0
- package/out/tokenManagement/resources.js.map +1 -0
- package/out/tokenManagement/tokenManagementController.d.ts +108 -0
- package/out/tokenManagement/tokenManagementController.js +582 -0
- package/out/tokenManagement/tokenManagementController.js.map +1 -0
- package/out/tokenManagement/tokenManagementTransactionsFactory.d.ts +82 -0
- package/out/tokenManagement/tokenManagementTransactionsFactory.js +684 -0
- package/out/tokenManagement/tokenManagementTransactionsFactory.js.map +1 -0
- package/out/tokenManagement/tokenManagementTransactionsOutcomeParser.d.ts +109 -0
- package/out/tokenManagement/tokenManagementTransactionsOutcomeParser.js +356 -0
- package/out/tokenManagement/tokenManagementTransactionsOutcomeParser.js.map +1 -0
- package/out/tokenOperations/codec.d.ts +7 -0
- package/out/tokenOperations/codec.js +55 -0
- package/out/tokenOperations/codec.js.map +1 -0
- package/out/transactionsOutcomeParsers/index.d.ts +4 -0
- package/out/transactionsOutcomeParsers/index.js +17 -0
- package/out/transactionsOutcomeParsers/index.js.map +1 -0
- package/out/transactionsOutcomeParsers/resources.d.ts +23 -0
- package/out/transactionsOutcomeParsers/resources.js +48 -0
- package/out/transactionsOutcomeParsers/resources.js.map +1 -0
- package/out/transactionsOutcomeParsers/transactionEventsParser.d.ts +16 -0
- package/out/transactionsOutcomeParsers/transactionEventsParser.js +48 -0
- package/out/transactionsOutcomeParsers/transactionEventsParser.js.map +1 -0
- package/out/transfers/index.d.ts +3 -0
- package/out/transfers/index.js +16 -0
- package/out/transfers/index.js.map +1 -0
- package/out/transfers/resources.d.ts +17 -0
- package/out/transfers/resources.js +3 -0
- package/out/transfers/resources.js.map +1 -0
- package/out/transfers/transferTransactionsFactory.d.ts +32 -0
- package/out/transfers/transferTransactionsFactory.js +131 -0
- package/out/transfers/transferTransactionsFactory.js.map +1 -0
- package/out/transfers/transfersControllers.d.ts +11 -0
- package/out/transfers/transfersControllers.js +43 -0
- package/out/transfers/transfersControllers.js.map +1 -0
- package/out/wallet/assertions.d.ts +3 -0
- package/out/wallet/assertions.js +12 -0
- package/out/wallet/assertions.js.map +1 -0
- package/out/wallet/crypto/constants.d.ts +6 -0
- package/out/wallet/crypto/constants.js +11 -0
- package/out/wallet/crypto/constants.js.map +1 -0
- package/out/wallet/crypto/decryptor.d.ts +5 -0
- package/out/wallet/crypto/decryptor.js +29 -0
- package/out/wallet/crypto/decryptor.js.map +1 -0
- package/out/wallet/crypto/derivationParams.d.ts +23 -0
- package/out/wallet/crypto/derivationParams.js +38 -0
- package/out/wallet/crypto/derivationParams.js.map +1 -0
- package/out/wallet/crypto/encryptedData.d.ts +15 -0
- package/out/wallet/crypto/encryptedData.js +52 -0
- package/out/wallet/crypto/encryptedData.js.map +1 -0
- package/out/wallet/crypto/encryptor.d.ts +14 -0
- package/out/wallet/crypto/encryptor.js +39 -0
- package/out/wallet/crypto/encryptor.js.map +1 -0
- package/out/wallet/crypto/index.d.ts +7 -0
- package/out/wallet/crypto/index.js +20 -0
- package/out/wallet/crypto/index.js.map +1 -0
- package/out/wallet/crypto/pubkeyDecryptor.d.ts +6 -0
- package/out/wallet/crypto/pubkeyDecryptor.js +38 -0
- package/out/wallet/crypto/pubkeyDecryptor.js.map +1 -0
- package/out/wallet/crypto/pubkeyEncryptor.d.ts +6 -0
- package/out/wallet/crypto/pubkeyEncryptor.js +54 -0
- package/out/wallet/crypto/pubkeyEncryptor.js.map +1 -0
- package/out/wallet/crypto/randomness.d.ts +7 -0
- package/out/wallet/crypto/randomness.js +15 -0
- package/out/wallet/crypto/randomness.js.map +1 -0
- package/out/wallet/crypto/x25519EncryptedData.d.ts +15 -0
- package/out/wallet/crypto/x25519EncryptedData.js +37 -0
- package/out/wallet/crypto/x25519EncryptedData.js.map +1 -0
- package/out/wallet/index.d.ts +11 -0
- package/out/wallet/index.js +24 -0
- package/out/wallet/index.js.map +1 -0
- package/out/wallet/keypair.d.ts +12 -0
- package/out/wallet/keypair.js +32 -0
- package/out/wallet/keypair.js.map +1 -0
- package/out/wallet/mnemonic.d.ts +13 -0
- package/out/wallet/mnemonic.js +74 -0
- package/out/wallet/mnemonic.js.map +1 -0
- package/out/wallet/pem.d.ts +8 -0
- package/out/wallet/pem.js +60 -0
- package/out/wallet/pem.js.map +1 -0
- package/out/wallet/pemEntry.d.ts +10 -0
- package/out/wallet/pemEntry.js +73 -0
- package/out/wallet/pemEntry.js.map +1 -0
- package/out/wallet/userKeys.d.ts +23 -0
- package/out/wallet/userKeys.js +99 -0
- package/out/wallet/userKeys.js.map +1 -0
- package/out/wallet/userPem.d.ts +15 -0
- package/out/wallet/userPem.js +51 -0
- package/out/wallet/userPem.js.map +1 -0
- package/out/wallet/userSigner.d.ts +16 -0
- package/out/wallet/userSigner.js +41 -0
- package/out/wallet/userSigner.js.map +1 -0
- package/out/wallet/userVerifier.d.ts +18 -0
- package/out/wallet/userVerifier.js +27 -0
- package/out/wallet/userVerifier.js.map +1 -0
- package/out/wallet/userWallet.d.ts +54 -0
- package/out/wallet/userWallet.js +206 -0
- package/out/wallet/userWallet.js.map +1 -0
- package/out/wallet/validatorKeys.d.ts +26 -0
- package/out/wallet/validatorKeys.js +77 -0
- package/out/wallet/validatorKeys.js.map +1 -0
- package/out/wallet/validatorSigner.d.ts +10 -0
- package/out/wallet/validatorSigner.js +25 -0
- package/out/wallet/validatorSigner.js.map +1 -0
- package/package.json +84 -0
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { Address } from "./address";
|
|
2
|
+
export declare class SmartContractQuery {
|
|
3
|
+
contract: Address;
|
|
4
|
+
caller?: Address;
|
|
5
|
+
value?: bigint;
|
|
6
|
+
function: string;
|
|
7
|
+
arguments?: Uint8Array[];
|
|
8
|
+
constructor(options: {
|
|
9
|
+
contract: Address;
|
|
10
|
+
caller?: Address;
|
|
11
|
+
value?: bigint;
|
|
12
|
+
function: string;
|
|
13
|
+
arguments?: Uint8Array[];
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
export declare type SmartContractQueryInput = {
|
|
17
|
+
contract: Address;
|
|
18
|
+
caller?: Address;
|
|
19
|
+
value?: bigint;
|
|
20
|
+
function: string;
|
|
21
|
+
arguments: any[];
|
|
22
|
+
};
|
|
23
|
+
export declare class SmartContractQueryResponse {
|
|
24
|
+
function: string;
|
|
25
|
+
returnCode: string;
|
|
26
|
+
returnMessage: string;
|
|
27
|
+
returnDataParts: Uint8Array[];
|
|
28
|
+
constructor(obj: {
|
|
29
|
+
function: string;
|
|
30
|
+
returnCode: string;
|
|
31
|
+
returnMessage: string;
|
|
32
|
+
returnDataParts: Uint8Array[];
|
|
33
|
+
});
|
|
34
|
+
static fromHttpResponse(payload: any, functionName: string): SmartContractQueryResponse;
|
|
35
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SmartContractQueryResponse = exports.SmartContractQuery = void 0;
|
|
4
|
+
class SmartContractQuery {
|
|
5
|
+
constructor(options) {
|
|
6
|
+
this.contract = options.contract;
|
|
7
|
+
this.caller = options.caller;
|
|
8
|
+
this.value = options.value;
|
|
9
|
+
this.function = options.function;
|
|
10
|
+
this.arguments = options.arguments;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
exports.SmartContractQuery = SmartContractQuery;
|
|
14
|
+
class SmartContractQueryResponse {
|
|
15
|
+
constructor(obj) {
|
|
16
|
+
this.function = obj.function;
|
|
17
|
+
this.returnCode = obj.returnCode;
|
|
18
|
+
this.returnMessage = obj.returnMessage;
|
|
19
|
+
this.returnDataParts = obj.returnDataParts;
|
|
20
|
+
}
|
|
21
|
+
static fromHttpResponse(payload, functionName) {
|
|
22
|
+
let returnData = payload["returnData"] || payload["ReturnData"];
|
|
23
|
+
let returnCode = payload["returnCode"] || payload["ReturnCode"];
|
|
24
|
+
let returnMessage = payload["returnMessage"] || payload["ReturnMessage"];
|
|
25
|
+
return new SmartContractQueryResponse({
|
|
26
|
+
returnDataParts: returnData?.map((item) => Buffer.from(item || "", "base64")) ?? [],
|
|
27
|
+
returnCode: returnCode,
|
|
28
|
+
returnMessage: returnMessage,
|
|
29
|
+
function: functionName,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
exports.SmartContractQueryResponse = SmartContractQueryResponse;
|
|
34
|
+
//# sourceMappingURL=smartContractQuery.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"smartContractQuery.js","sourceRoot":"","sources":["../../src/core/smartContractQuery.ts"],"names":[],"mappings":";;;AAEA,MAAa,kBAAkB;IAO3B,YAAY,OAMX;QACG,IAA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import { Address } from "./address";
|
|
2
|
+
import { TokenTransfer } from "./tokens";
|
|
3
|
+
export declare class TokenTransfersDataBuilder {
|
|
4
|
+
private tokenComputer;
|
|
5
|
+
private argsSerializer;
|
|
6
|
+
constructor();
|
|
7
|
+
buildDataPartsForDCDTTransfer(transfer: TokenTransfer): string[];
|
|
8
|
+
buildDataPartsForSingleDCDTNFTTransfer(transfer: TokenTransfer, receiver: Address): string[];
|
|
9
|
+
buildDataPartsForMultiDCDTNFTTransfer(receiver: Address, transfers: TokenTransfer[]): string[];
|
|
10
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TokenTransfersDataBuilder = void 0;
|
|
4
|
+
const abi_1 = require("../abi");
|
|
5
|
+
const tokens_1 = require("./tokens");
|
|
6
|
+
class TokenTransfersDataBuilder {
|
|
7
|
+
constructor() {
|
|
8
|
+
this.tokenComputer = new tokens_1.TokenComputer();
|
|
9
|
+
this.argsSerializer = new abi_1.ArgSerializer();
|
|
10
|
+
}
|
|
11
|
+
buildDataPartsForDCDTTransfer(transfer) {
|
|
12
|
+
const args = this.argsSerializer.valuesToStrings([
|
|
13
|
+
new abi_1.TokenIdentifierValue(transfer.token.identifier),
|
|
14
|
+
new abi_1.BigUIntValue(transfer.amount),
|
|
15
|
+
]);
|
|
16
|
+
return ["DCDTTransfer", ...args];
|
|
17
|
+
}
|
|
18
|
+
buildDataPartsForSingleDCDTNFTTransfer(transfer, receiver) {
|
|
19
|
+
const token = transfer.token;
|
|
20
|
+
const identifier = this.tokenComputer.extractIdentifierFromExtendedIdentifier(token.identifier);
|
|
21
|
+
const args = this.argsSerializer.valuesToStrings([
|
|
22
|
+
new abi_1.TokenIdentifierValue(identifier),
|
|
23
|
+
new abi_1.BigUIntValue(token.nonce),
|
|
24
|
+
new abi_1.BigUIntValue(transfer.amount),
|
|
25
|
+
new abi_1.AddressValue(receiver),
|
|
26
|
+
]);
|
|
27
|
+
return ["DCDTNFTTransfer", ...args];
|
|
28
|
+
}
|
|
29
|
+
buildDataPartsForMultiDCDTNFTTransfer(receiver, transfers) {
|
|
30
|
+
const argsTyped = [new abi_1.AddressValue(receiver), new abi_1.U32Value(transfers.length)];
|
|
31
|
+
for (const transfer of transfers) {
|
|
32
|
+
const identifier = this.tokenComputer.extractIdentifierFromExtendedIdentifier(transfer.token.identifier);
|
|
33
|
+
argsTyped.push(...[
|
|
34
|
+
new abi_1.TokenIdentifierValue(identifier),
|
|
35
|
+
new abi_1.BigUIntValue(transfer.token.nonce),
|
|
36
|
+
new abi_1.BigUIntValue(transfer.amount),
|
|
37
|
+
]);
|
|
38
|
+
}
|
|
39
|
+
const args = this.argsSerializer.valuesToStrings(argsTyped);
|
|
40
|
+
return ["MultiDCDTNFTTransfer", ...args];
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
exports.TokenTransfersDataBuilder = TokenTransfersDataBuilder;
|
|
44
|
+
//# sourceMappingURL=tokenTransfersDataBuilder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokenTransfersDataBuilder.js","sourceRoot":"","sources":["../../src/core/tokenTransfersDataBuilder.ts"],"names":[],"mappings":";;;AAAA,gCAA+G;AAE/G,qCAAwD;AAExD,MAAa,yBAAyB;IAIlC;QACI,IAAI,CAAC,aAAa,GAAG,IAAI,sBAAa,EAAE,CAAC;QACzC,IAAI,CAAC,cAAc,GAAG,IAAI,mBAAa,EAAE,CAAC;IAC9C,CAAC;IAED,6BAA6B,CAAC,QAAuB;QACjD,MAAM,IAAI,GAAG,IAAI,CAAC,cAAc,CAAC,eAAe,CAAC;YAC7C,IAAI,0BAAoB,CAAC,QAAQ,CAAC,KAAK,CAAC,UAAU,CAAC;YACnD,IAAI,kBAAY,CAAC,QAAQ,CAAC,MAAM,CAAC;SACpC,CAAC,CAAC;QAEH,OAAO,CAAC,cAAc,EAAE,GAAG,IAAI,CAAC,CAA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|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import BigNumber from "bignumber.js";
|
|
2
|
+
interface ILegacyTokenTransferOptions {
|
|
3
|
+
tokenIdentifier: string;
|
|
4
|
+
nonce: number;
|
|
5
|
+
amountAsBigInteger: BigNumber.Value;
|
|
6
|
+
numDecimals?: number;
|
|
7
|
+
}
|
|
8
|
+
export declare type TokenType = "NFT" | "SFT" | "META" | "FNG";
|
|
9
|
+
export declare class Token {
|
|
10
|
+
/**
|
|
11
|
+
* E.g. "FOO-abcdef", "REWA-000000".
|
|
12
|
+
*/
|
|
13
|
+
readonly identifier: string;
|
|
14
|
+
readonly nonce: bigint;
|
|
15
|
+
constructor(options: {
|
|
16
|
+
identifier: string;
|
|
17
|
+
nonce?: bigint;
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
export declare class TokenTransfer {
|
|
21
|
+
readonly token: Token;
|
|
22
|
+
readonly amount: bigint;
|
|
23
|
+
/**
|
|
24
|
+
* @deprecated field. Use "token.identifier" instead.
|
|
25
|
+
*/
|
|
26
|
+
readonly tokenIdentifier: string;
|
|
27
|
+
/**
|
|
28
|
+
* @deprecated field. Use "token.nonce" instead.
|
|
29
|
+
*/
|
|
30
|
+
readonly nonce: number;
|
|
31
|
+
/**
|
|
32
|
+
* @deprecated field. Use "amount" instead.
|
|
33
|
+
*/
|
|
34
|
+
readonly amountAsBigInteger: BigNumber;
|
|
35
|
+
/**
|
|
36
|
+
* @deprecated field. The number of decimals is not a concern of "sdk-core".
|
|
37
|
+
* For formatting and parsing amounts, use "sdk-dapp" or "bignumber.js" directly.
|
|
38
|
+
*/
|
|
39
|
+
readonly numDecimals: number;
|
|
40
|
+
constructor(options: {
|
|
41
|
+
token: Token;
|
|
42
|
+
amount: bigint;
|
|
43
|
+
} | ILegacyTokenTransferOptions);
|
|
44
|
+
/** *
|
|
45
|
+
* @param amount
|
|
46
|
+
* @returns @TokenTransfer from native token
|
|
47
|
+
*/
|
|
48
|
+
static newFromNativeAmount(amount: bigint): TokenTransfer;
|
|
49
|
+
private isLegacyTokenTransferOptions;
|
|
50
|
+
/**
|
|
51
|
+
* @deprecated Use {@link newFromNativeAmount} instead.
|
|
52
|
+
*/
|
|
53
|
+
static rewaFromAmount(amount: BigNumber.Value): TokenTransfer;
|
|
54
|
+
/**
|
|
55
|
+
* @deprecated Use {@link newFromNativeAmount} instead.
|
|
56
|
+
*/
|
|
57
|
+
static rewaFromBigInteger(amountAsBigInteger: BigNumber.Value): TokenTransfer;
|
|
58
|
+
/**
|
|
59
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
60
|
+
*/
|
|
61
|
+
static fungibleFromAmount(tokenIdentifier: string, amount: BigNumber.Value, numDecimals: number): TokenTransfer;
|
|
62
|
+
/**
|
|
63
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
64
|
+
*/
|
|
65
|
+
static fungibleFromBigInteger(tokenIdentifier: string, amountAsBigInteger: BigNumber.Value, numDecimals?: number): TokenTransfer;
|
|
66
|
+
/**
|
|
67
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
68
|
+
*/
|
|
69
|
+
static nonFungible(tokenIdentifier: string, nonce: number): TokenTransfer;
|
|
70
|
+
/**
|
|
71
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
72
|
+
*/
|
|
73
|
+
static semiFungible(tokenIdentifier: string, nonce: number, quantity: number): TokenTransfer;
|
|
74
|
+
/**
|
|
75
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
76
|
+
*/
|
|
77
|
+
static metaDcdtFromAmount(tokenIdentifier: string, nonce: number, amount: BigNumber.Value, numDecimals: number): TokenTransfer;
|
|
78
|
+
/**
|
|
79
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
80
|
+
*/
|
|
81
|
+
static metaDcdtFromBigInteger(tokenIdentifier: string, nonce: number, amountAsBigInteger: BigNumber.Value, numDecimals?: number): TokenTransfer;
|
|
82
|
+
toString(): string;
|
|
83
|
+
/**
|
|
84
|
+
* @deprecated Use the "amount" field instead.
|
|
85
|
+
*/
|
|
86
|
+
valueOf(): BigNumber;
|
|
87
|
+
/**
|
|
88
|
+
* @deprecated For formatting and parsing amounts, use "sdk-dapp" or "bignumber.js" directly.
|
|
89
|
+
*/
|
|
90
|
+
toPrettyString(): string;
|
|
91
|
+
private toAmount;
|
|
92
|
+
/**
|
|
93
|
+
* @deprecated Within your code, don't mix native values (REWA) and custom (DCDT) tokens.
|
|
94
|
+
* See "TransferTransactionsFactory.createTransactionForNativeTokenTransfer()" vs. "TransferTransactionsFactory.createTransactionForDCDTTokenTransfer()".
|
|
95
|
+
*/
|
|
96
|
+
isRewa(): boolean;
|
|
97
|
+
/**
|
|
98
|
+
* @deprecated Use "TokenComputer.isFungible(token)" instead.
|
|
99
|
+
*/
|
|
100
|
+
isFungible(): boolean;
|
|
101
|
+
}
|
|
102
|
+
export declare class TokenComputer {
|
|
103
|
+
TOKEN_RANDOM_SEQUENCE_LENGTH: number;
|
|
104
|
+
constructor();
|
|
105
|
+
/**
|
|
106
|
+
* Returns token.nonce == 0
|
|
107
|
+
*/
|
|
108
|
+
isFungible(token: Token): boolean;
|
|
109
|
+
/**
|
|
110
|
+
* Given "FOO-abcdef-0a" returns 10.
|
|
111
|
+
*/
|
|
112
|
+
extractNonceFromExtendedIdentifier(identifier: string): number;
|
|
113
|
+
/**
|
|
114
|
+
* Given "FOO-abcdef-0a" returns FOO-abcdef.
|
|
115
|
+
*/
|
|
116
|
+
extractIdentifierFromExtendedIdentifier(identifier: string): string;
|
|
117
|
+
/**
|
|
118
|
+
* Given "FOO-abcdef-0a" returns FOO.
|
|
119
|
+
* Given "FOO-abcdef" returns FOO.
|
|
120
|
+
*/
|
|
121
|
+
extractTickerFromExtendedIdentifier(identifier: string): string;
|
|
122
|
+
computeExtendedIdentifier(token: Token): string;
|
|
123
|
+
private validateExtendedIdentifier;
|
|
124
|
+
private splitIdentifierIntoComponents;
|
|
125
|
+
private checkIfExtendedIdentifierWasProvided;
|
|
126
|
+
private checkLengthOfRandomSequence;
|
|
127
|
+
private checkLengthOfPrefix;
|
|
128
|
+
private ensureTokenTickerValidity;
|
|
129
|
+
}
|
|
130
|
+
export {};
|
|
@@ -0,0 +1,287 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.TokenComputer = exports.TokenTransfer = exports.Token = void 0;
|
|
7
|
+
const bignumber_js_1 = __importDefault(require("bignumber.js"));
|
|
8
|
+
const constants_1 = require("./constants");
|
|
9
|
+
const errors_1 = require("./errors");
|
|
10
|
+
const utils_codec_1 = require("./utils.codec");
|
|
11
|
+
// Legacy constants:
|
|
12
|
+
const REWATokenIdentifier = "REWA";
|
|
13
|
+
const REWANumDecimals = 18;
|
|
14
|
+
// Legacy configuration.
|
|
15
|
+
// Note: this will actually set the default rounding mode for all BigNumber objects in the environment (in the application / dApp).
|
|
16
|
+
bignumber_js_1.default.set({ ROUNDING_MODE: 1 });
|
|
17
|
+
class Token {
|
|
18
|
+
constructor(options) {
|
|
19
|
+
this.identifier = options.identifier;
|
|
20
|
+
this.nonce = options.nonce || 0n;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.Token = Token;
|
|
24
|
+
class TokenTransfer {
|
|
25
|
+
constructor(options) {
|
|
26
|
+
if (this.isLegacyTokenTransferOptions(options)) {
|
|
27
|
+
// Handle legacy fields.
|
|
28
|
+
const amount = new bignumber_js_1.default(options.amountAsBigInteger);
|
|
29
|
+
if (!amount.isInteger() || amount.isNegative()) {
|
|
30
|
+
throw new errors_1.ErrInvalidArgument(`bad amountAsBigInteger: ${options.amountAsBigInteger}`);
|
|
31
|
+
}
|
|
32
|
+
this.tokenIdentifier = options.tokenIdentifier;
|
|
33
|
+
this.nonce = options.nonce;
|
|
34
|
+
this.amountAsBigInteger = amount;
|
|
35
|
+
this.numDecimals = options.numDecimals || 0;
|
|
36
|
+
// Handle new fields.
|
|
37
|
+
this.token = new Token({
|
|
38
|
+
identifier: options.tokenIdentifier,
|
|
39
|
+
nonce: BigInt(options.nonce),
|
|
40
|
+
});
|
|
41
|
+
this.amount = BigInt(this.amountAsBigInteger.toFixed(0));
|
|
42
|
+
}
|
|
43
|
+
else {
|
|
44
|
+
// Handle new fields.
|
|
45
|
+
this.token = options.token;
|
|
46
|
+
this.amount = options.amount;
|
|
47
|
+
// Handle legacy fields.
|
|
48
|
+
this.tokenIdentifier = options.token.identifier;
|
|
49
|
+
this.nonce = Number(options.token.nonce);
|
|
50
|
+
this.amountAsBigInteger = new bignumber_js_1.default(this.amount.toString());
|
|
51
|
+
this.numDecimals = 0;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
/** *
|
|
55
|
+
* @param amount
|
|
56
|
+
* @returns @TokenTransfer from native token
|
|
57
|
+
*/
|
|
58
|
+
static newFromNativeAmount(amount) {
|
|
59
|
+
const token = new Token({ identifier: constants_1.REWA_IDENTIFIER_FOR_MULTI_DCDTNFT_TRANSFER });
|
|
60
|
+
return new TokenTransfer({ token, amount });
|
|
61
|
+
}
|
|
62
|
+
isLegacyTokenTransferOptions(options) {
|
|
63
|
+
return options.tokenIdentifier !== undefined;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* @deprecated Use {@link newFromNativeAmount} instead.
|
|
67
|
+
*/
|
|
68
|
+
static rewaFromAmount(amount) {
|
|
69
|
+
const amountAsBigInteger = new bignumber_js_1.default(amount).shiftedBy(REWANumDecimals).decimalPlaces(0);
|
|
70
|
+
return this.rewaFromBigInteger(amountAsBigInteger);
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* @deprecated Use {@link newFromNativeAmount} instead.
|
|
74
|
+
*/
|
|
75
|
+
static rewaFromBigInteger(amountAsBigInteger) {
|
|
76
|
+
return new TokenTransfer({
|
|
77
|
+
tokenIdentifier: REWATokenIdentifier,
|
|
78
|
+
nonce: 0,
|
|
79
|
+
amountAsBigInteger,
|
|
80
|
+
numDecimals: REWANumDecimals,
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
85
|
+
*/
|
|
86
|
+
static fungibleFromAmount(tokenIdentifier, amount, numDecimals) {
|
|
87
|
+
const amountAsBigInteger = new bignumber_js_1.default(amount).shiftedBy(numDecimals).decimalPlaces(0);
|
|
88
|
+
return this.fungibleFromBigInteger(tokenIdentifier, amountAsBigInteger, numDecimals);
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
92
|
+
*/
|
|
93
|
+
static fungibleFromBigInteger(tokenIdentifier, amountAsBigInteger, numDecimals = 0) {
|
|
94
|
+
return new TokenTransfer({
|
|
95
|
+
tokenIdentifier,
|
|
96
|
+
nonce: 0,
|
|
97
|
+
amountAsBigInteger,
|
|
98
|
+
numDecimals,
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
103
|
+
*/
|
|
104
|
+
static nonFungible(tokenIdentifier, nonce) {
|
|
105
|
+
return new TokenTransfer({
|
|
106
|
+
tokenIdentifier,
|
|
107
|
+
nonce,
|
|
108
|
+
amountAsBigInteger: 1,
|
|
109
|
+
numDecimals: 0,
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
114
|
+
*/
|
|
115
|
+
static semiFungible(tokenIdentifier, nonce, quantity) {
|
|
116
|
+
return new TokenTransfer({
|
|
117
|
+
tokenIdentifier,
|
|
118
|
+
nonce,
|
|
119
|
+
amountAsBigInteger: quantity,
|
|
120
|
+
numDecimals: 0,
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
125
|
+
*/
|
|
126
|
+
static metaDcdtFromAmount(tokenIdentifier, nonce, amount, numDecimals) {
|
|
127
|
+
const amountAsBigInteger = new bignumber_js_1.default(amount).shiftedBy(numDecimals).decimalPlaces(0);
|
|
128
|
+
return this.metaDcdtFromBigInteger(tokenIdentifier, nonce, amountAsBigInteger, numDecimals);
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* @deprecated Use the constructor instead: new TokenTransfer({ token, amount });
|
|
132
|
+
*/
|
|
133
|
+
static metaDcdtFromBigInteger(tokenIdentifier, nonce, amountAsBigInteger, numDecimals = 0) {
|
|
134
|
+
return new TokenTransfer({
|
|
135
|
+
tokenIdentifier,
|
|
136
|
+
nonce,
|
|
137
|
+
amountAsBigInteger,
|
|
138
|
+
numDecimals,
|
|
139
|
+
});
|
|
140
|
+
}
|
|
141
|
+
toString() {
|
|
142
|
+
return this.amount.toString();
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* @deprecated Use the "amount" field instead.
|
|
146
|
+
*/
|
|
147
|
+
valueOf() {
|
|
148
|
+
return new bignumber_js_1.default(this.amount.toString());
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* @deprecated For formatting and parsing amounts, use "sdk-dapp" or "bignumber.js" directly.
|
|
152
|
+
*/
|
|
153
|
+
toPrettyString() {
|
|
154
|
+
return `${this.toAmount()} ${this.tokenIdentifier}`;
|
|
155
|
+
}
|
|
156
|
+
toAmount() {
|
|
157
|
+
return this.amountAsBigInteger.shiftedBy(-this.numDecimals).toFixed(this.numDecimals);
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* @deprecated Within your code, don't mix native values (REWA) and custom (DCDT) tokens.
|
|
161
|
+
* See "TransferTransactionsFactory.createTransactionForNativeTokenTransfer()" vs. "TransferTransactionsFactory.createTransactionForDCDTTokenTransfer()".
|
|
162
|
+
*/
|
|
163
|
+
isRewa() {
|
|
164
|
+
return this.token.identifier == REWATokenIdentifier;
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* @deprecated Use "TokenComputer.isFungible(token)" instead.
|
|
168
|
+
*/
|
|
169
|
+
isFungible() {
|
|
170
|
+
return this.token.nonce == 0n;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
exports.TokenTransfer = TokenTransfer;
|
|
174
|
+
class TokenComputer {
|
|
175
|
+
constructor() {
|
|
176
|
+
this.TOKEN_RANDOM_SEQUENCE_LENGTH = 6;
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* Returns token.nonce == 0
|
|
180
|
+
*/
|
|
181
|
+
isFungible(token) {
|
|
182
|
+
return token.nonce === 0n;
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Given "FOO-abcdef-0a" returns 10.
|
|
186
|
+
*/
|
|
187
|
+
extractNonceFromExtendedIdentifier(identifier) {
|
|
188
|
+
const parts = identifier.split("-");
|
|
189
|
+
const { prefix, ticker, randomSequence } = this.splitIdentifierIntoComponents(parts);
|
|
190
|
+
this.validateExtendedIdentifier(prefix, ticker, randomSequence, parts);
|
|
191
|
+
// If identifier is for a fungible token (2 parts or 3 with prefix), return 0
|
|
192
|
+
if (parts.length === 2 || (prefix && parts.length === 3)) {
|
|
193
|
+
return 0;
|
|
194
|
+
}
|
|
195
|
+
// Otherwise, decode the last part as an unsigned number
|
|
196
|
+
const hexNonce = parts[parts.length - 1];
|
|
197
|
+
return decodeUnsignedNumber(Buffer.from(hexNonce, "hex"));
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* Given "FOO-abcdef-0a" returns FOO-abcdef.
|
|
201
|
+
*/
|
|
202
|
+
extractIdentifierFromExtendedIdentifier(identifier) {
|
|
203
|
+
const parts = identifier.split("-");
|
|
204
|
+
const { prefix, ticker, randomSequence } = this.splitIdentifierIntoComponents(parts);
|
|
205
|
+
this.validateExtendedIdentifier(prefix, ticker, randomSequence, parts);
|
|
206
|
+
if (prefix) {
|
|
207
|
+
this.checkLengthOfPrefix(prefix);
|
|
208
|
+
return prefix + "-" + ticker + "-" + randomSequence;
|
|
209
|
+
}
|
|
210
|
+
return ticker + "-" + randomSequence;
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* Given "FOO-abcdef-0a" returns FOO.
|
|
214
|
+
* Given "FOO-abcdef" returns FOO.
|
|
215
|
+
*/
|
|
216
|
+
extractTickerFromExtendedIdentifier(identifier) {
|
|
217
|
+
const parts = identifier.split("-");
|
|
218
|
+
const { prefix, ticker, randomSequence } = this.splitIdentifierIntoComponents(parts);
|
|
219
|
+
this.validateExtendedIdentifier(prefix, ticker, randomSequence, parts);
|
|
220
|
+
if (prefix) {
|
|
221
|
+
this.checkLengthOfPrefix(prefix);
|
|
222
|
+
return prefix + "-" + ticker + "-" + randomSequence;
|
|
223
|
+
}
|
|
224
|
+
return ticker;
|
|
225
|
+
}
|
|
226
|
+
computeExtendedIdentifier(token) {
|
|
227
|
+
const parts = token.identifier.split("-");
|
|
228
|
+
const { prefix, ticker, randomSequence } = this.splitIdentifierIntoComponents(parts);
|
|
229
|
+
this.validateExtendedIdentifier(prefix, ticker, randomSequence, parts);
|
|
230
|
+
if (token.nonce < 0) {
|
|
231
|
+
throw new Error("The token nonce can't be less than 0");
|
|
232
|
+
}
|
|
233
|
+
if (token.nonce === 0n) {
|
|
234
|
+
return token.identifier;
|
|
235
|
+
}
|
|
236
|
+
const nonceAsHex = utils_codec_1.numberToPaddedHex(token.nonce);
|
|
237
|
+
return `${token.identifier}-${nonceAsHex}`;
|
|
238
|
+
}
|
|
239
|
+
validateExtendedIdentifier(prefix, ticker, randomSequence, parts) {
|
|
240
|
+
this.checkIfExtendedIdentifierWasProvided(prefix, parts);
|
|
241
|
+
this.ensureTokenTickerValidity(ticker);
|
|
242
|
+
this.checkLengthOfRandomSequence(randomSequence);
|
|
243
|
+
}
|
|
244
|
+
splitIdentifierIntoComponents(parts) {
|
|
245
|
+
if (parts.length >= 3 && parts[2].length === this.TOKEN_RANDOM_SEQUENCE_LENGTH) {
|
|
246
|
+
return { prefix: parts[0], ticker: parts[1], randomSequence: parts[2] };
|
|
247
|
+
}
|
|
248
|
+
return { prefix: null, ticker: parts[0], randomSequence: parts[1] };
|
|
249
|
+
}
|
|
250
|
+
checkIfExtendedIdentifierWasProvided(prefix, tokenParts) {
|
|
251
|
+
// this is for the identifiers of fungible tokens
|
|
252
|
+
const MIN_EXTENDED_IDENTIFIER_LENGTH_IF_SPLITTED = 2;
|
|
253
|
+
// this is for the identifiers of nft, sft and meta-dcdt
|
|
254
|
+
const MAX_EXTENDED_IDENTIFIER_LENGTH_IF_SPLITTED = prefix ? 4 : 3;
|
|
255
|
+
if (tokenParts.length < MIN_EXTENDED_IDENTIFIER_LENGTH_IF_SPLITTED ||
|
|
256
|
+
tokenParts.length > MAX_EXTENDED_IDENTIFIER_LENGTH_IF_SPLITTED) {
|
|
257
|
+
throw new errors_1.ErrInvalidTokenIdentifier("Invalid extended token identifier provided");
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
checkLengthOfRandomSequence(randomSequence) {
|
|
261
|
+
if (randomSequence.length !== this.TOKEN_RANDOM_SEQUENCE_LENGTH) {
|
|
262
|
+
throw new errors_1.ErrInvalidTokenIdentifier("The identifier is not valid. The random sequence does not have the right length");
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
checkLengthOfPrefix(prefix) {
|
|
266
|
+
const MAX_TOKEN_PREFIX_LENGTH = 4;
|
|
267
|
+
const MIN_TOKEN_PREFIX_LENGTH = 1;
|
|
268
|
+
if (prefix.length < MIN_TOKEN_PREFIX_LENGTH || prefix.length > MAX_TOKEN_PREFIX_LENGTH) {
|
|
269
|
+
throw new errors_1.ErrInvalidTokenIdentifier("The identifier is not valid. The prefix does not have the right length");
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
ensureTokenTickerValidity(ticker) {
|
|
273
|
+
const MIN_TICKER_LENGTH = 3;
|
|
274
|
+
const MAX_TICKER_LENGTH = 10;
|
|
275
|
+
if (ticker.length < MIN_TICKER_LENGTH || ticker.length > MAX_TICKER_LENGTH) {
|
|
276
|
+
throw new errors_1.ErrInvalidTokenIdentifier(`The token ticker should be between ${MIN_TICKER_LENGTH} and ${MAX_TICKER_LENGTH} characters`);
|
|
277
|
+
}
|
|
278
|
+
if (!ticker.match(/^[a-zA-Z0-9]+$/)) {
|
|
279
|
+
throw new errors_1.ErrInvalidTokenIdentifier("The token ticker should only contain alphanumeric characters");
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
exports.TokenComputer = TokenComputer;
|
|
284
|
+
function decodeUnsignedNumber(arg) {
|
|
285
|
+
return arg.readUIntBE(0, arg.length);
|
|
286
|
+
}
|
|
287
|
+
//# sourceMappingURL=tokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.js","sourceRoot":"","sources":["../../src/core/tokens.ts"],"names":[],"mappings":";;;;;;AAAA,gEAAqC;AACrC,2CAAyE;AACzE,qCAAyE;AACzE,+CAAkD;AAElD,oBAAoB;AACpB,MAAM,mBAAmB,GAAG,MAAM,CAAC;AACnC,MAAM,eAAe,GAAG,EAAE,CAAC;AAE3B,wBAAwB;AACxB,mIAAmI;AACnI,sBAAS,CAAC,GAAG,CAAC,EAAE,aAAa,EAAE,CAAC,EAAE,CAAC,CAAC;AAWpC,MAAa,KAAK;IAOd,YAAY,OAA+C;QACvD,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;QACrC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,IAAI,EAAE,CAAC;IACrC,CAAC;CACJ;AAXD,sBAWC;AAED,MAAa,aAAa;IAyBtB,YAAY,OAAuE;QAC/E,IAAI,IAAI,CA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