From af8f64dfd0424b533611e7110e088182607b7c41 Mon Sep 17 00:00:00 2001 From: "facat@lab.com" Date: Sun, 28 Dec 2014 17:49:16 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E8=AF=95=E4=BA=86=E8=87=AA=E5=8A=A8?= =?UTF-8?q?=E7=BC=96=E5=8F=B7=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: facat@lab.com --- testHasttable/cimexporter.cpp | 11 ++++++++++- testHasttable/elementhashtable.cpp | 2 ++ testHasttable/topologyrecorder.cpp | 5 +++++ testHasttable/topologyrecorder.h | 1 + 4 files changed, 18 insertions(+), 1 deletion(-) diff --git a/testHasttable/cimexporter.cpp b/testHasttable/cimexporter.cpp index 5298659..8fdf615 100644 --- a/testHasttable/cimexporter.cpp +++ b/testHasttable/cimexporter.cpp @@ -1,5 +1,5 @@ #include "cimexporter.h" - +#include CIMExporter::CIMExporter() { } @@ -37,6 +37,15 @@ void CIMExporter::exportTo(const QString& path) this->idToNumber(this->line); this->idToNumber(this->sw); this->idToNumber(this->tf); + //开始按要求输出 + for(QList::iterator ite=this->line.begin(); + ite!=this->line.end(); + ite++) + { + LineStru l=*ite; + std::cout<eleHT); tpRecorder.startWithNode(node); + tpRecorder.exportTo(""); + break; } } diff --git a/testHasttable/topologyrecorder.cpp b/testHasttable/topologyrecorder.cpp index 93fbf41..056892c 100644 --- a/testHasttable/topologyrecorder.cpp +++ b/testHasttable/topologyrecorder.cpp @@ -25,6 +25,11 @@ bool TopologyRecorder::isEquipmentNeeded(const QString& substatinID) return false; } +void TopologyRecorder::exportTo(const QString& path) +{ + this->cimExporter.exportTo(path); +} + bool TopologyRecorder::startWithNode(const QString& node) { if(node=="") diff --git a/testHasttable/topologyrecorder.h b/testHasttable/topologyrecorder.h index c6fb580..50a56f0 100644 --- a/testHasttable/topologyrecorder.h +++ b/testHasttable/topologyrecorder.h @@ -32,6 +32,7 @@ public: TopologyRecorder(const QHash& elementHT,QObject *parent=0); ~TopologyRecorder(); bool startWithNode(const QString& node); + void exportTo(const QString& path); private: NodeToTerminal nodeToTerminal; const QHash& eleHT;