SHORE API
|
Read plain text files line by line (monolithic interface). More...
Public Member Functions | |
line_reader (const std::string &fn, compare_type cmp=compare_type()) | |
line_reader (std::istream *const in, compare_type cmp=compare_type()) | |
line_reader & | set_commentchar (const char c) |
line_reader & | set_skipempty (const bool s) |
shore::signal< const std::string & > & | sigmetadata () |
const std::string & | get_name () const |
void | seek (const std::streampos position) |
Seek to the next line start following a position in the file. | |
void | set_blocks (const size_t blocksize, const std::set< size_t > &blocks) |
void | seek_to (const std::string &key) |
Perform line_sorter::upper_bound() on a file sorted according to cmp. | |
void | seek_to_lower (const std::string &key) |
Perform line_sorter::lower_bound() on a file sorted according to cmp. | |
![]() | |
monolithic (bool(*)(const typename source_traits< basic_line_reader >::current_type &, const typename source_traits< basic_line_reader >::current_type &)cmp=bool(*)(const typename source_traits< basic_line_reader >::current_type &, const typename source_traits< basic_line_reader >::current_type &)()) | |
Initialize, optionally with a comparator. | |
monolithic (Arg a1, bool(*)(const typename source_traits< basic_line_reader >::current_type &, const typename source_traits< basic_line_reader >::current_type &)cmp=bool(*)(const typename source_traits< basic_line_reader >::current_type &, const typename source_traits< basic_line_reader >::current_type &)()) | |
Initialize with a single argument to the wrapped type, and optionally with a comparator. | |
monolithic (Arg1 a1, Arg2 a2, bool(*)(const typename source_traits< basic_line_reader >::current_type &, const typename source_traits< basic_line_reader >::current_type &)cmp=bool(*)(const typename source_traits< basic_line_reader >::current_type &, const typename source_traits< basic_line_reader >::current_type &)()) | |
Initialize with two arguments to the wrapped type, and optionally with a comparator. | |
source_type & | basic () |
Get the wrapped data source object ("basic" interface). | |
const source_type & | basic () const |
Get the wrapped data source object ("basic" interface). | |
const current_type & | current () const |
Get the current dataset element. | |
bool | has_data () |
Initialize / check for data availability. | |
void | next () |
Discard the current dataset element. | |
![]() | |
buffer_chain () | |
Constructor - initialize empty buffer chain. | |
~buffer_chain () | |
Destructor - free all buffers. | |
void | add_plugin (plugin_type *const p) |
Add a plugin object. | |
void | clear_plugins () |
Remove all plugin objects. | |
Additional Inherited Members | |
![]() | |
typedef basic_line_reader | source_type |
typedef typename source_traits < basic_line_reader > ::current_type | current_type |
typedef bool(*)(const typename source_traits < basic_line_reader > ::current_type &, const typename source_traits < basic_line_reader > ::current_type &) | compare_type |
![]() | |
bool(*)(const typename source_traits < basic_line_reader > ::current_type &, const typename source_traits < basic_line_reader > ::current_type &) | get_comparator () const |
Get the comparator for the current ordering check. | |
Read plain text files line by line (monolithic interface).