aimstil  5.0.5
til::io::GetArraySize Class Reference

Return the number of row and columns of an array in a text file. More...

#include <cathier/io.h>

Classes

class  CannotOpenFile
 

Public Member Functions

 GetArraySize (std::size_t maxlinelength)
 
void setMaxLineLength (std::size_t mll)
 
std::size_t nlines () const
 Returns the number of lines. More...
 
std::size_t ncolumns () const
 Returns the number of columns. More...
 
void operator() (const char *filename)
 Scan file to extract size information. More...
 
void operator() (const std::string &filename)
 Scan file to extract size information. More...
 

Detailed Description

Return the number of row and columns of an array in a text file.

Definition at line 24 of file io.h.

Constructor & Destructor Documentation

◆ GetArraySize()

til::io::GetArraySize::GetArraySize ( std::size_t  maxlinelength)
explicit

Member Function Documentation

◆ ncolumns()

std::size_t til::io::GetArraySize::ncolumns ( ) const
inline

Returns the number of columns.

Definition at line 40 of file io.h.

References operator()().

◆ nlines()

std::size_t til::io::GetArraySize::nlines ( ) const
inline

Returns the number of lines.

Definition at line 38 of file io.h.

◆ operator()() [1/2]

void til::io::GetArraySize::operator() ( const char *  filename)

Scan file to extract size information.

Throws CannotOpenFile when, well, it cannot open the file.

Referenced by ncolumns(), and til::io::SimpleLoader< TIterator, TProgressIndicator >::progress_indicator().

◆ operator()() [2/2]

void til::io::GetArraySize::operator() ( const std::string &  filename)
inline

Scan file to extract size information.

Definition at line 49 of file io.h.

References til::io::get_array_size().

◆ setMaxLineLength()

void til::io::GetArraySize::setMaxLineLength ( std::size_t  mll)
inline

Definition at line 36 of file io.h.


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