Logo Search packages:      
Sourcecode: rarian version File versions

TiXmlHandle TiXmlHandle::Child ( int  index  )  const

Return a handle to the "index" child. The first child is 0, the second 1, etc.

Definition at line 1726 of file tinyxml.cpp.

References TiXmlNode::NextSibling(), and TiXmlHandle().

{
      if ( node )
      {
            int i;
            TiXmlNode* child = node->FirstChild();
            for ( i=0;
                        child && i<count;
                        child = child->NextSibling(), ++i )
            {
                  // nothing
            }
            if ( child )
                  return TiXmlHandle( child );
      }
      return TiXmlHandle( 0 );
}


Generated by  Doxygen 1.6.0   Back to index