Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r63533 - in sandbox/SOC/2009/unicode: boost/iterator boost/unicode libs/unicode/doc libs/unicode/example libs/unicode/test libs/unicode/test/iterator libs/unicode/test/unicode
From: loufoque_at_[hidden]
Date: 2010-07-02 19:00:42


Author: mgaunard
Date: 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
New Revision: 63533
URL: http://svn.boost.org/trac/boost/changeset/63533

Log:
renaming the pipe and consumer concepts
Added:
   sandbox/SOC/2009/unicode/boost/iterator/convert_iterator.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator.hpp
   sandbox/SOC/2009/unicode/boost/iterator/convert_iterator_fwd.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator_fwd.hpp
   sandbox/SOC/2009/unicode/boost/iterator/converter_concept.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/iterator/pipe_concept.hpp
   sandbox/SOC/2009/unicode/boost/iterator/segment_iterator.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator.hpp
   sandbox/SOC/2009/unicode/boost/iterator/segment_iterator_fwd.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator_fwd.hpp
   sandbox/SOC/2009/unicode/boost/iterator/segmenter_concept.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/iterator/consumer_concept.hpp
   sandbox/SOC/2009/unicode/boost/unicode/converter_def.hpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/boost/unicode/pipe_def.hpp
   sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_convert.cpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_pipe.cpp
   sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_segment.cpp
      - copied, changed from r63531, /sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_consumer.cpp
Removed:
   sandbox/SOC/2009/unicode/boost/iterator/consumer_concept.hpp
   sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator.hpp
   sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator_fwd.hpp
   sandbox/SOC/2009/unicode/boost/iterator/pipe_concept.hpp
   sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator.hpp
   sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator_fwd.hpp
   sandbox/SOC/2009/unicode/boost/unicode/pipe_def.hpp
   sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_consumer.cpp
   sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_pipe.cpp
Text files modified:
   sandbox/SOC/2009/unicode/boost/iterator/convert_iterator.hpp | 144 ++++++++++++++++----------------
   sandbox/SOC/2009/unicode/boost/iterator/convert_iterator_fwd.hpp | 72 ++++++++--------
   sandbox/SOC/2009/unicode/boost/iterator/converter_concept.hpp | 26 ++--
   sandbox/SOC/2009/unicode/boost/iterator/segment_iterator.hpp | 176 ++++++++++++++++++++-------------------
   sandbox/SOC/2009/unicode/boost/iterator/segment_iterator_fwd.hpp | 22 ++--
   sandbox/SOC/2009/unicode/boost/iterator/segmenter_concept.hpp | 6
   sandbox/SOC/2009/unicode/boost/unicode/cat.hpp | 36 ++++----
   sandbox/SOC/2009/unicode/boost/unicode/combining.hpp | 20 ++--
   sandbox/SOC/2009/unicode/boost/unicode/compose.hpp | 2
   sandbox/SOC/2009/unicode/boost/unicode/compose_fwd.hpp | 14 +-
   sandbox/SOC/2009/unicode/boost/unicode/converter_def.hpp | 28 +++---
   sandbox/SOC/2009/unicode/boost/unicode/graphemes.hpp | 38 ++++----
   sandbox/SOC/2009/unicode/boost/unicode/hangul.hpp | 8
   sandbox/SOC/2009/unicode/boost/unicode/utf.hpp | 36 ++++----
   sandbox/SOC/2009/unicode/boost/unicode/utf_codecs.hpp | 26 ++--
   sandbox/SOC/2009/unicode/libs/unicode/doc/Jamfile.v2 | 2
   sandbox/SOC/2009/unicode/libs/unicode/doc/autodoc1c.xml | 6
   sandbox/SOC/2009/unicode/libs/unicode/doc/users_manual.qbk | 92 ++++++++++----------
   sandbox/SOC/2009/unicode/libs/unicode/example/search.cpp | 8
   sandbox/SOC/2009/unicode/libs/unicode/test/Jamfile.v2 | 4
   sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_convert.cpp | 24 ++--
   sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_segment.cpp | 24 ++--
   sandbox/SOC/2009/unicode/libs/unicode/test/unicode/range_test.hpp | 2
   23 files changed, 409 insertions(+), 407 deletions(-)

Deleted: sandbox/SOC/2009/unicode/boost/iterator/consumer_concept.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/iterator/consumer_concept.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,53 +0,0 @@
-#ifndef BOOST_ITERATOR_CONSUMER_CONCEPT_HPP
-#define BOOST_ITERATOR_CONSUMER_CONCEPT_HPP
-
-#include <boost/concept_archetype.hpp>
-#include <boost/concept_check.hpp>
-
-namespace boost
-{
-
-/** Concept checking class for the \c Consumer concept */
-template<typename X>
-struct ConsumerConcept : DefaultConstructible<X>, CopyConstructible<X>
-{
- typedef typename X::input_type input_type;
-
- BOOST_CONCEPT_USAGE(ConsumerConcept)
- {
- X c;
- begin = c.ltr(begin, end);
- end = c.rtl(begin, end);
- }
-
-private:
- typedef bidirectional_iterator_archetype<input_type> in_type;
-
- in_type begin;
- in_type end;
-};
-
-/** Concept checking class for the \c BoundaryChecker concept */
-template<typename X>
-struct BoundaryCheckerConcept : DefaultConstructible<X>, CopyConstructible<X>
-{
- typedef typename X::input_type input_type;
-
- BOOST_CONCEPT_USAGE(BoundaryCheckerConcept)
- {
- X b;
- result = b(begin, end, pos);
- }
-
-private:
- typedef bidirectional_iterator_archetype<input_type> in_type;
- in_type begin;
- in_type end;
- in_type pos;
-
- bool result;
-};
-
-} // namespace boost
-
-#endif

Deleted: sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,257 +0,0 @@
-#ifndef BOOST_ITERATOR_CONSUMER_ITERATOR_HPP
-#define BOOST_ITERATOR_CONSUMER_ITERATOR_HPP
-
-#include <boost/iterator/dummy_output_iterator.hpp>
-
-#include <boost/concept/requires.hpp>
-#include <boost/range/concepts.hpp>
-#include <boost/iterator/pipe_concept.hpp>
-
-#include <boost/iterator/consumer_iterator_fwd.hpp>
-
-#include <boost/mpl/assert.hpp>
-#include <boost/mpl/equal_to.hpp>
-
-
-namespace boost
-{
-
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * constructed from a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly. */
-template<typename Pipe>
-struct pipe_consumer : private Pipe
-{
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
-
- typedef typename Pipe::input_type input_type;
-
- pipe_consumer() {} // singular
-
- pipe_consumer(Pipe p_) : Pipe(p_)
- {
- }
-
- template<typename In>
- In ltr(In begin, In end)
- {
- return Pipe::ltr(begin, end, dummy_output_iterator()).first;
- }
-
- template<typename In>
- In rtl(In begin, In end)
- {
- return Pipe::rtl(begin, end, dummy_output_iterator()).first;
- }
-};
-
-template<typename Pipe>
-BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<Pipe>)),
- (pipe_consumer<Pipe>)
-) make_pipe_consumer(Pipe p)
-{
- return pipe_consumer<Pipe>(p);
-}
-
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * constructed from a model of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly. */
-template<typename BoundaryChecker>
-struct boundary_consumer : private BoundaryChecker
-{
- BOOST_CONCEPT_ASSERT((BoundaryCheckerConcept<BoundaryChecker>));
-
- typedef typename BoundaryChecker::input_type input_type;
-
- boundary_consumer() {} // singular
-
- boundary_consumer(BoundaryChecker b_) : BoundaryChecker(b_)
- {
- }
-
- template<typename In>
- In ltr(In begin, In end)
- {
- In pos = begin;
- do
- ++pos;
- while(pos != end && !BoundaryChecker::operator()(begin, end, pos));
-
- return pos;
- }
-
- template<typename In>
- In rtl(In begin, In end)
- {
- In pos = end;
- do
- --pos;
- while(pos != end && !BoundaryChecker::operator()(begin, end, pos));
-
- return pos;
- }
-};
-
-template<typename BoundaryChecker>
-BOOST_CONCEPT_REQUIRES(
- ((BoundaryCheckerConcept<BoundaryChecker>)),
- (boundary_consumer<BoundaryChecker>)
-) make_boundary_consumer(BoundaryChecker b)
-{
- return boundary_consumer<BoundaryChecker>(b);
-}
-
-/** Model of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly
- * constructed from two models of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly
- * with a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly applied in the middle. */
-template<typename B1, typename Pipe, typename B2>
-struct multi_boundary
-{
- BOOST_CONCEPT_ASSERT((BoundaryCheckerConcept<B1>));
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
- BOOST_CONCEPT_ASSERT((BoundaryCheckerConcept<B2>));
-
- BOOST_CONCEPT_ASSERT((Convertible<typename B1::input_type, typename Pipe::input_type>));
- BOOST_CONCEPT_ASSERT((Convertible<typename Pipe::output_type, typename B2::input_type>));
-
- typedef typename B1::input_type input_type;
-
- multi_boundary() // singular
- {
- }
-
- multi_boundary(B1 b1_, Pipe p_, B2 b2_) : b1(b1_), p(p_), b2(b2_)
- {
- }
-
- template<typename In>
- bool operator()(In begin, In end, In pos)
- {
- return b1(begin, end, pos)
- && b2(
- make_pipe_iterator(begin, end, begin, p),
- make_pipe_iterator(begin, end, end, p),
- make_pipe_iterator(begin, end, pos, p)
- );
- }
-
-private:
- B1 b1;
- Pipe p;
- B2 b2;
-};
-
-template<typename B1, typename Pipe, typename B2>
-BOOST_CONCEPT_REQUIRES(
- ((BoundaryCheckerConcept<B1>))
- ((PipeConcept<Pipe>))
- ((BoundaryCheckerConcept<B2>))
- ((Convertible<typename B1::input_type, typename Pipe::input_type>))
- ((Convertible<typename Pipe::output_type, typename B2::input_type>)),
- (multi_boundary<B1, Pipe, B2>)
-) make_multi_boundary(B1 b1, Pipe p, B2 b2)
-{
- return multi_boundary<B1, Pipe, B2>(b1, p, b2);
-}
-
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * that adapts the elements another \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * sees with a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly, assuming its \c max_output is \c 1. */
-template<typename Pipe, typename Consumer>
-struct piped_consumer
-{
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
- BOOST_CONCEPT_ASSERT((ConsumerConcept<Consumer>));
- BOOST_CONCEPT_ASSERT((Convertible<typename Pipe::output_type, typename Consumer::input_type>));
-
- BOOST_MPL_ASSERT(( mpl::equal_to< typename Pipe::max_output, mpl::int_<1> > ));
-
- typedef typename Pipe::input_type input_type;
-
- piped_consumer() // singular
- {
- }
-
- piped_consumer(Pipe p_, Consumer c_) : p(p_), c(c_)
- {
- }
-
- template<typename In>
- In ltr(In begin, In end)
- {
- return c.ltr(
- make_pipe_iterator(begin, end, begin, p),
- make_pipe_iterator(begin, end, end, p)
- ).base();
- }
-
- template<typename In>
- In rtl(In begin, In end)
- {
- return c.rtl(
- make_pipe_iterator(begin, end, begin, p),
- make_pipe_iterator(begin, end, end, p)
- ).base();
- }
-
-private:
- Pipe p;
- Consumer c;
-};
-
-template<typename Pipe, typename Consumer>
-BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<Pipe>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename Pipe::output_type, typename Consumer::input_type>)),
- (piped_consumer<Pipe, Consumer>)
-) make_piped_consumer(Pipe p, Consumer c)
-{
- return piped_consumer<Pipe, Consumer>(p, c);
-}
-
-template<typename It, typename Consumer>
-BOOST_CONCEPT_REQUIRES(
- ((InputIterator<It>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename InputIterator<It>::value_type, typename Consumer::input_type>)),
- (consumer_iterator<It, Consumer>)
-) make_consumer_iterator(It begin, It end, It pos, Consumer c)
-{
- return consumer_iterator<It, Consumer>(begin, end, pos, c);
-}
-
-template<typename Range, typename Consumer>
-BOOST_CONCEPT_REQUIRES(
- ((SinglePassRangeConcept<Range>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename range_value<const Range>::type, typename Consumer::input_type>)),
- (iterator_range<
- consumer_iterator<typename range_iterator<const Range>::type, Consumer>
- >)
-) consumed(const Range& range, Consumer c)
-{
- return boost::make_iterator_range(
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::begin(range), c),
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::end(range), c)
- );
-}
-
-template<typename Range, typename Consumer>
-BOOST_CONCEPT_REQUIRES(
- ((SinglePassRangeConcept<Range>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename range_value<Range>::type, typename Consumer::input_type>)),
- (iterator_range<
- consumer_iterator<typename range_iterator<Range>::type, Consumer>
- >)
-) consumed(Range& range, Consumer c)
-{
- return boost::make_iterator_range(
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::begin(range), c),
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::end(range), c)
- );
-}
-
-} // namespace boost
-
-#endif

Deleted: sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator_fwd.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator_fwd.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,82 +0,0 @@
-#ifndef BOOST_ITERATOR_CONSUMER_ITERATOR_FWD_HPP
-#define BOOST_ITERATOR_CONSUMER_ITERATOR_FWD_HPP
-
-#include <boost/iterator/iterator_facade.hpp>
-#include <boost/range.hpp>
-
-#include <boost/iterator/consumer_concept.hpp>
-
-namespace boost
-{
-
-/** Iterator adapter that wraps a range to make it appear like a range
- * of subranges, each subrange being a step of a \c Consumer invocation. */
-template<typename It, typename Consumer>
-struct consumer_iterator
- : iterator_facade<
- consumer_iterator<It, Consumer>,
- iterator_range<It>,
- std::bidirectional_iterator_tag,
- const iterator_range<It>
- >
-{
- BOOST_CONCEPT_ASSERT((InputIterator<It>));
- BOOST_CONCEPT_ASSERT((ConsumerConcept<Consumer>));
- BOOST_CONCEPT_ASSERT((Convertible<typename InputIterator<It>::value_type, typename Consumer::input_type>));
-
- consumer_iterator() {} // singular
-
- consumer_iterator(It begin_, It end_, It pos_, Consumer c_) : pos(pos_), begin(begin_), end(end_), p(c_)
- {
- if(pos != end)
- next_pos = p.ltr(pos, end);
- }
-
- It base() const
- {
- BOOST_CONCEPT_ASSERT((ForwardIterator<It>));
-
- return pos;
- }
-
-private:
- friend class boost::iterator_core_access;
-
- iterator_range<It> dereference() const
- {
- return make_iterator_range(pos, next_pos);
- }
-
- void increment()
- {
- pos = next_pos;
- if(pos != end)
- next_pos = p.ltr(pos, end);
- }
-
- void decrement()
- {
- BOOST_CONCEPT_ASSERT((BidirectionalIterator<It>));
-
- next_pos = pos;
-
- pos = p.rtl(begin, pos);
- }
-
- bool equal(const consumer_iterator& other) const
- {
- return pos == other.pos;
- }
-
- It pos;
- It next_pos;
-
- It begin;
- It end;
-
- Consumer p;
-};
-
-} // namespace boost
-
-#endif

Copied: sandbox/SOC/2009/unicode/boost/iterator/convert_iterator.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/iterator/convert_iterator.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -12,7 +12,7 @@
 #include <boost/concept/requires.hpp>
 #include <boost/range/concepts.hpp>
 
-#include <boost/iterator/pipe_iterator_fwd.hpp>
+#include <boost/iterator/convert_iterator_fwd.hpp>
 
 #include <boost/type_traits.hpp>
 #include <boost/mpl/logical.hpp>
@@ -24,9 +24,9 @@
 namespace boost
 {
 
-/** CRTP Utility to define a \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly. */
-template<typename OneManyPipe>
-struct one_many_pipe
+/** CRTP Utility to define a \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly. */
+template<typename OneManyConverter>
+struct one_many_converter
 {
         template<typename In, typename Out>
         std::pair<In, Out>
@@ -34,7 +34,7 @@
         {
                 BOOST_ASSERT(begin != end);
                 
- out = static_cast<OneManyPipe&>(*this)(*begin, out);
+ out = static_cast<OneManyConverter&>(*this)(*begin, out);
                 return std::make_pair(++begin, out);
         }
         
@@ -44,23 +44,23 @@
         {
                 BOOST_ASSERT(begin != end);
                 
- out = static_cast<OneManyPipe&>(*this)(*--end, out);
+ out = static_cast<OneManyConverter&>(*this)(*--end, out);
                 return std::make_pair(end, out);
         }
 };
 
 /* TODO: Make it work for types that don't expose max_output */
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * constructed from two models of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
+ * constructed from two models of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
  * and that applies one after the other.
  *
- * The second pipe must require less input than the output of the first per
+ * The second convert must require less input than the output of the first per
  * step for it to work. */
 template<typename P1, typename P2>
-struct multi_pipe
+struct multi_converter
 {
- BOOST_CONCEPT_ASSERT((PipeConcept<P1>));
- BOOST_CONCEPT_ASSERT((PipeConcept<P2>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<P1>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<P2>));
     
     BOOST_CONCEPT_ASSERT((Convertible<typename P1::output_type, typename P2::input_type>));
     
@@ -72,8 +72,8 @@
         typename P2::max_output
>::type max_output;
     
- multi_pipe() {}
- multi_pipe(P1 p1_, P2 p2_ = P2()) : p1(p1_), p2(p2_) {}
+ multi_converter() {}
+ multi_converter(P1 p1_, P2 p2_ = P2()) : p1(p1_), p2(p2_) {}
     
     template<typename In, typename Out>
     typename enable_if<
@@ -202,23 +202,23 @@
 
 template<typename P1, typename P2>
 BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<P1>))
- ((PipeConcept<P2>))
+ ((ConverterConcept<P1>))
+ ((ConverterConcept<P2>))
     ((Convertible<typename P1::output_type, typename P2::input_type>)),
- (multi_pipe<P1, P2>)
-) make_multi_pipe(P1 p1, P2 p2)
+ (multi_converter<P1, P2>)
+) make_multi_converter(P1 p1, P2 p2)
 {
- return multi_pipe<P1, P2>(p1, p2);
+ return multi_converter<P1, P2>(p1, p2);
 }
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * that adapts the elements another \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * sees with a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly, assuming its \c max_output is \c 1. */
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
+ * that adapts the elements another \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
+ * sees with a model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly, assuming its \c max_output is \c 1. */
 template<typename P1, typename P2>
-struct piped_pipe : P2
+struct converted_converter : P2
 {
- BOOST_CONCEPT_ASSERT((PipeConcept<P1>));
- BOOST_CONCEPT_ASSERT((PipeConcept<P2>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<P1>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<P2>));
     
     BOOST_CONCEPT_ASSERT((Convertible<typename P1::output_type, typename P2::input_type>));
     
@@ -227,18 +227,18 @@
     typedef typename P1::input_type input_type;
     typedef typename P2::output_type output_type;
     
- piped_pipe() {}
- piped_pipe(P1 p1_, P2 p2_ = P2()) : P2(p2_), p1(p1_) {}
+ converted_converter() {}
+ converted_converter(P1 p1_, P2 p2_ = P2()) : P2(p2_), p1(p1_) {}
     
     template<typename In, typename Out>
     std::pair<In, Out> ltr(In begin, In end, Out out)
     {
         std::pair<
- pipe_iterator<In, P1>,
+ convert_iterator<In, P1>,
             Out
> pair = P2::ltr(
- make_pipe_iterator(begin, end, begin, p1),
- make_pipe_iterator(begin, end, end, p1),
+ make_convert_iterator(begin, end, begin, p1),
+ make_convert_iterator(begin, end, end, p1),
             out
         );
         
@@ -249,11 +249,11 @@
     std::pair<In, Out> rtl(In begin, In end, Out out)
     {
         std::pair<
- pipe_iterator<In, P1>,
+ convert_iterator<In, P1>,
             Out
> pair = P2::rtl(
- make_pipe_iterator(begin, end, begin, p1),
- make_pipe_iterator(begin, end, end, p1),
+ make_convert_iterator(begin, end, begin, p1),
+ make_convert_iterator(begin, end, end, p1),
             out
         );
         return std::make_pair(pair.first.base(), pair.second);
@@ -265,21 +265,21 @@
 
 template<typename P1, typename P2>
 BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<P1>))
- ((PipeConcept<P2>))
+ ((ConverterConcept<P1>))
+ ((ConverterConcept<P2>))
     ((Convertible<typename P1::output_type, typename P2::input_type>)),
- (piped_pipe<P1, P2>)
-) make_piped_pipe(P1 p1, P2 p2)
+ (converted_converter<P1, P2>)
+) make_converted_converter(P1 p1, P2 p2)
 {
- return piped_pipe<P1, P2>(p1, p2);
+ return converted_converter<P1, P2>(p1, p2);
 }
 
 
 
-/** Model of \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly
  * that casts its input to its template parameter and writes it to its output. */
 template<typename T>
-struct cast_pipe : one_many_pipe< cast_pipe<T> >
+struct cast_converter : one_many_converter< cast_converter<T> >
 {
     typedef T input_type;
     typedef T output_type;
@@ -293,57 +293,57 @@
     }
 };
 
-template<typename It, typename Pipe>
+template<typename It, typename Converter>
 BOOST_CONCEPT_REQUIRES(
     ((InputIterator<It>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename InputIterator<It>::value_type, typename Pipe::input_type>)),
- (pipe_iterator<It, Pipe>)
-) make_pipe_iterator(It begin, It end, It pos, Pipe p)
+ ((ConverterConcept<Converter>))
+ ((Convertible<typename InputIterator<It>::value_type, typename Converter::input_type>)),
+ (convert_iterator<It, Converter>)
+) make_convert_iterator(It begin, It end, It pos, Converter p)
 {
- return pipe_iterator<It, Pipe>(begin, end, pos, p);
+ return convert_iterator<It, Converter>(begin, end, pos, p);
 }
 
-template<typename Range, typename Pipe>
+template<typename Range, typename Converter>
 BOOST_CONCEPT_REQUIRES(
     ((SinglePassRangeConcept<Range>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename range_value<Range>::type, typename Pipe::input_type>)),
+ ((ConverterConcept<Converter>))
+ ((Convertible<typename range_value<Range>::type, typename Converter::input_type>)),
     (iterator_range<
- pipe_iterator<typename range_iterator<const Range>::type, Pipe>
+ convert_iterator<typename range_iterator<const Range>::type, Converter>
>)
-) piped(const Range& range, Pipe p)
+) converted(const Range& range, Converter p)
 {
         return boost::make_iterator_range(
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::begin(range), p),
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::end(range), p)
+ make_convert_iterator(boost::begin(range), boost::end(range), boost::begin(range), p),
+ make_convert_iterator(boost::begin(range), boost::end(range), boost::end(range), p)
         );
 }
 
-template<typename Range, typename Pipe>
+template<typename Range, typename Converter>
 BOOST_CONCEPT_REQUIRES(
     ((SinglePassRangeConcept<Range>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename range_value<Range>::type, typename Pipe::input_type>)),
+ ((ConverterConcept<Converter>))
+ ((Convertible<typename range_value<Range>::type, typename Converter::input_type>)),
     (iterator_range<
- pipe_iterator<typename range_iterator<Range>::type, Pipe>
+ convert_iterator<typename range_iterator<Range>::type, Converter>
>)
-) piped(Range& range, Pipe p)
+) converted(Range& range, Converter p)
 {
         return boost::make_iterator_range(
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::begin(range), p),
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::end(range), p)
+ make_convert_iterator(boost::begin(range), boost::end(range), boost::begin(range), p),
+ make_convert_iterator(boost::begin(range), boost::end(range), boost::end(range), p)
         );
 }
 
-template<typename Range, typename Pipe, typename OutputIterator>
+template<typename Range, typename Converter, typename OutputIterator>
 BOOST_CONCEPT_REQUIRES(
     ((SinglePassRangeConcept<Range>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename range_value<Range>::type, typename Pipe::input_type>))
- ((OutputIteratorConcept<OutputIterator, typename Pipe::output_type>)),
+ ((ConverterConcept<Converter>))
+ ((Convertible<typename range_value<Range>::type, typename Converter::input_type>))
+ ((OutputIteratorConcept<OutputIterator, typename Converter::output_type>)),
     (OutputIterator)
-) pipe(const Range& range, Pipe pipe, OutputIterator out)
+) convert(const Range& range, Converter convert, OutputIterator out)
 {
     typedef typename boost::range_iterator<const Range>::type Iterator;
     
@@ -352,7 +352,7 @@
     
     while(begin != end)
     {
- std::pair<Iterator, OutputIterator> p = pipe.ltr(begin, end, out);
+ std::pair<Iterator, OutputIterator> p = convert.ltr(begin, end, out);
         begin = p.first;
         out = p.second;
     }
@@ -360,14 +360,14 @@
     return out;
 }
 
-template<typename OutputIterator, typename OneManyPipe>
+template<typename OutputIterator, typename OneManyConverter>
 BOOST_CONCEPT_REQUIRES(
- ((OneManyPipeConcept<OneManyPipe>))
- ((OutputIteratorConcept<OutputIterator, typename OneManyPipe::output_type>)),
- (pipe_output_iterator<OutputIterator, OneManyPipe>)
-) piped_output(OutputIterator out, OneManyPipe p)
+ ((OneManyConverterConcept<OneManyConverter>))
+ ((OutputIteratorConcept<OutputIterator, typename OneManyConverter::output_type>)),
+ (convert_output_iterator<OutputIterator, OneManyConverter>)
+) converted_output(OutputIterator out, OneManyConverter p)
 {
- return pipe_output_iterator<OutputIterator, OneManyPipe>(out, p);
+ return convert_output_iterator<OutputIterator, OneManyConverter>(out, p);
 }
 
 } // namespace boost

Copied: sandbox/SOC/2009/unicode/boost/iterator/convert_iterator_fwd.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator_fwd.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator_fwd.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/iterator/convert_iterator_fwd.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -7,7 +7,7 @@
 #include <boost/iterator/iterator_facade.hpp>
 #include <vector>
 
-#include <boost/iterator/pipe_concept.hpp>
+#include <boost/iterator/converter_concept.hpp>
 
 namespace boost
 {
@@ -17,12 +17,12 @@
     BOOST_MPL_HAS_XXX_TRAIT_DEF(max_output)
 
     template<typename P, typename Enable = void>
- struct pipe_output_storage;
+ struct convert_output_storage;
 
     template<typename P>
- struct pipe_output_storage<P, typename ::boost::disable_if< has_max_output<P> >::type>
+ struct convert_output_storage<P, typename ::boost::disable_if< has_max_output<P> >::type>
     {
- BOOST_CONCEPT_ASSERT((PipeConcept<P>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<P>));
 private:
         typedef std::vector<typename P::output_type> Values;
 public:
@@ -53,9 +53,9 @@
     };
     
     template<typename P>
- struct pipe_output_storage<P, typename boost::enable_if< has_max_output<P> >::type>
+ struct convert_output_storage<P, typename boost::enable_if< has_max_output<P> >::type>
     {
- BOOST_CONCEPT_ASSERT((PipeConcept<P>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<P>));
 private:
         typedef typename P::output_type Value;
 public:
@@ -89,27 +89,27 @@
 
 /** Iterator adapter that wraps a range to make it appear like a converted
  * one, by converting it step-by-step as it is advanced. */
-template<typename It, typename Pipe>
-struct pipe_iterator
+template<typename It, typename Converter>
+struct convert_iterator
         : iterator_facade<
- pipe_iterator<It, Pipe>,
- typename Pipe::output_type,
+ convert_iterator<It, Converter>,
+ typename Converter::output_type,
                 std::bidirectional_iterator_tag,
- const typename Pipe::output_type
+ const typename Converter::output_type
>
 {
     BOOST_CONCEPT_ASSERT((InputIterator<It>));
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<Converter>));
     
- BOOST_CONCEPT_ASSERT((Convertible<typename InputIterator<It>::value_type, typename Pipe::input_type>));
+ BOOST_CONCEPT_ASSERT((Convertible<typename InputIterator<It>::value_type, typename Converter::input_type>));
     
- pipe_iterator() {} // singular
+ convert_iterator() {} // singular
     
- pipe_iterator(It begin_, It end_, It pos_, Pipe p_) : pos(pos_), begin(begin_), end(end_), index(0), p(p_)
+ convert_iterator(It begin_, It end_, It pos_, Converter p_) : pos(pos_), begin(begin_), end(end_), index(0), p(p_)
         {
                 if(pos != end)
         {
- std::pair<It, typename detail::pipe_output_storage<Pipe>::output_iterator> pair =
+ std::pair<It, typename detail::convert_output_storage<Converter>::output_iterator> pair =
                 p.ltr(pos, end, values.out());
             next_pos = pair.first;
             values.update(pair.second);
@@ -124,7 +124,7 @@
         }
 
 private:
- typedef typename Pipe::output_type T;
+ typedef typename Converter::output_type T;
         friend class boost::iterator_core_access;
 
         T dereference() const
@@ -143,7 +143,7 @@
                         pos = next_pos;
                         if(pos != end)
             {
- std::pair<It, typename detail::pipe_output_storage<Pipe>::output_iterator> pair =
+ std::pair<It, typename detail::convert_output_storage<Converter>::output_iterator> pair =
                                     p.ltr(pos, end, values.out());
                 next_pos = pair.first;
                 values.update(pair.second);
@@ -164,7 +164,7 @@
                 {
                         next_pos = pos;
             
- std::pair<It, typename detail::pipe_output_storage<Pipe>::output_iterator> pair =
+ std::pair<It, typename detail::convert_output_storage<Converter>::output_iterator> pair =
                 p.rtl(begin, pos, values.out());
             pos = pair.first;
             values.update(pair.second);
@@ -173,7 +173,7 @@
                 }
         }
         
- bool equal(const pipe_iterator& other) const
+ bool equal(const convert_iterator& other) const
         {
                 return pos == other.pos && index == other.index;
         }
@@ -185,28 +185,28 @@
         It end;
         size_t index;
         
- Pipe p;
+ Converter p;
         
- detail::pipe_output_storage<Pipe> values;
+ detail::convert_output_storage<Converter> values;
 };
 
 /** Output Iterator adapter that wraps an output iterator to make one
  * that will convert its output before pushing it to the wrapped iterator. */
-template<typename OutputIterator, typename OneManyPipe>
-struct pipe_output_iterator
+template<typename OutputIterator, typename OneManyConverter>
+struct convert_output_iterator
 {
- BOOST_CONCEPT_ASSERT((OutputIteratorConcept<OutputIterator, typename OneManyPipe::output_type>));
- BOOST_CONCEPT_ASSERT((OneManyPipeConcept<OneManyPipe>));
+ BOOST_CONCEPT_ASSERT((OutputIteratorConcept<OutputIterator, typename OneManyConverter::output_type>));
+ BOOST_CONCEPT_ASSERT((OneManyConverterConcept<OneManyConverter>));
     
     typedef void difference_type;
     typedef void value_type;
- typedef pipe_output_iterator<OutputIterator, OneManyPipe>* pointer;
- typedef pipe_output_iterator<OutputIterator, OneManyPipe>& reference;
+ typedef convert_output_iterator<OutputIterator, OneManyConverter>* pointer;
+ typedef convert_output_iterator<OutputIterator, OneManyConverter>& reference;
     typedef std::output_iterator_tag iterator_category;
 
- pipe_output_iterator() {} // singular
+ convert_output_iterator() {} // singular
     
- pipe_output_iterator(OutputIterator pos_, OneManyPipe p_) : pos(pos_), p(p_)
+ convert_output_iterator(OutputIterator pos_, OneManyConverter p_) : pos(pos_), p(p_)
         {
         }
         
@@ -215,17 +215,17 @@
                 return pos;
         }
         
- const pipe_output_iterator& operator*() const
+ const convert_output_iterator& operator*() const
         {
                 return *this;
         }
         
- pipe_output_iterator& operator++()
+ convert_output_iterator& operator++()
         {
                 return *this;
         }
         
- pipe_output_iterator& operator++(int)
+ convert_output_iterator& operator++(int)
         {
                 return *this;
         }
@@ -236,19 +236,19 @@
                 pos = p(val, pos);
         }
     
- bool operator==(const pipe_output_iterator& other) const
+ bool operator==(const convert_output_iterator& other) const
     {
         return pos == other.pos;
     }
     
- bool operator!=(const pipe_output_iterator& other) const
+ bool operator!=(const convert_output_iterator& other) const
     {
         return pos != other.pos;
     }
         
 private:
         mutable OutputIterator pos;
- mutable OneManyPipe p;
+ mutable OneManyConverter p;
 };
 
 } // namespace boost

Copied: sandbox/SOC/2009/unicode/boost/iterator/converter_concept.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/iterator/pipe_concept.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/iterator/pipe_concept.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/iterator/converter_concept.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -9,18 +9,18 @@
 namespace boost
 {
 
-/** Concept checking class for the \c Pipe concept */
+/** Concept checking class for the \c Converter concept */
 template<typename X>
-struct PipeConcept : DefaultConstructible<X>, CopyConstructible<X>
+struct ConverterConcept : DefaultConstructible<X>, CopyConstructible<X>
 {
     typedef typename X::input_type input_type;
     typedef typename X::output_type output_type;
     
- BOOST_CONCEPT_USAGE(PipeConcept)
+ BOOST_CONCEPT_USAGE(ConverterConcept)
     {
- X pipe;
- p = pipe.ltr(begin, end, out);
- p = pipe.rtl(begin, end, out);
+ X convert;
+ p = convert.ltr(begin, end, out);
+ p = convert.rtl(begin, end, out);
     }
     
 private:
@@ -33,21 +33,21 @@
     std::pair<in_type, out_type> p;
 };
 
-/** Concept checking class for the \c OneManyPipe concept */
+/** Concept checking class for the \c OneManyConverter concept */
 template<typename X>
-struct OneManyPipeConcept : PipeConcept<X>
+struct OneManyConverterConcept : ConverterConcept<X>
 {
     
- BOOST_CONCEPT_USAGE(OneManyPipeConcept)
+ BOOST_CONCEPT_USAGE(OneManyConverterConcept)
     {
- X pipe;
- out = pipe(in, out);
+ X convert;
+ out = convert(in, out);
     }
     
 private:
- typedef output_iterator_archetype<typename PipeConcept<X>::output_type> out_type;
+ typedef output_iterator_archetype<typename ConverterConcept<X>::output_type> out_type;
     
- typename PipeConcept<X>::input_type in;
+ typename ConverterConcept<X>::input_type in;
     out_type out;
 };
 

Deleted: sandbox/SOC/2009/unicode/boost/iterator/pipe_concept.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/iterator/pipe_concept.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,56 +0,0 @@
-#ifndef BOOST_ITERATOR_PIPE_CONCEPT_HPP
-#define BOOST_ITERATOR_PIPE_CONCEPT_HPP
-
-#include <boost/concept_archetype.hpp>
-#include <boost/concept_check.hpp>
-
-#include <utility>
-
-namespace boost
-{
-
-/** Concept checking class for the \c Pipe concept */
-template<typename X>
-struct PipeConcept : DefaultConstructible<X>, CopyConstructible<X>
-{
- typedef typename X::input_type input_type;
- typedef typename X::output_type output_type;
-
- BOOST_CONCEPT_USAGE(PipeConcept)
- {
- X pipe;
- p = pipe.ltr(begin, end, out);
- p = pipe.rtl(begin, end, out);
- }
-
-private:
- typedef bidirectional_iterator_archetype<input_type> in_type;
- typedef output_iterator_archetype<output_type> out_type;
-
- in_type begin;
- in_type end;
- out_type out;
- std::pair<in_type, out_type> p;
-};
-
-/** Concept checking class for the \c OneManyPipe concept */
-template<typename X>
-struct OneManyPipeConcept : PipeConcept<X>
-{
-
- BOOST_CONCEPT_USAGE(OneManyPipeConcept)
- {
- X pipe;
- out = pipe(in, out);
- }
-
-private:
- typedef output_iterator_archetype<typename PipeConcept<X>::output_type> out_type;
-
- typename PipeConcept<X>::input_type in;
- out_type out;
-};
-
-} // namespace boost
-
-#endif

Deleted: sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,375 +0,0 @@
-#ifndef BOOST_ITERATOR_PIPE_ITERATOR_HPP
-#define BOOST_ITERATOR_PIPE_ITERATOR_HPP
-
-#include <boost/assert.hpp>
-#include <utility>
-
-#include <boost/range.hpp>
-#include <boost/mpl/int.hpp>
-#include <boost/mpl/times.hpp>
-#include <boost/tuple/tuple.hpp>
-
-#include <boost/concept/requires.hpp>
-#include <boost/range/concepts.hpp>
-
-#include <boost/iterator/pipe_iterator_fwd.hpp>
-
-#include <boost/type_traits.hpp>
-#include <boost/mpl/logical.hpp>
-#include <boost/utility/enable_if.hpp>
-
-#include <boost/mpl/assert.hpp>
-#include <boost/mpl/equal_to.hpp>
-
-namespace boost
-{
-
-/** CRTP Utility to define a \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly. */
-template<typename OneManyPipe>
-struct one_many_pipe
-{
- template<typename In, typename Out>
- std::pair<In, Out>
- ltr(In begin, In end, Out out)
- {
- BOOST_ASSERT(begin != end);
-
- out = static_cast<OneManyPipe&>(*this)(*begin, out);
- return std::make_pair(++begin, out);
- }
-
- template<typename In, typename Out>
- std::pair<In, Out>
- rtl(In begin, In end, Out out)
- {
- BOOST_ASSERT(begin != end);
-
- out = static_cast<OneManyPipe&>(*this)(*--end, out);
- return std::make_pair(end, out);
- }
-};
-
-/* TODO: Make it work for types that don't expose max_output */
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * constructed from two models of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * and that applies one after the other.
- *
- * The second pipe must require less input than the output of the first per
- * step for it to work. */
-template<typename P1, typename P2>
-struct multi_pipe
-{
- BOOST_CONCEPT_ASSERT((PipeConcept<P1>));
- BOOST_CONCEPT_ASSERT((PipeConcept<P2>));
-
- BOOST_CONCEPT_ASSERT((Convertible<typename P1::output_type, typename P2::input_type>));
-
- typedef typename P1::input_type input_type;
- typedef typename P2::output_type output_type;
-
- typedef typename mpl::times<
- typename P1::max_output,
- typename P2::max_output
- >::type max_output;
-
- multi_pipe() {}
- multi_pipe(P1 p1_, P2 p2_ = P2()) : p1(p1_), p2(p2_) {}
-
- template<typename In, typename Out>
- typename enable_if<
- mpl::and_<
- is_base_of<
- std::forward_iterator_tag,
- typename std::iterator_traits<Out>::iterator_category
- >,
- is_same<
- typename P1::output_type,
- typename P2::output_type
- >
- >,
- std::pair<In, Out>
- >::type
- ltr(In begin, In end, Out out)
- {
- Out b = out;
-
- std::pair<In, Out> pair = p1.ltr(begin, end, out);
- Out e = pair.second;
-
- do
- {
- tie(b, out) = p2.ltr(b, e, out);
- }
- while(b != e);
-
- return std::make_pair(pair.first, out);
- }
-
- template<typename In, typename Out>
- typename disable_if<
- mpl::and_<
- is_base_of<
- std::forward_iterator_tag,
- typename std::iterator_traits<Out>::iterator_category
- >,
- is_same<
- typename P1::output_type,
- typename P2::output_type
- >
- >,
- std::pair<In, Out>
- >::type
- ltr(In begin, In end, Out out)
- {
- typename P1::output_type buf[max_output::value];
- typename P1::output_type* b = buf;
-
- std::pair<In, typename P1::output_type*> pair = p1.ltr(begin, end, buf);
- typename P1::output_type* e = pair.second;
-
- do
- {
- tie(b, out) = p2.ltr(b, e, out);
- }
- while(b != e);
-
- return std::make_pair(pair.first, out);
- }
-
- template<typename In, typename Out>
- typename enable_if<
- mpl::and_<
- is_base_of<
- std::forward_iterator_tag,
- typename std::iterator_traits<Out>::iterator_category
- >,
- is_same<
- typename P1::output_type,
- typename P2::output_type
- >
- >,
- std::pair<In, Out>
- >::type rtl(In begin, In end, Out out)
- {
- Out b = out;
-
- std::pair<In, Out> pair = p1.rtl(begin, end, out);
- Out e = pair.second;
-
- do
- {
- tie(b, out) = p2.ltr(b, e, out);
- }
- while(b != e);
-
- return std::make_pair(pair.first, out);
- }
-
- template<typename In, typename Out>
- typename disable_if<
- mpl::and_<
- is_base_of<
- std::forward_iterator_tag,
- typename std::iterator_traits<Out>::iterator_category
- >,
- is_same<
- typename P1::output_type,
- typename P2::output_type
- >
- >,
- std::pair<In, Out>
- >::type rtl(In begin, In end, Out out)
- {
- typename P1::output_type buf[max_output::value];
- typename P1::output_type* b = buf;
-
- std::pair<In, typename P1::output_type*> pair = p1.rtl(begin, end, buf);
- typename P1::output_type* e = pair.second;
-
- do
- {
- tie(b, out) = p2.ltr(b, e, out);
- }
- while(b != e);
-
- return std::make_pair(pair.first, out);
- }
-
-private:
- P1 p1;
- P2 p2;
-};
-
-template<typename P1, typename P2>
-BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<P1>))
- ((PipeConcept<P2>))
- ((Convertible<typename P1::output_type, typename P2::input_type>)),
- (multi_pipe<P1, P2>)
-) make_multi_pipe(P1 p1, P2 p2)
-{
- return multi_pipe<P1, P2>(p1, p2);
-}
-
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * that adapts the elements another \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
- * sees with a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly, assuming its \c max_output is \c 1. */
-template<typename P1, typename P2>
-struct piped_pipe : P2
-{
- BOOST_CONCEPT_ASSERT((PipeConcept<P1>));
- BOOST_CONCEPT_ASSERT((PipeConcept<P2>));
-
- BOOST_CONCEPT_ASSERT((Convertible<typename P1::output_type, typename P2::input_type>));
-
- BOOST_MPL_ASSERT(( mpl::equal_to< typename P1::max_output, mpl::int_<1> > ));
-
- typedef typename P1::input_type input_type;
- typedef typename P2::output_type output_type;
-
- piped_pipe() {}
- piped_pipe(P1 p1_, P2 p2_ = P2()) : P2(p2_), p1(p1_) {}
-
- template<typename In, typename Out>
- std::pair<In, Out> ltr(In begin, In end, Out out)
- {
- std::pair<
- pipe_iterator<In, P1>,
- Out
- > pair = P2::ltr(
- make_pipe_iterator(begin, end, begin, p1),
- make_pipe_iterator(begin, end, end, p1),
- out
- );
-
- return std::make_pair(pair.first.base(), pair.second);
- }
-
- template<typename In, typename Out>
- std::pair<In, Out> rtl(In begin, In end, Out out)
- {
- std::pair<
- pipe_iterator<In, P1>,
- Out
- > pair = P2::rtl(
- make_pipe_iterator(begin, end, begin, p1),
- make_pipe_iterator(begin, end, end, p1),
- out
- );
- return std::make_pair(pair.first.base(), pair.second);
- }
-
-private:
- P1 p1;
-};
-
-template<typename P1, typename P2>
-BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<P1>))
- ((PipeConcept<P2>))
- ((Convertible<typename P1::output_type, typename P2::input_type>)),
- (piped_pipe<P1, P2>)
-) make_piped_pipe(P1 p1, P2 p2)
-{
- return piped_pipe<P1, P2>(p1, p2);
-}
-
-
-
-/** Model of \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly
- * that casts its input to its template parameter and writes it to its output. */
-template<typename T>
-struct cast_pipe : one_many_pipe< cast_pipe<T> >
-{
- typedef T input_type;
- typedef T output_type;
- typedef mpl::int_<1> max_output;
-
- template<typename U, typename Out>
- Out operator()(U in, Out out)
- {
- *out++ = static_cast<output_type>(in);
- return out;
- }
-};
-
-template<typename It, typename Pipe>
-BOOST_CONCEPT_REQUIRES(
- ((InputIterator<It>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename InputIterator<It>::value_type, typename Pipe::input_type>)),
- (pipe_iterator<It, Pipe>)
-) make_pipe_iterator(It begin, It end, It pos, Pipe p)
-{
- return pipe_iterator<It, Pipe>(begin, end, pos, p);
-}
-
-template<typename Range, typename Pipe>
-BOOST_CONCEPT_REQUIRES(
- ((SinglePassRangeConcept<Range>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename range_value<Range>::type, typename Pipe::input_type>)),
- (iterator_range<
- pipe_iterator<typename range_iterator<const Range>::type, Pipe>
- >)
-) piped(const Range& range, Pipe p)
-{
- return boost::make_iterator_range(
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::begin(range), p),
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::end(range), p)
- );
-}
-
-template<typename Range, typename Pipe>
-BOOST_CONCEPT_REQUIRES(
- ((SinglePassRangeConcept<Range>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename range_value<Range>::type, typename Pipe::input_type>)),
- (iterator_range<
- pipe_iterator<typename range_iterator<Range>::type, Pipe>
- >)
-) piped(Range& range, Pipe p)
-{
- return boost::make_iterator_range(
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::begin(range), p),
- make_pipe_iterator(boost::begin(range), boost::end(range), boost::end(range), p)
- );
-}
-
-template<typename Range, typename Pipe, typename OutputIterator>
-BOOST_CONCEPT_REQUIRES(
- ((SinglePassRangeConcept<Range>))
- ((PipeConcept<Pipe>))
- ((Convertible<typename range_value<Range>::type, typename Pipe::input_type>))
- ((OutputIteratorConcept<OutputIterator, typename Pipe::output_type>)),
- (OutputIterator)
-) pipe(const Range& range, Pipe pipe, OutputIterator out)
-{
- typedef typename boost::range_iterator<const Range>::type Iterator;
-
- Iterator begin = boost::begin(range);
- Iterator end = boost::end(range);
-
- while(begin != end)
- {
- std::pair<Iterator, OutputIterator> p = pipe.ltr(begin, end, out);
- begin = p.first;
- out = p.second;
- }
-
- return out;
-}
-
-template<typename OutputIterator, typename OneManyPipe>
-BOOST_CONCEPT_REQUIRES(
- ((OneManyPipeConcept<OneManyPipe>))
- ((OutputIteratorConcept<OutputIterator, typename OneManyPipe::output_type>)),
- (pipe_output_iterator<OutputIterator, OneManyPipe>)
-) piped_output(OutputIterator out, OneManyPipe p)
-{
- return pipe_output_iterator<OutputIterator, OneManyPipe>(out, p);
-}
-
-} // namespace boost
-
-#endif

Deleted: sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator_fwd.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/iterator/pipe_iterator_fwd.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,256 +0,0 @@
-#ifndef BOOST_ITERATOR_PIPE_ITERATOR_FWD_HPP
-#define BOOST_ITERATOR_PIPE_ITERATOR_FWD_HPP
-
-#include <boost/utility/enable_if.hpp>
-#include <boost/mpl/has_xxx.hpp>
-
-#include <boost/iterator/iterator_facade.hpp>
-#include <vector>
-
-#include <boost/iterator/pipe_concept.hpp>
-
-namespace boost
-{
-
-namespace detail
-{
- BOOST_MPL_HAS_XXX_TRAIT_DEF(max_output)
-
- template<typename P, typename Enable = void>
- struct pipe_output_storage;
-
- template<typename P>
- struct pipe_output_storage<P, typename ::boost::disable_if< has_max_output<P> >::type>
- {
- BOOST_CONCEPT_ASSERT((PipeConcept<P>));
-private:
- typedef std::vector<typename P::output_type> Values;
-public:
- typedef std::back_insert_iterator<Values> output_iterator;
-
- const typename P::output_type& operator[](size_t i) const
- {
- return values[i];
- }
-
- size_t last_index() const
- {
- return values.size() - 1;
- }
-
- output_iterator out()
- {
- values.clear();
- return std::back_inserter(values);
- }
-
- void update(output_iterator)
- {
- }
-
- private:
- Values values;
- };
-
- template<typename P>
- struct pipe_output_storage<P, typename boost::enable_if< has_max_output<P> >::type>
- {
- BOOST_CONCEPT_ASSERT((PipeConcept<P>));
-private:
- typedef typename P::output_type Value;
-public:
- typedef Value* output_iterator;
-
- const Value& operator[](size_t i) const
- {
- return values[i];
- }
-
- size_t last_index() const
- {
- return last;
- }
-
- output_iterator out()
- {
- return values;
- }
-
- void update(output_iterator u)
- {
- last = u - values - 1;
- }
-
- private:
- Value values[P::max_output::value];
- size_t last;
- };
-}
-
-/** Iterator adapter that wraps a range to make it appear like a converted
- * one, by converting it step-by-step as it is advanced. */
-template<typename It, typename Pipe>
-struct pipe_iterator
- : iterator_facade<
- pipe_iterator<It, Pipe>,
- typename Pipe::output_type,
- std::bidirectional_iterator_tag,
- const typename Pipe::output_type
- >
-{
- BOOST_CONCEPT_ASSERT((InputIterator<It>));
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
-
- BOOST_CONCEPT_ASSERT((Convertible<typename InputIterator<It>::value_type, typename Pipe::input_type>));
-
- pipe_iterator() {} // singular
-
- pipe_iterator(It begin_, It end_, It pos_, Pipe p_) : pos(pos_), begin(begin_), end(end_), index(0), p(p_)
- {
- if(pos != end)
- {
- std::pair<It, typename detail::pipe_output_storage<Pipe>::output_iterator> pair =
- p.ltr(pos, end, values.out());
- next_pos = pair.first;
- values.update(pair.second);
- }
- }
-
- It base() const
- {
- BOOST_CONCEPT_ASSERT((ForwardIterator<It>));
-
- return pos;
- }
-
-private:
- typedef typename Pipe::output_type T;
- friend class boost::iterator_core_access;
-
- T dereference() const
- {
- return values[index];
- }
-
- void increment()
- {
- if(index != values.last_index())
- {
- index++;
- }
- else
- {
- pos = next_pos;
- if(pos != end)
- {
- std::pair<It, typename detail::pipe_output_storage<Pipe>::output_iterator> pair =
- p.ltr(pos, end, values.out());
- next_pos = pair.first;
- values.update(pair.second);
- }
- index = 0;
- }
- }
-
- void decrement()
- {
- BOOST_CONCEPT_ASSERT((BidirectionalIterator<It>));
-
- if(index != 0)
- {
- index--;
- }
- else
- {
- next_pos = pos;
-
- std::pair<It, typename detail::pipe_output_storage<Pipe>::output_iterator> pair =
- p.rtl(begin, pos, values.out());
- pos = pair.first;
- values.update(pair.second);
-
- index = values.last_index();
- }
- }
-
- bool equal(const pipe_iterator& other) const
- {
- return pos == other.pos && index == other.index;
- }
-
- It pos;
- It next_pos;
-
- It begin;
- It end;
- size_t index;
-
- Pipe p;
-
- detail::pipe_output_storage<Pipe> values;
-};
-
-/** Output Iterator adapter that wraps an output iterator to make one
- * that will convert its output before pushing it to the wrapped iterator. */
-template<typename OutputIterator, typename OneManyPipe>
-struct pipe_output_iterator
-{
- BOOST_CONCEPT_ASSERT((OutputIteratorConcept<OutputIterator, typename OneManyPipe::output_type>));
- BOOST_CONCEPT_ASSERT((OneManyPipeConcept<OneManyPipe>));
-
- typedef void difference_type;
- typedef void value_type;
- typedef pipe_output_iterator<OutputIterator, OneManyPipe>* pointer;
- typedef pipe_output_iterator<OutputIterator, OneManyPipe>& reference;
- typedef std::output_iterator_tag iterator_category;
-
- pipe_output_iterator() {} // singular
-
- pipe_output_iterator(OutputIterator pos_, OneManyPipe p_) : pos(pos_), p(p_)
- {
- }
-
- OutputIterator base() const
- {
- return pos;
- }
-
- const pipe_output_iterator& operator*() const
- {
- return *this;
- }
-
- pipe_output_iterator& operator++()
- {
- return *this;
- }
-
- pipe_output_iterator& operator++(int)
- {
- return *this;
- }
-
- template<typename T>
- void operator=(T val) const
- {
- pos = p(val, pos);
- }
-
- bool operator==(const pipe_output_iterator& other) const
- {
- return pos == other.pos;
- }
-
- bool operator!=(const pipe_output_iterator& other) const
- {
- return pos != other.pos;
- }
-
-private:
- mutable OutputIterator pos;
- mutable OneManyPipe p;
-};
-
-} // namespace boost
-
-#endif

Copied: sandbox/SOC/2009/unicode/boost/iterator/segment_iterator.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/iterator/segment_iterator.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -5,9 +5,9 @@
 
 #include <boost/concept/requires.hpp>
 #include <boost/range/concepts.hpp>
-#include <boost/iterator/pipe_concept.hpp>
+#include <boost/iterator/converter_concept.hpp>
 
-#include <boost/iterator/consumer_iterator_fwd.hpp>
+#include <boost/iterator/segment_iterator_fwd.hpp>
 
 #include <boost/mpl/assert.hpp>
 #include <boost/mpl/equal_to.hpp>
@@ -16,55 +16,57 @@
 namespace boost
 {
 
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * constructed from a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly. */
-template<typename Pipe>
-struct pipe_consumer : private Pipe
+/** Model of \c \xmlonly<conceptname>Segmenter</conceptname>\endxmlonly
+ * constructed from a model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
+ * by ignoring its output. */
+template<typename Converter>
+struct converter_segmenter : private Converter
 {
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<Converter>));
     
- typedef typename Pipe::input_type input_type;
+ typedef typename Converter::input_type input_type;
     
- pipe_consumer() {} // singular
+ converter_segmenter() {} // singular
     
- pipe_consumer(Pipe p_) : Pipe(p_)
+ converter_segmenter(Converter p_) : Converter(p_)
     {
     }
     
     template<typename In>
     In ltr(In begin, In end)
     {
- return Pipe::ltr(begin, end, dummy_output_iterator()).first;
+ return Converter::ltr(begin, end, dummy_output_iterator()).first;
     }
     
     template<typename In>
     In rtl(In begin, In end)
     {
- return Pipe::rtl(begin, end, dummy_output_iterator()).first;
+ return Converter::rtl(begin, end, dummy_output_iterator()).first;
     }
 };
 
-template<typename Pipe>
+template<typename Converter>
 BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<Pipe>)),
- (pipe_consumer<Pipe>)
-) make_pipe_consumer(Pipe p)
+ ((ConverterConcept<Converter>)),
+ (converter_segmenter<Converter>)
+) make_converter_segmenter(Converter p)
 {
- return pipe_consumer<Pipe>(p);
+ return converter_segmenter<Converter>(p);
 }
 
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * constructed from a model of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly. */
+/** Model of \c \xmlonly<conceptname>Segmenter</conceptname>\endxmlonly
+ * constructed from a model of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly
+ * and that checks for boundaries until one is reached. */
 template<typename BoundaryChecker>
-struct boundary_consumer : private BoundaryChecker
+struct boundary_segmenter : private BoundaryChecker
 {
     BOOST_CONCEPT_ASSERT((BoundaryCheckerConcept<BoundaryChecker>));
     
     typedef typename BoundaryChecker::input_type input_type;
     
- boundary_consumer() {} // singular
+ boundary_segmenter() {} // singular
     
- boundary_consumer(BoundaryChecker b_) : BoundaryChecker(b_)
+ boundary_segmenter(BoundaryChecker b_) : BoundaryChecker(b_)
     {
     }
     
@@ -94,24 +96,24 @@
 template<typename BoundaryChecker>
 BOOST_CONCEPT_REQUIRES(
     ((BoundaryCheckerConcept<BoundaryChecker>)),
- (boundary_consumer<BoundaryChecker>)
-) make_boundary_consumer(BoundaryChecker b)
+ (boundary_segmenter<BoundaryChecker>)
+) make_boundary_segmenter(BoundaryChecker b)
 {
- return boundary_consumer<BoundaryChecker>(b);
+ return boundary_segmenter<BoundaryChecker>(b);
 }
 
 /** Model of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly
  * constructed from two models of \c \xmlonly<conceptname>BoundaryChecker</conceptname>\endxmlonly
- * with a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly applied in the middle. */
-template<typename B1, typename Pipe, typename B2>
+ * with a model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly applied in the middle. */
+template<typename B1, typename Converter, typename B2>
 struct multi_boundary
 {
     BOOST_CONCEPT_ASSERT((BoundaryCheckerConcept<B1>));
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<Converter>));
     BOOST_CONCEPT_ASSERT((BoundaryCheckerConcept<B2>));
     
- BOOST_CONCEPT_ASSERT((Convertible<typename B1::input_type, typename Pipe::input_type>));
- BOOST_CONCEPT_ASSERT((Convertible<typename Pipe::output_type, typename B2::input_type>));
+ BOOST_CONCEPT_ASSERT((Convertible<typename B1::input_type, typename Converter::input_type>));
+ BOOST_CONCEPT_ASSERT((Convertible<typename Converter::output_type, typename B2::input_type>));
     
     typedef typename B1::input_type input_type;
     
@@ -119,7 +121,7 @@
     {
     }
     
- multi_boundary(B1 b1_, Pipe p_, B2 b2_) : b1(b1_), p(p_), b2(b2_)
+ multi_boundary(B1 b1_, Converter p_, B2 b2_) : b1(b1_), p(p_), b2(b2_)
     {
     }
     
@@ -128,50 +130,50 @@
     {
         return b1(begin, end, pos)
            && b2(
- make_pipe_iterator(begin, end, begin, p),
- make_pipe_iterator(begin, end, end, p),
- make_pipe_iterator(begin, end, pos, p)
+ make_convert_iterator(begin, end, begin, p),
+ make_convert_iterator(begin, end, end, p),
+ make_convert_iterator(begin, end, pos, p)
                );
     }
     
 private:
     B1 b1;
- Pipe p;
+ Converter p;
     B2 b2;
 };
 
-template<typename B1, typename Pipe, typename B2>
+template<typename B1, typename Converter, typename B2>
 BOOST_CONCEPT_REQUIRES(
     ((BoundaryCheckerConcept<B1>))
- ((PipeConcept<Pipe>))
+ ((ConverterConcept<Converter>))
     ((BoundaryCheckerConcept<B2>))
- ((Convertible<typename B1::input_type, typename Pipe::input_type>))
- ((Convertible<typename Pipe::output_type, typename B2::input_type>)),
- (multi_boundary<B1, Pipe, B2>)
-) make_multi_boundary(B1 b1, Pipe p, B2 b2)
+ ((Convertible<typename B1::input_type, typename Converter::input_type>))
+ ((Convertible<typename Converter::output_type, typename B2::input_type>)),
+ (multi_boundary<B1, Converter, B2>)
+) make_multi_boundary(B1 b1, Converter p, B2 b2)
 {
- return multi_boundary<B1, Pipe, B2>(b1, p, b2);
+ return multi_boundary<B1, Converter, B2>(b1, p, b2);
 }
 
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * that adapts the elements another \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * sees with a model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly, assuming its \c max_output is \c 1. */
-template<typename Pipe, typename Consumer>
-struct piped_consumer
+/** Model of \c \xmlonly<conceptname>Segmenter</conceptname>\endxmlonly
+ * that adapts the elements another \c \xmlonly<conceptname>Segmenter</conceptname>\endxmlonly
+ * sees with a model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly, assuming its \c max_output is \c 1. */
+template<typename Converter, typename Segmenter>
+struct converted_segmenter
 {
- BOOST_CONCEPT_ASSERT((PipeConcept<Pipe>));
- BOOST_CONCEPT_ASSERT((ConsumerConcept<Consumer>));
- BOOST_CONCEPT_ASSERT((Convertible<typename Pipe::output_type, typename Consumer::input_type>));
+ BOOST_CONCEPT_ASSERT((ConverterConcept<Converter>));
+ BOOST_CONCEPT_ASSERT((SegmenterConcept<Segmenter>));
+ BOOST_CONCEPT_ASSERT((Convertible<typename Converter::output_type, typename Segmenter::input_type>));
     
- BOOST_MPL_ASSERT(( mpl::equal_to< typename Pipe::max_output, mpl::int_<1> > ));
+ BOOST_MPL_ASSERT(( mpl::equal_to< typename Converter::max_output, mpl::int_<1> > ));
     
- typedef typename Pipe::input_type input_type;
+ typedef typename Converter::input_type input_type;
     
- piped_consumer() // singular
+ converted_segmenter() // singular
     {
     }
     
- piped_consumer(Pipe p_, Consumer c_) : p(p_), c(c_)
+ converted_segmenter(Converter p_, Segmenter c_) : p(p_), c(c_)
     {
     }
     
@@ -179,8 +181,8 @@
     In ltr(In begin, In end)
     {
         return c.ltr(
- make_pipe_iterator(begin, end, begin, p),
- make_pipe_iterator(begin, end, end, p)
+ make_convert_iterator(begin, end, begin, p),
+ make_convert_iterator(begin, end, end, p)
         ).base();
     }
     
@@ -188,67 +190,67 @@
     In rtl(In begin, In end)
     {
         return c.rtl(
- make_pipe_iterator(begin, end, begin, p),
- make_pipe_iterator(begin, end, end, p)
+ make_convert_iterator(begin, end, begin, p),
+ make_convert_iterator(begin, end, end, p)
         ).base();
     }
     
 private:
- Pipe p;
- Consumer c;
+ Converter p;
+ Segmenter c;
 };
 
-template<typename Pipe, typename Consumer>
+template<typename Converter, typename Segmenter>
 BOOST_CONCEPT_REQUIRES(
- ((PipeConcept<Pipe>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename Pipe::output_type, typename Consumer::input_type>)),
- (piped_consumer<Pipe, Consumer>)
-) make_piped_consumer(Pipe p, Consumer c)
+ ((ConverterConcept<Converter>))
+ ((SegmenterConcept<Segmenter>))
+ ((Convertible<typename Converter::output_type, typename Segmenter::input_type>)),
+ (converted_segmenter<Converter, Segmenter>)
+) make_converted_segmenter(Converter p, Segmenter c)
 {
- return piped_consumer<Pipe, Consumer>(p, c);
+ return converted_segmenter<Converter, Segmenter>(p, c);
 }
 
-template<typename It, typename Consumer>
+template<typename It, typename Segmenter>
 BOOST_CONCEPT_REQUIRES(
     ((InputIterator<It>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename InputIterator<It>::value_type, typename Consumer::input_type>)),
- (consumer_iterator<It, Consumer>)
-) make_consumer_iterator(It begin, It end, It pos, Consumer c)
+ ((SegmenterConcept<Segmenter>))
+ ((Convertible<typename InputIterator<It>::value_type, typename Segmenter::input_type>)),
+ (segment_iterator<It, Segmenter>)
+) make_segment_iterator(It begin, It end, It pos, Segmenter c)
 {
- return consumer_iterator<It, Consumer>(begin, end, pos, c);
+ return segment_iterator<It, Segmenter>(begin, end, pos, c);
 }
 
-template<typename Range, typename Consumer>
+template<typename Range, typename Segmenter>
 BOOST_CONCEPT_REQUIRES(
     ((SinglePassRangeConcept<Range>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename range_value<const Range>::type, typename Consumer::input_type>)),
+ ((SegmenterConcept<Segmenter>))
+ ((Convertible<typename range_value<const Range>::type, typename Segmenter::input_type>)),
     (iterator_range<
- consumer_iterator<typename range_iterator<const Range>::type, Consumer>
+ segment_iterator<typename range_iterator<const Range>::type, Segmenter>
>)
-) consumed(const Range& range, Consumer c)
+) segmented(const Range& range, Segmenter c)
 {
         return boost::make_iterator_range(
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::begin(range), c),
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::end(range), c)
+ make_segment_iterator(boost::begin(range), boost::end(range), boost::begin(range), c),
+ make_segment_iterator(boost::begin(range), boost::end(range), boost::end(range), c)
         );
 }
 
-template<typename Range, typename Consumer>
+template<typename Range, typename Segmenter>
 BOOST_CONCEPT_REQUIRES(
     ((SinglePassRangeConcept<Range>))
- ((ConsumerConcept<Consumer>))
- ((Convertible<typename range_value<Range>::type, typename Consumer::input_type>)),
+ ((SegmenterConcept<Segmenter>))
+ ((Convertible<typename range_value<Range>::type, typename Segmenter::input_type>)),
     (iterator_range<
- consumer_iterator<typename range_iterator<Range>::type, Consumer>
+ segment_iterator<typename range_iterator<Range>::type, Segmenter>
>)
-) consumed(Range& range, Consumer c)
+) segmented(Range& range, Segmenter c)
 {
         return boost::make_iterator_range(
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::begin(range), c),
- make_consumer_iterator(boost::begin(range), boost::end(range), boost::end(range), c)
+ make_segment_iterator(boost::begin(range), boost::end(range), boost::begin(range), c),
+ make_segment_iterator(boost::begin(range), boost::end(range), boost::end(range), c)
         );
 }
     

Copied: sandbox/SOC/2009/unicode/boost/iterator/segment_iterator_fwd.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator_fwd.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/iterator/consumer_iterator_fwd.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/iterator/segment_iterator_fwd.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -4,29 +4,29 @@
 #include <boost/iterator/iterator_facade.hpp>
 #include <boost/range.hpp>
 
-#include <boost/iterator/consumer_concept.hpp>
+#include <boost/iterator/segmenter_concept.hpp>
 
 namespace boost
 {
 
 /** Iterator adapter that wraps a range to make it appear like a range
- * of subranges, each subrange being a step of a \c Consumer invocation. */
-template<typename It, typename Consumer>
-struct consumer_iterator
+ * of subranges, each subrange being a step of a \c Segmenter invocation. */
+template<typename It, typename Segmenter>
+struct segment_iterator
         : iterator_facade<
- consumer_iterator<It, Consumer>,
+ segment_iterator<It, Segmenter>,
                 iterator_range<It>,
                 std::bidirectional_iterator_tag,
                 const iterator_range<It>
>
 {
     BOOST_CONCEPT_ASSERT((InputIterator<It>));
- BOOST_CONCEPT_ASSERT((ConsumerConcept<Consumer>));
- BOOST_CONCEPT_ASSERT((Convertible<typename InputIterator<It>::value_type, typename Consumer::input_type>));
+ BOOST_CONCEPT_ASSERT((SegmenterConcept<Segmenter>));
+ BOOST_CONCEPT_ASSERT((Convertible<typename InputIterator<It>::value_type, typename Segmenter::input_type>));
     
- consumer_iterator() {} // singular
+ segment_iterator() {} // singular
     
- consumer_iterator(It begin_, It end_, It pos_, Consumer c_) : pos(pos_), begin(begin_), end(end_), p(c_)
+ segment_iterator(It begin_, It end_, It pos_, Segmenter c_) : pos(pos_), begin(begin_), end(end_), p(c_)
         {
                 if(pos != end)
             next_pos = p.ltr(pos, end);
@@ -63,7 +63,7 @@
         pos = p.rtl(begin, pos);
         }
         
- bool equal(const consumer_iterator& other) const
+ bool equal(const segment_iterator& other) const
         {
                 return pos == other.pos;
         }
@@ -74,7 +74,7 @@
         It begin;
         It end;
         
- Consumer p;
+ Segmenter p;
 };
 
 } // namespace boost

Copied: sandbox/SOC/2009/unicode/boost/iterator/segmenter_concept.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/iterator/consumer_concept.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/iterator/consumer_concept.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/iterator/segmenter_concept.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -7,13 +7,13 @@
 namespace boost
 {
 
-/** Concept checking class for the \c Consumer concept */
+/** Concept checking class for the \c Segmenter concept */
 template<typename X>
-struct ConsumerConcept : DefaultConstructible<X>, CopyConstructible<X>
+struct SegmenterConcept : DefaultConstructible<X>, CopyConstructible<X>
 {
     typedef typename X::input_type input_type;
     
- BOOST_CONCEPT_USAGE(ConsumerConcept)
+ BOOST_CONCEPT_USAGE(SegmenterConcept)
     {
         X c;
         begin = c.ltr(begin, end);

Modified: sandbox/SOC/2009/unicode/boost/unicode/cat.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/cat.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/cat.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -52,7 +52,7 @@
 cat_limits(cv1 Range1 ref1 range1, cv2 Range2 ref2 range2) \
 { \
     iterator_range< \
- pipe_iterator< \
+ convert_iterator< \
             typename range_iterator<cv2 Range2>::type, \
             utf_decoder \
> \
@@ -62,7 +62,7 @@
     if(ucd::get_combining_class(ch) != 0) \
     { \
         iterator_range< \
- pipe_iterator< \
+ convert_iterator< \
                 typename range_iterator<cv1 Range1>::type, \
                 utf_decoder \
> \
@@ -94,7 +94,7 @@
 
 #ifdef BOOST_UNICODE_DOXYGEN_INVOKED
 /** INTERNAL ONLY */
-#define BOOST_UNICODE_COMPOSE_CONCAT_DEF(name, nf, pipe, n) \
+#define BOOST_UNICODE_COMPOSE_CONCAT_DEF(name, nf, convert, n) \
 /** Concatenates two ranges of UTF code units and puts the result in \c out.
    Throws \c std::out_of_range if the input or resulting strings are not stream-safe.
    \pre \c Range1 and \c Range2 are in Normalized Form nf, have the same value type and are non-empty.
@@ -102,8 +102,8 @@
 template<typename Range1, typename Range2, typename OutputIterator, typename... T> \
 OutputIterator name##_concat(const Range1& range1, const Range2& range2, OutputIterator out, const T&... args);
 #else
-#define BOOST_UNICODE_COMPOSE_CONCAT_DEF(name, nf, pipe, n) \
-BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_COMPOSE_CONCAT_DEF_A, (name)(pipe))
+#define BOOST_UNICODE_COMPOSE_CONCAT_DEF(name, nf, convert, n) \
+BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_COMPOSE_CONCAT_DEF_A, (name)(convert))
 #endif
 
 /** INTERNAL ONLY */
@@ -120,13 +120,13 @@
     t = cat_limits(range1, range2); \
      \
     out = copy(t.get<0>(), out); \
- out = pipe(boost::join(t.get<1>(), t.get<2>()), make_piped_pipe(utf_decoder(), BOOST_PP_SEQ_ELEM(1, seq)(BOOST_PP_ENUM_PARAMS(n, t))), utf_encoded_out<typename range_value<const Range1>::type>(out)).base(); \
+ out = convert(boost::join(t.get<1>(), t.get<2>()), make_converted_converter(utf_decoder(), BOOST_PP_SEQ_ELEM(1, seq)(BOOST_PP_ENUM_PARAMS(n, t))), utf_encoded_out<typename range_value<const Range1>::type>(out)).base(); \
     return copy(t.get<3>(), out); \
 }
 
 #ifdef BOOST_UNICODE_DOXYGEN_INVOKED
 /** INTERNAL ONLY */
-#define BOOST_UNICODE_COMPOSE_CONCATED_DEF(name, nf, pipe, n) \
+#define BOOST_UNICODE_COMPOSE_CONCATED_DEF(name, nf, convert, n) \
 /** Concatenates two ranges of UTF code units and returns the result as a lazily
    evaluated range.
    Throws \c std::out_of_range if the input or resulting strings are not stream-safe.
@@ -135,8 +135,8 @@
 template<typename Range1, typename Range2, typename... T> \
 detail::unspecified<void> name##_concated(const Range1& range1, const Range2& range2, const T&... args);
 #else
-#define BOOST_UNICODE_COMPOSE_CONCATED_DEF(name, nf, pipe, n) \
-BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_COMPOSE_CONCATED_DEF_A, (name)(pipe))
+#define BOOST_UNICODE_COMPOSE_CONCATED_DEF(name, nf, convert, n) \
+BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_COMPOSE_CONCATED_DEF_A, (name)(convert))
 #endif
 
 /** INTERNAL ONLY */
@@ -146,14 +146,14 @@
     sub_range<const Range1>, \
     joined_range< \
         iterator_range< \
- pipe_iterator< \
+ convert_iterator< \
                 joined_range< \
                     sub_range<const Range1>, \
                     sub_range<const Range2> \
>, \
- piped_pipe< \
+ converted_converter< \
                     utf_decoder, \
- multi_pipe< \
+ multi_converter< \
                         BOOST_PP_SEQ_ELEM(1, seq), \
                         utf_encoder<typename range_value<const Range1>::type> \
> \
@@ -174,11 +174,11 @@
      \
     return boost::join( \
         t.get<0>(), \
- boost::join(piped( \
+ boost::join(convertd( \
             boost::join(t.get<1>(), t.get<2>()), \
- make_piped_pipe( \
+ make_converted_converter( \
                 utf_decoder(), \
- make_multi_pipe( \
+ make_multi_converter( \
                     BOOST_PP_SEQ_ELEM(1, seq)(BOOST_PP_ENUM_PARAMS(n, t)), \
                     utf_encoder<typename range_value<const Range1>::type>() \
                 ) \
@@ -189,9 +189,9 @@
 }
 
 /** INTERNAL ONLY */
-#define BOOST_UNICODE_COMPOSE_CAT_DEF(name, nf, pipe, n) \
-BOOST_UNICODE_COMPOSE_CONCATED_DEF(name, nf, pipe, n) \
-BOOST_UNICODE_COMPOSE_CONCAT_DEF(name, nf, pipe, n)
+#define BOOST_UNICODE_COMPOSE_CAT_DEF(name, nf, convert, n) \
+BOOST_UNICODE_COMPOSE_CONCATED_DEF(name, nf, convert, n) \
+BOOST_UNICODE_COMPOSE_CONCAT_DEF(name, nf, convert, n)
 
 BOOST_UNICODE_COMPOSE_CAT_DEF(composed, C, normalizer, 1)
 BOOST_UNICODE_COMPOSE_CAT_DEF(decomposed, D, combine_sorter, 0)

Modified: sandbox/SOC/2009/unicode/boost/unicode/combining.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/combining.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/combining.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -2,7 +2,7 @@
 #define BOOST_UNICODE_COMBINING_HPP
 
 #include <boost/config.hpp>
-#include <boost/iterator/consumer_iterator.hpp>
+#include <boost/iterator/segment_iterator.hpp>
 #include <boost/cuchar.hpp>
 #include <algorithm>
 
@@ -78,8 +78,8 @@
 
 } // namespace detail
 
-/** Model of \c \xmlonly<conceptname>Consumer</conceptname>\endxmlonly
- * that consumes combining character sequences. */
+/** Model of \c \xmlonly<conceptname>Segmenter</conceptname>\endxmlonly
+ * that segments combining character sequences. */
 struct combiner
 {
     typedef char32 input_type;
@@ -114,7 +114,7 @@
     std::pair<In, Out> ltr(In begin, In end, Out out)
     {
         return combine_sort_impl(
- *make_consumer_iterator(begin, end, begin, combiner()),
+ *make_segment_iterator(begin, end, begin, combiner()),
             out
         );
     }
@@ -128,7 +128,7 @@
> p = combine_sort_impl(
             boost::adaptors::reverse(
                 *boost::prior(
- make_consumer_iterator(begin, end, end, combiner())
+ make_segment_iterator(begin, end, end, combiner())
                 )
             ),
             out
@@ -181,26 +181,26 @@
  * each subrange being a combining character sequence. */
 template<typename Range>
 iterator_range<
- consumer_iterator<typename range_iterator<Range>::type, combiner>
+ segment_iterator<typename range_iterator<Range>::type, combiner>
>
 combine_bounded(Range&& range);
 #else
 template<typename Range>
 iterator_range<
- consumer_iterator<typename range_iterator<const Range>::type, combiner>
+ segment_iterator<typename range_iterator<const Range>::type, combiner>
>
 combine_bounded(const Range& range)
 {
- return consumed(range, combiner());
+ return segmented(range, combiner());
 }
 
 template<typename Range>
 iterator_range<
- consumer_iterator<typename range_iterator<Range>::type, combiner>
+ segment_iterator<typename range_iterator<Range>::type, combiner>
>
 combine_bounded(Range& range)
 {
- return consumed(range, combiner());
+ return segmented(range, combiner());
 }
 #endif
     

Modified: sandbox/SOC/2009/unicode/boost/unicode/compose.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/compose.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/compose.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -2,7 +2,7 @@
 #define BOOST_UNICODE_COMPOSE_HPP
 
 #include <boost/unicode/compose_fwd.hpp>
-#include <boost/unicode/pipe_def.hpp>
+#include <boost/unicode/converter_def.hpp>
 
 namespace boost
 {

Modified: sandbox/SOC/2009/unicode/boost/unicode/compose_fwd.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/compose_fwd.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/compose_fwd.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -11,7 +11,7 @@
 #include <vector>
 
 #include <boost/detail/unspecified.hpp>
-#include <boost/iterator/pipe_iterator.hpp>
+#include <boost/iterator/convert_iterator.hpp>
 
 #include <boost/range/adaptor/reversed.hpp>
 
@@ -29,7 +29,7 @@
 #undef BOOST_UNICODE_OPTION
 #endif
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
  * that decomposes a combining character sequence, i.e. it transforms a combining
  * character sequence into its canonically ordered decomposed equivalent.
  * It applies UCD decompositions that match \c mask recursively as well as the Hangul decompositions
@@ -51,7 +51,7 @@
     std::pair<In, Out> ltr(In begin, In end, Out out)
     {
         return decompose_impl(
- *make_consumer_iterator(begin, end, begin, combiner()),
+ *make_segment_iterator(begin, end, begin, combiner()),
             out
         );
     }
@@ -67,7 +67,7 @@
> p = decompose_impl(
             boost::adaptors::reverse(
                 *boost::prior(
- make_consumer_iterator(begin, end, end, combiner())
+ make_segment_iterator(begin, end, end, combiner())
                 )
             ),
             out
@@ -237,7 +237,7 @@
     };
 }
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
  * that composes a sequence of code points, i.e. it converts a sequence
  * of code points into a single code point.
  * It applies UCD canonical compositions as well as the Hangul
@@ -347,10 +347,10 @@
     }
 };
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly
  * that decomposes using a mask and then recomposes canonically a
  * sequence of code points. */
-typedef boost::detail::unspecified< multi_pipe<decomposer, composer> >::type normalizer;
+typedef boost::detail::unspecified< multi_converter<decomposer, composer> >::type normalizer;
 
 } // namespace unicode
 } // namespace boost

Copied: sandbox/SOC/2009/unicode/boost/unicode/converter_def.hpp (from r63531, /sandbox/SOC/2009/unicode/boost/unicode/pipe_def.hpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/boost/unicode/pipe_def.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/converter_def.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -11,7 +11,7 @@
 
 #include <boost/detail/unspecified.hpp>
 
-#include <boost/iterator/pipe_iterator.hpp>
+#include <boost/iterator/convert_iterator.hpp>
 
 #ifdef BOOST_UNICODE_DOXYGEN_INVOKED
 /** INTERNAL ONLY */
@@ -26,7 +26,7 @@
 template<typename Range, typename OutputIterator BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
 OutputIterator text(const Range& range, OutputIterator out BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
 { \
- return pipe( \
+ return convert( \
         range, \
         BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t)), \
         out \
@@ -46,14 +46,14 @@
 #define BOOST_UNICODE_PIPE_LAZY_DEF(z, n, text) \
 template<typename Range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
 iterator_range< \
- pipe_iterator< \
+ convert_iterator< \
         typename range_iterator<const Range>::type, \
         unicode::BOOST_PP_CAT(text, r) \
> \
> \
 BOOST_PP_CAT(text, d)(const Range& range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
 { \
- return piped(range, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
+ return converted(range, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
 }
 #endif
 
@@ -64,14 +64,14 @@
 #define BOOST_UNICODE_PIPE_LAZY_2_DEF(z, n, text) \
 template<typename Range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
 iterator_range< \
- pipe_iterator< \
+ convert_iterator< \
         typename range_iterator<Range>::type, \
         unicode::BOOST_PP_CAT(text, r) \
> \
> \
 BOOST_PP_CAT(text, d)(Range& range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
 { \
- return piped(range, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
+ return converted(range, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
 }
 #endif
 
@@ -92,28 +92,28 @@
 #else
 #define BOOST_UNICODE_PIPE_OUTPUT_DEF(z, n, text) \
 template<typename OutputIterator BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
-pipe_output_iterator< \
+convert_output_iterator< \
     OutputIterator, \
     unicode::BOOST_PP_CAT(text, r) \
> BOOST_PP_CAT(text, d_out)(OutputIterator out BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
 { \
- return piped_output(out, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
+ return converted_output(out, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
 }
 #endif
 
-/** Defines helper functions for usage of a \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly.
+/** Defines helper functions for usage of a \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly.
  * Helper functions provide a pseudo-variadic interface where they forward all the extra arguments to
- * the constructor of the \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly.
- * \arg \c name Name of the type modelling the \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly.
+ * the constructor of the \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly.
+ * \arg \c name Name of the type modelling the \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly.
  * \arg \c n Maximum number of optional arguments. */
 #define BOOST_UNICODE_ONE_MANY_PIPE_DEF(name, n) \
 BOOST_UNICODE_PIPE_COMMON_DEF(name, n) \
 BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_PIPE_OUTPUT_DEF, name)
 
-/** Defines helper functions for usage of a \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly.
+/** Defines helper functions for usage of a \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly.
  * Helper functions provide a pseudo-variadic interface where they forward all the extra arguments to
- * the constructor of the \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly.
- * \arg \c name Name of the type modelling the \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly.
+ * the constructor of the \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly.
+ * \arg \c name Name of the type modelling the \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly.
  * \arg \c n Maximum number of optional arguments. */
 #define BOOST_UNICODE_PIPE_DEF(name, n) \
 BOOST_UNICODE_PIPE_COMMON_DEF(name, n)

Modified: sandbox/SOC/2009/unicode/boost/unicode/graphemes.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/graphemes.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/graphemes.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -5,7 +5,7 @@
 #include <boost/utility.hpp>
 #include <boost/detail/unspecified.hpp>
 
-#include <boost/iterator/consumer_iterator.hpp>
+#include <boost/iterator/segment_iterator.hpp>
 
 #include <boost/unicode/utf_codecs.hpp>
 
@@ -45,26 +45,26 @@
 #else
 template<typename Range>
 iterator_range<typename boost::detail::unspecified<
- consumer_iterator<
+ segment_iterator<
         typename range_iterator<const Range>::type,
- boundary_consumer<unicode::grapheme_boundary>
+ boundary_segmenter<unicode::grapheme_boundary>
>
>::type>
 grapheme_bounded(const Range& range)
 {
- return consumed(range, make_boundary_consumer(unicode::grapheme_boundary()));
+ return segmented(range, make_boundary_segmenter(unicode::grapheme_boundary()));
 }
 
 template<typename Range>
 iterator_range<typename boost::detail::unspecified<
- consumer_iterator<
+ segment_iterator<
         typename range_iterator<Range>::type,
- boundary_consumer<unicode::grapheme_boundary>
+ boundary_segmenter<unicode::grapheme_boundary>
>
>::type>
 grapheme_bounded(Range& range)
 {
- return consumed(range, make_boundary_consumer(unicode::grapheme_boundary()));
+ return segmented(range, make_boundary_segmenter(unicode::grapheme_boundary()));
 }
 #endif
 
@@ -87,42 +87,42 @@
 #define BOOST_UNICODE_GRAPHEME_BOUNDED_DEF(Name) \
 template<typename Range> \
 iterator_range<typename boost::detail::unspecified< \
- consumer_iterator< \
+ segment_iterator< \
         typename range_iterator<const Range>::type, \
- piped_consumer< \
+ converted_segmenter< \
             unicode::Name##_decoder, \
- boundary_consumer<unicode::grapheme_boundary> \
+ boundary_segmenter<unicode::grapheme_boundary> \
> \
> \
>::type> \
 Name##_grapheme_bounded(const Range& range) \
 { \
- return consumed( \
+ return segmented( \
         range, \
- make_piped_consumer( \
+ make_converted_segmenter( \
             unicode::Name##_decoder(), \
- make_boundary_consumer(unicode::grapheme_boundary()) \
+ make_boundary_segmenter(unicode::grapheme_boundary()) \
         ) \
     ); \
 } \
                                                                        \
 template<typename Range> \
 iterator_range<typename boost::detail::unspecified< \
- consumer_iterator< \
+ segment_iterator< \
         typename range_iterator<Range>::type, \
- piped_consumer< \
+ converted_segmenter< \
             unicode::Name##_decoder, \
- boundary_consumer<unicode::grapheme_boundary> \
+ boundary_segmenter<unicode::grapheme_boundary> \
> \
> \
>::type> \
 Name##_grapheme_bounded(Range& range) \
 { \
- return consumed( \
+ return segmented( \
         range, \
- make_piped_consumer( \
+ make_converted_segmenter( \
             unicode::Name##_decoder(), \
- make_boundary_consumer(unicode::grapheme_boundary()) \
+ make_boundary_segmenter(unicode::grapheme_boundary()) \
         ) \
     ); \
 } \

Modified: sandbox/SOC/2009/unicode/boost/unicode/hangul.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/hangul.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/hangul.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -7,7 +7,7 @@
 
 #include <boost/cuchar.hpp>
 #include <boost/mpl/int.hpp>
-#include <boost/iterator/pipe_iterator.hpp>
+#include <boost/iterator/convert_iterator.hpp>
 
 namespace boost
 {
@@ -27,11 +27,11 @@
     static const char32 SCount = LCount * NCount; // 11172
 }
 
-/** \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly that
+/** \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly that
  * transforms a single Hangul syllable (LV or LVT) into its decomposed
  * form since those decompositions are not part of the UCD.
  * Other code points are left unchanged. */
-struct hangul_decomposer : one_many_pipe<hangul_decomposer>
+struct hangul_decomposer : one_many_converter<hangul_decomposer>
 {
     typedef char32 input_type;
     typedef char32 output_type;
@@ -77,7 +77,7 @@
     
 };
 
-/** \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly that
+/** \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly that
  * transforms <L, V>, <L, V, T> and <LV, T> Hangul code points sequences into the
  * LV and LVT Hangul syllables, since those compositions are not part
  * of the UCD.

Deleted: sandbox/SOC/2009/unicode/boost/unicode/pipe_def.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/pipe_def.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,121 +0,0 @@
-#ifndef BOOST_UNICODE_PIPE_DEF_HPP
-#define BOOST_UNICODE_PIPE_DEF_HPP
-
-#include <boost/preprocessor/punctuation/comma_if.hpp>
-#include <boost/preprocessor/repetition/enum_params.hpp>
-#include <boost/preprocessor/repetition/enum_binary_params.hpp>
-#include <boost/preprocessor/repetition/repeat.hpp>
-#include <boost/preprocessor/tuple/elem.hpp>
-#include <boost/preprocessor/cat.hpp>
-#include <boost/preprocessor/arithmetic/inc.hpp>
-
-#include <boost/detail/unspecified.hpp>
-
-#include <boost/iterator/pipe_iterator.hpp>
-
-#ifdef BOOST_UNICODE_DOXYGEN_INVOKED
-/** INTERNAL ONLY */
-#define BOOST_UNICODE_PIPE_EAGER_DEF(z, n, text) \
-/** Eagerly evaluates \c unicode##::##text##r until the whole input
- range \c range has been treated, copying the result to \c out and
- returning the past-the-end output iterator. */ \
-template<typename Range, typename OutputIterator, typename... T> \
-OutputIterator text(const Range& range, OutputIterator out, const T&... args);
-#else
-#define BOOST_UNICODE_PIPE_EAGER_DEF(z, n, text) \
-template<typename Range, typename OutputIterator BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
-OutputIterator text(const Range& range, OutputIterator out BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
-{ \
- return pipe( \
- range, \
- BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t)), \
- out \
- ); \
-}
-#endif
-
-#ifdef BOOST_UNICODE_DOXYGEN_INVOKED
-/** INTERNAL ONLY */
-#define BOOST_UNICODE_PIPE_LAZY_DEF(z, n, text) \
-/** Lazily evalutes \c unicode::##text##r by returning a range
- adapter that wraps the range \c range and converts it step-by-step as
- the range is advanced. */ \
-template<typename Range, typename... T> \
-detail::unspecified<void> BOOST_PP_CAT(text, d)(Range&& range, const T&... args);
-#else
-#define BOOST_UNICODE_PIPE_LAZY_DEF(z, n, text) \
-template<typename Range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
-iterator_range< \
- pipe_iterator< \
- typename range_iterator<const Range>::type, \
- unicode::BOOST_PP_CAT(text, r) \
- > \
-> \
-BOOST_PP_CAT(text, d)(const Range& range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
-{ \
- return piped(range, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
-}
-#endif
-
-#ifdef BOOST_UNICODE_DOXYGEN_INVOKED
-/** INTERNAL ONLY */
-#define BOOST_UNICODE_PIPE_LAZY_2_DEF(z, n, text)
-#else
-#define BOOST_UNICODE_PIPE_LAZY_2_DEF(z, n, text) \
-template<typename Range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
-iterator_range< \
- pipe_iterator< \
- typename range_iterator<Range>::type, \
- unicode::BOOST_PP_CAT(text, r) \
- > \
-> \
-BOOST_PP_CAT(text, d)(Range& range BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
-{ \
- return piped(range, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
-}
-#endif
-
-/** INTERNAL ONLY */
-#define BOOST_UNICODE_PIPE_COMMON_DEF(name, n) \
-BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_PIPE_EAGER_DEF, name) \
-BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_PIPE_LAZY_DEF, name) \
-BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_PIPE_LAZY_2_DEF, name)
-
-#ifdef BOOST_UNICODE_DOXYGEN_INVOKED
-/** INTERNAL ONLY */
-#define BOOST_UNICODE_PIPE_OUTPUT_DEF(z, n, text) \
-/** Lazily evalutes \c unicode::##text##r by returning an output
- iterator that wraps \c out and converts every pushed element. */ \
-template<typename OutputIterator, typename... T> \
-detail::unspecified<void> \
-BOOST_PP_CAT(text, d_out)(OutputIterator out, const T&... args);
-#else
-#define BOOST_UNICODE_PIPE_OUTPUT_DEF(z, n, text) \
-template<typename OutputIterator BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_PARAMS(n, typename T)> \
-pipe_output_iterator< \
- OutputIterator, \
- unicode::BOOST_PP_CAT(text, r) \
-> BOOST_PP_CAT(text, d_out)(OutputIterator out BOOST_PP_COMMA_IF(n) BOOST_PP_ENUM_BINARY_PARAMS(n, const T, & t)) \
-{ \
- return piped_output(out, unicode::BOOST_PP_CAT(text, r)(BOOST_PP_ENUM_PARAMS(n, t))); \
-}
-#endif
-
-/** Defines helper functions for usage of a \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly.
- * Helper functions provide a pseudo-variadic interface where they forward all the extra arguments to
- * the constructor of the \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly.
- * \arg \c name Name of the type modelling the \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly.
- * \arg \c n Maximum number of optional arguments. */
-#define BOOST_UNICODE_ONE_MANY_PIPE_DEF(name, n) \
-BOOST_UNICODE_PIPE_COMMON_DEF(name, n) \
-BOOST_PP_REPEAT(BOOST_PP_INC(n), BOOST_UNICODE_PIPE_OUTPUT_DEF, name)
-
-/** Defines helper functions for usage of a \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly.
- * Helper functions provide a pseudo-variadic interface where they forward all the extra arguments to
- * the constructor of the \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly.
- * \arg \c name Name of the type modelling the \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly.
- * \arg \c n Maximum number of optional arguments. */
-#define BOOST_UNICODE_PIPE_DEF(name, n) \
-BOOST_UNICODE_PIPE_COMMON_DEF(name, n)
-
-#endif

Modified: sandbox/SOC/2009/unicode/boost/unicode/utf.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/utf.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/utf.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -2,10 +2,10 @@
 #define BOOST_UNICODE_UTF_HPP
 
 #include <boost/unicode/utf_codecs.hpp>
-#include <boost/iterator/pipe_iterator.hpp>
-#include <boost/iterator/consumer_iterator.hpp>
+#include <boost/iterator/convert_iterator.hpp>
+#include <boost/iterator/segment_iterator.hpp>
 
-#include <boost/unicode/pipe_def.hpp>
+#include <boost/unicode/converter_def.hpp>
 #include <boost/detail/unspecified.hpp>
 
 namespace boost
@@ -33,29 +33,29 @@
                                                                        \
 template<typename Range> \
 iterator_range<typename boost::detail::unspecified< \
- consumer_iterator< \
+ segment_iterator< \
         typename range_iterator<const Range>::type, \
- pipe_consumer<unicode::Name##_decoder> \
+ converter_segmenter<unicode::Name##_decoder> \
> \
>::type> Name##_bounded(const Range& range) \
 { \
- return consumed( \
+ return segmented( \
         range, \
- make_pipe_consumer(unicode::Name##_decoder()) \
+ make_converter_segmenter(unicode::Name##_decoder()) \
     ); \
 } \
                                                                        \
 template<typename Range> \
 iterator_range<typename boost::detail::unspecified< \
- consumer_iterator< \
+ segment_iterator< \
         typename range_iterator<Range>::type, \
- pipe_consumer<unicode::Name##_decoder> \
+ converter_segmenter<unicode::Name##_decoder> \
> \
>::type> Name##_bounded(Range& range) \
 { \
- return consumed( \
+ return segmented( \
         range, \
- make_pipe_consumer(unicode::Name##_decoder()) \
+ make_converter_segmenter(unicode::Name##_decoder()) \
     ); \
 }
 #endif
@@ -71,7 +71,7 @@
 template<typename ValueType, typename Range, typename OutputIterator>
 OutputIterator utf_encode(const Range& range, OutputIterator out)
 {
- return pipe(range, utf_encoder<ValueType>(), out);
+ return convert(range, utf_encoder<ValueType>(), out);
 }
 
 #ifdef BOOST_UNICODE_DOXYGEN_INVOKED
@@ -80,36 +80,36 @@
 #else
 template<typename ValueType, typename Range>
 iterator_range<
- pipe_iterator<
+ convert_iterator<
         typename range_iterator<const Range>::type,
         utf_encoder<ValueType>
>
> utf_encoded(const Range& range)
 {
- return piped(range, utf_encoder<ValueType>());
+ return converted(range, utf_encoder<ValueType>());
 }
 
 template<typename ValueType, typename Range>
 iterator_range<
- pipe_iterator<
+ convert_iterator<
         typename range_iterator<Range>::type,
         utf_encoder<ValueType>
>
> utf_encoded(Range& range)
 {
- return piped(range, utf_encoder<ValueType>());
+ return converted(range, utf_encoder<ValueType>());
 }
 #endif
 
 template<typename ValueType, typename OutputIterator>
 typename boost::detail::unspecified<
- pipe_output_iterator<
+ convert_output_iterator<
         OutputIterator,
         utf_encoder<ValueType>
>
>::type utf_encoded_out(OutputIterator out)
 {
- return piped_output(out, utf_encoder<ValueType>());
+ return converted_output(out, utf_encoder<ValueType>());
 }
 
 BOOST_UNICODE_ENCODER_DEF(latin1);

Modified: sandbox/SOC/2009/unicode/boost/unicode/utf_codecs.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/boost/unicode/utf_codecs.hpp (original)
+++ sandbox/SOC/2009/unicode/boost/unicode/utf_codecs.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -12,7 +12,7 @@
 
 #include <boost/unicode/surrogates.hpp>
 
-#include <boost/iterator/pipe_iterator.hpp>
+#include <boost/iterator/convert_iterator.hpp>
 #include <boost/type_traits/is_same.hpp>
 #include <boost/mpl/and.hpp>
 #include <boost/mpl/bool.hpp>
@@ -76,9 +76,9 @@
 
 } // namespace detail
 
-/** Model of \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly
  * that converts a code point to a sequence of UTF-16 code units. */
-struct u16_encoder : one_many_pipe<u16_encoder>
+struct u16_encoder : one_many_converter<u16_encoder>
 {
     typedef char32 input_type;
         typedef char16 output_type;
@@ -119,7 +119,7 @@
         }
 };
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly that
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly that
  * converts a sequence of UTF-16 code units into a single code point. */
 struct u16_decoder
 {
@@ -215,9 +215,9 @@
     }
 };
 
-/** Model of \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly
  * that converts a code point to a sequence of UTF-8 code units. */
-struct u8_encoder : one_many_pipe<u8_encoder>
+struct u8_encoder : one_many_converter<u8_encoder>
 {
     typedef char32 input_type;
         typedef char output_type;
@@ -257,7 +257,7 @@
         }
 };
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly that
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly that
  * converts a sequence of UTF-8 code units into a single code point. */
 struct u8_decoder
 {
@@ -439,7 +439,7 @@
         detail::is_u32<ValueType>
>::type>
     {
- typedef cast_pipe<char32> type;
+ typedef cast_converter<char32> type;
     };
     
     template<typename ValueType>
@@ -460,7 +460,7 @@
 
 } // namespace detail
 
-/** Model of \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly,
+/** Model of \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly,
  * either behaves like \c u16_encoder, \c u8_encoder or nothing
  * depending on the targeted element type \c ValueType. */
 template<typename ValueType>
@@ -468,7 +468,7 @@
 {
 };
 
-/** Model of \c \xmlonly<conceptname>Pipe</conceptname>\endxmlonly,
+/** Model of \c \xmlonly<conceptname>Converter</conceptname>\endxmlonly,
  * either behaves like \c u16_decoder, a \c u8_decoder or nothing depending on the
  * value type of the input range. */
 struct utf_decoder
@@ -491,7 +491,7 @@
>
>::type>
     {
- typedef cast_pipe<char32> type;
+ typedef cast_converter<char32> type;
     };
     
     template<typename Iterator>
@@ -587,9 +587,9 @@
 #endif
 };
 
-/** Model of \c \xmlonly<conceptname>OneManyPipe</conceptname>\endxmlonly
+/** Model of \c \xmlonly<conceptname>OneManyConverter</conceptname>\endxmlonly
  * that converts from UTF-32 to ISO-8859-1 alias latin-1. */
-typedef boost::detail::unspecified< cast_pipe<char> >::type latin1_encoder;
+typedef boost::detail::unspecified< cast_converter<char> >::type latin1_encoder;
 
 } // namespace unicode
 

Modified: sandbox/SOC/2009/unicode/libs/unicode/doc/Jamfile.v2
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/doc/Jamfile.v2 (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/doc/Jamfile.v2 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -44,7 +44,7 @@
 
 doxygen autodoc1
     :
- [ path.glob-tree ../../../boost/iterator : pipe_*.hpp consumer_*.hpp join_*.hpp any_*.hpp : .svn detail ]
+ [ path.glob-tree ../../../boost/iterator : convert*.hpp segment*.hpp any_*.hpp : .svn detail ]
         [ path.glob-tree ../../../boost/range : any_*.hpp : .svn detail ]
         
         :

Modified: sandbox/SOC/2009/unicode/libs/unicode/doc/autodoc1c.xml
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/doc/autodoc1c.xml (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/doc/autodoc1c.xml 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -2,9 +2,9 @@
 <library-reference xmlns:xi="http://www.w3.org/2001/XInclude" id="iterator_range_reference">
 <title>Iterator/Range reference</title>
 
-<xi:include href="concepts/Pipe.xml"/>
-<xi:include href="concepts/OneManyPipe.xml"/>
-<xi:include href="concepts/Consumer.xml"/>
+<xi:include href="concepts/Converter.xml"/>
+<xi:include href="concepts/OneManyConverter.xml"/>
+<xi:include href="concepts/Segmenter.xml"/>
 <xi:include href="concepts/BoundaryChecker.xml"/>
 
 <xi:include href="autodoc1.xml" xpointer="xpointer(/library-reference/header)"/>

Modified: sandbox/SOC/2009/unicode/libs/unicode/doc/users_manual.qbk
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/doc/users_manual.qbk (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/doc/users_manual.qbk 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -258,13 +258,13 @@
 
 [section The concepts behind this library]
 
-Two concepts are of utmost importance within this library, the [conceptref Consumer]
+Two concepts are of utmost importance within this library, the [conceptref Segmenter]
 concept, which is used for segmentation of text, and, more importantly,
-the [conceptref Pipe] concept, which is used for conversion, including
+the [conceptref Converter] concept, which is used for conversion, including
 transcoding and normalization.
 
-[heading Consumer]
-A model of the [conceptref Consumer] concept is a class that takes an
+[heading Segmenter]
+A model of the [conceptref Segmenter] concept is a class that takes an
 input range, specified as two iterators, and consumes it left-to-right
 or right-to-left, that is to say it returns an iterator with the new
 begin in the case of left-to-right consuming, and the new end in the case
@@ -275,9 +275,9 @@
 be provided in a symmetric way in order to implement bidirectional
 iteration.
 
-Here is an example of a consumer that consumes one element in a range
+Here is an example of a segmenter that consumes one element in a range
 of integers:
-``struct element_consumer
+``struct element_segmenter
 {
     typedef int input_type;
 
@@ -294,16 +294,16 @@
     }
 };``
 
-A model of the [conceptref Consumer] concept may then be used to segment
-a range. The [classref boost::consumer_iterator], eventually invoked
-by [funcref boost::consumed], can be used to exploit that concept to
+A model of the [conceptref Segmenter] concept may then be used to segment
+a range. The [classref boost::segment_iterator], eventually invoked
+by [funcref boost::segmented], can be used to exploit that concept to
 turn a range into a range of subranges.
 
 With the above example, the range would be converted into a range of
 subranges, each subrange being exactly one element.
 
-[heading Pipe]
-A model of the [conceptref Pipe] concept is a class that takes an input
+[heading Converter]
+A model of the [conceptref Converter] concept is a class that takes an input
 range, specified as two iterators, consumes it left-to-right
 or right-to-left, writes some elements to an output iterator, and returns
 the new begin in the case of left-to-right consuming or the new end
@@ -314,13 +314,13 @@
 but the output shall also be the same for a given consumed subrange,
 whatever the consuming direction.
 Furthermore, the output shall always be ordered left-to-right, even when
-applying the pipe right-to-left.
+applying the convert right-to-left.
 
-Here is an example of a pipe that converts two adjacent numbers into the
+Here is an example of a convert that converts two adjacent numbers into the
 two numbers reversed, in a range of integers that must have an
 even number of elements; indeed, for the two operations to be symmetric
 here, there is not really another way.
-``struct reverse2_pipe
+``struct reverse2_convert
 {
     typedef int input_type;
     typedef int output_type;
@@ -350,24 +350,24 @@
     }
 };``
 
-A model of the [conceptref Pipe] concept may then be used to perform
+A model of the [conceptref Converter] concept may then be used to perform
 a many-to-many conversion on a whole range, be it eagerly (by calling
-repeatly the pipe) or lazily (be evaluating it step by step as an
+repeatly the convert) or lazily (be evaluating it step by step as an
 iterator adapter is advanced).
 
-The [funcref boost::pipe] function provides the former, while the
-[funcref boost::piped] function which returns a range in terms of
-[classref boost::pipe_iterator] provides the latter.
+The [funcref boost::convert] function provides the former, while the
+[funcref boost::converted] function which returns a range in terms of
+[classref boost::convert_iterator] provides the latter.
 
-With the above example, a piped range [1, 2, 3, 4] would be converted
+With the above example, a convertd range [1, 2, 3, 4] would be converted
 to [2, 1, 4, 3].
 
-[heading OneManyPipe]
+[heading OneManyConverter]
 
-Additionally, there is a refinement of the [conceptref Pipe] concept named
-[conceptref OneManyPipe], where one element is converted to many.
+Additionally, there is a refinement of the [conceptref Converter] concept named
+[conceptref OneManyConverter], where one element is converted to many.
 
-This allows avoiding the consuming altogether so that the pipe can be
+This allows avoiding the consuming altogether so that the convert can be
 defined as a single function that takes a value, an output iterator,
 and returns it.
 
@@ -384,21 +384,21 @@
 
 [heading Conversion]
 Conversions can be applied in a variety of means, all generated from using
-the [conceptref Pipe] concept that performs one step of the conversion:
+the [conceptref Converter] concept that performs one step of the conversion:
 
 * Eager evaluation, with simply
-loops the =Pipe= until the whole input range has been treated.
+loops the =Converter= until the whole input range has been treated.
 * Lazy evaluation, where a new range is returned that wraps the input range
 and converts step-by-step as the range is advanced. The resulting range is
-however read-only. It is implemented in terms of [classref boost::pipe_iterator].
+however read-only. It is implemented in terms of [classref boost::convert_iterator].
 * Lazy output evaluation, where an output iterator is returned that wraps the output
-and converts every pushed element with a [conceptref OneManyPipe]. It is implemented in terms
-of [classref boost::pipe_output_iterator].
+and converts every pushed element with a [conceptref OneManyConverter]. It is implemented in terms
+of [classref boost::convert_output_iterator].
 
 The naming scheme of the utilities within the library reflect this; here is
 for example what is provided to convert UTF-32 to UTF-8:
 
-* [classref boost::unicode::u8_encoder] is a model of the =OneManyPipe= concept.
+* [classref boost::unicode::u8_encoder] is a model of the =OneManyConverter= concept.
 * [funcref boost::unicode::u8_encode] is an eager encoding algorithm.
 * [funcref boost::unicode::u8_encoded] returns a range adapter that does on-the-fly encoding.
 * [funcref boost::unicode::u8_encoded_out] returns an output iterator adapter that will encode its elements before forwarding them to the wrapped output iterator.
@@ -408,18 +408,18 @@
 This is because code points is what the library mainly deals with, and UTF-32 is a sequence of code points.]
 
 [heading Segmentation]
-Segmentations are expressed in terms of the [conceptref Consumer] concept, which is inherently
-very similar to the [conceptref Pipe] concept except it doesn't perform any kind of transformation,
+Segmentations are expressed in terms of the [conceptref Segmenter] concept, which is inherently
+very similar to the [conceptref Converter] concept except it doesn't perform any kind of transformation,
 it just reads part of the input.
-As a matter of fact, a =Pipe= can be converted to =Consumer= using [classref boost::pipe_consumer].
+As a matter of fact, a =Converter= can be converted to =Segmenter= using [classref boost::converter_segmenter].
 
-Segmentation may be done either by using the appropriate =Consumer= directly, or by using the
-[classref boost::consumer_iterator] template to adapt the range into a
+Segmentation may be done either by using the appropriate =Segmenter= directly, or by using the
+[classref boost::segment_iterator] template to adapt the range into a
 read-only range of subranges.
 
 Additionally, the [conceptref BoundaryChecker] concept may prove useful to tell whether
-a segment starts at a given position; a =Consumer= may also be defined
-in terms of it using [classref boost::boundary_consumer].
+a segment starts at a given position; a =Segmenter= may also be defined
+in terms of it using [classref boost::boundary_segmenter].
 
 The naming scheme is as follows:
 
@@ -462,7 +462,7 @@
 procedurally generated, allowing space to be saved.
 
 The library provides [classref boost::unicode::hangul_decomposer], a
-[conceptref OneManyPipe] to decompose Hangul syllables.
+[conceptref OneManyConverter] to decompose Hangul syllables.
 
 There are several types of decompositions, which are exposed by
 [funcref boost::unicode::ucd::get_decomposition_type], most importantly
@@ -471,7 +471,7 @@
 compatibility decomposition is obtained by applying the Hangul decompositions
 and all decompositions from the UCD.
 
-[classref boost::unicode::decomposer], model of [conceptref Pipe]
+[classref boost::unicode::decomposer], model of [conceptref Converter]
 allows to perform any decomposition that matches a certain mask, recursively,
 including Hangul ones (which are treated as canonical decompositions),
 and canonically orders combining sequences as well.
@@ -489,7 +489,7 @@
 compositions from their fully decomposed and canonically ordered form to
 identity composable sequences and apply the compositions.
 
-[classref boost::unicode::composer] is a [conceptref Pipe] that uses that
+[classref boost::unicode::composer] is a [conceptref Converter] that uses that
 tree as well as the Hangul compositions.
 
 [heading Normalization]
@@ -531,9 +531,9 @@
 
 Different approaches to do that are possible:
 
-* [conceptref Pipe]- or [conceptref Consumer]-based, you may simply run classic search algorithms, such as
+* [conceptref Converter]- or [conceptref Segmenter]-based, you may simply run classic search algorithms, such as
 the ones from Boost.StringAlgo, with ranges of the appropriate elements -- those elements being able
-to be ranges themselves (subranges returned by [classref boost::consumer_iterator] are =EqualityComparable=).
+to be ranges themselves (subranges returned by [classref boost::segment_iterator] are =EqualityComparable=).
 * [conceptref BoundaryChecker]-based, the classic algorithms are run, then false positives
 that don't lie on the right boundaries are discarded. This has the advantage of reducing conversion and
 iteration overhead in certain situations.
@@ -716,8 +716,8 @@
 there are also quite more efficient.
 
 
-[heading Pipe concept]
-Centralizing conversion into a single [conceptref Pipe] model allows
+[heading Converter concept]
+Centralizing conversion into a single [conceptref Converter] model allows
 eager and lazy variants of evaluation to be possible for any conversion
 facility.
 
@@ -739,11 +739,11 @@
 type.
 
 [heading Non-checked UTF conversion]
-The library only provides UTF conversion pipes that do extensive checking
+The library only provides UTF conversion converts that do extensive checking
 that the input is correct and that the end is not unexpectedly met.
 
 These could be avoided when it is known that the input is valid, and
-thus performance be increased. [classref boost::pipe_iterator] could as
+thus performance be increased. [classref boost::convert_iterator] could as
 well avoid storing the =begin= and =end= iterator in such cases.
 
 [heading Fast Normalization]

Modified: sandbox/SOC/2009/unicode/libs/unicode/example/search.cpp
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/example/search.cpp (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/example/search.cpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -33,8 +33,8 @@
     char search[] = "foo";
     BOOST_AUTO(search_bounded, unicode::utf_grapheme_bounded(boost::as_literal(search)));
     
-//` We perform the search using the ranges of graphemes, i.e. the [conceptref Consumer]-based approach:
- BOOST_AUTO(range_consumer, boost::algorithm::find_first(foo_bounded, search_bounded));
+//` We perform the search using the ranges of graphemes, i.e. the [conceptref Segmenter]-based approach:
+ BOOST_AUTO(range_segmenter, boost::algorithm::find_first(foo_bounded, search_bounded));
     
 //` We perform the search using the original range, but using an adapted Boost.StringAlgo Finder with the relevant [conceptref BoundaryChecker]:
     BOOST_AUTO(finder,
@@ -46,8 +46,8 @@
     boost::iterator_range<char*> range_boundary = boost::algorithm::find(foo, finder);
     
 //` We now display the resulting matches, which should both be pointing to the second occurrence, with their positions within the original UTF-8 string:
- std::cout << "[" << std::distance(boost::begin(foo), range_consumer.begin().base()) << ", " << std::distance(boost::begin(foo), range_consumer.end().base()) << "] ";
- std::cout << range_consumer << std::endl;
+ std::cout << "[" << std::distance(boost::begin(foo), range_segmenter.begin().base()) << ", " << std::distance(boost::begin(foo), range_segmenter.end().base()) << "] ";
+ std::cout << range_segmenter << std::endl;
     
     std::cout << "[" << std::distance(boost::begin(foo), range_boundary.begin()) << ", " << std::distance(boost::begin(foo), range_boundary.end()) << "] ";
     std::cout << range_boundary << std::endl;

Modified: sandbox/SOC/2009/unicode/libs/unicode/test/Jamfile.v2
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/test/Jamfile.v2 (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/test/Jamfile.v2 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -20,8 +20,8 @@
     ;
 
 test-suite iterator :
- [ run iterator/test_pipe.cpp ]
- [ run iterator/test_consumer.cpp ]
+ [ run iterator/test_convert.cpp ]
+ [ run iterator/test_segment.cpp ]
 ;
 
 test-suite unicode :

Deleted: sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_consumer.cpp
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_consumer.cpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,118 +0,0 @@
-#define BOOST_TEST_MODULE Consumer
-#include <boost/test/included/unit_test.hpp>
-#include <boost/test/test_case_template.hpp>
-#include <boost/mpl/list.hpp>
-
-#include <boost/iterator/consumer_iterator.hpp>
-#include <boost/range/distance.hpp>
-
-#include <boost/assert.hpp>
-
-#include <vector>
-#include <list>
-#include <iterator>
-
-struct increasing_consumer
-{
- typedef int input_type;
-
- increasing_consumer() : count(1)
- {
- }
-
- template<typename In>
- In ltr(In begin, In end)
- {
- BOOST_ASSERT(std::distance(begin, end) >= count);
-
- for(int i=0; i<count; i++)
- ++begin;
-
- if(begin != end)
- ++count;
- return begin;
- }
-
- template<typename In>
- In rtl(In begin, In end)
- {
- BOOST_ASSERT(std::distance(begin, end) >= count);
-
- for(int i=0; i<count; i++)
- --end;
-
- if(end != begin)
- --count;
- return end;
- }
-
- int count;
-};
-
-template<typename Range>
-void check_increasing_sequence(const Range& range, int acc)
-{
- for(
- typename boost::range_iterator<
- const Range
- >::type it = boost::begin(range);
- it != boost::end(range);
- ++it, ++acc
- )
- BOOST_CHECK_EQUAL(*it, acc);
-
-}
-
-BOOST_AUTO_TEST_CASE( increasing_test )
-{
- using boost::consumer_iterator;
- using boost::make_consumer_iterator;
-
- int data[] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
-
- consumer_iterator<int*, increasing_consumer> begin =
- make_consumer_iterator(data, data + sizeof data / sizeof data[0], data, increasing_consumer());
-
- consumer_iterator<int*, increasing_consumer> end =
- make_consumer_iterator(data, data + sizeof data / sizeof data[0], data + sizeof data / sizeof data[0], increasing_consumer());
-
- int count = 1;
- int acc = count;
- consumer_iterator<int*, increasing_consumer> it = begin;
- for(; it != end; ++it, acc += count, ++count)
- {
- BOOST_CHECK_EQUAL(boost::distance(*it), count);
- check_increasing_sequence(*it, acc);
- }
-
- --it;
- --count;
- acc -= count;
- for(;;)
- {
- BOOST_CHECK_EQUAL(boost::distance(*it), count);
- check_increasing_sequence(*it, acc);
-
- if(it == begin)
- break;
-
- --it;
- --count;
- acc -= count;
- }
-}
-
-typedef boost::mpl::list<
- int*,
- const int*,
- std::vector<int>::iterator,
- std::list<int>::iterator,
- std::istream_iterator<char, char>
-> instantiate_types;
-
-BOOST_AUTO_TEST_CASE_TEMPLATE( instantiate, T, instantiate_types )
-{
- boost::consumer_iterator<T, increasing_consumer>();
-}
-
-

Copied: sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_convert.cpp (from r63531, /sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_pipe.cpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_pipe.cpp (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_convert.cpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -1,9 +1,9 @@
-#define BOOST_TEST_MODULE Pipe
+#define BOOST_TEST_MODULE Converter
 #include <boost/test/included/unit_test.hpp>
 #include <boost/test/test_case_template.hpp>
 #include <boost/mpl/list.hpp>
 
-#include <boost/iterator/pipe_iterator.hpp>
+#include <boost/iterator/convert_iterator.hpp>
 #include <boost/range/distance.hpp>
 
 #include <boost/assert.hpp>
@@ -12,12 +12,12 @@
 #include <list>
 #include <iterator>
 
-struct increasing_pipe
+struct increasing_convert
 {
     typedef int input_type;
     typedef int output_type;
     
- increasing_pipe() : count(1)
+ increasing_convert() : count(1)
     {
     }
     
@@ -51,18 +51,18 @@
 
 BOOST_AUTO_TEST_CASE( increasing_test )
 {
- using boost::pipe_iterator;
- using boost::make_pipe_iterator;
+ using boost::convert_iterator;
+ using boost::make_convert_iterator;
     
     int data[] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
     
- pipe_iterator<int*, increasing_pipe> begin =
- make_pipe_iterator(data, data + sizeof data / sizeof data[0], data, increasing_pipe());
+ convert_iterator<int*, increasing_convert> begin =
+ make_convert_iterator(data, data + sizeof data / sizeof data[0], data, increasing_convert());
         
- pipe_iterator<int*, increasing_pipe> end =
- make_pipe_iterator(data, data + sizeof data / sizeof data[0], data + sizeof data / sizeof data[0], increasing_pipe());
+ convert_iterator<int*, increasing_convert> end =
+ make_convert_iterator(data, data + sizeof data / sizeof data[0], data + sizeof data / sizeof data[0], increasing_convert());
         
- pipe_iterator<int*, increasing_pipe> it = begin;
+ convert_iterator<int*, increasing_convert> it = begin;
     int count = 1;
     for(; it != end; ++count)
         for(int i=0; i<count; ++i, ++it)
@@ -93,5 +93,5 @@
 
 BOOST_AUTO_TEST_CASE_TEMPLATE( instantiate, T, instantiate_types )
 {
- boost::pipe_iterator<T, increasing_pipe>();
+ boost::convert_iterator<T, increasing_convert>();
 }

Deleted: sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_pipe.cpp
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_pipe.cpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
+++ (empty file)
@@ -1,97 +0,0 @@
-#define BOOST_TEST_MODULE Pipe
-#include <boost/test/included/unit_test.hpp>
-#include <boost/test/test_case_template.hpp>
-#include <boost/mpl/list.hpp>
-
-#include <boost/iterator/pipe_iterator.hpp>
-#include <boost/range/distance.hpp>
-
-#include <boost/assert.hpp>
-
-#include <vector>
-#include <list>
-#include <iterator>
-
-struct increasing_pipe
-{
- typedef int input_type;
- typedef int output_type;
-
- increasing_pipe() : count(1)
- {
- }
-
- template<typename In, typename Out>
- std::pair<In, Out> ltr(In begin, In end, Out out)
- {
- for(int i=0; i<count; i++)
- *out++ = *begin + i;
-
- if(++begin != end)
- ++count;
-
- return std::make_pair(begin, out);
- }
-
- template<typename In, typename Out>
- std::pair<In, Out> rtl(In begin, In end, Out out)
- {
- --end;
- for(int i=0; i<count; i++)
- *out++ = *end + i;
-
- if(end != begin)
- --count;
-
- return std::make_pair(end, out);
- }
-
- int count;
-};
-
-BOOST_AUTO_TEST_CASE( increasing_test )
-{
- using boost::pipe_iterator;
- using boost::make_pipe_iterator;
-
- int data[] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
-
- pipe_iterator<int*, increasing_pipe> begin =
- make_pipe_iterator(data, data + sizeof data / sizeof data[0], data, increasing_pipe());
-
- pipe_iterator<int*, increasing_pipe> end =
- make_pipe_iterator(data, data + sizeof data / sizeof data[0], data + sizeof data / sizeof data[0], increasing_pipe());
-
- pipe_iterator<int*, increasing_pipe> it = begin;
- int count = 1;
- for(; it != end; ++count)
- for(int i=0; i<count; ++i, ++it)
- BOOST_CHECK_EQUAL(*it, data[count-1]+i);
-
-
- --it;
- --count;
- for(;;)
- {
- for(int i=count-1; i>=0; --i, --it)
- BOOST_CHECK_EQUAL(*it, data[count-1]+i);
-
- if(it == begin)
- break;
-
- --count;
- }
-}
-
-typedef boost::mpl::list<
- int*,
- const int*,
- std::vector<int>::iterator,
- std::list<int>::iterator,
- std::istream_iterator<char, char>
-> instantiate_types;
-
-BOOST_AUTO_TEST_CASE_TEMPLATE( instantiate, T, instantiate_types )
-{
- boost::pipe_iterator<T, increasing_pipe>();
-}

Copied: sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_segment.cpp (from r63531, /sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_consumer.cpp)
==============================================================================
--- /sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_consumer.cpp (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/test/iterator/test_segment.cpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -1,9 +1,9 @@
-#define BOOST_TEST_MODULE Consumer
+#define BOOST_TEST_MODULE Segmenter
 #include <boost/test/included/unit_test.hpp>
 #include <boost/test/test_case_template.hpp>
 #include <boost/mpl/list.hpp>
 
-#include <boost/iterator/consumer_iterator.hpp>
+#include <boost/iterator/segment_iterator.hpp>
 #include <boost/range/distance.hpp>
 
 #include <boost/assert.hpp>
@@ -12,11 +12,11 @@
 #include <list>
 #include <iterator>
 
-struct increasing_consumer
+struct increasing_segmenter
 {
     typedef int input_type;
     
- increasing_consumer() : count(1)
+ increasing_segmenter() : count(1)
     {
     }
     
@@ -65,20 +65,20 @@
 
 BOOST_AUTO_TEST_CASE( increasing_test )
 {
- using boost::consumer_iterator;
- using boost::make_consumer_iterator;
+ using boost::segment_iterator;
+ using boost::make_segment_iterator;
     
     int data[] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
     
- consumer_iterator<int*, increasing_consumer> begin =
- make_consumer_iterator(data, data + sizeof data / sizeof data[0], data, increasing_consumer());
+ segment_iterator<int*, increasing_segmenter> begin =
+ make_segment_iterator(data, data + sizeof data / sizeof data[0], data, increasing_segmenter());
         
- consumer_iterator<int*, increasing_consumer> end =
- make_consumer_iterator(data, data + sizeof data / sizeof data[0], data + sizeof data / sizeof data[0], increasing_consumer());
+ segment_iterator<int*, increasing_segmenter> end =
+ make_segment_iterator(data, data + sizeof data / sizeof data[0], data + sizeof data / sizeof data[0], increasing_segmenter());
         
     int count = 1;
     int acc = count;
- consumer_iterator<int*, increasing_consumer> it = begin;
+ segment_iterator<int*, increasing_segmenter> it = begin;
     for(; it != end; ++it, acc += count, ++count)
     {
         BOOST_CHECK_EQUAL(boost::distance(*it), count);
@@ -112,7 +112,7 @@
 
 BOOST_AUTO_TEST_CASE_TEMPLATE( instantiate, T, instantiate_types )
 {
- boost::consumer_iterator<T, increasing_consumer>();
+ boost::segment_iterator<T, increasing_segmenter>();
 }
 
 

Modified: sandbox/SOC/2009/unicode/libs/unicode/test/unicode/range_test.hpp
==============================================================================
--- sandbox/SOC/2009/unicode/libs/unicode/test/unicode/range_test.hpp (original)
+++ sandbox/SOC/2009/unicode/libs/unicode/test/unicode/range_test.hpp 2010-07-02 19:00:38 EDT (Fri, 02 Jul 2010)
@@ -53,7 +53,7 @@
 )
 
 /* Checking in both directions allows to make sure the right-to-left
- * part of the pipe also works */
+ * part of the convert also works */
 #define CHECK_BI_EQUALS(range1, range2) \
 do { \
     using detail::reversed; \


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