OpenASIP  2.0
CostEstimationData.hh
Go to the documentation of this file.
1 /*
2  Copyright (c) 2002-2009 Tampere University.
3 
4  This file is part of TTA-Based Codesign Environment (TCE).
5 
6  Permission is hereby granted, free of charge, to any person obtaining a
7  copy of this software and associated documentation files (the "Software"),
8  to deal in the Software without restriction, including without limitation
9  the rights to use, copy, modify, merge, publish, distribute, sublicense,
10  and/or sell copies of the Software, and to permit persons to whom the
11  Software is furnished to do so, subject to the following conditions:
12 
13  The above copyright notice and this permission notice shall be included in
14  all copies or substantial portions of the Software.
15 
16  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19  THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21  FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22  DEALINGS IN THE SOFTWARE.
23  */
24 /**
25  * @file CostEstimationData.hh
26  *
27  * Declaration of CostEstimationData class.
28  *
29  * @author Veli-Pekka Jääskeläinen 2006 (vjaaskel-no.spam-cs.tut.fi)
30  * @note rating: red
31  */
32 
33 #ifndef TTA_COST_ESTIMATION_DATA_HH
34 #define TTA_COST_ESTIMATION_DATA_HH
35 
36 #include "DBTypes.hh"
37 #include "DataObject.hh"
38 
39 /**
40  * Class that represents one row in the cost estimation data table.
41  */
43 public:
45  virtual ~CostEstimationData();
46 
47  void setName(const std::string& name);
48  bool hasName() const;
49  std::string name() const;
50 
51  void setValue(const DataObject& value);
52  bool hasValue() const;
53  DataObject value() const;
54 
55  void setFUReference(RowID fuEntryID);
56  bool hasFUReference() const;
57  RowID fuReference() const;
58 
59  void setRFReference(RowID rfEntryID);
60  bool hasRFReference() const;
61  RowID rfReference() const;
62 
63  void setBusReference(RowID busEntryID);
64  bool hasBusReference() const;
65  RowID busReference() const;
66 
67  void setSocketReference(RowID socketEntryID);
68  bool hasSocketReference() const;
69  RowID socketReference() const;
70 
72  bool hasPluginID() const;
73  RowID pluginID() const;
74 
75 private:
76  /// Is the data name set?
77  bool hasName_;
78  /// Name of the data.
79  std::string name_;
80 
81  /// Is the value set?
82  bool hasValue_;
83  /// Value data.
85 
86  /// Is the fu reference set?
88  /// FU reference.
90 
91  /// Is the RF reference set?
93  /// RF reference.
95 
96  /// Is the bus reference set?
98  /// Bus reference.
100 
101  /// Is the socket reference set?
103  /// Socket reference.
105 
106  /// Is the plugin ID set?
108  /// Plugin ID.
110 };
111 
112 #include "CostEstimationData.icc"
113 
114 #endif
CostEstimationData::rfReference
RowID rfReference() const
Definition: CostEstimationData.cc:118
CostEstimationData::hasValue_
bool hasValue_
Is the value set?
Definition: CostEstimationData.hh:82
CostEstimationData::setName
void setName(const std::string &name)
CostEstimationData::CostEstimationData
CostEstimationData()
Definition: CostEstimationData.cc:38
CostEstimationData::name
std::string name() const
Definition: CostEstimationData.cc:58
CostEstimationData::hasName_
bool hasName_
Is the data name set?
Definition: CostEstimationData.hh:77
DataObject
Definition: DataObject.hh:50
CostEstimationData::pluginID
RowID pluginID() const
Definition: CostEstimationData.cc:88
CostEstimationData::hasSocketReference
bool hasSocketReference() const
CostEstimationData::socketReference_
RowID socketReference_
Socket reference.
Definition: CostEstimationData.hh:104
RowID
int RowID
Type definition of row ID in relational databases.
Definition: DBTypes.hh:37
CostEstimationData::hasFUReference_
bool hasFUReference_
Is the fu reference set?
Definition: CostEstimationData.hh:87
CostEstimationData::setFUReference
void setFUReference(RowID fuEntryID)
CostEstimationData::setRFReference
void setRFReference(RowID rfEntryID)
CostEstimationData::hasFUReference
bool hasFUReference() const
CostEstimationData::hasValue
bool hasValue() const
CostEstimationData::setValue
void setValue(const DataObject &value)
CostEstimationData::rfReference_
RowID rfReference_
RF reference.
Definition: CostEstimationData.hh:94
CostEstimationData::busReference_
RowID busReference_
Bus reference.
Definition: CostEstimationData.hh:99
CostEstimationData::hasRFReference_
bool hasRFReference_
Is the RF reference set?
Definition: CostEstimationData.hh:92
CostEstimationData::~CostEstimationData
virtual ~CostEstimationData()
Definition: CostEstimationData.cc:49
CostEstimationData::name_
std::string name_
Name of the data.
Definition: CostEstimationData.hh:79
DBTypes.hh
CostEstimationData::hasName
bool hasName() const
CostEstimationData::hasBusReference_
bool hasBusReference_
Is the bus reference set?
Definition: CostEstimationData.hh:97
CostEstimationData::busReference
RowID busReference() const
Definition: CostEstimationData.cc:133
CostEstimationData::setBusReference
void setBusReference(RowID busEntryID)
CostEstimationData::value_
DataObject value_
Value data.
Definition: CostEstimationData.hh:84
CostEstimationData::socketReference
RowID socketReference() const
Definition: CostEstimationData.cc:148
DataObject.hh
CostEstimationData
Definition: CostEstimationData.hh:42
CostEstimationData::value
DataObject value() const
Definition: CostEstimationData.cc:73
CostEstimationData::hasPluginID
bool hasPluginID() const
CostEstimationData::hasSocketReference_
bool hasSocketReference_
Is the socket reference set?
Definition: CostEstimationData.hh:102
CostEstimationData::hasBusReference
bool hasBusReference() const
CostEstimationData::hasPluginID_
bool hasPluginID_
Is the plugin ID set?
Definition: CostEstimationData.hh:107
CostEstimationData::fuReference
RowID fuReference() const
Definition: CostEstimationData.cc:103
CostEstimationData::setPluginID
void setPluginID(RowID pluginID)
CostEstimationData::hasRFReference
bool hasRFReference() const
CostEstimationData::pluginID_
RowID pluginID_
Plugin ID.
Definition: CostEstimationData.hh:109
CostEstimationData::setSocketReference
void setSocketReference(RowID socketEntryID)
CostEstimationData::fuReference_
RowID fuReference_
FU reference.
Definition: CostEstimationData.hh:89
CostEstimationData.icc