Enum distant_protocol::ChangeKind
source · pub enum ChangeKind {
Access,
Attribute,
CloseWrite,
CloseNoWrite,
Create,
Delete,
Modify,
Open,
Rename,
Unknown,
}
Expand description
Represents a label attached to a Change
that describes the kind of change.
This mirrors events seen from incron
.
Variants§
Access
A file was read
Attribute
A file’s or directory’s attributes were changed
CloseWrite
A file open for writing was closed
CloseNoWrite
A file not open for writing was closed
Create
A file, directory, or something else was created within a watched directory
Delete
A file, directory, or something else was deleted
Modify
A file’s content was modified
Open
A file was opened
Rename
A file, directory, or something else was renamed in some way
Unknown
Catch-all for any other change
Implementations§
source§impl ChangeKind
impl ChangeKind
sourcepub fn all() -> Vec<ChangeKind>
pub fn all() -> Vec<ChangeKind>
Returns a list of all variants as a vec
sourcepub fn is_unknown(&self) -> bool
pub fn is_unknown(&self) -> bool
Returns true if kind is unknown.
Trait Implementations§
source§impl BitOr<ChangeKind> for ChangeKind
impl BitOr<ChangeKind> for ChangeKind
source§impl BitOr<ChangeKind> for ChangeKindSet
impl BitOr<ChangeKind> for ChangeKindSet
§type Output = ChangeKindSet
type Output = ChangeKindSet
The resulting type after applying the
|
operator.source§impl BitOr<ChangeKindSet> for ChangeKind
impl BitOr<ChangeKindSet> for ChangeKind
§type Output = ChangeKindSet
type Output = ChangeKindSet
The resulting type after applying the
|
operator.source§impl Clone for ChangeKind
impl Clone for ChangeKind
source§fn clone(&self) -> ChangeKind
fn clone(&self) -> ChangeKind
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ChangeKind
impl Debug for ChangeKind
source§impl<'de> Deserialize<'de> for ChangeKind
impl<'de> Deserialize<'de> for ChangeKind
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 Display for ChangeKind
impl Display for ChangeKind
source§impl From<ChangeKind> for ChangeKindSet
impl From<ChangeKind> for ChangeKindSet
source§fn from(change_kind: ChangeKind) -> Self
fn from(change_kind: ChangeKind) -> Self
Converts to this type from the input type.
source§impl FromIterator<ChangeKind> for ChangeKindSet
impl FromIterator<ChangeKind> for ChangeKindSet
source§fn from_iter<I: IntoIterator<Item = ChangeKind>>(iter: I) -> Self
fn from_iter<I: IntoIterator<Item = ChangeKind>>(iter: I) -> Self
Creates a value from an iterator. Read more
source§impl FromStr for ChangeKind
impl FromStr for ChangeKind
source§impl Hash for ChangeKind
impl Hash for ChangeKind
source§impl Ord for ChangeKind
impl Ord for ChangeKind
source§fn cmp(&self, other: &ChangeKind) -> Ordering
fn cmp(&self, other: &ChangeKind) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<ChangeKind> for ChangeKind
impl PartialEq<ChangeKind> for ChangeKind
source§fn eq(&self, other: &ChangeKind) -> bool
fn eq(&self, other: &ChangeKind) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<ChangeKind> for ChangeKind
impl PartialOrd<ChangeKind> for ChangeKind
source§fn partial_cmp(&self, other: &ChangeKind) -> Option<Ordering>
fn partial_cmp(&self, other: &ChangeKind) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for ChangeKind
impl Serialize for ChangeKind
source§impl TryFrom<&str> for ChangeKind
impl TryFrom<&str> for ChangeKind
source§impl VariantNames for ChangeKind
impl VariantNames for ChangeKind
impl Copy for ChangeKind
impl Eq for ChangeKind
impl StructuralEq for ChangeKind
impl StructuralPartialEq for ChangeKind
Auto Trait Implementations§
impl RefUnwindSafe for ChangeKind
impl Send for ChangeKind
impl Sync for ChangeKind
impl Unpin for ChangeKind
impl UnwindSafe for ChangeKind
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