XML DOM | NodeList Object

XML DOM - NodeList Object


Hello folks! welcome back to a new section of our tutorial on XML DOM. In this tutorial post, we are going to be studying about the XML DOM NodeList Object.

The XML DOM NodeList object represents an ordered collection of nodes. The items in the NodeList are accessable through an integral index, starting from 0.

NodeList Object Attributes

The following table lists the attributes of the NodeList object -

AttributeTypeDescription
lengthunsigned longIt gives the number of nodes in the node list.


NodeList Object Methods

The following table lists the methods of the NodeList object -

S.No.Method & Description
1item()

It returns the indexth item in the collection. If index is greater than or equal to the number of nodes in the list, this returns null.



Alright guys! This is where we are going to be rounding up for this tutorial post. In our next tutorial, we will be studying about XML DOM length Property.

Feel free to ask your questions where necessary and we will attend to them as soon as possible. If this tutorial was helpful to you, you can use the share button to share this tutorial.

Follow us on our various social media platforms to stay updated with our latest tutorials. You can also subscribe to our newsletter in order to get our tutorials delivered directly to your emails.

Thanks for reading and bye for now.