method

size

v1_8_7_72 - Show latest stable - Class: REXML::Elements
size()
public

Returns the number of Element children of the parent object.

 doc = Document.new '<a>sean<b/>elliott<b/>russell<b/></a>'
 doc.root.size            #-> 6, 3 element and 3 text nodes
 doc.root.elements.size   #-> 3