Class UnambiguousExactNucleicAcidComparator
- java.lang.Object
-
- psidev.psi.mi.jami.utils.comparator.interactor.NucleicAcidComparator
-
- psidev.psi.mi.jami.utils.comparator.interactor.UnambiguousExactNucleicAcidComparator
-
- All Implemented Interfaces:
Comparator<NucleicAcid>
public class UnambiguousExactNucleicAcidComparator extends NucleicAcidComparator
Unambiguous exact nucleic acids comparator. It will first use UnambiguousExactPolymerBaseComparator to compare the basic interactor properties. If the basic polymer properties are the same, It will look for DDBJ/EMBL/Genbank identifier. If the DDBJ/EMBL/Genbank identifiers are identical, it will look at the Refseq identifiers.- Since:
17/01/13
- Version:
- $Id$
- Author:
- Marine Dumousseau (marine@ebi.ac.uk)
-
-
Constructor Summary
Constructors Constructor Description UnambiguousExactNucleicAcidComparator()
Creates a new DefaultExactNucleicAcidComparator.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static boolean
areEquals(NucleicAcid nucleicAcid1, NucleicAcid nucleicAcid2)
Use UnambiguousExactNucleicAcidComparator to know if two nucleic acids are equals.int
compare(NucleicAcid nucleicAcid1, NucleicAcid nucleicAcid2)
It will first use UnambiguousPolymerComparator to compare the basic interactor properties.UnambiguousExactPolymerComparator
getInteractorComparator()
Getter for the fieldinteractorComparator
.-
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
-
compare
public int compare(NucleicAcid nucleicAcid1, NucleicAcid nucleicAcid2)
Description copied from class:NucleicAcidComparator
It will first use UnambiguousPolymerComparator to compare the basic interactor properties. If the basic polymer properties are the same, It will look for DDBJ/EMBL/Genbank identifier. If the DDBJ/EMBL/Genbank identifiers are identical, it will look at the Refseq identifiers.- Specified by:
compare
in interfaceComparator<NucleicAcid>
- Overrides:
compare
in classNucleicAcidComparator
- Parameters:
nucleicAcid1
- aNucleicAcid
object.nucleicAcid2
- aNucleicAcid
object.- Returns:
- a int.
-
getInteractorComparator
public UnambiguousExactPolymerComparator getInteractorComparator()
Getter for the field
interactorComparator
.- Overrides:
getInteractorComparator
in classNucleicAcidComparator
- Returns:
- a
PolymerComparator
object.
-
areEquals
public static boolean areEquals(NucleicAcid nucleicAcid1, NucleicAcid nucleicAcid2)
Use UnambiguousExactNucleicAcidComparator to know if two nucleic acids are equals.- Parameters:
nucleicAcid1
- aNucleicAcid
object.nucleicAcid2
- aNucleicAcid
object.- Returns:
- true if the two nucleic acids are equal
-
-