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
core
fragment
ConstantLengthFragSet.hh
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
// :noTabs=false:tabSize=4:indentSize=4:
4
//
5
// (c) Copyright Rosetta Commons Member Institutions.
6
// (c) This file is part of the Rosetta software suite and is made available under license.
7
// (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
8
// (c) For more information, see http://www.rosettacommons.org. Questions about this can be
9
// (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
10
11
/// @file core/fragments/ConstantLengthFragSet.hh
12
/// @brief yields a simple implementation of a fragset
13
/// @author Oliver Lange ( olange@u.washington.edu)
14
/// @date Wed Aug 22 12:08:31 2007
15
///
16
17
#ifndef INCLUDED_core_fragment_ConstantLengthFragSet_HH
18
#define INCLUDED_core_fragment_ConstantLengthFragSet_HH
19
20
// Unit Headers
21
#include <
core/fragment/ConstantLengthFragSet.fwd.hh
>
22
23
// Package Headers
24
#include <
core/fragment/FragSet.hh
>
25
#include <
core/fragment/Frame.hh
>
26
#include <
core/fragment/FrameList.hh
>
27
28
// Project Headers
29
// AUTO-REMOVED #include <utility/io/izstream.hh>
30
#include <
core/kinematics/MoveMap.fwd.hh
>
31
#include <
core/types.hh
>
32
33
// ObjexxFCL Headers
34
35
// Utility headers
36
// AUTO-REMOVED #include <utility/vector1.hh>
37
#include <utility/pointer/ReferenceCount.hh>
38
39
#include <utility/vector1.hh>
40
#include <utility/io/izstream.fwd.hh>
41
42
43
// Package Headers
44
45
// std Headers
46
47
/* Just a mad thought: with fragments becoming ever more "Residue" like one might want to use the
48
packer to choose a combination of good fragments instead of makeing independent choices.
49
I guess, it is only a question of keeping the combinatorics in control...
50
maybe it makes sense to pack with only "unconfident" regions of the backbone flexible ..
51
*/
52
53
namespace
core {
54
namespace
fragment {
55
56
/* classic 9mer Frags would be in one of those */
57
/// @brief A set of fragments that contains fragments of a constant length read
58
/// in from a fragment file.
59
/// @note this object is a simple implementation of the FragSet
60
/// @note for custom fragments, check out https://robetta.bakerlab.org/fragmentsubmit.jsp
61
///
62
/// example:
63
/// ninemers = ConstantLengthFragSet(9)
64
/// ninemers.read_fragment_file("test9_fragments")
65
/// See also:
66
/// Pose
67
/// ClassicFragmentMover
68
class
ConstantLengthFragSet
:
public
FragSet
{
69
typedef
FragSet
Parent
;
70
// ConstantLengthFragSet is a FragSet with only one frame per position!
71
public
:
72
73
ConstantLengthFragSet
(
Size
frag_length ) {
74
set_max_frag_length
( frag_length );
75
};
76
77
ConstantLengthFragSet
(
Size
frag_length,
std::string
filename
);
78
79
ConstantLengthFragSet
() {};
80
81
~ConstantLengthFragSet
();
82
83
ConstantLengthFragSet
(
FragSet
const
& fragments );
84
85
virtual
FragSetOP
clone
()
const
86
{
87
return
new
ConstantLengthFragSet
( *
this
);
88
}
89
90
virtual
FragSetOP
empty_clone
()
const
91
{
92
return
new
ConstantLengthFragSet
();
93
}
94
95
/// @brief Loads the contents of <filename> into the ConstantLengthFragSet
96
///
97
/// example:
98
/// ninemers.read_fragment_file("test9_fragments")
99
/// See also:
100
/// ConstantLengthFragSet
101
/// Pose
102
/// Pose.omega
103
/// Pose.phi
104
/// Pose.psi
105
/// ClassicFragmentMover
106
void
read_fragment_file
(
std::string
filename
,
Size
top25 = 0,
Size
ncopies = 1,
bool
bAnnotation =
false
);
107
108
void
read_fragment_stream
( utility::io::izstream & data,
Size
top25 = 0,
Size
ncopies = 1,
bool
bAnnotation =
false
);
109
110
// void print_fragments();
111
///@brief there is only one Frame per position, end / max_overlap are ignored
112
Size
region
(
113
kinematics::MoveMap
const
& mm,
114
core::Size
start
,
115
core::Size
end
,
116
core::Size
,
//min_overlap not used
117
core::Size
,
//min_length not used
118
FrameList
&
frames
119
)
const
;
120
121
// /// @brief Accessor for the Frames at the specified insertion position. Returns 0=false if
122
// /// there is no frame at the specified position.
123
// virtual Size frames(
124
// Size pos,
125
// FrameList & frame
126
// );
127
128
FrameIterator
begin
()
const
;
129
130
FrameIterator
end
()
const
;
131
132
virtual
bool
empty
()
const
{
133
return
frames_
.size()==0;
134
}
135
protected
:
136
virtual
void
add_
(
FrameOP
aframe );
137
138
private
:
139
FrameList
frames_
;
140
};
141
142
}
143
}
144
145
#endif
Generated on Sat Jun 1 2013 11:32:33 for Rosetta 3.5 by
1.8.4