|
|
|||
File indexing completed on 2026-06-02 08:51:42
0001 #ifndef COLLINEAR_DISTRIBUTION_RESULT_H 0002 #define COLLINEAR_DISTRIBUTION_RESULT_H 0003 0004 /** 0005 * @file CollinearDistributionResult.h 0006 * @author: Valerio BERTONE (CEA Saclay) 0007 * @date 18 July 2020 0008 * @version 1.0 0009 */ 0010 0011 #include <map> 0012 #include <string> 0013 #include <vector> 0014 0015 #include "../parton_distribution/PartonDistribution.h" 0016 #include "../Result.h" 0017 #include "CollinearDistributionKinematic.h" 0018 #include "CollinearDistributionType.h" 0019 0020 namespace PARTONS { 0021 0022 /** 0023 * @class CollinearDistributionResult 0024 * 0025 * @brief Class representing single result of a collinear-distribution 0026 * computation. 0027 * 0028 * This class is used to store results of a single collinear 0029 * distribution computation. In other words, the class stores a 0030 * collection of PartonDistribution objects, with each of them 0031 * containing a part of the result defined for a specific collinear 0032 * distribution type. 0033 */ 0034 class CollinearDistributionResult: public Result<CollinearDistributionKinematic> { 0035 0036 public: 0037 0038 /** 0039 * Default constructor. 0040 */ 0041 CollinearDistributionResult(); 0042 0043 /** 0044 * Assignment constructor. 0045 * @param kinematic collinear distribution kinematics to be assigned. 0046 */ 0047 CollinearDistributionResult(const CollinearDistributionKinematic& kinematic); 0048 0049 /** 0050 * Copy constructor. 0051 * @param other Object to be copied. 0052 */ 0053 CollinearDistributionResult(const CollinearDistributionResult &other); 0054 0055 /** 0056 * Destructor. 0057 */ 0058 virtual ~CollinearDistributionResult(); 0059 0060 virtual std::string toString() const; 0061 0062 /** 0063 * Add parton distribution associated to given collinear distribution type. 0064 * @param colldistType collinear distribution type of parton distribution to be inserted. 0065 * @param partonDistribution Parton distribution to be added. 0066 */ 0067 void addPartonDistribution(CollinearDistributionType::Type colldistType, 0068 const PartonDistribution& partonDistribution); 0069 0070 /** 0071 * Get reference to parton distribution associated to given collinear distribution type. 0072 * @param colldistType collinear distribution type associated to parton distribution to be selected. 0073 * @return Reference to selected parton distribution. 0074 */ 0075 const PartonDistribution& getPartonDistribution( 0076 CollinearDistributionType::Type colldistType) const; 0077 0078 /** 0079 * Check if the object stores parton distribution of given collinear distribution type. 0080 * @param colldistType collinear distribution type to be checked. 0081 * @return True if the object stores parton distribution of given collinear distribution type, otherwise false. 0082 * @see CollinearDistributionResult::getLastAvailable() 0083 */ 0084 bool isAvailable(const CollinearDistributionType::Type &colldistType) const; 0085 0086 /** 0087 * Get reference to parton distribution marked by the last call of CollinearDistributionResult::isAvailible() function. 0088 * @return Reference to selected parton distribution. 0089 * @see CollinearDistributionResult::isAvailible() 0090 */ 0091 PartonDistribution& getLastAvailable() const; 0092 0093 /** 0094 * Get list of collinear distribution types associated to stored parton distributions. 0095 * @return Vector of associated types. 0096 */ 0097 std::vector<CollinearDistributionType> listCollinearDistributionTypeComputed() const; 0098 0099 //******************************************************** 0100 //*** SETTERS AND GETTERS ******************************** 0101 //******************************************************** 0102 0103 /** 0104 * Get reference to map containing stored parton distributions distinguished by associated collinear distribution types. 0105 */ 0106 const std::map<CollinearDistributionType::Type, PartonDistribution>& getPartonDistributions() const; 0107 0108 /** 0109 * Set map containing stored parton distributions distinguished by associated collinear distribution types. 0110 */ 0111 void setPartonDistributions( 0112 const std::map<CollinearDistributionType::Type, PartonDistribution>& partonDistributions); 0113 0114 private: 0115 0116 /** 0117 * Map containing stored parton distributions distinguished by associated collinear distribution types. 0118 */ 0119 std::map<CollinearDistributionType::Type, PartonDistribution> m_partonDistributions; 0120 0121 /** 0122 * Iterator used to mark a specific entry in CollinearDistributionResult::m_partonDistributions. 0123 */ 0124 mutable std::map<CollinearDistributionType::Type, PartonDistribution>::const_iterator m_it; 0125 }; 0126 0127 } /* namespace PARTONS */ 0128 0129 #endif /* COLLINEAR_DISTRIBUTION_RESULT_H */
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|