| The Gaudi Framework v32r1 (f65d50dc)

HistoProperty.h
Go to the documentation of this file.
1 #ifndef GAUDIKERNEL_HISTOPROPERTY_H
2 #define GAUDIKERNEL_HISTOPROPERTY_H 1
3 // ============================================================================
4 // Include files
5 // ============================================================================
6 // GaudiKernel
7 // ============================================================================
8 #include "GaudiKernel/HistoDef.h"
9 #include "GaudiKernel/Property.h"
10 namespace Gaudi {
11 namespace Details {
12 namespace Property {
13 // ============================================================================
19 template <>
20 inline void BoundedVerifier<Gaudi::Histo1DDef>::operator()( const Gaudi::Histo1DDef& value ) const {
21 if ( !value.ok() || ( m_hasLowerBound && ( value < m_lowerBound ) ) ||
22 ( m_hasUpperBound && ( m_upperBound < value ) ) )
23 throw std::out_of_range( "value " + Gaudi::Utils::toString( value ) + " outside range" );
24 }
25 // ============================================================================
30 template <>
31 inline void NullVerifier::operator()<Gaudi::Histo1DDef>( const Gaudi::Histo1DDef& value ) const {
32 if ( !value.ok() ) throw std::invalid_argument( "bad value " + Gaudi::Utils::toString( value ) );
33 }
34 // ============================================================================
35 } // namespace Property
36 } // namespace Details
37 } // namespace Gaudi
38 // ============================================================================
40 typedef Gaudi::Property<Gaudi::Histo1DDef> Histo1DProperty;
41 // ============================================================================
43 typedef Gaudi::Property<Gaudi::Histo1DDef&> Histo1DPropertyRef;
44 // ============================================================================
45
46 // ============================================================================
47 // The END
48 // ============================================================================
49 #endif // GAUDIKERNEL_HISTOPROPERTY_H
std::out_of_range
STL class.
Gaudi::Property
Implementation of property with value of concrete type.
Definition: Property.h:352
Gaudi::Utils::toString
std::string toString(const TYPE &obj)
the generic implementation of the type conversion to the string
Definition: ToStream.h:334
Histo1DPropertyRef
Gaudi::Property< Gaudi::Histo1DDef & > Histo1DPropertyRef
the actual type of "histogram property reference"
Definition: HistoProperty.h:43
Property
Gaudi::Details::PropertyBase Property
\fixme backward compatibility hack for old Property base class
Definition: PropertyFwd.h:25
Histo1DProperty
Gaudi::Property< Gaudi::Histo1DDef > Histo1DProperty
the actual type of "histogram property"
Definition: HistoProperty.h:40
Gaudi::Histo1DDef
Simple helper class for description of 1D-histogram The class is targeted to act as the primary "hist...
Definition: HistoDef.h:31
Gaudi::Histo1DDef::ok
bool ok() const
check if all fields are "reasonable"
Definition: HistoDef.h:92
Property.h
Gaudi::Details::Property::BoundedVerifier::operator()
void operator()(const TYPE &value) const
Definition: Property.h:229
Gaudi
Header file for std:chrono::duration-based Counters.
Definition: __init__.py:1
std::invalid_argument
STL class.
HistoDef.h