diff --git a/xtandempipeline/debian/changelog b/xtandempipeline/debian/changelog index aeef40e070efb9702efbbe4124703ff3ea2cbe39..81357770c8bf41d4b51140d97f548b476a6c8b71 100644 --- a/xtandempipeline/debian/changelog +++ b/xtandempipeline/debian/changelog @@ -3,6 +3,7 @@ xtandempipeline (3.1.2-1) natty; urgency=low * Work In Progress * ODS export * Didier Chevret has found a bug (fixed in this version) : error writing MS sample name in project file + * HashCode collision problem on huge data file fixed for HashPeptide -- Olivier Langella <Olivier.Langella@moulon.inra.fr> Sun, 8 May 2011 9:18:51 +0200 diff --git a/xtandempipeline/src/fr/inra/pappso/xtandempipeline/grouping/HashPeptide.java b/xtandempipeline/src/fr/inra/pappso/xtandempipeline/grouping/HashPeptide.java index c906f26d3f15afc73412c5543348432658e74e70..60dc0535cd651c1ff5e55ef8528c1797ac57196a 100644 --- a/xtandempipeline/src/fr/inra/pappso/xtandempipeline/grouping/HashPeptide.java +++ b/xtandempipeline/src/fr/inra/pappso/xtandempipeline/grouping/HashPeptide.java @@ -19,12 +19,25 @@ public class HashPeptide extends HashKey4Groups { + sequence).hashCode(); } + @Override + public boolean equals(Object toCompare) { + if (this.hashCode() == toCompare.hashCode()) { + //very good idea Benoit ! + HashPeptide toComparePeptide = (HashPeptide) toCompare; + if ((this.hashSampleScan == toComparePeptide.hashSampleScan) + && (this.sequence == toComparePeptide.sequence)) { + return true; + } + } + return false; + } + @Override public String toString() { - return hashSampleScan.toString()+" "+sequence; - + return hashSampleScan.toString() + " " + sequence; + } - + @Override public int hashCode() { return this.hascode;