Struct lsp2::SemanticTokens
pub struct SemanticTokens {
pub result_id: Option<String>,
pub data: Vec<SemanticToken, Global>,
}
Expand description
@since 3.16.0
Fields§
§result_id: Option<String>
An optional result id. If provided and clients support delta updating the client will include the result id in the next semantic token request. A server can then instead of computing all semantic tokens again simply send a delta.
data: Vec<SemanticToken, Global>
The actual tokens. For a detailed description about how the data is structured please see https://github.com/microsoft/vscode-extension-samples/blob/5ae1f7787122812dcc84e37427ca90af5ee09f14/semantic-tokens-sample/vscode.proposed.d.ts#L71
Trait Implementations§
§impl Clone for SemanticTokens
impl Clone for SemanticTokens
§fn clone(&self) -> SemanticTokens
fn clone(&self) -> SemanticTokens
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 SemanticTokens
impl Debug for SemanticTokens
§impl Default for SemanticTokens
impl Default for SemanticTokens
§fn default() -> SemanticTokens
fn default() -> SemanticTokens
Returns the “default value” for a type. Read more
§impl<'de> Deserialize<'de> for SemanticTokens
impl<'de> Deserialize<'de> for SemanticTokens
§fn deserialize<__D>(
__deserializer: __D
) -> Result<SemanticTokens, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<SemanticTokens, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl From<SemanticTokens> for SemanticTokensFullDeltaResult
impl From<SemanticTokens> for SemanticTokensFullDeltaResult
§fn from(from: SemanticTokens) -> SemanticTokensFullDeltaResult
fn from(from: SemanticTokens) -> SemanticTokensFullDeltaResult
Converts to this type from the input type.
§impl From<SemanticTokens> for SemanticTokensRangeResult
impl From<SemanticTokens> for SemanticTokensRangeResult
§fn from(tokens: SemanticTokens) -> SemanticTokensRangeResult
fn from(tokens: SemanticTokens) -> SemanticTokensRangeResult
Converts to this type from the input type.
§impl From<SemanticTokens> for SemanticTokensResult
impl From<SemanticTokens> for SemanticTokensResult
§fn from(from: SemanticTokens) -> SemanticTokensResult
fn from(from: SemanticTokens) -> SemanticTokensResult
Converts to this type from the input type.
§impl PartialEq<SemanticTokens> for SemanticTokens
impl PartialEq<SemanticTokens> for SemanticTokens
§fn eq(&self, other: &SemanticTokens) -> bool
fn eq(&self, other: &SemanticTokens) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.§impl Serialize for SemanticTokens
impl Serialize for SemanticTokens
§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 SemanticTokens
impl StructuralEq for SemanticTokens
impl StructuralPartialEq for SemanticTokens
Auto Trait Implementations§
impl RefUnwindSafe for SemanticTokens
impl Send for SemanticTokens
impl Sync for SemanticTokens
impl Unpin for SemanticTokens
impl UnwindSafe for SemanticTokens
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.