Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

Shadow.h

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.1.1.1 $
00022 // $Date: 2000/09/15 08:23:16 $
00023 // $Source: /usr/local/cvs/OpenSees/SRC/actor/shadow/Shadow.h,v $
00024                                                                         
00025                                                                         
00026 // File: ~/actor/Shadow.h
00027 //
00028 // Written: fmk
00029 // Created: 11/96
00030 // Revision: A
00031 //
00032 // Purpose: This file contains the class definition for Shadow.
00033 // Shadow is meant to be an abstract base class and thus no objects of it's type
00034 // can be instantiated. 
00035 //
00036 // What: "@(#) Shadow.h, revA"
00037 
00038 #ifndef Shadow_h
00039 #define Shadow_h
00040 
00041 #include <bool.h>
00042 
00043 #include <MachineBroker.h>
00044 #include <Message.h>
00045 #include <Channel.h>
00046 #include <ChannelAddress.h>
00047 #include <MovableObject.h>
00048 #include <Matrix.h>
00049 #include <Vector.h>
00050 #include <ID.h>
00051 
00052 #include <FEM_ObjectBroker.h>
00053 
00067 class Shadow
00068 {
00069   public:
00073     Shadow(Channel &theChannel, 
00074 
00075     FEM_ObjectBroker &theBroker,
00076     ChannelAddress &theAddress); 
00077     
00078     Shadow(char *program,
00079     Channel &theChannel, 
00080     FEM_ObjectBroker &theBroker,
00081     MachineBroker &theMachineBroker,
00082     int compDemand,
00083            bool startShadow);   
00084 
00085     virtual ~Shadow();
00086 
00093     virtual int sendObject(MovableObject &theObject);  
00094 
00101     virtual int recvObject(MovableObject &theObject);      
00102 
00109     virtual int sendMessage(const Message &theMessage);  
00110 
00117     virtual int recvMessage(Message &theMessage);  
00118 
00125     virtual int sendMatrix(const Matrix &theMatrix);  
00126 
00133     virtual int recvMatrix(Matrix &theMatrix);      
00134 
00141     virtual int sendVector(const Vector &theVector);  
00142 
00149     virtual int recvVector(Vector &theVector);      
00150 
00157     virtual int sendID(const ID &theID);  
00158 
00165     virtual int recvID(ID &theID);      
00166 
00167 
00171     Channel     *getChannelPtr(void) const;
00172 
00177     FEM_ObjectBroker  *getObjectBrokerPtr(void) const;        
00178 
00183     ChannelAddress    *getActorAddressPtr(void) const;            
00184 
00185 
00186   protected:
00188     FEM_ObjectBroker      *theBroker;
00189 
00191     Channel     *theChannel;    
00192 
00193   private:
00195     ChannelAddress    *theRemoteActorsAddress;    
00196 };
00197 
00198 #endif
Copyright Contact Us