pub struct SphinxEnvironment {
pub docname_to_path: HashMap<String, PathBuf>,
pub path_to_docname: HashMap<PathBuf, String>,
pub dependencies: HashMap<String, Vec<String>>,
pub included: HashMap<String, Vec<String>>,
pub toctree_includes: HashMap<String, Vec<String>>,
pub files_to_rebuild: HashMap<String, Vec<String>>,
pub glob_toctrees: Vec<String>,
pub numbered_toctrees: Vec<String>,
pub metadata: HashMap<String, HashMap<String, String>>,
}Expand description
Sphinx build environment
Fields§
§docname_to_path: HashMap<String, PathBuf>§path_to_docname: HashMap<PathBuf, String>§dependencies: HashMap<String, Vec<String>>§included: HashMap<String, Vec<String>>§toctree_includes: HashMap<String, Vec<String>>§files_to_rebuild: HashMap<String, Vec<String>>§glob_toctrees: Vec<String>§numbered_toctrees: Vec<String>§metadata: HashMap<String, HashMap<String, String>>Implementations§
Source§impl SphinxEnvironment
impl SphinxEnvironment
Sourcepub fn add_document(&mut self, docname: String, path: PathBuf)
pub fn add_document(&mut self, docname: String, path: PathBuf)
Add a document to the environment
Sourcepub fn get_doc_path(&self, docname: &str) -> Option<&PathBuf>
pub fn get_doc_path(&self, docname: &str) -> Option<&PathBuf>
Get document path by name
Sourcepub fn get_docname(&self, path: &PathBuf) -> Option<&String>
pub fn get_docname(&self, path: &PathBuf) -> Option<&String>
Get document name by path
Sourcepub fn add_dependency(&mut self, docname: String, dependency: String)
pub fn add_dependency(&mut self, docname: String, dependency: String)
Add dependency between documents
Sourcepub fn get_dependencies(&self, docname: &str) -> Option<&Vec<String>>
pub fn get_dependencies(&self, docname: &str) -> Option<&Vec<String>>
Get dependencies for a document
Sourcepub fn add_metadata(&mut self, docname: String, key: String, value: String)
pub fn add_metadata(&mut self, docname: String, key: String, value: String)
Add metadata for a document
Trait Implementations§
Source§impl Debug for SphinxEnvironment
impl Debug for SphinxEnvironment
Auto Trait Implementations§
impl Freeze for SphinxEnvironment
impl RefUnwindSafe for SphinxEnvironment
impl Send for SphinxEnvironment
impl Sync for SphinxEnvironment
impl Unpin for SphinxEnvironment
impl UnwindSafe for SphinxEnvironment
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> 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>
Converts
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>
Converts
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