pub struct WorkspaceRootConfig {
root_dir: PathBuf,
members: Option<Vec<String>>,
default_members: Option<Vec<String>>,
exclude: Vec<String>,
inheritable_fields: InheritableFields,
custom_metadata: Option<Value>,
}
Expand description
Intermediate configuration of a workspace root in a manifest.
Knows the Workspace Root path, as well as members
and exclude
lists of path patterns, which
together tell if some path is recognized as a member by this root or not.
Fields§
§root_dir: PathBuf
§members: Option<Vec<String>>
§default_members: Option<Vec<String>>
§exclude: Vec<String>
§inheritable_fields: InheritableFields
§custom_metadata: Option<Value>
Implementations§
Source§impl WorkspaceRootConfig
impl WorkspaceRootConfig
Sourcepub fn new(
root_dir: &Path,
members: &Option<Vec<String>>,
default_members: &Option<Vec<String>>,
exclude: &Option<Vec<String>>,
inheritable: &Option<InheritableFields>,
custom_metadata: &Option<Value>,
) -> WorkspaceRootConfig
pub fn new( root_dir: &Path, members: &Option<Vec<String>>, default_members: &Option<Vec<String>>, exclude: &Option<Vec<String>>, inheritable: &Option<InheritableFields>, custom_metadata: &Option<Value>, ) -> WorkspaceRootConfig
Creates a new Intermediate Workspace Root configuration.
Sourcefn is_excluded(&self, manifest_path: &Path) -> bool
fn is_excluded(&self, manifest_path: &Path) -> bool
Checks the path against the excluded
list.
This method does not consider the members
list.
fn has_members_list(&self) -> bool
Sourcefn members_paths<'g>(
&self,
globs: &'g [String],
) -> CargoResult<Vec<(PathBuf, Option<&'g str>)>>
fn members_paths<'g>( &self, globs: &'g [String], ) -> CargoResult<Vec<(PathBuf, Option<&'g str>)>>
Returns expanded paths along with the glob that they were expanded from.
The glob is None
if the path matched exactly.
fn expand_member_path(path: &Path) -> CargoResult<Vec<PathBuf>>
pub fn inheritable(&self) -> &InheritableFields
Trait Implementations§
Source§impl Clone for WorkspaceRootConfig
impl Clone for WorkspaceRootConfig
Source§fn clone(&self) -> WorkspaceRootConfig
fn clone(&self) -> WorkspaceRootConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl Freeze for WorkspaceRootConfig
impl RefUnwindSafe for WorkspaceRootConfig
impl Send for WorkspaceRootConfig
impl Sync for WorkspaceRootConfig
impl Unpin for WorkspaceRootConfig
impl UnwindSafe for WorkspaceRootConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
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>
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§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>where
S: Into<Dispatch>,
§fn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
impl<T> ErasedDestructor for Twhere
T: 'static,
impl<T> MaybeSendSync for T
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 680 bytes