libyui  3.4.2
YCodeLocation Class Reference

Helper class for UI exceptions: Store FILE, FUNCTION and LINE. More...

#include <YUIException.h>

Public Member Functions

 YCodeLocation (const std::string &file_r, const std::string &func_r, int line_r)
 Constructor. More...
 
 YCodeLocation ()
 Default constructor.
 
std::string file () const
 Returns the source file name where the exception occured.
 
std::string func () const
 Returns the name of the function where the exception occured.
 
int line () const
 Returns the source line number where the exception occured.
 
std::string asString () const
 Returns the location in normalized string format.
 

Friends

std::ostream & operator<< (std::ostream &str, const YCodeLocation &obj)
 Stream output.
 

Detailed Description

Helper class for UI exceptions: Store FILE, FUNCTION and LINE.

Construct this using the YUI_EXCEPTION_CODE_LOCATION macro.

Definition at line 229 of file YUIException.h.

Constructor & Destructor Documentation

◆ YCodeLocation()

YCodeLocation::YCodeLocation ( const std::string &  file_r,
const std::string &  func_r,
int  line_r 
)
inline

Constructor.

Commonly called using the YUI_EXCEPTION_CODE_LOCATION macro.

Definition at line 236 of file YUIException.h.


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