new NonceTracker(opts)
Parameters:
| Name | Type | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
opts |
Object |
Properties
|
Methods
_getHighestContinuousFrom(txList, startPoint) → {highestContinuousFrom}
Parameters:
| Name | Type | Description |
|---|---|---|
txList |
array | list of txMeta's |
startPoint |
number | the highest known locally confirmed nonce |
Returns:
(async) getGlobalLock() → {Promise.<Object>}
Returns:
with the key releaseLock (the gloabl mutex)
- Type
- Promise.<Object>
(async) getNonceLock(address) → {Promise.<NonceDetails>}
this will return an object with the nextNonce nonceDetails of type NonceDetails, and the releaseLock
Note: releaseLock must be called after adding a signed tx to pending transactions (or discarding).
Parameters:
| Name | Type | Description |
|---|---|---|
address |
string | the hex string for the address whose nonce we are calculating |
Returns:
- Type
- Promise.<NonceDetails>