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

Method recvSelf

DEVELOPER/core/Node.cpp:1597–1771  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1595}
1596
1597int
1598Node::recvSelf(int cTag, Channel &theChannel,
1599 FEM_ObjectBroker &theBroker)
1600{
1601 int res = 0;
1602 int dataTag = this->getDbTag();
1603
1604
1605 ID data(14);
1606 res = theChannel.recvID(dataTag, cTag, data);
1607 if (res < 0) {
1608 opserr << "Node::recvSelf() - failed to receive ID data\n";
1609 return res;
1610 }
1611
1612 this->setTag(data(0));
1613 numberDOF = data(1);
1614 int numberCrd = data(7);
1615
1616 dbTag1 = data(8);
1617 dbTag2 = data(9);
1618 dbTag3 = data(10);
1619 dbTag4 = data(11);
1620
1621
1622 // create a Vector to hold coordinates IF one needed
1623 if (Crd == 0) {
1624 Crd = new Vector(numberCrd);
1625 }
1626
1627 // check we did not run out of memory
1628 if (Crd == 0) {
1629 opserr << "Node::recvSelf() - out of memory creating Coordinate vector\n";
1630 return -1;
1631 }
1632
1633 if (theChannel.recvVector(dataTag, cTag, *Crd) < 0) {
1634 opserr << "Node::recvSelf() - failed to receive the Coordinate vector\n";
1635 return -2;
1636 }
1637
1638 if (data(2) == 0) {
1639 // create the disp vectors if node is a total blank
1640 if (commitDisp == 0)
1641 this->createDisp();
1642
1643 // recv the committed disp
1644 if (theChannel.recvVector(dbTag1, cTag, *commitDisp) < 0) {
1645 opserr << "Node::recvSelf - failed to receive Disp data\n";
1646 return res;
1647 }
1648
1649 // set the trial quantities equal to committed
1650 for (int i=0; i<numberDOF; i++)
1651 disp[i] = disp[i+numberDOF]; // set trial equal commited
1652
1653 } else if (commitDisp != 0) {
1654 // if going back to initial we will just zero the vectors

Callers 2

recvObjMethod · 0.45
restoreStateMethod · 0.45

Calls 11

createDispMethod · 0.95
createVelMethod · 0.95
createAccelMethod · 0.95
exitFunction · 0.85
getDbTagMethod · 0.45
recvIDMethod · 0.45
setTagMethod · 0.45
recvVectorMethod · 0.45
ZeroMethod · 0.45
recvMatrixMethod · 0.45
noRowsMethod · 0.45

Tested by

no test coverage detected