Serializes a Param class in paramCTD file format. Note: only storing is currently possible.
More...
#include <OpenMS/FORMAT/ParamCTDFile.h>
|
static std::string | escapeXML (const std::string &to_escape) |
| Escapes certain characters in a string that are not allowed in XML Escaped characters are: & < > " '. More...
|
|
static void | replace (std::string &replace_in, char to_replace, const std::string &replace_with) |
| Replace all occurrences of a character in a string with a string. More...
|
|
Serializes a Param class in paramCTD file format. Note: only storing is currently possible.
◆ ParamCTDFile()
◆ ~ParamCTDFile()
◆ escapeXML()
static std::string escapeXML |
( |
const std::string & |
to_escape | ) |
|
|
staticprivate |
Escapes certain characters in a string that are not allowed in XML Escaped characters are: & < > " '.
- Parameters
-
to_escape | The string in which the characters should be escaped |
- Returns
- The escaped string
◆ replace()
static void replace |
( |
std::string & |
replace_in, |
|
|
char |
to_replace, |
|
|
const std::string & |
replace_with |
|
) |
| |
|
staticprivate |
Replace all occurrences of a character in a string with a string.
- Parameters
-
replace_in | The string in which the characters should be replaced. |
to_replace | The character that should be replaced. |
replace_with | The string the character should be replaced with. |
◆ store()
void store |
( |
const std::string & |
filename, |
|
|
const Param & |
param, |
|
|
const ToolInfo & |
tool_info |
|
) |
| const |
Destructor.
Write CTD file
- Parameters
-
filename | The name of the file the param data structure should be stored in. |
param | The param data structure that should be stored. |
tool_info | Additional information about the Tool for which the param data should be stored. |
- Exceptions
-
std::ios::failure | is thrown if the file could not be created |
◆ writeCTDToStream()
void writeCTDToStream |
( |
std::ostream * |
os_ptr, |
|
|
const Param & |
param, |
|
|
const ToolInfo & |
tool_info |
|
) |
| const |
Write CTD to output stream.
- Parameters
-
os_ptr | The stream to which the param data should be written. |
param | The param data structure that should be writte to stream. |
tool_info | Additional information about the Tool for which the param data should be written. |
◆ schema_location_
const std::string schema_location_ = "/SCHEMAS/Param_1_7_0.xsd" |
|
private |
◆ schema_version_
const std::string schema_version_ = "1.7.0" |
|
private |