diff options
Diffstat (limited to 'librepology/src/v1/types/download.rs')
-rw-r--r-- | librepology/src/v1/types/download.rs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/librepology/src/v1/types/download.rs b/librepology/src/v1/types/download.rs new file mode 100644 index 0000000..e337baa --- /dev/null +++ b/librepology/src/v1/types/download.rs @@ -0,0 +1,16 @@ +use std::ops::Deref; + +use url::Url; + +// list of package downloads +#[derive(Eq, PartialEq, Clone, Debug, Serialize, Deserialize)] +pub struct Download(#[serde(with = "url_serde")] Url); + +impl Deref for Download { + type Target = Url; + + fn deref(&self) -> &Self::Target { + &self.0 + } +} + |