Public Types | Static Public Member Functions | Private Types | List of all members
proxy::ParallelDataProxyMaker< Main, Aux, CollProxy, Tag, AuxColl > Class Template Reference

Creates an associated data wrapper for the specified types. More...

#include <ParallelDataProxyMaker.h>

Inheritance diagram for proxy::ParallelDataProxyMaker< Main, Aux, CollProxy, Tag, AuxColl >:
proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, Tag >

Public Types

using main_element_t = Main
 Type of the main datum. More...
 
using aux_collection_t = AuxColl
 Type of the auxiliary data product. More...
 
using aux_element_t = Aux
 Type of the auxiliary datum. More...
 
using aux_collection_proxy_t = details::ParallelData< aux_collection_t, aux_element_t, data_tag >
 Type of associated data proxy being created. More...
 
- Public Types inherited from proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, Tag >
using data_tag = Tag
 Tag labelling the associated data we are going to produce. More...
 
using main_element_t = Main
 Type of the main datum. More...
 
using aux_collection_t = AuxColl
 Type of the auxiliary data product. More...
 
using aux_element_t = Aux
 Type of the auxiliary datum. More...
 
using aux_collection_proxy_t = details::ParallelData< aux_collection_t, aux_element_t, data_tag >
 Type of associated data proxy being created. More...
 

Static Public Member Functions

template<typename Event , typename Handle , typename MainArgs , typename... Args>
static auto make (Event const &event, Handle &&mainHandle, MainArgs const &margs, Args &&...args)
 Create a association proxy collection using main collection tag. More...
 
- Static Public Member Functions inherited from proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, Tag >
static auto make (Event const &event, Handle &&mainHandle, MainArgs const &mainArgs)
 Create a parallel data proxy collection using main collection tag. More...
 
static auto make (Event const &event, Handle &&mainHandle, MainArgs const &, art::InputTag const &auxInputTag)
 Create a parallel data proxy collection using the specified tag. More...
 
static auto make (Event const &, Handle &&, MainArgs const &, aux_collection_t const &auxColl)
 Create a parallel data proxy collection using the specified tag. More...
 

Private Types

using base_t = ParallelDataProxyMakerBase< Main, AuxColl, Aux, Tag >
 

Detailed Description

template<typename Main, typename Aux, typename CollProxy, typename Tag = Aux, typename AuxColl = std::vector<Aux>>
class proxy::ParallelDataProxyMaker< Main, Aux, CollProxy, Tag, AuxColl >

Creates an associated data wrapper for the specified types.

Template Parameters
Maintype of main datum (element) to associate from ("left")
Auxtype of datum (element) to associate to ("right")
CollProxytype of proxy this associated data works for
Tagtag for the association proxy to be created
AuxColltype of the auxiliary data (default: std::vector<Aux>)
See also
withParallelDataAs(), wrapParallelDataAs()

This class is (indirectly) called when using proxy::withParallelData() in getCollection(). Its task is to supervise the creation of the proxy to the auxiliary data parallel to the main data type. The interface required by withParallelData() includes:

This class can be specialized (see withParallelData() for an example). The default implementation just wraps a one-to-many std::vector<Aux> data product fulfilling "parallel data product" requirement (see the "Definitions" section in ProxyBase.h documentation).

The last template argument is designed for specialization of auxiliary data in the context of a specific proxy type.

Definition at line 207 of file ParallelDataProxyMaker.h.

Member Typedef Documentation

template<typename Main , typename Aux , typename CollProxy , typename Tag = Aux, typename AuxColl = std::vector<Aux>>
using proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, AuxTag >::aux_collection_proxy_t = details::ParallelData<aux_collection_t, aux_element_t, data_tag>

Type of associated data proxy being created.

Definition at line 85 of file ParallelDataProxyMaker.h.

template<typename Main , typename Aux , typename CollProxy , typename Tag = Aux, typename AuxColl = std::vector<Aux>>
using proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, AuxTag >::aux_collection_t = AuxColl

Type of the auxiliary data product.

Definition at line 78 of file ParallelDataProxyMaker.h.

template<typename Main , typename Aux , typename CollProxy , typename Tag = Aux, typename AuxColl = std::vector<Aux>>
using proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, AuxTag >::aux_element_t = Aux

Type of the auxiliary datum.

Definition at line 81 of file ParallelDataProxyMaker.h.

template<typename Main , typename Aux , typename CollProxy , typename Tag = Aux, typename AuxColl = std::vector<Aux>>
using proxy::ParallelDataProxyMaker< Main, Aux, CollProxy, Tag, AuxColl >::base_t = ParallelDataProxyMakerBase<Main, AuxColl, Aux, Tag>
private

Definition at line 215 of file ParallelDataProxyMaker.h.

template<typename Main , typename Aux , typename CollProxy , typename Tag = Aux, typename AuxColl = std::vector<Aux>>
using proxy::ParallelDataProxyMakerBase< Main, AuxColl, Aux, AuxTag >::main_element_t = Main

Type of the main datum.

Definition at line 75 of file ParallelDataProxyMaker.h.

Member Function Documentation

template<typename Main , typename Aux , typename CollProxy , typename Tag = Aux, typename AuxColl = std::vector<Aux>>
template<typename Event , typename Handle , typename MainArgs , typename... Args>
static auto proxy::ParallelDataProxyMaker< Main, Aux, CollProxy, Tag, AuxColl >::make ( Event const &  event,
Handle &&  mainHandle,
MainArgs const &  margs,
Args &&...  args 
)
inlinestatic

Create a association proxy collection using main collection tag.

Template Parameters
Eventtype of the event to read associations from
Handletype of data product handle
MainArgsany type convertible to art::InputTag
Argsoptional single type (art::InputTag required)
Parameters
eventthe event to read associations from
mainHandlehandle of the main collection data product
margsan object describing the main data product
argsinput tag for parallel data, if different from main
Returns
an auxiliary data proxy object

The returned object exposes a random access container interface, with data indexed by the index of the corresponding object in the main collection.

This implementation requires margs object to be convertible by explicit type cast into a art::InputTag; that input tag will be used to fetch the association.

Definition at line 254 of file ParallelDataProxyMaker.h.

258  {
259  return base_t::make(
260  event,
261  std::forward<Handle>(mainHandle),
262  margs,
263  std::forward<Args>(args)...
264  );
265  }
static QCString args
Definition: declinfo.cpp:674
static auto make(Event const &event, Handle &&mainHandle, MainArgs const &mainArgs)
Create a parallel data proxy collection using main collection tag.
Event finding and building.

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