pub struct DocComment {
pub span: Span,
pub summary: String,
pub body: String,
pub tags: Vec<DocTag>,
}Fields§
§span: Span§summary: String§body: StringImplementations§
Source§impl DocComment
impl DocComment
pub fn is_empty(&self) -> bool
pub fn param_doc(&self, name: &str) -> Option<&str>
pub fn type_param_doc(&self, name: &str) -> Option<&str>
pub fn returns_doc(&self) -> Option<&str>
pub fn deprecated_doc(&self) -> Option<&str>
pub fn example_doc(&self) -> Option<&str>
pub fn since_doc(&self) -> Option<&str>
pub fn to_markdown(&self) -> String
Trait Implementations§
Source§impl Clone for DocComment
impl Clone for DocComment
Source§fn clone(&self) -> DocComment
fn clone(&self) -> DocComment
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 DocComment
impl Debug for DocComment
Source§impl Default for DocComment
impl Default for DocComment
Source§fn default() -> DocComment
fn default() -> DocComment
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for DocComment
impl<'de> Deserialize<'de> for DocComment
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 PartialEq for DocComment
impl PartialEq for DocComment
Source§impl Serialize for DocComment
impl Serialize for DocComment
impl Eq for DocComment
impl StructuralPartialEq for DocComment
Auto Trait Implementations§
impl Freeze for DocComment
impl RefUnwindSafe for DocComment
impl Send for DocComment
impl Sync for DocComment
impl Unpin for DocComment
impl UnsafeUnpin for DocComment
impl UnwindSafe for DocComment
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