-
Notifications
You must be signed in to change notification settings - Fork 0
/
Residue.cpp
53 lines (43 loc) · 895 Bytes
/
Residue.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#include "Residue.h"
#include <QTextStream>
QVector<Atom*>& Residue::GetAtomVectorRef()
{
return m_AtomVector;
}
void Residue::setAtomVector(QVector<Atom*> atomVector)
{
m_AtomVector = atomVector;
}
int Residue::GetResidueID()
{
return m_ResidueID;
}
void Residue::SetResidueID(int residueID)
{
m_ResidueID = residueID;
}
QString Residue::GetResidueName()
{
return m_ResidueName;
}
void Residue::SetResidueName(QString residueName)
{
m_ResidueName = residueName;
}
Residue::Residue()
{
}
void Residue::AddAtom(Atom* atom)
{
GetAtomVectorRef().append(atom);
}
void Residue::PrintResidue()
{
QTextStream out(stdout);
out << GetResidueID() << " " << GetResidueName() << " " << endl;
QVector<Atom*> atomVector = GetAtomVectorRef();
for (int i = 0; i < atomVector.length(); ++i)
{
out << atomVector[i]->GetAtomName() << endl;
}
}