Property.cpp
Go to the documentation of this file.
1 // Copyright 2011 alexander.mazurov@gmail.com
2 // ============================================================================
3 // Include files
4 // ============================================================================
5 #include "Property.h"
6 
7 #include "PropertyName.h"
8 #include "PropertyValue.h"
9 #include "Utils.h"
10 // ============================================================================
11 // Boost:
12 // ============================================================================
13 #include <boost/format.hpp>
14 // ============================================================================
15 // Namespace aliases:
16 namespace gp = Gaudi::Parsers;
17 namespace gpu = Gaudi::Parsers::Utils;
18 // ============================================================================
19 const gp::Position& gp::Property::DefinedPosition() const {
20  return property_name_.position();
21 }
22 // ============================================================================
23 const gp::Position& gp::Property::ValuePosition() const {
24  return property_value_.position();
25 }
26 // ============================================================================
27 const std::string& gp::Property::ClientName() const {
28  return property_name_.client();
29 }
30 // ============================================================================
31 const std::string& gp::Property::NameInClient() const {
32  return property_name_.property();
33 }
34 // ============================================================================
35 std::string gp::Property::FullName() const {
36  return property_name_.ToString();
37 }
38 // ============================================================================
39 std::string gp::Property::ValueAsString() const {
40  return gpu::replaceEnvironments(property_value_.ToString());
41 }
42 // ============================================================================
43 std::string gp::Property::ToString() const {
44  return FullName()+" = "+ValueAsString();
45 }
46 // ============================================================================
47 bool gp::Property::IsSimple() const {
48  return property_value_.IsSimple();
49 }
50 // ============================================================================
51 bool gp::Property::IsVector() const {
52  return property_value_.IsVector();
53 }
54 // ============================================================================
55 bool gp::Property::IsMap() const {
56  return property_value_.IsMap();
57 }
58 // ============================================================================
std::string replaceEnvironments(const std::string &input)
Definition: Utils.cpp:18