pub enum TextRetrievalOption {
InnerText,
Attribute(String),
AttributeStartsWith(String),
}
Expand description
Different options for retrieving text from a node. We generate selectors for every node that yields text that matches the expected attribute value.
Variants§
InnerText
Consider the node’s inner text as text.
Attribute(String)
Consider the value of the given attribute as text. For example, Attribute(“title”“) will consider the value of the “title” attribute as searchable text.
AttributeStartsWith(String)
Consider the value of the first attribute whose name starts with the given prefix as text. For example, AttributeStartsWith(“data-”) will consider the value of the first attribute whose name starts with “data-” as searchable text.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TextRetrievalOption
impl RefUnwindSafe for TextRetrievalOption
impl Send for TextRetrievalOption
impl Sync for TextRetrievalOption
impl Unpin for TextRetrievalOption
impl UnwindSafe for TextRetrievalOption
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