| 116 | } |
| 117 | |
| 118 | int |
| 119 | MPI_Channel::recvObj(int commitTag, |
| 120 | MovableObject &theObject, |
| 121 | FEM_ObjectBroker &theBroker, |
| 122 | ChannelAddress *theAddress) |
| 123 | { |
| 124 | // first check address is the only address a MPI_Channel can send to |
| 125 | MPI_ChannelAddress *theMPI_ChannelAddress = 0; |
| 126 | if (theAddress != 0) { |
| 127 | if (theAddress->getType() == MPI_TYPE) { |
| 128 | theMPI_ChannelAddress = (MPI_ChannelAddress *)theAddress; |
| 129 | otherTag = theMPI_ChannelAddress->otherTag; |
| 130 | otherComm= theMPI_ChannelAddress->otherComm; |
| 131 | } else { |
| 132 | opserr << "MPI_Channel::recvObj() - a MPI_Channel "; |
| 133 | opserr << "can only communicate with a MPI_Channel"; |
| 134 | opserr << " address given is not of type MPI_ChannelAddress\n"; |
| 135 | return -1; |
| 136 | } |
| 137 | } |
| 138 | return theObject.recvSelf(commitTag, *this, theBroker); |
| 139 | } |
| 140 | |
| 141 | |
| 142 | // void Recv(Message &): |