Exemplo n.º 1
0
//_______________________________________________________________________________
bool xmlreader::endElement (const char* eltName)
{
	debug("endElement", eltName);
	Sxmlelement top = fStack.top();
	fStack.pop();
	return top->getName() == eltName;
}
Exemplo n.º 2
0
//_______________________________________________________________________________
static void test1(Sxmlelement elt)
{
	cerr << "test1: iterate thru the tree" << endl;
	ctree<xmlelement>::iterator iter = elt->begin();
	cerr << "=> test1: iterate thru the tree" << endl;

	while (iter != elt->end()) {
		Sxmlelement xml = *iter;
		if (xml)
			cerr << "  element type " << xml->getType() 
				 << " - " << xml->getName()
				 << " - size: " << xml->size() << endl;
		else
			cerr << "iterate thru unknown element type " << endl;
		iter++;
	}

}