TPIE

v1.1rc1-6-g0c97303
tpie::pipelining::passive_sorter< T, pred_t > Class Template Reference

Pipelined sorter with push input and pull output. More...

#include <tpie/pipelining/sort.h>

Public Types

typedef T item_type
 Type of items sorted. More...
 
typedef merge_sorter
< item_type, true, pred_t > 
sorter_t
 Type of the merge sort implementation used. More...
 
typedef sorter_t::ptr sorterptr
 Smart pointer to sorter_t. More...
 
typedef
bits::sort_pull_output_t
< item_type, pred_t > 
output_t
 Type of pipe sorter output. More...
 

Public Member Functions

 passive_sorter (pred_t pred=pred_t())
 
pipe_end
< bits::passive_sorter_factory
< item_type, pred_t > > 
input ()
 Get the input push node. More...
 
pullpipe_begin
< bits::passive_sorter_factory_2
< item_type, pred_t > > 
output ()
 Get the output pull node. More...
 

Friends

class bits::passive_sorter_factory_2< T, pred_t >
 

Detailed Description

template<typename T, typename pred_t = std::less<T>>
class tpie::pipelining::passive_sorter< T, pred_t >

Pipelined sorter with push input and pull output.

Get the input pipe with input() and the output pullpipe with output(). input() must not be called after output().

Template Parameters
TThe type of item to sort
pred_tThe predicate (e.g. std::less<T>) indicating the predicate on which to order an item before another.

Definition at line 415 of file sort.h.

Member Typedef Documentation

template<typename T, typename pred_t = std::less<T>>
typedef T tpie::pipelining::passive_sorter< T, pred_t >::item_type

Type of items sorted.

Definition at line 484 of file sort.h.

template<typename T, typename pred_t = std::less<T>>
typedef bits::sort_pull_output_t<item_type, pred_t> tpie::pipelining::passive_sorter< T, pred_t >::output_t

Type of pipe sorter output.

Definition at line 490 of file sort.h.

template<typename T, typename pred_t = std::less<T>>
typedef merge_sorter<item_type, true, pred_t> tpie::pipelining::passive_sorter< T, pred_t >::sorter_t

Type of the merge sort implementation used.

Definition at line 486 of file sort.h.

template<typename T, typename pred_t = std::less<T>>
typedef sorter_t::ptr tpie::pipelining::passive_sorter< T, pred_t >::sorterptr

Smart pointer to sorter_t.

Definition at line 488 of file sort.h.

Member Function Documentation

template<typename T, typename pred_t = std::less<T>>
pipe_end<bits::passive_sorter_factory<item_type, pred_t> > tpie::pipelining::passive_sorter< T, pred_t >::input ( )
inline

Get the input push node.

Definition at line 502 of file sort.h.

502  {
503  return bits::passive_sorter_factory<item_type, pred_t>(m_output);
504  }
template<typename T, typename pred_t = std::less<T>>
pullpipe_begin<bits::passive_sorter_factory_2<item_type, pred_t> > tpie::pipelining::passive_sorter< T, pred_t >::output ( )
inline

Get the output pull node.

Definition at line 509 of file sort.h.

509  {
510  return bits::passive_sorter_factory_2<item_type, pred_t>(*this);
511  }

The documentation for this class was generated from the following file: