Victor
 All Data Structures Functions Variables Friends Pages
SeqConstructor.h
1 /* This file is part of Victor.
2 
3  Victor is free software: you can redistribute it and/or modify
4  it under the terms of the GNU General Public License as published by
5  the Free Software Foundation, either version 3 of the License, or
6  (at your option) any later version.
7 
8  Victor is distributed in the hope that it will be useful,
9  but WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  GNU General Public License for more details.
12 
13  You should have received a copy of the GNU General Public License
14  along with Victor. If not, see <http://www.gnu.org/licenses/>.
15  */
16 
17 #ifndef _SIDECHAIN_CONSTRUCTOR_H_
18 #define _SIDECHAIN_CONSTRUCTOR_H_
19 
20 // Includes:
21 #include <Spacer.h>
22 #include <AminoAcid.h>
23 #include <Debug.h>
24 #include <string>
25 #include <vector>
26 
27 // Global constants, typedefs, etc. (to avoid):
28 
29 namespace Victor { namespace Biopool {
30 
36  public:
37 
38  // CONSTRUCTORS/DESTRUCTOR:
39 
40  SeqConstructor(istream& _refInput = cin) :
41  refInput(_refInput), loaded(false), refAmino() {
42  }
43 
44  virtual ~SeqConstructor() {
45  PRINT_NAME;
46  }
47 
48  // MODIFIERS:
49  virtual Spacer& makeSpacer(string type, unsigned int n);
50  // make spacer by concatenating code n-times
51 
52  protected:
53  // HELPERS:
54  virtual void loadReference();
55  void searchReference(AminoAcid& aa, string type);
56  void buildAminoAcid(AminoAcid& aa, AminoAcid* prev);
57 
58  private:
59  istream& refInput; // reference stream
60  bool loaded; // is reference loaded yet?
61  vector<AminoAcid> refAmino; // reference types
62  };
63 
64 }} //namespace
65 #endif //_SEQ_CONSTRUCTOR_H_
virtual void loadReference()
Definition: SeqConstructor.cc:36
void buildAminoAcid(AminoAcid &aa, AminoAcid *prev)
Definition: SeqConstructor.cc:78
This class builds a spacer by concatenating the same aminoacid type for n times.
Definition: SeqConstructor.h:35
It mplements a simple amino acid.
Definition: AminoAcid.h:43
Implements a "Spacer" for a protein chain. Includes methods to obtain values from the atoms and its p...
Definition: Spacer.h:42
virtual Spacer & makeSpacer(string type, unsigned int n)
Definition: SeqConstructor.cc:55