1 #ifndef HCALConfigDBTools_XMLTools_XMLProcessor_h 2 #define HCALConfigDBTools_XMLTools_XMLProcessor_h 25 #include <xercesc/dom/DOM.hpp> 26 #include <xercesc/util/XMLString.hpp> 28 #include <xercesc/dom/DOMNode.hpp> 29 #include <xercesc/framework/MemBufInputSource.hpp> 32 #if defined(XERCES_NEW_IOSTREAMS) 155 inline static XMLCh *
_toXMLCh(
int temp );
156 inline static XMLCh *
_toXMLCh(
double temp );
157 inline static XMLCh *
_toXMLCh( time_t temp );
185 XMLCh* buff = XERCES_CPP_NAMESPACE::XMLString::transcode(temp.c_str());
192 int status = snprintf( buf, 100,
"%d", temp );
195 std::cout <<
"XMLProcessor::_toXMLCh(int temp): buffer overflow, the std::string will be truncated!" << std::endl;
197 else if ( status <0 )
199 std::cout <<
"XMLProcessor::_toXMLCh(int temp): output error" << std::endl;
201 XMLCh* buff = XERCES_CPP_NAMESPACE::XMLString::transcode( buf );
208 int status = snprintf( buf, 100,
"%.10e", temp );
211 std::cout <<
"XMLProcessor::_toXMLCh(int temp): buffer overflow, the std::string will be truncated!" << std::endl;
213 else if ( status <0 )
215 std::cout <<
"XMLProcessor::_toXMLCh(int temp): output error" << std::endl;
217 XMLCh* buff = XERCES_CPP_NAMESPACE::XMLString::transcode( buf );
224 int status = strftime( buf, 50,
"%c", gmtime( &temp ) );
227 std::cout <<
"XML Processor::_toXMLCh(int temp): buffer overflow, the std::string is indeterminate!" << std::endl;
229 XMLCh* buff = XERCES_CPP_NAMESPACE::XMLString::transcode( buf );
std::string detector_name
XMLCh * serializeDOM(XERCES_CPP_NAMESPACE::DOMNode *node, std::string target="stdout")
XMLDOMBlock * createLMapHBEFXMLBase(std::string templateFileName)
struct XMLProcessor::_loaderBaseConfig loaderBaseConfig
XMLProcessor::_checksumsDBConfig checksumsDBConfig
std::string comment_description
int addLMapHBEFDataset(XMLDOMBlock *doc, LMapRowHBEF *row, std::string templateFileName)
struct XMLProcessor::_LMapRowHO LMapRowHO
std::string extention_table_name
int addLMapHODataset(XMLDOMBlock *doc, LMapRowHO *row, std::string templateFileName)
struct XMLProcessor::_DBConfig DBConfig
struct XMLProcessor::_LMapRowHBEF LMapRowHBEF
XMLDOMBlock * createLMapHOXMLBase(std::string templateFileName)
static XMLCh * _toXMLCh(std::string temp)
XMLProcessor::_lutDBConfig lutDBConfig
int write(XMLDOMBlock *doc, std::string target="stdout")
static XMLProcessor * instance
static XMLProcessor * getInstance()
std::string created_by_user