pub enum SourceRecord {
Bundled,
Local(PathBuf),
Git {
url: String,
rev: Option<String>,
},
Prebuilt {
url: String,
},
Unknown,
}Expand description
Where a plugin on disk came from.
Variants§
Bundled
Ships with lattice, discovered from the runtime root (§7). Never built by the editor.
Local(PathBuf)
Built in place from a directory the user named.
Git
Cloned from a git remote.
Prebuilt
Downloaded ready-built.
Unknown
Present on disk with no marker — hand-installed, or installed by a
lattice older than PM.8. Explicitly a state, not a fallback to
Local: claiming a source we do not know would make the column lie.
Implementations§
Source§impl SourceRecord
impl SourceRecord
Sourcepub fn is_buildable(&self) -> bool
pub fn is_buildable(&self) -> bool
Can the editor rebuild this from source? Prebuilt and Bundled
cannot — there is nothing to build — and Unknown has nowhere to
build from.
Sourcepub fn as_plugin_source(&self) -> Option<PluginSource>
pub fn as_plugin_source(&self) -> Option<PluginSource>
The resolver input this record describes, for a rebuild (PM.8b).
Trait Implementations§
Source§impl Clone for SourceRecord
impl Clone for SourceRecord
Source§fn clone(&self) -> SourceRecord
fn clone(&self) -> SourceRecord
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 SourceRecord
impl Debug for SourceRecord
impl Eq for SourceRecord
Source§impl PartialEq for SourceRecord
impl PartialEq for SourceRecord
impl StructuralPartialEq for SourceRecord
Auto Trait Implementations§
impl Freeze for SourceRecord
impl RefUnwindSafe for SourceRecord
impl Send for SourceRecord
impl Sync for SourceRecord
impl Unpin for SourceRecord
impl UnsafeUnpin for SourceRecord
impl UnwindSafe for SourceRecord
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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