Class ModelledParticipantPoolComparator
- java.lang.Object
-
- psidev.psi.mi.jami.utils.comparator.participant.ModelledParticipantPoolComparator
-
- All Implemented Interfaces:
Comparator<ModelledParticipantPool>
- Direct Known Subclasses:
UnambiguousExactModelledParticipantPoolComparator
,UnambiguousModelledParticipantPoolComparator
public class ModelledParticipantPoolComparator extends Object implements Comparator<ModelledParticipantPool>
Basic biological participant pool comparator. It will compare the basic properties of a biological participant pool using ParticipantBaseComparator. Then features will be compared with ModelledFeatureComparator. All the participant candidates will be compared using ModelledEntityComparator This comparator will ignore all the other properties of a biological participant.- Since:
13/02/13
- Version:
- $Id$
- Author:
- Marine Dumousseau (marine@ebi.ac.uk)
-
-
Constructor Summary
Constructors Constructor Description ModelledParticipantPoolComparator(ParticipantBaseComparator participantBaseComparator, CollectionComparator<ModelledFeature> featureComparator, CollectionComparator<ModelledEntity> entityComparator)
Creates a new ComponentComparatorModelledParticipantPoolComparator(ParticipantBaseComparator participantBaseComparator, ModelledFeatureComparator featureComparator, ModelledEntityComparator entityComparator)
Creates a new ComponentComparator
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(ModelledParticipantPool bioParticipant1, ModelledParticipantPool bioParticipant2)
It will compare the basic properties of a biological participant pool using ParticipantBaseComparator.CollectionComparator<ModelledFeature>
getFeatureCollectionComparator()
Getter for the fieldfeatureCollectionComparator
.Comparator<ModelledEntity>
getModelledEntityComparator()
Getter for the fieldmodelledEntityComparator
.ParticipantBaseComparator
getParticipantBaseComparator()
Getter for the fieldparticipantBaseComparator
.-
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
-
ModelledParticipantPoolComparator
public ModelledParticipantPoolComparator(ParticipantBaseComparator participantBaseComparator, ModelledFeatureComparator featureComparator, ModelledEntityComparator entityComparator)
Creates a new ComponentComparator- Parameters:
participantBaseComparator
- aParticipantBaseComparator
object.featureComparator
- aModelledFeatureComparator
object.entityComparator
- aModelledEntityComparator
object.
-
ModelledParticipantPoolComparator
public ModelledParticipantPoolComparator(ParticipantBaseComparator participantBaseComparator, CollectionComparator<ModelledFeature> featureComparator, CollectionComparator<ModelledEntity> entityComparator)
Creates a new ComponentComparator- Parameters:
participantBaseComparator
- aParticipantBaseComparator
object.featureComparator
- aCollectionComparator
object.entityComparator
- aCollectionComparator
object.
-
-
Method Detail
-
getModelledEntityComparator
public Comparator<ModelledEntity> getModelledEntityComparator()
Getter for the field
modelledEntityComparator
.- Returns:
- a
Comparator
object.
-
getParticipantBaseComparator
public ParticipantBaseComparator getParticipantBaseComparator()
Getter for the field
participantBaseComparator
.- Returns:
- a
ParticipantBaseComparator
object.
-
getFeatureCollectionComparator
public CollectionComparator<ModelledFeature> getFeatureCollectionComparator()
Getter for the field
featureCollectionComparator
.- Returns:
- a
CollectionComparator
object.
-
compare
public int compare(ModelledParticipantPool bioParticipant1, ModelledParticipantPool bioParticipant2)
It will compare the basic properties of a biological participant pool using ParticipantBaseComparator. Then features will be compared with ModelledFeatureComparator. All the participant candidates will be compared using ModelledEntityComparator This comparator will ignore all the other properties of a biological participant.- Specified by:
compare
in interfaceComparator<ModelledParticipantPool>
- Parameters:
bioParticipant1
- aModelledParticipantPool
object.bioParticipant2
- aModelledParticipantPool
object.- Returns:
- a int.
-
-