@hiero-ledger/sdk 2.70.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 +190 -0
- package/README.md +167 -0
- package/dist/umd.js +98781 -0
- package/dist/umd.min.js +122 -0
- package/lib/BadEntityIdError.cjs +27 -0
- package/lib/BadEntityIdError.d.ts +15 -0
- package/lib/BadEntityIdError.js +2 -0
- package/lib/BadEntityIdError.js.map +1 -0
- package/lib/Cache.cjs +376 -0
- package/lib/Cache.d.ts +228 -0
- package/lib/Cache.js +2 -0
- package/lib/Cache.js.map +1 -0
- package/lib/Duration.cjs +53 -0
- package/lib/Duration.d.ts +37 -0
- package/lib/Duration.js +2 -0
- package/lib/Duration.js.map +1 -0
- package/lib/EntityIdHelper.cjs +547 -0
- package/lib/EntityIdHelper.d.ts +203 -0
- package/lib/EntityIdHelper.js +2 -0
- package/lib/EntityIdHelper.js.map +1 -0
- package/lib/EthereumFlow.cjs +207 -0
- package/lib/EthereumFlow.d.ts +134 -0
- package/lib/EthereumFlow.js +2 -0
- package/lib/EthereumFlow.js.map +1 -0
- package/lib/EthereumTransaction.cjs +260 -0
- package/lib/EthereumTransaction.d.ts +161 -0
- package/lib/EthereumTransaction.js +2 -0
- package/lib/EthereumTransaction.js.map +1 -0
- package/lib/EthereumTransactionData.cjs +66 -0
- package/lib/EthereumTransactionData.d.ts +33 -0
- package/lib/EthereumTransactionData.js +2 -0
- package/lib/EthereumTransactionData.js.map +1 -0
- package/lib/EthereumTransactionDataEip1559.cjs +134 -0
- package/lib/EthereumTransactionDataEip1559.d.ts +64 -0
- package/lib/EthereumTransactionDataEip1559.js +2 -0
- package/lib/EthereumTransactionDataEip1559.js.map +1 -0
- package/lib/EthereumTransactionDataEip2930.cjs +129 -0
- package/lib/EthereumTransactionDataEip2930.d.ts +60 -0
- package/lib/EthereumTransactionDataEip2930.js +2 -0
- package/lib/EthereumTransactionDataEip2930.js.map +1 -0
- package/lib/EthereumTransactionDataLegacy.cjs +112 -0
- package/lib/EthereumTransactionDataLegacy.d.ts +52 -0
- package/lib/EthereumTransactionDataLegacy.js +2 -0
- package/lib/EthereumTransactionDataLegacy.js.map +1 -0
- package/lib/EvmAddress.cjs +84 -0
- package/lib/EvmAddress.d.ts +47 -0
- package/lib/EvmAddress.js +2 -0
- package/lib/EvmAddress.js.map +1 -0
- package/lib/ExchangeRate.cjs +113 -0
- package/lib/ExchangeRate.d.ts +75 -0
- package/lib/ExchangeRate.js +2 -0
- package/lib/ExchangeRate.js.map +1 -0
- package/lib/ExchangeRates.cjs +75 -0
- package/lib/ExchangeRates.d.ts +39 -0
- package/lib/ExchangeRates.js +2 -0
- package/lib/ExchangeRates.js.map +1 -0
- package/lib/Executable.cjs +760 -0
- package/lib/Executable.d.ts +365 -0
- package/lib/Executable.js +2 -0
- package/lib/Executable.js.map +1 -0
- package/lib/FeeComponents.cjs +170 -0
- package/lib/FeeComponents.d.ts +66 -0
- package/lib/FeeComponents.js +2 -0
- package/lib/FeeComponents.js.map +1 -0
- package/lib/FeeData.cjs +111 -0
- package/lib/FeeData.d.ts +58 -0
- package/lib/FeeData.js +2 -0
- package/lib/FeeData.js.map +1 -0
- package/lib/FeeDataType.cjs +128 -0
- package/lib/FeeDataType.d.ts +44 -0
- package/lib/FeeDataType.js +2 -0
- package/lib/FeeDataType.js.map +1 -0
- package/lib/FeeSchedule.cjs +79 -0
- package/lib/FeeSchedule.d.ts +40 -0
- package/lib/FeeSchedule.js +2 -0
- package/lib/FeeSchedule.js.map +1 -0
- package/lib/FeeSchedules.cjs +79 -0
- package/lib/FeeSchedules.d.ts +40 -0
- package/lib/FeeSchedules.js +2 -0
- package/lib/FeeSchedules.js.map +1 -0
- package/lib/FreezeType.cjs +117 -0
- package/lib/FreezeType.d.ts +42 -0
- package/lib/FreezeType.js +2 -0
- package/lib/FreezeType.js.map +1 -0
- package/lib/Hbar.cjs +139 -0
- package/lib/Hbar.d.ts +62 -0
- package/lib/Hbar.js +2 -0
- package/lib/Hbar.js.map +1 -0
- package/lib/HbarUnit.cjs +77 -0
- package/lib/HbarUnit.d.ts +46 -0
- package/lib/HbarUnit.js +2 -0
- package/lib/HbarUnit.js.map +1 -0
- package/lib/Key.cjs +62 -0
- package/lib/Key.d.ts +23 -0
- package/lib/Key.js +2 -0
- package/lib/Key.js.map +1 -0
- package/lib/KeyList.cjs +181 -0
- package/lib/KeyList.d.ts +87 -0
- package/lib/KeyList.js +2 -0
- package/lib/KeyList.js.map +1 -0
- package/lib/LedgerId.cjs +137 -0
- package/lib/LedgerId.d.ts +64 -0
- package/lib/LedgerId.js +2 -0
- package/lib/LedgerId.js.map +1 -0
- package/lib/LocalProvider.cjs +159 -0
- package/lib/LocalProvider.d.ts +120 -0
- package/lib/LocalProvider.js +2 -0
- package/lib/LocalProvider.js.map +1 -0
- package/lib/ManagedNode.cjs +245 -0
- package/lib/ManagedNode.d.ts +127 -0
- package/lib/ManagedNode.js +2 -0
- package/lib/ManagedNode.js.map +1 -0
- package/lib/ManagedNodeAddress.cjs +104 -0
- package/lib/ManagedNodeAddress.d.ts +51 -0
- package/lib/ManagedNodeAddress.js +2 -0
- package/lib/ManagedNodeAddress.js.map +1 -0
- package/lib/MaxAttemptsOrTimeoutError.cjs +48 -0
- package/lib/MaxAttemptsOrTimeoutError.d.ts +26 -0
- package/lib/MaxAttemptsOrTimeoutError.js +2 -0
- package/lib/MaxAttemptsOrTimeoutError.js.map +1 -0
- package/lib/MaxQueryPaymentExceeded.cjs +34 -0
- package/lib/MaxQueryPaymentExceeded.d.ts +21 -0
- package/lib/MaxQueryPaymentExceeded.js +2 -0
- package/lib/MaxQueryPaymentExceeded.js.map +1 -0
- package/lib/MirrorNode.cjs +48 -0
- package/lib/MirrorNode.d.ts +39 -0
- package/lib/MirrorNode.js +2 -0
- package/lib/MirrorNode.js.map +1 -0
- package/lib/Mnemonic.cjs +232 -0
- package/lib/Mnemonic.d.ts +145 -0
- package/lib/Mnemonic.js +2 -0
- package/lib/Mnemonic.js.map +1 -0
- package/lib/Node.cjs +114 -0
- package/lib/Node.d.ts +72 -0
- package/lib/Node.js +2 -0
- package/lib/Node.js.map +1 -0
- package/lib/ObjectMap.cjs +137 -0
- package/lib/ObjectMap.d.ts +88 -0
- package/lib/ObjectMap.js +2 -0
- package/lib/ObjectMap.js.map +1 -0
- package/lib/PrecheckStatusError.cjs +77 -0
- package/lib/PrecheckStatusError.d.ts +68 -0
- package/lib/PrecheckStatusError.js +2 -0
- package/lib/PrecheckStatusError.js.map +1 -0
- package/lib/PrivateKey.cjs +529 -0
- package/lib/PrivateKey.d.ts +312 -0
- package/lib/PrivateKey.js +2 -0
- package/lib/PrivateKey.js.map +1 -0
- package/lib/PrngTransaction.cjs +136 -0
- package/lib/PrngTransaction.d.ts +74 -0
- package/lib/PrngTransaction.js +2 -0
- package/lib/PrngTransaction.js.map +1 -0
- package/lib/Provider.cjs +41 -0
- package/lib/Provider.d.ts +32 -0
- package/lib/Provider.js +2 -0
- package/lib/Provider.js.map +1 -0
- package/lib/PublicKey.cjs +285 -0
- package/lib/PublicKey.d.ts +142 -0
- package/lib/PublicKey.js +2 -0
- package/lib/PublicKey.js.map +1 -0
- package/lib/ReceiptStatusError.cjs +45 -0
- package/lib/ReceiptStatusError.d.ts +38 -0
- package/lib/ReceiptStatusError.js +2 -0
- package/lib/ReceiptStatusError.js.map +1 -0
- package/lib/RecordStatusError.cjs +34 -0
- package/lib/RecordStatusError.d.ts +27 -0
- package/lib/RecordStatusError.js +2 -0
- package/lib/RecordStatusError.js.map +1 -0
- package/lib/RequestType.cjs +922 -0
- package/lib/RequestType.d.ts +131 -0
- package/lib/RequestType.js +2 -0
- package/lib/RequestType.js.map +1 -0
- package/lib/Signer.cjs +47 -0
- package/lib/Signer.d.ts +38 -0
- package/lib/Signer.js +2 -0
- package/lib/Signer.js.map +1 -0
- package/lib/SignerSignature.cjs +34 -0
- package/lib/SignerSignature.d.ts +29 -0
- package/lib/SignerSignature.js +2 -0
- package/lib/SignerSignature.js.map +1 -0
- package/lib/StakingInfo.cjs +160 -0
- package/lib/StakingInfo.d.ts +109 -0
- package/lib/StakingInfo.js +2 -0
- package/lib/StakingInfo.js.map +1 -0
- package/lib/Status.cjs +3353 -0
- package/lib/Status.d.ts +395 -0
- package/lib/Status.js +2 -0
- package/lib/Status.js.map +1 -0
- package/lib/StatusError.cjs +66 -0
- package/lib/StatusError.d.ts +41 -0
- package/lib/StatusError.js +2 -0
- package/lib/StatusError.js.map +1 -0
- package/lib/Timestamp.cjs +144 -0
- package/lib/Timestamp.d.ts +69 -0
- package/lib/Timestamp.js +2 -0
- package/lib/Timestamp.js.map +1 -0
- package/lib/TransactionFeeSchedule.cjs +85 -0
- package/lib/TransactionFeeSchedule.d.ts +39 -0
- package/lib/TransactionFeeSchedule.js +2 -0
- package/lib/TransactionFeeSchedule.js.map +1 -0
- package/lib/Transfer.cjs +104 -0
- package/lib/Transfer.d.ts +77 -0
- package/lib/Transfer.js +2 -0
- package/lib/Transfer.js.map +1 -0
- package/lib/Wallet.cjs +253 -0
- package/lib/Wallet.d.ts +147 -0
- package/lib/Wallet.js +2 -0
- package/lib/Wallet.js.map +1 -0
- package/lib/account/AccountAllowanceAdjustTransaction.cjs +366 -0
- package/lib/account/AccountAllowanceAdjustTransaction.d.ts +208 -0
- package/lib/account/AccountAllowanceAdjustTransaction.js +2 -0
- package/lib/account/AccountAllowanceAdjustTransaction.js.map +1 -0
- package/lib/account/AccountAllowanceApproveTransaction.cjs +353 -0
- package/lib/account/AccountAllowanceApproveTransaction.d.ts +194 -0
- package/lib/account/AccountAllowanceApproveTransaction.js +2 -0
- package/lib/account/AccountAllowanceApproveTransaction.js.map +1 -0
- package/lib/account/AccountAllowanceDeleteTransaction.cjs +166 -0
- package/lib/account/AccountAllowanceDeleteTransaction.d.ts +90 -0
- package/lib/account/AccountAllowanceDeleteTransaction.js +2 -0
- package/lib/account/AccountAllowanceDeleteTransaction.js.map +1 -0
- package/lib/account/AccountBalance.cjs +145 -0
- package/lib/account/AccountBalance.d.ts +72 -0
- package/lib/account/AccountBalance.js +2 -0
- package/lib/account/AccountBalance.js.map +1 -0
- package/lib/account/AccountBalanceQuery.cjs +210 -0
- package/lib/account/AccountBalanceQuery.d.ts +92 -0
- package/lib/account/AccountBalanceQuery.js +2 -0
- package/lib/account/AccountBalanceQuery.js.map +1 -0
- package/lib/account/AccountCreateTransaction.cjs +566 -0
- package/lib/account/AccountCreateTransaction.d.ts +309 -0
- package/lib/account/AccountCreateTransaction.js +2 -0
- package/lib/account/AccountCreateTransaction.js.map +1 -0
- package/lib/account/AccountDeleteTransaction.cjs +181 -0
- package/lib/account/AccountDeleteTransaction.d.ts +97 -0
- package/lib/account/AccountDeleteTransaction.js +2 -0
- package/lib/account/AccountDeleteTransaction.js.map +1 -0
- package/lib/account/AccountId.cjs +400 -0
- package/lib/account/AccountId.d.ts +149 -0
- package/lib/account/AccountId.js +2 -0
- package/lib/account/AccountId.js.map +1 -0
- package/lib/account/AccountInfo.cjs +356 -0
- package/lib/account/AccountInfo.d.ts +234 -0
- package/lib/account/AccountInfo.js +2 -0
- package/lib/account/AccountInfo.js.map +1 -0
- package/lib/account/AccountInfoFlow.cjs +88 -0
- package/lib/account/AccountInfoFlow.d.ts +53 -0
- package/lib/account/AccountInfoFlow.js +2 -0
- package/lib/account/AccountInfoFlow.js.map +1 -0
- package/lib/account/AccountInfoQuery.cjs +170 -0
- package/lib/account/AccountInfoQuery.d.ts +67 -0
- package/lib/account/AccountInfoQuery.js +2 -0
- package/lib/account/AccountInfoQuery.js.map +1 -0
- package/lib/account/AccountRecordsQuery.cjs +163 -0
- package/lib/account/AccountRecordsQuery.d.ts +67 -0
- package/lib/account/AccountRecordsQuery.js +2 -0
- package/lib/account/AccountRecordsQuery.js.map +1 -0
- package/lib/account/AccountUpdateTransaction.cjs +503 -0
- package/lib/account/AccountUpdateTransaction.d.ts +271 -0
- package/lib/account/AccountUpdateTransaction.js +2 -0
- package/lib/account/AccountUpdateTransaction.js.map +1 -0
- package/lib/account/HbarAllowance.cjs +126 -0
- package/lib/account/HbarAllowance.d.ts +85 -0
- package/lib/account/HbarAllowance.js +2 -0
- package/lib/account/HbarAllowance.js.map +1 -0
- package/lib/account/HbarTransferMap.cjs +45 -0
- package/lib/account/HbarTransferMap.d.ts +31 -0
- package/lib/account/HbarTransferMap.js +2 -0
- package/lib/account/HbarTransferMap.js.map +1 -0
- package/lib/account/LiveHash.cjs +76 -0
- package/lib/account/LiveHash.d.ts +49 -0
- package/lib/account/LiveHash.js +2 -0
- package/lib/account/LiveHash.js.map +1 -0
- package/lib/account/LiveHashAddTransaction.cjs +238 -0
- package/lib/account/LiveHashAddTransaction.d.ts +125 -0
- package/lib/account/LiveHashAddTransaction.js +2 -0
- package/lib/account/LiveHashAddTransaction.js.map +1 -0
- package/lib/account/LiveHashDeleteTransaction.cjs +170 -0
- package/lib/account/LiveHashDeleteTransaction.d.ts +88 -0
- package/lib/account/LiveHashDeleteTransaction.js +2 -0
- package/lib/account/LiveHashDeleteTransaction.js.map +1 -0
- package/lib/account/LiveHashQuery.cjs +188 -0
- package/lib/account/LiveHashQuery.d.ts +91 -0
- package/lib/account/LiveHashQuery.js +2 -0
- package/lib/account/LiveHashQuery.js.map +1 -0
- package/lib/account/NullableTokenDecimalMap.cjs +26 -0
- package/lib/account/NullableTokenDecimalMap.d.ts +19 -0
- package/lib/account/NullableTokenDecimalMap.js +2 -0
- package/lib/account/NullableTokenDecimalMap.js.map +1 -0
- package/lib/account/ProxyStaker.cjs +73 -0
- package/lib/account/ProxyStaker.d.ts +53 -0
- package/lib/account/ProxyStaker.js +2 -0
- package/lib/account/ProxyStaker.js.map +1 -0
- package/lib/account/TokenAllowance.cjs +130 -0
- package/lib/account/TokenAllowance.d.ts +93 -0
- package/lib/account/TokenAllowance.js +2 -0
- package/lib/account/TokenAllowance.js.map +1 -0
- package/lib/account/TokenBalanceMap.cjs +30 -0
- package/lib/account/TokenBalanceMap.d.ts +23 -0
- package/lib/account/TokenBalanceMap.js +2 -0
- package/lib/account/TokenBalanceMap.js.map +1 -0
- package/lib/account/TokenDecimalMap.cjs +26 -0
- package/lib/account/TokenDecimalMap.d.ts +19 -0
- package/lib/account/TokenDecimalMap.js +2 -0
- package/lib/account/TokenDecimalMap.js.map +1 -0
- package/lib/account/TokenNftAllowance.cjs +168 -0
- package/lib/account/TokenNftAllowance.d.ts +110 -0
- package/lib/account/TokenNftAllowance.js +2 -0
- package/lib/account/TokenNftAllowance.js.map +1 -0
- package/lib/account/TokenNftTransferMap.cjs +116 -0
- package/lib/account/TokenNftTransferMap.d.ts +55 -0
- package/lib/account/TokenNftTransferMap.js +2 -0
- package/lib/account/TokenNftTransferMap.js.map +1 -0
- package/lib/account/TokenRelationship.cjs +113 -0
- package/lib/account/TokenRelationship.d.ts +87 -0
- package/lib/account/TokenRelationship.js +2 -0
- package/lib/account/TokenRelationship.js.map +1 -0
- package/lib/account/TokenRelationshipMap.cjs +57 -0
- package/lib/account/TokenRelationshipMap.d.ts +33 -0
- package/lib/account/TokenRelationshipMap.js +2 -0
- package/lib/account/TokenRelationshipMap.js.map +1 -0
- package/lib/account/TokenTransferAccountMap.cjs +28 -0
- package/lib/account/TokenTransferAccountMap.d.ts +8 -0
- package/lib/account/TokenTransferAccountMap.js +2 -0
- package/lib/account/TokenTransferAccountMap.js.map +1 -0
- package/lib/account/TokenTransferMap.cjs +86 -0
- package/lib/account/TokenTransferMap.d.ts +41 -0
- package/lib/account/TokenTransferMap.js +2 -0
- package/lib/account/TokenTransferMap.js.map +1 -0
- package/lib/account/TransferTransaction.cjs +303 -0
- package/lib/account/TransferTransaction.d.ts +173 -0
- package/lib/account/TransferTransaction.js +2 -0
- package/lib/account/TransferTransaction.js.map +1 -0
- package/lib/address_book/AddressBooks.cjs +17 -0
- package/lib/address_book/AddressBooks.d.ts +4 -0
- package/lib/address_book/AddressBooks.js +2 -0
- package/lib/address_book/AddressBooks.js.map +1 -0
- package/lib/address_book/Endpoint.cjs +140 -0
- package/lib/address_book/Endpoint.d.ts +79 -0
- package/lib/address_book/Endpoint.js +2 -0
- package/lib/address_book/Endpoint.js.map +1 -0
- package/lib/address_book/IPv4Address.cjs +116 -0
- package/lib/address_book/IPv4Address.d.ts +59 -0
- package/lib/address_book/IPv4Address.js +2 -0
- package/lib/address_book/IPv4Address.js.map +1 -0
- package/lib/address_book/IPv4AddressPart.cjs +76 -0
- package/lib/address_book/IPv4AddressPart.d.ts +41 -0
- package/lib/address_book/IPv4AddressPart.js +2 -0
- package/lib/address_book/IPv4AddressPart.js.map +1 -0
- package/lib/address_book/NodeAddress.cjs +287 -0
- package/lib/address_book/NodeAddress.d.ts +170 -0
- package/lib/address_book/NodeAddress.js +2 -0
- package/lib/address_book/NodeAddress.js.map +1 -0
- package/lib/address_book/NodeAddressBook.cjs +108 -0
- package/lib/address_book/NodeAddressBook.d.ts +66 -0
- package/lib/address_book/NodeAddressBook.js +2 -0
- package/lib/address_book/NodeAddressBook.js.map +1 -0
- package/lib/array.cjs +51 -0
- package/lib/array.d.ts +14 -0
- package/lib/array.js +2 -0
- package/lib/array.js.map +1 -0
- package/lib/base32.cjs +38 -0
- package/lib/base32.d.ts +18 -0
- package/lib/base32.js +2 -0
- package/lib/base32.js.map +1 -0
- package/lib/browser.cjs +36 -0
- package/lib/browser.d.ts +3 -0
- package/lib/browser.js +2 -0
- package/lib/browser.js.map +1 -0
- package/lib/channel/Channel.cjs +293 -0
- package/lib/channel/Channel.d.ts +121 -0
- package/lib/channel/Channel.js +2 -0
- package/lib/channel/Channel.js.map +1 -0
- package/lib/channel/MirrorChannel.cjs +55 -0
- package/lib/channel/MirrorChannel.d.ts +32 -0
- package/lib/channel/MirrorChannel.js +2 -0
- package/lib/channel/MirrorChannel.js.map +1 -0
- package/lib/channel/NativeChannel.cjs +97 -0
- package/lib/channel/NativeChannel.d.ts +12 -0
- package/lib/channel/NativeChannel.js +2 -0
- package/lib/channel/NativeChannel.js.map +1 -0
- package/lib/channel/NodeChannel.cjs +173 -0
- package/lib/channel/NodeChannel.d.ts +41 -0
- package/lib/channel/NodeChannel.js +2 -0
- package/lib/channel/NodeChannel.js.map +1 -0
- package/lib/channel/NodeMirrorChannel.cjs +78 -0
- package/lib/channel/NodeMirrorChannel.d.ts +22 -0
- package/lib/channel/NodeMirrorChannel.js +2 -0
- package/lib/channel/NodeMirrorChannel.js.map +1 -0
- package/lib/channel/WebChannel.cjs +90 -0
- package/lib/channel/WebChannel.d.ts +12 -0
- package/lib/channel/WebChannel.js +2 -0
- package/lib/channel/WebChannel.js.map +1 -0
- package/lib/client/Client.cjs +818 -0
- package/lib/client/Client.d.ts +487 -0
- package/lib/client/Client.js +2 -0
- package/lib/client/Client.js.map +1 -0
- package/lib/client/ManagedNetwork.cjs +427 -0
- package/lib/client/ManagedNetwork.d.ts +175 -0
- package/lib/client/ManagedNetwork.js +2 -0
- package/lib/client/ManagedNetwork.js.map +1 -0
- package/lib/client/MirrorNetwork.cjs +89 -0
- package/lib/client/MirrorNetwork.d.ts +27 -0
- package/lib/client/MirrorNetwork.js +2 -0
- package/lib/client/MirrorNetwork.js.map +1 -0
- package/lib/client/NativeClient.cjs +210 -0
- package/lib/client/NativeClient.d.ts +72 -0
- package/lib/client/NativeClient.js +2 -0
- package/lib/client/NativeClient.js.map +1 -0
- package/lib/client/Network.cjs +257 -0
- package/lib/client/Network.d.ts +90 -0
- package/lib/client/Network.js +2 -0
- package/lib/client/Network.js.map +1 -0
- package/lib/client/NodeClient.cjs +316 -0
- package/lib/client/NodeClient.d.ts +129 -0
- package/lib/client/NodeClient.js +2 -0
- package/lib/client/NodeClient.js.map +1 -0
- package/lib/client/WebClient.cjs +280 -0
- package/lib/client/WebClient.d.ts +90 -0
- package/lib/client/WebClient.js +2 -0
- package/lib/client/WebClient.js.map +1 -0
- package/lib/client/addressbooks/mainnet.cjs +7 -0
- package/lib/client/addressbooks/mainnet.d.ts +1 -0
- package/lib/client/addressbooks/mainnet.js +2 -0
- package/lib/client/addressbooks/mainnet.js.map +1 -0
- package/lib/client/addressbooks/previewnet.cjs +7 -0
- package/lib/client/addressbooks/previewnet.d.ts +1 -0
- package/lib/client/addressbooks/previewnet.js +2 -0
- package/lib/client/addressbooks/previewnet.js.map +1 -0
- package/lib/client/addressbooks/testnet.cjs +7 -0
- package/lib/client/addressbooks/testnet.d.ts +1 -0
- package/lib/client/addressbooks/testnet.js +2 -0
- package/lib/client/addressbooks/testnet.js.map +1 -0
- package/lib/constants/ClientConstants.cjs +201 -0
- package/lib/constants/ClientConstants.d.ts +74 -0
- package/lib/constants/ClientConstants.js +2 -0
- package/lib/constants/ClientConstants.js.map +1 -0
- package/lib/contract/ContractByteCodeQuery.cjs +158 -0
- package/lib/contract/ContractByteCodeQuery.d.ts +76 -0
- package/lib/contract/ContractByteCodeQuery.js +2 -0
- package/lib/contract/ContractByteCodeQuery.js.map +1 -0
- package/lib/contract/ContractCallQuery.cjs +338 -0
- package/lib/contract/ContractCallQuery.d.ts +141 -0
- package/lib/contract/ContractCallQuery.js +2 -0
- package/lib/contract/ContractCallQuery.js.map +1 -0
- package/lib/contract/ContractCreateFlow.cjs +452 -0
- package/lib/contract/ContractCreateFlow.d.ts +243 -0
- package/lib/contract/ContractCreateFlow.js +2 -0
- package/lib/contract/ContractCreateFlow.js.map +1 -0
- package/lib/contract/ContractCreateTransaction.cjs +556 -0
- package/lib/contract/ContractCreateTransaction.d.ts +315 -0
- package/lib/contract/ContractCreateTransaction.js +2 -0
- package/lib/contract/ContractCreateTransaction.js.map +1 -0
- package/lib/contract/ContractDeleteTransaction.cjs +235 -0
- package/lib/contract/ContractDeleteTransaction.d.ts +135 -0
- package/lib/contract/ContractDeleteTransaction.js +2 -0
- package/lib/contract/ContractDeleteTransaction.js.map +1 -0
- package/lib/contract/ContractExecuteTransaction.cjs +269 -0
- package/lib/contract/ContractExecuteTransaction.d.ts +164 -0
- package/lib/contract/ContractExecuteTransaction.js +2 -0
- package/lib/contract/ContractExecuteTransaction.js.map +1 -0
- package/lib/contract/ContractFunctionParameters.cjs +1703 -0
- package/lib/contract/ContractFunctionParameters.d.ts +725 -0
- package/lib/contract/ContractFunctionParameters.js +2 -0
- package/lib/contract/ContractFunctionParameters.js.map +1 -0
- package/lib/contract/ContractFunctionResult.cjs +846 -0
- package/lib/contract/ContractFunctionResult.d.ts +510 -0
- package/lib/contract/ContractFunctionResult.js +2 -0
- package/lib/contract/ContractFunctionResult.js.map +1 -0
- package/lib/contract/ContractFunctionSelector.cjs +1775 -0
- package/lib/contract/ContractFunctionSelector.d.ts +688 -0
- package/lib/contract/ContractFunctionSelector.js +2 -0
- package/lib/contract/ContractFunctionSelector.js.map +1 -0
- package/lib/contract/ContractId.cjs +267 -0
- package/lib/contract/ContractId.d.ts +123 -0
- package/lib/contract/ContractId.js +2 -0
- package/lib/contract/ContractId.js.map +1 -0
- package/lib/contract/ContractInfo.cjs +227 -0
- package/lib/contract/ContractInfo.d.ts +151 -0
- package/lib/contract/ContractInfo.js +2 -0
- package/lib/contract/ContractInfo.js.map +1 -0
- package/lib/contract/ContractInfoQuery.cjs +172 -0
- package/lib/contract/ContractInfoQuery.d.ts +70 -0
- package/lib/contract/ContractInfoQuery.js +2 -0
- package/lib/contract/ContractInfoQuery.js.map +1 -0
- package/lib/contract/ContractLogInfo.cjs +87 -0
- package/lib/contract/ContractLogInfo.d.ts +66 -0
- package/lib/contract/ContractLogInfo.js +2 -0
- package/lib/contract/ContractLogInfo.js.map +1 -0
- package/lib/contract/ContractNonceInfo.cjs +129 -0
- package/lib/contract/ContractNonceInfo.d.ts +90 -0
- package/lib/contract/ContractNonceInfo.js +2 -0
- package/lib/contract/ContractNonceInfo.js.map +1 -0
- package/lib/contract/ContractStateChange.cjs +75 -0
- package/lib/contract/ContractStateChange.d.ts +37 -0
- package/lib/contract/ContractUpdateTransaction.cjs +525 -0
- package/lib/contract/ContractUpdateTransaction.d.ts +280 -0
- package/lib/contract/ContractUpdateTransaction.js +2 -0
- package/lib/contract/ContractUpdateTransaction.js.map +1 -0
- package/lib/contract/DelegateContractId.cjs +100 -0
- package/lib/contract/DelegateContractId.d.ts +24 -0
- package/lib/contract/DelegateContractId.js +2 -0
- package/lib/contract/DelegateContractId.js.map +1 -0
- package/lib/contract/StorageChange.cjs +73 -0
- package/lib/contract/StorageChange.d.ts +37 -0
- package/lib/cryptography/keccak.cjs +335 -0
- package/lib/cryptography/keccak.d.ts +14 -0
- package/lib/cryptography/keccak.js +2 -0
- package/lib/cryptography/keccak.js.map +1 -0
- package/lib/cryptography/sha384.browser.cjs +19 -0
- package/lib/cryptography/sha384.browser.d.ts +5 -0
- package/lib/cryptography/sha384.browser.js +2 -0
- package/lib/cryptography/sha384.browser.js.map +1 -0
- package/lib/cryptography/sha384.cjs +27 -0
- package/lib/cryptography/sha384.d.ts +10 -0
- package/lib/cryptography/sha384.js +2 -0
- package/lib/cryptography/sha384.js.map +1 -0
- package/lib/cryptography/sha384.native.cjs +21 -0
- package/lib/cryptography/sha384.native.d.ts +5 -0
- package/lib/encoding/base64.native.cjs +25 -0
- package/lib/encoding/base64.native.d.ts +10 -0
- package/lib/encoding/base64.native.js +2 -0
- package/lib/encoding/base64.native.js.map +1 -0
- package/lib/encoding/hex.browser.cjs +95 -0
- package/lib/encoding/hex.browser.d.ts +26 -0
- package/lib/encoding/hex.browser.js +2 -0
- package/lib/encoding/hex.browser.js.map +1 -0
- package/lib/encoding/hex.cjs +82 -0
- package/lib/encoding/hex.d.ts +26 -0
- package/lib/encoding/hex.js +2 -0
- package/lib/encoding/hex.js.map +1 -0
- package/lib/encoding/hex.native.cjs +127 -0
- package/lib/encoding/hex.native.d.ts +36 -0
- package/lib/encoding/utf8.browser.cjs +26 -0
- package/lib/encoding/utf8.browser.d.ts +10 -0
- package/lib/encoding/utf8.browser.js +2 -0
- package/lib/encoding/utf8.browser.js.map +1 -0
- package/lib/encoding/utf8.cjs +24 -0
- package/lib/encoding/utf8.d.ts +10 -0
- package/lib/encoding/utf8.js +2 -0
- package/lib/encoding/utf8.js.map +1 -0
- package/lib/encoding/utf8.native.cjs +29 -0
- package/lib/encoding/utf8.native.d.ts +10 -0
- package/lib/exports.cjs +1264 -0
- package/lib/exports.d.ts +200 -0
- package/lib/exports.js +2 -0
- package/lib/exports.js.map +1 -0
- package/lib/file/FileAppendTransaction.cjs +482 -0
- package/lib/file/FileAppendTransaction.d.ts +196 -0
- package/lib/file/FileAppendTransaction.js +2 -0
- package/lib/file/FileAppendTransaction.js.map +1 -0
- package/lib/file/FileContentsQuery.cjs +159 -0
- package/lib/file/FileContentsQuery.d.ts +77 -0
- package/lib/file/FileContentsQuery.js +2 -0
- package/lib/file/FileContentsQuery.js.map +1 -0
- package/lib/file/FileCreateTransaction.cjs +259 -0
- package/lib/file/FileCreateTransaction.d.ts +153 -0
- package/lib/file/FileCreateTransaction.js +2 -0
- package/lib/file/FileCreateTransaction.js.map +1 -0
- package/lib/file/FileDeleteTransaction.cjs +149 -0
- package/lib/file/FileDeleteTransaction.d.ts +84 -0
- package/lib/file/FileDeleteTransaction.js +2 -0
- package/lib/file/FileDeleteTransaction.js.map +1 -0
- package/lib/file/FileId.cjs +240 -0
- package/lib/file/FileId.d.ts +126 -0
- package/lib/file/FileId.js +2 -0
- package/lib/file/FileId.js.map +1 -0
- package/lib/file/FileInfo.cjs +128 -0
- package/lib/file/FileInfo.d.ts +76 -0
- package/lib/file/FileInfo.js +2 -0
- package/lib/file/FileInfo.js.map +1 -0
- package/lib/file/FileInfoQuery.cjs +171 -0
- package/lib/file/FileInfoQuery.d.ts +68 -0
- package/lib/file/FileInfoQuery.js +2 -0
- package/lib/file/FileInfoQuery.js.map +1 -0
- package/lib/file/FileUpdateTransaction.cjs +319 -0
- package/lib/file/FileUpdateTransaction.d.ts +188 -0
- package/lib/file/FileUpdateTransaction.js +2 -0
- package/lib/file/FileUpdateTransaction.js.map +1 -0
- package/lib/grpc/GrpcServiceError.cjs +65 -0
- package/lib/grpc/GrpcServiceError.d.ts +32 -0
- package/lib/grpc/GrpcServiceError.js +2 -0
- package/lib/grpc/GrpcServiceError.js.map +1 -0
- package/lib/grpc/GrpcStatus.cjs +145 -0
- package/lib/grpc/GrpcStatus.d.ts +46 -0
- package/lib/grpc/GrpcStatus.js +2 -0
- package/lib/grpc/GrpcStatus.js.map +1 -0
- package/lib/http/HttpError.cjs +32 -0
- package/lib/http/HttpError.d.ts +14 -0
- package/lib/http/HttpError.js +2 -0
- package/lib/http/HttpError.js.map +1 -0
- package/lib/http/HttpStatus.cjs +44 -0
- package/lib/http/HttpStatus.d.ts +24 -0
- package/lib/http/HttpStatus.js +2 -0
- package/lib/http/HttpStatus.js.map +1 -0
- package/lib/index.cjs +44 -0
- package/lib/index.d.ts +4 -0
- package/lib/index.js +2 -0
- package/lib/index.js.map +1 -0
- package/lib/logger/LogLevel.cjs +77 -0
- package/lib/logger/LogLevel.d.ts +29 -0
- package/lib/logger/LogLevel.js +2 -0
- package/lib/logger/LogLevel.js.map +1 -0
- package/lib/logger/Logger.cjs +221 -0
- package/lib/logger/Logger.d.ts +132 -0
- package/lib/logger/Logger.js +2 -0
- package/lib/logger/Logger.js.map +1 -0
- package/lib/long.cjs +26 -0
- package/lib/long.d.ts +16 -0
- package/lib/long.js +2 -0
- package/lib/long.js.map +1 -0
- package/lib/native.cjs +36 -0
- package/lib/native.d.ts +3 -0
- package/lib/native.js +2 -0
- package/lib/native.js.map +1 -0
- package/lib/network/AddressBookQuery.cjs +218 -0
- package/lib/network/AddressBookQuery.d.ts +104 -0
- package/lib/network/AddressBookQuery.js +2 -0
- package/lib/network/AddressBookQuery.js.map +1 -0
- package/lib/network/AddressBookQueryWeb.cjs +326 -0
- package/lib/network/AddressBookQueryWeb.d.ts +165 -0
- package/lib/network/AddressBookQueryWeb.js +2 -0
- package/lib/network/AddressBookQueryWeb.js.map +1 -0
- package/lib/network/NetworkVersionInfo.cjs +81 -0
- package/lib/network/NetworkVersionInfo.d.ts +46 -0
- package/lib/network/NetworkVersionInfo.js +2 -0
- package/lib/network/NetworkVersionInfo.js.map +1 -0
- package/lib/network/NetworkVersionInfoQuery.cjs +112 -0
- package/lib/network/NetworkVersionInfoQuery.d.ts +50 -0
- package/lib/network/NetworkVersionInfoQuery.js +2 -0
- package/lib/network/NetworkVersionInfoQuery.js.map +1 -0
- package/lib/network/SemanticVersion.cjs +78 -0
- package/lib/network/SemanticVersion.d.ts +45 -0
- package/lib/network/SemanticVersion.js +2 -0
- package/lib/network/SemanticVersion.js.map +1 -0
- package/lib/node/NodeCreateTransaction.cjs +413 -0
- package/lib/node/NodeCreateTransaction.d.ts +239 -0
- package/lib/node/NodeCreateTransaction.js +2 -0
- package/lib/node/NodeCreateTransaction.js.map +1 -0
- package/lib/node/NodeDeleteTransaction.cjs +143 -0
- package/lib/node/NodeDeleteTransaction.d.ts +80 -0
- package/lib/node/NodeDeleteTransaction.js +2 -0
- package/lib/node/NodeDeleteTransaction.js.map +1 -0
- package/lib/node/NodeUpdateTransaction.cjs +481 -0
- package/lib/node/NodeUpdateTransaction.d.ts +274 -0
- package/lib/node/NodeUpdateTransaction.js +2 -0
- package/lib/node/NodeUpdateTransaction.js.map +1 -0
- package/lib/node/ServiceEndpoint.cjs +140 -0
- package/lib/node/ServiceEndpoint.d.ts +91 -0
- package/lib/node/ServiceEndpoint.js +2 -0
- package/lib/node/ServiceEndpoint.js.map +1 -0
- package/lib/query/CostQuery.cjs +171 -0
- package/lib/query/CostQuery.d.ts +43 -0
- package/lib/query/CostQuery.js +2 -0
- package/lib/query/CostQuery.js.map +1 -0
- package/lib/query/MirrorNodeContractCallQuery.cjs +53 -0
- package/lib/query/MirrorNodeContractCallQuery.d.ts +21 -0
- package/lib/query/MirrorNodeContractCallQuery.js +2 -0
- package/lib/query/MirrorNodeContractCallQuery.js.map +1 -0
- package/lib/query/MirrorNodeContractEstimateQuery.cjs +53 -0
- package/lib/query/MirrorNodeContractEstimateQuery.d.ts +21 -0
- package/lib/query/MirrorNodeContractEstimateQuery.js +2 -0
- package/lib/query/MirrorNodeContractEstimateQuery.js.map +1 -0
- package/lib/query/MirrorNodeContractQuery.cjs +260 -0
- package/lib/query/MirrorNodeContractQuery.d.ts +158 -0
- package/lib/query/MirrorNodeContractQuery.js +2 -0
- package/lib/query/MirrorNodeContractQuery.js.map +1 -0
- package/lib/query/Query.cjs +450 -0
- package/lib/query/Query.d.ts +173 -0
- package/lib/query/Query.js +2 -0
- package/lib/query/Query.js.map +1 -0
- package/lib/query/QueryBase.cjs +114 -0
- package/lib/query/QueryBase.d.ts +43 -0
- package/lib/query/QueryBase.js +2 -0
- package/lib/query/QueryBase.js.map +1 -0
- package/lib/schedule/ScheduleCreateTransaction.cjs +308 -0
- package/lib/schedule/ScheduleCreateTransaction.d.ts +153 -0
- package/lib/schedule/ScheduleCreateTransaction.js +2 -0
- package/lib/schedule/ScheduleCreateTransaction.js.map +1 -0
- package/lib/schedule/ScheduleDeleteTransaction.cjs +146 -0
- package/lib/schedule/ScheduleDeleteTransaction.d.ts +81 -0
- package/lib/schedule/ScheduleDeleteTransaction.js +2 -0
- package/lib/schedule/ScheduleDeleteTransaction.js.map +1 -0
- package/lib/schedule/ScheduleId.cjs +164 -0
- package/lib/schedule/ScheduleId.d.ts +96 -0
- package/lib/schedule/ScheduleId.js +2 -0
- package/lib/schedule/ScheduleId.js.map +1 -0
- package/lib/schedule/ScheduleInfo.cjs +176 -0
- package/lib/schedule/ScheduleInfo.d.ts +93 -0
- package/lib/schedule/ScheduleInfo.js +2 -0
- package/lib/schedule/ScheduleInfo.js.map +1 -0
- package/lib/schedule/ScheduleInfoQuery.cjs +170 -0
- package/lib/schedule/ScheduleInfoQuery.d.ts +66 -0
- package/lib/schedule/ScheduleInfoQuery.js +2 -0
- package/lib/schedule/ScheduleInfoQuery.js.map +1 -0
- package/lib/schedule/ScheduleSignTransaction.cjs +164 -0
- package/lib/schedule/ScheduleSignTransaction.d.ts +110 -0
- package/lib/schedule/ScheduleSignTransaction.js +2 -0
- package/lib/schedule/ScheduleSignTransaction.js.map +1 -0
- package/lib/system/FreezeTransaction.cjs +348 -0
- package/lib/system/FreezeTransaction.d.ts +188 -0
- package/lib/system/FreezeTransaction.js +2 -0
- package/lib/system/FreezeTransaction.js.map +1 -0
- package/lib/system/SystemDeleteTransaction.cjs +200 -0
- package/lib/system/SystemDeleteTransaction.d.ts +110 -0
- package/lib/system/SystemDeleteTransaction.js +2 -0
- package/lib/system/SystemDeleteTransaction.js.map +1 -0
- package/lib/system/SystemUndeleteTransaction.cjs +172 -0
- package/lib/system/SystemUndeleteTransaction.d.ts +97 -0
- package/lib/system/SystemUndeleteTransaction.js +2 -0
- package/lib/system/SystemUndeleteTransaction.js.map +1 -0
- package/lib/token/AbstractTokenTransferTransaction.cjs +406 -0
- package/lib/token/AbstractTokenTransferTransaction.d.ts +138 -0
- package/lib/token/AbstractTokenTransferTransaction.js +2 -0
- package/lib/token/AbstractTokenTransferTransaction.js.map +1 -0
- package/lib/token/AirdropPendingTransaction.cjs +65 -0
- package/lib/token/AirdropPendingTransaction.d.ts +35 -0
- package/lib/token/AirdropPendingTransaction.js +2 -0
- package/lib/token/AirdropPendingTransaction.js.map +1 -0
- package/lib/token/AssessedCustomFee.cjs +177 -0
- package/lib/token/AssessedCustomFee.d.ts +113 -0
- package/lib/token/AssessedCustomFee.js +2 -0
- package/lib/token/AssessedCustomFee.js.map +1 -0
- package/lib/token/CustomFee.cjs +88 -0
- package/lib/token/CustomFee.d.ts +57 -0
- package/lib/token/CustomFee.js +2 -0
- package/lib/token/CustomFee.js.map +1 -0
- package/lib/token/CustomFixedFee.cjs +155 -0
- package/lib/token/CustomFixedFee.d.ts +85 -0
- package/lib/token/CustomFixedFee.js +2 -0
- package/lib/token/CustomFixedFee.js.map +1 -0
- package/lib/token/CustomFractionalFee.cjs +200 -0
- package/lib/token/CustomFractionalFee.d.ts +103 -0
- package/lib/token/CustomFractionalFee.js +2 -0
- package/lib/token/CustomFractionalFee.js.map +1 -0
- package/lib/token/CustomRoyaltyFee.cjs +150 -0
- package/lib/token/CustomRoyaltyFee.d.ts +75 -0
- package/lib/token/CustomRoyaltyFee.js +2 -0
- package/lib/token/CustomRoyaltyFee.js.map +1 -0
- package/lib/token/FeeAssessmentMethod.cjs +58 -0
- package/lib/token/FeeAssessmentMethod.d.ts +29 -0
- package/lib/token/FeeAssessmentMethod.js +2 -0
- package/lib/token/FeeAssessmentMethod.js.map +1 -0
- package/lib/token/NftId.cjs +89 -0
- package/lib/token/NftId.d.ts +46 -0
- package/lib/token/NftId.js +2 -0
- package/lib/token/NftId.js.map +1 -0
- package/lib/token/PendingAirdropId.cjs +152 -0
- package/lib/token/PendingAirdropId.d.ts +81 -0
- package/lib/token/PendingAirdropId.js +2 -0
- package/lib/token/PendingAirdropId.js.map +1 -0
- package/lib/token/PendingAirdropRecord.cjs +55 -0
- package/lib/token/PendingAirdropRecord.d.ts +29 -0
- package/lib/token/PendingAirdropRecord.js +2 -0
- package/lib/token/PendingAirdropRecord.js.map +1 -0
- package/lib/token/TokenAirdropTransaction.cjs +179 -0
- package/lib/token/TokenAirdropTransaction.d.ts +119 -0
- package/lib/token/TokenAirdropTransaction.js +2 -0
- package/lib/token/TokenAirdropTransaction.js.map +1 -0
- package/lib/token/TokenAssociateTransaction.cjs +176 -0
- package/lib/token/TokenAssociateTransaction.d.ts +90 -0
- package/lib/token/TokenAssociateTransaction.js +2 -0
- package/lib/token/TokenAssociateTransaction.js.map +1 -0
- package/lib/token/TokenAssociation.cjs +117 -0
- package/lib/token/TokenAssociation.d.ts +76 -0
- package/lib/token/TokenAssociation.js +2 -0
- package/lib/token/TokenAssociation.js.map +1 -0
- package/lib/token/TokenBurnTransaction.cjs +199 -0
- package/lib/token/TokenBurnTransaction.d.ts +108 -0
- package/lib/token/TokenBurnTransaction.js +2 -0
- package/lib/token/TokenBurnTransaction.js.map +1 -0
- package/lib/token/TokenCancelAirdropTransaction.cjs +109 -0
- package/lib/token/TokenCancelAirdropTransaction.d.ts +50 -0
- package/lib/token/TokenCancelAirdropTransaction.js +2 -0
- package/lib/token/TokenCancelAirdropTransaction.js.map +1 -0
- package/lib/token/TokenClaimAirdropTransaction.cjs +109 -0
- package/lib/token/TokenClaimAirdropTransaction.d.ts +50 -0
- package/lib/token/TokenClaimAirdropTransaction.js +2 -0
- package/lib/token/TokenClaimAirdropTransaction.js.map +1 -0
- package/lib/token/TokenCreateTransaction.cjs +817 -0
- package/lib/token/TokenCreateTransaction.d.ts +446 -0
- package/lib/token/TokenCreateTransaction.js +2 -0
- package/lib/token/TokenCreateTransaction.js.map +1 -0
- package/lib/token/TokenDeleteTransaction.cjs +140 -0
- package/lib/token/TokenDeleteTransaction.d.ts +75 -0
- package/lib/token/TokenDeleteTransaction.js +2 -0
- package/lib/token/TokenDeleteTransaction.js.map +1 -0
- package/lib/token/TokenDissociateTransaction.cjs +176 -0
- package/lib/token/TokenDissociateTransaction.d.ts +90 -0
- package/lib/token/TokenDissociateTransaction.js +2 -0
- package/lib/token/TokenDissociateTransaction.js.map +1 -0
- package/lib/token/TokenFeeScheduleUpdateTransaction.cjs +172 -0
- package/lib/token/TokenFeeScheduleUpdateTransaction.d.ts +93 -0
- package/lib/token/TokenFeeScheduleUpdateTransaction.js +2 -0
- package/lib/token/TokenFeeScheduleUpdateTransaction.js.map +1 -0
- package/lib/token/TokenFreezeTransaction.cjs +172 -0
- package/lib/token/TokenFreezeTransaction.d.ts +90 -0
- package/lib/token/TokenFreezeTransaction.js +2 -0
- package/lib/token/TokenFreezeTransaction.js.map +1 -0
- package/lib/token/TokenGrantKycTransaction.cjs +172 -0
- package/lib/token/TokenGrantKycTransaction.d.ts +90 -0
- package/lib/token/TokenGrantKycTransaction.js +2 -0
- package/lib/token/TokenGrantKycTransaction.js.map +1 -0
- package/lib/token/TokenId.cjs +185 -0
- package/lib/token/TokenId.d.ts +103 -0
- package/lib/token/TokenId.js +2 -0
- package/lib/token/TokenId.js.map +1 -0
- package/lib/token/TokenInfo.cjs +349 -0
- package/lib/token/TokenInfo.d.ts +224 -0
- package/lib/token/TokenInfo.js +2 -0
- package/lib/token/TokenInfo.js.map +1 -0
- package/lib/token/TokenInfoQuery.cjs +170 -0
- package/lib/token/TokenInfoQuery.d.ts +67 -0
- package/lib/token/TokenInfoQuery.js +2 -0
- package/lib/token/TokenInfoQuery.js.map +1 -0
- package/lib/token/TokenKeyValidation.cjs +73 -0
- package/lib/token/TokenKeyValidation.d.ts +39 -0
- package/lib/token/TokenKeyValidation.js +2 -0
- package/lib/token/TokenKeyValidation.js.map +1 -0
- package/lib/token/TokenMintTransaction.cjs +219 -0
- package/lib/token/TokenMintTransaction.d.ts +113 -0
- package/lib/token/TokenMintTransaction.js +2 -0
- package/lib/token/TokenMintTransaction.js.map +1 -0
- package/lib/token/TokenNftInfo.cjs +127 -0
- package/lib/token/TokenNftInfo.d.ts +96 -0
- package/lib/token/TokenNftInfo.js +2 -0
- package/lib/token/TokenNftInfo.js.map +1 -0
- package/lib/token/TokenNftInfoQuery.cjs +312 -0
- package/lib/token/TokenNftInfoQuery.d.ts +149 -0
- package/lib/token/TokenNftInfoQuery.js +2 -0
- package/lib/token/TokenNftInfoQuery.js.map +1 -0
- package/lib/token/TokenNftTransfer.cjs +95 -0
- package/lib/token/TokenNftTransfer.d.ts +70 -0
- package/lib/token/TokenNftTransfer.js +2 -0
- package/lib/token/TokenNftTransfer.js.map +1 -0
- package/lib/token/TokenNftsUpdateTransaction.cjs +185 -0
- package/lib/token/TokenNftsUpdateTransaction.d.ts +97 -0
- package/lib/token/TokenPauseTransaction.cjs +140 -0
- package/lib/token/TokenPauseTransaction.d.ts +75 -0
- package/lib/token/TokenPauseTransaction.js +2 -0
- package/lib/token/TokenPauseTransaction.js.map +1 -0
- package/lib/token/TokenReference.cjs +41 -0
- package/lib/token/TokenReference.d.ts +29 -0
- package/lib/token/TokenReference.js +2 -0
- package/lib/token/TokenReference.js.map +1 -0
- package/lib/token/TokenRejectFlow.cjs +248 -0
- package/lib/token/TokenRejectFlow.d.ts +141 -0
- package/lib/token/TokenRejectFlow.js +2 -0
- package/lib/token/TokenRejectFlow.js.map +1 -0
- package/lib/token/TokenRejectTransaction.cjs +240 -0
- package/lib/token/TokenRejectTransaction.d.ts +120 -0
- package/lib/token/TokenRejectTransaction.js +2 -0
- package/lib/token/TokenRejectTransaction.js.map +1 -0
- package/lib/token/TokenRevokeKycTransaction.cjs +172 -0
- package/lib/token/TokenRevokeKycTransaction.d.ts +90 -0
- package/lib/token/TokenRevokeKycTransaction.js +2 -0
- package/lib/token/TokenRevokeKycTransaction.js.map +1 -0
- package/lib/token/TokenSupplyType.cjs +77 -0
- package/lib/token/TokenSupplyType.d.ts +38 -0
- package/lib/token/TokenSupplyType.js +2 -0
- package/lib/token/TokenSupplyType.js.map +1 -0
- package/lib/token/TokenTransfer.cjs +122 -0
- package/lib/token/TokenTransfer.d.ts +92 -0
- package/lib/token/TokenTransfer.js +2 -0
- package/lib/token/TokenTransfer.js.map +1 -0
- package/lib/token/TokenType.cjs +77 -0
- package/lib/token/TokenType.d.ts +38 -0
- package/lib/token/TokenType.js +2 -0
- package/lib/token/TokenType.js.map +1 -0
- package/lib/token/TokenUnfreezeTransaction.cjs +172 -0
- package/lib/token/TokenUnfreezeTransaction.d.ts +90 -0
- package/lib/token/TokenUnfreezeTransaction.js +2 -0
- package/lib/token/TokenUnfreezeTransaction.js.map +1 -0
- package/lib/token/TokenUnpauseTransaction.cjs +140 -0
- package/lib/token/TokenUnpauseTransaction.d.ts +75 -0
- package/lib/token/TokenUnpauseTransaction.js +2 -0
- package/lib/token/TokenUnpauseTransaction.js.map +1 -0
- package/lib/token/TokenUpdateNftsTransaction.cjs +189 -0
- package/lib/token/TokenUpdateNftsTransaction.d.ts +103 -0
- package/lib/token/TokenUpdateNftsTransaction.js +2 -0
- package/lib/token/TokenUpdateNftsTransaction.js.map +1 -0
- package/lib/token/TokenUpdateTransaction.cjs +672 -0
- package/lib/token/TokenUpdateTransaction.d.ts +366 -0
- package/lib/token/TokenUpdateTransaction.js +2 -0
- package/lib/token/TokenUpdateTransaction.js.map +1 -0
- package/lib/token/TokenWipeTransaction.cjs +231 -0
- package/lib/token/TokenWipeTransaction.d.ts +123 -0
- package/lib/token/TokenWipeTransaction.js +2 -0
- package/lib/token/TokenWipeTransaction.js.map +1 -0
- package/lib/topic/SubscriptionHandle.cjs +40 -0
- package/lib/topic/SubscriptionHandle.d.ts +22 -0
- package/lib/topic/SubscriptionHandle.js +2 -0
- package/lib/topic/SubscriptionHandle.js.map +1 -0
- package/lib/topic/TopicCreateTransaction.cjs +473 -0
- package/lib/topic/TopicCreateTransaction.d.ts +250 -0
- package/lib/topic/TopicCreateTransaction.js +2 -0
- package/lib/topic/TopicCreateTransaction.js.map +1 -0
- package/lib/topic/TopicDeleteTransaction.cjs +146 -0
- package/lib/topic/TopicDeleteTransaction.d.ts +80 -0
- package/lib/topic/TopicDeleteTransaction.js +2 -0
- package/lib/topic/TopicDeleteTransaction.js.map +1 -0
- package/lib/topic/TopicId.cjs +185 -0
- package/lib/topic/TopicId.d.ts +102 -0
- package/lib/topic/TopicId.js +2 -0
- package/lib/topic/TopicId.js.map +1 -0
- package/lib/topic/TopicInfo.cjs +187 -0
- package/lib/topic/TopicInfo.d.ts +119 -0
- package/lib/topic/TopicInfo.js +2 -0
- package/lib/topic/TopicInfo.js.map +1 -0
- package/lib/topic/TopicInfoQuery.cjs +174 -0
- package/lib/topic/TopicInfoQuery.d.ts +81 -0
- package/lib/topic/TopicInfoQuery.js +2 -0
- package/lib/topic/TopicInfoQuery.js.map +1 -0
- package/lib/topic/TopicMessage.cjs +116 -0
- package/lib/topic/TopicMessage.d.ts +65 -0
- package/lib/topic/TopicMessage.js +2 -0
- package/lib/topic/TopicMessage.js.map +1 -0
- package/lib/topic/TopicMessageChunk.cjs +71 -0
- package/lib/topic/TopicMessageChunk.d.ts +56 -0
- package/lib/topic/TopicMessageChunk.js +2 -0
- package/lib/topic/TopicMessageChunk.js.map +1 -0
- package/lib/topic/TopicMessageQuery.cjs +450 -0
- package/lib/topic/TopicMessageQuery.d.ts +220 -0
- package/lib/topic/TopicMessageQuery.js +2 -0
- package/lib/topic/TopicMessageQuery.js.map +1 -0
- package/lib/topic/TopicMessageSubmitTransaction.cjs +412 -0
- package/lib/topic/TopicMessageSubmitTransaction.d.ts +201 -0
- package/lib/topic/TopicMessageSubmitTransaction.js +2 -0
- package/lib/topic/TopicMessageSubmitTransaction.js.map +1 -0
- package/lib/topic/TopicUpdateTransaction.cjs +532 -0
- package/lib/topic/TopicUpdateTransaction.d.ts +284 -0
- package/lib/topic/TopicUpdateTransaction.js +2 -0
- package/lib/topic/TopicUpdateTransaction.js.map +1 -0
- package/lib/transaction/BatchTransaction.cjs +262 -0
- package/lib/transaction/BatchTransaction.d.ts +134 -0
- package/lib/transaction/BatchTransaction.js +2 -0
- package/lib/transaction/BatchTransaction.js.map +1 -0
- package/lib/transaction/CustomFeeLimit.cjs +116 -0
- package/lib/transaction/CustomFeeLimit.d.ts +64 -0
- package/lib/transaction/CustomFeeLimit.js +2 -0
- package/lib/transaction/CustomFeeLimit.js.map +1 -0
- package/lib/transaction/List.cjs +177 -0
- package/lib/transaction/List.d.ts +100 -0
- package/lib/transaction/List.js +2 -0
- package/lib/transaction/List.js.map +1 -0
- package/lib/transaction/NodeAccountIdSignatureMap.cjs +62 -0
- package/lib/transaction/NodeAccountIdSignatureMap.d.ts +23 -0
- package/lib/transaction/NodeAccountIdSignatureMap.js +2 -0
- package/lib/transaction/NodeAccountIdSignatureMap.js.map +1 -0
- package/lib/transaction/NodeAccountIdSignatureMapLegacy.cjs +39 -0
- package/lib/transaction/NodeAccountIdSignatureMapLegacy.d.ts +14 -0
- package/lib/transaction/NodeAccountIdSignatureMapLegacy.js +2 -0
- package/lib/transaction/NodeAccountIdSignatureMapLegacy.js.map +1 -0
- package/lib/transaction/SignableNodeTransactionBodyBytes.cjs +47 -0
- package/lib/transaction/SignableNodeTransactionBodyBytes.d.ts +38 -0
- package/lib/transaction/SignableNodeTransactionBodyBytes.js +2 -0
- package/lib/transaction/SignableNodeTransactionBodyBytes.js.map +1 -0
- package/lib/transaction/SignatureMap.cjs +95 -0
- package/lib/transaction/SignatureMap.d.ts +42 -0
- package/lib/transaction/SignatureMap.js +2 -0
- package/lib/transaction/SignatureMap.js.map +1 -0
- package/lib/transaction/SignatureMapLegacy.cjs +37 -0
- package/lib/transaction/SignatureMapLegacy.d.ts +15 -0
- package/lib/transaction/SignatureMapLegacy.js +2 -0
- package/lib/transaction/SignatureMapLegacy.js.map +1 -0
- package/lib/transaction/SignaturePairMap.cjs +50 -0
- package/lib/transaction/SignaturePairMap.d.ts +21 -0
- package/lib/transaction/SignaturePairMap.js +2 -0
- package/lib/transaction/SignaturePairMap.js.map +1 -0
- package/lib/transaction/TokenTransfer.cjs +2 -0
- package/lib/transaction/TokenTransfer.d.ts +0 -0
- package/lib/transaction/Transaction.cjs +1959 -0
- package/lib/transaction/Transaction.d.ts +698 -0
- package/lib/transaction/Transaction.js +2 -0
- package/lib/transaction/Transaction.js.map +1 -0
- package/lib/transaction/TransactionHashMap.cjs +44 -0
- package/lib/transaction/TransactionHashMap.d.ts +22 -0
- package/lib/transaction/TransactionHashMap.js +2 -0
- package/lib/transaction/TransactionHashMap.js.map +1 -0
- package/lib/transaction/TransactionId.cjs +224 -0
- package/lib/transaction/TransactionId.d.ts +122 -0
- package/lib/transaction/TransactionId.js +2 -0
- package/lib/transaction/TransactionId.js.map +1 -0
- package/lib/transaction/TransactionReceipt.cjs +303 -0
- package/lib/transaction/TransactionReceipt.d.ts +202 -0
- package/lib/transaction/TransactionReceipt.js +2 -0
- package/lib/transaction/TransactionReceipt.js.map +1 -0
- package/lib/transaction/TransactionReceiptQuery.cjs +347 -0
- package/lib/transaction/TransactionReceiptQuery.d.ts +96 -0
- package/lib/transaction/TransactionReceiptQuery.js +2 -0
- package/lib/transaction/TransactionReceiptQuery.js.map +1 -0
- package/lib/transaction/TransactionRecord.cjs +470 -0
- package/lib/transaction/TransactionRecord.d.ts +317 -0
- package/lib/transaction/TransactionRecord.js +2 -0
- package/lib/transaction/TransactionRecord.js.map +1 -0
- package/lib/transaction/TransactionRecordQuery.cjs +366 -0
- package/lib/transaction/TransactionRecordQuery.d.ts +99 -0
- package/lib/transaction/TransactionRecordQuery.js +2 -0
- package/lib/transaction/TransactionRecordQuery.js.map +1 -0
- package/lib/transaction/TransactionResponse.cjs +242 -0
- package/lib/transaction/TransactionResponse.d.ts +119 -0
- package/lib/transaction/TransactionResponse.js +2 -0
- package/lib/transaction/TransactionResponse.js.map +1 -0
- package/lib/util/ASN1-Decoder.cjs +276 -0
- package/lib/util/ASN1-Decoder.d.ts +104 -0
- package/lib/util/ASN1-Decoder.js +2 -0
- package/lib/util/ASN1-Decoder.js.map +1 -0
- package/lib/util.cjs +464 -0
- package/lib/util.d.ts +210 -0
- package/lib/util.js +2 -0
- package/lib/util.js.map +1 -0
- package/lib/version.cjs +8 -0
- package/lib/version.d.ts +2 -0
- package/lib/version.js +2 -0
- package/lib/version.js.map +1 -0
- package/package.json +139 -0
- package/src/BadEntityIdError.js +24 -0
- package/src/Cache.js +418 -0
- package/src/Duration.js +48 -0
- package/src/EntityIdHelper.js +620 -0
- package/src/EthereumFlow.js +244 -0
- package/src/EthereumTransaction.js +298 -0
- package/src/EthereumTransactionData.js +60 -0
- package/src/EthereumTransactionDataEip1559.js +146 -0
- package/src/EthereumTransactionDataEip2930.js +140 -0
- package/src/EthereumTransactionDataLegacy.js +121 -0
- package/src/EvmAddress.js +78 -0
- package/src/ExchangeRate.js +117 -0
- package/src/ExchangeRates.js +71 -0
- package/src/Executable.js +884 -0
- package/src/FeeComponents.js +199 -0
- package/src/FeeData.js +127 -0
- package/src/FeeDataType.js +125 -0
- package/src/FeeSchedule.js +88 -0
- package/src/FeeSchedules.js +82 -0
- package/src/FreezeType.js +113 -0
- package/src/Hbar.js +147 -0
- package/src/HbarUnit.js +90 -0
- package/src/Key.js +60 -0
- package/src/KeyList.js +179 -0
- package/src/LedgerId.js +134 -0
- package/src/LocalProvider.js +165 -0
- package/src/ManagedNode.js +269 -0
- package/src/ManagedNodeAddress.js +101 -0
- package/src/MaxAttemptsOrTimeoutError.js +42 -0
- package/src/MaxQueryPaymentExceeded.js +28 -0
- package/src/MirrorNode.js +41 -0
- package/src/Mnemonic.js +250 -0
- package/src/Node.js +106 -0
- package/src/ObjectMap.js +137 -0
- package/src/PrecheckStatusError.js +73 -0
- package/src/PrivateKey.js +547 -0
- package/src/PrngTransaction.js +152 -0
- package/src/Provider.js +40 -0
- package/src/PublicKey.js +294 -0
- package/src/ReceiptStatusError.js +41 -0
- package/src/RecordStatusError.js +30 -0
- package/src/RequestType.js +920 -0
- package/src/Signer.js +46 -0
- package/src/SignerSignature.js +27 -0
- package/src/StakingInfo.js +187 -0
- package/src/Status.js +3353 -0
- package/src/StatusError.js +64 -0
- package/src/Timestamp.js +160 -0
- package/src/TransactionFeeSchedule.js +100 -0
- package/src/Transfer.js +113 -0
- package/src/Wallet.js +300 -0
- package/src/account/AccountAllowanceAdjustTransaction.js +540 -0
- package/src/account/AccountAllowanceApproveTransaction.js +569 -0
- package/src/account/AccountAllowanceDeleteTransaction.js +199 -0
- package/src/account/AccountBalance.js +160 -0
- package/src/account/AccountBalanceQuery.js +238 -0
- package/src/account/AccountCreateTransaction.js +674 -0
- package/src/account/AccountDeleteTransaction.js +221 -0
- package/src/account/AccountId.js +486 -0
- package/src/account/AccountInfo.js +433 -0
- package/src/account/AccountInfoFlow.js +106 -0
- package/src/account/AccountInfoQuery.js +187 -0
- package/src/account/AccountRecordsQuery.js +186 -0
- package/src/account/AccountUpdateTransaction.js +634 -0
- package/src/account/HbarAllowance.js +147 -0
- package/src/account/HbarTransferMap.js +48 -0
- package/src/account/LiveHash.js +79 -0
- package/src/account/LiveHashAddTransaction.js +289 -0
- package/src/account/LiveHashDeleteTransaction.js +196 -0
- package/src/account/LiveHashQuery.js +209 -0
- package/src/account/NullableTokenDecimalMap.js +19 -0
- package/src/account/ProxyStaker.js +74 -0
- package/src/account/TokenAllowance.js +152 -0
- package/src/account/TokenBalanceMap.js +23 -0
- package/src/account/TokenDecimalMap.js +19 -0
- package/src/account/TokenNftAllowance.js +217 -0
- package/src/account/TokenNftTransferMap.js +134 -0
- package/src/account/TokenRelationship.js +125 -0
- package/src/account/TokenRelationshipMap.js +59 -0
- package/src/account/TokenTransferAccountMap.js +24 -0
- package/src/account/TokenTransferMap.js +99 -0
- package/src/account/TransferTransaction.js +372 -0
- package/src/address_book/AddressBooks.js +27 -0
- package/src/address_book/Endpoint.js +141 -0
- package/src/address_book/IPv4Address.js +125 -0
- package/src/address_book/IPv4AddressPart.js +71 -0
- package/src/address_book/NodeAddress.js +319 -0
- package/src/address_book/NodeAddressBook.js +114 -0
- package/src/array.js +60 -0
- package/src/base32.js +29 -0
- package/src/browser.js +10 -0
- package/src/channel/Channel.js +340 -0
- package/src/channel/MirrorChannel.js +49 -0
- package/src/channel/NativeChannel.js +120 -0
- package/src/channel/NodeChannel.js +196 -0
- package/src/channel/NodeMirrorChannel.js +91 -0
- package/src/channel/WebChannel.js +100 -0
- package/src/client/Client.js +871 -0
- package/src/client/ManagedNetwork.js +473 -0
- package/src/client/MirrorNetwork.js +87 -0
- package/src/client/NativeClient.js +218 -0
- package/src/client/Network.js +304 -0
- package/src/client/NodeClient.js +321 -0
- package/src/client/WebClient.js +302 -0
- package/src/client/addressbooks/mainnet.js +2 -0
- package/src/client/addressbooks/previewnet.js +2 -0
- package/src/client/addressbooks/testnet.js +2 -0
- package/src/constants/ClientConstants.js +204 -0
- package/src/contract/ContractByteCodeQuery.js +178 -0
- package/src/contract/ContractCallQuery.js +382 -0
- package/src/contract/ContractCreateFlow.js +551 -0
- package/src/contract/ContractCreateTransaction.js +677 -0
- package/src/contract/ContractDeleteTransaction.js +291 -0
- package/src/contract/ContractExecuteTransaction.js +313 -0
- package/src/contract/ContractFunctionParameters.js +1759 -0
- package/src/contract/ContractFunctionResult.js +1060 -0
- package/src/contract/ContractFunctionSelector.js +1360 -0
- package/src/contract/ContractId.js +316 -0
- package/src/contract/ContractInfo.js +264 -0
- package/src/contract/ContractInfoQuery.js +190 -0
- package/src/contract/ContractLogInfo.js +83 -0
- package/src/contract/ContractNonceInfo.js +129 -0
- package/src/contract/ContractStateChange.js +77 -0
- package/src/contract/ContractUpdateTransaction.js +665 -0
- package/src/contract/DelegateContractId.js +94 -0
- package/src/contract/StorageChange.js +71 -0
- package/src/cryptography/keccak.js +419 -0
- package/src/cryptography/sha384.browser.js +13 -0
- package/src/cryptography/sha384.js +20 -0
- package/src/cryptography/sha384.native.js +19 -0
- package/src/encoding/base64.native.js +19 -0
- package/src/encoding/hex.browser.js +95 -0
- package/src/encoding/hex.js +76 -0
- package/src/encoding/hex.native.js +386 -0
- package/src/encoding/utf8.browser.js +19 -0
- package/src/encoding/utf8.js +17 -0
- package/src/encoding/utf8.native.js +20 -0
- package/src/exports.js +213 -0
- package/src/file/FileAppendTransaction.js +586 -0
- package/src/file/FileContentsQuery.js +174 -0
- package/src/file/FileCreateTransaction.js +301 -0
- package/src/file/FileDeleteTransaction.js +167 -0
- package/src/file/FileId.js +247 -0
- package/src/file/FileInfo.js +136 -0
- package/src/file/FileInfoQuery.js +186 -0
- package/src/file/FileUpdateTransaction.js +375 -0
- package/src/grpc/GrpcServiceError.js +64 -0
- package/src/grpc/GrpcStatus.js +142 -0
- package/src/http/HttpError.js +26 -0
- package/src/http/HttpStatus.js +38 -0
- package/src/index.js +11 -0
- package/src/logger/LogLevel.js +72 -0
- package/src/logger/Logger.js +225 -0
- package/src/long.js +20 -0
- package/src/native.js +10 -0
- package/src/network/AddressBookQuery.js +272 -0
- package/src/network/AddressBookQueryWeb.js +388 -0
- package/src/network/NetworkVersionInfo.js +81 -0
- package/src/network/NetworkVersionInfoQuery.js +117 -0
- package/src/network/SemanticVersion.js +74 -0
- package/src/node/NodeCreateTransaction.js +513 -0
- package/src/node/NodeDeleteTransaction.js +161 -0
- package/src/node/NodeUpdateTransaction.js +592 -0
- package/src/node/ServiceEndpoint.js +145 -0
- package/src/query/CostQuery.js +187 -0
- package/src/query/MirrorNodeContractCallQuery.js +49 -0
- package/src/query/MirrorNodeContractEstimateQuery.js +48 -0
- package/src/query/MirrorNodeContractQuery.js +266 -0
- package/src/query/Query.js +527 -0
- package/src/query/QueryBase.js +116 -0
- package/src/schedule/ScheduleCreateTransaction.js +371 -0
- package/src/schedule/ScheduleDeleteTransaction.js +174 -0
- package/src/schedule/ScheduleId.js +173 -0
- package/src/schedule/ScheduleInfo.js +243 -0
- package/src/schedule/ScheduleInfoQuery.js +189 -0
- package/src/schedule/ScheduleSignTransaction.js +189 -0
- package/src/system/FreezeTransaction.js +390 -0
- package/src/system/SystemDeleteTransaction.js +239 -0
- package/src/system/SystemUndeleteTransaction.js +207 -0
- package/src/token/AbstractTokenTransferTransaction.js +589 -0
- package/src/token/AirdropPendingTransaction.js +58 -0
- package/src/token/AssessedCustomFee.js +198 -0
- package/src/token/CustomFee.js +87 -0
- package/src/token/CustomFixedFee.js +178 -0
- package/src/token/CustomFractionalFee.js +226 -0
- package/src/token/CustomRoyaltyFee.js +173 -0
- package/src/token/FeeAssessmentMethod.js +53 -0
- package/src/token/NftId.js +95 -0
- package/src/token/PendingAirdropId.js +157 -0
- package/src/token/PendingAirdropRecord.js +50 -0
- package/src/token/TokenAirdropTransaction.js +220 -0
- package/src/token/TokenAssociateTransaction.js +214 -0
- package/src/token/TokenAssociation.js +127 -0
- package/src/token/TokenBurnTransaction.js +229 -0
- package/src/token/TokenCancelAirdropTransaction.js +120 -0
- package/src/token/TokenClaimAirdropTransaction.js +121 -0
- package/src/token/TokenCreateTransaction.js +978 -0
- package/src/token/TokenDeleteTransaction.js +161 -0
- package/src/token/TokenDissociateTransaction.js +214 -0
- package/src/token/TokenFeeScheduleUpdateTransaction.js +198 -0
- package/src/token/TokenFreezeTransaction.js +203 -0
- package/src/token/TokenGrantKycTransaction.js +203 -0
- package/src/token/TokenId.js +203 -0
- package/src/token/TokenInfo.js +454 -0
- package/src/token/TokenInfoQuery.js +185 -0
- package/src/token/TokenKeyValidation.js +70 -0
- package/src/token/TokenMintTransaction.js +258 -0
- package/src/token/TokenNftInfo.js +135 -0
- package/src/token/TokenNftInfoQuery.js +369 -0
- package/src/token/TokenNftTransfer.js +115 -0
- package/src/token/TokenNftsUpdateTransaction.js +220 -0
- package/src/token/TokenPauseTransaction.js +161 -0
- package/src/token/TokenReference.js +40 -0
- package/src/token/TokenRejectFlow.js +261 -0
- package/src/token/TokenRejectTransaction.js +262 -0
- package/src/token/TokenRevokeKycTransaction.js +203 -0
- package/src/token/TokenSupplyType.js +74 -0
- package/src/token/TokenTransfer.js +142 -0
- package/src/token/TokenType.js +74 -0
- package/src/token/TokenUnfreezeTransaction.js +203 -0
- package/src/token/TokenUnpauseTransaction.js +161 -0
- package/src/token/TokenUpdateNftsTransaction.js +225 -0
- package/src/token/TokenUpdateTransaction.js +827 -0
- package/src/token/TokenWipeTransaction.js +271 -0
- package/src/topic/SubscriptionHandle.js +34 -0
- package/src/topic/TopicCreateTransaction.js +557 -0
- package/src/topic/TopicDeleteTransaction.js +167 -0
- package/src/topic/TopicId.js +204 -0
- package/src/topic/TopicInfo.js +254 -0
- package/src/topic/TopicInfoQuery.js +190 -0
- package/src/topic/TopicMessage.js +170 -0
- package/src/topic/TopicMessageChunk.js +76 -0
- package/src/topic/TopicMessageQuery.js +523 -0
- package/src/topic/TopicMessageSubmitTransaction.js +488 -0
- package/src/topic/TopicUpdateTransaction.js +659 -0
- package/src/transaction/BatchTransaction.js +293 -0
- package/src/transaction/CustomFeeLimit.js +121 -0
- package/src/transaction/List.js +175 -0
- package/src/transaction/NodeAccountIdSignatureMap.js +62 -0
- package/src/transaction/NodeAccountIdSignatureMapLegacy.js +41 -0
- package/src/transaction/SignableNodeTransactionBodyBytes.js +40 -0
- package/src/transaction/SignatureMap.js +104 -0
- package/src/transaction/SignatureMapLegacy.js +37 -0
- package/src/transaction/SignaturePairMap.js +53 -0
- package/src/transaction/TokenTransfer.js +1 -0
- package/src/transaction/Transaction.js +2295 -0
- package/src/transaction/TransactionHashMap.js +41 -0
- package/src/transaction/TransactionId.js +262 -0
- package/src/transaction/TransactionReceipt.js +414 -0
- package/src/transaction/TransactionReceiptQuery.js +418 -0
- package/src/transaction/TransactionRecord.js +638 -0
- package/src/transaction/TransactionRecordQuery.js +440 -0
- package/src/transaction/TransactionResponse.js +283 -0
- package/src/types.d.ts +5 -0
- package/src/util/ASN1-Decoder.js +256 -0
- package/src/util.js +479 -0
- package/src/version.js +3 -0
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @namespace proto
|
|
3
|
+
* @typedef {import("@hashgraph/proto").proto.ITransaction} HieroProto.proto.ITransaction
|
|
4
|
+
* @typedef {import("@hashgraph/proto").proto.ISignedTransaction} HieroProto.proto.ISignedTransaction
|
|
5
|
+
* @typedef {import("@hashgraph/proto").proto.TransactionBody} HieroProto.proto.TransactionBody
|
|
6
|
+
* @typedef {import("@hashgraph/proto").proto.ITransactionBody} HieroProto.proto.ITransactionBody
|
|
7
|
+
* @typedef {import("@hashgraph/proto").proto.ITransactionResponse} HieroProto.proto.ITransactionResponse
|
|
8
|
+
* @typedef {import("@hashgraph/proto").proto.ICryptoUpdateTransactionBody} HieroProto.proto.ICryptoUpdateTransactionBody
|
|
9
|
+
* @typedef {import("@hashgraph/proto").proto.IAccountID} HieroProto.proto.IAccountID
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* @typedef {import("../channel/Channel.js").default} Channel
|
|
13
|
+
* @typedef {import("../client/Client.js").default<*, *>} Client
|
|
14
|
+
* @typedef {import("../transaction/TransactionId.js").default} TransactionId
|
|
15
|
+
*/
|
|
16
|
+
/**
|
|
17
|
+
* Change properties for the given account.
|
|
18
|
+
*/
|
|
19
|
+
export default class AccountUpdateTransaction extends Transaction {
|
|
20
|
+
/**
|
|
21
|
+
* @internal
|
|
22
|
+
* @param {HieroProto.proto.ITransaction[]} transactions
|
|
23
|
+
* @param {HieroProto.proto.ISignedTransaction[]} signedTransactions
|
|
24
|
+
* @param {TransactionId[]} transactionIds
|
|
25
|
+
* @param {AccountId[]} nodeIds
|
|
26
|
+
* @param {HieroProto.proto.ITransactionBody[]} bodies
|
|
27
|
+
* @returns {AccountUpdateTransaction}
|
|
28
|
+
*/
|
|
29
|
+
static _fromProtobuf(transactions: HieroProto.proto.ITransaction[], signedTransactions: HieroProto.proto.ISignedTransaction[], transactionIds: TransactionId[], nodeIds: AccountId[], bodies: HieroProto.proto.ITransactionBody[]): AccountUpdateTransaction;
|
|
30
|
+
/**
|
|
31
|
+
* @param {object} props
|
|
32
|
+
* @param {AccountId} [props.accountId]
|
|
33
|
+
* @param {Key} [props.key]
|
|
34
|
+
* @param {?boolean} [props.receiverSignatureRequired]
|
|
35
|
+
* @param {AccountId} [props.proxyAccountId]
|
|
36
|
+
* @param {Duration | Long | number} [props.autoRenewPeriod]
|
|
37
|
+
* @param {Timestamp | Date} [props.expirationTime]
|
|
38
|
+
* @param {?string} [props.accountMemo]
|
|
39
|
+
* @param {Long | number} [props.maxAutomaticTokenAssociations]
|
|
40
|
+
* @param {Key} [props.aliasKey]
|
|
41
|
+
* @param {AccountId | string} [props.stakedAccountId]
|
|
42
|
+
* @param {Long | number} [props.stakedNodeId]
|
|
43
|
+
* @param {?boolean} [props.declineStakingReward]
|
|
44
|
+
*/
|
|
45
|
+
constructor(props?: {
|
|
46
|
+
accountId?: AccountId | undefined;
|
|
47
|
+
key?: Key | undefined;
|
|
48
|
+
receiverSignatureRequired?: boolean | null | undefined;
|
|
49
|
+
proxyAccountId?: AccountId | undefined;
|
|
50
|
+
autoRenewPeriod?: number | Long | Duration | undefined;
|
|
51
|
+
expirationTime?: Date | Timestamp | undefined;
|
|
52
|
+
accountMemo?: string | null | undefined;
|
|
53
|
+
maxAutomaticTokenAssociations?: number | Long | undefined;
|
|
54
|
+
aliasKey?: Key | undefined;
|
|
55
|
+
stakedAccountId?: string | AccountId | undefined;
|
|
56
|
+
stakedNodeId?: number | Long | undefined;
|
|
57
|
+
declineStakingReward?: boolean | null | undefined;
|
|
58
|
+
});
|
|
59
|
+
/**
|
|
60
|
+
* @private
|
|
61
|
+
* @type {?AccountId}
|
|
62
|
+
*/
|
|
63
|
+
private _accountId;
|
|
64
|
+
/**
|
|
65
|
+
* @private
|
|
66
|
+
* @type {?Key}
|
|
67
|
+
*/
|
|
68
|
+
private _key;
|
|
69
|
+
/**
|
|
70
|
+
* @private
|
|
71
|
+
* @type {?boolean}
|
|
72
|
+
*/
|
|
73
|
+
private _receiverSignatureRequired;
|
|
74
|
+
/**
|
|
75
|
+
* @private
|
|
76
|
+
* @type {?AccountId}
|
|
77
|
+
*/
|
|
78
|
+
private _proxyAccountId;
|
|
79
|
+
/**
|
|
80
|
+
* @private
|
|
81
|
+
* @type {?Duration}
|
|
82
|
+
*/
|
|
83
|
+
private _autoRenewPeriod;
|
|
84
|
+
/**
|
|
85
|
+
* @private
|
|
86
|
+
* @type {?Timestamp}
|
|
87
|
+
*/
|
|
88
|
+
private _expirationTime;
|
|
89
|
+
/**
|
|
90
|
+
* @private
|
|
91
|
+
* @type {?string}
|
|
92
|
+
*/
|
|
93
|
+
private _accountMemo;
|
|
94
|
+
/**
|
|
95
|
+
* @private
|
|
96
|
+
* @type {?Long}
|
|
97
|
+
*/
|
|
98
|
+
private _maxAutomaticTokenAssociations;
|
|
99
|
+
/**
|
|
100
|
+
* @private
|
|
101
|
+
* @type {?Key}
|
|
102
|
+
*/
|
|
103
|
+
private _aliasKey;
|
|
104
|
+
/**
|
|
105
|
+
* @private
|
|
106
|
+
* @type {?AccountId}
|
|
107
|
+
*/
|
|
108
|
+
private _stakedAccountId;
|
|
109
|
+
/**
|
|
110
|
+
* @private
|
|
111
|
+
* @type {?Long}
|
|
112
|
+
*/
|
|
113
|
+
private _stakedNodeId;
|
|
114
|
+
/**
|
|
115
|
+
* @private
|
|
116
|
+
* @type {?boolean}
|
|
117
|
+
*/
|
|
118
|
+
private _declineStakingReward;
|
|
119
|
+
/**
|
|
120
|
+
* @returns {?AccountId}
|
|
121
|
+
*/
|
|
122
|
+
get accountId(): AccountId | null;
|
|
123
|
+
/**
|
|
124
|
+
* Sets the account ID which is being updated in this transaction.
|
|
125
|
+
*
|
|
126
|
+
* @param {AccountId | string} accountId
|
|
127
|
+
* @returns {AccountUpdateTransaction}
|
|
128
|
+
*/
|
|
129
|
+
setAccountId(accountId: AccountId | string): AccountUpdateTransaction;
|
|
130
|
+
/**
|
|
131
|
+
* @returns {?Key}
|
|
132
|
+
*/
|
|
133
|
+
get key(): Key | null;
|
|
134
|
+
/**
|
|
135
|
+
* @param {Key} key
|
|
136
|
+
* @returns {this}
|
|
137
|
+
*/
|
|
138
|
+
setKey(key: Key): this;
|
|
139
|
+
/**
|
|
140
|
+
* @returns {?boolean}
|
|
141
|
+
*/
|
|
142
|
+
get receiverSignatureRequired(): boolean | null;
|
|
143
|
+
/**
|
|
144
|
+
* @param {boolean} receiverSignatureRequired
|
|
145
|
+
* @returns {this}
|
|
146
|
+
*/
|
|
147
|
+
setReceiverSignatureRequired(receiverSignatureRequired: boolean): this;
|
|
148
|
+
/**
|
|
149
|
+
* @deprecated
|
|
150
|
+
* @returns {?AccountId}
|
|
151
|
+
*/
|
|
152
|
+
get proxyAccountId(): AccountId | null;
|
|
153
|
+
/**
|
|
154
|
+
* @deprecated
|
|
155
|
+
* @param {AccountId} proxyAccountId
|
|
156
|
+
* @returns {this}
|
|
157
|
+
*/
|
|
158
|
+
setProxyAccountId(proxyAccountId: AccountId): this;
|
|
159
|
+
/**
|
|
160
|
+
* @returns {?Duration}
|
|
161
|
+
*/
|
|
162
|
+
get autoRenewPeriod(): Duration | null;
|
|
163
|
+
/**
|
|
164
|
+
* @param {Duration | Long | number} autoRenewPeriod
|
|
165
|
+
* @returns {this}
|
|
166
|
+
*/
|
|
167
|
+
setAutoRenewPeriod(autoRenewPeriod: Duration | Long | number): this;
|
|
168
|
+
/**
|
|
169
|
+
* @returns {?Timestamp}
|
|
170
|
+
*/
|
|
171
|
+
get expirationTime(): Timestamp | null;
|
|
172
|
+
/**
|
|
173
|
+
* @param {Timestamp | Date} expirationTime
|
|
174
|
+
* @returns {this}
|
|
175
|
+
*/
|
|
176
|
+
setExpirationTime(expirationTime: Timestamp | Date): this;
|
|
177
|
+
/**
|
|
178
|
+
* @returns {?string}
|
|
179
|
+
*/
|
|
180
|
+
get accountMemo(): string | null;
|
|
181
|
+
/**
|
|
182
|
+
* @param {string} memo
|
|
183
|
+
* @returns {this}
|
|
184
|
+
*/
|
|
185
|
+
setAccountMemo(memo: string): this;
|
|
186
|
+
/**
|
|
187
|
+
* @returns {this}
|
|
188
|
+
*/
|
|
189
|
+
clearAccountMemo(): this;
|
|
190
|
+
/**
|
|
191
|
+
* @returns {?Long}
|
|
192
|
+
*/
|
|
193
|
+
get maxAutomaticTokenAssociations(): Long | null;
|
|
194
|
+
/**
|
|
195
|
+
* @param {Long | number} maxAutomaticTokenAssociations
|
|
196
|
+
* @returns {this}
|
|
197
|
+
*/
|
|
198
|
+
setMaxAutomaticTokenAssociations(maxAutomaticTokenAssociations: Long | number): this;
|
|
199
|
+
/**
|
|
200
|
+
* @deprecated - no longer supported
|
|
201
|
+
* @returns {?Key}
|
|
202
|
+
*/
|
|
203
|
+
get aliasKey(): Key | null;
|
|
204
|
+
/**
|
|
205
|
+
* @deprecated - no longer supported
|
|
206
|
+
* @param {Key} _
|
|
207
|
+
* @returns {this}
|
|
208
|
+
*/
|
|
209
|
+
setAliasKey(_: Key): this;
|
|
210
|
+
/**
|
|
211
|
+
* @returns {?AccountId}
|
|
212
|
+
*/
|
|
213
|
+
get stakedAccountId(): AccountId | null;
|
|
214
|
+
/**
|
|
215
|
+
* @param {AccountId | string} stakedAccountId
|
|
216
|
+
* @returns {this}
|
|
217
|
+
*/
|
|
218
|
+
setStakedAccountId(stakedAccountId: AccountId | string): this;
|
|
219
|
+
/**
|
|
220
|
+
* @returns {this}
|
|
221
|
+
*/
|
|
222
|
+
clearStakedAccountId(): this;
|
|
223
|
+
/**
|
|
224
|
+
* @returns {?Long}
|
|
225
|
+
*/
|
|
226
|
+
get stakedNodeId(): Long | null;
|
|
227
|
+
/**
|
|
228
|
+
* @param {Long | number} stakedNodeId
|
|
229
|
+
* @returns {this}
|
|
230
|
+
*/
|
|
231
|
+
setStakedNodeId(stakedNodeId: Long | number): this;
|
|
232
|
+
/**
|
|
233
|
+
* @returns {this}
|
|
234
|
+
*/
|
|
235
|
+
clearStakedNodeId(): this;
|
|
236
|
+
/**
|
|
237
|
+
* @returns {?boolean}
|
|
238
|
+
*/
|
|
239
|
+
get declineStakingRewards(): boolean | null;
|
|
240
|
+
/**
|
|
241
|
+
* @param {boolean} declineStakingReward
|
|
242
|
+
* @returns {this}
|
|
243
|
+
*/
|
|
244
|
+
setDeclineStakingReward(declineStakingReward: boolean): this;
|
|
245
|
+
/**
|
|
246
|
+
* @override
|
|
247
|
+
* @protected
|
|
248
|
+
* @returns {HieroProto.proto.ICryptoUpdateTransactionBody}
|
|
249
|
+
*/
|
|
250
|
+
protected override _makeTransactionData(): HieroProto.proto.ICryptoUpdateTransactionBody;
|
|
251
|
+
}
|
|
252
|
+
export namespace HieroProto {
|
|
253
|
+
namespace proto {
|
|
254
|
+
type ITransaction = import("@hashgraph/proto").proto.ITransaction;
|
|
255
|
+
type ISignedTransaction = import("@hashgraph/proto").proto.ISignedTransaction;
|
|
256
|
+
type TransactionBody = import("@hashgraph/proto").proto.TransactionBody;
|
|
257
|
+
type ITransactionBody = import("@hashgraph/proto").proto.ITransactionBody;
|
|
258
|
+
type ITransactionResponse = import("@hashgraph/proto").proto.ITransactionResponse;
|
|
259
|
+
type ICryptoUpdateTransactionBody = import("@hashgraph/proto").proto.ICryptoUpdateTransactionBody;
|
|
260
|
+
type IAccountID = import("@hashgraph/proto").proto.IAccountID;
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
export type Channel = import("../channel/Channel.js").default;
|
|
264
|
+
export type Client = import("../client/Client.js").default<any, any>;
|
|
265
|
+
export type TransactionId = import("../transaction/TransactionId.js").default;
|
|
266
|
+
import Transaction from "../transaction/Transaction.js";
|
|
267
|
+
import AccountId from "./AccountId.js";
|
|
268
|
+
import Key from "../Key.js";
|
|
269
|
+
import Duration from "../Duration.js";
|
|
270
|
+
import Long from "long";
|
|
271
|
+
import Timestamp from "../Timestamp.js";
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import e,{TRANSACTION_REGISTRY as t}from"../transaction/Transaction.js";import o from"./AccountId.js";import i from"../Timestamp.js";import n from"../Duration.js";import r from"long";import u from"../Key.js";class s extends e{constructor(e={}){super(),this._accountId=null,this._key=null,this._receiverSignatureRequired=null,this._proxyAccountId=null,this._autoRenewPeriod=null,this._expirationTime=null,this._accountMemo=null,this._maxAutomaticTokenAssociations=null,this._aliasKey=null,this._stakedAccountId=null,this._stakedNodeId=null,this._declineStakingReward=null,null!=e.accountId&&this.setAccountId(e.accountId),null!=e.key&&this.setKey(e.key),null!=e.receiverSignatureRequired&&this.setReceiverSignatureRequired(e.receiverSignatureRequired),null!=e.proxyAccountId&&this.setProxyAccountId(e.proxyAccountId),null!=e.autoRenewPeriod&&this.setAutoRenewPeriod(e.autoRenewPeriod),null!=e.expirationTime&&this.setExpirationTime(e.expirationTime),null!=e.accountMemo&&this.setAccountMemo(e.accountMemo),null!=e.maxAutomaticTokenAssociations&&this.setMaxAutomaticTokenAssociations(e.maxAutomaticTokenAssociations),null!=e.stakedAccountId&&this.setStakedAccountId(e.stakedAccountId),null!=e.stakedNodeId&&this.setStakedNodeId(e.stakedNodeId),null!=e.declineStakingReward&&this.setDeclineStakingReward(e.declineStakingReward)}static _fromProtobuf(t,n,a,c,d){const l=d[0].cryptoUpdateAccount;return e._fromProtobufTransactions(new s({accountId:null!=l.accountIDToUpdate?o._fromProtobuf(l.accountIDToUpdate):void 0,key:null!=l.key?u._fromProtobufKey(l.key):void 0,receiverSignatureRequired:null!=l.receiverSigRequiredWrapper&&Object.hasOwn(l.receiverSigRequiredWrapper,"value")?l.receiverSigRequiredWrapper.value:void 0,proxyAccountId:null!=l.proxyAccountID?o._fromProtobuf(l.proxyAccountID):void 0,autoRenewPeriod:null!=l.autoRenewPeriod&&null!=l.autoRenewPeriod.seconds?l.autoRenewPeriod.seconds:void 0,expirationTime:null!=l.expirationTime?i._fromProtobuf(l.expirationTime):void 0,accountMemo:null!=l.memo&&Object.hasOwn(l.memo,"value")?l.memo.value:void 0,maxAutomaticTokenAssociations:null!=l.maxAutomaticTokenAssociations&&null!=l.maxAutomaticTokenAssociations.value&&Object.hasOwn(l.maxAutomaticTokenAssociations,"value")?r.fromNumber(l.maxAutomaticTokenAssociations.value):void 0,stakedAccountId:null!=l.stakedAccountId?o._fromProtobuf(l.stakedAccountId):void 0,stakedNodeId:null!=l.stakedNodeId?l.stakedNodeId:void 0,declineStakingReward:null!=l.declineReward&&Object.hasOwn(l.declineReward,"value")?l.declineReward.value:void 0}),t,n,a,c,d)}get accountId(){return this._accountId}setAccountId(e){return this._requireNotFrozen(),this._accountId="string"==typeof e?o.fromString(e):e.clone(),this}get key(){return this._key}setKey(e){return this._requireNotFrozen(),this._key=e,this}get receiverSignatureRequired(){return this._receiverSignatureRequired}setReceiverSignatureRequired(e){return this._requireNotFrozen(),this._receiverSignatureRequired=e,this}get proxyAccountId(){return this._proxyAccountId}setProxyAccountId(e){return this._requireNotFrozen(),this._proxyAccountId=e,this}get autoRenewPeriod(){return this._autoRenewPeriod}setAutoRenewPeriod(e){return this._requireNotFrozen(),this._autoRenewPeriod=e instanceof n?e:new n(e),this}get expirationTime(){return this._expirationTime}setExpirationTime(e){return this._requireNotFrozen(),this._expirationTime=e instanceof Date?i.fromDate(e):e,this}get accountMemo(){return this._accountMemo}setAccountMemo(e){return this._requireNotFrozen(),this._accountMemo=e,this}clearAccountMemo(){return this._requireNotFrozen(),this._accountMemo=null,this}get maxAutomaticTokenAssociations(){return this._maxAutomaticTokenAssociations}setMaxAutomaticTokenAssociations(e){return this._requireNotFrozen(),this._maxAutomaticTokenAssociations="number"==typeof e?r.fromNumber(e):e,this}get aliasKey(){return null}setAliasKey(e){return this}get stakedAccountId(){return this._stakedAccountId}setStakedAccountId(e){return this._requireNotFrozen(),this._stakedAccountId="string"==typeof e?o.fromString(e):e,this}clearStakedAccountId(){return this._requireNotFrozen(),this._stakedAccountId=new o(0,0,0),this}get stakedNodeId(){return this._stakedNodeId}setStakedNodeId(e){return this._requireNotFrozen(),this._stakedNodeId=r.fromValue(e),this}clearStakedNodeId(){return this._requireNotFrozen(),this._stakedNodeId=r.fromNumber(-1),this}get declineStakingRewards(){return this._declineStakingReward}setDeclineStakingReward(e){return this._requireNotFrozen(),this._declineStakingReward=e,this}_validateChecksums(e){null!=this._accountId&&this._accountId.validateChecksum(e),null!=this._proxyAccountId&&this._proxyAccountId.validateChecksum(e)}_execute(e,t){return e.crypto.updateAccount(t)}_getTransactionDataCase(){return"cryptoUpdateAccount"}_makeTransactionData(){return{accountIDToUpdate:null!=this._accountId?this._accountId._toProtobuf():null,key:null!=this._key?this._key._toProtobufKey():null,expirationTime:null!=this._expirationTime?this._expirationTime._toProtobuf():null,proxyAccountID:null!=this._proxyAccountId?this._proxyAccountId._toProtobuf():null,autoRenewPeriod:null!=this._autoRenewPeriod?this._autoRenewPeriod._toProtobuf():null,receiverSigRequiredWrapper:null==this._receiverSignatureRequired?null:{value:this._receiverSignatureRequired},memo:null!=this._accountMemo?{value:this._accountMemo}:null,maxAutomaticTokenAssociations:null!=this._maxAutomaticTokenAssociations?{value:this._maxAutomaticTokenAssociations.toInt()}:null,stakedAccountId:null!=this.stakedAccountId?this.stakedAccountId._toProtobuf():null,stakedNodeId:this.stakedNodeId,declineReward:null!=this.declineStakingRewards?{value:this.declineStakingRewards}:null}}_getLogId(){return`AccountUpdateTransaction:${this._transactionIds.current.validStart.toString()}`}}t.set("cryptoUpdateAccount",s._fromProtobuf);export{s as default};
|
|
2
|
+
//# sourceMappingURL=AccountUpdateTransaction.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AccountUpdateTransaction.js","sources":["../../src/account/AccountUpdateTransaction.js"],"sourcesContent":["// SPDX-License-Identifier: Apache-2.0\n\nimport Transaction, {\n TRANSACTION_REGISTRY,\n} from \"../transaction/Transaction.js\";\nimport AccountId from \"./AccountId.js\";\nimport Timestamp from \"../Timestamp.js\";\nimport Duration from \"../Duration.js\";\nimport Long from \"long\";\nimport Key from \"../Key.js\";\n\n/**\n * @namespace proto\n * @typedef {import(\"@hashgraph/proto\").proto.ITransaction} HieroProto.proto.ITransaction\n * @typedef {import(\"@hashgraph/proto\").proto.ISignedTransaction} HieroProto.proto.ISignedTransaction\n * @typedef {import(\"@hashgraph/proto\").proto.TransactionBody} HieroProto.proto.TransactionBody\n * @typedef {import(\"@hashgraph/proto\").proto.ITransactionBody} HieroProto.proto.ITransactionBody\n * @typedef {import(\"@hashgraph/proto\").proto.ITransactionResponse} HieroProto.proto.ITransactionResponse\n * @typedef {import(\"@hashgraph/proto\").proto.ICryptoUpdateTransactionBody} HieroProto.proto.ICryptoUpdateTransactionBody\n * @typedef {import(\"@hashgraph/proto\").proto.IAccountID} HieroProto.proto.IAccountID\n */\n\n/**\n * @typedef {import(\"../channel/Channel.js\").default} Channel\n * @typedef {import(\"../client/Client.js\").default<*, *>} Client\n * @typedef {import(\"../transaction/TransactionId.js\").default} TransactionId\n */\n\n/**\n * Change properties for the given account.\n */\nexport default class AccountUpdateTransaction extends Transaction {\n /**\n * @param {object} props\n * @param {AccountId} [props.accountId]\n * @param {Key} [props.key]\n * @param {?boolean} [props.receiverSignatureRequired]\n * @param {AccountId} [props.proxyAccountId]\n * @param {Duration | Long | number} [props.autoRenewPeriod]\n * @param {Timestamp | Date} [props.expirationTime]\n * @param {?string} [props.accountMemo]\n * @param {Long | number} [props.maxAutomaticTokenAssociations]\n * @param {Key} [props.aliasKey]\n * @param {AccountId | string} [props.stakedAccountId]\n * @param {Long | number} [props.stakedNodeId]\n * @param {?boolean} [props.declineStakingReward]\n */\n constructor(props = {}) {\n super();\n\n /**\n * @private\n * @type {?AccountId}\n */\n this._accountId = null;\n\n /**\n * @private\n * @type {?Key}\n */\n this._key = null;\n\n /**\n * @private\n * @type {?boolean}\n */\n this._receiverSignatureRequired = null;\n\n /**\n * @private\n * @type {?AccountId}\n */\n this._proxyAccountId = null;\n\n /**\n * @private\n * @type {?Duration}\n */\n this._autoRenewPeriod = null;\n\n /**\n * @private\n * @type {?Timestamp}\n */\n this._expirationTime = null;\n\n /**\n * @private\n * @type {?string}\n */\n this._accountMemo = null;\n\n /**\n * @private\n * @type {?Long}\n */\n this._maxAutomaticTokenAssociations = null;\n\n /**\n * @private\n * @type {?Key}\n */\n this._aliasKey = null;\n\n /**\n * @private\n * @type {?AccountId}\n */\n this._stakedAccountId = null;\n\n /**\n * @private\n * @type {?Long}\n */\n this._stakedNodeId = null;\n\n /**\n * @private\n * @type {?boolean}\n */\n this._declineStakingReward = null;\n\n if (props.accountId != null) {\n this.setAccountId(props.accountId);\n }\n\n if (props.key != null) {\n this.setKey(props.key);\n }\n\n if (props.receiverSignatureRequired != null) {\n this.setReceiverSignatureRequired(props.receiverSignatureRequired);\n }\n\n if (props.proxyAccountId != null) {\n // eslint-disable-next-line deprecation/deprecation\n this.setProxyAccountId(props.proxyAccountId);\n }\n\n if (props.autoRenewPeriod != null) {\n this.setAutoRenewPeriod(props.autoRenewPeriod);\n }\n\n if (props.expirationTime != null) {\n this.setExpirationTime(props.expirationTime);\n }\n\n if (props.accountMemo != null) {\n this.setAccountMemo(props.accountMemo);\n }\n\n if (props.maxAutomaticTokenAssociations != null) {\n this.setMaxAutomaticTokenAssociations(\n props.maxAutomaticTokenAssociations,\n );\n }\n\n if (props.stakedAccountId != null) {\n this.setStakedAccountId(props.stakedAccountId);\n }\n\n if (props.stakedNodeId != null) {\n this.setStakedNodeId(props.stakedNodeId);\n }\n\n if (props.declineStakingReward != null) {\n this.setDeclineStakingReward(props.declineStakingReward);\n }\n }\n\n /**\n * @internal\n * @param {HieroProto.proto.ITransaction[]} transactions\n * @param {HieroProto.proto.ISignedTransaction[]} signedTransactions\n * @param {TransactionId[]} transactionIds\n * @param {AccountId[]} nodeIds\n * @param {HieroProto.proto.ITransactionBody[]} bodies\n * @returns {AccountUpdateTransaction}\n */\n static _fromProtobuf(\n transactions,\n signedTransactions,\n transactionIds,\n nodeIds,\n bodies,\n ) {\n const body = bodies[0];\n const update =\n /** @type {HieroProto.proto.ICryptoUpdateTransactionBody} */ (\n body.cryptoUpdateAccount\n );\n\n return Transaction._fromProtobufTransactions(\n new AccountUpdateTransaction({\n accountId:\n update.accountIDToUpdate != null\n ? AccountId._fromProtobuf(\n /** @type {HieroProto.proto.IAccountID} */ (\n update.accountIDToUpdate\n ),\n )\n : undefined,\n key:\n update.key != null\n ? Key._fromProtobufKey(update.key)\n : undefined,\n receiverSignatureRequired:\n update.receiverSigRequiredWrapper != null\n ? Object.hasOwn(\n update.receiverSigRequiredWrapper,\n \"value\",\n )\n ? update.receiverSigRequiredWrapper.value\n : undefined\n : undefined,\n proxyAccountId:\n update.proxyAccountID != null\n ? AccountId._fromProtobuf(\n /** @type {HieroProto.proto.IAccountID} */ (\n update.proxyAccountID\n ),\n )\n : undefined,\n autoRenewPeriod:\n update.autoRenewPeriod != null\n ? update.autoRenewPeriod.seconds != null\n ? update.autoRenewPeriod.seconds\n : undefined\n : undefined,\n expirationTime:\n update.expirationTime != null\n ? Timestamp._fromProtobuf(update.expirationTime)\n : undefined,\n accountMemo:\n update.memo != null\n ? Object.hasOwn(update.memo, \"value\")\n ? update.memo.value\n : undefined\n : undefined,\n maxAutomaticTokenAssociations:\n update.maxAutomaticTokenAssociations != null &&\n update.maxAutomaticTokenAssociations.value != null &&\n Object.hasOwn(update.maxAutomaticTokenAssociations, \"value\")\n ? Long.fromNumber(\n update.maxAutomaticTokenAssociations.value,\n )\n : undefined,\n stakedAccountId:\n update.stakedAccountId != null\n ? AccountId._fromProtobuf(update.stakedAccountId)\n : undefined,\n stakedNodeId:\n update.stakedNodeId != null\n ? update.stakedNodeId\n : undefined,\n declineStakingReward:\n update.declineReward != null\n ? Object.hasOwn(update.declineReward, \"value\")\n ? update.declineReward.value\n : undefined\n : undefined,\n }),\n transactions,\n signedTransactions,\n transactionIds,\n nodeIds,\n bodies,\n );\n }\n\n /**\n * @returns {?AccountId}\n */\n get accountId() {\n return this._accountId;\n }\n\n /**\n * Sets the account ID which is being updated in this transaction.\n *\n * @param {AccountId | string} accountId\n * @returns {AccountUpdateTransaction}\n */\n setAccountId(accountId) {\n this._requireNotFrozen();\n this._accountId =\n typeof accountId === \"string\"\n ? AccountId.fromString(accountId)\n : accountId.clone();\n\n return this;\n }\n\n /**\n * @returns {?Key}\n */\n get key() {\n return this._key;\n }\n\n /**\n * @param {Key} key\n * @returns {this}\n */\n setKey(key) {\n this._requireNotFrozen();\n this._key = key;\n\n return this;\n }\n\n /**\n * @returns {?boolean}\n */\n get receiverSignatureRequired() {\n return this._receiverSignatureRequired;\n }\n\n /**\n * @param {boolean} receiverSignatureRequired\n * @returns {this}\n */\n setReceiverSignatureRequired(receiverSignatureRequired) {\n this._requireNotFrozen();\n this._receiverSignatureRequired = receiverSignatureRequired;\n\n return this;\n }\n\n /**\n * @deprecated\n * @returns {?AccountId}\n */\n get proxyAccountId() {\n return this._proxyAccountId;\n }\n\n /**\n * @deprecated\n * @param {AccountId} proxyAccountId\n * @returns {this}\n */\n setProxyAccountId(proxyAccountId) {\n this._requireNotFrozen();\n this._proxyAccountId = proxyAccountId;\n\n return this;\n }\n\n /**\n * @returns {?Duration}\n */\n get autoRenewPeriod() {\n return this._autoRenewPeriod;\n }\n\n /**\n * @param {Duration | Long | number} autoRenewPeriod\n * @returns {this}\n */\n setAutoRenewPeriod(autoRenewPeriod) {\n this._requireNotFrozen();\n this._autoRenewPeriod =\n autoRenewPeriod instanceof Duration\n ? autoRenewPeriod\n : new Duration(autoRenewPeriod);\n\n return this;\n }\n\n /**\n * @returns {?Timestamp}\n */\n get expirationTime() {\n return this._expirationTime;\n }\n\n /**\n * @param {Timestamp | Date} expirationTime\n * @returns {this}\n */\n setExpirationTime(expirationTime) {\n this._requireNotFrozen();\n this._expirationTime =\n expirationTime instanceof Date\n ? Timestamp.fromDate(expirationTime)\n : expirationTime;\n\n return this;\n }\n\n /**\n * @returns {?string}\n */\n get accountMemo() {\n return this._accountMemo;\n }\n\n /**\n * @param {string} memo\n * @returns {this}\n */\n setAccountMemo(memo) {\n this._requireNotFrozen();\n this._accountMemo = memo;\n\n return this;\n }\n\n /**\n * @returns {this}\n */\n clearAccountMemo() {\n this._requireNotFrozen();\n this._accountMemo = null;\n\n return this;\n }\n\n /**\n * @returns {?Long}\n */\n get maxAutomaticTokenAssociations() {\n return this._maxAutomaticTokenAssociations;\n }\n\n /**\n * @param {Long | number} maxAutomaticTokenAssociations\n * @returns {this}\n */\n setMaxAutomaticTokenAssociations(maxAutomaticTokenAssociations) {\n this._requireNotFrozen();\n this._maxAutomaticTokenAssociations =\n typeof maxAutomaticTokenAssociations === \"number\"\n ? Long.fromNumber(maxAutomaticTokenAssociations)\n : maxAutomaticTokenAssociations;\n\n return this;\n }\n\n /**\n * @deprecated - no longer supported\n * @returns {?Key}\n */\n get aliasKey() {\n return null;\n }\n\n /**\n * @deprecated - no longer supported\n * @param {Key} _\n * @returns {this}\n */\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n setAliasKey(_) {\n return this;\n }\n\n /**\n * @returns {?AccountId}\n */\n get stakedAccountId() {\n return this._stakedAccountId;\n }\n\n /**\n * @param {AccountId | string} stakedAccountId\n * @returns {this}\n */\n setStakedAccountId(stakedAccountId) {\n this._requireNotFrozen();\n this._stakedAccountId =\n typeof stakedAccountId === \"string\"\n ? AccountId.fromString(stakedAccountId)\n : stakedAccountId;\n\n return this;\n }\n\n /**\n * @returns {this}\n */\n clearStakedAccountId() {\n this._requireNotFrozen();\n this._stakedAccountId = new AccountId(0, 0, 0);\n\n return this;\n }\n\n /**\n * @returns {?Long}\n */\n get stakedNodeId() {\n return this._stakedNodeId;\n }\n\n /**\n * @param {Long | number} stakedNodeId\n * @returns {this}\n */\n setStakedNodeId(stakedNodeId) {\n this._requireNotFrozen();\n this._stakedNodeId = Long.fromValue(stakedNodeId);\n\n return this;\n }\n\n /**\n * @returns {this}\n */\n clearStakedNodeId() {\n this._requireNotFrozen();\n this._stakedNodeId = Long.fromNumber(-1);\n\n return this;\n }\n\n /**\n * @returns {?boolean}\n */\n get declineStakingRewards() {\n return this._declineStakingReward;\n }\n\n /**\n * @param {boolean} declineStakingReward\n * @returns {this}\n */\n setDeclineStakingReward(declineStakingReward) {\n this._requireNotFrozen();\n this._declineStakingReward = declineStakingReward;\n\n return this;\n }\n\n /**\n * @param {Client} client\n */\n _validateChecksums(client) {\n if (this._accountId != null) {\n this._accountId.validateChecksum(client);\n }\n\n if (this._proxyAccountId != null) {\n this._proxyAccountId.validateChecksum(client);\n }\n }\n\n /**\n * @override\n * @internal\n * @param {Channel} channel\n * @param {HieroProto.proto.ITransaction} request\n * @returns {Promise<HieroProto.proto.ITransactionResponse>}\n */\n _execute(channel, request) {\n return channel.crypto.updateAccount(request);\n }\n\n /**\n * @override\n * @protected\n * @returns {NonNullable<HieroProto.proto.TransactionBody[\"data\"]>}\n */\n _getTransactionDataCase() {\n return \"cryptoUpdateAccount\";\n }\n\n /**\n * @override\n * @protected\n * @returns {HieroProto.proto.ICryptoUpdateTransactionBody}\n */\n _makeTransactionData() {\n return {\n accountIDToUpdate:\n this._accountId != null ? this._accountId._toProtobuf() : null,\n key: this._key != null ? this._key._toProtobufKey() : null,\n expirationTime:\n this._expirationTime != null\n ? this._expirationTime._toProtobuf()\n : null,\n proxyAccountID:\n this._proxyAccountId != null\n ? this._proxyAccountId._toProtobuf()\n : null,\n autoRenewPeriod:\n this._autoRenewPeriod != null\n ? this._autoRenewPeriod._toProtobuf()\n : null,\n receiverSigRequiredWrapper:\n this._receiverSignatureRequired == null\n ? null\n : {\n value: this._receiverSignatureRequired,\n },\n memo:\n this._accountMemo != null\n ? {\n value: this._accountMemo,\n }\n : null,\n maxAutomaticTokenAssociations:\n this._maxAutomaticTokenAssociations != null\n ? { value: this._maxAutomaticTokenAssociations.toInt() }\n : null,\n stakedAccountId:\n this.stakedAccountId != null\n ? this.stakedAccountId._toProtobuf()\n : null,\n stakedNodeId: this.stakedNodeId,\n declineReward:\n this.declineStakingRewards != null\n ? { value: this.declineStakingRewards }\n : null,\n };\n }\n\n /**\n * @returns {string}\n */\n _getLogId() {\n const timestamp = /** @type {import(\"../Timestamp.js\").default} */ (\n this._transactionIds.current.validStart\n );\n return `AccountUpdateTransaction:${timestamp.toString()}`;\n }\n}\n\nTRANSACTION_REGISTRY.set(\n \"cryptoUpdateAccount\",\n // eslint-disable-next-line @typescript-eslint/unbound-method\n AccountUpdateTransaction._fromProtobuf,\n);\n"],"names":["AccountUpdateTransaction","Transaction","constructor","props","super","this","_accountId","_key","_receiverSignatureRequired","_proxyAccountId","_autoRenewPeriod","_expirationTime","_accountMemo","_maxAutomaticTokenAssociations","_aliasKey","_stakedAccountId","_stakedNodeId","_declineStakingReward","accountId","setAccountId","key","setKey","receiverSignatureRequired","setReceiverSignatureRequired","proxyAccountId","setProxyAccountId","autoRenewPeriod","setAutoRenewPeriod","expirationTime","setExpirationTime","accountMemo","setAccountMemo","maxAutomaticTokenAssociations","setMaxAutomaticTokenAssociations","stakedAccountId","setStakedAccountId","stakedNodeId","setStakedNodeId","declineStakingReward","setDeclineStakingReward","_fromProtobuf","transactions","signedTransactions","transactionIds","nodeIds","bodies","update","_fromProtobufTransactions","accountIDToUpdate","AccountId","undefined","Key","_fromProtobufKey","receiverSigRequiredWrapper","Object","hasOwn","value","proxyAccountID","seconds","Timestamp","memo","Long","fromNumber","declineReward","_requireNotFrozen","fromString","clone","Duration","Date","fromDate","clearAccountMemo","aliasKey","setAliasKey","_","clearStakedAccountId","fromValue","clearStakedNodeId","declineStakingRewards","_validateChecksums","client","validateChecksum","_execute","channel","request","crypto","updateAccount","_getTransactionDataCase","_makeTransactionData","_toProtobuf","_toProtobufKey","toInt","_getLogId","_transactionIds","current","toString","TRANSACTION_REGISTRY","set"],"mappings":"gNA+Be,MAAMA,UAAiCC,EAgBlD,WAAAC,CAAYC,EAAQ,IAChBC,QAMAC,KAAKC,WAAa,KAMlBD,KAAKE,KAAO,KAMZF,KAAKG,2BAA6B,KAMlCH,KAAKI,gBAAkB,KAMvBJ,KAAKK,iBAAmB,KAMxBL,KAAKM,gBAAkB,KAMvBN,KAAKO,aAAe,KAMpBP,KAAKQ,+BAAiC,KAMtCR,KAAKS,UAAY,KAMjBT,KAAKU,iBAAmB,KAMxBV,KAAKW,cAAgB,KAMrBX,KAAKY,sBAAwB,KAEN,MAAnBd,EAAMe,WACNb,KAAKc,aAAahB,EAAMe,WAGX,MAAbf,EAAMiB,KACNf,KAAKgB,OAAOlB,EAAMiB,KAGiB,MAAnCjB,EAAMmB,2BACNjB,KAAKkB,6BAA6BpB,EAAMmB,2BAGhB,MAAxBnB,EAAMqB,gBAENnB,KAAKoB,kBAAkBtB,EAAMqB,gBAGJ,MAAzBrB,EAAMuB,iBACNrB,KAAKsB,mBAAmBxB,EAAMuB,iBAGN,MAAxBvB,EAAMyB,gBACNvB,KAAKwB,kBAAkB1B,EAAMyB,gBAGR,MAArBzB,EAAM2B,aACNzB,KAAK0B,eAAe5B,EAAM2B,aAGa,MAAvC3B,EAAM6B,+BACN3B,KAAK4B,iCACD9B,EAAM6B,+BAIe,MAAzB7B,EAAM+B,iBACN7B,KAAK8B,mBAAmBhC,EAAM+B,iBAGR,MAAtB/B,EAAMiC,cACN/B,KAAKgC,gBAAgBlC,EAAMiC,cAGG,MAA9BjC,EAAMmC,sBACNjC,KAAKkC,wBAAwBpC,EAAMmC,qBAE/C,CAWI,oBAAOE,CACHC,EACAC,EACAC,EACAC,EACAC,GAEA,MACMC,EADOD,EAAO,GAIf,oBAEL,OAAO5C,EAAY8C,0BACf,IAAI/C,EAAyB,CACzBkB,UACgC,MAA5B4B,EAAOE,kBACDC,EAAUT,cAEFM,EAClC,wBAE0BI,EACV9B,IACkB,MAAd0B,EAAO1B,IACD+B,EAAIC,iBAAiBN,EAAO1B,UAC5B8B,EACV5B,0BACyC,MAArCwB,EAAOO,4BACDC,OAAOC,OACHT,EAAOO,2BACP,SAEAP,EAAOO,2BAA2BG,WAEtCN,EACV1B,eAC6B,MAAzBsB,EAAOW,eACDR,EAAUT,cAEFM,EAClC,qBAE0BI,EACVxB,gBAC8B,MAA1BoB,EAAOpB,iBACiC,MAAlCoB,EAAOpB,gBAAgBgC,QACnBZ,EAAOpB,gBAAgBgC,aAE3BR,EACVtB,eAC6B,MAAzBkB,EAAOlB,eACD+B,EAAUnB,cAAcM,EAAOlB,qBAC/BsB,EACVpB,YACmB,MAAfgB,EAAOc,MACDN,OAAOC,OAAOT,EAAOc,KAAM,SACvBd,EAAOc,KAAKJ,WAEhBN,EACVlB,8BAC4C,MAAxCc,EAAOd,+BACuC,MAA9Cc,EAAOd,8BAA8BwB,OACrCF,OAAOC,OAAOT,EAAOd,8BAA+B,SAC9C6B,EAAKC,WACDhB,EAAOd,8BAA8BwB,YAEzCN,EACVhB,gBAC8B,MAA1BY,EAAOZ,gBACDe,EAAUT,cAAcM,EAAOZ,sBAC/BgB,EACVd,aAC2B,MAAvBU,EAAOV,aACDU,EAAOV,kBACPc,EACVZ,qBAC4B,MAAxBQ,EAAOiB,eACDT,OAAOC,OAAOT,EAAOiB,cAAe,SAChCjB,EAAOiB,cAAcP,WAEzBN,IAEdT,EACAC,EACAC,EACAC,EACAC,EAEZ,CAKI,aAAI3B,GACA,OAAOb,KAAKC,UACpB,CAQI,YAAAa,CAAaD,GAOT,OANAb,KAAK2D,oBACL3D,KAAKC,WACoB,iBAAdY,EACD+B,EAAUgB,WAAW/C,GACrBA,EAAUgD,QAEb7D,IACf,CAKI,OAAIe,GACA,OAAOf,KAAKE,IACpB,CAMI,MAAAc,CAAOD,GAIH,OAHAf,KAAK2D,oBACL3D,KAAKE,KAAOa,EAELf,IACf,CAKI,6BAAIiB,GACA,OAAOjB,KAAKG,0BACpB,CAMI,4BAAAe,CAA6BD,GAIzB,OAHAjB,KAAK2D,oBACL3D,KAAKG,2BAA6Bc,EAE3BjB,IACf,CAMI,kBAAImB,GACA,OAAOnB,KAAKI,eACpB,CAOI,iBAAAgB,CAAkBD,GAId,OAHAnB,KAAK2D,oBACL3D,KAAKI,gBAAkBe,EAEhBnB,IACf,CAKI,mBAAIqB,GACA,OAAOrB,KAAKK,gBACpB,CAMI,kBAAAiB,CAAmBD,GAOf,OANArB,KAAK2D,oBACL3D,KAAKK,iBACDgB,aAA2ByC,EACrBzC,EACA,IAAIyC,EAASzC,GAEhBrB,IACf,CAKI,kBAAIuB,GACA,OAAOvB,KAAKM,eACpB,CAMI,iBAAAkB,CAAkBD,GAOd,OANAvB,KAAK2D,oBACL3D,KAAKM,gBACDiB,aAA0BwC,KACpBT,EAAUU,SAASzC,GACnBA,EAEHvB,IACf,CAKI,eAAIyB,GACA,OAAOzB,KAAKO,YACpB,CAMI,cAAAmB,CAAe6B,GAIX,OAHAvD,KAAK2D,oBACL3D,KAAKO,aAAegD,EAEbvD,IACf,CAKI,gBAAAiE,GAII,OAHAjE,KAAK2D,oBACL3D,KAAKO,aAAe,KAEbP,IACf,CAKI,iCAAI2B,GACA,OAAO3B,KAAKQ,8BACpB,CAMI,gCAAAoB,CAAiCD,GAO7B,OANA3B,KAAK2D,oBACL3D,KAAKQ,+BACwC,iBAAlCmB,EACD6B,EAAKC,WAAW9B,GAChBA,EAEH3B,IACf,CAMI,YAAIkE,GACA,OAAO,IACf,CAQI,WAAAC,CAAYC,GACR,OAAOpE,IACf,CAKI,mBAAI6B,GACA,OAAO7B,KAAKU,gBACpB,CAMI,kBAAAoB,CAAmBD,GAOf,OANA7B,KAAK2D,oBACL3D,KAAKU,iBAC0B,iBAApBmB,EACDe,EAAUgB,WAAW/B,GACrBA,EAEH7B,IACf,CAKI,oBAAAqE,GAII,OAHArE,KAAK2D,oBACL3D,KAAKU,iBAAmB,IAAIkC,EAAU,EAAG,EAAG,GAErC5C,IACf,CAKI,gBAAI+B,GACA,OAAO/B,KAAKW,aACpB,CAMI,eAAAqB,CAAgBD,GAIZ,OAHA/B,KAAK2D,oBACL3D,KAAKW,cAAgB6C,EAAKc,UAAUvC,GAE7B/B,IACf,CAKI,iBAAAuE,GAII,OAHAvE,KAAK2D,oBACL3D,KAAKW,cAAgB6C,EAAKC,YAAW,GAE9BzD,IACf,CAKI,yBAAIwE,GACA,OAAOxE,KAAKY,qBACpB,CAMI,uBAAAsB,CAAwBD,GAIpB,OAHAjC,KAAK2D,oBACL3D,KAAKY,sBAAwBqB,EAEtBjC,IACf,CAKI,kBAAAyE,CAAmBC,GACQ,MAAnB1E,KAAKC,YACLD,KAAKC,WAAW0E,iBAAiBD,GAGT,MAAxB1E,KAAKI,iBACLJ,KAAKI,gBAAgBuE,iBAAiBD,EAElD,CASI,QAAAE,CAASC,EAASC,GACd,OAAOD,EAAQE,OAAOC,cAAcF,EAC5C,CAOI,uBAAAG,GACI,MAAO,qBACf,CAOI,oBAAAC,GACI,MAAO,CACHvC,kBACuB,MAAnB3C,KAAKC,WAAqBD,KAAKC,WAAWkF,cAAgB,KAC9DpE,IAAkB,MAAbf,KAAKE,KAAeF,KAAKE,KAAKkF,iBAAmB,KACtD7D,eAC4B,MAAxBvB,KAAKM,gBACCN,KAAKM,gBAAgB6E,cACrB,KACV/B,eAC4B,MAAxBpD,KAAKI,gBACCJ,KAAKI,gBAAgB+E,cACrB,KACV9D,gBAC6B,MAAzBrB,KAAKK,iBACCL,KAAKK,iBAAiB8E,cACtB,KACVnC,2BACuC,MAAnChD,KAAKG,2BACC,KACA,CACIgD,MAAOnD,KAAKG,4BAE1BoD,KACyB,MAArBvD,KAAKO,aACC,CACI4C,MAAOnD,KAAKO,cAEhB,KACVoB,8BAC2C,MAAvC3B,KAAKQ,+BACC,CAAE2C,MAAOnD,KAAKQ,+BAA+B6E,SAC7C,KACVxD,gBAC4B,MAAxB7B,KAAK6B,gBACC7B,KAAK6B,gBAAgBsD,cACrB,KACVpD,aAAc/B,KAAK+B,aACnB2B,cACkC,MAA9B1D,KAAKwE,sBACC,CAAErB,MAAOnD,KAAKwE,uBACd,KAEtB,CAKI,SAAAc,GAII,MAAO,4BAFHtF,KAAKuF,gBAAgBC,QACxB,WAC4CC,YACrD,EAGAC,EAAqBC,IACjB,sBAEAhG,EAAyBwC"}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _AccountId = _interopRequireDefault(require("./AccountId.cjs"));
|
|
8
|
+
var _Hbar = _interopRequireDefault(require("../Hbar.cjs"));
|
|
9
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
10
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* @namespace proto
|
|
14
|
+
* @typedef {import("@hashgraph/proto").proto.IGrantedCryptoAllowance} HieroProto.proto.IGrantedCryptoAllowance
|
|
15
|
+
* @typedef {import("@hashgraph/proto").proto.ICryptoAllowance} HieroProto.proto.ICryptoAllowance
|
|
16
|
+
* @typedef {import("@hashgraph/proto").proto.IAccountID} HieroProto.proto.IAccountID
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @typedef {import("long")} Long
|
|
21
|
+
*/
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* @typedef {import("../client/Client.js").default<*, *>} Client
|
|
25
|
+
*/
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Represents an HBAR allowance granted to a spender account by an owner account.
|
|
29
|
+
* This class manages the permissions for one account to spend HBAR on behalf of another account.
|
|
30
|
+
*/
|
|
31
|
+
class HbarAllowance {
|
|
32
|
+
/**
|
|
33
|
+
* @internal
|
|
34
|
+
* @param {object} props
|
|
35
|
+
* @param {AccountId | null} props.spenderAccountId
|
|
36
|
+
* @param {AccountId | null} props.ownerAccountId
|
|
37
|
+
* @param {Hbar | null} props.amount
|
|
38
|
+
*/
|
|
39
|
+
constructor(props) {
|
|
40
|
+
/**
|
|
41
|
+
* The account ID of the hbar allowance spender.
|
|
42
|
+
*
|
|
43
|
+
* @readonly
|
|
44
|
+
*/
|
|
45
|
+
this.spenderAccountId = props.spenderAccountId;
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* The account ID of the hbar allowance owner.
|
|
49
|
+
*
|
|
50
|
+
* @readonly
|
|
51
|
+
*/
|
|
52
|
+
this.ownerAccountId = props.ownerAccountId;
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* The current balance of the spender's allowance in tinybars.
|
|
56
|
+
*
|
|
57
|
+
* @readonly
|
|
58
|
+
*/
|
|
59
|
+
this.amount = props.amount;
|
|
60
|
+
Object.freeze(this);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* @internal
|
|
65
|
+
* @param {HieroProto.proto.ICryptoAllowance} allowance
|
|
66
|
+
* @returns {HbarAllowance}
|
|
67
|
+
*/
|
|
68
|
+
static _fromProtobuf(allowance) {
|
|
69
|
+
return new HbarAllowance({
|
|
70
|
+
spenderAccountId: _AccountId.default._fromProtobuf(/** @type {HieroProto.proto.IAccountID} */allowance.spender),
|
|
71
|
+
ownerAccountId: allowance.owner != null ? _AccountId.default._fromProtobuf(/**@type {HieroProto.proto.IAccountID}*/
|
|
72
|
+
allowance.owner) : null,
|
|
73
|
+
amount: _Hbar.default.fromTinybars(allowance.amount != null ? allowance.amount : 0)
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* @internal
|
|
79
|
+
* @param {HieroProto.proto.IGrantedCryptoAllowance} allowance
|
|
80
|
+
* @param {AccountId} ownerAccountId
|
|
81
|
+
* @returns {HbarAllowance}
|
|
82
|
+
*/
|
|
83
|
+
static _fromGrantedProtobuf(allowance, ownerAccountId) {
|
|
84
|
+
return new HbarAllowance({
|
|
85
|
+
spenderAccountId: _AccountId.default._fromProtobuf(/** @type {HieroProto.proto.IAccountID} */allowance.spender),
|
|
86
|
+
ownerAccountId,
|
|
87
|
+
amount: _Hbar.default.fromTinybars(allowance.amount != null ? allowance.amount : 0)
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* @internal
|
|
93
|
+
* @returns {HieroProto.proto.ICryptoAllowance}
|
|
94
|
+
*/
|
|
95
|
+
_toProtobuf() {
|
|
96
|
+
return {
|
|
97
|
+
owner: this.ownerAccountId != null ? this.ownerAccountId._toProtobuf() : null,
|
|
98
|
+
spender: this.spenderAccountId != null ? this.spenderAccountId._toProtobuf() : null,
|
|
99
|
+
amount: this.amount != null ? this.amount.toTinybars() : null
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* @param {Client} client
|
|
105
|
+
*/
|
|
106
|
+
_validateChecksums(client) {
|
|
107
|
+
if (this.spenderAccountId != null) {
|
|
108
|
+
this.spenderAccountId.validateChecksum(client);
|
|
109
|
+
}
|
|
110
|
+
if (this.spenderAccountId != null) {
|
|
111
|
+
this.spenderAccountId.validateChecksum(client);
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* @returns {object}
|
|
117
|
+
*/
|
|
118
|
+
toJSON() {
|
|
119
|
+
return {
|
|
120
|
+
ownerAccountId: this.ownerAccountId != null ? this.ownerAccountId.toString() : null,
|
|
121
|
+
spenderAccountId: this.spenderAccountId != null ? this.spenderAccountId.toString() : null,
|
|
122
|
+
amount: this.amount != null ? this.amount.toString() : null
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
exports.default = HbarAllowance;
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @namespace proto
|
|
3
|
+
* @typedef {import("@hashgraph/proto").proto.IGrantedCryptoAllowance} HieroProto.proto.IGrantedCryptoAllowance
|
|
4
|
+
* @typedef {import("@hashgraph/proto").proto.ICryptoAllowance} HieroProto.proto.ICryptoAllowance
|
|
5
|
+
* @typedef {import("@hashgraph/proto").proto.IAccountID} HieroProto.proto.IAccountID
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* @typedef {import("long")} Long
|
|
9
|
+
*/
|
|
10
|
+
/**
|
|
11
|
+
* @typedef {import("../client/Client.js").default<*, *>} Client
|
|
12
|
+
*/
|
|
13
|
+
/**
|
|
14
|
+
* Represents an HBAR allowance granted to a spender account by an owner account.
|
|
15
|
+
* This class manages the permissions for one account to spend HBAR on behalf of another account.
|
|
16
|
+
*/
|
|
17
|
+
export default class HbarAllowance {
|
|
18
|
+
/**
|
|
19
|
+
* @internal
|
|
20
|
+
* @param {HieroProto.proto.ICryptoAllowance} allowance
|
|
21
|
+
* @returns {HbarAllowance}
|
|
22
|
+
*/
|
|
23
|
+
static _fromProtobuf(allowance: HieroProto.proto.ICryptoAllowance): HbarAllowance;
|
|
24
|
+
/**
|
|
25
|
+
* @internal
|
|
26
|
+
* @param {HieroProto.proto.IGrantedCryptoAllowance} allowance
|
|
27
|
+
* @param {AccountId} ownerAccountId
|
|
28
|
+
* @returns {HbarAllowance}
|
|
29
|
+
*/
|
|
30
|
+
static _fromGrantedProtobuf(allowance: HieroProto.proto.IGrantedCryptoAllowance, ownerAccountId: AccountId): HbarAllowance;
|
|
31
|
+
/**
|
|
32
|
+
* @internal
|
|
33
|
+
* @param {object} props
|
|
34
|
+
* @param {AccountId | null} props.spenderAccountId
|
|
35
|
+
* @param {AccountId | null} props.ownerAccountId
|
|
36
|
+
* @param {Hbar | null} props.amount
|
|
37
|
+
*/
|
|
38
|
+
constructor(props: {
|
|
39
|
+
spenderAccountId: AccountId | null;
|
|
40
|
+
ownerAccountId: AccountId | null;
|
|
41
|
+
amount: Hbar | null;
|
|
42
|
+
});
|
|
43
|
+
/**
|
|
44
|
+
* The account ID of the hbar allowance spender.
|
|
45
|
+
*
|
|
46
|
+
* @readonly
|
|
47
|
+
*/
|
|
48
|
+
readonly spenderAccountId: AccountId | null;
|
|
49
|
+
/**
|
|
50
|
+
* The account ID of the hbar allowance owner.
|
|
51
|
+
*
|
|
52
|
+
* @readonly
|
|
53
|
+
*/
|
|
54
|
+
readonly ownerAccountId: AccountId | null;
|
|
55
|
+
/**
|
|
56
|
+
* The current balance of the spender's allowance in tinybars.
|
|
57
|
+
*
|
|
58
|
+
* @readonly
|
|
59
|
+
*/
|
|
60
|
+
readonly amount: Hbar | null;
|
|
61
|
+
/**
|
|
62
|
+
* @internal
|
|
63
|
+
* @returns {HieroProto.proto.ICryptoAllowance}
|
|
64
|
+
*/
|
|
65
|
+
_toProtobuf(): HieroProto.proto.ICryptoAllowance;
|
|
66
|
+
/**
|
|
67
|
+
* @param {Client} client
|
|
68
|
+
*/
|
|
69
|
+
_validateChecksums(client: Client): void;
|
|
70
|
+
/**
|
|
71
|
+
* @returns {object}
|
|
72
|
+
*/
|
|
73
|
+
toJSON(): object;
|
|
74
|
+
}
|
|
75
|
+
export namespace HieroProto {
|
|
76
|
+
namespace proto {
|
|
77
|
+
type IGrantedCryptoAllowance = import("@hashgraph/proto").proto.IGrantedCryptoAllowance;
|
|
78
|
+
type ICryptoAllowance = import("@hashgraph/proto").proto.ICryptoAllowance;
|
|
79
|
+
type IAccountID = import("@hashgraph/proto").proto.IAccountID;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
export type Long = import("long");
|
|
83
|
+
export type Client = import("../client/Client.js").default<any, any>;
|
|
84
|
+
import AccountId from "./AccountId.js";
|
|
85
|
+
import Hbar from "../Hbar.js";
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import n from"./AccountId.js";import t from"../Hbar.js";class o{constructor(n){this.spenderAccountId=n.spenderAccountId,this.ownerAccountId=n.ownerAccountId,this.amount=n.amount,Object.freeze(this)}static _fromProtobuf(u){return new o({spenderAccountId:n._fromProtobuf(u.spender),ownerAccountId:null!=u.owner?n._fromProtobuf(u.owner):null,amount:t.fromTinybars(null!=u.amount?u.amount:0)})}static _fromGrantedProtobuf(u,r){return new o({spenderAccountId:n._fromProtobuf(u.spender),ownerAccountId:r,amount:t.fromTinybars(null!=u.amount?u.amount:0)})}_toProtobuf(){return{owner:null!=this.ownerAccountId?this.ownerAccountId._toProtobuf():null,spender:null!=this.spenderAccountId?this.spenderAccountId._toProtobuf():null,amount:null!=this.amount?this.amount.toTinybars():null}}_validateChecksums(n){null!=this.spenderAccountId&&this.spenderAccountId.validateChecksum(n),null!=this.spenderAccountId&&this.spenderAccountId.validateChecksum(n)}toJSON(){return{ownerAccountId:null!=this.ownerAccountId?this.ownerAccountId.toString():null,spenderAccountId:null!=this.spenderAccountId?this.spenderAccountId.toString():null,amount:null!=this.amount?this.amount.toString():null}}}export{o as default};
|
|
2
|
+
//# sourceMappingURL=HbarAllowance.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"HbarAllowance.js","sources":["../../src/account/HbarAllowance.js"],"sourcesContent":["// SPDX-License-Identifier: Apache-2.0\n\nimport AccountId from \"./AccountId.js\";\nimport Hbar from \"../Hbar.js\";\n\n/**\n * @namespace proto\n * @typedef {import(\"@hashgraph/proto\").proto.IGrantedCryptoAllowance} HieroProto.proto.IGrantedCryptoAllowance\n * @typedef {import(\"@hashgraph/proto\").proto.ICryptoAllowance} HieroProto.proto.ICryptoAllowance\n * @typedef {import(\"@hashgraph/proto\").proto.IAccountID} HieroProto.proto.IAccountID\n */\n\n/**\n * @typedef {import(\"long\")} Long\n */\n\n/**\n * @typedef {import(\"../client/Client.js\").default<*, *>} Client\n */\n\n/**\n * Represents an HBAR allowance granted to a spender account by an owner account.\n * This class manages the permissions for one account to spend HBAR on behalf of another account.\n */\nexport default class HbarAllowance {\n /**\n * @internal\n * @param {object} props\n * @param {AccountId | null} props.spenderAccountId\n * @param {AccountId | null} props.ownerAccountId\n * @param {Hbar | null} props.amount\n */\n constructor(props) {\n /**\n * The account ID of the hbar allowance spender.\n *\n * @readonly\n */\n this.spenderAccountId = props.spenderAccountId;\n\n /**\n * The account ID of the hbar allowance owner.\n *\n * @readonly\n */\n this.ownerAccountId = props.ownerAccountId;\n\n /**\n * The current balance of the spender's allowance in tinybars.\n *\n * @readonly\n */\n this.amount = props.amount;\n\n Object.freeze(this);\n }\n\n /**\n * @internal\n * @param {HieroProto.proto.ICryptoAllowance} allowance\n * @returns {HbarAllowance}\n */\n static _fromProtobuf(allowance) {\n return new HbarAllowance({\n spenderAccountId: AccountId._fromProtobuf(\n /** @type {HieroProto.proto.IAccountID} */ (allowance.spender),\n ),\n ownerAccountId:\n allowance.owner != null\n ? AccountId._fromProtobuf(\n /**@type {HieroProto.proto.IAccountID}*/ (\n allowance.owner\n ),\n )\n : null,\n amount: Hbar.fromTinybars(\n allowance.amount != null ? allowance.amount : 0,\n ),\n });\n }\n\n /**\n * @internal\n * @param {HieroProto.proto.IGrantedCryptoAllowance} allowance\n * @param {AccountId} ownerAccountId\n * @returns {HbarAllowance}\n */\n static _fromGrantedProtobuf(allowance, ownerAccountId) {\n return new HbarAllowance({\n spenderAccountId: AccountId._fromProtobuf(\n /** @type {HieroProto.proto.IAccountID} */ (allowance.spender),\n ),\n ownerAccountId,\n amount: Hbar.fromTinybars(\n allowance.amount != null ? allowance.amount : 0,\n ),\n });\n }\n\n /**\n * @internal\n * @returns {HieroProto.proto.ICryptoAllowance}\n */\n _toProtobuf() {\n return {\n owner:\n this.ownerAccountId != null\n ? this.ownerAccountId._toProtobuf()\n : null,\n spender:\n this.spenderAccountId != null\n ? this.spenderAccountId._toProtobuf()\n : null,\n amount: this.amount != null ? this.amount.toTinybars() : null,\n };\n }\n\n /**\n * @param {Client} client\n */\n _validateChecksums(client) {\n if (this.spenderAccountId != null) {\n this.spenderAccountId.validateChecksum(client);\n }\n\n if (this.spenderAccountId != null) {\n this.spenderAccountId.validateChecksum(client);\n }\n }\n\n /**\n * @returns {object}\n */\n toJSON() {\n return {\n ownerAccountId:\n this.ownerAccountId != null\n ? this.ownerAccountId.toString()\n : null,\n spenderAccountId:\n this.spenderAccountId != null\n ? this.spenderAccountId.toString()\n : null,\n amount: this.amount != null ? this.amount.toString() : null,\n };\n }\n}\n"],"names":["HbarAllowance","constructor","props","this","spenderAccountId","ownerAccountId","amount","Object","freeze","_fromProtobuf","allowance","AccountId","owner","Hbar","fromTinybars","_fromGrantedProtobuf","_toProtobuf","spender","toTinybars","_validateChecksums","client","validateChecksum","toJSON","toString"],"mappings":"wDAwBe,MAAMA,EAQjB,WAAAC,CAAYC,GAMRC,KAAKC,iBAAmBF,EAAME,iBAO9BD,KAAKE,eAAiBH,EAAMG,eAO5BF,KAAKG,OAASJ,EAAMI,OAEpBC,OAAOC,OAAOL,KACtB,CAOI,oBAAOM,CAAcC,GACjB,OAAO,IAAIV,EAAc,CACrBI,iBAAkBO,EAAUF,cACoBC,EAAiB,SAEjEL,eACuB,MAAnBK,EAAUE,MACJD,EAAUF,cAEFC,EAC9B,OAEsB,KACVJ,OAAQO,EAAKC,aACW,MAApBJ,EAAUJ,OAAiBI,EAAUJ,OAAS,IAG9D,CAQI,2BAAOS,CAAqBL,EAAWL,GACnC,OAAO,IAAIL,EAAc,CACrBI,iBAAkBO,EAAUF,cACoBC,EAAiB,SAEjEL,iBACAC,OAAQO,EAAKC,aACW,MAApBJ,EAAUJ,OAAiBI,EAAUJ,OAAS,IAG9D,CAMI,WAAAU,GACI,MAAO,CACHJ,MAC2B,MAAvBT,KAAKE,eACCF,KAAKE,eAAeW,cACpB,KACVC,QAC6B,MAAzBd,KAAKC,iBACCD,KAAKC,iBAAiBY,cACtB,KACVV,OAAuB,MAAfH,KAAKG,OAAiBH,KAAKG,OAAOY,aAAe,KAErE,CAKI,kBAAAC,CAAmBC,GACc,MAAzBjB,KAAKC,kBACLD,KAAKC,iBAAiBiB,iBAAiBD,GAGd,MAAzBjB,KAAKC,kBACLD,KAAKC,iBAAiBiB,iBAAiBD,EAEnD,CAKI,MAAAE,GACI,MAAO,CACHjB,eAC2B,MAAvBF,KAAKE,eACCF,KAAKE,eAAekB,WACpB,KACVnB,iBAC6B,MAAzBD,KAAKC,iBACCD,KAAKC,iBAAiBmB,WACtB,KACVjB,OAAuB,MAAfH,KAAKG,OAAiBH,KAAKG,OAAOiB,WAAa,KAEnE"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _AccountId = _interopRequireDefault(require("./AccountId.cjs"));
|
|
8
|
+
var _Hbar = _interopRequireDefault(require("../Hbar.cjs"));
|
|
9
|
+
var _ObjectMap = _interopRequireDefault(require("../ObjectMap.cjs"));
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* @namespace proto
|
|
15
|
+
* @typedef {import("@hashgraph/proto").proto.ITransferList} HieroProto.proto.ITransferList
|
|
16
|
+
* @typedef {import("@hashgraph/proto").proto.IAccountID} HieroProto.proto.IAccountID
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @typedef {import("../long.js").LongObject} LongObject
|
|
21
|
+
* @typedef {import("bignumber.js").default} BigNumber
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* @augments {ObjectMap<AccountId, Hbar>}
|
|
26
|
+
*/
|
|
27
|
+
class HbarTransferMap extends _ObjectMap.default {
|
|
28
|
+
constructor() {
|
|
29
|
+
super(s => _AccountId.default.fromString(s));
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* @param {HieroProto.proto.ITransferList} transfers
|
|
34
|
+
* @returns {HbarTransferMap}
|
|
35
|
+
*/
|
|
36
|
+
static _fromProtobuf(transfers) {
|
|
37
|
+
const accountTransfers = new HbarTransferMap();
|
|
38
|
+
for (const transfer of transfers.accountAmounts != null ? transfers.accountAmounts : []) {
|
|
39
|
+
const account = _AccountId.default._fromProtobuf(/** @type {HieroProto.proto.IAccountID} */transfer.accountID);
|
|
40
|
+
accountTransfers._set(account, _Hbar.default.fromTinybars(/** @type {Long} */transfer.amount));
|
|
41
|
+
}
|
|
42
|
+
return accountTransfers;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.default = HbarTransferMap;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @namespace proto
|
|
3
|
+
* @typedef {import("@hashgraph/proto").proto.ITransferList} HieroProto.proto.ITransferList
|
|
4
|
+
* @typedef {import("@hashgraph/proto").proto.IAccountID} HieroProto.proto.IAccountID
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* @typedef {import("../long.js").LongObject} LongObject
|
|
8
|
+
* @typedef {import("bignumber.js").default} BigNumber
|
|
9
|
+
*/
|
|
10
|
+
/**
|
|
11
|
+
* @augments {ObjectMap<AccountId, Hbar>}
|
|
12
|
+
*/
|
|
13
|
+
export default class HbarTransferMap extends ObjectMap<AccountId, Hbar> {
|
|
14
|
+
/**
|
|
15
|
+
* @param {HieroProto.proto.ITransferList} transfers
|
|
16
|
+
* @returns {HbarTransferMap}
|
|
17
|
+
*/
|
|
18
|
+
static _fromProtobuf(transfers: HieroProto.proto.ITransferList): HbarTransferMap;
|
|
19
|
+
constructor();
|
|
20
|
+
}
|
|
21
|
+
export namespace HieroProto {
|
|
22
|
+
namespace proto {
|
|
23
|
+
type ITransferList = import("@hashgraph/proto").proto.ITransferList;
|
|
24
|
+
type IAccountID = import("@hashgraph/proto").proto.IAccountID;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
export type LongObject = import("../long.js").LongObject;
|
|
28
|
+
export type BigNumber = import("bignumber.js").default;
|
|
29
|
+
import AccountId from "./AccountId.js";
|
|
30
|
+
import Hbar from "../Hbar.js";
|
|
31
|
+
import ObjectMap from "../ObjectMap.js";
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import o from"./AccountId.js";import t from"../Hbar.js";import r from"../ObjectMap.js";class n extends r{constructor(){super((t=>o.fromString(t)))}static _fromProtobuf(r){const s=new n;for(const n of null!=r.accountAmounts?r.accountAmounts:[]){const r=o._fromProtobuf(n.accountID);s._set(r,t.fromTinybars(n.amount))}return s}}export{n as default};
|
|
2
|
+
//# sourceMappingURL=HbarTransferMap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"HbarTransferMap.js","sources":["../../src/account/HbarTransferMap.js"],"sourcesContent":["// SPDX-License-Identifier: Apache-2.0\n\nimport AccountId from \"./AccountId.js\";\nimport Hbar from \"../Hbar.js\";\nimport ObjectMap from \"../ObjectMap.js\";\n\n/**\n * @namespace proto\n * @typedef {import(\"@hashgraph/proto\").proto.ITransferList} HieroProto.proto.ITransferList\n * @typedef {import(\"@hashgraph/proto\").proto.IAccountID} HieroProto.proto.IAccountID\n */\n\n/**\n * @typedef {import(\"../long.js\").LongObject} LongObject\n * @typedef {import(\"bignumber.js\").default} BigNumber\n */\n\n/**\n * @augments {ObjectMap<AccountId, Hbar>}\n */\nexport default class HbarTransferMap extends ObjectMap {\n constructor() {\n super((s) => AccountId.fromString(s));\n }\n\n /**\n * @param {HieroProto.proto.ITransferList} transfers\n * @returns {HbarTransferMap}\n */\n static _fromProtobuf(transfers) {\n const accountTransfers = new HbarTransferMap();\n\n for (const transfer of transfers.accountAmounts != null\n ? transfers.accountAmounts\n : []) {\n const account = AccountId._fromProtobuf(\n /** @type {HieroProto.proto.IAccountID} */ (transfer.accountID),\n );\n\n accountTransfers._set(\n account,\n Hbar.fromTinybars(/** @type {Long} */ (transfer.amount)),\n );\n }\n\n return accountTransfers;\n }\n}\n"],"names":["HbarTransferMap","ObjectMap","constructor","super","s","AccountId","fromString","_fromProtobuf","transfers","accountTransfers","transfer","accountAmounts","account","_set","Hbar","fromTinybars"],"mappings":"uFAoBe,MAAMA,UAAwBC,EACzC,WAAAC,GACIC,OAAOC,GAAMC,EAAUC,WAAWF,IAC1C,CAMI,oBAAOG,CAAcC,GACjB,MAAMC,EAAmB,IAAIT,EAE7B,IAAK,MAAMU,KAAwC,MAA5BF,EAAUG,eAC3BH,EAAUG,eACV,GAAI,CACN,MAAMC,EAAUP,EAAUE,cACsBG,EAAkB,WAGlED,EAAiBI,KACbD,EACAE,EAAKC,aAAkCL,EAAe,QAEtE,CAEQ,OAAOD,CACf"}
|