Public Types | Public Member Functions | Private Types | Private Attributes | List of all members
art::FindMany< ProdB, Data > Class Template Reference

#include "/cvmfs/nova.opensciencegrid.org/externals/canvas/v3_09_01/source/canvas/Persistency/Common/FindMany.h"

Public Types

using dataColl_t = std::vector< std::vector< Data const * >>
 
using value_type = typename base::value_type
 
using size_type = typename base::size_type
 
using difference_type = typename base::difference_type
 
using const_reference = typename base::const_reference
 
using reference = typename base::reference
 
using assoc_t = typename base::assoc_t
 
using data_const_pointer = typename dataColl_t::const_pointer
 
using data_const_reference = typename dataColl_t::const_reference
 
using data_reference = typename dataColl_t::reference
 
using data_t = Data
 

Public Member Functions

template<typename Handle , typename DataContainer , typename Tag >
 FindMany (Handle const &aCollection, DataContainer const &dc, Tag const &tag, std::enable_if_t< detail::is_handle< Handle >::value > *=nullptr)
 
template<typename ProdAColl , typename DataContainer , typename Tag >
 FindMany (ProdAColl const &view, DataContainer const &dc, Tag const &tag, std::enable_if_t< std::is_pointer_v< typename ProdAColl::value_type >> *=nullptr)
 
template<typename PtrProdAColl , typename DataContainer , typename Tag >
 FindMany (PtrProdAColl const &aPtrColl, DataContainer const &dc, Tag const &tag, std::enable_if_t< std::is_same_v< typename PtrProdAColl::value_type, art::Ptr< typename PtrProdAColl::value_type::value_type >>> *=nullptr)
 
template<typename ProdA , typename DataContainer , typename Tag >
 FindMany (std::initializer_list< Ptr< ProdA >> const &ptrs, DataContainer const &dc, Tag const &tag)
 
data_const_reference data (size_type i) const
 
size_type get (size_type i, reference item, data_reference data) const
 
bool operator== (FindMany< ProdB, Data > const &other) const
 

Private Types

using base = FindMany< ProdB, void >
 

Private Attributes

dataColl_t dataCollection_ {}
 

Detailed Description

template<typename ProdB, typename Data>
class art::FindMany< ProdB, Data >

Definition at line 140 of file FindMany.h.

Member Typedef Documentation

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::assoc_t = typename base::assoc_t

Definition at line 229 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::base = FindMany<ProdB, void>
private

Definition at line 220 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::const_reference = typename base::const_reference

Definition at line 227 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::data_const_pointer = typename dataColl_t::const_pointer

Definition at line 231 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::data_const_reference = typename dataColl_t::const_reference

Definition at line 232 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::data_reference = typename dataColl_t::reference

Definition at line 233 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::data_t = Data

Definition at line 235 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::dataColl_t = std::vector<std::vector<Data const*>>

Definition at line 223 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::difference_type = typename base::difference_type

Definition at line 226 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::reference = typename base::reference

Definition at line 228 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::size_type = typename base::size_type

Definition at line 225 of file FindMany.h.

template<typename ProdB, typename Data>
using art::FindMany< ProdB, Data >::value_type = typename base::value_type

Definition at line 224 of file FindMany.h.

Constructor & Destructor Documentation

template<typename ProdB , typename Data >
template<typename Handle , typename DataContainer , typename Tag >
art::FindMany< ProdB, Data >::FindMany ( Handle const &  aCollection,
DataContainer const &  dc,
Tag const &  tag,
std::enable_if_t< detail::is_handle< Handle >::value > *  = nullptr 
)

Definition at line 393 of file FindMany.h.

References art::FindMany< ProdB, void >::bCollection(), art::FindMany< ProdB, Data >::dataCollection_, art::FindMany< ProdB, void >::setStoredException(), and getGoodRuns4SAM::tag.

397 {
398  using ProdA = typename Handle::element_type::value_type;
399  detail::IPRHelper<ProdA, ProdB, Data, dataColl_t, DataContainer> finder{
400  dc, detail::input_tag<ProdA, ProdB, void>(tag)};
402  finder(*aCollection, base::bCollection(), dataCollection_));
403 }
dataColl_t dataCollection_
Definition: FindMany.h:277
void setStoredException(std::shared_ptr< art::Exception const > &&e)
Definition: FindMany.h:373
template<typename ProdB , typename Data >
template<typename ProdAColl , typename DataContainer , typename Tag >
art::FindMany< ProdB, Data >::FindMany ( ProdAColl const &  view,
DataContainer const &  dc,
Tag const &  tag,
std::enable_if_t< std::is_pointer_v< typename ProdAColl::value_type >> *  = nullptr 
)

Definition at line 407 of file FindMany.h.

References art::FindMany< ProdB, void >::bCollection(), art::FindMany< ProdB, Data >::dataCollection_, art::FindMany< ProdB, void >::setStoredException(), and getGoodRuns4SAM::tag.

411 {
412  using ProdA =
413  std::remove_const_t<std::remove_pointer_t<typename ProdAColl::value_type>>;
414  detail::IPRHelper<ProdA, ProdB, Data, dataColl_t, DataContainer> finder{
415  dc, detail::input_tag<ProdA, ProdB, void>(tag)};
417 }
dataColl_t dataCollection_
Definition: FindMany.h:277
void setStoredException(std::shared_ptr< art::Exception const > &&e)
Definition: FindMany.h:373
template<typename ProdB , typename Data >
template<typename PtrProdAColl , typename DataContainer , typename Tag >
art::FindMany< ProdB, Data >::FindMany ( PtrProdAColl const &  aPtrColl,
DataContainer const &  dc,
Tag const &  tag,
std::enable_if_t< std::is_same_v< typename PtrProdAColl::value_type, art::Ptr< typename PtrProdAColl::value_type::value_type >>> *  = nullptr 
)

Definition at line 421 of file FindMany.h.

References art::FindMany< ProdB, void >::bCollection(), art::FindMany< ProdB, Data >::dataCollection_, art::FindMany< ProdB, void >::setStoredException(), and getGoodRuns4SAM::tag.

427 {
428  using ProdA = typename PtrProdAColl::value_type::value_type;
429  detail::IPRHelper<ProdA, ProdB, Data, dataColl_t, DataContainer> finder{
430  dc, detail::input_tag<ProdA, ProdB, Data>(tag)};
432  finder(aPtrColl, base::bCollection(), dataCollection_));
433 }
dataColl_t dataCollection_
Definition: FindMany.h:277
void setStoredException(std::shared_ptr< art::Exception const > &&e)
Definition: FindMany.h:373
template<typename ProdB , typename Data >
template<typename ProdA , typename DataContainer , typename Tag >
art::FindMany< ProdB, Data >::FindMany ( std::initializer_list< Ptr< ProdA >> const &  ptrs,
DataContainer const &  dc,
Tag const &  tag 
)

Definition at line 437 of file FindMany.h.

References art::FindMany< ProdB, void >::bCollection(), art::FindMany< ProdB, Data >::dataCollection_, art::FindMany< ProdB, void >::setStoredException(), and getGoodRuns4SAM::tag.

441 {
442  detail::IPRHelper<ProdA, ProdB, Data, dataColl_t, DataContainer> finder{
443  dc, detail::input_tag<ProdA, ProdB, Data>(tag)};
445 }
dataColl_t dataCollection_
Definition: FindMany.h:277
void setStoredException(std::shared_ptr< art::Exception const > &&e)
Definition: FindMany.h:373

Member Function Documentation

template<typename ProdB , typename Data >
auto art::FindMany< ProdB, Data >::data ( size_type  i) const
inline
template<typename ProdB , typename Data >
auto art::FindMany< ProdB, Data >::get ( size_type  i,
reference  item,
data_reference  data 
) const
inline

Definition at line 455 of file FindMany.h.

References art::FindMany< ProdB, Data >::dataCollection_, art::FindMany< ProdB, void >::get(), MECModelEnuComparisons::i, and fillBadChanDBTables::result.

Referenced by skim::SkimmerAna::FillNumuHistograms(), skim::CosmicBeamComparison::FillNumuHistograms(), skim::SkimmingUtils::FillSliceMap(), and skim::SkimmingUtils::FillSliceVector().

458 {
459  size_type result = base::get(i, item); // Will check validity.
461  data.insert(data.end(), ref.begin(), ref.end());
462  ;
463  return result;
464 }
size_type get(size_type i, reference item) const
Definition: FindMany.h:357
const XML_Char const XML_Char * data
Definition: expat.h:268
dataColl_t dataCollection_
Definition: FindMany.h:277
typename base::size_type size_type
Definition: FindMany.h:225
typename dataColl_t::const_reference data_const_reference
Definition: FindMany.h:232
template<typename ProdB , typename Data >
bool art::FindMany< ProdB, Data >::operator== ( FindMany< ProdB, Data > const &  other) const
inline

Definition at line 467 of file FindMany.h.

References art::FindMany< ProdB, Data >::dataCollection_, and art::FindMany< ProdB, void >::operator==().

468 {
469  return this->base::operator==(other) && // Will check validity.
470  dataCollection_ == other.dataCollection_;
471 }
dataColl_t dataCollection_
Definition: FindMany.h:277
bool operator==(FindMany< ProdB, void > const &other) const
Definition: FindMany.h:366

Member Data Documentation

template<typename ProdB, typename Data>
dataColl_t art::FindMany< ProdB, Data >::dataCollection_ {}
private

The documentation for this class was generated from the following file: