| 212 | } |
| 213 | |
| 214 | int |
| 215 | SimulationInformation::setForceUnit(const char *name) |
| 216 | { |
| 217 | // check for valid i/p |
| 218 | if (name == 0) |
| 219 | return -1; |
| 220 | |
| 221 | // delete the old |
| 222 | if (forceUnit != 0) |
| 223 | delete [] forceUnit; |
| 224 | |
| 225 | // create new space & copy string |
| 226 | forceUnit = new char[strlen(name)+1]; |
| 227 | if (forceUnit == 0) |
| 228 | return -1; |
| 229 | strcpy(forceUnit, name); |
| 230 | |
| 231 | return 0; |
| 232 | } |
| 233 | |
| 234 | int |
| 235 | SimulationInformation::setTimeUnit(const char *name) |
no outgoing calls
no test coverage detected