1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
|
... AnalyserNoeud(wxXmlNode *p_noeud_,...)
{
if(!p_noeud_){
// parcours terminé.
return ;
}
// analyse en profondeur : on commence par les fils :
AnalyserNoeud(p_noeud_->GetChildren());
// le noeud courant :
p_noeud_->GetName(); // nom du noeud
p_noeud_->GetContent();// contenu du noeud
// analyse des attributs :
wxXmlProperty * attributs_noeud(p_noeud_->GetProperties());
while(attributs_noeud){
// nom de l'attribut
attributs_noeud->GetName();
// nom de la valeur
attributs_noeud->GetValue();
// au suivant !
attributs_noeud = attributs_noeud->GetNext();
}
// les frères :
AnalyserNoeud(p_noeud_->GetNext(),p_treectrl_,parent_id_);
} |