block status moved
This commit is contained in:
parent
e95f610195
commit
14bcca54d2
@ -45,19 +45,7 @@ pub use blockchain::CacheSize as BlockChainCacheSize;
|
||||
use trace::{TraceDB, ImportRequest as TraceImportRequest, LocalizedTrace, Database as TraceDatabase};
|
||||
use trace;
|
||||
pub use types::blockchain_info::BlockChainInfo;
|
||||
|
||||
/// General block status
|
||||
#[derive(Debug, Eq, PartialEq)]
|
||||
pub enum BlockStatus {
|
||||
/// Part of the blockchain.
|
||||
InChain,
|
||||
/// Queued for import.
|
||||
Queued,
|
||||
/// Known as bad.
|
||||
Bad,
|
||||
/// Unknown.
|
||||
Unknown,
|
||||
}
|
||||
pub use types::block_status::BlockStatus;
|
||||
|
||||
impl fmt::Display for BlockChainInfo {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
||||
|
30
ethcore/src/types/block_status.rs
Normal file
30
ethcore/src/types/block_status.rs
Normal file
@ -0,0 +1,30 @@
|
||||
// Copyright 2015, 2016 Ethcore (UK) Ltd.
|
||||
// This file is part of Parity.
|
||||
|
||||
// Parity is free software: you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License as published by
|
||||
// the Free Software Foundation, either version 3 of the License, or
|
||||
// (at your option) any later version.
|
||||
|
||||
// Parity is distributed in the hope that it will be useful,
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
// GNU General Public License for more details.
|
||||
|
||||
// You should have received a copy of the GNU General Public License
|
||||
// along with Parity. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
//! Block status description module
|
||||
|
||||
/// General block status
|
||||
#[derive(Debug, Eq, PartialEq)]
|
||||
pub enum BlockStatus {
|
||||
/// Part of the blockchain.
|
||||
InChain,
|
||||
/// Queued for import.
|
||||
Queued,
|
||||
/// Known as bad.
|
||||
Bad,
|
||||
/// Unknown.
|
||||
Unknown,
|
||||
}
|
@ -20,8 +20,6 @@ use util::*;
|
||||
use trace::Trace;
|
||||
use types::log_entry::LogEntry;
|
||||
|
||||
|
||||
|
||||
/// Transaction execution receipt.
|
||||
#[derive(Debug, PartialEq, Clone)]
|
||||
pub struct Executed {
|
||||
|
@ -60,6 +60,3 @@ pub struct UncleId (
|
||||
pub usize
|
||||
);
|
||||
|
||||
sized_binary_map!(TransactionId);
|
||||
sized_binary_map!(UncleId);
|
||||
sized_binary_map!(BlockId);
|
||||
|
@ -24,3 +24,4 @@ pub mod blockchain_info;
|
||||
pub mod log_entry;
|
||||
pub mod trace_types;
|
||||
pub mod executed;
|
||||
pub mod block_status;
|
||||
|
Loading…
Reference in New Issue
Block a user