@@ -1,7 +1,7 @@
|
||||
#include "elementhashtable.h"
|
||||
#include <iostream>
|
||||
ElementHashtable::ElementHashtable(QObject *parent) :
|
||||
QObject(parent),currentHT(NULL)
|
||||
QObject(parent),currentHT(NULL),tpRecorder(NULL)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -96,9 +96,14 @@ bool ElementHashtable::GoPath()
|
||||
continue;//有些Terminal是没有Node的
|
||||
}
|
||||
std::cout<<node.toStdString()<<std::endl;
|
||||
TopologyRecorder tpRecorder(this->eleHT,this->FDSet);
|
||||
tpRecorder.startWithNode(node);
|
||||
tpRecorder.exportTo("");
|
||||
if(this->tpRecorder!=NULL)
|
||||
{
|
||||
delete this->tpRecorder;
|
||||
this->tpRecorder=NULL;
|
||||
}
|
||||
this->tpRecorder=new TopologyRecorder(this->eleHT,this->FDSet);
|
||||
this->tpRecorder->startWithNode(node);
|
||||
this->tpRecorder->exportTo("");
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -155,6 +160,8 @@ bool ElementHashtable::Parse(const QString& xmlPWPath,const QString& xmlZWPath){
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
void ElementHashtable::SetACLineID(const QString &id)//寻找的线路ID
|
||||
{
|
||||
this->lineID=id;
|
||||
@@ -163,3 +170,15 @@ void ElementHashtable::SetFDSet(const QVector<QString> &FDSet)//FeeDer集合
|
||||
{
|
||||
this->FDSet=FDSet;
|
||||
}
|
||||
|
||||
void ElementHashtable::ShowContainerInfo(const QString& fileName)
|
||||
{
|
||||
QString relPath="./../output/";
|
||||
QFile file(relPath+fileName+".txt");
|
||||
if(file.open(QFile::ReadOnly))
|
||||
{
|
||||
QTextStream stream(&file);
|
||||
this->tpRecorder->showContainerInfo(stream);
|
||||
file.close();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user