Properties and Methods of the nodeList Object

Since the nodeList object is a list and not a node, there are none of the properties that the document and node objects use to work with their data. In fact, there's only one property, the length, which is one that you've used many times in this book.

There are only three member methods in the nodeList, and you've encountered all of them in previous hours:

  • item(index)

  • nextNode()

  • reset()

Given your previous experience, there's no need to demonstrate them further.

Get Sams Teach Yourself XML in 24 Hours now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.