Helper class for XML parsing that handles the memory management for conversions of Xerces strings. More...
#include <OpenMS/FORMAT/HANDLERS/XMLHandler.h>
Public Member Functions | |
| StringManager () | |
| Constructor. | |
| ~StringManager () | |
| Destructor. Destroys the strings in the various lists. | |
| void | clear () |
| Frees memory of all owned strings. | |
| XMLCh * | convert (const char *str) const |
| Transcode the supplied C string to XMLCh* and take ownership of the XMLCh*. | |
| XMLCh * | convert (const std::string &str) const |
| Transcode the supplied C++ string to XMLCh* and take ownership of the XMLCh*. | |
| XMLCh * | convert (const String &str) const |
| Transcode the supplied OpenMS string to XMLCh* and take ownership of the XMLCh*. | |
| char * | convert (const XMLCh *str) const |
| Transcode the supplied XMLCh* to a C string and take ownership of the C string. | |
Private Attributes | |
| std::vector< XMLCh * > | xml_strings_ |
| std::vector< char * > | c_strings_ |
Helper class for XML parsing that handles the memory management for conversions of Xerces strings.
| StringManager | ( | ) |
Constructor.
| ~StringManager | ( | ) |
Destructor. Destroys the strings in the various lists.
| void clear | ( | ) |
Frees memory of all owned strings.
Referenced by MzXMLHandler< MapType >::endElement(), MzMLHandler< MapType >::endElement(), and MzDataHandler< MapType >::endElement().
| char* convert | ( | const XMLCh * | str | ) | const |
Transcode the supplied XMLCh* to a C string and take ownership of the C string.
| XMLCh* convert | ( | const String & | str | ) | const |
Transcode the supplied OpenMS string to XMLCh* and take ownership of the XMLCh*.
| XMLCh* convert | ( | const std::string & | str | ) | const |
Transcode the supplied C++ string to XMLCh* and take ownership of the XMLCh*.
| XMLCh* convert | ( | const char * | str | ) | const |
Transcode the supplied C string to XMLCh* and take ownership of the XMLCh*.
Referenced by MzXMLHandler< MapType >::characters(), MzMLHandler< MapType >::characters(), MzDataHandler< MapType >::characters(), MzXMLHandler< MapType >::startElement(), MzMLHandler< MapType >::startElement(), and MzDataHandler< MapType >::startElement().
std::vector<char *> c_strings_ [mutable, private] |
std::vector<XMLCh *> xml_strings_ [mutable, private] |
| OpenMS / TOPP release 1.10.0 | Documentation generated on Thu Mar 7 2013 09:43:00 using doxygen 1.7.1 |