Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
MotifHit.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 MotifHit.cc
11 /// @brief Class that holds information about a motif in the context of the search
12 /// @author sthyme (sthyme@gmail.com)
13 
14 // Unit Headers
16 
17 // Package Headers
19 
20 // Project Headers
22 #include <core/pose/Pose.hh>
23 #include <core/io/pdb/pose_io.hh>
24 #include <utility/vector1.hh>
25 
26 #include <sstream>
27 
28 // Utility Headers
29 
30 // C++ Headers
31 
32 namespace protocols {
33 namespace motifs{
34 
36  Motif const & motif,
37  Size const & vbpos,
38  bool const passed_automorphism
39 ) : motifcop_( motif.clone() ),
40  vbpos_( vbpos ),
41  passed_automorphism_( passed_automorphism ),
42  build_rotamer_(0),
43  target_conformer_(0)
44 {}
45 
47 {}
48 
49 MotifHit::MotifHit( MotifHit const & src ) :
50  utility::pointer::ReferenceCount( src ),
51  motifcop_( src.motifcop()->clone() ),
52  vbpos_( src.vbpos_ ),
53  passed_automorphism_( src.passed_automorphism_ ),
54  final_test_( src.final_test_ ),
55  build_rotamer_( src.build_rotamer()->clone() ),
56  target_conformer_( src.target_conformer()->clone() )
57 {}
58 
61 {
62  return new MotifHit(*this);
63 }
64 
65 void
67  core::Real const & final_test
68 )
69 {
71 }
72 
73 void
75  core::conformation::Residue const & build_rotamer
76 )
77 {
78  build_rotamer_ = build_rotamer.clone();
79 }
80 
81 void
83  core::conformation::Residue const & target_conformer
84 )
85 {
86  target_conformer_ = target_conformer.clone();
87 }
88 
89 void
91 {
92  core::pose::Pose pose_mh;
95  std::stringstream pose_mh_name_full;
96  pose_mh_name_full << "MH_" << final_test_ << "_" << motifcop_->restype_name2()[0] << "_" << vbpos_ << "_" << motifcop_->restype_name1() << "_" << motifcop_->remark() << ".pdb";
97  core::io::pdb::dump_pdb( pose_mh, pose_mh_name_full.str() );
98 }
99 } // namespace motifs
100 } // namespace protocols