chain verifier stub
This commit is contained in:
parent
9ab048acd9
commit
e3558fc269
|
@ -25,7 +25,7 @@ const _COL_RESERVED6: u32 = 10;
|
|||
const DB_VERSION: u32 = 1;
|
||||
|
||||
/// Blockchain storage interface
|
||||
pub trait Store {
|
||||
pub trait Store : Send + Sync {
|
||||
/// resolves hash by block number
|
||||
fn block_hash(&self, number: u64) -> Option<H256>;
|
||||
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
//! Bitcoin chain verifier
|
||||
|
||||
use std::sync::Arc;
|
||||
|
||||
use db;
|
||||
use chain;
|
||||
use super::{Verify, VerificationResult, Chain};
|
||||
|
||||
struct ChainVerifier {
|
||||
store: Arc<db::Store>,
|
||||
}
|
||||
|
||||
impl Verify for ChainVerifier {
|
||||
fn verify(&self, block: &chain::Block) -> VerificationResult {
|
||||
Ok(Chain::Main)
|
||||
}
|
||||
}
|
|
@ -13,6 +13,7 @@ extern crate ethcore_devtools as devtools;
|
|||
extern crate test_data;
|
||||
|
||||
mod queue;
|
||||
mod chain_verifier;
|
||||
|
||||
pub use queue::Queue;
|
||||
|
||||
|
|
Loading…
Reference in New Issue