home *** CD-ROM | disk | FTP | other *** search
- //
- // $Id: IrOutputStream.h,v 1.3 2000/06/06 09:30:56 sergey Exp $
- //
-
- #ifndef _IrOutputStream_h_
- #define _IrOutputStream_h_
-
- #include "Util/OutputStream.h"
- #include "IrPort.h"
-
-
- namespace IrDA
- {
- //
- // IrOutputStream class implements OutputStream interface.
- // All data will be re-directed into the IR port.
- //
- class IrOutputStream: public Util::OutputStream
- {
- public:
- IrOutputStream() {}
-
- private:
- IrOutputStream(const IrOutputStream&);
- IrOutputStream& operator =(const IrOutputStream&);
-
- // operations
- public:
- bool open();
- bool open(Callback& callback);
-
- void close();
-
- // OutputStream interface
-
- virtual void writeData(const void* data, int size);
-
- // attributes
-
- bool isOpened() const { _port.isOpened(); }
-
- // data members
- private:
- Port _port;
- };
- }
- // namespace IrDA
-
- #endif // _IrOutputStream_h_
-