pub enum FileEvent {
CreateFile(SecretPath, ExternalFileName),
MoveFile {
name: ExternalFileName,
from: SecretPath,
dest: SecretPath,
},
DeleteFile(SecretPath, ExternalFileName),
// some variants omitted
}Available on crate feature
files only.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<()>> + Send + 'async_trait>>where
W: 'async_trait + AsyncWrite + AsyncSeek + Unpin + Send,
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn encode<'life0, 'life1, 'async_trait, W>(
&'life0 self,
writer: &'life1 mut BinaryWriter<W>,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
W: 'async_trait + AsyncWrite + AsyncSeek + Unpin + Send,
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Encode self into the binary writer.
Source§impl From<ExternalFile> for FileEvent
impl From<ExternalFile> for FileEvent
Source§fn from(value: ExternalFile) -> Self
fn from(value: ExternalFile) -> Self
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