[][src]Struct etebase::ItemMetadata

pub struct ItemMetadata { /* fields omitted */ }

Metadata of the item

Implementations

impl ItemMetadata[src]

pub fn new() -> Self[src]

Create a new metadata object

pub fn set_item_type(&mut self, type_: Option<&str>) -> &mut Self[src]

Set the item type

Arguments:

  • type - the type to be set

pub fn item_type(&self) -> Option<&str>[src]

The item type

pub fn set_name(&mut self, name: Option<&str>) -> &mut Self[src]

Set the item name

For example, you can set it to "Secret Note" or "todo.txt"

Arguments:

  • name - the name to be set

pub fn name(&self) -> Option<&str>[src]

The item name

pub fn set_mtime(&mut self, mtime: Option<i64>) -> &mut Self[src]

Set the modification time of the item

Arguments:

  • mtime - the modification time in milliseconds since epoch

pub fn mtime(&self) -> Option<i64>[src]

Modification time of the item

pub fn set_description(&mut self, description: Option<&str>) -> &mut Self[src]

Set a description for the item

Arguments:

  • description - the description to be set

pub fn description(&self) -> Option<&str>[src]

The item description

pub fn set_color(&mut self, color: Option<&str>) -> &mut Self[src]

Set a color for the item

Arguments:

  • color - the color to be set in #RRGGBB or #RRGGBBAA format

pub fn color(&self) -> Option<&str>[src]

The item color in #RRGGBB or #RRGGBBAA format

Trait Implementations

impl Clone for ItemMetadata[src]

impl Debug for ItemMetadata[src]

impl<'de> Deserialize<'de> for ItemMetadata[src]

impl MsgPackSerilization for ItemMetadata[src]

type Output = ItemMetadata

The type of the struct implementing this trait

impl PartialEq<ItemMetadata> for ItemMetadata[src]

impl Serialize for ItemMetadata[src]

impl StructuralPartialEq for ItemMetadata[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.