diff options
author | Matthias Beyer <mail@beyermatthias.de> | 2019-04-24 09:57:24 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-24 09:57:24 +0200 |
commit | 4f3aebf1d71e98a8c78495838e229ea3999a8db1 (patch) | |
tree | eab80d9db64cc63137d49198cabb33399cf98520 /librepology/src/v1/types/www.rs | |
parent | cf4edeadab3f54b328cbdd17e6d2ca8ac92e4a85 (diff) | |
parent | 35e92e4055b8a6c6294602627896cc22d234c0bd (diff) |
Merge pull request #5 from matthiasbeyer/lib-v1-types-in-mod
Split types into module and submodules
Diffstat (limited to 'librepology/src/v1/types/www.rs')
-rw-r--r-- | librepology/src/v1/types/www.rs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/librepology/src/v1/types/www.rs b/librepology/src/v1/types/www.rs new file mode 100644 index 0000000..a59ef02 --- /dev/null +++ b/librepology/src/v1/types/www.rs @@ -0,0 +1,15 @@ +use std::ops::Deref; +use url::Url; + +// list of package webpages +#[derive(Eq, PartialEq, Clone, Debug, Serialize, Deserialize)] +pub struct Www(#[serde(with = "url_serde")] Url); + +impl Deref for Www { + type Target = Url; + + fn deref(&self) -> &Self::Target { + &self.0 + } +} + |