2008-05-05 06:07:14 -05:00
|
|
|
#ifndef ATECHNOLOGY_H_
|
|
|
|
#define ATECHNOLOGY_H_
|
|
|
|
|
2008-05-06 11:23:45 -05:00
|
|
|
#include "Property.h"
|
|
|
|
using namespace Hurricane;
|
|
|
|
|
|
|
|
namespace Hurricane {
|
|
|
|
class Technology;
|
|
|
|
}
|
|
|
|
|
|
|
|
class ATechnology : public PrivateProperty {
|
2008-05-06 08:34:26 -05:00
|
|
|
public:
|
2008-05-06 11:23:45 -05:00
|
|
|
typedef PrivateProperty Inherit;
|
|
|
|
|
2008-05-06 08:34:26 -05:00
|
|
|
class PhysicalRule {
|
|
|
|
public:
|
2008-05-06 11:23:45 -05:00
|
|
|
PhysicalRule(const string& name,
|
2008-05-06 08:34:26 -05:00
|
|
|
double value,
|
2008-05-06 11:23:45 -05:00
|
|
|
const string& reference):
|
2008-05-06 08:34:26 -05:00
|
|
|
name_(name),
|
|
|
|
value_(value),
|
|
|
|
reference_(reference) {}
|
|
|
|
PhysicalRule(const PhysicalRule& physicalRule):
|
|
|
|
name_(physicalRule.name_),
|
|
|
|
value_(physicalRule.value_),
|
|
|
|
reference_(physicalRule.reference_) {}
|
|
|
|
const string name_;
|
|
|
|
const double value_;
|
|
|
|
const string reference_;
|
|
|
|
};
|
2008-05-06 11:23:45 -05:00
|
|
|
typedef map<string, ATechnology::PhysicalRule*> PhysicalRules;
|
|
|
|
static ATechnology* create(Hurricane::Technology* technology);
|
|
|
|
static ATechnology* getATechnology(Hurricane::Technology* technology);
|
|
|
|
const PhysicalRule* getPhysicalRule(string name);
|
|
|
|
void addPhysicalRule(const string& name, double value, const string& reference);
|
|
|
|
void print();
|
|
|
|
virtual Name getName() const;
|
|
|
|
virtual string _getTypeName() const;
|
|
|
|
|
|
|
|
ATechnology():
|
|
|
|
Inherit(),
|
|
|
|
physicalRules_() {}
|
|
|
|
|
|
|
|
private:
|
|
|
|
PhysicalRules physicalRules_;
|
2008-05-05 06:07:14 -05:00
|
|
|
};
|
|
|
|
|
2008-05-06 08:34:26 -05:00
|
|
|
#endif /* ATECHNOLOGY_H_*/
|