binary for trace
This commit is contained in:
parent
29531ae72f
commit
c622fc62d5
@ -20,9 +20,12 @@ use util::rlp::*;
|
|||||||
use util::sha3::Hashable;
|
use util::sha3::Hashable;
|
||||||
use action_params::ActionParams;
|
use action_params::ActionParams;
|
||||||
use basic_types::LogBloom;
|
use basic_types::LogBloom;
|
||||||
|
use ipc::binary::BinaryConvertError;
|
||||||
|
use std::mem;
|
||||||
|
use std::collections::VecDeque;
|
||||||
|
|
||||||
/// `Call` result.
|
/// `Call` result.
|
||||||
#[derive(Debug, Clone, PartialEq, Default)]
|
#[derive(Debug, Clone, PartialEq, Default, Binary)]
|
||||||
pub struct CallResult {
|
pub struct CallResult {
|
||||||
/// Gas used by call.
|
/// Gas used by call.
|
||||||
pub gas_used: U256,
|
pub gas_used: U256,
|
||||||
@ -51,7 +54,7 @@ impl Decodable for CallResult {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// `Create` result.
|
/// `Create` result.
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Binary)]
|
||||||
pub struct CreateResult {
|
pub struct CreateResult {
|
||||||
/// Gas used by create.
|
/// Gas used by create.
|
||||||
pub gas_used: U256,
|
pub gas_used: U256,
|
||||||
@ -84,7 +87,7 @@ impl Decodable for CreateResult {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Description of a _call_ action, either a `CALL` operation or a message transction.
|
/// Description of a _call_ action, either a `CALL` operation or a message transction.
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Binary)]
|
||||||
pub struct Call {
|
pub struct Call {
|
||||||
/// The sending account.
|
/// The sending account.
|
||||||
pub from: Address,
|
pub from: Address,
|
||||||
@ -146,7 +149,7 @@ impl Call {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Description of a _create_ action, either a `CREATE` operation or a create transction.
|
/// Description of a _create_ action, either a `CREATE` operation or a create transction.
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Binary)]
|
||||||
pub struct Create {
|
pub struct Create {
|
||||||
/// The address of the creator.
|
/// The address of the creator.
|
||||||
pub from: Address,
|
pub from: Address,
|
||||||
@ -202,7 +205,7 @@ impl Create {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Description of an action that we trace; will be either a call or a create.
|
/// Description of an action that we trace; will be either a call or a create.
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Binary)]
|
||||||
pub enum Action {
|
pub enum Action {
|
||||||
/// It's a call action.
|
/// It's a call action.
|
||||||
Call(Call),
|
Call(Call),
|
||||||
@ -249,7 +252,7 @@ impl Action {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// The result of the performed action.
|
/// The result of the performed action.
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Binary)]
|
||||||
pub enum Res {
|
pub enum Res {
|
||||||
/// Successful call action result.
|
/// Successful call action result.
|
||||||
Call(CallResult),
|
Call(CallResult),
|
||||||
@ -300,7 +303,7 @@ impl Decodable for Res {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, PartialEq)]
|
#[derive(Debug, Clone, PartialEq, Binary)]
|
||||||
/// A trace; includes a description of the action being traced and sub traces of each interior action.
|
/// A trace; includes a description of the action being traced and sub traces of each interior action.
|
||||||
pub struct Trace {
|
pub struct Trace {
|
||||||
/// The number of EVM execution environments active when this action happened; 0 if it's
|
/// The number of EVM execution environments active when this action happened; 0 if it's
|
||||||
|
Loading…
Reference in New Issue
Block a user