pub struct Tag(/* private fields */);
Expand description
An APE Tag containing APE Tag Items.
§Examples
§Creating a tag
use ape::{Item, ItemType, Tag, write_to_path};
let mut tag = Tag::new();
let item = Item::new("artist", ItemType::Text, "Artist Name").unwrap();
tag.set_item(item);
write_to_path(&tag, "path/to/file").unwrap();
§Updating a tag
use ape::{Item, ItemType, read_from_path, write_to_path};
let path = "path/to/file";
let mut tag = read_from_path(path).unwrap();
let item = Item::new("album", ItemType::Text, "Album Name").unwrap();
tag.set_item(item);
tag.remove_items("cover");
write_to_path(&tag, path).unwrap();
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Tag
impl RefUnwindSafe for Tag
impl Send for Tag
impl Sync for Tag
impl Unpin for Tag
impl UnwindSafe for Tag
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more