Struct json5format::Comments
source · pub struct Comments { /* private fields */ }
Expand description
A struct containing all comments associated with a specific Value
.
Implementations§
source§impl Comments
impl Comments
sourcepub fn before_value(&self) -> &Vec<Comment>
pub fn before_value(&self) -> &Vec<Comment>
Retrieves the comments immediately before an associated value.
sourcepub fn append_end_of_line_comment(&mut self, comment: &str) -> Result<(), Error>
pub fn append_end_of_line_comment(&mut self, comment: &str) -> Result<(), Error>
Injects text into the end-of-line comment.
sourcepub fn end_of_line(&self) -> &Option<String>
pub fn end_of_line(&self) -> &Option<String>
Retrieves a reference to the end-of-line comment.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Comments
impl RefUnwindSafe for Comments
impl Send for Comments
impl Sync for Comments
impl Unpin for Comments
impl UnwindSafe for Comments
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)