Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-03-13 09:29:12

0001 //!    \file MaterialInfo.h
0002 //!    \brief Declares helper functions to manipulate data from XML
0003 //!
0004 //!    \authors Author:  Dmitry Savin <sd57@protonmail.ch>
0005 //!
0006 
0007 #pragma once
0008 
0009 #ifndef MaterialInfo_h
0010 #define MaterialInfo_h
0011 
0012 #include <string>
0013 #include <vector>
0014 #include <utility>
0015 #include <array>
0016 #include <map>
0017 
0018 // TODO use std::optional and std::any
0019 
0020 namespace vgdml {
0021 
0022 struct Isotope {
0023   std::map<std::string, std::string> attributes;
0024 };
0025 
0026 struct Element {
0027   std::map<std::string, std::string> attributes;
0028   std::map<std::string, std::string> isotopeFractions;
0029 };
0030 
0031 struct Material {
0032   std::string name;
0033   std::map<std::string, std::string> attributes;
0034   std::map<std::string, std::string> fractions;
0035   std::map<std::string, std::string> components;
0036 };
0037 
0038 } // namespace vgdml
0039 
0040 #endif