|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r49844 - sandbox/interthreads/libs/interthreads/example/detail
From: vicente.botet_at_[hidden]
Date: 2008-11-19 10:52:01
Author: viboes
Date: 2008-11-19 10:52:01 EST (Wed, 19 Nov 2008)
New Revision: 49844
URL: http://svn.boost.org/trac/boost/changeset/49844
Log:
interthreads version 0.1
Added:
sandbox/interthreads/libs/interthreads/example/detail/async_ostream_sink.hpp (contents, props changed)
Added: sandbox/interthreads/libs/interthreads/example/detail/async_ostream_sink.hpp
==============================================================================
--- (empty file)
+++ sandbox/interthreads/libs/interthreads/example/detail/async_ostream_sink.hpp 2008-11-19 10:52:01 EST (Wed, 19 Nov 2008)
@@ -0,0 +1,46 @@
+#ifndef BOOST_INTERTHREADS_DETAIL_ASYNC_OSTREAM_SINK_HPP
+#define BOOST_INTERTHREADS_DETAIL_ASYNC_OSTREAM_SINK_HPP
+
+//////////////////////////////////////////////////////////////////////////////
+//
+// (C) Copyright Vicente J. Botet Escriba 2008.
+// Distributed under the Boost Software License, Version 1.0.
+// (See accompanying file LICENSE_1_0.txt or
+// copy at http://www.boost.org/LICENSE_1_0.txt)
+//
+// See http://www.boost.org/libs/interthreads for documentation.
+//
+//////////////////////////////////////////////////////////////////////////////
+
+#include <boost/iostreams/categories.hpp> // iostreams::sink_tag
+
+#include <iosfwd> // std::streamsize
+#include <iostream> // std::ostream
+#include <boost/shared_ptr.hpp> // shared_ptr
+
+namespace boost {
+namespace interthreads {
+ class async_ostream;
+ namespace detail {
+
+ struct async_ostream_sink {
+ typedef char char_type;
+ typedef boost::iostreams::sink_tag category;
+
+ async_ostream_sink(std::ostream& os);
+
+ std::streamsize write(const char* s, std::streamsize n);
+ void flush();
+
+ private:
+ friend class async_ostream_concentrator;
+ friend class async_ostream;
+ struct impl;
+ boost::shared_ptr<impl> impl_;
+ };
+ }
+}
+}
+
+#endif
+
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk