| 192 | } |
| 193 | |
| 194 | int |
| 195 | SimulationInformation::setLengthUnit(const char *name) |
| 196 | { |
| 197 | // check for valid i/p |
| 198 | if (name == 0) |
| 199 | return -1; |
| 200 | |
| 201 | // delete the old |
| 202 | if (lengthUnit != 0) |
| 203 | delete [] lengthUnit; |
| 204 | |
| 205 | // create new space & copy string |
| 206 | lengthUnit = new char[strlen(name)+1]; |
| 207 | if (lengthUnit == 0) |
| 208 | return -1; |
| 209 | strcpy(lengthUnit, name); |
| 210 | |
| 211 | return 0; |
| 212 | } |
| 213 | |
| 214 | int |
| 215 | SimulationInformation::setForceUnit(const char *name) |
no outgoing calls
no test coverage detected