Public Methods | |
Error () | |
~Error () | |
void | clear () |
void | set (CmtError::code code, const cmt_string& text) |
CmtError::code | get_code () const |
const cmt_string& | get_text () const |
const cmt_string& | get_name (CmtError::code error) const |
Static Public Methods | |
Error& | instance () |
Private Attributes | |
CmtError::code | m_code |
cmt_string | m_text |
cmt_vector<cmt_string> | error_names |
|
Definition at line 10 of file cmt_error.cxx. 00011 { 00012 error_names.add() = "ok"; 00013 error_names.add() = "symbol not found"; 00014 error_names.add() = "pattern not found"; 00015 error_names.add() = "syntax error"; 00016 error_names.add() = "command_not_implemented"; 00017 error_names.add() = "package_not_found"; 00018 error_names.add() = "path_not_found"; 00019 error_names.add() = "version_conflict"; 00020 error_names.add() = "file_access_error"; 00021 error_names.add() = "execution_error"; 00022 error_names.add() = "cannot_lock"; 00023 error_names.add() = "cannot_write_lock"; 00024 error_names.add() = "cannot_run_lock_command"; 00025 error_names.add() = "cannot_unlock"; 00026 error_names.add() = "cannot_run_unlock_command"; 00027 error_names.add() = "cannot_remove_lock"; 00028 error_names.add() = "conflicting_lock"; 00029 } |
|
Definition at line 31 of file cmt_error.cxx. 00032 { 00033 } |
|
Definition at line 35 of file cmt_error.cxx. Referenced by CmtError::clear(). 00036 { 00037 m_code = CmtError::ok; 00038 m_text = ""; 00039 } |
|
Definition at line 47 of file cmt_error.cxx. Referenced by CmtError::get_last_error(), CmtError::get_last_error_code(), CmtError::has_pending_error(), and CmtError::print(). 00048 { 00049 return (m_code); 00050 } |
|
Definition at line 57 of file cmt_error.cxx. Referenced by CmtError::get_error_name(). 00058 { 00059 const cmt_string& s = error_names[error]; 00060 00061 return (s); 00062 } |
|
Definition at line 52 of file cmt_error.cxx. Referenced by CmtError::get_last_error(), and CmtError::print(). 00053 { 00054 return (m_text); 00055 } |
|
Definition at line 71 of file cmt_error.cxx. Referenced by CmtError::clear(), CmtError::get_error_name(), CmtError::get_last_error(), CmtError::get_last_error_code(), CmtError::has_pending_error(), CmtError::print(), and CmtError::set(). 00073 { 00074 static Error e; 00075 00076 return (e); 00077 } |
|
Definition at line 41 of file cmt_error.cxx. Referenced by CmtError::set(). 00042 { 00043 m_code = code; 00044 m_text = text; 00045 } |
|
Definition at line 67 of file cmt_error.cxx. |
|
Definition at line 65 of file cmt_error.cxx. |
|
Definition at line 66 of file cmt_error.cxx. |