00001 #ifndef CLASSLIB_PIPED_INPUT_STREAM_H 00002 # define CLASSLIB_PIPED_INPUT_STREAM_H 00003 00004 //<<<<<< INCLUDES >>>>>> 00005 00006 # include "classlib/iotools/InputStream.h" 00007 00008 namespace lat { 00009 //<<<<<< PUBLIC DEFINES >>>>>> 00010 //<<<<<< PUBLIC CONSTANTS >>>>>> 00011 //<<<<<< PUBLIC TYPES >>>>>> 00012 00013 class PipedOutputStream; 00014 00015 //<<<<<< PUBLIC VARIABLES >>>>>> 00016 //<<<<<< PUBLIC FUNCTIONS >>>>>> 00017 //<<<<<< CLASS DECLARATIONS >>>>>> 00018 00019 class PipedInputStream : public InputStream 00020 { 00021 friend class PipedOutputStream; 00022 public: 00023 PipedInputStream (PipedOutputStream *link = 0); 00024 ~PipedInputStream (void); 00025 00026 virtual void connect (PipedOutputStream *to); 00027 00028 using InputStream::read; 00029 virtual IOSize read (void *into, IOSize n); 00030 virtual void close (void); 00031 00032 protected: 00033 PipedOutputStream *m_link; 00034 }; 00035 00036 //<<<<<< INLINE PUBLIC FUNCTIONS >>>>>> 00037 //<<<<<< INLINE MEMBER FUNCTIONS >>>>>> 00038 00039 } // namespace lat 00040 #endif // CLASSLIB_PIPED_INPUT_STREAM_H