[−][src]Struct web_sys::Range
The Range
object
This API requires the following crate features to be activated: Range
Methods
impl Range
[src]
pub fn new() -> Result<Range, JsValue>
[src]
The new Range(..)
constructor, creating a new instance of Range
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn clone_contents(&self) -> Result<DocumentFragment, JsValue>
[src]
The cloneContents()
method
This API requires the following crate features to be activated: DocumentFragment
, Range
impl Range
[src]
pub fn clone_range(&self) -> Range
[src]
The cloneRange()
method
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn collapse(&self)
[src]
The collapse()
method
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn collapse_with_to_start(&self, to_start: bool)
[src]
The collapse()
method
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn compare_boundary_points(
&self,
how: u16,
source_range: &Range
) -> Result<i16, JsValue>
[src]
&self,
how: u16,
source_range: &Range
) -> Result<i16, JsValue>
The compareBoundaryPoints()
method
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn compare_point(&self, node: &Node, offset: u32) -> Result<i16, JsValue>
[src]
The comparePoint()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn create_contextual_fragment(
&self,
fragment: &str
) -> Result<DocumentFragment, JsValue>
[src]
&self,
fragment: &str
) -> Result<DocumentFragment, JsValue>
The createContextualFragment()
method
This API requires the following crate features to be activated: DocumentFragment
, Range
impl Range
[src]
pub fn delete_contents(&self) -> Result<(), JsValue>
[src]
The deleteContents()
method
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn detach(&self)
[src]
The detach()
method
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn extract_contents(&self) -> Result<DocumentFragment, JsValue>
[src]
The extractContents()
method
This API requires the following crate features to be activated: DocumentFragment
, Range
impl Range
[src]
pub fn get_bounding_client_rect(&self) -> DomRect
[src]
The getBoundingClientRect()
method
This API requires the following crate features to be activated: DomRect
, Range
impl Range
[src]
pub fn get_client_rects(&self) -> Option<DomRectList>
[src]
The getClientRects()
method
This API requires the following crate features to be activated: DomRectList
, Range
impl Range
[src]
pub fn insert_node(&self, node: &Node) -> Result<(), JsValue>
[src]
The insertNode()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn intersects_node(&self, node: &Node) -> Result<bool, JsValue>
[src]
The intersectsNode()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn is_point_in_range(
&self,
node: &Node,
offset: u32
) -> Result<bool, JsValue>
[src]
&self,
node: &Node,
offset: u32
) -> Result<bool, JsValue>
The isPointInRange()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn select_node(&self, ref_node: &Node) -> Result<(), JsValue>
[src]
The selectNode()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn select_node_contents(&self, ref_node: &Node) -> Result<(), JsValue>
[src]
The selectNodeContents()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn set_end(&self, ref_node: &Node, offset: u32) -> Result<(), JsValue>
[src]
The setEnd()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn set_end_after(&self, ref_node: &Node) -> Result<(), JsValue>
[src]
The setEndAfter()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn set_end_before(&self, ref_node: &Node) -> Result<(), JsValue>
[src]
The setEndBefore()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn set_start(&self, ref_node: &Node, offset: u32) -> Result<(), JsValue>
[src]
The setStart()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn set_start_after(&self, ref_node: &Node) -> Result<(), JsValue>
[src]
The setStartAfter()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn set_start_before(&self, ref_node: &Node) -> Result<(), JsValue>
[src]
The setStartBefore()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn surround_contents(&self, new_parent: &Node) -> Result<(), JsValue>
[src]
The surroundContents()
method
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn start_container(&self) -> Result<Node, JsValue>
[src]
The startContainer
getter
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn start_offset(&self) -> Result<u32, JsValue>
[src]
The startOffset
getter
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn end_container(&self) -> Result<Node, JsValue>
[src]
The endContainer
getter
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub fn end_offset(&self) -> Result<u32, JsValue>
[src]
The endOffset
getter
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn collapsed(&self) -> bool
[src]
The collapsed
getter
This API requires the following crate features to be activated: Range
impl Range
[src]
pub fn common_ancestor_container(&self) -> Result<Node, JsValue>
[src]
The commonAncestorContainer
getter
This API requires the following crate features to be activated: Node
, Range
impl Range
[src]
pub const START_TO_START: u16
[src]
impl Range
[src]
pub const START_TO_END: u16
[src]
impl Range
[src]
pub const END_TO_END: u16
[src]
impl Range
[src]
pub const END_TO_START: u16
[src]
Trait Implementations
impl Clone for Range
[src]
fn clone(&self) -> Range
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl From<JsValue> for Range
[src]
impl From<Range> for JsValue
[src]
impl From<Range> for Object
[src]
impl AsRef<JsValue> for Range
[src]
impl AsRef<Object> for Range
[src]
impl Deref for Range
[src]
impl Debug for Range
[src]
impl FromWasmAbi for Range
[src]
type Abi = <JsValue as FromWasmAbi>::Abi
The wasm ABI type that this converts from when coming back out from the ABI boundary. Read more
unsafe fn from_abi(js: Self::Abi, extra: &mut dyn Stack) -> Self
[src]
impl WasmDescribe for Range
[src]
impl IntoWasmAbi for Range
[src]
type Abi = <JsValue as IntoWasmAbi>::Abi
The wasm ABI type that this converts into when crossing the ABI boundary. Read more
fn into_abi(self, extra: &mut dyn Stack) -> Self::Abi
[src]
impl<'a> IntoWasmAbi for &'a Range
[src]
type Abi = <&'a JsValue as IntoWasmAbi>::Abi
The wasm ABI type that this converts into when crossing the ABI boundary. Read more
fn into_abi(self, extra: &mut dyn Stack) -> Self::Abi
[src]
impl OptionFromWasmAbi for Range
[src]
impl OptionIntoWasmAbi for Range
[src]
impl<'a> OptionIntoWasmAbi for &'a Range
[src]
impl RefFromWasmAbi for Range
[src]
type Abi = <JsValue as RefFromWasmAbi>::Abi
The wasm ABI type references to Self
are recovered from.
type Anchor = ManuallyDrop<Range>
The type that holds the reference to Self
for the duration of the invocation of the function that has an &Self
parameter. This is required to ensure that the lifetimes don't persist beyond one function call, and so that they remain anonymous. Read more
unsafe fn ref_from_abi(js: Self::Abi, extra: &mut dyn Stack) -> Self::Anchor
[src]
impl JsCast for Range
[src]
fn instanceof(val: &JsValue) -> bool
[src]
fn unchecked_from_js(val: JsValue) -> Self
[src]
fn unchecked_from_js_ref(val: &JsValue) -> &Self
[src]
fn is_instance_of<T>(&self) -> bool where
T: JsCast,
[src]
T: JsCast,
Test whether this JS value is an instance of the type T
. Read more
fn dyn_into<T>(self) -> Result<T, Self> where
T: JsCast,
[src]
T: JsCast,
Performs a dynamic cast (checked at runtime) of this value into the target type T
. Read more
fn dyn_ref<T>(&self) -> Option<&T> where
T: JsCast,
[src]
T: JsCast,
Performs a dynamic cast (checked at runtime) of this value into the target type T
. Read more
fn unchecked_into<T>(self) -> T where
T: JsCast,
[src]
T: JsCast,
Performs a zero-cost unchecked cast into the specified type. Read more
fn unchecked_ref<T>(&self) -> &T where
T: JsCast,
[src]
T: JsCast,
Performs a zero-cost unchecked cast into a reference to the specified type. Read more
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> ReturnWasmAbi for T where
T: IntoWasmAbi,
[src]
T: IntoWasmAbi,
type Abi = <T as IntoWasmAbi>::Abi
Same as IntoWasmAbi::Abi