cwCsv.h/cpp : Added has_field().
This commit is contained in:
parent
40840286cf
commit
3319804d60
@ -420,6 +420,12 @@ unsigned cw::csv::title_col_index( handle_t h, const char* title )
|
|||||||
return _title_to_col_index(p,title);
|
return _title_to_col_index(p,title);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool cw::csv::has_field( handle_t h, const char* title )
|
||||||
|
{
|
||||||
|
csv_t* p = _handleToPtr(h);
|
||||||
|
return _title_to_col_index(p,title) != kInvalidIdx;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
cw::rc_t cw::csv::rewind( handle_t h )
|
cw::rc_t cw::csv::rewind( handle_t h )
|
||||||
{
|
{
|
||||||
|
1
cwCsv.h
1
cwCsv.h
@ -22,6 +22,7 @@ namespace cw
|
|||||||
|
|
||||||
const char* col_title( handle_t h, unsigned idx );
|
const char* col_title( handle_t h, unsigned idx );
|
||||||
unsigned title_col_index( handle_t h, const char* title );
|
unsigned title_col_index( handle_t h, const char* title );
|
||||||
|
bool has_field( handle_t h, const char* title );
|
||||||
|
|
||||||
// Reset the CSV to make the title line current.
|
// Reset the CSV to make the title line current.
|
||||||
// The next call to 'next_line()' will make the first data row current.
|
// The next call to 'next_line()' will make the first data row current.
|
||||||
|
Loading…
Reference in New Issue
Block a user