pub struct LocatorSpec {
pub query: LocatorQuery,
pub frame_id: Option<String>,
pub index: Option<usize>,
}Expand description
A serializable locator. Frame identifiers and backend nodes are pinned identities.
Fields§
§query: LocatorQueryQuery used to resolve the target.
frame_id: Option<String>Pinned frame identifier, or the main frame when absent.
index: Option<usize>Explicit zero-based match index; absence requires a unique match.
Implementations§
Source§impl LocatorSpec
impl LocatorSpec
Sourcepub fn css(selector: impl Into<String>) -> LocatorSpec
pub fn css(selector: impl Into<String>) -> LocatorSpec
Create a strict CSS locator specification.
Sourcepub fn text(text: impl Into<String>) -> LocatorSpec
pub fn text(text: impl Into<String>) -> LocatorSpec
Create a strict text locator specification.
Trait Implementations§
Source§impl Clone for LocatorSpec
impl Clone for LocatorSpec
Source§fn clone(&self) -> LocatorSpec
fn clone(&self) -> LocatorSpec
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LocatorSpec
impl Debug for LocatorSpec
Source§impl<'de> Deserialize<'de> for LocatorSpec
impl<'de> Deserialize<'de> for LocatorSpec
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<LocatorSpec, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<LocatorSpec, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for LocatorSpec
Source§impl JsonSchema for LocatorSpec
impl JsonSchema for LocatorSpec
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for LocatorSpec
impl PartialEq for LocatorSpec
Source§impl Serialize for LocatorSpec
impl Serialize for LocatorSpec
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for LocatorSpec
Auto Trait Implementations§
impl Freeze for LocatorSpec
impl RefUnwindSafe for LocatorSpec
impl Send for LocatorSpec
impl Sync for LocatorSpec
impl Unpin for LocatorSpec
impl UnsafeUnpin for LocatorSpec
impl UnwindSafe for LocatorSpec
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