- Timestamp:
- 05/01/12 17:28:47 (13 years ago)
- Location:
- issm/branches/trunk-jpl-damage
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/branches/trunk-jpl-damage
- Property svn:ignore
-
old new 7 7 config.status 8 8 configure 9 doxygen10 9 ISSM.paf 11 10 ISSM.ppf 12 11 ISSM.ppf_cache 13 12 libtool 14 list15 13 Makefile 16 14 Makefile.in 17 15 stamp-h1 18 16 svn-commit* 19 nightlylog
-
- Property svn:mergeinfo changed
/issm/trunk merged: 11526,11533,11681-11682,11710,11778-11779,11995 /issm/trunk-jpl merged: 11992-11994,11996-12003,12005-12113,12115-12161,12163-12166
- Property svn:ignore
-
issm/branches/trunk-jpl-damage/src/c/objects/Loads/Icefront.cpp
r12004 r12168 163 163 } 164 164 /*}}}*/ 165 #ifdef _SERIAL_166 /*FUNCTION Icefront::Marshall {{{1*/167 void Icefront::Marshall(char** pmarshalled_dataset){168 169 char* marshalled_dataset=NULL;170 int enum_type=0;171 char* marshalled_inputs=NULL;172 int marshalled_inputs_size;173 174 /*recover marshalled_dataset: */175 marshalled_dataset=*pmarshalled_dataset;176 177 /*get enum type of Icefront: */178 enum_type=IcefrontEnum;179 180 /*marshall enum: */181 memcpy(marshalled_dataset,&enum_type,sizeof(enum_type));marshalled_dataset+=sizeof(enum_type);182 183 /*marshall Icefront data: */184 memcpy(marshalled_dataset,&id,sizeof(id));marshalled_dataset+=sizeof(id);185 memcpy(marshalled_dataset,&analysis_type,sizeof(analysis_type));marshalled_dataset+=sizeof(analysis_type);186 187 /*Marshall hooks: */188 hnodes->Marshall(&marshalled_dataset);189 helement->Marshall(&marshalled_dataset);190 hmatpar->Marshall(&marshalled_dataset);191 192 /*Marshall inputs: */193 marshalled_inputs_size=inputs->MarshallSize();194 marshalled_inputs=inputs->Marshall();195 memcpy(marshalled_dataset,marshalled_inputs,marshalled_inputs_size*sizeof(char));196 marshalled_dataset+=marshalled_inputs_size;197 198 /*parameters: don't do anything about it. parameters are marshalled somewhere else!*/199 200 xfree((void**)&marshalled_inputs);201 202 *pmarshalled_dataset=marshalled_dataset;203 }204 /*}}}*/205 /*FUNCTION Icefront::MarshallSize {{{1*/206 int Icefront::MarshallSize(){207 208 return sizeof(id)209 +sizeof(analysis_type)210 +hnodes->MarshallSize()211 +helement->MarshallSize()212 +hmatpar->MarshallSize()213 +inputs->MarshallSize()214 +sizeof(int); //sizeof(int) for enum type215 }216 /*}}}*/217 /*FUNCTION Icefront::Demarshall {{{1*/218 void Icefront::Demarshall(char** pmarshalled_dataset){219 220 char* marshalled_dataset=NULL;221 int i;222 223 /*recover marshalled_dataset: */224 marshalled_dataset=*pmarshalled_dataset;225 226 /*this time, no need to get enum type, the pointer directly points to the beginning of the227 *object data (thanks to DataSet::Demarshall):*/228 memcpy(&id,marshalled_dataset,sizeof(id));marshalled_dataset+=sizeof(id);229 memcpy(&analysis_type,marshalled_dataset,sizeof(analysis_type));marshalled_dataset+=sizeof(analysis_type);230 231 /*demarshall hooks: */232 hnodes=new Hook(); hnodes->Demarshall(&marshalled_dataset);233 helement=new Hook(); helement->Demarshall(&marshalled_dataset);234 hmatpar=new Hook(); hmatpar->Demarshall(&marshalled_dataset);235 236 /*pointers are garbabe, until configuration is carried out: */237 nodes=NULL;238 element=NULL;239 matpar=NULL;240 241 /*demarshall inputs: */242 inputs=(Inputs*)DataSetDemarshallRaw(&marshalled_dataset);243 244 /*parameters: may not exist even yet, so let Configure handle it: */245 this->parameters=NULL;246 247 /*return: */248 *pmarshalled_dataset=marshalled_dataset;249 return;250 }251 /*}}}*/252 #endif253 165 /*FUNCTION Icefront::ObjectEnum{{{1*/ 254 166 int Icefront::ObjectEnum(void){
Note:
See TracChangeset
for help on using the changeset viewer.