110 bool p2vassmap =
false;
111 bool v2passmap =
false;
119 if ( ( asstype ==
"PFCandsToVertex" ) || ( asstype ==
"Both" ) ) {
125 if ( ( asstype ==
"VertexToPFCands" ) || ( asstype ==
"Both" ) ) {
131 if ( !p2vassmap && !v2passmap ) {
132 edm::LogWarning(
"FirstVertexParticles") <<
"PFCand_NoPU_WithAM:: No input collection could be found" << endl;
138 if ( p2vAM->size()==0 ) {
139 iEvent.
put( p2v_firstvertex,
"P2V" );
146 for (
unsigned int pfccoll_ite = 0; pfccoll_ite < pfccoll.size(); pfccoll_ite++ ) {
149 int quality = pfccoll[pfccoll_ite].second;
152 p2v_firstvertex->push_back( *pfcand );
157 iEvent.
put( p2v_firstvertex,
"P2V" );
167 VertexRef firstVertexRef(input_vtxcollH,0);
171 for(v2p_ite=v2pAM->begin(); v2p_ite!=v2pAM->end(); v2p_ite++){
175 for(
unsigned v_ite = 0; v_ite<(v2p_ite->
val).
size(); v_ite++){
178 int quality = (v2p_ite->
val)[v_ite].
second;
181 v2p_firstvertex->push_back( *pfcand);
188 iEvent.
put( v2p_firstvertex,
"V2P" );
U second(std::pair< T, U > const &p)
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
std::vector< PFCandQualityPair > PFCandQualityPairVector
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
std::vector< reco::PFCandidate > PFCandidateCollection
collection of PFCandidates
edm::InputTag input_VertexPFCandAssociationMap_
edm::InputTag input_VertexCollection_
edm::InputTag input_AssociationType_
tuple size
Write out results.