DummyStream.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 $
00022 // $Date: 2006/08/03 23:34:32 $
00023 // $Source: /usr/local/cvs/OpenSees/SRC/handler/DummyStream.h,v $
00024 
00025 #ifndef _DummyStream
00026 #define _DummyStream
00027 
00028 #include <OPS_Stream.h>
00029 
00030 #include <fstream>
00031 using std::ofstream;
00032 
00033 class DummyStream : public OPS_Stream
00034 {
00035  public:
00036   DummyStream();
00037   ~DummyStream();
00038 
00039   // xml stuff
00040   int tag(const char *) {return 0;};
00041   int tag(const char *, const char *) {return 0;};
00042   int endTag() {return 0;};
00043   int attr(const char *name, int value) {return 0;};
00044   int attr(const char *name, double value) {return 0;};
00045   int attr(const char *name, const char *value) {return 0;};
00046   int write(Vector &data) {return 0;};
00047 
00048 
00049   OPS_Stream& write(const char *s, int n) {return *this;};
00050   OPS_Stream& write(const unsigned char *s, int n) {return *this;};
00051   OPS_Stream& write(const signed char *s, int n) {return *this;};
00052   OPS_Stream& write(const void *s, int n) {return *this;};
00053   OPS_Stream& operator<<(char c) {return *this;};
00054   OPS_Stream& operator<<(unsigned char c) {return *this;};
00055   OPS_Stream& operator<<(signed char c) {return *this;};
00056   OPS_Stream& operator<<(const char *s) {return *this;};
00057   OPS_Stream& operator<<(const unsigned char *s) {return *this;};
00058   OPS_Stream& operator<<(const signed char *s) {return *this;};
00059   OPS_Stream& operator<<(const void *p) {return *this;};
00060   OPS_Stream& operator<<(int n) {return *this;};
00061   OPS_Stream& operator<<(unsigned int n) {return *this;};
00062   OPS_Stream& operator<<(long n) {return *this;};
00063   OPS_Stream& operator<<(unsigned long n) {return *this;};
00064   OPS_Stream& operator<<(short n) {return *this;};
00065   OPS_Stream& operator<<(unsigned short n) {return *this;};
00066   OPS_Stream& operator<<(bool b) {return *this;};
00067   OPS_Stream& operator<<(double n) {return *this;};
00068   OPS_Stream& operator<<(float n) {return *this;};
00069 
00070   int sendSelf(int commitTag, Channel &theChannel) {return 0;};  
00071   int recvSelf(int commitTag, Channel &theChannel, 
00072                FEM_ObjectBroker &theBroker) {return 0;};
00073 
00074  private:
00075 };
00076 
00077 #endif

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