pub enum FileEvent {
CreateFile(SecretPath, ExternalFileName),
MoveFile {
name: ExternalFileName,
from: SecretPath,
dest: SecretPath,
},
DeleteFile(SecretPath, ExternalFileName),
// some variants omitted
}Expand description
File event records changes to external files
There is no update file event because files are content-addressable by SHA256 digest so changing a file’s contents results in a delete and create.
Variants§
CreateFile(SecretPath, ExternalFileName)
File was created.
MoveFile
File was moved.
Fields
§
name: ExternalFileNameFile name.
§
from: SecretPathFrom identifiers.
§
dest: SecretPathDestination identifiers.
DeleteFile(SecretPath, ExternalFileName)
File was deleted.
Trait Implementations§
Source§impl Decodable for FileEvent
impl Decodable for FileEvent
Source§impl Encodable for FileEvent
impl Encodable for FileEvent
Source§fn encode<'life0, 'life1, 'async_trait, W>(
&'life0 self,
writer: &'life1 mut BinaryWriter<W>,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
W: 'async_trait + AsyncWrite + AsyncSeek + Unpin + Send,
FileEvent: 'async_trait,
fn encode<'life0, 'life1, 'async_trait, W>(
&'life0 self,
writer: &'life1 mut BinaryWriter<W>,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
W: 'async_trait + AsyncWrite + AsyncSeek + Unpin + Send,
FileEvent: 'async_trait,
Encode self into the binary writer.
Source§impl From<ExternalFile> for FileEvent
impl From<ExternalFile> for FileEvent
Source§fn from(value: ExternalFile) -> FileEvent
fn from(value: ExternalFile) -> FileEvent
Converts to this type from the input type.
Source§impl LogEvent for FileEvent
impl LogEvent for FileEvent
Source§fn event_kind(&self) -> EventKind
fn event_kind(&self) -> EventKind
Get the event kind for this event.
impl Eq for FileEvent
impl StructuralPartialEq for FileEvent
Auto Trait Implementations§
impl Freeze for FileEvent
impl RefUnwindSafe for FileEvent
impl Send for FileEvent
impl Sync for FileEvent
impl Unpin for FileEvent
impl UnwindSafe for FileEvent
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more