Packages

p

org.bitcoins.chain

blockchain

package blockchain

Ordering
  1. Alphabetic
Visibility
  1. Public
  2. Protected

Package Members

  1. package sync

Type Members

  1. case class Blockchain(headers: Vector[BlockHeaderDb]) extends BaseBlockChain with Product with Serializable

    <invalid inheritdoc annotation>

  2. sealed abstract class BlockchainUpdate extends AnyRef

    Represens the state of a batch of BlockHeaders being added to our blockchain

    Represens the state of a batch of BlockHeaders being added to our blockchain

    An example of a Failed update is when we receive a BlockHeader that is invalid and because of a TipUpdateFailure because of BadPOW or a BadNonce etc

  3. sealed abstract class ChainException extends RuntimeException

    A base class for various types of block chain exceptions

  4. class ChainHandler extends ChainApi with ChainVerificationLogger

    Chain Handler is meant to be the reference implementation of ChainApi, this is the entry point in to the chain project.

    Chain Handler is meant to be the reference implementation of ChainApi, this is the entry point in to the chain project.

    This implementation of ChainApi reads all values directly from the database. If you want an optimized version that caches headers locally please see ChainHandlerCached

  5. case class ChainHandlerCached(blockHeaderDAO: BlockHeaderDAO, filterHeaderDAO: CompactFilterHeaderDAO, filterDAO: CompactFilterDAO, stateDAO: ChainStateDescriptorDAO, blockchains: Vector[Blockchain], blockFilterCheckpoints: Map[DoubleSha256DigestBE, DoubleSha256DigestBE])(implicit chainConfig: ChainAppConfig, executionContext: ExecutionContext) extends ChainHandler with Product with Serializable

    An optimized version of ChainHandler that avoids database reads for determining what the best block header is.

    An optimized version of ChainHandler that avoids database reads for determining what the best block header is. This should be used with care as it is possible the cached blockchains may be out of date! Unless you know what you are doing, you should probably use ChainHandler

  6. case class CheckHeaderResult(result: TipUpdateResult, chain: Blockchain) extends Product with Serializable
  7. sealed trait ConnectTipResult extends AnyRef

    The result indicating how the TipUpdateResult modified the chain.

    The result indicating how the TipUpdateResult modified the chain.

    We can

    1. Extend the chain 2. Reorg the chain 3. Fail to connect to anything in the chain
  8. case class DuplicateFilters(message: String) extends ChainException with Product with Serializable

    org.bitcoins.chain.blockchain.ChainHandler tried to process multiple filters for the same block hash

  9. case class DuplicateHeaders(message: String) extends ChainException with Product with Serializable
  10. case class InvalidBlockHeader(message: String) extends ChainException with Product with Serializable
  11. case class InvalidBlockRange(message: String) extends ChainException with Product with Serializable

    The given block range is invalid

  12. case class UnknownBlockHash(message: String) extends ChainException with Product with Serializable

    org.bitcoins.chain.blockchain.ChainHandler cannot find a blockchain item by its block hash

  13. case class UnknownBlockHeight(message: String) extends ChainException with Product with Serializable

    org.bitcoins.chain.blockchain.ChainHandler cannot find a blockchain item by its height

  14. case class UnknownFilterHash(message: String) extends ChainException with Product with Serializable

    org.bitcoins.chain.blockchain.ChainHandler cannot find a compact filter or header by its filter hash

Value Members

  1. object Blockchain extends BaseBlockChainCompObject with Serializable
  2. object BlockchainUpdate
  3. object ChainHandler
  4. object ChainHandlerCached extends Serializable
  5. object ConnectTipResult

Ungrouped