#include <SAX2DefaultHandler.h>
Public Member Functions | |
| ~SAX2DefaultHandler () | |
| void | startElement (const XMLCh *const uri, const XMLCh *const localname, const XMLCh *const qname, const Attributes &attributes) |
| void | endElement (const XMLCh *const uri, const XMLCh *const localname, const XMLCh *const qname) |
| void | characters (const XMLCh *const chars, const unsigned int length) |
Private Attributes | |
| std::stack< SAX2Handler * > | fHandler |
Definition at line 17 of file SAX2DefaultHandler.h.
|
|
Definition at line 11 of file SAX2DefaultHandler.cxx. References fHandler.
00012 {
00013
00014 xmli::SAX2Handler* handler = 0;
00015
00016 if (fHandler.empty()==false) {
00017 for (handler = fHandler.top(); handler!=0; fHandler.pop()) {
00018 std::cerr << "xmli::SAX2DefaultHandler::" << __LINE__
00019 << " Unterminated tag." << std::endl;
00020 delete handler;
00021 }
00022 }
00023 }
|
|
||||||||||||
|
Definition at line 71 of file SAX2DefaultHandler.cxx. References xmli::SAX2Handler::Characters(), and fHandler.
00073 {
00074 xmli::ChString chs(chars);
00075 xmli::SAX2Handler* handler = fHandler.top();
00076 if (handler) handler->Characters(chs);
00077 }
|
|
||||||||||||||||
|
Definition at line 53 of file SAX2DefaultHandler.cxx. References xmli::SAX2Handler::EndElement(), and fHandler.
00056 {
00057 xmli::ChString uris(uri);
00058 xmli::ChString localnames(localname);
00059 xmli::ChString qnames(qname);
00060
00061 xmli::SAX2Handler* handler = fHandler.top();
00062 if (handler) {
00063 handler->EndElement(uris,localnames,qnames);
00064 delete handler;
00065 }
00066 fHandler.pop();
00067 }
|
|
||||||||||||||||||||
|
Definition at line 27 of file SAX2DefaultHandler.cxx. References xmli::AttributeList, fHandler, and xmli::SAX2Handler::StartElement().
00031 {
00032 xmli::ChString uris(uri);
00033 xmli::ChString localnames(localname);
00034 xmli::ChString qnames(qname);
00035
00036 xmli::AttributeList attr;
00037 for (unsigned int i=0; i<attributes.getLength(); ++i) {
00038 xmli::ChString names = attributes.getLocalName(i);
00039 xmli::ChString values = attributes.getValue(i);
00040 xmli::Attribute a(names,values);
00041 attr.push_back(a);
00042 }
00043
00044 xmli::SAX2Handler* handler = new xmli::SAX2Handler();
00045 if (handler) {
00046 handler->StartElement(uris,localnames,qnames,attr);
00047 }
00048 fHandler.push(handler);
00049 }
|
|
|
Definition at line 33 of file SAX2DefaultHandler.h. Referenced by characters(), endElement(), startElement(), and ~SAX2DefaultHandler(). |
1.3.5