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