1.0.10 • Published 5 years ago

@sec-block/secjs-transactionpool v1.0.10

Weekly downloads
1
License
ISC
Repository
github
Last release
5 years ago

JavaScript Style Guide

[JavaScript Style Guide]

SECTransactionPool

This package is for sec blockchain transaction pool

new SECTransactionPool(config)

create a transaction pool with config, such as transaction pool of token chain or transaction chain

ParamType
configObject

secTransactionPool.addTxIntoPool(transaction)

save the transaction into local transaction pool

Kind: instance method of SECTransactionPool

ParamType
transactionObject

secTransactionPool.updateBlockHashArray(blockChain)

upate the block hash array this blockChainHashBuffer is for checking the transaction in transaction pool, just compare the TxHash

Kind: instance method of SECTransactionPool

ParamType
blockChainObject

secTransactionPool.compareTxWithHashTable()

remove transactions in transaction pool, if they are already upload to blockchain

Kind: instance method of SECTransactionPool

secTransactionPool.addTxFromOtherPeerIntoPool(txFromOtherPeer)

to update the local transaction pool with transactions from other peers

Kind: instance method of SECTransactionPool

ParamType
txFromOtherPeerObject

secTransactionPool.getTxStatus(transaction) => Status

get transaction status: pending, success, error

Kind: instance method of SECTransactionPool

ParamType
transactionObject

secTransactionPool.getAllTxFromPool() => Array

return all transaction from pool

Kind: instance method of SECTransactionPool

secTransactionPool.clear()

clear the transaction pool

Kind: instance method of SECTransactionPool

1.0.10

5 years ago

1.0.9

5 years ago

1.0.8

6 years ago

1.0.7

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago