Members
(static, constant) ABSURD_FEE_FACTOR :Number
Maximum relay fee FACTOR for safety (policy). Multiplied by result of policy.getMinFee()
Type:
- Number
- Source:
(static, constant) BLOCK_PRIORITY_THRESHOLD :Number
Priority threshold to be reached before switching to fee rate comparison.
Type:
- Number
- Source:
(static, constant) BLOCK_PRIORITY_WEIGHT :Number
How much of the block should be dedicated to high-priority transactions (included regardless of fee rate).
Type:
- Number
- Source:
(static, constant) BYTES_PER_SIGOP :Number
How much weight a sigop should add to virtual size (policy).
Type:
- Number
- Default Value:
- 20
- Source:
(static, constant) FREE_THRESHOLD :Number
Priority threshold for free transactions (policy).
Type:
- Number
- Source:
(static, constant) MAX_BLOCK_WEIGHT :Number
Maximum block weight to be mined.
Type:
- Number
- Source:
(static, constant) MAX_P2WSH_PUSH :Number
Max p2wsh push size. Used for witness malleation checks (policy).
Type:
- Number
- Default Value:
- 80
- Source:
(static, constant) MAX_P2WSH_SIZE :Number
Max serialized p2wsh size. Used for witness malleation checks (policy).
Type:
- Number
- Default Value:
- 3600
- Source:
(static, constant) MAX_P2WSH_STACK :Number
Max p2wsh stack size. Used for witness malleation checks (policy).
Type:
- Number
- Default Value:
- 100
- Source:
(static, constant) MAX_TX_SIGOPS :Number
Maximum cost of transaction sigops (policy).
Type:
- Number
- Source:
(static, constant) MAX_TX_SIZE :Number
Maximum transaction base size (policy).
Type:
- Number
- Source:
(static, constant) MAX_TX_VERSION :Number
Maximum transaction version (policy).
Type:
- Number
- Source:
(static, constant) MAX_TX_WEIGHT :Number
Maximum transaction weight (policy).
Type:
- Number
- Source:
(static, constant) MEMPOOL_EXPIRY_TIME :Number
Time at which transactions fall out of the mempool.
Type:
- Number
- Source:
(static, constant) MEMPOOL_MAX_ANCESTORS :Number
Default ancestor limit.
Type:
- Number
- Default Value:
- 50
- Source:
(static, constant) MEMPOOL_MAX_ORPHANS :Number
Maximum number of orphan transactions.
Type:
- Number
- Default Value:
- 100
- Source:
(static, constant) MEMPOOL_MAX_SIZE :Number
Default maximum mempool size in bytes.
Type:
- Number
- Source:
(static, constant) MIN_BLOCK_WEIGHT :Number
Minimum block size to create. Block will be filled with free transactions until block reaches this weight.
Type:
- Number
- Default Value:
- 5000
- Source:
(static, constant) MIN_RELAY :Rate
Minimum relay fee rate (policy).
Type:
- Source:
Methods
(static) getMinFee(size, rateopt, nullable) → {Amount}
Calculate minimum fee based on rate and size.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
size |
Number | ||
rate |
Rate |
<optional> <nullable> |
Rate of dollarydoo per kB. |
- Source:
Returns:
fee
- Type
- Amount
(static) getRate(size, fee) → {Rate}
Calculate a fee rate based on size and fees.
Parameters:
Name | Type | Description |
---|---|---|
size |
Number | |
fee |
Amount |
- Source:
Returns:
- Type
- Rate
(static) getRoundFee(size, rateopt, nullable) → {Amount}
Calculate the minimum fee in order for the transaction to be relayable, but _round to the nearest kilobyte when taking into account size.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
size |
Number | ||
rate |
Rate |
<optional> <nullable> |
Rate of dollarydoo per kB. |
- Source:
Returns:
fee
- Type
- Amount