ATLAS Offline Software
Loading...
Searching...
No Matches
IUnitInterpreter.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
6// IUnitInterpreter.h, (c) ATLAS Detector software
8// Author: Thomas Gillam (thomas.gillam@cern.ch)
9// ExpressionParsing library
11
12#ifndef UNIT_INTERPRETER_H
13#define UNIT_INTERPRETER_H
14
15#include <string>
16#include <map>
17
18namespace ExpressionParsing {
20 public:
21 virtual ~IUnitInterpreter() { }
22
23 bool isKnownUnit(const std::string &unitname) const;
24 double unitValue(const std::string &unitname) const;
25
26 private:
27 virtual const std::map<std::string, double> &unitMap() const = 0;
28 };
29}
30
31#endif // UNIT_INTERPRETER_H
double unitValue(const std::string &unitname) const
virtual const std::map< std::string, double > & unitMap() const =0
bool isKnownUnit(const std::string &unitname) const
Namespace holding all the expression evaluation code.