changed: rename the 'patchfile' attribute to 'basis'

more describing since we do not refer to external files any longer

git-svn-id: http://svn.sintef.no/trondheim/IFEM/trunk@1023 e10b68d5-8a6e-419e-a041-bce267b0401d
This commit is contained in:
akva
2011-06-01 13:27:44 +00:00
committed by Knut Morten Okstad
parent 63ebd5f00a
commit 2205096b27
3 changed files with 10 additions and 10 deletions

View File

@@ -76,11 +76,11 @@ int main (int argc, char** argv)
ProcessList processlist;
for (it = entry.begin(); it != entry.end(); ++it)
if (!it->patchfile.empty())
if (!it->basis.empty())
{
processlist["PATCHFILE " + it->patchfile].push_back(*it);
processlist["PATCHFILE " + it->basis].push_back(*it);
std::cout << it->name <<"\t"<< it->description <<"\tnc="<< it->components
<<"\t"<< it->patchfile << std::endl;
<<"\t"<< it->basis << std::endl;
}
ProcessList::const_iterator pit = processlist.begin();

View File

@@ -73,8 +73,8 @@ void XMLWriter::readInfo()
entry.description = elem->Attribute("description");
entry.patches = atoi(elem->Attribute("patches"));
entry.components = atoi(elem->Attribute("components"));
if (elem->Attribute("patchfile"))
entry.patchfile = elem->Attribute("patchfile");
if (elem->Attribute("basis"))
entry.basis = elem->Attribute("basis");
m_entry.push_back(entry);
}
elem = elem->NextSiblingElement("entry");
@@ -144,15 +144,15 @@ void XMLWriter::writeSIM (int level, const DataEntry& entry)
void XMLWriter::addField (const std::string& name,
const std::string& description,
const std::string& patchfile,
const std::string& basis,
int components, int patches)
{
TiXmlElement element("entry");
element.SetAttribute("name",name.c_str());
element.SetAttribute("description",description.c_str());
element.SetAttribute("type","field");
if (!patchfile.empty())
element.SetAttribute("patchfile",patchfile.c_str());
if (!basis.empty())
element.SetAttribute("basis",basis.c_str());
element.SetAttribute("patches",patches);
element.SetAttribute("components",components);
m_node->InsertEndChild(element);

View File

@@ -14,7 +14,7 @@ public:
struct Entry {
std::string name;
std::string description;
std::string patchfile;
std::string basis;
int patches;
int components;
};
@@ -37,7 +37,7 @@ public:
protected:
void addField(const std::string& name, const std::string& description,
const std::string& patchfile, int components, int patches);
const std::string& geometry, int components, int patches);
std::vector<Entry> m_entry;