# Trait ethcore_light::client::LightChainClient [−] [src]

    pub trait LightChainClient: Send + Sync {
        fn chain_info(&self) -> BlockChainInfo;
        fn queue_header(&self, header: Header) -> Result<H256, BlockImportError>;
        fn is_known(&self, hash: &H256) -> bool;
        fn clear_queue(&self);
        fn flush_queue(&self);
        fn queue_info(&self) -> QueueInfo;
        fn cht_root(&self, i: usize) -> Option<H256>;
    }

Trait for interacting with the header chain abstractly.

## Required Methods

### `fn chain_info(&self) -> BlockChainInfo`

Get chain info.

### `fn queue_header(&self, header: Header) -> Result<H256, BlockImportError>`

Queue header to be verified. Required that all headers queued have their parent queued prior.

### `fn is_known(&self, hash: &H256) -> bool`

Query whether a block is known.

### `fn clear_queue(&self)`

Clear the queue.

### `fn flush_queue(&self)`

Flush the queue.

### `fn queue_info(&self) -> QueueInfo`

Get queue info.

### `fn cht_root(&self, i: usize) -> Option<H256>`

Get the `i`th CHT root.

## Implementors

- `impl LightChainClient for Client`

# Help

## Keyboard Shortcuts

?
  Show this help dialog
S
  Focus the search field
⇤
  Move up in search results
⇥
  Move down in search results
⏎
  Go to active search result
+
  Collapse/expand all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g. `vec -> usize` or `* -> vec`)