| 57 | } |
| 58 | |
| 59 | void |
| 60 | MaterialStageParameter::setDomain(Domain *theDomain) |
| 61 | { |
| 62 | Element *theEle; |
| 63 | ElementIter &theEles = theDomain->getElements(); |
| 64 | |
| 65 | int theResult = -1; |
| 66 | |
| 67 | const char *theString[2];// = new const char*[2]; |
| 68 | char parameterName[21]; |
| 69 | char materialIdTag[10]; |
| 70 | sprintf(parameterName,"updateMaterialStage"); |
| 71 | sprintf(materialIdTag,"%d",theMaterialTag); |
| 72 | theString[0] = parameterName; |
| 73 | theString[1] = materialIdTag; |
| 74 | |
| 75 | // note because of the way this parameter is updated only need to find one in the domain |
| 76 | while (((theEle = theEles()) != 0) && (theResult == -1)) { |
| 77 | theResult = theEle->setParameter(theString, 2, *this); |
| 78 | } |
| 79 | |
| 80 | if (theResult == -1) |
| 81 | opserr << "WARNING: MaterialStageParameter::setDomain() - no effect with material tag " << theMaterialTag << endln; |
| 82 | |
| 83 | theResult = 0; |
| 84 | |
| 85 | return; |
| 86 | } |
| 87 | |
| 88 | int |
| 89 | MaterialStageParameter::sendSelf(int commitTag, Channel &theChannel) |
nothing calls this directly
no test coverage detected