Struct lsp2::FileOperationPattern
pub struct FileOperationPattern {
pub glob: String,
pub matches: Option<FileOperationPatternKind>,
pub options: Option<FileOperationPatternOptions>,
}
Expand description
A pattern to describe in which file operation requests or notifications the server is interested in.
@since 3.16.0
Fields§
§glob: String
The glob pattern to match. Glob patterns can have the following syntax:
*
to match one or more characters in a path segment?
to match on one character in a path segment**
to match any number of path segments, including none{}
to group conditions (e.g.**/*.{ts,js}
matches all TypeScript and JavaScript files)[]
to declare a range of characters to match in a path segment (e.g.,example.[0-9]
to match onexample.0
,example.1
, …)[!...]
to negate a range of characters to match in a path segment (e.g.,example.[!0-9]
to match onexample.a
,example.b
, but notexample.0
)
matches: Option<FileOperationPatternKind>
Whether to match files or folders with this pattern.
Matches both if undefined.
options: Option<FileOperationPatternOptions>
Additional options used during matching.
Trait Implementations§
§impl Clone for FileOperationPattern
impl Clone for FileOperationPattern
§fn clone(&self) -> FileOperationPattern
fn clone(&self) -> FileOperationPattern
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more§impl Debug for FileOperationPattern
impl Debug for FileOperationPattern
§impl Default for FileOperationPattern
impl Default for FileOperationPattern
§fn default() -> FileOperationPattern
fn default() -> FileOperationPattern
Returns the “default value” for a type. Read more
§impl<'de> Deserialize<'de> for FileOperationPattern
impl<'de> Deserialize<'de> for FileOperationPattern
§fn deserialize<__D>(
__deserializer: __D
) -> Result<FileOperationPattern, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<FileOperationPattern, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl PartialEq<FileOperationPattern> for FileOperationPattern
impl PartialEq<FileOperationPattern> for FileOperationPattern
§fn eq(&self, other: &FileOperationPattern) -> bool
fn eq(&self, other: &FileOperationPattern) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.§impl Serialize for FileOperationPattern
impl Serialize for FileOperationPattern
§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>( &self, __serializer: __S ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where __S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Eq for FileOperationPattern
impl StructuralEq for FileOperationPattern
impl StructuralPartialEq for FileOperationPattern
Auto Trait Implementations§
impl RefUnwindSafe for FileOperationPattern
impl Send for FileOperationPattern
impl Sync for FileOperationPattern
impl Unpin for FileOperationPattern
impl UnwindSafe for FileOperationPattern
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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.