use std::fmt;
use std::borrow::Cow;
use response::NamedResponse;
use response::NotArray;
#[derive(Deserialize, Debug)]
pub struct Account {
pub droplet_limit: f64,
pub email: String,
pub uuid: String,
pub email_verified: bool
}
impl NotArray for Account {}
impl fmt::Display for Account {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
write!(f, "Email: {}\n\
Droplet Limit: {:.0}\n\
UUID: {}\n\
E-Mail Verified: {}",
self.email,
self.droplet_limit,
self.uuid,
self.email_verified)
}
}
impl NamedResponse for Account {
fn name<'a>() -> Cow<'a, str> {
"account".into()
}
}