pub enum DistantResponseData {
Show 17 variants Ok, Error(Error), Blob { data: Vec<u8>, }, Text { data: String, }, DirEntries { entries: Vec<DirEntry>, errors: Vec<Error>, }, Changed(Change), Exists { value: bool, }, Metadata(Metadata), SearchStarted { id: SearchId, }, SearchResults { id: SearchId, matches: Vec<SearchQueryMatch>, }, SearchDone { id: SearchId, }, ProcSpawned { id: ProcessId, }, ProcStdout { id: ProcessId, data: Vec<u8>, }, ProcStderr { id: ProcessId, data: Vec<u8>, }, ProcDone { id: ProcessId, success: bool, code: Option<i32>, }, SystemInfo(SystemInfo), Capabilities { supported: Capabilities, },
}
Expand description

Represents the payload of a successful response

Variants

Ok

General okay with no extra data, returned in cases like creating or removing a directory, copying a file, or renaming a file

Error(Error)

General-purpose failure that occurred from some request

Blob

Fields

data: Vec<u8>

Binary data associated with the response

Response containing some arbitrary, binary data

Text

Fields

data: String

Text data associated with the response

Response containing some arbitrary, text data

DirEntries

Fields

entries: Vec<DirEntry>

Entries contained within the requested directory

errors: Vec<Error>

Errors encountered while scanning for entries

Response to reading a directory

Changed(Change)

Response to a filesystem change for some watched file, directory, or symlink

Exists

Fields

value: bool

Response to checking if a path exists

Metadata(Metadata)

Represents metadata about some filesystem object (file, directory, symlink) on remote machine

SearchStarted

Fields

id: SearchId

Arbitrary id associated with search

Represents a search being started

SearchResults

Fields

id: SearchId

Arbitrary id associated with search

matches: Vec<SearchQueryMatch>

Collection of matches from performing a query

Represents some subset of results for a search query (may not be all of them)

SearchDone

Fields

id: SearchId

Arbitrary id associated with search

Represents a search being completed

ProcSpawned

Fields

id: ProcessId

Arbitrary id associated with running process

Response to starting a new process

ProcStdout

Fields

id: ProcessId

Arbitrary id associated with running process

data: Vec<u8>

Data read from a process’ stdout pipe

Actively-transmitted stdout as part of running process

ProcStderr

Fields

id: ProcessId

Arbitrary id associated with running process

data: Vec<u8>

Data read from a process’ stderr pipe

Actively-transmitted stderr as part of running process

ProcDone

Fields

id: ProcessId

Arbitrary id associated with running process

success: bool

Whether or not termination was successful

code: Option<i32>

Exit code associated with termination, will be missing if terminated by signal

Response to a process finishing

SystemInfo(SystemInfo)

Response to retrieving information about the server and the system it is on

Capabilities

Fields

supported: Capabilities

Response to retrieving information about the server’s capabilities

Implementations

Trait Implementations

Converts this type into a shared reference of the (usually inferred) input type.

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Converts to this type from the input type.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Converts reference to Any

Converts mutable reference to Any

Consumes and produces Box<dyn Any>

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more