8#include <tracking/trackFindingCDC/eventdata/tracks/CDCAxialSegmentPair.h>
10#include <tracking/trackFindingCDC/eventdata/segments/CDCSegment2D.h>
11#include <tracking/trackFindingCDC/eventdata/segments/CDCAxialSegment2D.h>
13#include <tracking/trackFindingCDC/eventdata/trajectories/CDCTrajectory2D.h>
15#include <tracking/trackFindingCDC/topology/ISuperLayer.h>
17#include <tracking/trackFindingCDC/ca/AutomatonCell.h>
19#include <tracking/trackFindingCDC/numerics/EForwardBackward.h>
21#include <framework/logging/Logger.h>
24using namespace TrackFindingCDC;
33 const CDCAxialSegment2D* endSegment)
37 B2ASSERT(
"CDCAxialSegmentPair initialized with nullptr as start segment", startSegment);
38 B2ASSERT(
"CDCAxialSegmentPair initialized with nullptr as end segment", endSegment);
42 const CDCAxialSegment2D* endSegment,
48 B2ASSERT(
"CDCAxialSegmentPair initialized with nullptr as start segment", startSegment);
49 B2ASSERT(
"CDCAxialSegmentPair initialized with nullptr as end segment", endSegment);
65 const bool toHits =
true;
73 const bool toHits =
true;
80 const bool fromHits =
true;
94 if (startIsCoaligned == EForwardBackward::c_Forward and
95 endIsCoaligned == EForwardBackward::c_Forward) {
96 return EForwardBackward::c_Forward;
97 }
else if (startIsCoaligned == EForwardBackward::c_Backward and
98 endIsCoaligned == EForwardBackward::c_Backward) {
99 return EForwardBackward::c_Backward;
101 return EForwardBackward::c_Invalid;
void setMaskedFlag(bool setTo=true)
Sets the masked flag to the given value. Default value true.
void unsetMaskedFlag()
Resets the masked flag to false.
ISuperLayer getStartISuperLayer() const
Getter for the superlayer id of the start segment.
const CDCAxialSegment2D * getEndSegment() const
Getter for the end segment.
CDCTrajectory2D m_trajectory2D
Reference to the common trajectory.
const CDCAxialSegment2D * m_startSegment
Reference to the start segment.
AutomatonCell & getAutomatonCell() const
Mutable getter for the automaton cell.
void setAndForwardMaskedFlag() const
Sets the masked flag of the segment pair's automaton cell. Also forward the masked flag to the contai...
void unsetAndForwardMaskedFlag() const
Unsets the masked flag of the segment pair's automaton cell, of the contained segments and of the con...
CDCAxialSegmentPair()
Default constructor setting the contained segments to nullptr.
const CDCAxialSegment2D * getStartSegment() const
Getter for the start segment.
const CDCAxialSegment2D * m_endSegment
Reference to the end segment.
ISuperLayer getEndISuperLayer() const
Getter for the superlayer id of the end segment.
EForwardBackward isCoaligned(const CDCTrajectory2D &trajectory2D) const
Checks if the last entity in the vector lies greater or lower travel distance than the last entity.
void receiveMaskedFlag() const
If one of the contained segments is marked as masked this segment pair is set be masked as well.
Particle trajectory as it is seen in xy projection represented as a circle.
EForwardBackward isForwardOrBackwardTo(const AHits &hits) const
Calculates if this trajectory and the hits are coaligned Returns:
Abstract base class for different kinds of events.
static ISuperLayer getFrom(const T &t)
Returns the superlayer of an object.