pub struct ColorPresentationParams {
pub color: Color,
pub partial_result_token: Option<ProgressToken>,
pub range: Range,
pub text_document: TextDocumentIdentifier,
pub work_done_token: Option<ProgressToken>,
}Fields§
§color: ColorThe color information to request presentations for.
partial_result_token: Option<ProgressToken>An optional token that a server can use to report partial results (e.g. streaming) to the client.
range: RangeThe range where the color would be inserted. Serves as a context.
text_document: TextDocumentIdentifierThe text document.
work_done_token: Option<ProgressToken>An optional token that a server can use to report work done progress.
Implementations§
Source§impl ColorPresentationParams
impl ColorPresentationParams
Sourcepub fn ret(result: Vec<ColorPresentation>) -> Vec<ColorPresentation>
pub fn ret(result: Vec<ColorPresentation>) -> Vec<ColorPresentation>
helper function for user do not need to remember result type of a request
Trait Implementations§
Source§impl Clone for ColorPresentationParams
impl Clone for ColorPresentationParams
Source§fn clone(&self) -> ColorPresentationParams
fn clone(&self) -> ColorPresentationParams
Returns a duplicate 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 moreSource§impl Debug for ColorPresentationParams
impl Debug for ColorPresentationParams
Source§impl<'de> Deserialize<'de> for ColorPresentationParams
impl<'de> Deserialize<'de> for ColorPresentationParams
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
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 FromReq for ColorPresentationParams
impl FromReq for ColorPresentationParams
const METHOD: &'static str = "textDocument/colorPresentation"
type Ret = Vec<ColorPresentation>
Source§fn from_req(req: RequestMessage) -> OneOf<(ReqId, Self), RequestMessage>
fn from_req(req: RequestMessage) -> OneOf<(ReqId, Self), RequestMessage>
perform message cast from raw request message
if method do not match, return
OneOf::Other(request)Source§fn can_cast(req: &RequestMessage) -> bool
fn can_cast(req: &RequestMessage) -> bool
helper function to test method match or not
Source§impl PartialEq for ColorPresentationParams
impl PartialEq for ColorPresentationParams
Source§impl Serialize for ColorPresentationParams
impl Serialize for ColorPresentationParams
impl StructuralPartialEq for ColorPresentationParams
Auto Trait Implementations§
impl Freeze for ColorPresentationParams
impl RefUnwindSafe for ColorPresentationParams
impl Send for ColorPresentationParams
impl Sync for ColorPresentationParams
impl Unpin for ColorPresentationParams
impl UnwindSafe for ColorPresentationParams
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