MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / toXMLString

Method toXMLString

src/openms/source/FORMAT/ControlledVocabulary.cpp:108–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106 }
107
108 String ControlledVocabulary::CVTerm::toXMLString(const OpenMS::String& ref, const String& value) const
109 {
110 String s = "<cvParam accession=\"" + id + "\" cvRef=\"" + ref + "\" name=\"" + Internal::XMLHandler::writeXMLEscape(name);
111 if (!value.empty())
112 {
113 s += "\" value=\"" + Internal::XMLHandler::writeXMLEscape(value);
114 }
115 s += "\"/>";
116 return s;
117 //~ TODO: handle unknown cvparams in ControlledVocabulary to get same formatting but more userdefined interface
118 }
119
120 String ControlledVocabulary::CVTerm::toXMLString(const OpenMS::String& ref, const OpenMS::DataValue& value) const
121 {

Callers

nothing calls this directly

Calls 6

hasUnitMethod · 0.80
prefixMethod · 0.80
writeXMLEscapeFunction · 0.70
emptyMethod · 0.45
isEmptyMethod · 0.45
beginMethod · 0.45

Tested by

no test coverage detected