COPASI API  4.16.103
CFluxMode.h
Go to the documentation of this file.
1 /* Begin CVS Header
2  $Source: /Volumes/Home/Users/shoops/cvs/copasi_dev/copasi/elementaryFluxModes/CFluxMode.h,v $
3  $Revision: 1.15 $
4  $Name: $
5  $Author: shoops $
6  $Date: 2011/03/07 19:27:36 $
7  End CVS Header */
8 
9 // Copyright (C) 2011 - 2010 by Pedro Mendes, Virginia Tech Intellectual
10 // Properties, Inc., University of Heidelberg, and The University
11 // of Manchester.
12 // All rights reserved.
13 
14 // Copyright (C) 2008 by Pedro Mendes, Virginia Tech Intellectual
15 // Properties, Inc., EML Research, gGmbH, University of Heidelberg,
16 // and The University of Manchester.
17 // All rights reserved.
18 
19 // Copyright (C) 2001 - 2007 by Pedro Mendes, Virginia Tech Intellectual
20 // Properties, Inc. and EML Research, gGmbH.
21 // All rights reserved.
22 
23 /**
24  * CFluxMode class.
25  * Used to return the flux modes in human readable form
26  *
27  * Created for Copasi by Stefan Hoops 2002-05-10
28  * (C) Stefan Hoops 2002
29  */
30 
31 #ifndef COPASI_CFluxMode
32 #define COPASI_CFluxMode
33 
34 #include <map>
35 
36 class CReaction;
37 class CModel;
38 class CTableauLine;
39 
40 class CFluxMode
41 {
42 public:
43  typedef std::map< size_t, C_FLOAT64 >::const_iterator const_iterator;
44 
45  // Attributes
46 private:
47  /**
48  * Vector containing an index to a reaction and the multiplier
49  * for that reaction.
50  */
51  std::map< size_t, C_FLOAT64 > mReactions;
52 
53  /**
54  * Reversibility of the mode.
55  */
57 
58  // Operations
59 
60 public:
61  /**
62  * Default constructor
63  */
64  CFluxMode();
65 
66  /**
67  * Copy constructor
68  * @param "const CFluxMode &" src
69  */
70  CFluxMode(const CFluxMode & src);
71 
72  /**
73  * Specific constructor
74  * @param const std::map< size_t, C_FLOAT64 > & reactions
75  * @param const bool & reversible
76  */
77  CFluxMode(const std::map< size_t, C_FLOAT64 > & reactions,
78  const bool & reversible);
79 
80  /**
81  * Specific constructor
82  * @param "const CTableauLine &" line
83  */
84  CFluxMode(const CTableauLine * line);
85 
86  /**
87  * Destructor
88  */
89  ~CFluxMode();
90 
91  /**
92  * Retrieve the iterator to the first element of the flux mode
93  * @return CFluxMode::const_iterator begin;
94  */
95  const_iterator begin() const;
96 
97  /**
98  * Retrieve the iterator pointing beyond the last element of the flux mode
99  * @return CFluxMode::const_iterator end;
100  */
101  const_iterator end() const;
102 
103  /**
104  * Check whether the mode is reversible
105  * @return "bool" isReversible
106  */
107  bool isReversible() const;
108 
109  /**
110  * Retrieves the size of the mode
111  * @return "size_t" size
112  */
113  size_t size() const;
114 
115  /**
116  * Determine whether the current mode is the reversed mode
117  * @param const CFluxMode &mode
118  * @return bool isReversed
119  */
120  bool isReversed(const CFluxMode &mode);
121 
122  /**
123  * Retrieve the multiplier for the indexed reaction
124  * @param const size_t & index
125  * @return C_FLOAT64 multiplier
126  */
127  C_FLOAT64 getMultiplier(const size_t & index) const;
128 };
129 
130 #endif // COPASI_CFluxMode
bool mReversible
Definition: CFluxMode.h:56
size_t size() const
Definition: CFluxMode.cpp:84
C_FLOAT64 getMultiplier(const size_t &index) const
Definition: CFluxMode.cpp:111
bool isReversed(const CFluxMode &mode)
Definition: CFluxMode.cpp:89
const_iterator begin() const
Definition: CFluxMode.cpp:69
#define C_FLOAT64
Definition: copasi.h:92
std::map< size_t, C_FLOAT64 >::const_iterator const_iterator
Definition: CFluxMode.h:43
Definition: CModel.h:50
std::map< size_t, C_FLOAT64 > mReactions
Definition: CFluxMode.h:51
bool isReversible() const
Definition: CFluxMode.cpp:79
const_iterator end() const
Definition: CFluxMode.cpp:74