[−][src]Struct nextcloud_passwords_client::tag::TagApi
Actions on the TagApi API
Implementations
impl<'a> TagApi<'a>
[src]
pub async fn list<'_>(
&'_ self,
details: Option<Details>
) -> Result<Vec<Tag>, Error>
[src]
&'_ self,
details: Option<Details>
) -> Result<Vec<Tag>, Error>
The list action lists all tags of the user except those in trash and the hidden ones.
Notes
- The list will not include trashed tags
- The list will not include hidden tags
pub async fn get<'_>(
&'_ self,
details: Option<Details>,
id: Uuid
) -> Result<Tag, Error>
[src]
&'_ self,
details: Option<Details>,
id: Uuid
) -> Result<Tag, Error>
The show action lists the properties of a single tag.
Notes
- This is the only action that can access hidden tags
pub async fn find<'_>(
&'_ self,
criteria: TagSearch,
details: Option<Details>
) -> Result<Vec<Tag>, Error>
[src]
&'_ self,
criteria: TagSearch,
details: Option<Details>
) -> Result<Vec<Tag>, Error>
The find action can be used to find all tags matching the given search criteria
Notes
- The property trashed will be set to false if not present
- The list will not include hidden tags
pub async fn create<'_>(
&'_ self,
value: CreateTag
) -> Result<TagIdentifier, Error>
[src]
&'_ self,
value: CreateTag
) -> Result<TagIdentifier, Error>
The create action creates a new tag with the given attributes.
Notes
- If the edited argument is "0", missing or in the future, the current time will be used
pub async fn update<'_>(
&'_ self,
folder: UpdateTag
) -> Result<TagIdentifier, Error>
[src]
&'_ self,
folder: UpdateTag
) -> Result<TagIdentifier, Error>
The update action creates a new revision of a tag with an updated set of attributes.
Notes
- If you hide a tag, the tag will be no longer visible in passwords which are not hidden, but the passwords will be visible in the tag
- If the edited argument is "0" or missing, the timestamp from the last revision will be used
- If the edited time is in the future, the current time will be used
pub async fn delete<'_>(
&'_ self,
id: Uuid,
revision: Option<Uuid>
) -> Result<TrashedIdentifier, Error>
[src]
&'_ self,
id: Uuid,
revision: Option<Uuid>
) -> Result<TrashedIdentifier, Error>
The delete action moves a tag to the trash or deletes it completely if it is already in the trash.
Notes
- If a tag is moved to the trash, the relation to all passwords which are not in trash will be hidden from the password
- If a tag is deleted, all relations to passwords are deleted
- If the revision is set, the tag will only be deleted if that revision is the current revision. This way, a tag is not accidentally deleted instead of trashed if the client is out of sync.
pub async fn restore<'_>(
&'_ self,
id: Uuid,
revision: Option<Uuid>
) -> Result<TagIdentifier, Error>
[src]
&'_ self,
id: Uuid,
revision: Option<Uuid>
) -> Result<TagIdentifier, Error>
The restore action can restore an earlier state of a tag.
Notes
- If no revision is given and the tag is in trash, it will be removed from trash
- If no revision is given and the tag is not in trash, nothing is done
- If a revision is given and the revision is marked as in trash, it will be removed from trash
- This action will always create a new revision
- The server side encryption type may change
- Deleted tags can not be restored
Auto Trait Implementations
impl<'a> !RefUnwindSafe for TagApi<'a>
impl<'a> Send for TagApi<'a>
impl<'a> Sync for TagApi<'a>
impl<'a> Unpin for TagApi<'a>
impl<'a> !UnwindSafe for TagApi<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,