pub struct ProjectConfig {
pub include: Vec<String>,
pub exclude: Vec<String>,
}Expand description
项目树配置对象
include需要包含的路径的规则eclude需要排除的路径的规则
Fields§
§include: Vec<String>需要包含的路径
exclude: Vec<String>需要排除的路径
Implementations§
Source§impl ProjectConfig
impl ProjectConfig
Sourcepub fn add_include<S: Into<String>>(self, include: S) -> Self
pub fn add_include<S: Into<String>>(self, include: S) -> Self
添加单个 include(接受 &str 或 String)
Sourcepub fn add_includes<I, S>(self, includes: I) -> Self
pub fn add_includes<I, S>(self, includes: I) -> Self
添加需要被包含的路径
Sourcepub fn add_exclude<S: Into<String>>(self, exclude: S) -> Self
pub fn add_exclude<S: Into<String>>(self, exclude: S) -> Self
添加单个 exclude(接受 &str 或 String)
Sourcepub fn add_excludes<I, S>(self, excludes: I) -> Self
pub fn add_excludes<I, S>(self, excludes: I) -> Self
添加需要被忽略的路径
Sourcepub fn clear_include(self) -> Self
pub fn clear_include(self) -> Self
清空需要被包含的路径
Sourcepub fn clear_exclude(self) -> Self
pub fn clear_exclude(self) -> Self
清空需要被忽略的路径
Trait Implementations§
Source§impl Clone for ProjectConfig
impl Clone for ProjectConfig
Source§fn clone(&self) -> ProjectConfig
fn clone(&self) -> ProjectConfig
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 ProjectConfig
impl Debug for ProjectConfig
Source§impl Default for ProjectConfig
impl Default for ProjectConfig
Source§fn default() -> ProjectConfig
fn default() -> ProjectConfig
Returns the “default value” for a type. Read more
Source§impl PartialEq for ProjectConfig
impl PartialEq for ProjectConfig
impl StructuralPartialEq for ProjectConfig
Auto Trait Implementations§
impl Freeze for ProjectConfig
impl RefUnwindSafe for ProjectConfig
impl Send for ProjectConfig
impl Sync for ProjectConfig
impl Unpin for ProjectConfig
impl UnsafeUnpin for ProjectConfig
impl UnwindSafe for ProjectConfig
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