moved old rpc implementation to v1/ dir

This commit is contained in:
debris 2016-01-27 17:14:41 +01:00
parent 61c64d264b
commit 856c348e3e
13 changed files with 16 additions and 11 deletions

View File

@ -50,7 +50,7 @@ fn setup_log(init: &String) {
#[cfg(feature = "rpc")] #[cfg(feature = "rpc")]
fn setup_rpc_server(client: Arc<Client>) { fn setup_rpc_server(client: Arc<Client>) {
use rpc::*; use rpc::v1::*;
let mut server = HttpServer::new(1); let mut server = HttpServer::new(1);
server.add_delegate(Web3Client::new().to_delegate()); server.add_delegate(Web3Client::new().to_delegate());

View File

@ -17,12 +17,7 @@ macro_rules! rpcerr {
() => (Err(Error::internal_error())) () => (Err(Error::internal_error()))
} }
pub mod traits; pub mod v1;
mod impls;
mod types;
pub use self::traits::{Web3, Eth, EthFilter, Net};
pub use self::impls::*;
/// Http server. /// Http server.
pub struct HttpServer { pub struct HttpServer {

View File

@ -6,8 +6,8 @@ use util::uint::*;
use util::sha3::*; use util::sha3::*;
use ethcore::client::*; use ethcore::client::*;
use ethcore::views::*; use ethcore::views::*;
use traits::{Eth, EthFilter}; use v1::traits::{Eth, EthFilter};
use types::Block; use v1::types::Block;
/// Eth rpc implementation. /// Eth rpc implementation.
pub struct EthClient { pub struct EthClient {

View File

@ -1,6 +1,6 @@
//! Net rpc implementation. //! Net rpc implementation.
use jsonrpc_core::*; use jsonrpc_core::*;
use traits::Net; use v1::traits::Net;
/// Net rpc implementation. /// Net rpc implementation.
pub struct NetClient; pub struct NetClient;

View File

@ -1,6 +1,6 @@
//! Web3 rpc implementation. //! Web3 rpc implementation.
use jsonrpc_core::*; use jsonrpc_core::*;
use traits::Web3; use v1::traits::Web3;
/// Web3 rpc implementation. /// Web3 rpc implementation.
pub struct Web3Client; pub struct Web3Client;

10
rpc/src/v1/mod.rs Normal file
View File

@ -0,0 +1,10 @@
//! Ethcore rpc v1.
//!
//! Compliant with ethereum rpc.
pub mod traits;
mod impls;
mod types;
pub use self::traits::{Web3, Eth, EthFilter, Net};
pub use self::impls::*;