Skip to content
Snippets Groups Projects
Commit 3d4da960 authored by Oliver Bock's avatar Oliver Bock
Browse files

Added support for nested VOResource objects (in compliance with VOTable 1.1 standard)

git-svn-id: https://svn.origo.ethz.ch/fidelity@10 53d1999f-d1a8-4366-aa61-588fded17473
parent 738cf80b
No related branches found
No related tags found
No related merge requests found
...@@ -32,8 +32,7 @@ Fidelity::Common::VOResource::~VOResource() ...@@ -32,8 +32,7 @@ Fidelity::Common::VOResource::~VOResource()
delete m_ParamList; delete m_ParamList;
delete m_LinkList; delete m_LinkList;
delete m_TableList; delete m_TableList;
// TODO: VOResource needs to include itself! delete m_ResourceList;
// delete m_ResourceList;
} }
void Fidelity::Common::VOResource::initAttributes() void Fidelity::Common::VOResource::initAttributes()
...@@ -43,8 +42,7 @@ void Fidelity::Common::VOResource::initAttributes() ...@@ -43,8 +42,7 @@ void Fidelity::Common::VOResource::initAttributes()
m_ParamList = new QList<VOParam*>(); m_ParamList = new QList<VOParam*>();
m_LinkList = new QList<VOLink*>(); m_LinkList = new QList<VOLink*>();
m_TableList = new QList<VOTable*>(); m_TableList = new QList<VOTable*>();
// TODO: VOResource needs to include itself! m_ResourceList = new QList<VOResource*>();
// m_ResourceList = new QList<VOResource*>();
} }
...@@ -116,16 +114,16 @@ bool Fidelity::Common::VOResource::buildXml(QDomElement* parent) ...@@ -116,16 +114,16 @@ bool Fidelity::Common::VOResource::buildXml(QDomElement* parent)
parent->appendChild(tag); parent->appendChild(tag);
} }
} }
// TODO: VOResource needs to include itself!
// if (!m_ResourceList->isEmpty()) { if (!m_ResourceList->isEmpty()) {
// for (int i = 0;i < m_ResourceList->size();i++) { for (int i = 0;i < m_ResourceList->size();i++) {
// QDomElement tag = doc.createElement("RESOURCE"); QDomElement tag = doc.createElement("RESOURCE");
// if(m_ResourceList->at(i)->buildXml(&tag) == false) { if(m_ResourceList->at(i)->buildXml(&tag) == false) {
// return(false); return(false);
// } }
// parent->appendChild(tag); parent->appendChild(tag);
// } }
// } }
return(true); return(true);
} }
...@@ -205,8 +203,8 @@ QList<VOTable*>* Fidelity::Common::VOResource::TableList() ...@@ -205,8 +203,8 @@ QList<VOTable*>* Fidelity::Common::VOResource::TableList()
{ {
return m_TableList; return m_TableList;
} }
// TODO: VOResource needs to include itself!
// QList<VOResource*>* Fidelity::Common::VOResource::ResourceList() QList<VOResource*>* Fidelity::Common::VOResource::ResourceList()
// { {
// return m_ResourceList; return m_ResourceList;
// } }
...@@ -165,7 +165,7 @@ public: ...@@ -165,7 +165,7 @@ public:
* Get the value of m_ResourceList * Get the value of m_ResourceList
* @return the value of m_ResourceList * @return the value of m_ResourceList
*/ */
// QList<VOResource*>* ResourceList(); QList<VOResource*>* ResourceList();
private: private:
QString m_ID; QString m_ID;
...@@ -178,8 +178,7 @@ private: ...@@ -178,8 +178,7 @@ private:
QList<VOParam*>* m_ParamList; QList<VOParam*>* m_ParamList;
QList<VOLink*>* m_LinkList; QList<VOLink*>* m_LinkList;
QList<VOTable*>* m_TableList; QList<VOTable*>* m_TableList;
// TODO: VOResource needs to include itself! QList<VOResource*>* m_ResourceList;
// QList<VOResource*>* m_ResourceList;
void initAttributes(); void initAttributes();
};}} };}}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment