pub struct ValidateOptions {
pub cli_lints: BTreeMap<String, LintLevel>,
pub cli_preset: Option<LintPreset>,
}Expand description
Configuration applied during validation.
Fields§
§cli_lints: BTreeMap<String, LintLevel>Per-run lint level overrides keyed by lint code.
cli_preset: Option<LintPreset>Per-run lint preset.
Implementations§
Source§impl ValidateOptions
impl ValidateOptions
Sourcepub fn with_cli_lint_overrides(
entries: impl IntoIterator<Item = (String, LintLevel)>,
) -> Self
pub fn with_cli_lint_overrides( entries: impl IntoIterator<Item = (String, LintLevel)>, ) -> Self
Builds options from CLI-style lint overrides.
Sourcepub fn with_cli_preset(self, preset: Option<LintPreset>) -> Self
pub fn with_cli_preset(self, preset: Option<LintPreset>) -> Self
Applies a CLI-style preset to these options.
Trait Implementations§
Source§impl Clone for ValidateOptions
impl Clone for ValidateOptions
Source§fn clone(&self) -> ValidateOptions
fn clone(&self) -> ValidateOptions
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 ValidateOptions
impl Debug for ValidateOptions
Source§impl Default for ValidateOptions
impl Default for ValidateOptions
Source§fn default() -> ValidateOptions
fn default() -> ValidateOptions
Returns the “default value” for a type. Read more
Source§impl PartialEq for ValidateOptions
impl PartialEq for ValidateOptions
Source§fn eq(&self, other: &ValidateOptions) -> bool
fn eq(&self, other: &ValidateOptions) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ValidateOptions
impl StructuralPartialEq for ValidateOptions
Auto Trait Implementations§
impl Freeze for ValidateOptions
impl RefUnwindSafe for ValidateOptions
impl Send for ValidateOptions
impl Sync for ValidateOptions
impl Unpin for ValidateOptions
impl UnsafeUnpin for ValidateOptions
impl UnwindSafe for ValidateOptions
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.