X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fio%2Fpipe.h;h=6d65a9a6b2f6bc140014c281b0f7b0c01e9f4b94;hb=c2003dc69422262a5c90b3bd73b60b459f563c6e;hp=a2a7d0f99f53ec6fafb69752c2f60886d5365a93;hpb=31e72f50fbb34d86877e5110401c49ce3fefd4bb;p=libs%2Fcore.git diff --git a/source/io/pipe.h b/source/io/pipe.h index a2a7d0f..6d65a9a 100644 --- a/source/io/pipe.h +++ b/source/io/pipe.h @@ -1,26 +1,24 @@ #ifndef MSP_IO_PIPE_H_ #define MSP_IO_PIPE_H_ -#include "base.h" +#include "eventobject.h" +#include "eventreader.h" #include "handle.h" namespace Msp { namespace IO { -class Pipe: public Base +class Pipe: public EventObject { private: - struct Private; - - Handle handle[2]; - Private *priv; + Handle read_handle; + Handle write_handle; + EventReader reader; public: Pipe(); ~Pipe(); - void close(); - void set_block(bool); protected: @@ -28,7 +26,7 @@ protected: virtual unsigned do_read(char *, unsigned); public: - virtual const Handle &get_event_handle(); + virtual const Handle &get_event_handle() { return reader.get_event(); } }; } // namespace IO