Backend

Trait Backend 

Source
pub trait Backend {
    // Required methods
    fn compile(&self, params: &dyn BackendCompileParams) -> HyperlitResult<()>;
    fn transform_segment(&self, segment: &Segment) -> HyperlitResult<String>;

    // Provided method
    fn prepare(
        &mut self,
        _params: &mut dyn BackendCompileParams,
    ) -> HyperlitResult<()> { ... }
}
Expand description

An output backend

Required Methods§

Source

fn compile(&self, params: &dyn BackendCompileParams) -> HyperlitResult<()>

Perform the actual compilation of the documentation In this step the files in the build_directory should be transformed into the output_directory

Source

fn transform_segment(&self, segment: &Segment) -> HyperlitResult<String>

Transform a given segment into its representation in the backend language (e.g., markdown)

Provided Methods§

Source

fn prepare( &mut self, _params: &mut dyn BackendCompileParams, ) -> HyperlitResult<()>

Perform an (optional)preparation step before files are copied to the build directory

Implementors§