33 mExpressions.removeAt( index );
38 QDomElement expressionFieldsElem = document.createElement(
"expressionfields" );
39 layerNode.appendChild( expressionFieldsElem );
43 QDomElement fldElem = document.createElement(
"field" );
45 fldElem.setAttribute(
"expression", fld.
expression );
46 fldElem.setAttribute(
"name", fld.
field.
name() );
49 fldElem.setAttribute(
"length", fld.
field.
length() );
50 fldElem.setAttribute(
"type", fld.
field.
type() );
53 expressionFieldsElem.appendChild( fldElem );
61 const QDomElement expressionFieldsElem = layerNode.firstChildElement(
"expressionfields" );
63 if ( !expressionFieldsElem.isNull() )
65 QDomNodeList fields = expressionFieldsElem.elementsByTagName(
"field" );
67 for (
unsigned int i = 0; i < fields.length(); ++i )
69 QDomElement field = fields.at( i ).toElement();
70 QString exp = field.attribute(
"expression" );
71 QString name = field.attribute(
"name" );
72 QString comment = field.attribute(
"comment" );
73 int precision = field.attribute(
"precision" ).toInt();
74 int length = field.attribute(
"length" ).toInt();
75 QVariant::Type type = ( QVariant::Type )( field.attribute(
"type" ).toInt() );
76 QString typeName = field.attribute(
"typeName" );