pub enum SelectionRefusal {
Empty,
Unexpanded {
subject: String,
value: String,
home: Option<PathBuf>,
},
Relative(String),
NotQuotable(String),
NotADirectory(PathBuf),
Incompatible {
path: PathBuf,
reason: String,
},
}Variants§
Empty
A selection with no path in it.
Unexpanded
A shell path nothing expands: MCP host configuration is not a shell.
subject names whoever said it, because the same refusal answers the
explicit environment override and the saved selection alike.
Relative(String)
A relative path, which would mean a different store per working directory — the opposite of what saving a selection is for.
NotQuotable(String)
A path the settings file cannot carry back unchanged.
NotADirectory(PathBuf)
A path that exists and is not a directory.
Incompatible
A directory that holds a store this engine will not open.
Implementations§
Source§impl SelectionRefusal
impl SelectionRefusal
Sourcepub fn unexpanded(subject: impl Into<String>, value: impl Into<String>) -> Self
pub fn unexpanded(subject: impl Into<String>, value: impl Into<String>) -> Self
A ~ path, attributed to whoever wrote it.
Sourcepub fn concerns_an_existing_store(&self) -> bool
pub fn concerns_an_existing_store(&self) -> bool
Whether the refusal is about an existing store’s bytes, which is the case that has to promise it touched nothing.
Trait Implementations§
Source§impl Clone for SelectionRefusal
impl Clone for SelectionRefusal
Source§fn clone(&self) -> SelectionRefusal
fn clone(&self) -> SelectionRefusal
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 SelectionRefusal
impl Debug for SelectionRefusal
Source§impl Display for SelectionRefusal
impl Display for SelectionRefusal
impl Eq for SelectionRefusal
Source§impl PartialEq for SelectionRefusal
impl PartialEq for SelectionRefusal
impl StructuralPartialEq for SelectionRefusal
Auto Trait Implementations§
impl Freeze for SelectionRefusal
impl RefUnwindSafe for SelectionRefusal
impl Send for SelectionRefusal
impl Sync for SelectionRefusal
impl Unpin for SelectionRefusal
impl UnsafeUnpin for SelectionRefusal
impl UnwindSafe for SelectionRefusal
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