pub struct Documentation { /* private fields */ }Expand description
Collection of all the documentation entries across the project
Implementations§
Source§impl Documentation
impl Documentation
Sourcepub fn contains_key(&self, key: &ContentOrigin) -> bool
pub fn contains_key(&self, key: &ContentOrigin) -> bool
Check if a particular key is contained.
Sourcepub fn iter(
&self,
) -> impl Iterator<Item = (&ContentOrigin, &Vec<CheckableChunk>)>
pub fn iter( &self, ) -> impl Iterator<Item = (&ContentOrigin, &Vec<CheckableChunk>)>
Borrowing iterator across content origins and associated sets of chunks.
Sourcepub fn par_iter(
&self,
) -> impl ParallelIterator<Item = (&ContentOrigin, &Vec<CheckableChunk>)>
pub fn par_iter( &self, ) -> impl ParallelIterator<Item = (&ContentOrigin, &Vec<CheckableChunk>)>
Borrowing iterator across content origins and associated sets of chunks.
Sourcepub fn into_par_iter(
self,
) -> impl ParallelIterator<Item = (ContentOrigin, Vec<CheckableChunk>)>
pub fn into_par_iter( self, ) -> impl ParallelIterator<Item = (ContentOrigin, Vec<CheckableChunk>)>
Consuming iterator across content origins and associated sets of chunks.
Sourcepub fn extend<I, J>(&mut self, other: I)where
I: IntoIterator<Item = (ContentOrigin, Vec<CheckableChunk>), IntoIter = J>,
J: Iterator<Item = (ContentOrigin, Vec<CheckableChunk>)>,
pub fn extend<I, J>(&mut self, other: I)where
I: IntoIterator<Item = (ContentOrigin, Vec<CheckableChunk>), IntoIter = J>,
J: Iterator<Item = (ContentOrigin, Vec<CheckableChunk>)>,
Extend self by joining in other Documentations.
Sourcepub fn add_inner(&mut self, origin: ContentOrigin, chunks: Vec<CheckableChunk>)
pub fn add_inner(&mut self, origin: ContentOrigin, chunks: Vec<CheckableChunk>)
Adds a set of CheckableChunks to the documentation to be checked.
Sourcepub fn add_rust(
&mut self,
origin: ContentOrigin,
content: &str,
doc_comments: bool,
dev_comments: bool,
) -> Result<()>
pub fn add_rust( &mut self, origin: ContentOrigin, content: &str, doc_comments: bool, dev_comments: bool, ) -> Result<()>
Adds a rust content str to the documentation.
Sourcepub fn add_cargo_manifest_description(
&mut self,
path: PathBuf,
manifest_content: &str,
) -> Result<()>
pub fn add_cargo_manifest_description( &mut self, path: PathBuf, manifest_content: &str, ) -> Result<()>
Adds a content string to the documentation sourced from the
description field in a Cargo.toml manifest.
Sourcepub fn add_commonmark(
&mut self,
origin: ContentOrigin,
content: &str,
) -> Result<()>
pub fn add_commonmark( &mut self, origin: ContentOrigin, content: &str, ) -> Result<()>
Adds a common mark content str to the documentation.
Sourcepub fn get(&self, origin: &ContentOrigin) -> Option<&[CheckableChunk]>
pub fn get(&self, origin: &ContentOrigin) -> Option<&[CheckableChunk]>
Obtain the set of chunks for a particular origin.
Sourcepub fn entry_count(&self) -> usize
pub fn entry_count(&self) -> usize
Count the number of origins.
Sourcepub fn load_from_str(
origin: ContentOrigin,
content: &str,
doc_comments: bool,
dev_comments: bool,
) -> Self
pub fn load_from_str( origin: ContentOrigin, content: &str, doc_comments: bool, dev_comments: bool, ) -> Self
Load a document from a single string with a defined origin.
pub fn len(&self) -> usize
Trait Implementations§
Source§impl Clone for Documentation
impl Clone for Documentation
Source§fn clone(&self) -> Documentation
fn clone(&self) -> Documentation
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Documentation
impl Debug for Documentation
Source§impl Default for Documentation
impl Default for Documentation
Source§impl IntoIterator for Documentation
impl IntoIterator for Documentation
Source§type Item = (ContentOrigin, Vec<CheckableChunk>)
type Item = (ContentOrigin, Vec<CheckableChunk>)
Source§type IntoIter = IntoIter<ContentOrigin, Vec<CheckableChunk>>
type IntoIter = IntoIter<ContentOrigin, Vec<CheckableChunk>>
Auto Trait Implementations§
impl Freeze for Documentation
impl RefUnwindSafe for Documentation
impl Send for Documentation
impl Sync for Documentation
impl Unpin for Documentation
impl UnsafeUnpin for Documentation
impl UnwindSafe for Documentation
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more