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
loops
Loops.tmpl.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
//
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/loops/Loops.tmpl.hh
11
/// @brief
12
/// @author Brian D. Weitzner
13
14
#ifndef INCLUDED_protocols_loops_Loops_TMPL_HH
15
#define INCLUDED_protocols_loops_Loops_TMPL_HH
16
17
// Unit header
18
#include <
protocols/loops/Loops.hh
>
19
20
// Package headers
21
#include <
protocols/loops/Loop.hh
>
22
23
// Utility headers
24
#include <utility/vector1.hh>
25
26
namespace
protocols {
27
namespace
loops {
28
29
///@brief set each loop-residue in the vector to val.
30
/// input vector of nres length ( if shorter last residues of loop are ignored )
31
template
<
class
T >
32
void
Loops::transfer_to_residue_vector
(
utility::vector1< T >
& vector,
T
val )
const
{
33
core::Size
nres = vector.size();
34
for
(
const_iterator
it =
begin
(); it !=
end
(); ++it ) {
35
if
( it->start() <= nres ) {
36
for
(
core::Size
pos = it->start(); pos <= std::min( it->stop(), nres ); pos++ ) {
37
vector[ pos ] = val;
38
}
39
}
40
}
41
}
42
43
}
//namespace loops
44
}
//namespace protocols
45
46
#endif //INCLUDED_protocols_loops_Loops_TMPL_HH
Generated on Sat Jun 1 2013 11:59:06 for Rosetta 3.5 by
1.8.4