diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/call/account.rs | 2 | ||||
-rw-r--r-- | src/call/mod.rs | 2 | ||||
-rw-r--r-- | src/response/mod.rs | 1 |
3 files changed, 4 insertions, 1 deletions
diff --git a/src/call/account.rs b/src/call/account.rs index 04fe52d..2cd89d5 100644 --- a/src/call/account.rs +++ b/src/call/account.rs @@ -3,6 +3,7 @@ use super::Call; use std::collections::BTreeMap; // Contains login information. Used to create an API session. +#[derive(Clone, Debug)] pub(crate) struct Login<'a> { pub(crate) user: &'a str, pub(crate) pass: &'a str, @@ -33,6 +34,7 @@ impl Call for Login<'_> { // Contains no information. This just signals to the server // that it should end the session. +#[derive(Clone, Debug)] pub(crate) struct Logout; impl From<Logout> for xmlrpc::Value { diff --git a/src/call/mod.rs b/src/call/mod.rs index 51fca5a..6b44a16 100644 --- a/src/call/mod.rs +++ b/src/call/mod.rs @@ -1,5 +1,5 @@ // A call to the API. -pub trait Call: Into<xmlrpc::Value> { +pub trait Call: Clone + std::fmt::Debug + Into<xmlrpc::Value> { fn method_name(&self) -> &'static str; fn expected(&self) -> &'static [i32]; } diff --git a/src/response/mod.rs b/src/response/mod.rs index 8d95dfb..4407c10 100644 --- a/src/response/mod.rs +++ b/src/response/mod.rs @@ -3,6 +3,7 @@ use std::collections::BTreeMap; /// A Response to an API call including status and data. /// Data is guaranteed to be a `Struct`. /// [`Struct`]: xmlrpc::Value::Struct +#[derive(Clone, Debug)] pub struct Response { pub status: i32, pub data: BTreeMap<String, xmlrpc::Value>, |