Public Types | Public Member Functions | List of all members
proxy::SpacePointWithCharge< CollProxy > Struct Template Reference

Proxy class for charged space point proxy elements. More...

#include <ChargedSpacePoints.h>

Inheritance diagram for proxy::SpacePointWithCharge< CollProxy >:
proxy::CollectionProxyElement< CollProxy >

Public Types

using base_t = CollectionProxyElement< CollProxy >
 Base type. More...
 
- Public Types inherited from proxy::CollectionProxyElement< CollProxy >
using collection_proxy_t = CollProxy
 
using main_element_t = typename collection_proxy_t::main_element_t
 
using aux_elements_t = typename details::SubstituteWithAuxList< typename collection_proxy_t::aux_collections_t >::type
 Tuple of elements (expected to be tagged types). More...
 

Public Member Functions

recob::PointCharge const & chargeInfo () const
 
Full data object access
recob::SpacePoint const & point () const
 Returns the original space point. More...
 
Direct space point interface
auto ID () const
 Returns the ID of the space point. More...
 
geo::Point_t position () const
 Returns the position of the space point. More...
 
Direct charge interface
recob::PointCharge::Charge_t charge () const
 
bool hasCharge () const
 
- Public Member Functions inherited from proxy::CollectionProxyElement< CollProxy >
 CollectionProxyElement (std::size_t index, main_element_t const &main, aux_elements_t &&auxData)
 
main_element_t const * operator-> () const
 Returns a pointer to the main element. More...
 
main_element_t const & operator* () const
 Returns a reference to the main element. More...
 
std::size_t index () const
 Returns the index of this element in the collection. More...
 
template<typename Tag >
auto get () const -> decltype(auto)
 Returns the auxiliary data specified by type (Tag). More...
 
template<typename Tag , typename T = Tag const&>
auto getIf () const -> decltype(auto)
 Returns the auxiliary data specified by type (Tag). More...
 

Additional Inherited Members

- Static Public Member Functions inherited from proxy::CollectionProxyElement< CollProxy >
template<typename Tag >
static constexpr bool has ()
 Returns whether this class knowns about the specified type (Tag). More...
 

Detailed Description

template<typename CollProxy>
struct proxy::SpacePointWithCharge< CollProxy >

Proxy class for charged space point proxy elements.

Template Parameters
CollProxytype of point proxy collection to get data from
See also
proxy::CollectionProxyElement, proxy::ChargedSpacePointsCollectionProxy

For details on the space point interface see proxy::ChargedSpacePoints.

Definition at line 244 of file ChargedSpacePoints.h.

Member Typedef Documentation

template<typename CollProxy >
using proxy::SpacePointWithCharge< CollProxy >::base_t = CollectionProxyElement<CollProxy>

Base type.

Definition at line 246 of file ChargedSpacePoints.h.

Member Function Documentation

template<typename CollProxy >
recob::PointCharge::Charge_t proxy::SpacePointWithCharge< CollProxy >::charge ( ) const
inline

Returns the charge associated to this point

See also
recob::PointCharge::charge()

Definition at line 287 of file ChargedSpacePoints.h.

288  { return chargeInfo().charge(); }
constexpr Charge_t charge() const
Returns the stored value of the reconstructed charge.
Definition: PointCharge.h:65
recob::PointCharge const & chargeInfo() const
template<typename CollProxy >
recob::PointCharge const& proxy::SpacePointWithCharge< CollProxy >::chargeInfo ( ) const
inline

Returns the recob::PointCharge object with the complete charge information.

Definition at line 263 of file ChargedSpacePoints.h.

264  { return base_t::template get<ChargedSpacePoints::ChargeTag>(); }
template<typename CollProxy >
bool proxy::SpacePointWithCharge< CollProxy >::hasCharge ( ) const
inline

Returns whether the charge associated to the space point is valid.

See also
recob::PointCharge::hasCharge()

Definition at line 292 of file ChargedSpacePoints.h.

292 { return chargeInfo().hasCharge(); }
constexpr bool hasCharge() const
Returns whether the reconstructed charge value is valid.
Definition: PointCharge.h:76
recob::PointCharge const & chargeInfo() const
template<typename CollProxy >
auto proxy::SpacePointWithCharge< CollProxy >::ID ( ) const
inline

Returns the ID of the space point.

Definition at line 271 of file ChargedSpacePoints.h.

271 { return point().ID(); }
recob::SpacePoint const & point() const
Returns the original space point.
ID_t ID() const
Definition: SpacePoint.h:75
template<typename CollProxy >
recob::SpacePoint const& proxy::SpacePointWithCharge< CollProxy >::point ( ) const
inline

Returns the original space point.

Definition at line 256 of file ChargedSpacePoints.h.

256 { return base_t::operator*(); }
main_element_t const & operator*() const
Returns a reference to the main element.
template<typename CollProxy >
geo::Point_t proxy::SpacePointWithCharge< CollProxy >::position ( ) const
inline

Returns the position of the space point.

Definition at line 274 of file ChargedSpacePoints.h.

275  { return geo::vect::makePointFromCoords(point().XYZ()); }
GENVECTOR_CONSTEXPR::geo::Point_t makePointFromCoords(Coords &&coords)
Creates a geo::Point_t from its coordinates (see makeFromCoords()).
recob::SpacePoint const & point() const
Returns the original space point.

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