Class ParticipantEvidenceComparator
- java.lang.Object
-
- psidev.psi.mi.jami.utils.comparator.participant.ParticipantEvidenceComparator
-
- All Implemented Interfaces:
Comparator<ParticipantEvidence>
- Direct Known Subclasses:
UnambiguousExactParticipantEvidenceComparator
,UnambiguousParticipantEvidenceComparator
public class ParticipantEvidenceComparator extends Object implements Comparator<ParticipantEvidence>
Basic Experimental participant comparator. It will first compares experimental roles using AbstractCvTermComparator. If both experimental roles are equals, it will look at the identification methods using AbstractCvTermComparator. If both identification methods are equals, it will look at the experimental preparations using AbstractCvTermComparator. If both experimental preparations are equals, it will look at the expressed in organisms using OrganismComparator. If both organisms are the same, it will compare parameters using ParameterComparator- Since:
17/01/13
- Version:
- $Id$
- Author:
- Marine Dumousseau (marine@ebi.ac.uk)
-
-
Constructor Summary
Constructors Constructor Description ParticipantEvidenceComparator(ExperimentalParticipantPoolComparator poolComparator)
Creates a new ParticipantEvidenceComparator
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(ParticipantEvidence experimentalParticipant1, ParticipantEvidence experimentalParticipant2)
It will first compares experimental roles using AbstractCvTermComparator.ExperimentalParticipantPoolComparator
getParticipantPoolComparator()
getParticipantPoolComparator-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
-
-
-
Constructor Detail
-
ParticipantEvidenceComparator
public ParticipantEvidenceComparator(ExperimentalParticipantPoolComparator poolComparator)
Creates a new ParticipantEvidenceComparator- Parameters:
poolComparator
- : the participant pool comparator required to compare basic properties of a participant and participant candidates in case of a pool
-
-
Method Detail
-
getParticipantPoolComparator
public ExperimentalParticipantPoolComparator getParticipantPoolComparator()
getParticipantPoolComparator
- Returns:
- a
ExperimentalParticipantPoolComparator
object.
-
compare
public int compare(ParticipantEvidence experimentalParticipant1, ParticipantEvidence experimentalParticipant2)
It will first compares experimental roles using AbstractCvTermComparator. If both experimental roles are equals, it will look at the identification methods using AbstractCvTermComparator. If both identification methods are equals, it will look at the experimental preparations using AbstractCvTermComparator. If both experimental preparations are equals, it will look at the expressed in organisms using OrganismComparator. If both organisms are the same, it will compare parameters using ParameterComparator- Specified by:
compare
in interfaceComparator<ParticipantEvidence>
- Parameters:
experimentalParticipant1
- aParticipantEvidence
object.experimentalParticipant2
- aParticipantEvidence
object.- Returns:
- a int.
-
-