diff --git a/src/main.rs b/src/main.rs index c9f66cc..131eb0d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -11,7 +11,6 @@ use yaserde_derive::{YaDeserialize, YaSerialize}; #[allow(unused)] fn publicise() {} -// #[derive(Default, PartialEq, Debug, YaDeserialize)] #[yaserde( rename = "multistatus", @@ -44,29 +43,6 @@ pub struct Propstat { status: Option, } -/* - - /nextcloud/remote.php/dav/files/adam/test_public/2021_test_public/ - - - Tue, 14 Dec 2021 03:46:36 GMT - RGDNVCK - - - - "61b8139c1beb0" - - HTTP/1.1 200 OK - - - - - - - HTTP/1.1 404 Not Found - - -*/ #[derive(Default, PartialEq, Debug, YaDeserialize)] #[yaserde(rename = "prop", namespace = "d: DAV:", namespace = "oc: http://owncloud.org/ns")] pub struct Prop { @@ -82,6 +58,15 @@ pub struct Prop { get_content_length: Option, #[yaserde(prefix = "d", rename = "getcontenttype")] get_content_type: Option, + #[yaserde(prefix = "oc", rename = "share-types")] + share_types: Vec, +} + +#[derive(Default, PartialEq, Debug, YaDeserialize)] +#[yaserde(rename = "share-types", namespace = "oc: http://owncloud.org/ns")] +pub struct ShareType { + #[yaserde(rename = "share-type", prefix = "oc")] + share_type: u8, } #[derive(Default, PartialEq, Debug, YaDeserialize)] @@ -174,5 +159,3 @@ async fn main() -> std::io::Result<()> { println!("{:?}", result); Ok(()) } - -// TO_BE_DELETED: Testing removal of SSH password.