[][src]Struct stdweb::web::HtmlCollection

pub struct HtmlCollection(_);

The HtmlCollection interface represents a generic collection (array-like object similar to arguments) of elements (in document order) and offers methods and properties for selecting from the list.

An HtmlCollection in the HTML DOM is live; it is automatically updated when the underlying document is changed.

(JavaScript docs)

Methods

impl HtmlCollection[src]

pub fn len(&self) -> u32[src]

Returns the number of elements in the collection.

(JavaScript docs)

pub fn item(&self, index: u32) -> Option<Element>[src]

Returns an element from an HtmlCollection by index.

(JavaScript docs)

pub fn iter(&self) -> ElementIter[src]

Returns an iterator over the collection.

Trait Implementations

impl JsSerialize for HtmlCollection[src]

impl TryFrom<HtmlCollection> for Reference[src]

type Error = Void

The type returned in the event of a conversion error.

impl TryFrom<Reference> for HtmlCollection[src]

type Error = ConversionError

The type returned in the event of a conversion error.

impl<'_r> TryFrom<&'_r Reference> for HtmlCollection[src]

type Error = ConversionError

The type returned in the event of a conversion error.

impl TryFrom<Value> for HtmlCollection[src]

type Error = ConversionError

The type returned in the event of a conversion error.

impl<'_r> TryFrom<&'_r Value> for HtmlCollection[src]

type Error = ConversionError

The type returned in the event of a conversion error.

impl InstanceOf for HtmlCollection[src]

impl ReferenceType for HtmlCollection[src]

impl IntoIterator for HtmlCollection[src]

type Item = Element

The type of the elements being iterated over.

type IntoIter = ElementIter

Which kind of iterator are we turning this into?

impl<'a> IntoIterator for &'a HtmlCollection[src]

type Item = Element

The type of the elements being iterated over.

type IntoIter = ElementIter

Which kind of iterator are we turning this into?

impl From<HtmlCollection> for Reference[src]

impl Eq for HtmlCollection[src]

impl AsRef<Reference> for HtmlCollection[src]

impl PartialEq<HtmlCollection> for HtmlCollection[src]

impl Clone for HtmlCollection[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for HtmlCollection[src]

Auto Trait Implementations

Blanket Implementations

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = !

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

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

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

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]