3rdParty/boost/1.78.0/libs/iostreams/doc/functions/compose.html
composeGiven a Filter f and a Device d, we may construct a device c whose member functions are implemented by invoking the fundamental i/o operations read, write, etc. with f as the first argument and d as the second. Similarly, if we are given two filters f1 and f2, we may construct a third filter f3 whose member function templates are implemented by invoking the fundamental i/o operations read, write, etc., with first argument equal to f1 and second argument equal to the result of composing f2 with the provided Device.
The function template composite represents a Filter or Device which has been constructed in the above manner. The function template compose is an object generator which given a pair of components returns an appropriate instance of composite.
The mode of a composite is defined to provide a maximal subset of the common functionality of the two components. A composite is Closable, Flushable, Localizable and OptimallyBuffered.
namespaceboost {namespaceiostreams {template<typename[Filter](#composite_template_params),typename[FilterOrDevice](#composite_template_params)>class[composite](#composite){public:typedeftypename[char\_type\_of](../guide/traits.html#char_type)<Filter>::type char_type;typedefimplementation-definedmode;[composite](#composite_ctor)(constFilter& first, [const] FilterOrDevice& second);// Filter or Device member functions};template<typename[Filter](#compose_template_params),typename[FilterOrDevice](#compose_template_params)>[composite](#composite)<Filter, FilterOrDevice>[compose](#compose)(constFilter& first, [const] FilterOrDevice& second);
} } // End namespace boost::io
composite| | | | Filter | - | A model of Filter | | FilterOrDevice | - | A model of Filter or Device |
composite::compositecomposite(constFilter& first, [const] FilterOrDevice& second);
Constructs an instance of composite based on the given components. If FilterOrDevice is a stream or stream buffer type, the second parameter is a non-const reference; otherwise it is a const reference.
composecomposite(constFilter& first, [const] FilterOrDevice& second);
| | | | Filter | - | A model of Filter | | FilterOrDevice | - | A model of Filter or Device |
Returns an instance of an appropriate specialization of composite constructed from the given components. If FilterOrDevice is a stream or stream buffer type, the second parameter is a non-const reference; otherwise it is a const reference.
© Copyright 2008 CodeRage, LLC
© Copyright 2004-2007 Jonathan Turkanis
Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)