[][src]Enum tamasfe_lsp_types::MarkedString

pub enum MarkedString {
    String(String),
    LanguageString(LanguageString),
}

The marked string is rendered:

  • as markdown if it is represented as a string
  • as code block of the given langauge if it is represented as a pair of a language and a value

The pair of a language and a value is an equivalent to markdown: ${language} ${value}

Variants

String(String)
LanguageString(LanguageString)

Implementations

impl MarkedString[src]

pub fn from_markdown(markdown: String) -> MarkedString[src]

pub fn from_language_code(language: String, code_block: String) -> MarkedString[src]

Trait Implementations

impl Clone for MarkedString[src]

impl Debug for MarkedString[src]

impl<'de> Deserialize<'de> for MarkedString[src]

impl Eq for MarkedString[src]

impl PartialEq<MarkedString> for MarkedString[src]

impl Serialize for MarkedString[src]

impl StructuralEq for MarkedString[src]

impl StructuralPartialEq for MarkedString[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.