DummyNode.cpp

Go to the documentation of this file.
00001 /* ****************************************************************** **
00002 **    OpenSees - Open System for Earthquake Engineering Simulation    **
00003 **          Pacific Earthquake Engineering Research Center            **
00004 **                                                                    **
00005 **                                                                    **
00006 ** (C) Copyright 1999, The Regents of the University of California    **
00007 ** All Rights Reserved.                                               **
00008 **                                                                    **
00009 ** Commercial use of this program without express permission of the   **
00010 ** University of California, Berkeley, is strictly prohibited.  See   **
00011 ** file 'COPYRIGHT'  in main directory for information on usage and   **
00012 ** redistribution,  and for a DISCLAIMER OF ALL WARRANTIES.           **
00013 **                                                                    **
00014 ** Developed by:                                                      **
00015 **   Frank McKenna (fmckenna@ce.berkeley.edu)                         **
00016 **   Gregory L. Fenves (fenves@ce.berkeley.edu)                       **
00017 **   Filip C. Filippou (filippou@ce.berkeley.edu)                     **
00018 **                                                                    **
00019 ** ****************************************************************** */
00020                                                                         
00021 // $Revision: 1.2 $
00022 // $Date: 2003/02/14 23:00:58 $
00023 // $Source: /usr/local/cvs/OpenSees/SRC/domain/node/DummyNode.cpp,v $
00024                                                                         
00025                                                                         
00026 // File: ~/model/DummyNode.C
00027 //
00028 // Written: fmk 11/95
00029 // Revised:
00030 //
00031 // This file contains the methods required for class DummyNode.
00032    
00033 #include "DummyNode.h"
00034 #include <classTags.h>
00035 
00036 DummyNode::DummyNode()
00037 :Node(0, NOD_TAG_DummyNode), 
00038  theRealNode(0), theDOFGroup(0)
00039 {
00040 
00041 }
00042 
00043 DummyNode::DummyNode(Node &theNode)
00044 :Node(theNode.getTag(), NOD_TAG_DummyNode), 
00045  theRealNode(&theNode), theDOFGroup(0)
00046 {
00047     theRealNode = &theNode;
00048 }
00049 
00050 
00051 
00052 DummyNode::~DummyNode()
00053 {
00054 
00055 }
00056 
00057 Node *
00058 DummyNode::getNode() const
00059 {
00060 
00061     return theRealNode;
00062 }
00063 
00064 void
00065 DummyNode::setDOF_GroupPtr(DOF_Group *theDOF_Grp)
00066 {
00067       theDOFGroup = theDOF_Grp;
00068 }
00069 
00070 
00071 
00072 DOF_Group *
00073 DummyNode::getDOF_GroupPtr(void)
00074 {
00075     return theDOFGroup;
00076 }
00077 
00078 
00079 
00080 int
00081 DummyNode::getNumberDOF(void) const
00082 {
00083     return theRealNode->getNumberDOF();
00084 }
00085 
00086 
00087 
00088 
00089 
00090 const Matrix &
00091 DummyNode::getMass(void) 
00092 {
00093     
00094     return theRealNode->getMass();
00095 }
00096 
00097 
00098 
00099 
00100 int
00101 DummyNode::setMass(const Matrix &m)
00102 {
00103     return theRealNode->setMass(m);
00104 }
00105 
00106 
00107 
00108 const Vector &
00109 DummyNode::getCrds() const
00110 {
00111     return theRealNode->getCrds();
00112 }
00113 
00114 
00115 const Vector &
00116 DummyNode::getDisp(void) 
00117 {
00118     return theRealNode->getDisp();
00119 }
00120 
00121 
00122 const Vector &
00123 DummyNode::getVel(void) 
00124 {
00125     return theRealNode->getVel();
00126 }
00127 
00128 
00129 const Vector &
00130 DummyNode::getAccel(void) 
00131 {
00132     return theRealNode->getAccel();
00133 }
00134 
00135 
00136 const Vector &
00137 DummyNode::getTrialDisp(void) 
00138 {
00139     return theRealNode->getTrialDisp();
00140 }
00141 
00142 
00143 
00144 const Vector &
00145 DummyNode::getTrialVel(void) 
00146 {
00147     return theRealNode->getTrialVel();
00148 }
00149 
00150 
00151 
00152 const Vector &
00153 DummyNode::getTrialAccel(void) 
00154 {
00155     return theRealNode->getTrialAccel();
00156 }
00157 
00158 
00159 
00160 
00161 
00162 int
00163 DummyNode::setTrialDisp(const Vector &displ)
00164 {
00165     return 0;
00166 }
00167 
00168 int
00169 DummyNode::setTrialVel(const Vector &vel)
00170 {
00171     return 0;
00172 }
00173 
00174 
00175 int
00176 DummyNode::setTrialAccel(const Vector &accel)
00177 {
00178     return 0;
00179 }
00180 
00181 
00182 int
00183 DummyNode::setIncrTrialDisp(const Vector &incrDispl)
00184 {
00185     return 0;
00186 }
00187 
00188 
00189 int
00190 DummyNode::setIncrTrialVel(const Vector &incrVel)
00191 {
00192     return 0;
00193 }
00194 
00195 
00196 int
00197 DummyNode::setIncrTrialAccel(const Vector &incrAccel)
00198 {
00199     return 0;
00200 }
00201 
00202 
00203 int
00204 DummyNode::commitState()
00205 {
00206     return 0;
00207 }
00208 
00209 
00210 
00211 
00212 void 
00213 DummyNode::addUnbalancedLoad(const Vector &add)
00214 {
00215     theRealNode->addUnbalancedLoad(add);
00216 }
00217 
00218 
00219 
00220 const Vector &
00221 DummyNode::getUnbalancedLoad(void) const
00222 {
00223     return theRealNode->getUnbalancedLoad();
00224 }
00225 
00226 
00227 void 
00228 DummyNode::zeroUnbalancedLoad(void)
00229 {
00230     theRealNode->zeroUnbalancedLoad();
00231 }
00232 
00233 
00234 
00235 int
00236 DummyNode::addElementPtr(Element *elePtr)
00237 {
00238 //    return theRealNode->addElementPtr(elePtr);
00239   return 0;
00240 }
00241 
00242 
00243 
00244 void
00245 DummyNode::setColor(int newColor)
00246 {
00247 //    theRealNode->setColor(newColor);
00248 }
00249 
00250 int
00251 DummyNode::getColor(void) const
00252 {
00253 //    return theRealNode->getColor();
00254   return 0;
00255 }
00256 
00257 int 
00258 DummyNode::sendSelf(Channel &theChannel, FEM_ObjectBroker &theBroker)
00259 {
00260     opserr << "DummyNode::sendSelf - should never be called\n";
00261     opserr << "sending acual node\n";    
00262     
00263     return theRealNode->sendSelf(theChannel,theBroker);
00264 }
00265 
00266 int 
00267 DummyNode::recvSelf(Channel &theChannel, FEM_ObjectBroker &theBroker)
00268 {
00269     opserr << "DummyNode::recvSelf - should never be called\n";
00270     return 0;
00271 }    
00272 
00273 void
00274 DummyNode::Print(OPS_Stream &s) const
00275 {
00276     theRealNode->Print(s);
00277 }
00278   
00279 OPS_Stream &operator<<(OPS_Stream &s, const DummyNode &N)
00280 {
00281     N.Print(s);
00282     return s;
00283 }
00284 
00285 

Generated on Mon Oct 23 15:05:01 2006 for OpenSees by doxygen 1.5.0