Trait parsoid::prelude::WikinodeIterator[][src]

pub trait WikinodeIterator {
Show 22 methods fn as_node(&self) -> &NodeRef; fn append(&self, code: &NodeRef) { ... }
fn prepend(&self, code: &NodeRef) { ... }
fn insert_after(&self, code: &NodeRef) { ... }
fn insert_before(&self, code: &NodeRef) { ... }
fn select(&self, selector: &str) -> Vec<Wikinode> { ... }
fn select_first(&self, selector: &str) -> Option<Wikinode> { ... }
fn filter_links(&self) -> Vec<WikiLink> { ... }
fn filter_external_links(&self) -> Vec<ExtLink> { ... }
fn filter_categories(&self) -> Vec<Category> { ... }
fn filter_templates(&self) -> Result<Vec<Template>> { ... }
fn filter_parser_functions(&self) -> Result<Vec<Template>> { ... }
fn iter_sections(&self) -> Vec<Section> { ... }
fn inclusive_ancestors(&self) -> WikinodeMap<Ancestors> { ... }
fn ancestors(&self) -> WikinodeMap<Ancestors> { ... }
fn inclusive_preceding_siblings(&self) -> WikinodeMap<Rev<Siblings>> { ... }
fn preceding_simblings(&self) -> WikinodeMap<Rev<Siblings>> { ... }
fn inclusive_following_siblings(&self) -> WikinodeMap<Siblings> { ... }
fn following_siblings(&self) -> WikinodeMap<Siblings> { ... }
fn children(&self) -> WikinodeMap<Siblings> { ... }
fn inclusive_descendants(&self) -> WikinodeMap<Descendants> { ... }
fn descendants(&self) -> WikinodeMap<Descendants> { ... }
}
Expand description

Collection of iterators and mutators that allow operating on a tree of Wikinodes

Required methods

Provided methods

Append a node as a child

Prepend a node as a child

Insert a node after the current node, as a sibling

Insert a node before the current node, as a sibling

Select some wiki nodes

Get the first element that matches the selector, if possible

Get a list of all wikilinks ([[Foo|bar]])

Get a list of all external links ([https://example.org/ Example])

Get a list of all categories

Get a list of templates

Get a list of parser functions.

Return an iterator of references to this node and its ancestors.

Return an iterator of references to this node’s ancestors.

Return an iterator of references to this node and the siblings before it.

Return an iterator of references to this node’s siblings before it.

Return an iterator of references to this node and the siblings after it.

Return an iterator of references to this node’s siblings after it.

Return an iterator of references to this node’s children.

Return an iterator of references to this node and its descendants, in tree order. Parent nodes appear before the descendants.

Return an iterator of references to this node’s descendants, in tree order. Parent nodes appear before the descendants.

Implementors