Rosetta 3.5
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
protocols
frag_picker
VallChunk.cc
Go to the documentation of this file.
1
// -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
2
// vi: set ts=2 noet:
3
//
4
// (c) Copyright Rosetta Commons Member Institutions.
5
// (c) This file is part of the Rosetta software suite and is made available under license.
6
// (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
7
// (c) For more information, see http://www.rosettacommons.org. Questions about this can be
8
// (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
9
10
/// @file protocols/frag_picker/VallChunk.cc
11
/// @brief a contiguous chunk of residues taken from a vall.
12
/// @author Dominik Gront (dgront@chem.uw.edu.pl)
13
14
15
// unit headers
16
#include <
protocols/frag_picker/VallChunk.hh
>
17
18
// package headers
19
#include <
protocols/frag_picker/VallResidue.hh
>
20
#include <
protocols/frag_picker/VallProvider.hh
>
21
22
// mini
23
#include <
core/sequence/SequenceProfile.hh
>
24
#include <
core/pose/Pose.hh
>
25
26
// C++ stuff
27
#include <string>
28
#include <sstream>
29
30
31
namespace
protocols {
32
namespace
frag_picker {
33
34
/// @details Auto-generated virtual destructor
35
VallChunk::~VallChunk
() {}
36
37
VallChunk::VallChunk
(
VallProviderAP
provider) {
38
sequence_
=
""
;
39
my_provider_
= provider;
40
has_key_
=
false
;
41
}
42
43
44
void
VallChunk::create_key
() {
45
46
std::stringstream out;
47
out <<
get_pdb_id
() <<
get_chain_id
() <<
':'
<<
at
(1)->resi();
48
chunk_key_
= out.str();
49
has_key_
=
true
;
50
}
51
52
std::string
&
VallChunk::get_sequence
() {
53
if
(
sequence_
.length() == 0) {
54
for
(
Size
i = 1; i <=
residues_
.size(); i++) {
55
char
next =
residues_
.at(i)->aa();
56
sequence_
+= next;
57
}
58
}
59
return
sequence_
;
60
}
61
62
core::sequence::SequenceProfileOP
VallChunk::get_profile
() {
63
64
return
my_provider_
->cache_profile(
this
);
65
}
66
67
core::pose::PoseOP
VallChunk::get_pose
() {
68
69
return
my_provider_
->cache_pose(
this
);
70
}
71
72
}
// frag_picker
73
}
// protocols
Generated on Sat Jun 1 2013 11:53:08 for Rosetta 3.5 by
1.8.4