ANNA Suite  2020b
Multipurpose development suite for Telco applications
ResultCode.hpp
Go to the documentation of this file.
1 // ANNA - Anna is Not Nothingness Anymore //
2 // //
3 // (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo //
4 // //
5 // See project site at http://redmine.teslayout.com/projects/anna-suite //
6 // See accompanying file LICENSE or copy at http://www.teslayout.com/projects/public/anna.LICENSE //
7 
8 
9 #ifndef anna_dbms_oracle_ResultCode_hpp
10 #define anna_dbms_oracle_ResultCode_hpp
11 
12 #include <anna/dbms/ResultCode.hpp>
13 
14 struct OCIError;
15 
16 namespace anna {
17 
18 namespace dbms {
19 
20 namespace oracle {
21 
26 class ResultCode : public dbms::ResultCode {
27 public:
34  explicit ResultCode(const int status, OCIError* error);
35 
36 private:
37  class ErrorDecoder : public dbms::ResultCode::ErrorDecoder {
38  bool notFound(const int errorCode) const ;
39  bool successful(const int errorCode) const ;
40  bool locked(const int errorCode) const { return errorCode == 54; }
41  bool lostConnection(const int errorCode) const ;
42  };
43 
44  static ErrorDecoder st_errorDecoder;
45 };
46 
47 }
48 }
49 }
50 
51 #endif
52 
Definition: ResultCode.hpp:126
bool notFound() const noexcept(false)
Definition: app.hpp:12
bool locked() const noexcept(false)
bool lostConnection() const noexcept(false)
Definition: ResultCode.hpp:26
Definition: ResultCode.hpp:29
ResultCode()
Definition: ResultCode.hpp:36
bool successful() const noexcept(false)