9 #include "Pandora/AlgorithmHeaders.h"
18 PostProcessingAlgorithm::PostProcessingAlgorithm() : m_listCounter(0)
27 return STATUS_CODE_SUCCESS;
35 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, this->RenameList<PfoList>(listName));
38 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, this->RenameList<ClusterList>(listName));
41 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, this->RenameList<VertexList>(listName));
44 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, this->RenameList<CaloHitList>(listName));
46 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<CaloHit>(*
this));
47 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<Track>(*
this));
48 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<MCParticle>(*
this));
49 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<Cluster>(*
this));
50 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<ParticleFlowObject>(*
this));
51 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<Vertex>(*
this));
57 if (STATUS_CODE_SUCCESS != PandoraContentApi::ReplaceCurrentList<Pfo>(*
this, replacementListName))
59 if (PandoraContentApi::GetSettings(*this)->ShouldDisplayAlgorithmInfo())
60 std::cout <<
"PostProcessingAlgorithm: could not replace current pfo list with list named: " << replacementListName << std::endl;
62 PANDORA_RETURN_RESULT_IF(STATUS_CODE_SUCCESS, !=, PandoraContentApi::DropCurrentList<Pfo>(*
this));
67 return STATUS_CODE_SUCCESS;
75 const std::string newListName(oldListName + TypeToString(
m_listCounter));
76 PANDORA_RETURN_RESULT_IF_AND_IF(STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=, PandoraContentApi::RenameList<T>(*
this, oldListName, newListName));
77 return STATUS_CODE_SUCCESS;
84 PANDORA_RETURN_RESULT_IF_AND_IF(
85 STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=, XmlHelper::ReadVectorOfValues(xmlHandle,
"PfoListNames",
m_pfoListNames));
87 PANDORA_RETURN_RESULT_IF_AND_IF(
88 STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=, XmlHelper::ReadVectorOfValues(xmlHandle,
"ClusterListNames",
m_clusterListNames));
90 PANDORA_RETURN_RESULT_IF_AND_IF(
91 STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=, XmlHelper::ReadVectorOfValues(xmlHandle,
"VertexListNames",
m_vertexListNames));
93 PANDORA_RETURN_RESULT_IF_AND_IF(
94 STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=, XmlHelper::ReadVectorOfValues(xmlHandle,
"CaloHitListNames",
m_caloHitListNames));
96 PANDORA_RETURN_RESULT_IF_AND_IF(STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=,
99 return STATUS_CODE_SUCCESS;
105 template pandora::StatusCode PostProcessingAlgorithm::RenameList<PfoList>(
const std::string &)
const;
106 template pandora::StatusCode PostProcessingAlgorithm::RenameList<ClusterList>(
const std::string &)
const;
107 template pandora::StatusCode PostProcessingAlgorithm::RenameList<VertexList>(
const std::string &)
const;
108 template pandora::StatusCode PostProcessingAlgorithm::RenameList<CaloHitList>(
const std::string &)
const;
std::string m_currentPfoListReplacement
The name of the pfo list to replace the current list.
pandora::StatusCode Reset()
pandora::StatusCode Run()
pandora::StringVector m_clusterListNames
The list of cluster list names.
Header file for the post processing algorithm class.
unsigned int m_listCounter
The counter appended to output (and replacement current) list names and reset each event...
pandora::StringVector m_caloHitListNames
The list of calo hit list names.
pandora::StringVector m_vertexListNames
The list of vertex list names.
required by fuzzyCluster table::sbnd_g4_services gaushitTruthMatch pandora
pandora::StringVector m_pfoListNames
The list of pfo list names.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
BEGIN_PROLOG could also be cout
pandora::StatusCode RenameList(const std::string &oldListName) const
Rename a list of relevant type with specified name - the new name will be the old name with appended ...