Belle II Software development
CDCRLWireHitPair Class Reference

A pair of oriented wire hits. More...

#include <CDCRLWireHitPair.h>

Inheritance diagram for CDCRLWireHitPair:
CDCTangent

Public Member Functions

 CDCRLWireHitPair ()=default
 Default constructor for ROOT.
 
 CDCRLWireHitPair (const CDCRLWireHit &fromRLWireHit, const CDCRLWireHit &toRLWireHit, int iCluster=0)
 Constructor taking two oriented wire hits.
 
CDCRLWireHitPair reversed () const
 Constructs a oriented wire hit pair that is the reverse of this one.
 
void reverse ()
 Reverses the oriented wire hit pair inplace.
 
CDCRLWireHitPair getAlias () const
 Returns the aliased version of this oriented wire hit pair.
 
bool operator== (const CDCRLWireHitPair &other) const
 Equality comparision based the two oriented wire hits.
 
bool operator< (const CDCRLWireHitPair &other) const
 Total ordering relation based on the from oriented wire hit first and the to oriented wire hit second.
 
WireNeighborKind getNeighborKind () const
 Getter for the WireNeighborKind of the two underlying wires.
 
ISuperLayer getISuperLayer () const
 Getter for the common superlayer id of the pair.
 
EStereoKind getStereoKind () const
 Getter for the common stereo type of the superlayer of the pair.
 
bool isAxial () const
 Indicator if the underlying wires are axial.
 
const CDCWiregetFromWire () const
 Getter for the wire the first oriented wire hit is based on.
 
const CDCWiregetToWire () const
 Getter for the wire the second oriented wire hit is based on.
 
bool hasWire (const CDCWire &wire) const
 Indicator if any of the two oriented wire hits is based on the given wire.
 
const CDCWireHitgetFromWireHit () const
 Getter for the hit wire of the first oriented wire hit.
 
const CDCWireHitgetToWireHit () const
 Getter for the hit wire of the second oriented wire hit.
 
bool hasWireHit (const CDCWireHit &wirehit) const
 Indicator if any of the two oriented wire hits is based on the given wire hit.
 
ERightLeft getFromRLInfo () const
 Getter for the right left passage information of the first oriented wire hit.
 
ERightLeft getToRLInfo () const
 Getter for the right left passage information of the second oriented wire hit.
 
CDCRLWireHitgetFromRLWireHit ()
 Getter for the first oriented wire hit.
 
CDCRLWireHitgetToRLWireHit ()
 Getter for the second oriented wire hit.
 
const CDCRLWireHitgetFromRLWireHit () const
 Constant getter for the first oriented wire hit.
 
const CDCRLWireHitgetToRLWireHit () const
 Constant getter for the second oriented wire hit.
 
void setFromRLWireHit (const CDCRLWireHit &fromRLWireHit)
 Setter for the first oriented wire hit.
 
void setToRLWireHit (const CDCRLWireHit &toRLWireHit)
 Setter for the second oriented wire hit.
 
void setFromRLInfo (ERightLeft fromRLInfo)
 Setter for the right left passage information of the first oriented wire hit.
 
void setToRLInfo (ERightLeft toRLInfo)
 Setter for the right left passage information of the second oriented wire hit.
 
int getICluster () const
 Getter for the cluster id.
 
void setICluster (int iCluster)
 Setter for the cluster id.
 

Protected Attributes

CDCRLWireHit m_fromRLWireHit
 Memory for the reference to the first oriented wire hit.
 
CDCRLWireHit m_toRLWireHit
 Memory for the reference to the second oriented wire hit.
 
int m_iCluster = -1
 Memory for the cluster id of this facet.
 

Friends

bool operator< (const CDCRLWireHitPair &rlWireHitPair, const CDCWireHit &wireHit)
 Defines wire hits and oriented wire hit pair as coaligned on the first wire hit.
 
bool operator< (const CDCWireHit &wireHit, const CDCRLWireHitPair &rlWireHitPair)
 Defines wire hits and oriented wire hit pair as coaligned on the first wire hit.
 

Detailed Description

A pair of oriented wire hits.

Definition at line 27 of file CDCRLWireHitPair.h.

Constructor & Destructor Documentation

◆ CDCRLWireHitPair()

CDCRLWireHitPair ( const CDCRLWireHit fromRLWireHit,
const CDCRLWireHit toRLWireHit,
int  iCluster = 0 
)

Constructor taking two oriented wire hits.

Definition at line 22 of file CDCRLWireHitPair.cc.

25 : m_fromRLWireHit(fromRLWireHit)
26 , m_toRLWireHit(toRLWireHit)
27 , m_iCluster(iCluster)
28{
29}
CDCRLWireHit m_fromRLWireHit
Memory for the reference to the first oriented wire hit.
CDCRLWireHit m_toRLWireHit
Memory for the reference to the second oriented wire hit.
int m_iCluster
Memory for the cluster id of this facet.

Member Function Documentation

◆ getAlias()

CDCRLWireHitPair getAlias ( ) const

Returns the aliased version of this oriented wire hit pair.

Definition at line 49 of file CDCRLWireHitPair.cc.

50{
52}
CDCRLWireHit & getToRLWireHit()
Getter for the second oriented wire hit.
CDCRLWireHitPair getAlias() const
Returns the aliased version of this oriented wire hit pair.
int getICluster() const
Getter for the cluster id.
CDCRLWireHit & getFromRLWireHit()
Getter for the first oriented wire hit.
CDCRLWireHitPair()=default
Default constructor for ROOT.

◆ getFromRLInfo()

ERightLeft getFromRLInfo ( ) const
inline

Getter for the right left passage information of the first oriented wire hit.

Definition at line 137 of file CDCRLWireHitPair.h.

138 {
139 return getFromRLWireHit().getRLInfo();
140 }
ERightLeft getRLInfo() const
Getter for the right left passage information.
Definition: CDCRLWireHit.h:234

◆ getFromRLWireHit() [1/2]

CDCRLWireHit & getFromRLWireHit ( )
inline

Getter for the first oriented wire hit.

Definition at line 149 of file CDCRLWireHitPair.h.

150 {
151 return m_fromRLWireHit;
152 }

◆ getFromRLWireHit() [2/2]

const CDCRLWireHit & getFromRLWireHit ( ) const
inline

Constant getter for the first oriented wire hit.

Definition at line 161 of file CDCRLWireHitPair.h.

162 {
163 return m_fromRLWireHit;
164 }

◆ getFromWire()

const CDCWire & getFromWire ( ) const
inline

Getter for the wire the first oriented wire hit is based on.

Definition at line 101 of file CDCRLWireHitPair.h.

102 {
103 return getFromRLWireHit().getWire();
104 }
const CDCWire & getWire() const
Getter for the wire the oriented hit associated to.

◆ getFromWireHit()

const CDCWireHit & getFromWireHit ( ) const
inline

Getter for the hit wire of the first oriented wire hit.

Definition at line 119 of file CDCRLWireHitPair.h.

120 {
121 return getFromRLWireHit().getWireHit();
122 }
const CDCWireHit & getWireHit() const
Getter for the wire hit associated with the oriented hit.
Definition: CDCRLWireHit.h:192

◆ getICluster()

int getICluster ( ) const
inline

Getter for the cluster id.

Definition at line 191 of file CDCRLWireHitPair.h.

192 {
193 return m_iCluster;
194 }

◆ getISuperLayer()

ISuperLayer getISuperLayer ( ) const
inline

Getter for the common superlayer id of the pair.

Definition at line 82 of file CDCRLWireHitPair.h.

83 {
84 ISuperLayer result = getFromRLWireHit().getISuperLayer();
85 return result == getToRLWireHit().getISuperLayer() ? result : ISuperLayerUtil::c_Invalid;
86 }
ISuperLayer getISuperLayer() const
Getter for the superlayer id.
static const ISuperLayer c_Invalid
Constant making an invalid superlayer id.
Definition: ISuperLayer.h:65

◆ getNeighborKind()

WireNeighborKind getNeighborKind ( ) const
inline

Getter for the WireNeighborKind of the two underlying wires.

Definition at line 32 of file CDCRLWireHitPair.cc.

33{
35}
const CDCWire & getFromWire() const
Getter for the wire the first oriented wire hit is based on.
const CDCWire & getToWire() const
Getter for the wire the second oriented wire hit is based on.
WireNeighborKind getNeighborKind(const CDCWire &wire) const
Returns gives the kind of neighborhood relation from this wire to the given wire.
Definition: CDCWire.cc:139

◆ getStereoKind()

EStereoKind getStereoKind ( ) const
inline

Getter for the common stereo type of the superlayer of the pair.

Definition at line 89 of file CDCRLWireHitPair.h.

90 {
92 }
ISuperLayer getISuperLayer() const
Getter for the common superlayer id of the pair.
static EStereoKind getStereoKind(ISuperLayer iSuperLayer)
Returns the stereo kind of the super layer.
Definition: ISuperLayer.cc:26

◆ getToRLInfo()

ERightLeft getToRLInfo ( ) const
inline

Getter for the right left passage information of the second oriented wire hit.

Definition at line 143 of file CDCRLWireHitPair.h.

144 {
145 return getToRLWireHit().getRLInfo();
146 }

◆ getToRLWireHit() [1/2]

CDCRLWireHit & getToRLWireHit ( )
inline

Getter for the second oriented wire hit.

Definition at line 155 of file CDCRLWireHitPair.h.

156 {
157 return m_toRLWireHit;
158 }

◆ getToRLWireHit() [2/2]

const CDCRLWireHit & getToRLWireHit ( ) const
inline

Constant getter for the second oriented wire hit.

Definition at line 167 of file CDCRLWireHitPair.h.

168 {
169 return m_toRLWireHit;
170 }

◆ getToWire()

const CDCWire & getToWire ( ) const
inline

Getter for the wire the second oriented wire hit is based on.

Definition at line 107 of file CDCRLWireHitPair.h.

108 {
109 return getToRLWireHit().getWire();
110 }

◆ getToWireHit()

const CDCWireHit & getToWireHit ( ) const
inline

Getter for the hit wire of the second oriented wire hit.

Definition at line 125 of file CDCRLWireHitPair.h.

126 {
127 return getToRLWireHit().getWireHit();
128 }

◆ hasWire()

bool hasWire ( const CDCWire wire) const
inline

Indicator if any of the two oriented wire hits is based on the given wire.

Definition at line 113 of file CDCRLWireHitPair.h.

114 {
115 return getFromRLWireHit().isOnWire(wire) or getToRLWireHit().isOnWire(wire);
116 }
bool isOnWire(const CDCWire &wire) const
Checks if the oriented hit is associated with the give wire.
Definition: CDCRLWireHit.h:168

◆ hasWireHit()

bool hasWireHit ( const CDCWireHit wirehit) const
inline

Indicator if any of the two oriented wire hits is based on the given wire hit.

Definition at line 131 of file CDCRLWireHitPair.h.

132 {
133 return getFromRLWireHit().hasWireHit(wirehit) or getToRLWireHit().hasWireHit(wirehit);
134 }
bool hasWireHit(const CDCWireHit &wirehit) const
Checks if the oriented hit is associated with the give wire hit.
Definition: CDCRLWireHit.h:198

◆ isAxial()

bool isAxial ( ) const
inline

Indicator if the underlying wires are axial.

Definition at line 95 of file CDCRLWireHitPair.h.

96 {
97 return getStereoKind() == EStereoKind::c_Axial;
98 }
EStereoKind getStereoKind() const
Getter for the common stereo type of the superlayer of the pair.

◆ operator<()

bool operator< ( const CDCRLWireHitPair other) const
inline

Total ordering relation based on the from oriented wire hit first and the to oriented wire hit second.

Definition at line 57 of file CDCRLWireHitPair.h.

58 {
59 return getICluster() < other.getICluster() or
60 (getICluster() == other.getICluster() and
61 (getFromRLWireHit() < other.getFromRLWireHit() or
62 (getFromRLWireHit() == other.getFromRLWireHit() and
63 getToRLWireHit() < other.getToRLWireHit())));
64 }

◆ operator==()

bool operator== ( const CDCRLWireHitPair other) const
inline

Equality comparision based the two oriented wire hits.

Definition at line 47 of file CDCRLWireHitPair.h.

48 {
49 return getFromRLWireHit() == other.getFromRLWireHit() and
50 getToRLWireHit() == other.getToRLWireHit();
51 }

◆ reverse()

void reverse ( )

Reverses the oriented wire hit pair inplace.

Definition at line 42 of file CDCRLWireHitPair.cc.

43{
47}
void reverse()
Swiches the right left passage to its opposite inplace.
Definition: CDCRLWireHit.h:98

◆ reversed()

CDCRLWireHitPair reversed ( ) const

Constructs a oriented wire hit pair that is the reverse of this one.

Definition at line 37 of file CDCRLWireHitPair.cc.

38{
40}
CDCRLWireHitPair reversed() const
Constructs a oriented wire hit pair that is the reverse of this one.

◆ setFromRLInfo()

void setFromRLInfo ( ERightLeft  fromRLInfo)

Setter for the right left passage information of the first oriented wire hit.

Definition at line 54 of file CDCRLWireHitPair.cc.

55{
56 m_fromRLWireHit.setRLInfo(fromRLInfo);
57}
void setRLInfo(const ERightLeft rlInfo)
Setter for the right left passage information.
Definition: CDCRLWireHit.h:240

◆ setFromRLWireHit()

void setFromRLWireHit ( const CDCRLWireHit fromRLWireHit)
inline

Setter for the first oriented wire hit.

Definition at line 173 of file CDCRLWireHitPair.h.

174 {
175 m_fromRLWireHit = fromRLWireHit;
176 }

◆ setICluster()

void setICluster ( int  iCluster)
inline

Setter for the cluster id.

Definition at line 197 of file CDCRLWireHitPair.h.

198 {
199 m_iCluster = iCluster;
200 }

◆ setToRLInfo()

void setToRLInfo ( ERightLeft  toRLInfo)

Setter for the right left passage information of the second oriented wire hit.

Definition at line 59 of file CDCRLWireHitPair.cc.

60{
61 m_toRLWireHit.setRLInfo(toRLInfo);
62}

◆ setToRLWireHit()

void setToRLWireHit ( const CDCRLWireHit toRLWireHit)
inline

Setter for the second oriented wire hit.

Definition at line 179 of file CDCRLWireHitPair.h.

180 {
181 m_toRLWireHit = toRLWireHit;
182 }

Friends And Related Function Documentation

◆ operator< [1/2]

bool operator< ( const CDCRLWireHitPair rlWireHitPair,
const CDCWireHit wireHit 
)
friend

Defines wire hits and oriented wire hit pair as coaligned on the first wire hit.

Definition at line 67 of file CDCRLWireHitPair.h.

68 {
69 return rlWireHitPair.getFromRLWireHit() < wireHit;
70 }

◆ operator< [2/2]

bool operator< ( const CDCWireHit wireHit,
const CDCRLWireHitPair rlWireHitPair 
)
friend

Defines wire hits and oriented wire hit pair as coaligned on the first wire hit.

Definition at line 73 of file CDCRLWireHitPair.h.

74 {
75 return wireHit < rlWireHitPair.getFromRLWireHit();
76 }

Member Data Documentation

◆ m_fromRLWireHit

CDCRLWireHit m_fromRLWireHit
protected

Memory for the reference to the first oriented wire hit.

Definition at line 204 of file CDCRLWireHitPair.h.

◆ m_iCluster

int m_iCluster = -1
protected

Memory for the cluster id of this facet.

Definition at line 210 of file CDCRLWireHitPair.h.

◆ m_toRLWireHit

CDCRLWireHit m_toRLWireHit
protected

Memory for the reference to the second oriented wire hit.

Definition at line 207 of file CDCRLWireHitPair.h.


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