STXXL
1.4.1
|
All sorted runs of a sort operation.
Definition at line 37 of file sorted_runs.h.
Public Types | |
typedef trigger_entry_type::block_type | block_type |
typedef CompareType | cmp_type |
typedef std::vector< run_type > ::size_type | run_index_type |
typedef std::vector < trigger_entry_type > | run_type |
typedef stxxl::external_size_type | size_type |
typedef std::vector< value_type > | small_run_type |
typedef TriggerEntryType | trigger_entry_type |
typedef block_type::value_type | value_type |
may differ from trigger_entry_type::value_type More... | |
Public Member Functions | |
sorted_runs () | |
~sorted_runs () | |
void | add_run (const run_type &run, size_type run_size) |
Add a new run with given number of elements. More... | |
void | clear () |
Clear the internal state of the object: release all runs and reset. More... | |
void | swap (sorted_runs &b) |
Swap contents with another object. This is used by the recursive merger to swap in a sorted_runs object with fewer runs. More... | |
![]() | |
counted_object () | |
new objects have zero reference count More... | |
counted_object (const counted_object &) | |
coping still creates a new object with zero reference count More... | |
~counted_object () | |
bool | dec_reference () const |
Call whenever resetting (i.e. overwriting) a pointer to the object. IMPORTANT: In case of self-assignment, call AFTER inc_reference(). More... | |
unsigned_type | get_reference_count () const |
Return the number of references to this object (for debugging) More... | |
void | inc_reference () const |
Call whenever setting a pointer to the object. More... | |
counted_object & | operator= (const counted_object &) |
assignment operator, leaves pointers unchanged More... | |
bool | unique () const |
Test if the counted_object is referenced by only one counting_ptr. More... | |
Public Attributes | |
size_type | elements |
total number of elements in all runs More... | |
std::vector< run_type > | runs |
vector of runs (containing vectors of block ids) More... | |
std::vector< size_type > | runs_sizes |
vector of the number of elements in each individual run More... | |
small_run_type | small_run |
Small sort optimization: More... | |
Private Member Functions | |
void | deallocate_blocks () |
Deallocates the blocks which the runs occupy. More... | |
![]() | |
noncopyable () | |
typedef trigger_entry_type::block_type stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::block_type |
Definition at line 40 of file sorted_runs.h.
typedef CompareType stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::cmp_type |
Definition at line 48 of file sorted_runs.h.
typedef std::vector<run_type>::size_type stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::run_index_type |
Definition at line 46 of file sorted_runs.h.
typedef std::vector<trigger_entry_type> stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::run_type |
Definition at line 43 of file sorted_runs.h.
typedef stxxl::external_size_type stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::size_type |
Definition at line 45 of file sorted_runs.h.
typedef std::vector<value_type> stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::small_run_type |
Definition at line 44 of file sorted_runs.h.
typedef TriggerEntryType stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::trigger_entry_type |
Definition at line 39 of file sorted_runs.h.
typedef block_type::value_type stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::value_type |
may differ from trigger_entry_type::value_type
Definition at line 42 of file sorted_runs.h.
|
inline |
Definition at line 66 of file sorted_runs.h.
|
inline |
Definition at line 70 of file sorted_runs.h.
|
inline |
Add a new run with given number of elements.
Definition at line 87 of file sorted_runs.h.
|
inline |
Clear the internal state of the object: release all runs and reset.
Definition at line 76 of file sorted_runs.h.
Referenced by stxxl::stream::runs_creator< use_push< ValueType >, CompareType, BlockSize, AllocStr >::clear().
|
inlineprivate |
Deallocates the blocks which the runs occupy.
Definition at line 110 of file sorted_runs.h.
References stxxl::block_manager::delete_blocks(), and stxxl::make_bid_iterator().
|
inline |
Swap contents with another object. This is used by the recursive merger to swap in a sorted_runs object with fewer runs.
Definition at line 96 of file sorted_runs.h.
References stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::elements, stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::runs, stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::runs_sizes, and stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::small_run.
size_type stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::elements |
total number of elements in all runs
Definition at line 51 of file sorted_runs.h.
Referenced by stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::swap().
std::vector<run_type> stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::runs |
vector of runs (containing vectors of block ids)
Definition at line 54 of file sorted_runs.h.
Referenced by stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::swap().
std::vector<size_type> stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::runs_sizes |
vector of the number of elements in each individual run
Definition at line 57 of file sorted_runs.h.
Referenced by stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::swap().
small_run_type stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::small_run |
Small sort optimization:
Definition at line 63 of file sorted_runs.h.
Referenced by stxxl::stream::sorted_runs< TriggerEntryType, CompareType >::swap().