LDOM_NodeList systemList = systems.getElementsByTagName( DDS_Dictionary::KeyWord( "UNIT_SYSTEM" ) );
for ( Standard_Integer i = 0; i < systemList.getLength(); i++ )
{
- LDOM_Element aSystem = (const LDOM_Element &)systemList.item( i );
+ //const LDOM_Element& aSystem = (const LDOM_Element &)systemList.item( i );
+ LDOM_Node aNode = systemList.item( i );
+ const LDOM_Element& anElem = (const LDOM_Element&) aNode;
+ LDOM_Element aSystem(anElem);
TCollection_AsciiString aName = aSystem.getAttribute( DDS_Dictionary::KeyWord( "UNIT_SYSTEM_NAME" ) );
TCollection_ExtendedString aLabel = aSystem.getAttribute( DDS_Dictionary::KeyWord( "UNIT_SYSTEM_LABEL" ) );
for ( Standard_Integer i = 0; i < aData.getLength(); i++ )
{
- LDOM_Element aQuantity = (const LDOM_Element&)aData.item( i );
+ //LDOM_Element aQuantity = (const LDOM_Element&)aData.item( i );
+ LDOM_Node aNode = aData.item( i );
+ const LDOM_Element& anElem = (const LDOM_Element&) aNode;
+ LDOM_Element aQuantity(anElem);
// 1. Attributes (id,label,units?,format?,required?)
TCollection_AsciiString anID = aQuantity.getAttribute( DDS_Dictionary::KeyWord( "DATUM_ID" ) );
if ( aListValueID.IsIntegerValue() )
{
// Read the text in the element "value"
- LDOM_Text aListItemTxt = (const LDOM_Text&)aListItemValue.getFirstChild();
+ //LDOM_Text aListItemTxt = (const LDOM_Text&)aListItemValue.getFirstChild();
+ LDOM_Node aNode = aListItemValue.getFirstChild();
+ const LDOM_Text& aText = (const LDOM_Text&) aNode;
+ LDOM_Text aListItemTxt(aText);
if ( !aListItemTxt.isNull() )
{
// adding ID and text value to sequence
if ( !aShDescr.isNull() )
{
// text is always a sub-node of element, containing it
- LDOM_Text aShDescrTxt = (const LDOM_Text&)aShDescr.getFirstChild();
+ //LDOM_Text aShDescrTxt = (const LDOM_Text&)aShDescr.getFirstChild();
+ LDOM_Node aNode = aShDescr.getFirstChild();
+ const LDOM_Text& aText = (const LDOM_Text&) aNode;
+ LDOM_Text aShDescrTxt(aText);
if ( !aShDescrTxt.isNull() )
aShortD = aShDescrTxt.getData();
}
if ( !aLDescr.isNull() )
{
// text is always a sub-node of element, containing it
- LDOM_Text aLDescrTxt = (const LDOM_Text&)aLDescr.getFirstChild();
+ //LDOM_Text aLDescrTxt = (const LDOM_Text&)aLDescr.getFirstChild();
+ LDOM_Node aNode = aLDescr.getFirstChild();
+ const LDOM_Text& aText = (const LDOM_Text&) aNode;
+ LDOM_Text aLDescrTxt(aText);
if ( !aLDescrTxt.isNull() )
aLongD = aLDescrTxt.getData();
}