public XMLElementList getChildrenByName ( String name ) { XMLElementList selected = new XMLElementList ( ) ; XMLElementList children = getChildren ( ) ; for ( int i = 0 ; i < children . size ( ) ; i ++ ) { if ( children . get ( i ) . getName ( ) . equals ( name ) ) { selected . add ( children . get ( i ) ) ; } } return selected ; }
Get a list of children with a given element name