ARC SDK
Public Types | Public Member Functions | Static Public Member Functions
Arc::ConfigFile Class Reference
Inheritance diagram for Arc::ConfigFile:

Public Types

enum  file_type { file_XML, file_INI, file_unknown }
 Recognizable configuration file types. More...
 

Public Member Functions

 ConfigFile (void)
 Default constructor creates object not associated with file. More...
 
 ConfigFile (const std::string &path)
 Constructor creates object associated with file located at path. More...
 
bool open (const std::string &path)
 Open/assign configuration file located at path to this object. More...
 
bool close (void)
 Closes configuration file. More...
 
std::string read_line ()
 
file_type detect (void)
 Detect type of currently associated configuration file. More...
 

Static Public Member Functions

static std::string read_line (std::istream &stream)
 Helper function to read one line of configuration from provided stream. More...
 

Member Enumeration Documentation

◆ file_type

Recognizable configuration file types.

Constructor & Destructor Documentation

◆ ConfigFile() [1/2]

Arc::ConfigFile::ConfigFile ( void  )
inline

Default constructor creates object not associated with file.

◆ ConfigFile() [2/2]

Arc::ConfigFile::ConfigFile ( const std::string &  path)
inline

Constructor creates object associated with file located at path.

Member Function Documentation

◆ close()

bool Arc::ConfigFile::close ( void  )

Closes configuration file.

◆ detect()

file_type Arc::ConfigFile::detect ( void  )

Detect type of currently associated configuration file.

◆ open()

bool Arc::ConfigFile::open ( const std::string &  path)

Open/assign configuration file located at path to this object.

◆ read_line() [1/2]

std::string Arc::ConfigFile::read_line ( )

Read one line of configuration file. Returns string containing whole line.

◆ read_line() [2/2]

static std::string Arc::ConfigFile::read_line ( std::istream &  stream)
static

Helper function to read one line of configuration from provided stream.


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