MCPcopy Create free account
hub / github.com/OpenSees/OpenSees / setForceUnit

Method setForceUnit

SRC/utility/SimulationInformation.cpp:214–232  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

212}
213
214int
215SimulationInformation::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
234int
235SimulationInformation::setTimeUnit(const char *name)

Callers 2

OPS_defaultUnitsFunction · 0.45
defaultUnitsFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected