Show / Hide Table of Contents

Namespace Libplanet.Blockchain.Policies

Classes

BlockPolicy<T>

A default implementation of IBlockPolicy<T> interface.

NullBlockPolicy<T>

VolatileStagePolicy<T>

An in memory implementation of the IStagePolicy<T>.

This implementation holds on to every unconfirmed Transaction except for the following reasons:

  • A Transaction has been specifically marked to be ignored due to Transaction not being valid.
  • A Transaction has expired due to its staleness.

Additionally, any Transaction with a lower nonce than that of returned by the BlockChain<T> is masked and filtered by default.

Interfaces

IBlockPolicy<T>

An interface to determine if consecutive Blocks are valid.

An implementation of this interface should perform all policy dependent checks, such as whether a Block has the right difficulty, a Transaction has the right signer, etc.

Note that all index dependent sub-policies are ignored for genesis Blocks.

IStagePolicy<T>

An interface to configure a BlockChain<T>'s strategy to deal with staged transactions.

In This Article
Back to top Copyright © 2018–2023 Planetarium