Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GridBase.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 src/protocols/qsar/scoring_grid/GridBase.hh
11 /// @author Sam DeLuca
12 
13 #ifndef INCLUDED_protocols_qsar_scoring_grid_GridBase_HH
14 #define INCLUDED_protocols_qsar_scoring_grid_GridBase_HH
15 
18 #include <core/types.hh>
19 #include <core/pose/Pose.fwd.hh>
21 #include <utility/json_spirit/json_spirit_value.h>
22 #include <utility/pointer/ReferenceCount.hh>
23 #include <utility/tag/Tag.fwd.hh>
24 
25 namespace protocols {
26 namespace qsar {
27 namespace scoring_grid {
28 
30 {
31 public:
32  GridBase() {}
33  virtual ~GridBase() {}
34  /// @brief initialize a grid of zeros with a given centerpoint, width and resolution (in angstroms).
35  virtual void initialize(core::Vector const & center, core::Real width, core::Real resolution)=0;
36  /// @brief populate the grid with values based on a passed pose
37  virtual void refresh(core::pose::Pose const & pose, core::Vector const & center, core::Size const & ligand_chain_id_to_exclude)=0;
38  /// @brief populate the grid with values based on a passed pose
39  virtual void refresh(core::pose::Pose const & pose, core::Vector const & center,utility::vector1<core::Size> ligand_chain_ids_to_exclude)=0;
40  /// @brief populate the grid with values based on a passed pose
41  virtual void refresh(core::pose::Pose const & pose, core::Vector const & center)=0;
42  /// @setup a grid based on RosettaScripts input
43  virtual void parse_my_tag(utility::tag::TagPtr const tag)=0;
44  /// @brief return the current score of a residue using the current grid
45  virtual core::Real score(core::conformation::Residue const & residue, core::Real const max_score, qsarMapOP qsar_map) = 0;
46  /// @brief return the current score of an atom using the current grid
47  virtual core::Real atom_score(core::conformation::Residue const & residue, core::Size atomno, qsarMapOP qsar_map) = 0;
48  /// @brief get the type of the grid
49  virtual std::string get_type() = 0;
50  /// @brief set the chain the grid applies to
51  virtual void set_chain(char chain) = 0;
52  /// @brief output a BRIX formatted grid. This really does not work well but is being left for legacy purposes
53  virtual void dump_BRIX(std::string const & prefix) = 0;
54  /// @brief Serialize the GridBase object into a json_spirit Value
55  virtual utility::json_spirit::Value serialize() = 0;
56  /// @brief deserialize a json spirit Value into a GridBase object
57  virtual void deserialize(utility::json_spirit::mObject data) = 0;
58  /// @brief determine if all residue atoms are in a grid
59  virtual bool is_in_grid(core::conformation::Residue const & residue) =0;
60 };
61 
62 }
63 }
64 }
65 
66 #endif /* GRIDBASE_HH_ */