diff options
Diffstat (limited to 'src/call/account.rs')
-rw-r--r-- | src/call/account.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/call/account.rs b/src/call/account.rs index f35ab00..865baf6 100644 --- a/src/call/account.rs +++ b/src/call/account.rs @@ -1,3 +1,5 @@ +use super::Call; + use std::collections::BTreeMap; // Contains login information. Used to create an API session. @@ -19,6 +21,11 @@ impl From<Login<'_>> for xmlrpc::Value { } } +impl Call for Login<'_> { + fn method_name(&self) -> &'static str { "account.login" } + fn expected(&self) -> &'static [i32] { &[1000] } +} + // Contains no information. This just signals to the server // that it should end the session. pub(crate) struct Logout; @@ -28,3 +35,8 @@ impl From<Logout> for xmlrpc::Value { xmlrpc::Value::Nil } } + +impl Call for Logout { + fn method_name(&self) -> &'static str { "account.logout" } + fn expected(&self) -> &'static [i32] { &[1500] } +} |