1.1 --- a/attributeitem.cpp Wed Feb 10 13:48:42 2010 +0000
1.2 +++ b/attributeitem.cpp Fri Feb 19 13:47:03 2010 +0000
1.3 @@ -9,10 +9,6 @@
1.4 AttributeItem::AttributeItem(const QList<QVariant> &data, TreeItem *parent):BranchItem (data,parent)
1.5 {
1.6 TreeItem::setType (Attribute);
1.7 - //table=NULL;
1.8 - //definition=NULL;
1.9 - type=Attribute;
1.10 -
1.11 internal=false;
1.12 }
1.13
1.14 @@ -20,6 +16,20 @@
1.15 {
1.16 }
1.17
1.18 +void AttributeItem::set (const QString &k, const QString &v, const Type &t)
1.19 +{
1.20 + key=k;
1.21 + value=QVariant (v);
1.22 + setHeading (QString ("K: %1 | V: %2").arg(key).arg(value.toString()));
1.23 +}
1.24 +
1.25 +void AttributeItem::get (QString &k, QString &v, Type &t)
1.26 +{
1.27 + k=key;
1.28 + v=value.toString();
1.29 + t=attrType;
1.30 +}
1.31 +
1.32 void AttributeItem::setKey (const QString &k, const Type &t)
1.33 {
1.34 /*
1.35 @@ -145,6 +155,16 @@
1.36 */
1.37 }
1.38
1.39 +void AttributeItem::setInternal(bool b)
1.40 +{
1.41 + internal=b;
1.42 +}
1.43 +
1.44 +bool AttributeItem::isInternal()
1.45 +{
1.46 + return internal;
1.47 +}
1.48 +
1.49 QString AttributeItem::getDataXML()
1.50 {
1.51 QString a=beginElement ("attribute");