Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Atom.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 /// @begin Atom
11 ///
12 /// @brief
13 /// A class for defining chemical atoms, with properties specific to a ResidueType, not conformation info
14 /// specific to a Residue. Conformation info goes in conformation::Atom. AtomTypes are not ResidueType specific.
15 ///
16 ///
17 ///
18 ///
19 /// @author
20 /// Gordon Lemmon
21 ///
22 /////////////////////////////////////////////////////////////////////////
23 
24 
25 #ifndef INCLUDED_core_chemical_Atom_hh
26 #define INCLUDED_core_chemical_Atom_hh
27 
28 
29 // Unit headers
32 #include <core/types.hh>
33 #include <numeric/xyzVector.hh>
34 
35 // Package headers
36 #include <core/chemical/types.hh>
37 
38 // Utility headers
39 #include <utility/vector1_bool.hh>
40 
41 // C++ headers
42 #include <string>
43 
44 namespace core {
45 namespace chemical {
46 
47 /// @brief basic chemical atom
48 ///
49 /// @details name, element, certain properties and parameters from .params file
50 ///
51 class Atom {
52 
53 public:
54 
55  /// @brief Construct a new atom type with its name and element.
56  ///
57  /// @details All its properties are unset by default.
58  ///
59  Atom():
60  name_(""),
61  mm_name_(""),
64  charge_(0),
65  ideal_xyz_(),
66  icoor_()
67  {}
68 
70  std::string const & name_in,
71  // std::string const type_name,
72  std::string const mm_name,
73  Size const atom_type_index,
75  Real const charge,
76  Vector const ideal_xyz,
77  AtomICoor const icoor
78 
79  ):
80  name_( name_in ),
81  //type_name_(type_name),
82  mm_name_(mm_name),
83  atom_type_index_(atom_type_index),
84  mm_atom_type_index_(mm_atom_type_index),
85  charge_(charge),
86  ideal_xyz_(ideal_xyz),
87  icoor_(icoor)
88  {}
89 
90  Atom(Atom const & src) :
91  name_( src.name_ ),
92  //type_name_(src.type_name),
93  mm_name_(src.mm_name_),
96  charge_(src.charge_),
98  icoor_(src.icoor_)
99  {}
100 
101  void
102  print( std::ostream & out ) const;
103 
104  friend
105  std::ostream &
106  operator<< ( std::ostream & out, const Atom & atom_type );
107 
108 // Const Getters
109  std::string const& name() const { return name_; };
110  //std::string const& type_name() const { return type_name_; };
111  std::string const& mm_name() const { return mm_name_; };
112  Size const& atom_type_index() const { return atom_type_index_; };
113  Size const& mm_atom_type_index() const { return mm_atom_type_index_; };
114  Real const& charge() const { return charge_; };
115  Vector const& ideal_xyz() const { return ideal_xyz_; };
116  AtomICoor const& icoor() const { return icoor_; };
117 // Non-const getters
118  AtomICoor & icoor() { return icoor_; };
119 // Setters
120  void name( std::string const & name ) { name_ = name; };
121  //std::string const& type_name() const { return type_name_; };
122  void mm_name( std::string const & name ) { mm_name_ = name; };
125  void charge( Real const & charge ) { charge_ = charge; };
127  void icoor( AtomICoor const & icoor) { icoor_ = icoor; };
128 
129  // data
130 private:
131 
132  // Primary data
134  //std::string const type_name_;
135 
136  // Secondary data
138  // std::string const csd_atom_name_;
139 
141  /// MM atom-type index
146 };
147 
148 
149 } // chemical
150 } // core
151 
152 
153 
154 #endif // INCLUDED_core_chemical_Atom_HH