Class AMatch
java.lang.Object
org.jlab.clas.detector.matching.AMatch
- All Implemented Interfaces:
Comparator<javafx.util.Pair<DetectorParticle, DetectorResponse>>, IMatch
- Direct Known Subclasses:
MatchCND, MatchDOCA, MatchPOCA, MatchThetaPhi, MatchTrajDistance
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal intFind the best matching response in the given list for the given particle.final intbestMatch(DetectorParticle p, List<DetectorResponse> r, DetectorType t, int l) Find the best matching response in the given list for the given particle.intcompare(javafx.util.Pair<DetectorParticle, DetectorResponse> a, javafx.util.Pair<DetectorParticle, DetectorResponse> b) Compare the quality of two particle-response pairs.final intFind the first matching response in the given list for the given particle.final intfirstMatch(DetectorParticle p, List<DetectorResponse> r, DetectorType t, int l) Find the first matching response in the given list for the given particle.static doublegetDeltaPhi(double phi1, double phi2) static doublegetDeltaPhi(Point3D p1, Point3D p2) final booleanfinal voidsetSharing(boolean sharing) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
AMatch
public AMatch()
-
-
Method Details
-
setSharing
public final void setSharing(boolean sharing) -
getSharing
public final boolean getSharing() -
getDeltaPhi
public static double getDeltaPhi(double phi1, double phi2) -
getDeltaPhi
-
firstMatch
Find the first matching response in the given list for the given particle.- Specified by:
firstMatchin interfaceIMatch- Parameters:
p- the particler- the list of responsest- the requested detector type to considerl- the requested detector layer to consider- Returns:
- the index of the resulting match, else negative
-
firstMatch
Find the first matching response in the given list for the given particle.- Specified by:
firstMatchin interfaceIMatch- Parameters:
p- the particler- the list of responsest- the requested detector type to consider- Returns:
- the index of the resulting match, else negative
-
bestMatch
Find the best matching response in the given list for the given particle. -
bestMatch
Find the best matching response in the given list for the given particle. -
compare
public int compare(javafx.util.Pair<DetectorParticle, DetectorResponse> a, javafx.util.Pair<DetectorParticle, DetectorResponse> b) Compare the quality of two particle-response pairs.- Specified by:
comparein interfaceComparator<javafx.util.Pair<DetectorParticle, DetectorResponse>>- Parameters:
a-b-- Returns:
-