pstade

PrevUpHomeNext

Merge Adaptors

merged
set_cap
set_cup
set_delta
set_minus

A Merge Adaptor is a Range Adaptor for sorted ranges.

Description

merged combines two sorted ranges into a single sorted range.

Header
  • <pstade/oven/merged.hpp>
Model of
Notation
  • less is regular(boost::lambda::_1 < boost::lambda::_2).
Valid expressions

Valid expression

Semantics

_rng1|merged(_rng2, _prd)

An up-to-Forward Constant Range which behaves as if it were made by merge(_rng1, _rng2, _prd).

_rng1|merged(_rng2)

_rng1|merged(_rng2, less)

Preconditions
  • _rng1 and _rng2 are Readable or Lvalue.
  • boost::range_reference<_typeof(_rng2)>::type is convertible to boost::range_reference<_typeof(_rng1)>::type without binding reference to rvalue.
  • _rng1 and _rng2 are sorted.
  • _prd is Assignable and Default Constructible.
  • _prd shall not modify referents.
Example
std::string A1("abbbfH");
std::string A2("ABbCDFFhh");
std::string AA("aAbbbBbCDfFFHhh");
BOOST_CHECK( equals(A1|merged(A2, &::lt_nocase), AA) );
See also
Description
Header
  • <pstade/oven/set_cap.hpp>
Model of
Valid expressions

Valid expression

Semantics

_rng1|set_cap(_rng2, _prd)

An up-to-Forward Constant Range which behaves as if it were made by set_intersection(_rng1, _rng2, _prd).

_rng1|set_cap(_rng2)

_rng1|set_cap(_rng2, less)

Preconditions
  • The preconditions of merged.
Example
See also
Description
Header
  • <pstade/oven/set_cup.hpp>
Model of
Valid expressions

Valid expression

Semantics

_rng1|set_cup(_rng2, _prd)

An up-to-Forward Constant Range which behaves as if it were made by set_union(_rng1, _rng2, _prd).

_rng1|set_cup(_rng2)

_rng1|set_cup(_rng2, less)

Preconditions
  • The preconditions of merged.
Example
See also
Description
Header
  • <pstade/oven/set_delta.hpp>
Model of
Valid expressions

Valid expression

Semantics

_rng1|set_delta(_rng2, _prd)

An up-to-Forward Constant Range which behaves as if it were made by set_symmetric_difference(_rng1, _rng2, _prd).

_rng1|set_delta(_rng2)

_rng1|set_delta(_rng2, less)

Preconditions
  • The preconditions of merged.
Example
See also
Description
Header
  • <pstade/oven/set_minus.hpp>
Model of
Valid expressions

Valid expression

Semantics

_rng1|set_minus(_rng2, _prd)

An up-to-Forward Constant Range which behaves as if it were made by set_difference(_rng1, _rng2, _prd).

_rng1|set_minus(_rng2)

_rng1|set_minus(_rng2, less)

Preconditions
  • The preconditions of merged.
Example
See also
Copyright 2005 -2007 Shunsuke Sogame

PrevUpHomeNext