CGEM BOSS
6.6.5.g
BESIII Offline Software System
Loading...
Searching...
No Matches
BadVersionIssue.cxx
Go to the documentation of this file.
1
//Dear emacs, this is -*- c++ -*-
2
3
/**
4
* @file BadVersionIssue.cxx
5
* @author <a href="mailto:
[email protected]
">Andre DOS ANJOS</a>
6
* $Author: zhangy $
7
* $Revision: 1.1.1.1 $
8
* $Date: 2009/06/19 07:35:41 $
9
*
10
* Implements the bad-version Issue
11
*/
12
13
#include "
eformat/BadVersionIssue.h
"
14
15
/**
16
* Strings to identify keys in ERS
17
*/
18
static
const
char
* CURRENT_VERSION_KEY =
"Current version"
;
19
static
const
char
* SUPPORTED_VERSION_KEY =
"Supported version"
;
20
21
eformat::BadVersionIssue::BadVersionIssue
(
const
ers::Context
& context,
22
ers::severity_t
severity,
23
uint16_t current,
24
uint16_t supported)
25
:
eformat
::
Issue
(context,severity)
26
{
27
set_value
(CURRENT_VERSION_KEY,
current
);
28
set_value
(SUPPORTED_VERSION_KEY,
supported
);
29
finish_setup
(
"Unsupported eformat version detected"
);
30
}
31
32
uint16_t
eformat::BadVersionIssue::current
()
const
33
{
34
return
get_int_value(CURRENT_VERSION_KEY);
35
}
36
37
uint16_t
eformat::BadVersionIssue::supported
()
const
38
{
39
return
get_int_value(SUPPORTED_VERSION_KEY);
40
}
41
42
43
BadVersionIssue.h
Exception thrown when versions do not match.
eformat::BadVersionIssue::supported
uint16_t supported() const
Definition:
BadVersionIssue.cxx:37
eformat::BadVersionIssue::BadVersionIssue
BadVersionIssue(const ers::Context &context, ers::severity_t severity, uint16_t current, uint16_t supported)
Definition:
BadVersionIssue.cxx:21
eformat::BadVersionIssue::current
uint16_t current() const
Definition:
BadVersionIssue.cxx:32
eformat::Issue
Definition:
eformat/eformat-00-00-04/eformat/Issue.h:23
ers::Context
Source context for Issue.
Definition:
Context.h:42
ers::Issue::set_value
void set_value(const std::string &key, uint8_t value)
Sets a value 8 bit unsigned.
Definition:
ers/ers-00-00-03/src/Issue.cxx:371
ers::Issue::finish_setup
void finish_setup(const std::string &message)
Finishes the setup of the Issue.
Definition:
ers/ers-00-00-03/src/Issue.cxx:568
eformat
Definition:
BadVersionIssue.h:20
ers::severity_t
enum ers::_severity_t severity_t
source
Event
eformat
eformat-00-00-04
src
BadVersionIssue.cxx
Generated by
1.9.6