Rudimentary support for sending JSONRPC 2.0 requests and receiving responses.
This includes a pair of macros to enable serialization/deserialization of structures without using stable or nightly. They can be used as follows: ```rust
extern crate serde;
struct MyStruct {
elem1: bool,
elem2: String,
elem3: Vec
serdestructserialize!( MyStruct, MyStructMapVisitor, elem1 => 0, elem2 => 1, elem3 => 2 );
serdestructdeserialize!( MyStruct, MyStructVisitor, MyStructField, MyStructFieldVisitor, elem1 => Elem1, elem2 => Elem2, elem3 => Elem3 ); ``` The important parts in the above are that the name of the structure and names of the fields match those of the actual struct; every other identifier is used internally to the macros and can be made up.
(If anyone has ideas for how to clean up this external interface, please let me know.)
To send a request which should retrieve the above structure, consider the following example code
```rust
extern crate serde;
struct MyStruct {
elem1: bool,
elem2: String,
elem3: Vec
serdestructdeserialize!( MyStruct, MyStructVisitor, MyStructField, MyStructFieldVisitor, elem1 => Elem1, elem2 => Elem2, elem3 => Elem3 );
fn main() {
// The two Nones are for user/pass for authentication
let mut client = jsonrpc::client::Client::new("example.org", None, None);
let request = client.buildrequest("getmystruct", vec![]);
match client.sendrequest(&request).andthen(|res| res.intoresult::
```