|
|
|||
File indexing completed on 2026-09-27 09:15:18
0001 /** 0002 * @file PandoraSDK/include/Managers/ClusterManager.h 0003 * 0004 * @brief Header file for the cluster manager class. 0005 * 0006 * $Log: $ 0007 */ 0008 #ifndef PANDORA_CLUSTER_MANAGER_H 0009 #define PANDORA_CLUSTER_MANAGER_H 1 0010 0011 #include "Managers/AlgorithmObjectManager.h" 0012 0013 #include "Pandora/ObjectCreation.h" 0014 #include "Pandora/PandoraInternal.h" 0015 0016 namespace pandora 0017 { 0018 0019 /** 0020 * @brief ClusterManager class 0021 */ 0022 class ClusterManager : public AlgorithmObjectManager<Cluster> 0023 { 0024 public: 0025 /** 0026 * @brief Constructor 0027 * 0028 * @param pPandora address of the associated pandora object 0029 */ 0030 ClusterManager(const Pandora *const pPandora); 0031 0032 /** 0033 * @brief Destructor 0034 */ 0035 ~ClusterManager(); 0036 0037 private: 0038 /** 0039 * @brief Create cluster 0040 * 0041 * @param parameters the cluster parameters 0042 * @param pCluster to receive the address of the cluster created 0043 * @param factory the factory that performs the object allocation 0044 */ 0045 StatusCode Create(const object_creation::Cluster::Parameters ¶meters, const Cluster *&pCluster, 0046 const ObjectFactory<object_creation::Cluster::Parameters, object_creation::Cluster::Object> &factory); 0047 0048 /** 0049 * @brief Alter the metadata information stored in a cluster 0050 * 0051 * @param pCluster address of the cluster to modify 0052 * @param metaData the metadata (only populated metadata fields will be propagated to the object) 0053 */ 0054 StatusCode AlterMetadata(const Cluster *const pCluster, const object_creation::Cluster::Metadata &metadata) const; 0055 0056 /** 0057 * @brief Is a cluster, or a list of clusters, available to add to a particle flow object 0058 * 0059 * @param pT address of the object or object list 0060 * 0061 * @return boolean 0062 */ 0063 template <typename T> 0064 bool IsAvailable(const T *const pT) const; 0065 0066 /** 0067 * @brief Set availability of a cluster, or a list of clusters, to be added to a particle flow object 0068 * 0069 * @param pT the address of the object or object list 0070 * @param isAvailable the availability 0071 */ 0072 template <typename T> 0073 void SetAvailability(const T *const pT, bool isAvailable) const; 0074 0075 /** 0076 * @brief Add a calo hit to a cluster 0077 * 0078 * @param pCluster address of the cluster to modify 0079 * @param pCaloHit address of the hit to add 0080 */ 0081 StatusCode AddToCluster(const Cluster *const pCluster, const CaloHit *const pCaloHit); 0082 0083 /** 0084 * @brief Remove a calo hit from a cluster 0085 * 0086 * @param pCluster address of the cluster to modify 0087 * @param pCaloHit address of the hit to remove 0088 */ 0089 StatusCode RemoveFromCluster(const Cluster *const pCluster, const CaloHit *const pCaloHit); 0090 0091 /** 0092 * @brief Add an isolated calo hit to a cluster. This is not counted as a regular calo hit: it contributes only 0093 * towards the cluster energy and does not affect any other cluster properties. 0094 * 0095 * @param pCluster address of the cluster to modify 0096 * @param pCaloHit address of the hit to add 0097 */ 0098 StatusCode AddIsolatedToCluster(const Cluster *const pCluster, const CaloHit *const pCaloHit); 0099 0100 /** 0101 * @brief Remove an isolated calo hit from a cluster 0102 * 0103 * @param pCluster address of the cluster to modify 0104 * @param pCaloHit address of the hit to remove 0105 */ 0106 StatusCode RemoveIsolatedFromCluster(const Cluster *const pCluster, const CaloHit *const pCaloHit); 0107 0108 /** 0109 * @brief Merge two clusters from two specified lists, enlarging one cluster and deleting the second 0110 * 0111 * @param pClusterToEnlarge address of the cluster to enlarge 0112 * @param pClusterToDelete address of the cluster to delete 0113 * @param enlargeListName name of the list containing the cluster to enlarge 0114 * @param deleteListName name of the list containing the cluster to delete 0115 */ 0116 StatusCode MergeAndDeleteClusters(const Cluster *const pClusterToEnlarge, const Cluster *const pClusterToDelete, 0117 const std::string &enlargeListName, const std::string &deleteListName); 0118 0119 /** 0120 * @brief Add an association between a cluster and a track 0121 * 0122 * @param pCluster the address of the relevant cluster 0123 * @param pTrack the address of the track with which the cluster is associated 0124 */ 0125 StatusCode AddTrackAssociation(const Cluster *const pCluster, const Track *const pTrack) const; 0126 0127 /** 0128 * @brief Remove an association between a cluster and a track 0129 * 0130 * @param pCluster the address of the relevant cluster 0131 * @param pTrack the address of the track with which the cluster is no longer associated 0132 */ 0133 StatusCode RemoveTrackAssociation(const Cluster *const pCluster, const Track *const pTrack) const; 0134 0135 /** 0136 * @brief Remove all cluster to track associations 0137 */ 0138 StatusCode RemoveAllTrackAssociations() const; 0139 0140 /** 0141 * @brief Remove cluster to track associations from all clusters in the current list 0142 * 0143 * @param danglingTracks to receive the list of "dangling" associations 0144 */ 0145 StatusCode RemoveCurrentTrackAssociations(TrackList &danglingTracks) const; 0146 0147 /** 0148 * @brief Remove a specified list of cluster to track associations 0149 * 0150 * @param trackToClusterList the specified track to cluster list 0151 */ 0152 StatusCode RemoveTrackAssociations(const TrackToClusterMap &trackToClusterList) const; 0153 0154 friend class PandoraContentApiImpl; 0155 friend class PandoraImpl; 0156 }; 0157 0158 } // namespace pandora 0159 0160 #endif // #ifndef PANDORA_CLUSTER_MANAGER_H
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|