KiCad PCB EDA Suite
Loading...
Searching...
No Matches
KI_ERROR Class Reference

Holds a structured error message. More...

#include <ki_error.h>

Public Member Functions

 KI_ERROR ()
 
 KI_ERROR (SEVERITY aSeverity, const wxString &aTitle=wxEmptyString)
 
const wxString & GetTitle () const
 
const wxString & GetDescription () const
 
const wxString & GetDebugText () const
 
SEVERITY GetSeverity () const
 
std::chrono::system_clock::time_point GetTimestamp () const
 
KI_ERRORSetTitle (const wxString &aTitle)
 
KI_ERRORSetDescription (const wxString &aDescription)
 
KI_ERRORSetDebugText (const wxString &aDebugText)
 
KI_ERRORSetSeverity (SEVERITY aSeverity)
 
bool HasTitle () const
 
bool HasDescription () const
 
bool HasDebugText () const
 
wxString AsString () const
 

Private Attributes

wxString m_title
 
wxString m_description
 
wxString m_debugText
 
SEVERITY m_severity
 
std::chrono::system_clock::time_point m_timestamp
 

Detailed Description

Holds a structured error message.

Used to report errors in situations where you want to split up the title from a detailed description. Could also be used for an error log in the future if we want one.

Definition at line 37 of file ki_error.h.

Constructor & Destructor Documentation

◆ KI_ERROR() [1/2]

KI_ERROR::KI_ERROR ( )
inline

Definition at line 40 of file ki_error.h.

References m_severity, m_timestamp, and RPT_SEVERITY_UNDEFINED.

Referenced by SetDebugText(), SetDescription(), SetSeverity(), and SetTitle().

◆ KI_ERROR() [2/2]

KI_ERROR::KI_ERROR ( SEVERITY aSeverity,
const wxString & aTitle = wxEmptyString )
inlineexplicit

Definition at line 45 of file ki_error.h.

References m_severity, m_timestamp, and m_title.

Member Function Documentation

◆ AsString()

wxString KI_ERROR::AsString ( ) const

◆ GetDebugText()

const wxString & KI_ERROR::GetDebugText ( ) const
inline

Definition at line 53 of file ki_error.h.

References m_debugText.

Referenced by ERROR_CARD::ERROR_CARD().

◆ GetDescription()

const wxString & KI_ERROR::GetDescription ( ) const
inline

Definition at line 52 of file ki_error.h.

References m_description.

Referenced by ERROR_CARD::ERROR_CARD().

◆ GetSeverity()

SEVERITY KI_ERROR::GetSeverity ( ) const
inline

Definition at line 54 of file ki_error.h.

References m_severity.

Referenced by ERROR_CARD::ERROR_CARD(), REPORTER::Report(), and STATUSBAR_WARNING_REPORTER::Report().

◆ GetTimestamp()

std::chrono::system_clock::time_point KI_ERROR::GetTimestamp ( ) const
inline

Definition at line 56 of file ki_error.h.

References m_timestamp.

◆ GetTitle()

const wxString & KI_ERROR::GetTitle ( ) const
inline

Definition at line 51 of file ki_error.h.

References m_title.

Referenced by ERROR_CARD::ERROR_CARD().

◆ HasDebugText()

bool KI_ERROR::HasDebugText ( ) const
inline

Definition at line 84 of file ki_error.h.

References m_debugText.

Referenced by ERROR_CARD::ERROR_CARD().

◆ HasDescription()

bool KI_ERROR::HasDescription ( ) const
inline

Definition at line 83 of file ki_error.h.

References m_description.

Referenced by ERROR_CARD::ERROR_CARD().

◆ HasTitle()

bool KI_ERROR::HasTitle ( ) const
inline

Definition at line 82 of file ki_error.h.

References m_title.

Referenced by ERROR_CARD::ERROR_CARD().

◆ SetDebugText()

KI_ERROR & KI_ERROR::SetDebugText ( const wxString & aDebugText)
inline

Definition at line 70 of file ki_error.h.

References KI_ERROR(), and m_debugText.

Referenced by reportPluginLoadMessage().

◆ SetDescription()

KI_ERROR & KI_ERROR::SetDescription ( const wxString & aDescription)
inline

Definition at line 64 of file ki_error.h.

References KI_ERROR(), and m_description.

Referenced by reportPluginLoadMessage().

◆ SetSeverity()

KI_ERROR & KI_ERROR::SetSeverity ( SEVERITY aSeverity)
inline

◆ SetTitle()

KI_ERROR & KI_ERROR::SetTitle ( const wxString & aTitle)
inline

Member Data Documentation

◆ m_debugText

wxString KI_ERROR::m_debugText
private

Definition at line 91 of file ki_error.h.

Referenced by AsString(), GetDebugText(), HasDebugText(), and SetDebugText().

◆ m_description

wxString KI_ERROR::m_description
private

Definition at line 90 of file ki_error.h.

Referenced by AsString(), GetDescription(), HasDescription(), and SetDescription().

◆ m_severity

SEVERITY KI_ERROR::m_severity
private

Definition at line 92 of file ki_error.h.

Referenced by GetSeverity(), KI_ERROR(), KI_ERROR(), and SetSeverity().

◆ m_timestamp

std::chrono::system_clock::time_point KI_ERROR::m_timestamp
private

Definition at line 94 of file ki_error.h.

Referenced by GetTimestamp(), KI_ERROR(), and KI_ERROR().

◆ m_title

wxString KI_ERROR::m_title
private

Definition at line 89 of file ki_error.h.

Referenced by AsString(), GetTitle(), HasTitle(), KI_ERROR(), and SetTitle().


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