@bsv/wallet-toolbox 1.1.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/.env.template +22 -0
- package/.github/ISSUE_TEMPLATE/bug_report.md +40 -0
- package/.github/ISSUE_TEMPLATE/discussion.md +24 -0
- package/.github/pull_request_template.md +24 -0
- package/.github/workflows/push.yaml +66 -0
- package/.prettierrc +10 -0
- package/CONTRIBUTING.md +89 -0
- package/LICENSE.txt +28 -0
- package/README.md +124 -0
- package/dev.sqlite3 +0 -0
- package/docs/README.md +15 -0
- package/docs/client.md +6812 -0
- package/docs/monitor.md +648 -0
- package/docs/services.md +496 -0
- package/docs/storage.md +1884 -0
- package/docs/wallet.md +6812 -0
- package/jest.config.ts +29 -0
- package/knexfile.js +9 -0
- package/license.md +1 -0
- package/out/src/Wallet.d.ts +83 -0
- package/out/src/Wallet.d.ts.map +1 -0
- package/out/src/Wallet.js +415 -0
- package/out/src/Wallet.js.map +1 -0
- package/out/src/index.all.d.ts +9 -0
- package/out/src/index.all.d.ts.map +1 -0
- package/out/src/index.all.js +48 -0
- package/out/src/index.all.js.map +1 -0
- package/out/src/index.client.d.ts +8 -0
- package/out/src/index.client.d.ts.map +1 -0
- package/out/src/index.client.js +47 -0
- package/out/src/index.client.js.map +1 -0
- package/out/src/index.d.ts +3 -0
- package/out/src/index.d.ts.map +1 -0
- package/out/src/index.js +42 -0
- package/out/src/index.js.map +1 -0
- package/out/src/monitor/Monitor.d.ts +89 -0
- package/out/src/monitor/Monitor.d.ts.map +1 -0
- package/out/src/monitor/Monitor.js +253 -0
- package/out/src/monitor/Monitor.js.map +1 -0
- package/out/src/monitor/MonitorDaemon.d.ts +30 -0
- package/out/src/monitor/MonitorDaemon.d.ts.map +1 -0
- package/out/src/monitor/MonitorDaemon.js +135 -0
- package/out/src/monitor/MonitorDaemon.js.map +1 -0
- package/out/src/monitor/__test/MonitorDaemon.man.test.d.ts +2 -0
- package/out/src/monitor/__test/MonitorDaemon.man.test.d.ts.map +1 -0
- package/out/src/monitor/__test/MonitorDaemon.man.test.js +50 -0
- package/out/src/monitor/__test/MonitorDaemon.man.test.js.map +1 -0
- package/out/src/monitor/tasks/TaskCheckForProofs.d.ts +53 -0
- package/out/src/monitor/tasks/TaskCheckForProofs.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskCheckForProofs.js +197 -0
- package/out/src/monitor/tasks/TaskCheckForProofs.js.map +1 -0
- package/out/src/monitor/tasks/TaskClock.d.ts +14 -0
- package/out/src/monitor/tasks/TaskClock.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskClock.js +27 -0
- package/out/src/monitor/tasks/TaskClock.js.map +1 -0
- package/out/src/monitor/tasks/TaskFailAbandoned.d.ts +20 -0
- package/out/src/monitor/tasks/TaskFailAbandoned.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskFailAbandoned.js +52 -0
- package/out/src/monitor/tasks/TaskFailAbandoned.js.map +1 -0
- package/out/src/monitor/tasks/TaskNewHeader.d.ts +15 -0
- package/out/src/monitor/tasks/TaskNewHeader.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskNewHeader.js +45 -0
- package/out/src/monitor/tasks/TaskNewHeader.js.map +1 -0
- package/out/src/monitor/tasks/TaskPurge.d.ts +45 -0
- package/out/src/monitor/tasks/TaskPurge.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskPurge.js +35 -0
- package/out/src/monitor/tasks/TaskPurge.js.map +1 -0
- package/out/src/monitor/tasks/TaskReviewStatus.d.ts +26 -0
- package/out/src/monitor/tasks/TaskReviewStatus.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskReviewStatus.js +44 -0
- package/out/src/monitor/tasks/TaskReviewStatus.js.map +1 -0
- package/out/src/monitor/tasks/TaskSendWaiting.d.ts +32 -0
- package/out/src/monitor/tasks/TaskSendWaiting.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskSendWaiting.js +99 -0
- package/out/src/monitor/tasks/TaskSendWaiting.js.map +1 -0
- package/out/src/monitor/tasks/TaskSyncWhenIdle.d.ts +12 -0
- package/out/src/monitor/tasks/TaskSyncWhenIdle.d.ts.map +1 -0
- package/out/src/monitor/tasks/TaskSyncWhenIdle.js +22 -0
- package/out/src/monitor/tasks/TaskSyncWhenIdle.js.map +1 -0
- package/out/src/monitor/tasks/WalletMonitorTask.d.ts +40 -0
- package/out/src/monitor/tasks/WalletMonitorTask.d.ts.map +1 -0
- package/out/src/monitor/tasks/WalletMonitorTask.js +37 -0
- package/out/src/monitor/tasks/WalletMonitorTask.js.map +1 -0
- package/out/src/sdk/CertOps.d.ts +66 -0
- package/out/src/sdk/CertOps.d.ts.map +1 -0
- package/out/src/sdk/CertOps.js +198 -0
- package/out/src/sdk/CertOps.js.map +1 -0
- package/out/src/sdk/PrivilegedKeyManager.d.ts +125 -0
- package/out/src/sdk/PrivilegedKeyManager.d.ts.map +1 -0
- package/out/src/sdk/PrivilegedKeyManager.js +293 -0
- package/out/src/sdk/PrivilegedKeyManager.js.map +1 -0
- package/out/src/sdk/StorageSyncReader.d.ts +121 -0
- package/out/src/sdk/StorageSyncReader.d.ts.map +1 -0
- package/out/src/sdk/StorageSyncReader.js +3 -0
- package/out/src/sdk/StorageSyncReader.js.map +1 -0
- package/out/src/sdk/StorageSyncReaderWriter.d.ts +89 -0
- package/out/src/sdk/StorageSyncReaderWriter.d.ts.map +1 -0
- package/out/src/sdk/StorageSyncReaderWriter.js +3 -0
- package/out/src/sdk/StorageSyncReaderWriter.js.map +1 -0
- package/out/src/sdk/WERR_errors.d.ts +90 -0
- package/out/src/sdk/WERR_errors.d.ts.map +1 -0
- package/out/src/sdk/WERR_errors.js +128 -0
- package/out/src/sdk/WERR_errors.js.map +1 -0
- package/out/src/sdk/WalletError.d.ts +45 -0
- package/out/src/sdk/WalletError.d.ts.map +1 -0
- package/out/src/sdk/WalletError.js +122 -0
- package/out/src/sdk/WalletError.js.map +1 -0
- package/out/src/sdk/WalletServices.interfaces.d.ts +325 -0
- package/out/src/sdk/WalletServices.interfaces.d.ts.map +1 -0
- package/out/src/sdk/WalletServices.interfaces.js +3 -0
- package/out/src/sdk/WalletServices.interfaces.js.map +1 -0
- package/out/src/sdk/WalletSigner.interfaces.d.ts +10 -0
- package/out/src/sdk/WalletSigner.interfaces.d.ts.map +1 -0
- package/out/src/sdk/WalletSigner.interfaces.js +3 -0
- package/out/src/sdk/WalletSigner.interfaces.js.map +1 -0
- package/out/src/sdk/WalletStorage.interfaces.d.ts +299 -0
- package/out/src/sdk/WalletStorage.interfaces.d.ts.map +1 -0
- package/out/src/sdk/WalletStorage.interfaces.js +3 -0
- package/out/src/sdk/WalletStorage.interfaces.js.map +1 -0
- package/out/src/sdk/__test/CertificateLifeCycle.test.d.ts +2 -0
- package/out/src/sdk/__test/CertificateLifeCycle.test.d.ts.map +1 -0
- package/out/src/sdk/__test/CertificateLifeCycle.test.js +125 -0
- package/out/src/sdk/__test/CertificateLifeCycle.test.js.map +1 -0
- package/out/src/sdk/__test/PrivilegedKeyManager.test.d.ts +2 -0
- package/out/src/sdk/__test/PrivilegedKeyManager.test.d.ts.map +1 -0
- package/out/src/sdk/__test/PrivilegedKeyManager.test.js +660 -0
- package/out/src/sdk/__test/PrivilegedKeyManager.test.js.map +1 -0
- package/out/src/sdk/index.d.ts +12 -0
- package/out/src/sdk/index.d.ts.map +1 -0
- package/out/src/sdk/index.js +28 -0
- package/out/src/sdk/index.js.map +1 -0
- package/out/src/sdk/types.d.ts +74 -0
- package/out/src/sdk/types.d.ts.map +1 -0
- package/out/src/sdk/types.js +20 -0
- package/out/src/sdk/types.js.map +1 -0
- package/out/src/sdk/validationHelpers.d.ts +288 -0
- package/out/src/sdk/validationHelpers.d.ts.map +1 -0
- package/out/src/sdk/validationHelpers.js +630 -0
- package/out/src/sdk/validationHelpers.js.map +1 -0
- package/out/src/services/ServiceCollection.d.ts +25 -0
- package/out/src/services/ServiceCollection.d.ts.map +1 -0
- package/out/src/services/ServiceCollection.js +43 -0
- package/out/src/services/ServiceCollection.js.map +1 -0
- package/out/src/services/Services.d.ts +60 -0
- package/out/src/services/Services.d.ts.map +1 -0
- package/out/src/services/Services.js +342 -0
- package/out/src/services/Services.js.map +1 -0
- package/out/src/services/__tests/getMerklePath.test.d.ts +2 -0
- package/out/src/services/__tests/getMerklePath.test.d.ts.map +1 -0
- package/out/src/services/__tests/getMerklePath.test.js +16 -0
- package/out/src/services/__tests/getMerklePath.test.js.map +1 -0
- package/out/src/services/__tests/getRawTx.test.d.ts +2 -0
- package/out/src/services/__tests/getRawTx.test.d.ts.map +1 -0
- package/out/src/services/__tests/getRawTx.test.js +13 -0
- package/out/src/services/__tests/getRawTx.test.js.map +1 -0
- package/out/src/services/__tests/postBeef.test.d.ts +2 -0
- package/out/src/services/__tests/postBeef.test.d.ts.map +1 -0
- package/out/src/services/__tests/postBeef.test.js +18 -0
- package/out/src/services/__tests/postBeef.test.js.map +1 -0
- package/out/src/services/__tests/postBeefToArcTaal.test.d.ts +2 -0
- package/out/src/services/__tests/postBeefToArcTaal.test.d.ts.map +1 -0
- package/out/src/services/__tests/postBeefToArcTaal.test.js +479 -0
- package/out/src/services/__tests/postBeefToArcTaal.test.js.map +1 -0
- package/out/src/services/__tests/postTxs.test.d.ts +2 -0
- package/out/src/services/__tests/postTxs.test.d.ts.map +1 -0
- package/out/src/services/__tests/postTxs.test.js +19 -0
- package/out/src/services/__tests/postTxs.test.js.map +1 -0
- package/out/src/services/chaintracker/ChaintracksChainTracker.d.ts +15 -0
- package/out/src/services/chaintracker/ChaintracksChainTracker.d.ts.map +1 -0
- package/out/src/services/chaintracker/ChaintracksChainTracker.js +51 -0
- package/out/src/services/chaintracker/ChaintracksChainTracker.js.map +1 -0
- package/out/src/services/chaintracker/__tests/ChaintracksChainTracker.test.d.ts +2 -0
- package/out/src/services/chaintracker/__tests/ChaintracksChainTracker.test.d.ts.map +1 -0
- package/out/src/services/chaintracker/__tests/ChaintracksChainTracker.test.js +19 -0
- package/out/src/services/chaintracker/__tests/ChaintracksChainTracker.test.js.map +1 -0
- package/out/src/services/chaintracker/__tests/ChaintracksServiceClient.test.d.ts +2 -0
- package/out/src/services/chaintracker/__tests/ChaintracksServiceClient.test.d.ts.map +1 -0
- package/out/src/services/chaintracker/__tests/ChaintracksServiceClient.test.js +29 -0
- package/out/src/services/chaintracker/__tests/ChaintracksServiceClient.test.js.map +1 -0
- package/out/src/services/chaintracker/chaintracks/BlockHeaderApi.d.ts +98 -0
- package/out/src/services/chaintracker/chaintracks/BlockHeaderApi.d.ts.map +1 -0
- package/out/src/services/chaintracker/chaintracks/BlockHeaderApi.js +38 -0
- package/out/src/services/chaintracker/chaintracks/BlockHeaderApi.js.map +1 -0
- package/out/src/services/chaintracker/chaintracks/ChaintracksServiceClient.d.ts +36 -0
- package/out/src/services/chaintracker/chaintracks/ChaintracksServiceClient.d.ts.map +1 -0
- package/out/src/services/chaintracker/chaintracks/ChaintracksServiceClient.js +130 -0
- package/out/src/services/chaintracker/chaintracks/ChaintracksServiceClient.js.map +1 -0
- package/out/src/services/chaintracker/chaintracks/index.d.ts +3 -0
- package/out/src/services/chaintracker/chaintracks/index.d.ts.map +1 -0
- package/out/src/services/chaintracker/chaintracks/index.js +19 -0
- package/out/src/services/chaintracker/chaintracks/index.js.map +1 -0
- package/out/src/services/chaintracker/index.d.ts +3 -0
- package/out/src/services/chaintracker/index.d.ts.map +1 -0
- package/out/src/services/chaintracker/index.js +19 -0
- package/out/src/services/chaintracker/index.js.map +1 -0
- package/out/src/services/createDefaultWalletServicesOptions.d.ts +3 -0
- package/out/src/services/createDefaultWalletServicesOptions.d.ts.map +1 -0
- package/out/src/services/createDefaultWalletServicesOptions.js +34 -0
- package/out/src/services/createDefaultWalletServicesOptions.js.map +1 -0
- package/out/src/services/index.d.ts +2 -0
- package/out/src/services/index.d.ts.map +1 -0
- package/out/src/services/index.js +18 -0
- package/out/src/services/index.js.map +1 -0
- package/out/src/services/providers/arcServices.d.ts +62 -0
- package/out/src/services/providers/arcServices.d.ts.map +1 -0
- package/out/src/services/providers/arcServices.js +368 -0
- package/out/src/services/providers/arcServices.js.map +1 -0
- package/out/src/services/providers/echangeRates.d.ts +12 -0
- package/out/src/services/providers/echangeRates.d.ts.map +1 -0
- package/out/src/services/providers/echangeRates.js +237 -0
- package/out/src/services/providers/echangeRates.js.map +1 -0
- package/out/src/services/providers/whatsonchain.d.ts +17 -0
- package/out/src/services/providers/whatsonchain.d.ts.map +1 -0
- package/out/src/services/providers/whatsonchain.js +130 -0
- package/out/src/services/providers/whatsonchain.js.map +1 -0
- package/out/src/signer/WalletSigner.d.ts +11 -0
- package/out/src/signer/WalletSigner.d.ts.map +1 -0
- package/out/src/signer/WalletSigner.js +13 -0
- package/out/src/signer/WalletSigner.js.map +1 -0
- package/out/src/signer/methods/acquireDirectCertificate.d.ts +4 -0
- package/out/src/signer/methods/acquireDirectCertificate.d.ts.map +1 -0
- package/out/src/signer/methods/acquireDirectCertificate.js +47 -0
- package/out/src/signer/methods/acquireDirectCertificate.js.map +1 -0
- package/out/src/signer/methods/createAction.d.ts +7 -0
- package/out/src/signer/methods/createAction.d.ts.map +1 -0
- package/out/src/signer/methods/createAction.js +250 -0
- package/out/src/signer/methods/createAction.js.map +1 -0
- package/out/src/signer/methods/internalizeAction.d.ts +31 -0
- package/out/src/signer/methods/internalizeAction.d.ts.map +1 -0
- package/out/src/signer/methods/internalizeAction.js +95 -0
- package/out/src/signer/methods/internalizeAction.js.map +1 -0
- package/out/src/signer/methods/proveCertificate.d.ts +4 -0
- package/out/src/signer/methods/proveCertificate.d.ts.map +1 -0
- package/out/src/signer/methods/proveCertificate.js +45 -0
- package/out/src/signer/methods/proveCertificate.js.map +1 -0
- package/out/src/signer/methods/signAction.d.ts +6 -0
- package/out/src/signer/methods/signAction.d.ts.map +1 -0
- package/out/src/signer/methods/signAction.js +79 -0
- package/out/src/signer/methods/signAction.js.map +1 -0
- package/out/src/storage/StorageKnex.d.ts +176 -0
- package/out/src/storage/StorageKnex.d.ts.map +1 -0
- package/out/src/storage/StorageKnex.js +1035 -0
- package/out/src/storage/StorageKnex.js.map +1 -0
- package/out/src/storage/StorageProvider.d.ts +140 -0
- package/out/src/storage/StorageProvider.d.ts.map +1 -0
- package/out/src/storage/StorageProvider.js +539 -0
- package/out/src/storage/StorageProvider.js.map +1 -0
- package/out/src/storage/StorageReader.d.ts +76 -0
- package/out/src/storage/StorageReader.d.ts.map +1 -0
- package/out/src/storage/StorageReader.js +124 -0
- package/out/src/storage/StorageReader.js.map +1 -0
- package/out/src/storage/StorageReaderWriter.d.ts +87 -0
- package/out/src/storage/StorageReaderWriter.d.ts.map +1 -0
- package/out/src/storage/StorageReaderWriter.js +337 -0
- package/out/src/storage/StorageReaderWriter.js.map +1 -0
- package/out/src/storage/StorageSyncReader.d.ts +33 -0
- package/out/src/storage/StorageSyncReader.d.ts.map +1 -0
- package/out/src/storage/StorageSyncReader.js +142 -0
- package/out/src/storage/StorageSyncReader.js.map +1 -0
- package/out/src/storage/WalletStorageManager.d.ts +103 -0
- package/out/src/storage/WalletStorageManager.d.ts.map +1 -0
- package/out/src/storage/WalletStorageManager.js +408 -0
- package/out/src/storage/WalletStorageManager.js.map +1 -0
- package/out/src/storage/__test/WalletStorageManager.test.d.ts +2 -0
- package/out/src/storage/__test/WalletStorageManager.test.d.ts.map +1 -0
- package/out/src/storage/__test/WalletStorageManager.test.js +260 -0
- package/out/src/storage/__test/WalletStorageManager.test.js.map +1 -0
- package/out/src/storage/index.all.d.ts +11 -0
- package/out/src/storage/index.all.d.ts.map +1 -0
- package/out/src/storage/index.all.js +50 -0
- package/out/src/storage/index.all.js.map +1 -0
- package/out/src/storage/index.client.d.ts +7 -0
- package/out/src/storage/index.client.d.ts.map +1 -0
- package/out/src/storage/index.client.js +46 -0
- package/out/src/storage/index.client.js.map +1 -0
- package/out/src/storage/index.db.d.ts +1 -0
- package/out/src/storage/index.db.d.ts.map +1 -0
- package/out/src/storage/index.db.js +2 -0
- package/out/src/storage/index.db.js.map +1 -0
- package/out/src/storage/methods/__test/GenerateChange/generateChangeSdk.test.d.ts +2 -0
- package/out/src/storage/methods/__test/GenerateChange/generateChangeSdk.test.d.ts.map +1 -0
- package/out/src/storage/methods/__test/GenerateChange/generateChangeSdk.test.js +948 -0
- package/out/src/storage/methods/__test/GenerateChange/generateChangeSdk.test.js.map +1 -0
- package/out/src/storage/methods/__test/GenerateChange/randomValsUsed1.d.ts +2 -0
- package/out/src/storage/methods/__test/GenerateChange/randomValsUsed1.d.ts.map +1 -0
- package/out/src/storage/methods/__test/GenerateChange/randomValsUsed1.js +35 -0
- package/out/src/storage/methods/__test/GenerateChange/randomValsUsed1.js.map +1 -0
- package/out/src/storage/methods/attemptToPostReqsToNetwork.d.ts +27 -0
- package/out/src/storage/methods/attemptToPostReqsToNetwork.d.ts.map +1 -0
- package/out/src/storage/methods/attemptToPostReqsToNetwork.js +148 -0
- package/out/src/storage/methods/attemptToPostReqsToNetwork.js.map +1 -0
- package/out/src/storage/methods/createAction.d.ts +23 -0
- package/out/src/storage/methods/createAction.d.ts.map +1 -0
- package/out/src/storage/methods/createAction.js +663 -0
- package/out/src/storage/methods/createAction.js.map +1 -0
- package/out/src/storage/methods/generateChange.d.ts +108 -0
- package/out/src/storage/methods/generateChange.d.ts.map +1 -0
- package/out/src/storage/methods/generateChange.js +422 -0
- package/out/src/storage/methods/generateChange.js.map +1 -0
- package/out/src/storage/methods/getBeefForTransaction.d.ts +22 -0
- package/out/src/storage/methods/getBeefForTransaction.d.ts.map +1 -0
- package/out/src/storage/methods/getBeefForTransaction.js +94 -0
- package/out/src/storage/methods/getBeefForTransaction.js.map +1 -0
- package/out/src/storage/methods/getSyncChunk.d.ts +10 -0
- package/out/src/storage/methods/getSyncChunk.d.ts.map +1 -0
- package/out/src/storage/methods/getSyncChunk.js +271 -0
- package/out/src/storage/methods/getSyncChunk.js.map +1 -0
- package/out/src/storage/methods/internalizeAction.d.ts +38 -0
- package/out/src/storage/methods/internalizeAction.d.ts.map +1 -0
- package/out/src/storage/methods/internalizeAction.js +378 -0
- package/out/src/storage/methods/internalizeAction.js.map +1 -0
- package/out/src/storage/methods/listActions.d.ts +5 -0
- package/out/src/storage/methods/listActions.d.ts.map +1 -0
- package/out/src/storage/methods/listActions.js +174 -0
- package/out/src/storage/methods/listActions.js.map +1 -0
- package/out/src/storage/methods/listCertificates.d.ts +5 -0
- package/out/src/storage/methods/listCertificates.d.ts.map +1 -0
- package/out/src/storage/methods/listCertificates.js +68 -0
- package/out/src/storage/methods/listCertificates.js.map +1 -0
- package/out/src/storage/methods/listOutputs.d.ts +5 -0
- package/out/src/storage/methods/listOutputs.d.ts.map +1 -0
- package/out/src/storage/methods/listOutputs.js +189 -0
- package/out/src/storage/methods/listOutputs.js.map +1 -0
- package/out/src/storage/methods/processAction.d.ts +35 -0
- package/out/src/storage/methods/processAction.d.ts.map +1 -0
- package/out/src/storage/methods/processAction.js +271 -0
- package/out/src/storage/methods/processAction.js.map +1 -0
- package/out/src/storage/methods/purgeData.d.ts +4 -0
- package/out/src/storage/methods/purgeData.d.ts.map +1 -0
- package/out/src/storage/methods/purgeData.js +229 -0
- package/out/src/storage/methods/purgeData.js.map +1 -0
- package/out/src/storage/methods/reviewStatus.d.ts +9 -0
- package/out/src/storage/methods/reviewStatus.d.ts.map +1 -0
- package/out/src/storage/methods/reviewStatus.js +75 -0
- package/out/src/storage/methods/reviewStatus.js.map +1 -0
- package/out/src/storage/remoting/StorageClient.d.ts +56 -0
- package/out/src/storage/remoting/StorageClient.d.ts.map +1 -0
- package/out/src/storage/remoting/StorageClient.js +181 -0
- package/out/src/storage/remoting/StorageClient.js.map +1 -0
- package/out/src/storage/remoting/StorageServer.d.ts +26 -0
- package/out/src/storage/remoting/StorageServer.d.ts.map +1 -0
- package/out/src/storage/remoting/StorageServer.js +144 -0
- package/out/src/storage/remoting/StorageServer.js.map +1 -0
- package/out/src/storage/schema/KnexMigrations.d.ts +39 -0
- package/out/src/storage/schema/KnexMigrations.d.ts.map +1 -0
- package/out/src/storage/schema/KnexMigrations.js +442 -0
- package/out/src/storage/schema/KnexMigrations.js.map +1 -0
- package/out/src/storage/schema/entities/Certificate.d.ts +43 -0
- package/out/src/storage/schema/entities/Certificate.d.ts.map +1 -0
- package/out/src/storage/schema/entities/Certificate.js +162 -0
- package/out/src/storage/schema/entities/Certificate.js.map +1 -0
- package/out/src/storage/schema/entities/CertificateField.d.ts +32 -0
- package/out/src/storage/schema/entities/CertificateField.d.ts.map +1 -0
- package/out/src/storage/schema/entities/CertificateField.js +114 -0
- package/out/src/storage/schema/entities/CertificateField.js.map +1 -0
- package/out/src/storage/schema/entities/Commission.d.ts +37 -0
- package/out/src/storage/schema/entities/Commission.d.ts.map +1 -0
- package/out/src/storage/schema/entities/Commission.js +130 -0
- package/out/src/storage/schema/entities/Commission.js.map +1 -0
- package/out/src/storage/schema/entities/EntityBase.d.ts +105 -0
- package/out/src/storage/schema/entities/EntityBase.d.ts.map +1 -0
- package/out/src/storage/schema/entities/EntityBase.js +100 -0
- package/out/src/storage/schema/entities/EntityBase.js.map +1 -0
- package/out/src/storage/schema/entities/MergeEntity.d.ts +34 -0
- package/out/src/storage/schema/entities/MergeEntity.d.ts.map +1 -0
- package/out/src/storage/schema/entities/MergeEntity.js +57 -0
- package/out/src/storage/schema/entities/MergeEntity.js.map +1 -0
- package/out/src/storage/schema/entities/Output.d.ts +67 -0
- package/out/src/storage/schema/entities/Output.d.ts.map +1 -0
- package/out/src/storage/schema/entities/Output.js +281 -0
- package/out/src/storage/schema/entities/Output.js.map +1 -0
- package/out/src/storage/schema/entities/OutputBasket.d.ts +35 -0
- package/out/src/storage/schema/entities/OutputBasket.d.ts.map +1 -0
- package/out/src/storage/schema/entities/OutputBasket.js +133 -0
- package/out/src/storage/schema/entities/OutputBasket.js.map +1 -0
- package/out/src/storage/schema/entities/OutputTag.d.ts +31 -0
- package/out/src/storage/schema/entities/OutputTag.d.ts.map +1 -0
- package/out/src/storage/schema/entities/OutputTag.js +104 -0
- package/out/src/storage/schema/entities/OutputTag.js.map +1 -0
- package/out/src/storage/schema/entities/OutputTagMap.d.ts +28 -0
- package/out/src/storage/schema/entities/OutputTagMap.d.ts.map +1 -0
- package/out/src/storage/schema/entities/OutputTagMap.js +101 -0
- package/out/src/storage/schema/entities/OutputTagMap.js.map +1 -0
- package/out/src/storage/schema/entities/ProvenTx.d.ts +84 -0
- package/out/src/storage/schema/entities/ProvenTx.d.ts.map +1 -0
- package/out/src/storage/schema/entities/ProvenTx.js +283 -0
- package/out/src/storage/schema/entities/ProvenTx.js.map +1 -0
- package/out/src/storage/schema/entities/ProvenTxReq.d.ts +130 -0
- package/out/src/storage/schema/entities/ProvenTxReq.d.ts.map +1 -0
- package/out/src/storage/schema/entities/ProvenTxReq.js +521 -0
- package/out/src/storage/schema/entities/ProvenTxReq.js.map +1 -0
- package/out/src/storage/schema/entities/SyncState.d.ts +66 -0
- package/out/src/storage/schema/entities/SyncState.d.ts.map +1 -0
- package/out/src/storage/schema/entities/SyncState.js +284 -0
- package/out/src/storage/schema/entities/SyncState.js.map +1 -0
- package/out/src/storage/schema/entities/Transaction.d.ts +67 -0
- package/out/src/storage/schema/entities/Transaction.d.ts.map +1 -0
- package/out/src/storage/schema/entities/Transaction.js +264 -0
- package/out/src/storage/schema/entities/Transaction.js.map +1 -0
- package/out/src/storage/schema/entities/TxLabel.d.ts +31 -0
- package/out/src/storage/schema/entities/TxLabel.d.ts.map +1 -0
- package/out/src/storage/schema/entities/TxLabel.js +104 -0
- package/out/src/storage/schema/entities/TxLabel.js.map +1 -0
- package/out/src/storage/schema/entities/TxLabelMap.d.ts +28 -0
- package/out/src/storage/schema/entities/TxLabelMap.d.ts.map +1 -0
- package/out/src/storage/schema/entities/TxLabelMap.js +103 -0
- package/out/src/storage/schema/entities/TxLabelMap.js.map +1 -0
- package/out/src/storage/schema/entities/User.d.ts +29 -0
- package/out/src/storage/schema/entities/User.d.ts.map +1 -0
- package/out/src/storage/schema/entities/User.js +100 -0
- package/out/src/storage/schema/entities/User.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/CertificateFieldTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/CertificateFieldTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/CertificateFieldTests.test.js +588 -0
- package/out/src/storage/schema/entities/__tests/CertificateFieldTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/CertificateTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/CertificateTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/CertificateTests.test.js +449 -0
- package/out/src/storage/schema/entities/__tests/CertificateTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/CommissionTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/CommissionTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/CommissionTests.test.js +602 -0
- package/out/src/storage/schema/entities/__tests/CommissionTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputBasketTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/OutputBasketTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputBasketTests.test.js +515 -0
- package/out/src/storage/schema/entities/__tests/OutputBasketTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputTagMapTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/OutputTagMapTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputTagMapTests.test.js +478 -0
- package/out/src/storage/schema/entities/__tests/OutputTagMapTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputTagTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/OutputTagTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputTagTests.test.js +440 -0
- package/out/src/storage/schema/entities/__tests/OutputTagTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/OutputTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/OutputTests.test.js +626 -0
- package/out/src/storage/schema/entities/__tests/OutputTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxReqTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxReqTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxReqTests.test.js +585 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxReqTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxTests.test.js +628 -0
- package/out/src/storage/schema/entities/__tests/ProvenTxTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/SyncStateTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/SyncStateTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/SyncStateTests.test.js +307 -0
- package/out/src/storage/schema/entities/__tests/SyncStateTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/TransactionTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/TransactionTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/TransactionTests.test.js +823 -0
- package/out/src/storage/schema/entities/__tests/TransactionTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/TxLabelMapTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/TxLabelMapTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/TxLabelMapTests.test.js +442 -0
- package/out/src/storage/schema/entities/__tests/TxLabelMapTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/TxLabelTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/TxLabelTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/TxLabelTests.test.js +313 -0
- package/out/src/storage/schema/entities/__tests/TxLabelTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/stampLogTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/stampLogTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/stampLogTests.test.js +81 -0
- package/out/src/storage/schema/entities/__tests/stampLogTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/__tests/usersTests.test.d.ts +2 -0
- package/out/src/storage/schema/entities/__tests/usersTests.test.d.ts.map +1 -0
- package/out/src/storage/schema/entities/__tests/usersTests.test.js +418 -0
- package/out/src/storage/schema/entities/__tests/usersTests.test.js.map +1 -0
- package/out/src/storage/schema/entities/index.d.ts +17 -0
- package/out/src/storage/schema/entities/index.d.ts.map +1 -0
- package/out/src/storage/schema/entities/index.js +33 -0
- package/out/src/storage/schema/entities/index.js.map +1 -0
- package/out/src/storage/schema/tables/Certificate.d.ts +20 -0
- package/out/src/storage/schema/tables/Certificate.d.ts.map +1 -0
- package/out/src/storage/schema/tables/Certificate.js +3 -0
- package/out/src/storage/schema/tables/Certificate.js.map +1 -0
- package/out/src/storage/schema/tables/CertificateField.d.ts +12 -0
- package/out/src/storage/schema/tables/CertificateField.d.ts.map +1 -0
- package/out/src/storage/schema/tables/CertificateField.js +3 -0
- package/out/src/storage/schema/tables/CertificateField.js.map +1 -0
- package/out/src/storage/schema/tables/Commission.d.ts +13 -0
- package/out/src/storage/schema/tables/Commission.d.ts.map +1 -0
- package/out/src/storage/schema/tables/Commission.js +3 -0
- package/out/src/storage/schema/tables/Commission.js.map +1 -0
- package/out/src/storage/schema/tables/MonitorEvent.d.ts +9 -0
- package/out/src/storage/schema/tables/MonitorEvent.d.ts.map +1 -0
- package/out/src/storage/schema/tables/MonitorEvent.js +3 -0
- package/out/src/storage/schema/tables/MonitorEvent.js.map +1 -0
- package/out/src/storage/schema/tables/Output.d.ts +36 -0
- package/out/src/storage/schema/tables/Output.d.ts.map +1 -0
- package/out/src/storage/schema/tables/Output.js +31 -0
- package/out/src/storage/schema/tables/Output.js.map +1 -0
- package/out/src/storage/schema/tables/OutputBasket.d.ts +12 -0
- package/out/src/storage/schema/tables/OutputBasket.d.ts.map +1 -0
- package/out/src/storage/schema/tables/OutputBasket.js +3 -0
- package/out/src/storage/schema/tables/OutputBasket.js.map +1 -0
- package/out/src/storage/schema/tables/OutputTag.d.ts +10 -0
- package/out/src/storage/schema/tables/OutputTag.d.ts.map +1 -0
- package/out/src/storage/schema/tables/OutputTag.js +3 -0
- package/out/src/storage/schema/tables/OutputTag.js.map +1 -0
- package/out/src/storage/schema/tables/OutputTagMap.d.ts +9 -0
- package/out/src/storage/schema/tables/OutputTagMap.d.ts.map +1 -0
- package/out/src/storage/schema/tables/OutputTagMap.js +3 -0
- package/out/src/storage/schema/tables/OutputTagMap.js.map +1 -0
- package/out/src/storage/schema/tables/ProvenTx.d.ts +14 -0
- package/out/src/storage/schema/tables/ProvenTx.d.ts.map +1 -0
- package/out/src/storage/schema/tables/ProvenTx.js +3 -0
- package/out/src/storage/schema/tables/ProvenTx.js.map +1 -0
- package/out/src/storage/schema/tables/ProvenTxReq.d.ts +64 -0
- package/out/src/storage/schema/tables/ProvenTxReq.d.ts.map +1 -0
- package/out/src/storage/schema/tables/ProvenTxReq.js +3 -0
- package/out/src/storage/schema/tables/ProvenTxReq.js.map +1 -0
- package/out/src/storage/schema/tables/Settings.d.ts +17 -0
- package/out/src/storage/schema/tables/Settings.d.ts.map +1 -0
- package/out/src/storage/schema/tables/Settings.js +3 -0
- package/out/src/storage/schema/tables/Settings.js.map +1 -0
- package/out/src/storage/schema/tables/SyncState.d.ts +18 -0
- package/out/src/storage/schema/tables/SyncState.d.ts.map +1 -0
- package/out/src/storage/schema/tables/SyncState.js +3 -0
- package/out/src/storage/schema/tables/SyncState.js.map +1 -0
- package/out/src/storage/schema/tables/Transaction.d.ts +37 -0
- package/out/src/storage/schema/tables/Transaction.d.ts.map +1 -0
- package/out/src/storage/schema/tables/Transaction.js +21 -0
- package/out/src/storage/schema/tables/Transaction.js.map +1 -0
- package/out/src/storage/schema/tables/TxLabel.d.ts +10 -0
- package/out/src/storage/schema/tables/TxLabel.d.ts.map +1 -0
- package/out/src/storage/schema/tables/TxLabel.js +3 -0
- package/out/src/storage/schema/tables/TxLabel.js.map +1 -0
- package/out/src/storage/schema/tables/TxLabelMap.d.ts +9 -0
- package/out/src/storage/schema/tables/TxLabelMap.d.ts.map +1 -0
- package/out/src/storage/schema/tables/TxLabelMap.js +3 -0
- package/out/src/storage/schema/tables/TxLabelMap.js.map +1 -0
- package/out/src/storage/schema/tables/User.d.ts +16 -0
- package/out/src/storage/schema/tables/User.d.ts.map +1 -0
- package/out/src/storage/schema/tables/User.js +3 -0
- package/out/src/storage/schema/tables/User.js.map +1 -0
- package/out/src/storage/schema/tables/index.d.ts +17 -0
- package/out/src/storage/schema/tables/index.d.ts.map +1 -0
- package/out/src/storage/schema/tables/index.js +33 -0
- package/out/src/storage/schema/tables/index.js.map +1 -0
- package/out/src/storage/sync/StorageMySQLDojoReader.d.ts +71 -0
- package/out/src/storage/sync/StorageMySQLDojoReader.d.ts.map +1 -0
- package/out/src/storage/sync/StorageMySQLDojoReader.js +612 -0
- package/out/src/storage/sync/StorageMySQLDojoReader.js.map +1 -0
- package/out/src/storage/sync/index.d.ts +2 -0
- package/out/src/storage/sync/index.d.ts.map +1 -0
- package/out/src/storage/sync/index.js +18 -0
- package/out/src/storage/sync/index.js.map +1 -0
- package/out/src/utility/ScriptTemplateSABPPP.d.ts +25 -0
- package/out/src/utility/ScriptTemplateSABPPP.d.ts.map +1 -0
- package/out/src/utility/ScriptTemplateSABPPP.js +46 -0
- package/out/src/utility/ScriptTemplateSABPPP.js.map +1 -0
- package/out/src/utility/index.all.d.ts +7 -0
- package/out/src/utility/index.all.d.ts.map +1 -0
- package/out/src/utility/index.all.js +23 -0
- package/out/src/utility/index.all.js.map +1 -0
- package/out/src/utility/index.client.d.ts +7 -0
- package/out/src/utility/index.client.d.ts.map +1 -0
- package/out/src/utility/index.client.js +23 -0
- package/out/src/utility/index.client.js.map +1 -0
- package/out/src/utility/parseTxScriptOffsets.d.ts +14 -0
- package/out/src/utility/parseTxScriptOffsets.d.ts.map +1 -0
- package/out/src/utility/parseTxScriptOffsets.js +26 -0
- package/out/src/utility/parseTxScriptOffsets.js.map +1 -0
- package/out/src/utility/stampLog.d.ts +18 -0
- package/out/src/utility/stampLog.d.ts.map +1 -0
- package/out/src/utility/stampLog.js +72 -0
- package/out/src/utility/stampLog.js.map +1 -0
- package/out/src/utility/tscProofToMerklePath.d.ts +8 -0
- package/out/src/utility/tscProofToMerklePath.d.ts.map +1 -0
- package/out/src/utility/tscProofToMerklePath.js +41 -0
- package/out/src/utility/tscProofToMerklePath.js.map +1 -0
- package/out/src/utility/utilityHelpers.buffer.d.ts +18 -0
- package/out/src/utility/utilityHelpers.buffer.d.ts.map +1 -0
- package/out/src/utility/utilityHelpers.buffer.js +45 -0
- package/out/src/utility/utilityHelpers.buffer.js.map +1 -0
- package/out/src/utility/utilityHelpers.d.ts +129 -0
- package/out/src/utility/utilityHelpers.d.ts.map +1 -0
- package/out/src/utility/utilityHelpers.js +268 -0
- package/out/src/utility/utilityHelpers.js.map +1 -0
- package/out/src/utility/utilityHelpers.noBuffer.d.ts +9 -0
- package/out/src/utility/utilityHelpers.noBuffer.d.ts.map +1 -0
- package/out/src/utility/utilityHelpers.noBuffer.js +23 -0
- package/out/src/utility/utilityHelpers.noBuffer.js.map +1 -0
- package/out/test/Wallet/StorageClient/storageClient.man.test.d.ts +2 -0
- package/out/test/Wallet/StorageClient/storageClient.man.test.d.ts.map +1 -0
- package/out/test/Wallet/StorageClient/storageClient.man.test.js +45 -0
- package/out/test/Wallet/StorageClient/storageClient.man.test.js.map +1 -0
- package/out/test/Wallet/action/internalizeAction.a.test.d.ts +2 -0
- package/out/test/Wallet/action/internalizeAction.a.test.d.ts.map +1 -0
- package/out/test/Wallet/action/internalizeAction.a.test.js +243 -0
- package/out/test/Wallet/action/internalizeAction.a.test.js.map +1 -0
- package/out/test/Wallet/certificate/acquireCertificate.test.d.ts +2 -0
- package/out/test/Wallet/certificate/acquireCertificate.test.d.ts.map +1 -0
- package/out/test/Wallet/certificate/acquireCertificate.test.js +213 -0
- package/out/test/Wallet/certificate/acquireCertificate.test.js.map +1 -0
- package/out/test/Wallet/certificate/listCertificates.test.d.ts +2 -0
- package/out/test/Wallet/certificate/listCertificates.test.d.ts.map +1 -0
- package/out/test/Wallet/certificate/listCertificates.test.js +305 -0
- package/out/test/Wallet/certificate/listCertificates.test.js.map +1 -0
- package/out/test/Wallet/get/getHeaderForHeight.test.d.ts +2 -0
- package/out/test/Wallet/get/getHeaderForHeight.test.d.ts.map +1 -0
- package/out/test/Wallet/get/getHeaderForHeight.test.js +68 -0
- package/out/test/Wallet/get/getHeaderForHeight.test.js.map +1 -0
- package/out/test/Wallet/get/getHeight.test.d.ts +2 -0
- package/out/test/Wallet/get/getHeight.test.d.ts.map +1 -0
- package/out/test/Wallet/get/getHeight.test.js +45 -0
- package/out/test/Wallet/get/getHeight.test.js.map +1 -0
- package/out/test/Wallet/get/getKnownTxids.test.d.ts +2 -0
- package/out/test/Wallet/get/getKnownTxids.test.d.ts.map +1 -0
- package/out/test/Wallet/get/getKnownTxids.test.js +73 -0
- package/out/test/Wallet/get/getKnownTxids.test.js.map +1 -0
- package/out/test/Wallet/get/getNetwork.test.d.ts +2 -0
- package/out/test/Wallet/get/getNetwork.test.d.ts.map +1 -0
- package/out/test/Wallet/get/getNetwork.test.js +26 -0
- package/out/test/Wallet/get/getNetwork.test.js.map +1 -0
- package/out/test/Wallet/get/getVersion.test.d.ts +2 -0
- package/out/test/Wallet/get/getVersion.test.d.ts.map +1 -0
- package/out/test/Wallet/get/getVersion.test.js +25 -0
- package/out/test/Wallet/get/getVersion.test.js.map +1 -0
- package/out/test/Wallet/live/walletLive.man.test.d.ts +26 -0
- package/out/test/Wallet/live/walletLive.man.test.d.ts.map +1 -0
- package/out/test/Wallet/live/walletLive.man.test.js +389 -0
- package/out/test/Wallet/live/walletLive.man.test.js.map +1 -0
- package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.d.ts +2 -0
- package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.d.ts.map +1 -0
- package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.js +153 -0
- package/out/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.js.map +1 -0
- package/out/test/checkDB.d.ts +4 -0
- package/out/test/checkDB.d.ts.map +1 -0
- package/out/test/checkDB.js +55 -0
- package/out/test/checkDB.js.map +1 -0
- package/out/test/examples/README.man.test.d.ts +2 -0
- package/out/test/examples/README.man.test.d.ts.map +1 -0
- package/out/test/examples/README.man.test.js +46 -0
- package/out/test/examples/README.man.test.js.map +1 -0
- package/out/test/monitor/Monitor.test.d.ts +2 -0
- package/out/test/monitor/Monitor.test.d.ts.map +1 -0
- package/out/test/monitor/Monitor.test.js +446 -0
- package/out/test/monitor/Monitor.test.js.map +1 -0
- package/out/test/services/Services.test.d.ts +2 -0
- package/out/test/services/Services.test.d.ts.map +1 -0
- package/out/test/services/Services.test.js +128 -0
- package/out/test/services/Services.test.js.map +1 -0
- package/out/test/storage/KnexMigrations.test.d.ts +2 -0
- package/out/test/storage/KnexMigrations.test.d.ts.map +1 -0
- package/out/test/storage/KnexMigrations.test.js +81 -0
- package/out/test/storage/KnexMigrations.test.js.map +1 -0
- package/out/test/storage/StorageMySQLDojoReader.man.test.d.ts +2 -0
- package/out/test/storage/StorageMySQLDojoReader.man.test.d.ts.map +1 -0
- package/out/test/storage/StorageMySQLDojoReader.man.test.js +88 -0
- package/out/test/storage/StorageMySQLDojoReader.man.test.js.map +1 -0
- package/out/test/storage/count.test.d.ts +2 -0
- package/out/test/storage/count.test.d.ts.map +1 -0
- package/out/test/storage/count.test.js +141 -0
- package/out/test/storage/count.test.js.map +1 -0
- package/out/test/storage/find.test.d.ts +2 -0
- package/out/test/storage/find.test.d.ts.map +1 -0
- package/out/test/storage/find.test.js +148 -0
- package/out/test/storage/find.test.js.map +1 -0
- package/out/test/storage/findLegacy.test.d.ts +2 -0
- package/out/test/storage/findLegacy.test.d.ts.map +1 -0
- package/out/test/storage/findLegacy.test.js +52 -0
- package/out/test/storage/findLegacy.test.js.map +1 -0
- package/out/test/storage/insert.test.d.ts +2 -0
- package/out/test/storage/insert.test.d.ts.map +1 -0
- package/out/test/storage/insert.test.js +256 -0
- package/out/test/storage/insert.test.js.map +1 -0
- package/out/test/storage/update.test.d.ts +2 -0
- package/out/test/storage/update.test.d.ts.map +1 -0
- package/out/test/storage/update.test.js +926 -0
- package/out/test/storage/update.test.js.map +1 -0
- package/out/test/storage/update2.test.d.ts +2 -0
- package/out/test/storage/update2.test.d.ts.map +1 -0
- package/out/test/storage/update2.test.js +766 -0
- package/out/test/storage/update2.test.js.map +1 -0
- package/out/test/utils/TestUtilsWalletStorage.d.ts +399 -0
- package/out/test/utils/TestUtilsWalletStorage.d.ts.map +1 -0
- package/out/test/utils/TestUtilsWalletStorage.js +1337 -0
- package/out/test/utils/TestUtilsWalletStorage.js.map +1 -0
- package/out/test/wallet/action/abortAction.test.d.ts +2 -0
- package/out/test/wallet/action/abortAction.test.d.ts.map +1 -0
- package/out/test/wallet/action/abortAction.test.js +44 -0
- package/out/test/wallet/action/abortAction.test.js.map +1 -0
- package/out/test/wallet/action/createAction.test.d.ts +2 -0
- package/out/test/wallet/action/createAction.test.d.ts.map +1 -0
- package/out/test/wallet/action/createAction.test.js +230 -0
- package/out/test/wallet/action/createAction.test.js.map +1 -0
- package/out/test/wallet/action/createActionToGenerateBeefs.man.test.d.ts +2 -0
- package/out/test/wallet/action/createActionToGenerateBeefs.man.test.d.ts.map +1 -0
- package/out/test/wallet/action/createActionToGenerateBeefs.man.test.js +273 -0
- package/out/test/wallet/action/createActionToGenerateBeefs.man.test.js.map +1 -0
- package/out/test/wallet/action/internalizeAction.test.d.ts +2 -0
- package/out/test/wallet/action/internalizeAction.test.d.ts.map +1 -0
- package/out/test/wallet/action/internalizeAction.test.js +603 -0
- package/out/test/wallet/action/internalizeAction.test.js.map +1 -0
- package/out/test/wallet/action/relinquishOutput.test.d.ts +2 -0
- package/out/test/wallet/action/relinquishOutput.test.d.ts.map +1 -0
- package/out/test/wallet/action/relinquishOutput.test.js +31 -0
- package/out/test/wallet/action/relinquishOutput.test.js.map +1 -0
- package/out/test/wallet/construct/Wallet.constructor.test.d.ts +2 -0
- package/out/test/wallet/construct/Wallet.constructor.test.d.ts.map +1 -0
- package/out/test/wallet/construct/Wallet.constructor.test.js +49 -0
- package/out/test/wallet/construct/Wallet.constructor.test.js.map +1 -0
- package/out/test/wallet/list/listActions.test.d.ts +2 -0
- package/out/test/wallet/list/listActions.test.d.ts.map +1 -0
- package/out/test/wallet/list/listActions.test.js +265 -0
- package/out/test/wallet/list/listActions.test.js.map +1 -0
- package/out/test/wallet/list/listActions2.test.d.ts +2 -0
- package/out/test/wallet/list/listActions2.test.d.ts.map +1 -0
- package/out/test/wallet/list/listActions2.test.js +423 -0
- package/out/test/wallet/list/listActions2.test.js.map +1 -0
- package/out/test/wallet/list/listCertificates.test.d.ts +2 -0
- package/out/test/wallet/list/listCertificates.test.d.ts.map +1 -0
- package/out/test/wallet/list/listCertificates.test.js +115 -0
- package/out/test/wallet/list/listCertificates.test.js.map +1 -0
- package/out/test/wallet/list/listOutputs.test.d.ts +2 -0
- package/out/test/wallet/list/listOutputs.test.d.ts.map +1 -0
- package/out/test/wallet/list/listOutputs.test.js +521 -0
- package/out/test/wallet/list/listOutputs.test.js.map +1 -0
- package/out/test/wallet/sync/Wallet.sync.test.d.ts +2 -0
- package/out/test/wallet/sync/Wallet.sync.test.d.ts.map +1 -0
- package/out/test/wallet/sync/Wallet.sync.test.js +142 -0
- package/out/test/wallet/sync/Wallet.sync.test.js.map +1 -0
- package/out/tsconfig.all.tsbuildinfo +1 -0
- package/package.json +63 -0
- package/src/Wallet.ts +771 -0
- package/src/index.all.ts +8 -0
- package/src/index.client.ts +7 -0
- package/src/index.ts +2 -0
- package/src/monitor/Monitor.ts +317 -0
- package/src/monitor/MonitorDaemon.ts +197 -0
- package/src/monitor/README.md +3 -0
- package/src/monitor/__test/MonitorDaemon.man.test.ts +17 -0
- package/src/monitor/tasks/TaskCheckForProofs.ts +235 -0
- package/src/monitor/tasks/TaskClock.ts +35 -0
- package/src/monitor/tasks/TaskFailAbandoned.ts +56 -0
- package/src/monitor/tasks/TaskNewHeader.ts +48 -0
- package/src/monitor/tasks/TaskPurge.ts +69 -0
- package/src/monitor/tasks/TaskReviewStatus.ts +51 -0
- package/src/monitor/tasks/TaskSendWaiting.ts +107 -0
- package/src/monitor/tasks/TaskSyncWhenIdle.ts +26 -0
- package/src/monitor/tasks/WalletMonitorTask.ts +47 -0
- package/src/sdk/CertOps.ts +346 -0
- package/src/sdk/PrivilegedKeyManager.ts +402 -0
- package/src/sdk/README.md +13 -0
- package/src/sdk/StorageSyncReader.ts +155 -0
- package/src/sdk/StorageSyncReaderWriter.ts +263 -0
- package/src/sdk/WERR_errors.ts +152 -0
- package/src/sdk/WalletError.ts +136 -0
- package/src/sdk/WalletServices.interfaces.ts +399 -0
- package/src/sdk/WalletSigner.interfaces.ts +38 -0
- package/src/sdk/WalletStorage.interfaces.ts +416 -0
- package/src/sdk/__test/CertificateLifeCycle.test.ts +194 -0
- package/src/sdk/__test/PrivilegedKeyManager.test.ts +775 -0
- package/src/sdk/index.ts +11 -0
- package/src/sdk/types.ts +115 -0
- package/src/sdk/validationHelpers.ts +1248 -0
- package/src/services/README.md +11 -0
- package/src/services/ServiceCollection.ts +50 -0
- package/src/services/Services.ts +461 -0
- package/src/services/__tests/getMerklePath.test.ts +16 -0
- package/src/services/__tests/getRawTx.test.ts +15 -0
- package/src/services/__tests/postBeef.test.ts +19 -0
- package/src/services/__tests/postBeefToArcTaal.test.ts +487 -0
- package/src/services/__tests/postTxs.test.ts +20 -0
- package/src/services/chaintracker/ChaintracksChainTracker.ts +78 -0
- package/src/services/chaintracker/__tests/ChaintracksChainTracker.test.ts +25 -0
- package/src/services/chaintracker/__tests/ChaintracksServiceClient.test.ts +32 -0
- package/src/services/chaintracker/chaintracks/BlockHeaderApi.ts +123 -0
- package/src/services/chaintracker/chaintracks/ChaintracksServiceClient.ts +160 -0
- package/src/services/chaintracker/chaintracks/index.ts +2 -0
- package/src/services/chaintracker/index.ts +2 -0
- package/src/services/createDefaultWalletServicesOptions.ts +38 -0
- package/src/services/index.ts +1 -0
- package/src/services/providers/arcServices.ts +570 -0
- package/src/services/providers/echangeRates.ts +276 -0
- package/src/services/providers/whatsonchain.ts +170 -0
- package/src/signer/README.md +5 -0
- package/src/signer/WalletSigner.ts +21 -0
- package/src/signer/methods/acquireDirectCertificate.ts +53 -0
- package/src/signer/methods/createAction.ts +364 -0
- package/src/signer/methods/internalizeAction.ts +142 -0
- package/src/signer/methods/proveCertificate.ts +51 -0
- package/src/signer/methods/signAction.ts +121 -0
- package/src/storage/README.md +14 -0
- package/src/storage/StorageKnex.ts +1449 -0
- package/src/storage/StorageProvider.ts +853 -0
- package/src/storage/StorageReader.ts +222 -0
- package/src/storage/StorageReaderWriter.ts +623 -0
- package/src/storage/StorageSyncReader.ts +143 -0
- package/src/storage/WalletStorageManager.ts +532 -0
- package/src/storage/__test/WalletStorageManager.test.ts +292 -0
- package/src/storage/index.all.ts +10 -0
- package/src/storage/index.client.ts +6 -0
- package/src/storage/index.db.ts +0 -0
- package/src/storage/methods/__test/GenerateChange/generateChangeSdk.test.ts +1143 -0
- package/src/storage/methods/__test/GenerateChange/randomValsUsed1.ts +31 -0
- package/src/storage/methods/attemptToPostReqsToNetwork.ts +185 -0
- package/src/storage/methods/createAction.ts +997 -0
- package/src/storage/methods/generateChange.ts +629 -0
- package/src/storage/methods/getBeefForTransaction.ts +143 -0
- package/src/storage/methods/getSyncChunk.ts +330 -0
- package/src/storage/methods/internalizeAction.ts +538 -0
- package/src/storage/methods/listActions.ts +203 -0
- package/src/storage/methods/listCertificates.ts +81 -0
- package/src/storage/methods/listOutputs.ts +219 -0
- package/src/storage/methods/processAction.ts +477 -0
- package/src/storage/methods/purgeData.ts +276 -0
- package/src/storage/methods/reviewStatus.ts +95 -0
- package/src/storage/remoting/StorageClient.ts +306 -0
- package/src/storage/remoting/StorageServer.ts +179 -0
- package/src/storage/schema/KnexMigrations.ts +488 -0
- package/src/storage/schema/entities/Certificate.ts +199 -0
- package/src/storage/schema/entities/CertificateField.ts +157 -0
- package/src/storage/schema/entities/Commission.ts +169 -0
- package/src/storage/schema/entities/EntityBase.ts +214 -0
- package/src/storage/schema/entities/MergeEntity.ts +79 -0
- package/src/storage/schema/entities/Output.ts +323 -0
- package/src/storage/schema/entities/OutputBasket.ts +165 -0
- package/src/storage/schema/entities/OutputTag.ts +138 -0
- package/src/storage/schema/entities/OutputTagMap.ts +146 -0
- package/src/storage/schema/entities/ProvenTx.ts +349 -0
- package/src/storage/schema/entities/ProvenTxReq.ts +646 -0
- package/src/storage/schema/entities/SyncState.ts +429 -0
- package/src/storage/schema/entities/Transaction.ts +334 -0
- package/src/storage/schema/entities/TxLabel.ts +135 -0
- package/src/storage/schema/entities/TxLabelMap.ts +148 -0
- package/src/storage/schema/entities/User.ts +138 -0
- package/src/storage/schema/entities/__tests/CertificateFieldTests.test.ts +663 -0
- package/src/storage/schema/entities/__tests/CertificateTests.test.ts +527 -0
- package/src/storage/schema/entities/__tests/CommissionTests.test.ts +658 -0
- package/src/storage/schema/entities/__tests/OutputBasketTests.test.ts +567 -0
- package/src/storage/schema/entities/__tests/OutputTagMapTests.test.ts +530 -0
- package/src/storage/schema/entities/__tests/OutputTagTests.test.ts +504 -0
- package/src/storage/schema/entities/__tests/OutputTests.test.ts +689 -0
- package/src/storage/schema/entities/__tests/ProvenTxReqTests.test.ts +669 -0
- package/src/storage/schema/entities/__tests/ProvenTxTests.test.ts +700 -0
- package/src/storage/schema/entities/__tests/SyncStateTests.test.ts +376 -0
- package/src/storage/schema/entities/__tests/TransactionTests.test.ts +920 -0
- package/src/storage/schema/entities/__tests/TxLabelMapTests.test.ts +512 -0
- package/src/storage/schema/entities/__tests/TxLabelTests.test.ts +350 -0
- package/src/storage/schema/entities/__tests/stampLogTests.test.ts +97 -0
- package/src/storage/schema/entities/__tests/usersTests.test.ts +485 -0
- package/src/storage/schema/entities/index.ts +16 -0
- package/src/storage/schema/tables/Certificate.ts +21 -0
- package/src/storage/schema/tables/CertificateField.ts +12 -0
- package/src/storage/schema/tables/Commission.ts +13 -0
- package/src/storage/schema/tables/MonitorEvent.ts +9 -0
- package/src/storage/schema/tables/Output.ts +64 -0
- package/src/storage/schema/tables/OutputBasket.ts +12 -0
- package/src/storage/schema/tables/OutputTag.ts +10 -0
- package/src/storage/schema/tables/OutputTagMap.ts +9 -0
- package/src/storage/schema/tables/ProvenTx.ts +14 -0
- package/src/storage/schema/tables/ProvenTxReq.ts +65 -0
- package/src/storage/schema/tables/Settings.ts +17 -0
- package/src/storage/schema/tables/SyncState.ts +18 -0
- package/src/storage/schema/tables/Transaction.ts +54 -0
- package/src/storage/schema/tables/TxLabel.ts +10 -0
- package/src/storage/schema/tables/TxLabelMap.ts +9 -0
- package/src/storage/schema/tables/User.ts +16 -0
- package/src/storage/schema/tables/index.ts +16 -0
- package/src/storage/sync/StorageMySQLDojoReader.ts +771 -0
- package/src/storage/sync/index.ts +1 -0
- package/src/utility/README.md +3 -0
- package/src/utility/ScriptTemplateSABPPP.ts +79 -0
- package/src/utility/index.all.ts +7 -0
- package/src/utility/index.client.ts +7 -0
- package/src/utility/parseTxScriptOffsets.ts +29 -0
- package/src/utility/stampLog.ts +73 -0
- package/src/utility/tscProofToMerklePath.ts +51 -0
- package/src/utility/utilityHelpers.buffer.ts +43 -0
- package/src/utility/utilityHelpers.noBuffer.ts +18 -0
- package/src/utility/utilityHelpers.ts +283 -0
- package/test/Wallet/StorageClient/storageClient.man.test.ts +55 -0
- package/test/Wallet/action/internalizeAction.a.test.ts +301 -0
- package/test/Wallet/certificate/acquireCertificate.test.ts +253 -0
- package/test/Wallet/certificate/listCertificates.test.ts +352 -0
- package/test/Wallet/get/getHeaderForHeight.test.ts +79 -0
- package/test/Wallet/get/getHeight.test.ts +52 -0
- package/test/Wallet/get/getKnownTxids.test.ts +90 -0
- package/test/Wallet/get/getNetwork.test.ts +28 -0
- package/test/Wallet/get/getVersion.test.ts +28 -0
- package/test/Wallet/live/walletLive.man.test.ts +510 -0
- package/test/Wallet/sync/Wallet.updateWalletLegacyTestData.man.test.ts +155 -0
- package/test/checkDB.ts +63 -0
- package/test/checkdb +0 -0
- package/test/examples/README.man.test.ts +53 -0
- package/test/monitor/Monitor.test.ts +536 -0
- package/test/services/Services.test.ts +149 -0
- package/test/storage/KnexMigrations.test.ts +100 -0
- package/test/storage/StorageMySQLDojoReader.man.test.ts +71 -0
- package/test/storage/count.test.ts +193 -0
- package/test/storage/find.test.ts +216 -0
- package/test/storage/findLegacy.test.ts +70 -0
- package/test/storage/insert.test.ts +294 -0
- package/test/storage/update.test.ts +1146 -0
- package/test/storage/update2.test.ts +1017 -0
- package/test/utils/TestUtilsWalletStorage.ts +1923 -0
- package/test/utils/removeFailedFromDatabase.sql +17 -0
- package/test/wallet/action/abortAction.test.ts +55 -0
- package/test/wallet/action/createAction.test.ts +266 -0
- package/test/wallet/action/createActionToGenerateBeefs.man.test.ts +297 -0
- package/test/wallet/action/internalizeAction.test.ts +729 -0
- package/test/wallet/action/relinquishOutput.test.ts +43 -0
- package/test/wallet/construct/Wallet.constructor.test.ts +57 -0
- package/test/wallet/list/listActions.test.ts +282 -0
- package/test/wallet/list/listActions2.test.ts +570 -0
- package/test/wallet/list/listCertificates.test.ts +129 -0
- package/test/wallet/list/listOutputs.test.ts +573 -0
- package/test/wallet/sync/Wallet.sync.test.ts +226 -0
- package/ts2md.json +32 -0
- package/tsconfig.all.json +29 -0
- package/tsconfig.client.json +22 -0
- package/tsconfig.json +14 -0
- package/unlock-migrations.sh +41 -0
package/docs/monitor.md
ADDED
|
@@ -0,0 +1,648 @@
|
|
|
1
|
+
# API
|
|
2
|
+
|
|
3
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
4
|
+
|
|
5
|
+
## Interfaces
|
|
6
|
+
|
|
7
|
+
| |
|
|
8
|
+
| --- |
|
|
9
|
+
| [MonitorDaemonSetup](#interface-monitordaemonsetup) |
|
|
10
|
+
| [MonitorOptions](#interface-monitoroptions) |
|
|
11
|
+
| [TaskPurgeParams](#interface-taskpurgeparams) |
|
|
12
|
+
|
|
13
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
### Interface: MonitorDaemonSetup
|
|
18
|
+
|
|
19
|
+
```ts
|
|
20
|
+
export interface MonitorDaemonSetup {
|
|
21
|
+
chain?: sdk.Chain;
|
|
22
|
+
sqliteFilename?: string;
|
|
23
|
+
mySQLConnection?: string;
|
|
24
|
+
knexConfig?: Knex.Config;
|
|
25
|
+
knex?: Knex<any, any[]>;
|
|
26
|
+
storageKnexOptions?: StorageKnexOptions;
|
|
27
|
+
storageProvider?: StorageProvider;
|
|
28
|
+
storageManager?: WalletStorageManager;
|
|
29
|
+
servicesOptions?: sdk.WalletServicesOptions;
|
|
30
|
+
services?: Services;
|
|
31
|
+
monitor?: Monitor;
|
|
32
|
+
}
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
See also: [Chain](#type-chain), [Monitor](#class-monitor), [Services](#class-services), [StorageKnexOptions](#interface-storageknexoptions), [StorageProvider](#class-storageprovider), [WalletServicesOptions](#interface-walletservicesoptions), [WalletStorageManager](#class-walletstoragemanager)
|
|
36
|
+
|
|
37
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
38
|
+
|
|
39
|
+
---
|
|
40
|
+
### Interface: MonitorOptions
|
|
41
|
+
|
|
42
|
+
```ts
|
|
43
|
+
export interface MonitorOptions {
|
|
44
|
+
chain: sdk.Chain;
|
|
45
|
+
services: Services;
|
|
46
|
+
storage: MonitorStorage;
|
|
47
|
+
chaintracks: ChaintracksServiceClient;
|
|
48
|
+
msecsWaitPerMerkleProofServiceReq: number;
|
|
49
|
+
taskRunWaitMsecs: number;
|
|
50
|
+
abandonedMsecs: number;
|
|
51
|
+
unprovenAttemptsLimitTest: number;
|
|
52
|
+
unprovenAttemptsLimitMain: number;
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
See also: [Chain](#type-chain), [MonitorStorage](#type-monitorstorage), [Services](#class-services)
|
|
57
|
+
|
|
58
|
+
<details>
|
|
59
|
+
|
|
60
|
+
<summary>Interface MonitorOptions Details</summary>
|
|
61
|
+
|
|
62
|
+
#### Property msecsWaitPerMerkleProofServiceReq
|
|
63
|
+
|
|
64
|
+
How many msecs to wait after each getMerkleProof service request.
|
|
65
|
+
|
|
66
|
+
```ts
|
|
67
|
+
msecsWaitPerMerkleProofServiceReq: number
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
</details>
|
|
71
|
+
|
|
72
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
### Interface: TaskPurgeParams
|
|
76
|
+
|
|
77
|
+
The database stores a variety of data that may be considered transient.
|
|
78
|
+
|
|
79
|
+
At one extreme, the data that must be preserved:
|
|
80
|
+
- unspent outputs (UTXOs)
|
|
81
|
+
- in-use metadata (labels, baskets, tags...)
|
|
82
|
+
|
|
83
|
+
At the other extreme, everything can be preserved to fully log all transaction creation and processing actions.
|
|
84
|
+
|
|
85
|
+
The following purge actions are available to support sustained operation:
|
|
86
|
+
- Failed transactions, delete all associated data including:
|
|
87
|
+
+ Delete tag and label mapping records
|
|
88
|
+
+ Delete output records
|
|
89
|
+
+ Delete transaction records
|
|
90
|
+
+ Delete mapi_responses records
|
|
91
|
+
+ Delete proven_tx_reqs records
|
|
92
|
+
+ Delete commissions records
|
|
93
|
+
+ Update output records marked spentBy failed transactions
|
|
94
|
+
- Completed transactions, delete transient data including:
|
|
95
|
+
+ transactions table set truncatedExternalInputs = null
|
|
96
|
+
+ transactions table set beef = null
|
|
97
|
+
+ transactions table set rawTx = null
|
|
98
|
+
+ Delete mapi_responses records
|
|
99
|
+
+ proven_tx_reqs table delete records
|
|
100
|
+
|
|
101
|
+
```ts
|
|
102
|
+
export interface TaskPurgeParams extends sdk.PurgeParams {
|
|
103
|
+
}
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
See also: [PurgeParams](#interface-purgeparams)
|
|
107
|
+
|
|
108
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
109
|
+
|
|
110
|
+
---
|
|
111
|
+
## Classes
|
|
112
|
+
|
|
113
|
+
| |
|
|
114
|
+
| --- |
|
|
115
|
+
| [Monitor](#class-monitor) |
|
|
116
|
+
| [MonitorDaemon](#class-monitordaemon) |
|
|
117
|
+
| [TaskCheckForProofs](#class-taskcheckforproofs) |
|
|
118
|
+
| [TaskClock](#class-taskclock) |
|
|
119
|
+
| [TaskFailAbandoned](#class-taskfailabandoned) |
|
|
120
|
+
| [TaskNewHeader](#class-tasknewheader) |
|
|
121
|
+
| [TaskPurge](#class-taskpurge) |
|
|
122
|
+
| [TaskReviewStatus](#class-taskreviewstatus) |
|
|
123
|
+
| [TaskSendWaiting](#class-tasksendwaiting) |
|
|
124
|
+
| [TaskSyncWhenIdle](#class-tasksyncwhenidle) |
|
|
125
|
+
| [WalletMonitorTask](#class-walletmonitortask) |
|
|
126
|
+
|
|
127
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
128
|
+
|
|
129
|
+
---
|
|
130
|
+
|
|
131
|
+
### Class: Monitor
|
|
132
|
+
|
|
133
|
+
Background task to make sure transactions are processed, transaction proofs are received and propagated,
|
|
134
|
+
and potentially that reorgs update proofs that were already received.
|
|
135
|
+
|
|
136
|
+
```ts
|
|
137
|
+
export class Monitor {
|
|
138
|
+
static createDefaultWalletMonitorOptions(chain: sdk.Chain, storage: MonitorStorage, services?: Services): MonitorOptions
|
|
139
|
+
options: MonitorOptions;
|
|
140
|
+
services: Services;
|
|
141
|
+
chain: sdk.Chain;
|
|
142
|
+
storage: MonitorStorage;
|
|
143
|
+
chaintracks: ChaintracksServiceClient;
|
|
144
|
+
constructor(options: MonitorOptions)
|
|
145
|
+
oneSecond = 1000;
|
|
146
|
+
oneMinute = 60 * this.oneSecond;
|
|
147
|
+
oneHour = 60 * this.oneMinute;
|
|
148
|
+
oneDay = 24 * this.oneHour;
|
|
149
|
+
oneWeek = 7 * this.oneDay;
|
|
150
|
+
_tasks: WalletMonitorTask[] = [];
|
|
151
|
+
_otherTasks: WalletMonitorTask[] = [];
|
|
152
|
+
_tasksRunning = false;
|
|
153
|
+
defaultPurgeParams: TaskPurgeParams = {
|
|
154
|
+
purgeSpent: false,
|
|
155
|
+
purgeCompleted: false,
|
|
156
|
+
purgeFailed: true,
|
|
157
|
+
purgeSpentAge: 2 * this.oneWeek,
|
|
158
|
+
purgeCompletedAge: 2 * this.oneWeek,
|
|
159
|
+
purgeFailedAge: 5 * this.oneDay
|
|
160
|
+
};
|
|
161
|
+
addAllTasksToOther(): void
|
|
162
|
+
addDefaultTasks(): void
|
|
163
|
+
addMultiUserTasks(): void
|
|
164
|
+
addTask(task: WalletMonitorTask): void
|
|
165
|
+
removeTask(name: string): void
|
|
166
|
+
async setupChaintracksListeners(): Promise<void>
|
|
167
|
+
async runTask(name: string): Promise<string>
|
|
168
|
+
async runOnce(): Promise<void>
|
|
169
|
+
_runAsyncSetup: boolean = true;
|
|
170
|
+
async startTasks(): Promise<void>
|
|
171
|
+
async logEvent(event: string, details?: string): Promise<void>
|
|
172
|
+
stopTasks(): void
|
|
173
|
+
lastNewHeader: BlockHeader | undefined;
|
|
174
|
+
lastNewHeaderWhen: Date | undefined;
|
|
175
|
+
processNewBlockHeader(header: BlockHeader): void
|
|
176
|
+
processReorg(depth: number, oldTip: BlockHeader, newTip: BlockHeader): void
|
|
177
|
+
}
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
See also: [BlockHeader](#interface-blockheader), [Chain](#type-chain), [MonitorOptions](#interface-monitoroptions), [MonitorStorage](#type-monitorstorage), [Services](#class-services), [TaskPurgeParams](#interface-taskpurgeparams), [WalletMonitorTask](#class-walletmonitortask)
|
|
181
|
+
|
|
182
|
+
<details>
|
|
183
|
+
|
|
184
|
+
<summary>Class Monitor Details</summary>
|
|
185
|
+
|
|
186
|
+
#### Property _otherTasks
|
|
187
|
+
|
|
188
|
+
_otherTasks can be run by runTask but not by scheduler.
|
|
189
|
+
|
|
190
|
+
```ts
|
|
191
|
+
_otherTasks: WalletMonitorTask[] = []
|
|
192
|
+
```
|
|
193
|
+
See also: [WalletMonitorTask](#class-walletmonitortask)
|
|
194
|
+
|
|
195
|
+
#### Property _tasks
|
|
196
|
+
|
|
197
|
+
_tasks are typically run by the scheduler but may also be run by runTask.
|
|
198
|
+
|
|
199
|
+
```ts
|
|
200
|
+
_tasks: WalletMonitorTask[] = []
|
|
201
|
+
```
|
|
202
|
+
See also: [WalletMonitorTask](#class-walletmonitortask)
|
|
203
|
+
|
|
204
|
+
#### Method addDefaultTasks
|
|
205
|
+
|
|
206
|
+
Default tasks with settings appropriate for a single user storage
|
|
207
|
+
possibly with sync'ing enabled
|
|
208
|
+
|
|
209
|
+
```ts
|
|
210
|
+
addDefaultTasks(): void
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
#### Method addMultiUserTasks
|
|
214
|
+
|
|
215
|
+
Tasks appropriate for multi-user storage
|
|
216
|
+
without sync'ing enabled.
|
|
217
|
+
|
|
218
|
+
```ts
|
|
219
|
+
addMultiUserTasks(): void
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
#### Method processNewBlockHeader
|
|
223
|
+
|
|
224
|
+
Process new chain header event received from Chaintracks
|
|
225
|
+
|
|
226
|
+
Kicks processing 'unconfirmed' and 'unmined' request processing.
|
|
227
|
+
|
|
228
|
+
```ts
|
|
229
|
+
processNewBlockHeader(header: BlockHeader): void
|
|
230
|
+
```
|
|
231
|
+
See also: [BlockHeader](#interface-blockheader)
|
|
232
|
+
|
|
233
|
+
#### Method processReorg
|
|
234
|
+
|
|
235
|
+
Process reorg event received from Chaintracks
|
|
236
|
+
|
|
237
|
+
Reorgs can move recent transactions to new blocks at new index positions.
|
|
238
|
+
Affected transaction proofs become invalid and must be updated.
|
|
239
|
+
|
|
240
|
+
It is possible for a transaction to become invalid.
|
|
241
|
+
|
|
242
|
+
Coinbase transactions always become invalid.
|
|
243
|
+
|
|
244
|
+
```ts
|
|
245
|
+
processReorg(depth: number, oldTip: BlockHeader, newTip: BlockHeader): void
|
|
246
|
+
```
|
|
247
|
+
See also: [BlockHeader](#interface-blockheader)
|
|
248
|
+
|
|
249
|
+
</details>
|
|
250
|
+
|
|
251
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
252
|
+
|
|
253
|
+
---
|
|
254
|
+
### Class: MonitorDaemon
|
|
255
|
+
|
|
256
|
+
```ts
|
|
257
|
+
export class MonitorDaemon {
|
|
258
|
+
setup?: MonitorDaemonSetup;
|
|
259
|
+
doneListening?: Promise<void>;
|
|
260
|
+
doneTasks?: Promise<void>;
|
|
261
|
+
stopDaemon: boolean = false;
|
|
262
|
+
constructor(public args: MonitorDaemonSetup, public noRunTasks?: boolean)
|
|
263
|
+
async createSetup(): Promise<void>
|
|
264
|
+
async start(): Promise<void>
|
|
265
|
+
async stop(): Promise<void>
|
|
266
|
+
async destroy(): Promise<void>
|
|
267
|
+
async runDaemon(): Promise<void>
|
|
268
|
+
}
|
|
269
|
+
```
|
|
270
|
+
|
|
271
|
+
See also: [MonitorDaemonSetup](#interface-monitordaemonsetup)
|
|
272
|
+
|
|
273
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
274
|
+
|
|
275
|
+
---
|
|
276
|
+
### Class: TaskCheckForProofs
|
|
277
|
+
|
|
278
|
+
`TaskCheckForProofs` is a WalletMonitor task that retreives merkle proofs for
|
|
279
|
+
transactions.
|
|
280
|
+
|
|
281
|
+
It is normally triggered by the Chaintracks new block header event.
|
|
282
|
+
|
|
283
|
+
When a new block is found, cwi-external-services are used to obtain proofs for
|
|
284
|
+
any transactions that are currently in the 'unmined' or 'unknown' state.
|
|
285
|
+
|
|
286
|
+
If a proof is obtained and validated, a new ProvenTx record is created and
|
|
287
|
+
the original ProvenTxReq status is advanced to 'notifying'.
|
|
288
|
+
|
|
289
|
+
```ts
|
|
290
|
+
export class TaskCheckForProofs extends WalletMonitorTask {
|
|
291
|
+
static taskName = "CheckForProofs";
|
|
292
|
+
static checkNow = false;
|
|
293
|
+
constructor(monitor: Monitor, public triggerMsecs = 0)
|
|
294
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
295
|
+
run: boolean;
|
|
296
|
+
}
|
|
297
|
+
async runTask(): Promise<string>
|
|
298
|
+
async getProofs(reqs: table.ProvenTxReq[], indent = 0, countsAsAttempt = false, ignoreStatus = false): Promise<{
|
|
299
|
+
proven: table.ProvenTxReq[];
|
|
300
|
+
invalid: table.ProvenTxReq[];
|
|
301
|
+
log: string;
|
|
302
|
+
}>
|
|
303
|
+
}
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
See also: [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask), [log](#variable-log)
|
|
307
|
+
|
|
308
|
+
<details>
|
|
309
|
+
|
|
310
|
+
<summary>Class TaskCheckForProofs Details</summary>
|
|
311
|
+
|
|
312
|
+
#### Property checkNow
|
|
313
|
+
|
|
314
|
+
An external service such as the chaintracks new block header
|
|
315
|
+
listener can set this true to cause
|
|
316
|
+
|
|
317
|
+
```ts
|
|
318
|
+
static checkNow = false
|
|
319
|
+
```
|
|
320
|
+
|
|
321
|
+
#### Method getProofs
|
|
322
|
+
|
|
323
|
+
Process an array of table.ProvenTxReq (typically with status 'unmined' or 'unknown')
|
|
324
|
+
|
|
325
|
+
If req is invalid, set status 'invalid'
|
|
326
|
+
|
|
327
|
+
Verify the requests are valid, lookup proofs or updated transaction status using the array of getProofServices,
|
|
328
|
+
|
|
329
|
+
When proofs are found, create new ProvenTxApi records and transition the requests' status to 'unconfirmed' or 'notifying',
|
|
330
|
+
depending on chaintracks succeeding on proof verification.
|
|
331
|
+
|
|
332
|
+
Increments attempts if proofs where requested.
|
|
333
|
+
|
|
334
|
+
```ts
|
|
335
|
+
async getProofs(reqs: table.ProvenTxReq[], indent = 0, countsAsAttempt = false, ignoreStatus = false): Promise<{
|
|
336
|
+
proven: table.ProvenTxReq[];
|
|
337
|
+
invalid: table.ProvenTxReq[];
|
|
338
|
+
log: string;
|
|
339
|
+
}>
|
|
340
|
+
```
|
|
341
|
+
See also: [log](#variable-log)
|
|
342
|
+
|
|
343
|
+
Returns
|
|
344
|
+
|
|
345
|
+
reqs partitioned by status
|
|
346
|
+
|
|
347
|
+
#### Method trigger
|
|
348
|
+
|
|
349
|
+
Normally triggered by checkNow getting set by new block header found event from chaintracks
|
|
350
|
+
|
|
351
|
+
```ts
|
|
352
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
353
|
+
run: boolean;
|
|
354
|
+
}
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
</details>
|
|
358
|
+
|
|
359
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
360
|
+
|
|
361
|
+
---
|
|
362
|
+
### Class: TaskClock
|
|
363
|
+
|
|
364
|
+
```ts
|
|
365
|
+
export class TaskClock extends WalletMonitorTask {
|
|
366
|
+
static taskName = "Clock";
|
|
367
|
+
nextMinute: number;
|
|
368
|
+
constructor(monitor: Monitor, public triggerMsecs = 1 * monitor.oneSecond)
|
|
369
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
370
|
+
run: boolean;
|
|
371
|
+
}
|
|
372
|
+
async runTask(): Promise<string>
|
|
373
|
+
getNextMinute(): number
|
|
374
|
+
}
|
|
375
|
+
```
|
|
376
|
+
|
|
377
|
+
See also: [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask)
|
|
378
|
+
|
|
379
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
380
|
+
|
|
381
|
+
---
|
|
382
|
+
### Class: TaskFailAbandoned
|
|
383
|
+
|
|
384
|
+
Handles transactions which do not have terminal status and have not been
|
|
385
|
+
updated for an extended time period.
|
|
386
|
+
|
|
387
|
+
Calls `updateTransactionStatus` to set `status` to `failed`.
|
|
388
|
+
This returns inputs to spendable status and verifies that any
|
|
389
|
+
outputs are not spendable.
|
|
390
|
+
|
|
391
|
+
```ts
|
|
392
|
+
export class TaskFailAbandoned extends WalletMonitorTask {
|
|
393
|
+
static taskName = "FailAbandoned";
|
|
394
|
+
constructor(monitor: Monitor, public triggerMsecs = 1000 * 60 * 5)
|
|
395
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
396
|
+
run: boolean;
|
|
397
|
+
}
|
|
398
|
+
async runTask(): Promise<string>
|
|
399
|
+
}
|
|
400
|
+
```
|
|
401
|
+
|
|
402
|
+
See also: [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask)
|
|
403
|
+
|
|
404
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
405
|
+
|
|
406
|
+
---
|
|
407
|
+
### Class: TaskNewHeader
|
|
408
|
+
|
|
409
|
+
```ts
|
|
410
|
+
export class TaskNewHeader extends WalletMonitorTask {
|
|
411
|
+
static taskName = "NewHeader";
|
|
412
|
+
header?: sdk.BlockHeader;
|
|
413
|
+
constructor(monitor: Monitor, public triggerMsecs = 1 * monitor.oneMinute)
|
|
414
|
+
async getHeader(): Promise<sdk.BlockHeader>
|
|
415
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
416
|
+
run: boolean;
|
|
417
|
+
}
|
|
418
|
+
async runTask(): Promise<string>
|
|
419
|
+
}
|
|
420
|
+
```
|
|
421
|
+
|
|
422
|
+
See also: [BlockHeader](#interface-blockheader), [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask)
|
|
423
|
+
|
|
424
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
425
|
+
|
|
426
|
+
---
|
|
427
|
+
### Class: TaskPurge
|
|
428
|
+
|
|
429
|
+
```ts
|
|
430
|
+
export class TaskPurge extends WalletMonitorTask {
|
|
431
|
+
static taskName = "Purge";
|
|
432
|
+
static checkNow = false;
|
|
433
|
+
constructor(monitor: Monitor, public params: TaskPurgeParams, public triggerMsecs = 0)
|
|
434
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
435
|
+
run: boolean;
|
|
436
|
+
}
|
|
437
|
+
async runTask(): Promise<string>
|
|
438
|
+
}
|
|
439
|
+
```
|
|
440
|
+
|
|
441
|
+
See also: [Monitor](#class-monitor), [TaskPurgeParams](#interface-taskpurgeparams), [WalletMonitorTask](#class-walletmonitortask)
|
|
442
|
+
|
|
443
|
+
<details>
|
|
444
|
+
|
|
445
|
+
<summary>Class TaskPurge Details</summary>
|
|
446
|
+
|
|
447
|
+
#### Property checkNow
|
|
448
|
+
|
|
449
|
+
Set to true to trigger running this task
|
|
450
|
+
|
|
451
|
+
```ts
|
|
452
|
+
static checkNow = false
|
|
453
|
+
```
|
|
454
|
+
|
|
455
|
+
</details>
|
|
456
|
+
|
|
457
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
458
|
+
|
|
459
|
+
---
|
|
460
|
+
### Class: TaskReviewStatus
|
|
461
|
+
|
|
462
|
+
Notify Transaction records of changes in ProvenTxReq records they may have missed.
|
|
463
|
+
|
|
464
|
+
The `notified` property flags reqs that do not need to be checked.
|
|
465
|
+
|
|
466
|
+
Looks for aged Transactions with provenTxId with status != 'completed', sets status to 'completed'.
|
|
467
|
+
|
|
468
|
+
Looks for reqs with 'invalid' status that
|
|
469
|
+
|
|
470
|
+
```ts
|
|
471
|
+
export class TaskReviewStatus extends WalletMonitorTask {
|
|
472
|
+
static taskName = "ReviewStatus";
|
|
473
|
+
static checkNow = false;
|
|
474
|
+
constructor(monitor: Monitor, public triggerMsecs = 1000 * 60 * 15, public agedMsecs = 1000 * 60 * 5)
|
|
475
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
476
|
+
run: boolean;
|
|
477
|
+
}
|
|
478
|
+
async runTask(): Promise<string>
|
|
479
|
+
}
|
|
480
|
+
```
|
|
481
|
+
|
|
482
|
+
See also: [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask)
|
|
483
|
+
|
|
484
|
+
<details>
|
|
485
|
+
|
|
486
|
+
<summary>Class TaskReviewStatus Details</summary>
|
|
487
|
+
|
|
488
|
+
#### Property checkNow
|
|
489
|
+
|
|
490
|
+
Set to true to trigger running this task
|
|
491
|
+
|
|
492
|
+
```ts
|
|
493
|
+
static checkNow = false
|
|
494
|
+
```
|
|
495
|
+
|
|
496
|
+
</details>
|
|
497
|
+
|
|
498
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
499
|
+
|
|
500
|
+
---
|
|
501
|
+
### Class: TaskSendWaiting
|
|
502
|
+
|
|
503
|
+
```ts
|
|
504
|
+
export class TaskSendWaiting extends WalletMonitorTask {
|
|
505
|
+
static taskName = "SendWaiting";
|
|
506
|
+
constructor(monitor: Monitor, public triggerMsecs = 1000 * 60 * 5, public agedMsecs = 0)
|
|
507
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
508
|
+
run: boolean;
|
|
509
|
+
}
|
|
510
|
+
async runTask(): Promise<string>
|
|
511
|
+
async processUnsent(reqApis: table.ProvenTxReq[], indent = 0): Promise<string>
|
|
512
|
+
}
|
|
513
|
+
```
|
|
514
|
+
|
|
515
|
+
See also: [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask)
|
|
516
|
+
|
|
517
|
+
<details>
|
|
518
|
+
|
|
519
|
+
<summary>Class TaskSendWaiting Details</summary>
|
|
520
|
+
|
|
521
|
+
#### Method processUnsent
|
|
522
|
+
|
|
523
|
+
Process an array of 'unsent' status table.ProvenTxReq
|
|
524
|
+
|
|
525
|
+
Send rawTx to transaction processor(s), requesting proof callbacks when possible.
|
|
526
|
+
|
|
527
|
+
Set status 'invalid' if req is invalid.
|
|
528
|
+
|
|
529
|
+
Set status to 'callback' on successful network submission with callback service.
|
|
530
|
+
|
|
531
|
+
Set status to 'unmined' on successful network submission without callback service.
|
|
532
|
+
|
|
533
|
+
Add mapi responses to database table if received.
|
|
534
|
+
|
|
535
|
+
Increments attempts if sending was attempted.
|
|
536
|
+
|
|
537
|
+
```ts
|
|
538
|
+
async processUnsent(reqApis: table.ProvenTxReq[], indent = 0): Promise<string>
|
|
539
|
+
```
|
|
540
|
+
|
|
541
|
+
</details>
|
|
542
|
+
|
|
543
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
544
|
+
|
|
545
|
+
---
|
|
546
|
+
### Class: TaskSyncWhenIdle
|
|
547
|
+
|
|
548
|
+
```ts
|
|
549
|
+
export class TaskSyncWhenIdle extends WalletMonitorTask {
|
|
550
|
+
static taskName = "SyncWhenIdle";
|
|
551
|
+
constructor(monitor: Monitor, public triggerMsecs = 1000 * 60 * 1)
|
|
552
|
+
trigger(nowMsecsSinceEpoch: number): {
|
|
553
|
+
run: boolean;
|
|
554
|
+
}
|
|
555
|
+
async runTask(): Promise<string>
|
|
556
|
+
}
|
|
557
|
+
```
|
|
558
|
+
|
|
559
|
+
See also: [Monitor](#class-monitor), [WalletMonitorTask](#class-walletmonitortask)
|
|
560
|
+
|
|
561
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
562
|
+
|
|
563
|
+
---
|
|
564
|
+
### Class: WalletMonitorTask
|
|
565
|
+
|
|
566
|
+
A monitor task performs some periodic or state triggered maintenance function
|
|
567
|
+
on the data managed by a wallet (Bitcoin UTXO manager, aka wallet)
|
|
568
|
+
|
|
569
|
+
The monitor maintains a collection of tasks.
|
|
570
|
+
|
|
571
|
+
It runs each task's non-asynchronous trigger to determine if the runTask method needs to run.
|
|
572
|
+
|
|
573
|
+
Tasks that need to be run are run consecutively by awaiting their async runTask override method.
|
|
574
|
+
|
|
575
|
+
The monitor then waits a fixed interval before repeating...
|
|
576
|
+
|
|
577
|
+
Tasks may use the monitor_events table to persist their execution history.
|
|
578
|
+
This is done by accessing the wathman.storage object.
|
|
579
|
+
|
|
580
|
+
```ts
|
|
581
|
+
export abstract class WalletMonitorTask {
|
|
582
|
+
lastRunMsecsSinceEpoch = 0;
|
|
583
|
+
storage: MonitorStorage;
|
|
584
|
+
constructor(public monitor: Monitor, public name: string)
|
|
585
|
+
async asyncSetup(): Promise<void>
|
|
586
|
+
abstract trigger(nowMsecsSinceEpoch: number): {
|
|
587
|
+
run: boolean;
|
|
588
|
+
};
|
|
589
|
+
abstract runTask(): Promise<string>;
|
|
590
|
+
}
|
|
591
|
+
```
|
|
592
|
+
|
|
593
|
+
See also: [Monitor](#class-monitor), [MonitorStorage](#type-monitorstorage)
|
|
594
|
+
|
|
595
|
+
<details>
|
|
596
|
+
|
|
597
|
+
<summary>Class WalletMonitorTask Details</summary>
|
|
598
|
+
|
|
599
|
+
#### Property lastRunMsecsSinceEpoch
|
|
600
|
+
|
|
601
|
+
Set by monitor each time runTask completes
|
|
602
|
+
|
|
603
|
+
```ts
|
|
604
|
+
lastRunMsecsSinceEpoch = 0
|
|
605
|
+
```
|
|
606
|
+
|
|
607
|
+
#### Method asyncSetup
|
|
608
|
+
|
|
609
|
+
Override to handle async task setup configuration.
|
|
610
|
+
|
|
611
|
+
Called before first call to `trigger`
|
|
612
|
+
|
|
613
|
+
```ts
|
|
614
|
+
async asyncSetup(): Promise<void>
|
|
615
|
+
```
|
|
616
|
+
|
|
617
|
+
#### Method trigger
|
|
618
|
+
|
|
619
|
+
Return true if `runTask` needs to be called now.
|
|
620
|
+
|
|
621
|
+
```ts
|
|
622
|
+
abstract trigger(nowMsecsSinceEpoch: number): {
|
|
623
|
+
run: boolean;
|
|
624
|
+
}
|
|
625
|
+
```
|
|
626
|
+
|
|
627
|
+
</details>
|
|
628
|
+
|
|
629
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
630
|
+
|
|
631
|
+
---
|
|
632
|
+
## Functions
|
|
633
|
+
|
|
634
|
+
## Types
|
|
635
|
+
|
|
636
|
+
### Type: MonitorStorage
|
|
637
|
+
|
|
638
|
+
```ts
|
|
639
|
+
export type MonitorStorage = WalletStorageManager
|
|
640
|
+
```
|
|
641
|
+
|
|
642
|
+
See also: [WalletStorageManager](#class-walletstoragemanager)
|
|
643
|
+
|
|
644
|
+
Links: [API](#api), [Interfaces](#interfaces), [Classes](#classes), [Functions](#functions), [Types](#types), [Variables](#variables)
|
|
645
|
+
|
|
646
|
+
---
|
|
647
|
+
## Variables
|
|
648
|
+
|