The Gaudi Framework  v41r0 (bdbe7744)
Loading...
Searching...
No Matches
Property.h
Go to the documentation of this file.
1/***********************************************************************************\
2* (c) Copyright 1998-2025 CERN for the benefit of the LHCb and ATLAS collaborations *
3* *
4* This software is distributed under the terms of the Apache version 2 licence, *
5* copied verbatim in the file "LICENSE". *
6* *
7* In applying this licence, CERN does not waive the privileges and immunities *
8* granted to it by virtue of its status as an Intergovernmental Organization *
9* or submit itself to any jurisdiction. *
10\***********************************************************************************/
11#pragma once
12
13#include "Position.h"
14#include "PropertyName.h"
15#include "PropertyValue.h"
16#include <string>
17
18namespace Gaudi {
19 namespace Parsers {
20 class Property final {
21 public:
22 struct LessThen {
23 bool operator()( const Property& first, const Property& second ) const {
24 return first.FullName() < second.FullName();
25 }
26 };
27
30
31 const PropertyName& property_name() const { return property_name_; }
33 // ----------------------------------------------------------------------------
35 property_value_ += value;
36 return *this;
37 }
39 property_value_ -= value;
40 return *this;
41 }
42
43 const Position& DefinedPosition() const;
44 bool HasDefinedPosition() const { return DefinedPosition().Exists(); }
45
46 const Position& ValuePosition() const;
47 bool HasValuePosition() const { return ValuePosition().Exists(); }
48
49 const std::string& ClientName() const;
50 const std::string& NameInClient() const;
51 std::string FullName() const;
52 std::string ValueAsString() const;
53 std::string ToString() const;
54 bool IsSimple() const;
55 bool IsVector() const;
56 bool IsMap() const;
57 bool IsReference() const { return property_value_.IsReference(); }
58
59 private:
62 };
63 } // namespace Parsers
64} // namespace Gaudi
bool Exists() const
Definition Position.h:27
std::string ValueAsString() const
Definition Property.cpp:24
const Position & ValuePosition() const
Definition Property.cpp:20
std::string ToString() const
Definition Property.cpp:25
const PropertyName & property_name() const
Definition Property.h:31
const std::string & NameInClient() const
Definition Property.cpp:22
bool IsReference() const
Definition Property.h:57
const Position & DefinedPosition() const
Definition Property.cpp:19
const std::string & ClientName() const
Definition Property.cpp:21
PropertyName property_name_
Definition Property.h:60
PropertyValue property_value_
Definition Property.h:61
Property & operator-=(const PropertyValue &value)
Definition Property.h:38
std::string FullName() const
Definition Property.cpp:23
Property(PropertyName property_name, PropertyValue property_value)
Definition Property.h:28
bool HasDefinedPosition() const
Definition Property.h:44
bool HasValuePosition() const
Definition Property.h:47
PropertyValue & property_value()
Definition Property.h:32
Property & operator+=(const PropertyValue &value)
Definition Property.h:34
This file provides a Grammar for the type Gaudi::Accumulators::Axis It allows to use that type from p...
Definition __init__.py:1
STL namespace.
bool operator()(const Property &first, const Property &second) const
Definition Property.h:23