Struct readme_sync::CMarkDocs[][src]

pub struct CMarkDocs<P, M> { /* fields omitted */ }
Expand description

Parsed documentation Markdown with optionally specified package path and package manifest.

Implementations

Creates docs from package and default config.

First it reads docs file by path specified in the package manifest. Then it parses it with default configuration.

Creates docs from package and the specified config.

First it reads docs file by path specified in the package manifest. Then it parses it with the specified configuration.

Creates docs from file and the specified config.

The method parses a file with the specified configuration.

Adding the specified package path to the docs.

Adding the specified manifest to the docs.

Creates docs from file, config, package path and manifest.

Creates docs from file docs content, package path and manifest.

Creates docs from CMark items, package path and manifest.

Returns CMark items.

Consumes the CMarkDocs, returning CMarkData.

Returns the package path.

Returns the manifest.

Iterate over CMarkItems.

Iterate over pulldown-cmark events.

Concatenate adjacent text events.

Use this transformation if you deleted some nodes manually and want to merge the neighboring text nodes.

This transformation is always applied right after readme and docs parsing, because some text events remain ununited. For example Rust attribute parser generate seperate text events for every line of source code, and pulldown_cmark generate seperate text events for character entity reference.

Increment levels of all headings.

In readme, the first level heading is usually used only for the project title. The second level header is usually used in for text section headings in readme. Rustdoc automatically adds the header of a crate name and the first level headers are used for text sections.

So it is necessary to increase the level of all headings in the documentation in order to synchronize the headings.

Add a first level heading with the specified text.

This function could be useful after heading level incremented.

Remove section with the specified heading text and level and its subsections.

Remove the specified fenced code block tag.

Remove the specified fenced code block tags.

Remove fenced code block tags that are used by cargo test.

See https://doc.rust-lang.org/rustdoc/documentation-tests.html for more details.

Use the specified codeblock tag, if they are not specified

Use rust fenced codeblock highlight as default.

Remove hidden rust code from rust fenced codeblocks.

See https://doc.rust-lang.org/rustdoc/documentation-tests.html#hiding-portions-of-the-example for more details.

Returns self if absolute docs links to the specified repository not found, otherwise returns an error.

Convert all relative links into absolute ones using the specified package documentation url as the root address.

Add a first level heading with the manifest package name.

This function could be useful after heading level incremented.

Returns self if absolute docs links to the manifest repository not found, otherwise returns an error.

Convert all relative links into absolute ones using the manifest package documentation url as the root address.

Converts all links with function func applied to each link address.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.