#endif
}
else if ( !strcmp( Type , "float" ) || !strcmp( Type , "double" ) ) {
- double d ;
- sscanf( t , "%lf" , &d ) ;
- *theValue <<= d ;
- *theValue >>= d;
+ double d ;
+ sscanf( t , "%lf" , &d ) ;
+ theValue->replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d));
+ //*theValue <<= d ;
+ *theValue >>= d ;
#if ValueTrace
cdebug << " --> Value( " << d << ") (double) kind " << theValue->type()->kind() ;
#endif
<< theValue->type()->kind() ;
#endif
}
- _theValue = theValue ;
- *_Value = theValue ;
+ //_theValue = theValue ;
+ _theValue = new CORBA::Any( *theValue ) ;
+
+ //*_Value = theValue ;
+ _Value = &_theValue ;
+
//JR 21.02.2005 Debug Memory leak :
delete aDataValue ;
}
}
VXSize = 0 ;
GraphsNumber = 0 ;
+
+ aLinkValue = CORBA::Any();
}
GraphBase::XmlHandler::XmlHandler() {}
if ( constructor ) {
int sizedata = aListOfDataFlows[ GraphsNumber ].Datas.size() ;
aListOfDataFlows[ GraphsNumber ].Datas.resize( sizedata+1 ) ;
- aListOfDataFlows[ GraphsNumber ].Datas[ sizedata ] = aLink ;
+
+ if ( aLinkValue.type()->kind() == CORBA::tk_double )
+ aLink.aLinkValue = aLinkValue ;
+
+ aListOfDataFlows[ GraphsNumber ].Datas[ sizedata ] = aLink ;
+
if ( VXSize ) {
aListOfDataFlows[ GraphsNumber ].Datas[ sizedata ].aListOfCoords.resize( VXSize ) ;
int ic ;
break;
}
case CORBA::tk_double: {
- aLink.aLinkValue <<= (double ) 0. ;
- double d;
+ //aLink.aLinkValue <<= (double ) 0. ;
+ double d = 0.;
+ aLink.aLinkValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d));
aLink.aLinkValue >>= d;
#if TRACE
MESSAGE( d << " (double)" );
case CORBA::tk_double: {
double d;
sscanf( fieldvalue[depth].c_str() , "%lf" , &d ) ;
- aLink.aLinkValue <<= d;
+ //aLink.aLinkValue <<= d;
+ aLink.aLinkValue.replace(CORBA::TypeCode::PR_double_tc(), (void*)(&d));
+ aLinkValue = aLink.aLinkValue;
#if TRACE
- MESSAGE( d << " (double)" );
+ MESSAGE( d << " (double)" );
#endif
break;
}