Changeset 23690
- Timestamp:
- 02/04/19 16:28:18 (6 years ago)
- Location:
- issm/trunk-jpl/src/c
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/classes/ExternalResults/GenericExternalResult.h
r23643 r23690 56 56 57 57 MARSHALLING_ENUM(this->ObjectEnum()); 58 59 bool isnull=true;60 if(marshall_direction==MARSHALLING_FORWARD || marshall_direction == MARSHALLING_SIZE) if(value) isnull=false;61 62 58 MARSHALLING(id); 63 MARSHALLING(result_name);64 MARSHALLING(isnull)65 if (!isnull) MARSHALLING(value) else value=0;66 59 MARSHALLING(step); 67 60 MARSHALLING(time); 68 61 62 /*Marshal result name*/ 63 int size = 0; 64 if(marshall_direction==MARSHALLING_FORWARD || marshall_direction == MARSHALLING_SIZE) size=strlen(result_name)+1; 65 MARSHALLING(size); 66 MARSHALLING_DYNAMIC(result_name,char,size); 67 68 /*Marshall value*/ 69 this->value=0; 70 bool isnull=true; 71 if(marshall_direction==MARSHALLING_FORWARD || marshall_direction == MARSHALLING_SIZE){ 72 if(value) isnull=false; 73 } 74 MARSHALLING(isnull); 75 if(!isnull) MARSHALLING(value) 69 76 } /*}}}*/ 70 77 … … 77 84 step = 0; 78 85 time = 0; 79 value = NULL;86 value = 0; 80 87 } /*}}}*/ 81 88 GenericExternalResult(int in_id, int in_enum_type,ResultType in_values, int in_M,int in_N,int in_step,IssmDouble in_time){/*{{{*/ -
issm/trunk-jpl/src/c/datastructures/DataSet.cpp
r23644 r23690 293 293 this->AddObject(penpair); 294 294 } 295 else if(obj_enum==DoubleExternalResultEnum){ 296 GenericExternalResult<double>* result=new GenericExternalResult<double>(); 297 result->Marshall(pmarshalled_data,pmarshalled_data_size,marshall_direction); 298 result->Echo(); 299 this->AddObject(result); 300 } 295 301 else _error_("could not recognize enum type: " << obj_enum << ": " << EnumToStringx(obj_enum) ); 296 302 }
Note:
See TracChangeset
for help on using the changeset viewer.