3#ifndef EDM4EIC_TrackSegment_H
4#define EDM4EIC_TrackSegment_H
9#include "podio/RelationRange.h"
12#include "podio/utilities/MaybeSharedPtr.h"
17#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
18#include "nlohmann/json_fwd.hpp"
30class MutableTrackSegment;
31class TrackSegmentCollection;
32class TrackSegmentCollectionData;
84 std::vector<edm4eic::TrackPoint>::const_iterator
points_begin()
const;
85 std::vector<edm4eic::TrackPoint>::const_iterator
points_end()
const;
86 podio::RelationRange<edm4eic::TrackPoint>
getPoints()
const;
92 void unlink() { m_obj = podio::utils::MaybeSharedPtr<TrackSegmentObj>{
nullptr}; }
106 swap(a.m_obj, b.m_obj);
111 explicit TrackSegment(podio::utils::MaybeSharedPtr<TrackSegmentObj> obj);
114 podio::utils::MaybeSharedPtr<TrackSegmentObj> m_obj{
nullptr};
117std::ostream&
operator<<(std::ostream& o,
const TrackSegment& value);
119#if defined(PODIO_JSON_OUTPUT) && !defined(__CLING__)
120void to_json(nlohmann::json& j,
const TrackSegment& value);
Definition MutableTrackSegment.h:37
Definition TrackPoint.h:22
Definition TrackSegmentCollectionData.h:31
Definition TrackSegmentCollection.h:95
Definition TrackSegmentCollection.h:40
Definition TrackSegment.h:38
friend class TrackSegmentCollection
Definition TrackSegment.h:41
float getLength() const
Access the Pathlength from the first to the last point.
Definition TrackSegment.cc:48
friend class MutableTrackSegment
Definition TrackSegment.h:40
std::size_t points_size() const
Definition TrackSegment.cc:72
const podio::ObjectID getObjectID() const
Definition TrackSegment.cc:102
void unlink()
disconnect from TrackSegmentObj instance
Definition TrackSegment.h:92
~TrackSegment()=default
destructor
std::vector< edm4eic::TrackPoint >::const_iterator points_begin() const
Definition TrackSegment.cc:60
std::vector< edm4eic::TrackPoint >::const_iterator points_end() const
Definition TrackSegment.cc:66
bool isAvailable() const
check whether the object is actually available
Definition TrackSegment.cc:95
TrackSegment & operator=(TrackSegment other)
copy-assignment operator
Definition TrackSegment.cc:31
podio::RelationRange< edm4eic::TrackPoint > getPoints() const
Definition TrackSegment.cc:83
bool operator<(const TrackSegment &other) const
Definition TrackSegment.h:98
TrackSegment(const TrackSegment &other)=default
copy constructor
friend void swap(TrackSegment &a, TrackSegment &b)
Definition TrackSegment.h:104
MutableTrackSegment clone() const
create a mutable deep-copy of the object with identical relations
Definition TrackSegment.cc:36
TrackSegment()
default constructor
Definition TrackSegment.cc:22
const edm4eic::Track getTrack() const
Access the Track used for this projection.
Definition TrackSegment.cc:51
podio::ObjectID id() const
Definition TrackSegment.h:100
bool operator==(const TrackSegment &other) const
Definition TrackSegment.h:94
static TrackSegment makeEmpty()
Definition TrackSegment.cc:44
float getLengthError() const
Access the Error on the segment length.
Definition TrackSegment.cc:49
Definition TrackSegmentObj.h:23
Definition CalorimeterHit.cc:18
std::ostream & operator<<(std::ostream &o, const CalorimeterHit &value)
Definition CalorimeterHit.cc:97