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

Method toUnimodLikeString

src/openms/source/FORMAT/PepXMLFile.cpp:27–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

25{
26
27 String PepXMLFile::AminoAcidModification::toUnimodLikeString() const
28 {
29 String desc = "";
30 if (massdiff_ >= 0)
31 {
32 desc += "+" + String(massdiff_);
33 }
34 else
35 {
36 desc += String(massdiff_);
37 }
38
39 if (!aminoacid_.empty() || !terminus_.empty())
40 {
41 desc += " (";
42 if (!terminus_.empty())
43 {
44 if (is_protein_terminus_)
45 {
46 desc += "Protein ";
47 }
48 {
49 String t = terminus_;
50 desc += t.toUpper() + "-term";
51 }
52 if (!aminoacid_.empty())
53 {
54 desc += " ";
55 }
56 }
57 if (!aminoacid_.empty())
58 {
59 String a = aminoacid_;
60 desc += a.toUpper();
61 }
62 desc += ")";
63 }
64 return desc;
65 }
66
67 const String& PepXMLFile::AminoAcidModification::getDescription() const
68 {

Callers

nothing calls this directly

Calls 3

toUpperMethod · 0.80
StringClass · 0.50
emptyMethod · 0.45

Tested by

no test coverage detected