pshenmic-dpp 1.1.2-dev.8 → 2.0.0-dev.2
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/README.md +14 -99
- package/dist/binaries/bindingsTypes.d.ts +1700 -0
- package/dist/binaries/bindingsTypes.js +99 -0
- package/dist/binaries/pshenmic_dpp.android.node/react-native-node-api-module +0 -0
- package/dist/binaries/pshenmic_dpp.android.node/x86_64/libpshenmic_dpp.so +0 -0
- package/dist/binaries/pshenmic_dpp.d.ts +166 -0
- package/dist/binaries/pshenmic_dpp.js +3 -0
- package/dist/binaries/wasm/wasmBytes.d.ts +2 -0
- package/dist/binaries/wasm/wasmBytes.js +2 -0
- package/dist/binaries/wasm.d.ts +166 -0
- package/dist/binaries/wasm.js +44 -0
- package/dist/src/dpp/constants.d.ts +4 -0
- package/dist/src/dpp/constants.js +19 -0
- package/dist/src/dpp/dpp.d.ts +110 -0
- package/dist/src/dpp/dpp.js +110 -0
- package/dist/src/dpp/enums.d.ts +1 -0
- package/dist/src/dpp/enums.js +1 -0
- package/dist/src/dpp/provider.d.ts +11 -0
- package/dist/src/dpp/provider.js +21 -0
- package/dist/src/dpp/structs/Address/AddressWitness.d.ts +12 -0
- package/dist/src/dpp/structs/Address/AddressWitness.js +23 -0
- package/dist/src/dpp/structs/Address/PlatformAddress.d.ts +14 -0
- package/dist/src/dpp/structs/Address/PlatformAddress.js +32 -0
- package/dist/src/dpp/structs/AddressTransitions/AddressCreditWithdrawalTransition.d.ts +38 -0
- package/dist/src/dpp/structs/AddressTransitions/AddressCreditWithdrawalTransition.js +95 -0
- package/dist/src/dpp/structs/AddressTransitions/AddressFundingFromAssetLockTransition.d.ts +35 -0
- package/dist/src/dpp/structs/AddressTransitions/AddressFundingFromAssetLockTransition.js +85 -0
- package/dist/src/dpp/structs/AddressTransitions/AddressFundsTransferTransition.d.ts +30 -0
- package/dist/src/dpp/structs/AddressTransitions/AddressFundsTransferTransition.js +72 -0
- package/dist/src/dpp/structs/AddressTransitions/IdentityCreateFromAddressesTransition.d.ts +33 -0
- package/dist/src/dpp/structs/AddressTransitions/IdentityCreateFromAddressesTransition.js +82 -0
- package/dist/src/dpp/structs/AddressTransitions/IdentityCreditTransferToAddressesTransition.d.ts +31 -0
- package/dist/src/dpp/structs/AddressTransitions/IdentityCreditTransferToAddressesTransition.js +77 -0
- package/dist/src/dpp/structs/AddressTransitions/IdentityTopUpFromAddressesTransition.d.ts +31 -0
- package/dist/src/dpp/structs/AddressTransitions/IdentityTopUpFromAddressesTransition.js +76 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/AddressFundsFeeStrategyStep.d.ts +12 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/AddressFundsFeeStrategyStep.js +26 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/InputAddress.d.ts +14 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/InputAddress.js +32 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/OutputAddress.d.ts +12 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/OutputAddress.js +26 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/OutputAddressNullableCredits.d.ts +12 -0
- package/dist/src/dpp/structs/AddressTransitions/entities/OutputAddressNullableCredits.js +29 -0
- package/dist/src/dpp/structs/AssetLockProof/AssetLockProof.d.ts +19 -0
- package/dist/src/dpp/structs/AssetLockProof/AssetLockProof.js +50 -0
- package/dist/src/dpp/structs/AssetLockProof/ChainAssetLockProof.d.ts +17 -0
- package/dist/src/dpp/structs/AssetLockProof/ChainAssetLockProof.js +36 -0
- package/dist/src/dpp/structs/AssetLockProof/InstantAssetLockProof.d.ts +24 -0
- package/dist/src/dpp/structs/AssetLockProof/InstantAssetLockProof.js +48 -0
- package/dist/src/dpp/structs/AssetLockProof/OutPoint.d.ts +15 -0
- package/dist/src/dpp/structs/AssetLockProof/OutPoint.js +40 -0
- package/dist/src/dpp/structs/AssetLockProof/Transaction.d.ts +20 -0
- package/dist/src/dpp/structs/AssetLockProof/Transaction.js +49 -0
- package/dist/src/dpp/structs/AssetLockProof/TxIn.d.ts +17 -0
- package/dist/src/dpp/structs/AssetLockProof/TxIn.js +39 -0
- package/dist/src/dpp/structs/AssetLockProof/TxOut.d.ts +13 -0
- package/dist/src/dpp/structs/AssetLockProof/TxOut.js +34 -0
- package/dist/src/dpp/structs/AssetLockProof/Witness.d.ts +11 -0
- package/dist/src/dpp/structs/AssetLockProof/Witness.js +25 -0
- package/dist/src/dpp/structs/Batch/BatchTransition.d.ts +34 -0
- package/dist/src/dpp/structs/Batch/BatchTransition.js +95 -0
- package/dist/src/dpp/structs/Batch/BatchedTransition.d.ts +14 -0
- package/dist/src/dpp/structs/Batch/BatchedTransition.js +39 -0
- package/dist/src/dpp/structs/Batch/DocumentBaseTransition.d.ts +20 -0
- package/dist/src/dpp/structs/Batch/DocumentBaseTransition.js +54 -0
- package/dist/src/dpp/structs/Batch/DocumentTransition.d.ts +32 -0
- package/dist/src/dpp/structs/Batch/DocumentTransition.js +74 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentCreateTransition.d.ts +23 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentCreateTransition.js +58 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentDeleteTransition.d.ts +14 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentDeleteTransition.js +26 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentPurchaseTransition.d.ts +19 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentPurchaseTransition.js +39 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentReplaceTransition.d.ts +19 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentReplaceTransition.js +40 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentTransferTransition.d.ts +19 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentTransferTransition.js +35 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentUpdatePriceTransition.d.ts +17 -0
- package/dist/src/dpp/structs/Batch/DocumentTransitions/DocumentUpdatePriceTransition.js +33 -0
- package/dist/src/dpp/structs/Batch/PrefundedVotingBalance.d.ts +9 -0
- package/dist/src/dpp/structs/Batch/PrefundedVotingBalance.js +19 -0
- package/dist/src/dpp/structs/Batch/TokenBaseTransition.d.ts +20 -0
- package/dist/src/dpp/structs/Batch/TokenBaseTransition.js +49 -0
- package/dist/src/dpp/structs/Batch/TokenPaymentInfo.d.ts +19 -0
- package/dist/src/dpp/structs/Batch/TokenPaymentInfo.js +54 -0
- package/dist/src/dpp/structs/Batch/TokenPricingSchedule.d.ts +17 -0
- package/dist/src/dpp/structs/Batch/TokenPricingSchedule.js +41 -0
- package/dist/src/dpp/structs/Batch/TokenTransition.d.ts +20 -0
- package/dist/src/dpp/structs/Batch/TokenTransition.js +92 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenBurnTransition.d.ts +14 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenBurnTransition.js +32 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenClaimTransition.d.ts +15 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenClaimTransition.js +33 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenConfigUpdateTransition.d.ts +15 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenConfigUpdateTransition.js +33 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenDestroyFrozenFundsTransition.d.ts +16 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenDestroyFrozenFundsTransition.js +34 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenDirectPurchaseTransition.d.ts +14 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenDirectPurchaseTransition.js +32 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenEmergencyActionTransition.d.ts +15 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenEmergencyActionTransition.js +33 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenFreezeTransition.d.ts +16 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenFreezeTransition.js +34 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenMintTransition.d.ts +18 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenMintTransition.js +43 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenSetPriceForDirectPurchaseTransition.d.ts +15 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenSetPriceForDirectPurchaseTransition.js +36 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenTransferTransition.d.ts +21 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenTransferTransition.js +53 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenUnFreezeTransition.d.ts +16 -0
- package/dist/src/dpp/structs/Batch/TokenTransitions/TokenUnFreezeTransition.js +34 -0
- package/dist/src/dpp/structs/ConsensusError.d.ts +8 -0
- package/dist/src/dpp/structs/ConsensusError.js +22 -0
- package/dist/src/dpp/structs/ContractBounds.d.ts +17 -0
- package/dist/src/dpp/structs/ContractBounds.js +39 -0
- package/dist/src/dpp/structs/CoreScript.d.ts +15 -0
- package/dist/src/dpp/structs/CoreScript.js +37 -0
- package/dist/src/dpp/structs/DataContract.d.ts +36 -0
- package/dist/src/dpp/structs/DataContract.js +119 -0
- package/dist/src/dpp/structs/DataContractTransitions/DataContractCreateTransition.d.ts +23 -0
- package/dist/src/dpp/structs/DataContractTransitions/DataContractCreateTransition.js +55 -0
- package/dist/src/dpp/structs/DataContractTransitions/DataContractUpdateTransition.d.ts +23 -0
- package/dist/src/dpp/structs/DataContractTransitions/DataContractUpdateTransition.js +55 -0
- package/dist/src/dpp/structs/Document.d.ts +51 -0
- package/dist/src/dpp/structs/Document.js +184 -0
- package/dist/src/dpp/structs/EncryptedNote/PrivateEncryptedNote.d.ts +13 -0
- package/dist/src/dpp/structs/EncryptedNote/PrivateEncryptedNote.js +31 -0
- package/dist/src/dpp/structs/EncryptedNote/SharedEncryptedNote.d.ts +13 -0
- package/dist/src/dpp/structs/EncryptedNote/SharedEncryptedNote.js +31 -0
- package/dist/src/dpp/structs/GroupStateTransitionInfo.d.ts +15 -0
- package/dist/src/dpp/structs/GroupStateTransitionInfo.js +33 -0
- package/dist/src/dpp/structs/Identifier.d.ts +17 -0
- package/dist/src/dpp/structs/Identifier.js +50 -0
- package/dist/src/dpp/structs/Identity.d.ts +26 -0
- package/dist/src/dpp/structs/Identity.js +73 -0
- package/dist/src/dpp/structs/IdentityPublicKey.d.ts +43 -0
- package/dist/src/dpp/structs/IdentityPublicKey.js +126 -0
- package/dist/src/dpp/structs/IdentityPublicKeyInCreation.d.ts +30 -0
- package/dist/src/dpp/structs/IdentityPublicKeyInCreation.js +77 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityCreateTransition.d.ts +29 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityCreateTransition.js +69 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityCreditTransfer.d.ts +33 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityCreditTransfer.js +85 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityCreditWithdrawalTransition.d.ts +42 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityCreditWithdrawalTransition.js +114 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityTopUpTransition.d.ts +30 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityTopUpTransition.js +75 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityUpdateTransition.d.ts +40 -0
- package/dist/src/dpp/structs/IdentityTransitions/IdentityUpdateTransition.js +108 -0
- package/dist/src/dpp/structs/InstantLock.d.ts +17 -0
- package/dist/src/dpp/structs/InstantLock.js +43 -0
- package/dist/src/dpp/structs/MasternodeVote/MasternodeVoteTransition.d.ts +37 -0
- package/dist/src/dpp/structs/MasternodeVote/MasternodeVoteTransition.js +96 -0
- package/dist/src/dpp/structs/MasternodeVote/ResourceVoteChoice.d.ts +14 -0
- package/dist/src/dpp/structs/MasternodeVote/ResourceVoteChoice.js +29 -0
- package/dist/src/dpp/structs/MasternodeVote/Vote.d.ts +13 -0
- package/dist/src/dpp/structs/MasternodeVote/Vote.js +27 -0
- package/dist/src/dpp/structs/MasternodeVote/VotePoll.d.ts +18 -0
- package/dist/src/dpp/structs/MasternodeVote/VotePoll.js +42 -0
- package/dist/src/dpp/structs/PartialIdentity.d.ts +26 -0
- package/dist/src/dpp/structs/PartialIdentity.js +69 -0
- package/dist/src/dpp/structs/PrivateKey.d.ts +20 -0
- package/dist/src/dpp/structs/PrivateKey.js +48 -0
- package/dist/src/dpp/structs/PublicKey.d.ts +15 -0
- package/dist/src/dpp/structs/PublicKey.js +37 -0
- package/dist/src/dpp/structs/StateTransition.d.ts +38 -0
- package/dist/src/dpp/structs/StateTransition.js +100 -0
- package/dist/src/dpp/structs/TokenConfiguration/ActionTaker.d.ts +12 -0
- package/dist/src/dpp/structs/TokenConfiguration/ActionTaker.js +44 -0
- package/dist/src/dpp/structs/TokenConfiguration/AuthorizedActionTakers.d.ts +16 -0
- package/dist/src/dpp/structs/TokenConfiguration/AuthorizedActionTakers.js +43 -0
- package/dist/src/dpp/structs/TokenConfiguration/ChangeControlRules.d.ts +23 -0
- package/dist/src/dpp/structs/TokenConfiguration/ChangeControlRules.js +52 -0
- package/dist/src/dpp/structs/TokenConfiguration/DistributionFunction.d.ts +19 -0
- package/dist/src/dpp/structs/TokenConfiguration/DistributionFunction.js +57 -0
- package/dist/src/dpp/structs/TokenConfiguration/Group.d.ts +19 -0
- package/dist/src/dpp/structs/TokenConfiguration/Group.js +44 -0
- package/dist/src/dpp/structs/TokenConfiguration/RewardDistributionType.d.ts +13 -0
- package/dist/src/dpp/structs/TokenConfiguration/RewardDistributionType.js +40 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfiguration.d.ts +54 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfiguration.js +139 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfigurationChangeItem.d.ts +47 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfigurationChangeItem.js +140 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfigurationConvention.d.ts +19 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfigurationConvention.js +47 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfigurationLocalization.d.ts +15 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenConfigurationLocalization.js +34 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenDistributionRecipient.d.ts +14 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenDistributionRecipient.js +31 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenDistributionRules.d.ts +28 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenDistributionRules.js +75 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenKeepsHistoryRules.d.ts +19 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenKeepsHistoryRules.js +49 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenMarketplaceRules.d.ts +13 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenMarketplaceRules.js +27 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenPerpetualDistribution.d.ts +13 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenPerpetualDistribution.js +27 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenPreProgrammedDistribution.d.ts +21 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenPreProgrammedDistribution.js +42 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenTradeMode.d.ts +9 -0
- package/dist/src/dpp/structs/TokenConfiguration/TokenTradeMode.js +17 -0
- package/dist/src/dpp/types.d.ts +273 -0
- package/dist/src/dpp/types.js +1 -0
- package/dist/src/dpp/utils.d.ts +5 -0
- package/dist/src/dpp/utils.js +78 -0
- package/dist/src/dpp/verify/Contested/verifyVotePollVoteStateProof.d.ts +3 -0
- package/dist/src/dpp/verify/Contested/verifyVotePollVoteStateProof.js +34 -0
- package/dist/src/dpp/verify/Contract/verifyContract.d.ts +2 -0
- package/dist/src/dpp/verify/Contract/verifyContract.js +14 -0
- package/dist/src/dpp/verify/Document/verifyDocumentsProof.d.ts +3 -0
- package/dist/src/dpp/verify/Document/verifyDocumentsProof.js +10 -0
- package/dist/src/dpp/verify/Identity/verifyIdentifierByNonUniquePublicKeyHashProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentifierByNonUniquePublicKeyHashProof.js +10 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityBalanceProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityBalanceProof.js +9 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityByIdentifierProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityByIdentifierProof.js +10 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityByUniqueKeyHashProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityByUniqueKeyHashProof.js +10 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityContractNonceProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityContractNonceProof.js +9 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityKeysByIdentifierProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityKeysByIdentifierProof.js +10 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityNonceProof.d.ts +2 -0
- package/dist/src/dpp/verify/Identity/verifyIdentityNonceProof.js +9 -0
- package/dist/src/dpp/verify/StateTransition/utils.d.ts +2 -0
- package/dist/src/dpp/verify/StateTransition/utils.js +115 -0
- package/dist/src/dpp/verify/StateTransition/verifyStateTransitionResult.d.ts +4 -0
- package/dist/src/dpp/verify/StateTransition/verifyStateTransitionResult.js +10 -0
- package/dist/src/dpp/verify/System/verifyEpochsInfoProof.d.ts +2 -0
- package/dist/src/dpp/verify/System/verifyEpochsInfoProof.js +16 -0
- package/dist/src/dpp/verify/System/verifyTotalCreditsProof.d.ts +2 -0
- package/dist/src/dpp/verify/System/verifyTotalCreditsProof.js +9 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenBalancesForIdentitiesProof.d.ts +2 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenBalancesForIdentitiesProof.js +13 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenContractInfoProof.d.ts +2 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenContractInfoProof.js +15 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenDirectPurchasePrices.d.ts +2 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenDirectPurchasePrices.js +14 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenTotalSupplyProof.d.ts +2 -0
- package/dist/src/dpp/verify/Tokens/verifyTokenTotalSupplyProof.js +12 -0
- package/dist/src/dpp/verify/Tokens/verifyTokensBalancesForIdentityProof.d.ts +2 -0
- package/dist/src/dpp/verify/Tokens/verifyTokensBalancesForIdentityProof.js +13 -0
- package/dist/src/dpp/verify/verifySignatureDigest.d.ts +1 -0
- package/dist/src/dpp/verify/verifySignatureDigest.js +4 -0
- package/dist/src/react-native.d.ts +3 -0
- package/dist/src/react-native.js +6 -0
- package/dist/src/wasm.d.ts +3 -0
- package/dist/src/wasm.js +6 -0
- package/dist/utils/base122.d.ts +7 -0
- package/dist/utils/base122.js +63 -0
- package/package.json +30 -27
- package/tests/unit/DynamicValue.spec.ts +86 -0
- package/tests/unit/Identifier.spec.ts +105 -0
- package/tests/unit/Identity.spec.ts +119 -0
- package/tests/unit/IdentityPublicKey.spec.ts +126 -0
- package/dist/wasm/base122.d.ts +0 -1
- package/dist/wasm/base122.js +0 -67
- package/dist/wasm/index.d.ts +0 -148
- package/dist/wasm/index.js +0 -13
- package/dist/wasm/initAsync.d.ts +0 -4
- package/dist/wasm/initAsync.js +0 -20
- package/dist/wasm/initInterface.d.ts +0 -3
- package/dist/wasm/initInterface.js +0 -46
- package/dist/wasm/initWASM.d.ts +0 -1
- package/dist/wasm/initWASM.js +0 -28
- package/dist/wasm/pshenmic_dpp.d.ts +0 -5266
- package/dist/wasm/pshenmic_dpp.js +0 -25608
- package/dist/wasm/pshenmic_dpp_bg.d.ts +0 -3
- package/dist/wasm/pshenmic_dpp_bg.js +0 -2
- package/dist/wasm/pshenmic_dpp_bg.wasm.d.ts +0 -1636
- package/dist/wasm/pshenmic_dpp_zipped.d.ts +0 -3
- package/dist/wasm/pshenmic_dpp_zipped.js +0 -2
- package/dist/wasm/snippets/pshenmic_dpp_utils-23ab7381b198778d/stringify.js +0 -7
- package/tests/AssetLockProof.spec.cjs +0 -96
- package/tests/AsyncImportTest.spec.cjs +0 -930
- package/tests/AuthorizedActionTakers.spec.cjs +0 -75
- package/tests/BatchTransition.spec.cjs +0 -141
- package/tests/ChainLockProof.spec.cjs +0 -63
- package/tests/ChangeControlRules.spec.cjs +0 -184
- package/tests/CoreScript.spec.cjs +0 -37
- package/tests/DataContract.spec.cjs +0 -170
- package/tests/DataContractCreateStateTransition.spec.cjs +0 -102
- package/tests/DataContractUpdateStateTransition.spec.cjs +0 -103
- package/tests/DistributionFunction.spec.cjs +0 -416
- package/tests/Document.spec.cjs +0 -227
- package/tests/DocumentTransition.spec.cjs +0 -94
- package/tests/DocumentsTransitions.spec.cjs +0 -699
- package/tests/Identifier.spec.cjs +0 -82
- package/tests/Identity.spec.cjs +0 -107
- package/tests/IdentityCreateTransition.spec.cjs +0 -87
- package/tests/IdentityCreditTransferTransition.spec.cjs +0 -140
- package/tests/IdentityCreditWithdrawalTransition.spec.cjs +0 -186
- package/tests/IdentityPublicKey.spec.cjs +0 -166
- package/tests/IdentityTopUpTransition.spec.cjs +0 -125
- package/tests/IdentityUpdateTransition.spec.cjs +0 -141
- package/tests/InstantLockProof.spec.cjs +0 -91
- package/tests/OutPoint.spec.cjs +0 -49
- package/tests/PrivateKey.spec.cjs +0 -67
- package/tests/PublicKeyInCreation.spec.cjs +0 -252
- package/tests/RewardDistributionType.spec.cjs +0 -90
- package/tests/TokenBaseTransition.spec.cjs +0 -96
- package/tests/TokenConfiguration.spec.cjs +0 -188
- package/tests/TokenConfigurationConvention.spec.cjs +0 -93
- package/tests/TokenConfigurationLocalization.spec.cjs +0 -59
- package/tests/TokenDistributionRecipient.spec.cjs +0 -49
- package/tests/TokenDistributionRules.spec.cjs +0 -313
- package/tests/TokenKeepsHistoryRules.spec.cjs +0 -67
- package/tests/TokenPerpetualDistribution.spec.cjs +0 -130
- package/tests/TokenPreProgrammedDistribution.spec.cjs +0 -61
- package/tests/TokensTransitions.spec.cjs +0 -509
- package/tests/TxOut.spec.cjs +0 -70
- package/tests/mocks/DataContract/DataContract.json +0 -164
- package/tests/mocks/DataContract/index.js +0 -6
- package/tests/mocks/Document/DataContract.json +0 -23
- package/tests/mocks/Document/document.json +0 -3
- package/tests/mocks/Document/document2.json +0 -3
- package/tests/mocks/Document/index.js +0 -13
- package/tests/mocks/Identity/index.js +0 -13
- package/tests/mocks/Locks/index.js +0 -2
- package/tests/mocks/PrivateKey/index.js +0 -5
- package/tests/mocks/PublicKey/index.js +0 -13
- package/tests/mocks/TokenConfiguration/index.js +0 -5
- package/tests/utils/hex.js +0 -14
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { TokenDestroyFrozenFundsTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { IdentifierLike } from '../../../types.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export declare class TokenDestroyFrozenFundsTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition: TokenDestroyFrozenFundsTransitionNAPI;
|
|
8
|
+
constructor(base: TokenBaseTransitionWASM, frozenIdentityId: IdentifierLike, publicNote?: string);
|
|
9
|
+
get base(): TokenBaseTransitionWASM;
|
|
10
|
+
set base(value: TokenBaseTransitionWASM);
|
|
11
|
+
get frozenIdentityId(): IdentifierWASM;
|
|
12
|
+
set frozenIdentityId(value: IdentifierLike);
|
|
13
|
+
get publicNote(): string | undefined;
|
|
14
|
+
set publicNote(value: string | undefined);
|
|
15
|
+
static createFromRawInstance(rawInstance: TokenDestroyFrozenFundsTransitionNAPI): TokenDestroyFrozenFundsTransitionWASM;
|
|
16
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { dppProvider } from '../../../provider.js';
|
|
3
|
+
import { prepareIdentifierValue } from '../../../utils.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export class TokenDestroyFrozenFundsTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition;
|
|
8
|
+
constructor(base, frozenIdentityId, publicNote) {
|
|
9
|
+
this._rawTransition = new dppProvider.dpp.TokenDestroyFrozenFundsTransitionNAPI(base._rawTokenBaseTransition, prepareIdentifierValue(frozenIdentityId), publicNote);
|
|
10
|
+
}
|
|
11
|
+
get base() {
|
|
12
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
13
|
+
}
|
|
14
|
+
set base(value) {
|
|
15
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
16
|
+
}
|
|
17
|
+
get frozenIdentityId() {
|
|
18
|
+
return IdentifierWASM.createFromRawInstance(this._rawTransition.frozenIdentityId);
|
|
19
|
+
}
|
|
20
|
+
set frozenIdentityId(value) {
|
|
21
|
+
this._rawTransition.frozenIdentityId = prepareIdentifierValue(value);
|
|
22
|
+
}
|
|
23
|
+
get publicNote() {
|
|
24
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
25
|
+
}
|
|
26
|
+
set publicNote(value) {
|
|
27
|
+
this._rawTransition.publicNote = value;
|
|
28
|
+
}
|
|
29
|
+
static createFromRawInstance(rawInstance) {
|
|
30
|
+
const instance = Object.create(this.prototype);
|
|
31
|
+
instance._rawTransition = rawInstance;
|
|
32
|
+
return instance;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { TokenDirectPurchaseTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
export declare class TokenDirectPurchaseTransitionWASM {
|
|
4
|
+
/** @private **/
|
|
5
|
+
_rawTransition: TokenDirectPurchaseTransitionNAPI;
|
|
6
|
+
constructor(base: TokenBaseTransitionWASM, tokenCount: bigint, totalAgreedPrice: bigint);
|
|
7
|
+
get base(): TokenBaseTransitionWASM;
|
|
8
|
+
set base(value: TokenBaseTransitionWASM);
|
|
9
|
+
get tokenCount(): bigint;
|
|
10
|
+
set tokenCount(value: bigint);
|
|
11
|
+
get totalAgreedPrice(): bigint;
|
|
12
|
+
set totalAgreedPrice(value: bigint);
|
|
13
|
+
static createFromRawInstance(rawInstance: TokenDirectPurchaseTransitionNAPI): TokenDirectPurchaseTransitionWASM;
|
|
14
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { dppProvider } from '../../../provider.js';
|
|
3
|
+
export class TokenDirectPurchaseTransitionWASM {
|
|
4
|
+
/** @private **/
|
|
5
|
+
_rawTransition;
|
|
6
|
+
constructor(base, tokenCount, totalAgreedPrice) {
|
|
7
|
+
this._rawTransition = new dppProvider.dpp.TokenDirectPurchaseTransitionNAPI(base._rawTokenBaseTransition, tokenCount.toString(), totalAgreedPrice.toString());
|
|
8
|
+
}
|
|
9
|
+
get base() {
|
|
10
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
11
|
+
}
|
|
12
|
+
set base(value) {
|
|
13
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
14
|
+
}
|
|
15
|
+
get tokenCount() {
|
|
16
|
+
return BigInt(this._rawTransition.tokenCount);
|
|
17
|
+
}
|
|
18
|
+
set tokenCount(value) {
|
|
19
|
+
this._rawTransition.tokenCount = value.toString();
|
|
20
|
+
}
|
|
21
|
+
get totalAgreedPrice() {
|
|
22
|
+
return BigInt(this._rawTransition.totalAgreedPrice);
|
|
23
|
+
}
|
|
24
|
+
set totalAgreedPrice(value) {
|
|
25
|
+
this._rawTransition.totalAgreedPrice = value.toString();
|
|
26
|
+
}
|
|
27
|
+
static createFromRawInstance(rawInstance) {
|
|
28
|
+
const instance = Object.create(this.prototype);
|
|
29
|
+
instance._rawTransition = rawInstance;
|
|
30
|
+
return instance;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { TokenEmergencyActionTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { TokenEmergencyActionLike } from '../../../types.js';
|
|
4
|
+
export declare class TokenEmergencyActionTransitionWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawTransition: TokenEmergencyActionTransitionNAPI;
|
|
7
|
+
constructor(base: TokenBaseTransitionWASM, emergencyAction: TokenEmergencyActionLike, publicNote?: string);
|
|
8
|
+
get base(): TokenBaseTransitionWASM;
|
|
9
|
+
set base(value: TokenBaseTransitionWASM);
|
|
10
|
+
get emergencyAction(): string;
|
|
11
|
+
set emergencyAction(value: TokenEmergencyActionLike);
|
|
12
|
+
get publicNote(): string | undefined;
|
|
13
|
+
set publicNote(value: string | undefined);
|
|
14
|
+
static createFromRawInstance(rawInstance: TokenEmergencyActionTransitionNAPI): TokenEmergencyActionTransitionWASM;
|
|
15
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { dppProvider } from '../../../provider.js';
|
|
3
|
+
import { valueToDynamicValue } from '../../../utils.js';
|
|
4
|
+
export class TokenEmergencyActionTransitionWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawTransition;
|
|
7
|
+
constructor(base, emergencyAction, publicNote) {
|
|
8
|
+
this._rawTransition = new dppProvider.dpp.TokenEmergencyActionTransitionNAPI(base._rawTokenBaseTransition, valueToDynamicValue(emergencyAction), publicNote);
|
|
9
|
+
}
|
|
10
|
+
get base() {
|
|
11
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
12
|
+
}
|
|
13
|
+
set base(value) {
|
|
14
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
15
|
+
}
|
|
16
|
+
get emergencyAction() {
|
|
17
|
+
return this._rawTransition.emergencyAction;
|
|
18
|
+
}
|
|
19
|
+
set emergencyAction(value) {
|
|
20
|
+
this._rawTransition.emergencyAction = valueToDynamicValue(value);
|
|
21
|
+
}
|
|
22
|
+
get publicNote() {
|
|
23
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
24
|
+
}
|
|
25
|
+
set publicNote(value) {
|
|
26
|
+
this._rawTransition.publicNote = value;
|
|
27
|
+
}
|
|
28
|
+
static createFromRawInstance(rawInstance) {
|
|
29
|
+
const instance = Object.create(this.prototype);
|
|
30
|
+
instance._rawTransition = rawInstance;
|
|
31
|
+
return instance;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { TokenFreezeTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { IdentifierLike } from '../../../types.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export declare class TokenFreezeTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition: TokenFreezeTransitionNAPI;
|
|
8
|
+
constructor(base: TokenBaseTransitionWASM, identityIdToFreeze: IdentifierLike, publicNote?: string);
|
|
9
|
+
get base(): TokenBaseTransitionWASM;
|
|
10
|
+
set base(value: TokenBaseTransitionWASM);
|
|
11
|
+
get frozenIdentityId(): IdentifierWASM;
|
|
12
|
+
set frozenIdentityId(value: IdentifierLike);
|
|
13
|
+
get publicNote(): string | undefined;
|
|
14
|
+
set publicNote(value: string | undefined);
|
|
15
|
+
static createFromRawInstance(rawInstance: TokenFreezeTransitionNAPI): TokenFreezeTransitionWASM;
|
|
16
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { dppProvider } from '../../../provider.js';
|
|
3
|
+
import { prepareIdentifierValue } from '../../../utils.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export class TokenFreezeTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition;
|
|
8
|
+
constructor(base, identityIdToFreeze, publicNote) {
|
|
9
|
+
this._rawTransition = new dppProvider.dpp.TokenFreezeTransitionNAPI(base._rawTokenBaseTransition, prepareIdentifierValue(identityIdToFreeze), publicNote);
|
|
10
|
+
}
|
|
11
|
+
get base() {
|
|
12
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
13
|
+
}
|
|
14
|
+
set base(value) {
|
|
15
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
16
|
+
}
|
|
17
|
+
get frozenIdentityId() {
|
|
18
|
+
return IdentifierWASM.createFromRawInstance(this._rawTransition.frozenIdentityId);
|
|
19
|
+
}
|
|
20
|
+
set frozenIdentityId(value) {
|
|
21
|
+
this._rawTransition.frozenIdentityId = prepareIdentifierValue(value);
|
|
22
|
+
}
|
|
23
|
+
get publicNote() {
|
|
24
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
25
|
+
}
|
|
26
|
+
set publicNote(value) {
|
|
27
|
+
this._rawTransition.publicNote = value;
|
|
28
|
+
}
|
|
29
|
+
static createFromRawInstance(rawInstance) {
|
|
30
|
+
const instance = Object.create(this.prototype);
|
|
31
|
+
instance._rawTransition = rawInstance;
|
|
32
|
+
return instance;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { TokenMintTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { IdentifierLike } from '../../../types.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export declare class TokenMintTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition: TokenMintTransitionNAPI;
|
|
8
|
+
constructor(base: TokenBaseTransitionWASM, issueToIdentityId: IdentifierLike | undefined, amount: bigint, publicNote?: string);
|
|
9
|
+
get base(): TokenBaseTransitionWASM;
|
|
10
|
+
set base(value: TokenBaseTransitionWASM);
|
|
11
|
+
get issuedToIdentityId(): IdentifierWASM | undefined;
|
|
12
|
+
set issuedToIdentityId(value: IdentifierLike | undefined);
|
|
13
|
+
get amount(): bigint;
|
|
14
|
+
set amount(value: bigint);
|
|
15
|
+
get publicNote(): string | undefined;
|
|
16
|
+
set publicNote(value: string | undefined);
|
|
17
|
+
static createFromRawInstance(rawInstance: TokenMintTransitionNAPI): TokenMintTransitionWASM;
|
|
18
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { dppProvider } from '../../../provider.js';
|
|
3
|
+
import { prepareIdentifierValue } from '../../../utils.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export class TokenMintTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition;
|
|
8
|
+
constructor(base, issueToIdentityId, amount, publicNote) {
|
|
9
|
+
this._rawTransition = new dppProvider.dpp.TokenMintTransitionNAPI(base._rawTokenBaseTransition, issueToIdentityId != null ? prepareIdentifierValue(issueToIdentityId) : undefined, amount.toString(), publicNote);
|
|
10
|
+
}
|
|
11
|
+
get base() {
|
|
12
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
13
|
+
}
|
|
14
|
+
set base(value) {
|
|
15
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
16
|
+
}
|
|
17
|
+
get issuedToIdentityId() {
|
|
18
|
+
const id = this._rawTransition.issuedToIdentityId;
|
|
19
|
+
if (id != null) {
|
|
20
|
+
return IdentifierWASM.createFromRawInstance(id);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
set issuedToIdentityId(value) {
|
|
24
|
+
this._rawTransition.issuedToIdentityId = value != null ? prepareIdentifierValue(value) : undefined;
|
|
25
|
+
}
|
|
26
|
+
get amount() {
|
|
27
|
+
return BigInt(this._rawTransition.amount);
|
|
28
|
+
}
|
|
29
|
+
set amount(value) {
|
|
30
|
+
this._rawTransition.amount = value.toString();
|
|
31
|
+
}
|
|
32
|
+
get publicNote() {
|
|
33
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
34
|
+
}
|
|
35
|
+
set publicNote(value) {
|
|
36
|
+
this._rawTransition.publicNote = value;
|
|
37
|
+
}
|
|
38
|
+
static createFromRawInstance(rawInstance) {
|
|
39
|
+
const instance = Object.create(this.prototype);
|
|
40
|
+
instance._rawTransition = rawInstance;
|
|
41
|
+
return instance;
|
|
42
|
+
}
|
|
43
|
+
}
|
package/dist/src/dpp/structs/Batch/TokenTransitions/TokenSetPriceForDirectPurchaseTransition.d.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { TokenSetPriceForDirectPurchaseTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { TokenPricingScheduleWASM } from '../TokenPricingSchedule.js';
|
|
4
|
+
export declare class TokenSetPriceForDirectPurchaseTransitionWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawTransition: TokenSetPriceForDirectPurchaseTransitionNAPI;
|
|
7
|
+
constructor(base: TokenBaseTransitionWASM, prices?: TokenPricingScheduleWASM, publicNote?: string);
|
|
8
|
+
get base(): TokenBaseTransitionWASM;
|
|
9
|
+
set base(value: TokenBaseTransitionWASM);
|
|
10
|
+
get price(): TokenPricingScheduleWASM | undefined;
|
|
11
|
+
set price(value: TokenPricingScheduleWASM | undefined);
|
|
12
|
+
get publicNote(): string | undefined;
|
|
13
|
+
set publicNote(value: string | undefined);
|
|
14
|
+
static createFromRawInstance(rawInstance: TokenSetPriceForDirectPurchaseTransitionNAPI): TokenSetPriceForDirectPurchaseTransitionWASM;
|
|
15
|
+
}
|
package/dist/src/dpp/structs/Batch/TokenTransitions/TokenSetPriceForDirectPurchaseTransition.js
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { TokenPricingScheduleWASM } from '../TokenPricingSchedule.js';
|
|
3
|
+
import { dppProvider } from '../../../provider.js';
|
|
4
|
+
export class TokenSetPriceForDirectPurchaseTransitionWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawTransition;
|
|
7
|
+
constructor(base, prices, publicNote) {
|
|
8
|
+
this._rawTransition = new dppProvider.dpp.TokenSetPriceForDirectPurchaseTransitionNAPI(base._rawTokenBaseTransition, prices?._rawTokenPricingSchedule, publicNote);
|
|
9
|
+
}
|
|
10
|
+
get base() {
|
|
11
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
12
|
+
}
|
|
13
|
+
set base(value) {
|
|
14
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
15
|
+
}
|
|
16
|
+
get price() {
|
|
17
|
+
const price = this._rawTransition.price;
|
|
18
|
+
if (price != null) {
|
|
19
|
+
return TokenPricingScheduleWASM.createFromRawInstance(price);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
set price(value) {
|
|
23
|
+
this._rawTransition.price = value?._rawTokenPricingSchedule;
|
|
24
|
+
}
|
|
25
|
+
get publicNote() {
|
|
26
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
27
|
+
}
|
|
28
|
+
set publicNote(value) {
|
|
29
|
+
this._rawTransition.publicNote = value;
|
|
30
|
+
}
|
|
31
|
+
static createFromRawInstance(rawInstance) {
|
|
32
|
+
const instance = Object.create(this.prototype);
|
|
33
|
+
instance._rawTransition = rawInstance;
|
|
34
|
+
return instance;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { TokenTransferTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { IdentifierLike } from '../../../types.js';
|
|
4
|
+
import { SharedEncryptedNoteWASM } from '../../EncryptedNote/SharedEncryptedNote.js';
|
|
5
|
+
import { PrivateEncryptedNoteWASM } from '../../EncryptedNote/PrivateEncryptedNote.js';
|
|
6
|
+
export declare class TokenTransferTransitionWASM {
|
|
7
|
+
/** @private **/
|
|
8
|
+
_rawTransition: TokenTransferTransitionNAPI;
|
|
9
|
+
constructor(base: TokenBaseTransitionWASM, recipientId: IdentifierLike, amount: bigint, publicNote?: string, sharedEncryptedNote?: SharedEncryptedNoteWASM, privateEncryptedNote?: PrivateEncryptedNoteWASM);
|
|
10
|
+
get base(): TokenBaseTransitionWASM;
|
|
11
|
+
set base(value: TokenBaseTransitionWASM);
|
|
12
|
+
get amount(): bigint;
|
|
13
|
+
set amount(value: bigint);
|
|
14
|
+
get publicNote(): string | undefined;
|
|
15
|
+
set publicNote(value: string | undefined);
|
|
16
|
+
get sharedEncryptedNote(): SharedEncryptedNoteWASM | undefined;
|
|
17
|
+
set sharedEncryptedNote(value: SharedEncryptedNoteWASM | undefined);
|
|
18
|
+
get privateEncryptedNote(): PrivateEncryptedNoteWASM | undefined;
|
|
19
|
+
set privateEncryptedNote(value: PrivateEncryptedNoteWASM | undefined);
|
|
20
|
+
static createFromRawInstance(rawInstance: TokenTransferTransitionNAPI): TokenTransferTransitionWASM;
|
|
21
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { SharedEncryptedNoteWASM } from '../../EncryptedNote/SharedEncryptedNote.js';
|
|
3
|
+
import { PrivateEncryptedNoteWASM } from '../../EncryptedNote/PrivateEncryptedNote.js';
|
|
4
|
+
import { dppProvider } from '../../../provider.js';
|
|
5
|
+
import { prepareIdentifierValue } from '../../../utils.js';
|
|
6
|
+
export class TokenTransferTransitionWASM {
|
|
7
|
+
/** @private **/
|
|
8
|
+
_rawTransition;
|
|
9
|
+
constructor(base, recipientId, amount, publicNote, sharedEncryptedNote, privateEncryptedNote) {
|
|
10
|
+
this._rawTransition = new dppProvider.dpp.TokenTransferTransitionNAPI(base._rawTokenBaseTransition, prepareIdentifierValue(recipientId), amount.toString(), publicNote, sharedEncryptedNote?._rawSharedNote, privateEncryptedNote?._rawEncryptedNote);
|
|
11
|
+
}
|
|
12
|
+
get base() {
|
|
13
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
14
|
+
}
|
|
15
|
+
set base(value) {
|
|
16
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
17
|
+
}
|
|
18
|
+
get amount() {
|
|
19
|
+
return BigInt(this._rawTransition.amount);
|
|
20
|
+
}
|
|
21
|
+
set amount(value) {
|
|
22
|
+
this._rawTransition.amount = value.toString();
|
|
23
|
+
}
|
|
24
|
+
get publicNote() {
|
|
25
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
26
|
+
}
|
|
27
|
+
set publicNote(value) {
|
|
28
|
+
this._rawTransition.publicNote = value;
|
|
29
|
+
}
|
|
30
|
+
get sharedEncryptedNote() {
|
|
31
|
+
const note = this._rawTransition.sharedEncryptedNote;
|
|
32
|
+
if (note != null) {
|
|
33
|
+
return SharedEncryptedNoteWASM.createFromRawInstance(note);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
set sharedEncryptedNote(value) {
|
|
37
|
+
this._rawTransition.sharedEncryptedNote = value?._rawSharedNote;
|
|
38
|
+
}
|
|
39
|
+
get privateEncryptedNote() {
|
|
40
|
+
const note = this._rawTransition.privateEncryptedNote;
|
|
41
|
+
if (note != null) {
|
|
42
|
+
return PrivateEncryptedNoteWASM.createFromRawInstance(note);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
set privateEncryptedNote(value) {
|
|
46
|
+
this._rawTransition.privateEncryptedNote = value?._rawEncryptedNote;
|
|
47
|
+
}
|
|
48
|
+
static createFromRawInstance(rawInstance) {
|
|
49
|
+
const instance = Object.create(this.prototype);
|
|
50
|
+
instance._rawTransition = rawInstance;
|
|
51
|
+
return instance;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { TokenUnFreezeTransitionNAPI } from '../../../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
3
|
+
import { IdentifierLike } from '../../../types.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export declare class TokenUnFreezeTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition: TokenUnFreezeTransitionNAPI;
|
|
8
|
+
constructor(base: TokenBaseTransitionWASM, frozenIdentityId: IdentifierLike, publicNote?: string);
|
|
9
|
+
get base(): TokenBaseTransitionWASM;
|
|
10
|
+
set base(value: TokenBaseTransitionWASM);
|
|
11
|
+
get frozenIdentityId(): IdentifierWASM;
|
|
12
|
+
set frozenIdentityId(value: IdentifierLike);
|
|
13
|
+
get publicNote(): string | undefined;
|
|
14
|
+
set publicNote(value: string | undefined);
|
|
15
|
+
static createFromRawInstance(rawInstance: TokenUnFreezeTransitionNAPI): TokenUnFreezeTransitionWASM;
|
|
16
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { TokenBaseTransitionWASM } from '../TokenBaseTransition.js';
|
|
2
|
+
import { dppProvider } from '../../../provider.js';
|
|
3
|
+
import { prepareIdentifierValue } from '../../../utils.js';
|
|
4
|
+
import { IdentifierWASM } from '../../Identifier.js';
|
|
5
|
+
export class TokenUnFreezeTransitionWASM {
|
|
6
|
+
/** @private **/
|
|
7
|
+
_rawTransition;
|
|
8
|
+
constructor(base, frozenIdentityId, publicNote) {
|
|
9
|
+
this._rawTransition = new dppProvider.dpp.TokenUnFreezeTransitionNAPI(base._rawTokenBaseTransition, prepareIdentifierValue(frozenIdentityId), publicNote);
|
|
10
|
+
}
|
|
11
|
+
get base() {
|
|
12
|
+
return TokenBaseTransitionWASM.createFromRawInstance(this._rawTransition.base);
|
|
13
|
+
}
|
|
14
|
+
set base(value) {
|
|
15
|
+
this._rawTransition.base = value._rawTokenBaseTransition;
|
|
16
|
+
}
|
|
17
|
+
get frozenIdentityId() {
|
|
18
|
+
return IdentifierWASM.createFromRawInstance(this._rawTransition.frozenIdentityId);
|
|
19
|
+
}
|
|
20
|
+
set frozenIdentityId(value) {
|
|
21
|
+
this._rawTransition.frozenIdentityId = prepareIdentifierValue(value);
|
|
22
|
+
}
|
|
23
|
+
get publicNote() {
|
|
24
|
+
return this._rawTransition.publicNote ?? undefined;
|
|
25
|
+
}
|
|
26
|
+
set publicNote(value) {
|
|
27
|
+
this._rawTransition.publicNote = value;
|
|
28
|
+
}
|
|
29
|
+
static createFromRawInstance(rawInstance) {
|
|
30
|
+
const instance = Object.create(this.prototype);
|
|
31
|
+
instance._rawTransition = rawInstance;
|
|
32
|
+
return instance;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ConsensusErrorNAPI } from '../../../binaries/bindingsTypes.js';
|
|
2
|
+
export declare class ConsensusErrorWASM {
|
|
3
|
+
/** @private **/
|
|
4
|
+
_rawConsensusError: ConsensusErrorNAPI;
|
|
5
|
+
private constructor();
|
|
6
|
+
static deserialize(error: Uint8Array): ConsensusErrorWASM;
|
|
7
|
+
get message(): string;
|
|
8
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { dppProvider } from '../provider.js';
|
|
2
|
+
export class ConsensusErrorWASM {
|
|
3
|
+
/** @private **/
|
|
4
|
+
_rawConsensusError;
|
|
5
|
+
constructor(rawData) {
|
|
6
|
+
if (rawData instanceof dppProvider.dpp.ConsensusErrorNAPI) {
|
|
7
|
+
this._rawConsensusError = rawData;
|
|
8
|
+
}
|
|
9
|
+
else if (rawData instanceof ConsensusErrorWASM) {
|
|
10
|
+
this._rawConsensusError = rawData._rawConsensusError;
|
|
11
|
+
}
|
|
12
|
+
else {
|
|
13
|
+
this._rawConsensusError = dppProvider.dpp.ConsensusErrorNAPI.deserialize(rawData);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
static deserialize(error) {
|
|
17
|
+
return new ConsensusErrorWASM(dppProvider.dpp.ConsensusErrorNAPI.deserialize(error));
|
|
18
|
+
}
|
|
19
|
+
get message() {
|
|
20
|
+
return this._rawConsensusError.message;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { ContractBoundsNAPI } from '../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { IdentifierLike } from '../types.js';
|
|
3
|
+
import { IdentifierWASM } from './Identifier.js';
|
|
4
|
+
export declare class ContractBoundsWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawContractBounds: ContractBoundsNAPI;
|
|
7
|
+
constructor(contractId: IdentifierLike, documentTypeName?: string);
|
|
8
|
+
get identifier(): IdentifierWASM;
|
|
9
|
+
set identifier(value: IdentifierLike);
|
|
10
|
+
get documentTypeName(): string | null;
|
|
11
|
+
set documentTypeName(value: string);
|
|
12
|
+
get contractBoundsType(): string;
|
|
13
|
+
get contractBoundsTypeNumber(): number;
|
|
14
|
+
static SingleContract(contractId: IdentifierLike): ContractBoundsWASM;
|
|
15
|
+
static SingleContractDocumentType(contractId: IdentifierLike, documentTypeName: string): ContractBoundsWASM;
|
|
16
|
+
static createFromRawInstance(rawInstance: ContractBoundsNAPI): ContractBoundsWASM;
|
|
17
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { dppProvider } from '../provider.js';
|
|
2
|
+
import { prepareIdentifierValue } from '../utils.js';
|
|
3
|
+
import { IdentifierWASM } from './Identifier.js';
|
|
4
|
+
export class ContractBoundsWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawContractBounds;
|
|
7
|
+
constructor(contractId, documentTypeName) {
|
|
8
|
+
this._rawContractBounds = new dppProvider.dpp.ContractBoundsNAPI(prepareIdentifierValue(contractId), documentTypeName);
|
|
9
|
+
}
|
|
10
|
+
get identifier() {
|
|
11
|
+
return IdentifierWASM.createFromRawInstance(this._rawContractBounds.identifier);
|
|
12
|
+
}
|
|
13
|
+
set identifier(value) {
|
|
14
|
+
this._rawContractBounds.identifier = prepareIdentifierValue(value);
|
|
15
|
+
}
|
|
16
|
+
get documentTypeName() {
|
|
17
|
+
return this._rawContractBounds.documentTypeName;
|
|
18
|
+
}
|
|
19
|
+
set documentTypeName(value) {
|
|
20
|
+
this._rawContractBounds.documentTypeName = value;
|
|
21
|
+
}
|
|
22
|
+
get contractBoundsType() {
|
|
23
|
+
return this._rawContractBounds.contractBoundsType;
|
|
24
|
+
}
|
|
25
|
+
get contractBoundsTypeNumber() {
|
|
26
|
+
return this._rawContractBounds.contractBoundsTypeNumber;
|
|
27
|
+
}
|
|
28
|
+
static SingleContract(contractId) {
|
|
29
|
+
return new ContractBoundsWASM(contractId);
|
|
30
|
+
}
|
|
31
|
+
static SingleContractDocumentType(contractId, documentTypeName) {
|
|
32
|
+
return new ContractBoundsWASM(contractId, documentTypeName);
|
|
33
|
+
}
|
|
34
|
+
static createFromRawInstance(rawInstance) {
|
|
35
|
+
const instance = Object.create(this.prototype);
|
|
36
|
+
instance._rawContractBounds = rawInstance;
|
|
37
|
+
return instance;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { CoreScriptNAPI } from '../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { NetworkLike } from '../types.js';
|
|
3
|
+
export declare class CoreScriptWASM {
|
|
4
|
+
_rawCoreScript: CoreScriptNAPI;
|
|
5
|
+
toAddress(network: NetworkLike): string;
|
|
6
|
+
toString(): string;
|
|
7
|
+
bytes(): Uint8Array;
|
|
8
|
+
hex(): string;
|
|
9
|
+
base64(): string;
|
|
10
|
+
ASMString(): string;
|
|
11
|
+
static fromBytes(bytes: Uint8Array): CoreScriptWASM;
|
|
12
|
+
static newP2PKH(keyHash: Uint8Array): CoreScriptWASM;
|
|
13
|
+
static newP2SH(scriptHash: Uint8Array): CoreScriptWASM;
|
|
14
|
+
static createFromRawInstance(rawInstance: CoreScriptNAPI): CoreScriptWASM;
|
|
15
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { dppProvider } from '../provider.js';
|
|
2
|
+
import { valueToDynamicValue } from '../utils.js';
|
|
3
|
+
export class CoreScriptWASM {
|
|
4
|
+
_rawCoreScript;
|
|
5
|
+
toAddress(network) {
|
|
6
|
+
return this._rawCoreScript.toAddress(valueToDynamicValue(network));
|
|
7
|
+
}
|
|
8
|
+
toString() {
|
|
9
|
+
return this._rawCoreScript.toString();
|
|
10
|
+
}
|
|
11
|
+
bytes() {
|
|
12
|
+
return this._rawCoreScript.bytes();
|
|
13
|
+
}
|
|
14
|
+
hex() {
|
|
15
|
+
return this._rawCoreScript.hex();
|
|
16
|
+
}
|
|
17
|
+
base64() {
|
|
18
|
+
return this._rawCoreScript.base64();
|
|
19
|
+
}
|
|
20
|
+
ASMString() {
|
|
21
|
+
return this._rawCoreScript.ASMString();
|
|
22
|
+
}
|
|
23
|
+
static fromBytes(bytes) {
|
|
24
|
+
return CoreScriptWASM.createFromRawInstance(dppProvider.dpp.CoreScriptNAPI.fromBytes(bytes));
|
|
25
|
+
}
|
|
26
|
+
static newP2PKH(keyHash) {
|
|
27
|
+
return CoreScriptWASM.createFromRawInstance(dppProvider.dpp.CoreScriptNAPI.newP2PKH(keyHash));
|
|
28
|
+
}
|
|
29
|
+
static newP2SH(scriptHash) {
|
|
30
|
+
return CoreScriptWASM.createFromRawInstance(dppProvider.dpp.CoreScriptNAPI.newP2SH(scriptHash));
|
|
31
|
+
}
|
|
32
|
+
static createFromRawInstance(rawInstance) {
|
|
33
|
+
const instance = Object.create(this.prototype);
|
|
34
|
+
instance._rawCoreScript = rawInstance;
|
|
35
|
+
return instance;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type { DataContractNAPI } from '../../../binaries/bindingsTypes.js';
|
|
2
|
+
import { DataContractGroups, DataContractTokens, IdentifierLike, PlatformVersionLike } from '../types.js';
|
|
3
|
+
import { IdentifierWASM } from './Identifier.js';
|
|
4
|
+
export declare class DataContractWASM {
|
|
5
|
+
/** @private **/
|
|
6
|
+
_rawDataContract: DataContractNAPI;
|
|
7
|
+
constructor(ownerId: IdentifierLike, identityNonce: bigint, schema?: object, definitions?: object, tokens?: DataContractTokens[], fullValidation?: boolean, platformVersion?: PlatformVersionLike);
|
|
8
|
+
get systemVersion(): number;
|
|
9
|
+
set systemVersion(value: number);
|
|
10
|
+
get version(): number;
|
|
11
|
+
set version(value: number);
|
|
12
|
+
get id(): IdentifierWASM;
|
|
13
|
+
set id(value: IdentifierLike);
|
|
14
|
+
get tokens(): DataContractTokens[];
|
|
15
|
+
set tokens(tokens: DataContractTokens[]);
|
|
16
|
+
get groups(): DataContractGroups[];
|
|
17
|
+
set groups(groups: DataContractGroups[]);
|
|
18
|
+
get description(): string | undefined;
|
|
19
|
+
set description(value: string | undefined);
|
|
20
|
+
get keywords(): string[];
|
|
21
|
+
set keywords(value: string[]);
|
|
22
|
+
getSchemas(): object;
|
|
23
|
+
getConfig(): object;
|
|
24
|
+
setConfig(value: object, platformVersion?: PlatformVersionLike): void;
|
|
25
|
+
bytes(platformVersion: PlatformVersionLike): Uint8Array;
|
|
26
|
+
hex(platformVersion: PlatformVersionLike): string;
|
|
27
|
+
base64(platformVersion: PlatformVersionLike): string;
|
|
28
|
+
toJSON(platformVersion: PlatformVersionLike): object;
|
|
29
|
+
toValue(platformVersion: PlatformVersionLike): object;
|
|
30
|
+
static fromValue(value: object, fullValidation: boolean, platformVersion?: PlatformVersionLike): DataContractWASM;
|
|
31
|
+
static fromBytes(bytes: Uint8Array, fullValidation: boolean, platformVersion?: PlatformVersionLike): DataContractWASM;
|
|
32
|
+
static fromHex(hex: string, fullValidation: boolean, platformVersion?: PlatformVersionLike): DataContractWASM;
|
|
33
|
+
static fromBase64(base64: string, fullValidation: boolean, platformVersion?: PlatformVersionLike): DataContractWASM;
|
|
34
|
+
static generateId(ownerId: IdentifierLike, identityNonce: bigint): IdentifierWASM;
|
|
35
|
+
static createFromRawInstance(rawInstance: DataContractNAPI): DataContractWASM;
|
|
36
|
+
}
|