Class UnambiguousCooperativeEffectBaseComparator
- java.lang.Object
-
- psidev.psi.mi.jami.utils.comparator.cooperativity.CooperativeEffectBaseComparator
-
- psidev.psi.mi.jami.utils.comparator.cooperativity.UnambiguousCooperativeEffectBaseComparator
-
- All Implemented Interfaces:
Comparator<CooperativeEffect>
public class UnambiguousCooperativeEffectBaseComparator extends CooperativeEffectBaseComparator
Unambiguous comparator for CooperativeEffect It will first compare the outcome using UnambiguousCvTermComparator. Then it will compare the response using UnambiguousCvTermComparator. Then it will compare the CooperativityEvidences using UnambiguousCooperativityEvidenceComparator. Finally it will compare the affected interactions using UnambiguousModelledInteractionComparator- Since:
23/05/13
- Version:
- $Id$
- Author:
- Marine Dumousseau (marine@ebi.ac.uk)
-
-
Constructor Summary
Constructors Constructor Description UnambiguousCooperativeEffectBaseComparator()
Constructor for UnambiguousCooperativeEffectBaseComparator.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static boolean
areEquals(CooperativeEffect effect1, CooperativeEffect effect2)
Use UnambiguousCooperativeEffectBaseComparator to know if two CooperativeEffects are equals.int
compare(CooperativeEffect effect1, CooperativeEffect effect2)
It will first compare the outcome using UnambiguousCvTermComparator.UnambiguousCvTermComparator
getCvTermComparator()
Getter for the fieldcvTermComparator
.static int
hashCode(CooperativeEffect effect)
hashCode-
Methods inherited from class psidev.psi.mi.jami.utils.comparator.cooperativity.CooperativeEffectBaseComparator
getCooperativityEvidenceCollectionComparator, getModelledInteractionCollectionComparator
-
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
-
-
-
-
Method Detail
-
getCvTermComparator
public UnambiguousCvTermComparator getCvTermComparator()
Getter for the field
cvTermComparator
.- Overrides:
getCvTermComparator
in classCooperativeEffectBaseComparator
- Returns:
- a
Comparator
object.
-
compare
public int compare(CooperativeEffect effect1, CooperativeEffect effect2)
It will first compare the outcome using UnambiguousCvTermComparator. Then it will compare the response using UnambiguousCvTermComparator. Then it will compare the CooperativityEvidences using UnambiguousCooperativityEvidenceComparator. Finally it will compare the affected interactions using UnambiguousModelledInteractionComparator- Specified by:
compare
in interfaceComparator<CooperativeEffect>
- Overrides:
compare
in classCooperativeEffectBaseComparator
- Parameters:
effect1
- aCooperativeEffect
object.effect2
- aCooperativeEffect
object.- Returns:
- a int.
-
areEquals
public static boolean areEquals(CooperativeEffect effect1, CooperativeEffect effect2)
Use UnambiguousCooperativeEffectBaseComparator to know if two CooperativeEffects are equals.- Parameters:
effect1
- aCooperativeEffect
object.effect2
- aCooperativeEffect
object.- Returns:
- true if the two CooperativeEffects are equal
-
hashCode
public static int hashCode(CooperativeEffect effect)
hashCode
- Parameters:
effect
- aCooperativeEffect
object.- Returns:
- the hashcode consistent with the equals method for this comparator
-
-