Struct umm::vscode::Pattern

source ·
pub struct Pattern {
    code: Option<usize>,
    column: Option<usize>,
    end_column: Option<usize>,
    end_line: Option<usize>,
    file: Option<usize>,
    kind: Option<String>,
    line: Option<usize>,
    location: Option<String>,
    loop: Option<bool>,
    message: Option<usize>,
    regexp: String,
    severity: Option<usize>,
}
Expand description

Struct for VSCode task’s problem matcher’s pattern.

Fields§

§code: Option<usize>

The match group index of the problem’s code. Defaults to undefined

§column: Option<usize>

The match group index of the problem’s line character. Defaults to 3

§end_column: Option<usize>

The match group index of the problem’s end line character. Defaults to undefined

§end_line: Option<usize>

The match group index of the problem’s end line. Defaults to undefined

§file: Option<usize>

The match group index of the filename. If omitted 1 is used.

§kind: Option<String>

whether the pattern matches a location (file and line) or only a file.

§line: Option<usize>

The match group index of the problem’s line. Defaults to 2

§location: Option<String>

The match group index of the problem’s location. Valid location patterns are: (line), (line,column) and (startLine,startColumn,endLine,endColumn). If omitted (line,column) is assumed.

§loop: Option<bool>

In a multi line matcher loop indicated whether this pattern is executed in a loop as long as it matches. Can only specified on a last pattern in a multi line pattern.

§message: Option<usize>

The match group index of the message. If omitted it defaults to 4 if location is specified. Otherwise it defaults to 5.

§regexp: String

The regular expression to find an error, warning or info in the output.

§severity: Option<usize>

The match group index of the problem’s severity. Defaults to undefined

Implementations§

source§

impl Pattern

source

pub fn builder( ) -> PatternBuilder<((), (), (), (), (), (), (), (), (), (), (), ())>

Create a builder for building Pattern. On the builder, call .code(...)(optional), .column(...)(optional), .end_column(...)(optional), .end_line(...)(optional), .file(...)(optional), .kind(...)(optional), .line(...)(optional), .location(...)(optional), .r#loop(...)(optional), .message(...)(optional), .regexp(...), .severity(...)(optional) to set the values of the fields. Finally, call .build() to create the instance of Pattern.

Trait Implementations§

source§

impl<'de> Deserialize<'de> for Pattern

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Serialize for Pattern

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into<'async_trait>( self ) -> Pin<Box<dyn Future<Output = Result<U, <U as TryFrom<T>>::Error>> + 'async_trait>>
where T: 'async_trait,

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more
source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,