1.给Singleton的模板加了点功能。
2.添加了处理DG的功能。 Signed-off-by: dmy@lab <dmy@lab.lab>
This commit is contained in:
44
testHasttable/dginfo.cpp
Normal file
44
testHasttable/dginfo.cpp
Normal file
@@ -0,0 +1,44 @@
|
||||
#include "dginfo.h"
|
||||
|
||||
DGInfo::DGInfo(double powerFactor):powerFactor(powerFactor)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
DGInfo::~DGInfo()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
QString DGInfo::getAttchedSubstaitonID()
|
||||
{
|
||||
return this->attchedSubstaitonID;
|
||||
}
|
||||
|
||||
double DGInfo::getCapacity()
|
||||
{
|
||||
return this->capacity;
|
||||
}
|
||||
|
||||
QString DGInfo::getName()
|
||||
{
|
||||
return this->name;
|
||||
}
|
||||
|
||||
void DGInfo::setAttchedSubstaitonID(const QString& id)
|
||||
{
|
||||
this->attchedSubstaitonID=id;
|
||||
}
|
||||
|
||||
void DGInfo::setCapacity(double cap)
|
||||
{
|
||||
this->capacity=cap;
|
||||
}
|
||||
|
||||
void DGInfo::setName(const QString& name)
|
||||
{
|
||||
this->name=name;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user