pub struct TagKind(pub u64);
Expand description
The tag kind
Tuple Fields§
§0: u64
Implementations§
source§impl TagKind
impl TagKind
sourcepub const AUTHOR: Self = _
pub const AUTHOR: Self = _
The tag represents the author of the post (the creator of the image, not the uploader).
sourcepub const COPYRIGHT: Self = _
pub const COPYRIGHT: Self = _
The tag rperesents the copyright holder of characters in the post.
sourcepub const METADATA: Self = _
pub const METADATA: Self = _
The tag represents some form of metadata, like the year the post was made.
sourcepub fn is_general(self) -> bool
pub fn is_general(self) -> bool
Returns true if this tag kind is general.
Returns true if this tag kind is an author.
sourcepub fn is_copyright(self) -> bool
pub fn is_copyright(self) -> bool
Retruns true if this tag is a copyright.
sourcepub fn is_character(self) -> bool
pub fn is_character(self) -> bool
Returns true if this tag kind is a character.
sourcepub fn is_metadata(self) -> bool
pub fn is_metadata(self) -> bool
Returns true if this tag kind is a metadata.
sourcepub fn is_unknown(self) -> bool
pub fn is_unknown(self) -> bool
Returns true if the tag kind is unknown.
Trait Implementations§
source§impl<'de> Deserialize<'de> for TagKind
impl<'de> Deserialize<'de> for TagKind
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for TagKind
impl PartialEq for TagKind
impl Copy for TagKind
impl Eq for TagKind
impl StructuralEq for TagKind
impl StructuralPartialEq for TagKind
Auto Trait Implementations§
impl RefUnwindSafe for TagKind
impl Send for TagKind
impl Sync for TagKind
impl Unpin for TagKind
impl UnwindSafe for TagKind
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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.