BOSS
8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Event/eformat/include/eformat/BadVersionIssue.h
Go to the documentation of this file.
1
// Dear emacs, this is -*- c++ -*-
2
3
/**
4
* @file eformat/BadVersionIssue.h
5
* @author <a href="mailto:Andre.dos.Anjos@cern.ch">Andre DOS ANJOS</a>
6
* $Author: zhangy $
7
* $Revision: 1.1.1.1 $
8
* $Date: 2009/06/19 07:35:41 $
9
*
10
* @brief Exception thrown when versions do not match
11
*/
12
13
#ifndef EFORMAT_BADVERSIONISSUE_H
14
#define EFORMAT_BADVERSIONISSUE_H
15
16
#include "eformat/Issue.h"
17
#include <cstdlib>
18
#include <stdint.h>
19
20
namespace
eformat
{
21
22
/**
23
* This exception is supposed to be thrown when version problems are found
24
*/
25
class
BadVersionIssue
:
public
eformat::Issue
{
26
27
public
:
// interface
28
/**
29
* Builds a new bad-version exception
30
*
31
* @param context The Error Reporting System context to be used to identify
32
* the spot where this issue was created
33
* @param severity The severity of this issue
34
* @param current The version number that this fragment has
35
* @param supported The version which is supposed to be supported here
36
*/
37
BadVersionIssue
(
const
ers::Context
& context,
ers::severity_t
severity
, uint16_t
current
,
38
uint16_t
supported
);
39
40
/**
41
* Destructor virtualisation
42
*/
43
virtual
~BadVersionIssue
() throw() {}
44
45
/**
46
* Access the current object version
47
*/
48
uint16_t
current
()
const
;
49
50
/**
51
* Access the supported version
52
*/
53
uint16_t
supported
()
const
;
54
};
55
56
}
// namespace eformat
57
58
/**
59
* Simplifies the use of this Issue
60
*
61
* @param current The current version you are trying to read
62
* @param supported The supported version by this library
63
*/
64
#define EFORMAT_BAD_VERSION( current, supported ) \
65
eformat::BadVersionIssue( ERS_HERE, ers::error, current, supported )
66
67
#endif
/* EFORMAT_BADVERSIONISSUE_H */
eformat::BadVersionIssue::supported
uint16_t supported() const
Definition
BadVersionIssue.cxx:34
eformat::BadVersionIssue::BadVersionIssue
BadVersionIssue(const ers::Context &context, ers::severity_t severity, uint16_t current, uint16_t supported)
Definition
BadVersionIssue.cxx:21
eformat::BadVersionIssue::~BadVersionIssue
virtual ~BadVersionIssue()
Definition
Event/eformat/include/eformat/BadVersionIssue.h:43
eformat::BadVersionIssue::current
uint16_t current() const
Definition
BadVersionIssue.cxx:30
eformat::Issue
Definition
Event/eformat/include/eformat/Issue.h:23
ers::Context
Source context for Issue.
Definition
Event/ers/include/ers/Context.h:41
ers::Issue::severity
severity_t severity() const
severity_t of the issue
Definition
ers/src/Issue.cxx:584
eformat
Definition
Event/eformat/include/eformat/BadVersionIssue.h:20
ers::severity_t
enum ers::_severity_t severity_t
8.0.0
BOSS_Source
Event
eformat
include
eformat
BadVersionIssue.h
Generated by
1.16.1