The Gaudi Framework  v30r3 (a5ef0a68)
IInterface.cpp
Go to the documentation of this file.
3 
4 namespace
5 {
6  struct IInterfaceCategory : StatusCode::Category {
7  const char* name() const override { return "IInterface"; }
8 
9  bool isRecoverable( StatusCode::code_t ) const override { return false; }
10 
11  std::string message( StatusCode::code_t code ) const override
12  {
13  switch ( static_cast<IInterface::Status>( code ) ) {
15  return "NO_INTERFACE";
17  return "VERSMISMATCH";
18  default:
19  return StatusCode::default_category().message( code );
20  }
21  }
22  };
23 }
24 
25 STATUSCODE_ENUM_IMPL( IInterface::Status, IInterfaceCategory )
Requested interface is not available.
The category assigned to a StatusCode.
Definition: StatusCode.h:65
virtual const char * name() const =0
Name of the category.
STL class.
Requested interface version is incompatible.
virtual bool isRecoverable(code_t code) const
Is code considered recoverable ?
Definition: StatusCode.h:80
#define STATUSCODE_ENUM_IMPL(...)
Assign a category to the StatusCode enum declared with STATUSCODE_ENUM_DECL( ENUM ) ...
Definition: StatusCode.h:267
static const Category & default_category() noexcept
Default Gaudi StatusCode category.
Definition: StatusCode.h:282
Status
Return status.
Definition: IInterface.h:331
virtual std::string message(code_t code) const
Description for code within this category.
Definition: StatusCode.h:73
unsigned long code_t
type of StatusCode value
Definition: StatusCode.h:54