Index: lutinutil/src/java/org/codelutin/util/HashMapMultiKey.java diff -u lutinutil/src/java/org/codelutin/util/HashMapMultiKey.java:1.4 lutinutil/src/java/org/codelutin/util/HashMapMultiKey.java:1.5 --- lutinutil/src/java/org/codelutin/util/HashMapMultiKey.java:1.4 Wed Oct 5 20:23:46 2005 +++ lutinutil/src/java/org/codelutin/util/HashMapMultiKey.java Thu Oct 27 16:28:00 2005 @@ -23,9 +23,9 @@ * Created: 2 nov. 2004 * * @author Benjamin Poussin - * @version $Revision: 1.4 $ + * @version $Revision: 1.5 $ * - * Mise a jour: $Date: 2005/10/05 20:23:46 $ + * Mise a jour: $Date: 2005/10/27 16:28:00 $ * par : $Author: bpoussin $ */ @@ -93,7 +93,7 @@ protected void cleanQueue(){ Reference o = null; while(null != (o = refQueueValue.poll())) { - if(log.isTraceEnabled()){ log.trace("clean the refQueueValue : " + o.hashCode());} + if(log.isTraceEnabled()){ log.trace("clean the refQueueValue : " + o);} // suppression dans la table des values et recuperation de la cle // associé Object key = valueToKey.remove(o); @@ -107,6 +107,8 @@ list.remove(key); } } + } else { + if(log.isTraceEnabled()){ log.trace("key is null !!! " + o);} } } Index: lutinutil/src/java/org/codelutin/util/TransparenteSoftReference.java diff -u lutinutil/src/java/org/codelutin/util/TransparenteSoftReference.java:1.2 lutinutil/src/java/org/codelutin/util/TransparenteSoftReference.java:1.3 --- lutinutil/src/java/org/codelutin/util/TransparenteSoftReference.java:1.2 Wed Oct 5 20:23:46 2005 +++ lutinutil/src/java/org/codelutin/util/TransparenteSoftReference.java Thu Oct 27 16:28:00 2005 @@ -22,9 +22,9 @@ * * @author Benjamin Poussin * Copyright Code Lutin -* @version $Revision: 1.2 $ +* @version $Revision: 1.3 $ * -* Mise a jour: $Date: 2005/10/05 20:23:46 $ +* Mise a jour: $Date: 2005/10/27 16:28:00 $ * par : $Author: bpoussin $ */ package org.codelutin.util; @@ -43,6 +43,7 @@ public class TransparenteSoftReference extends SoftReference { protected int hash = 0; + protected String toString = null; /** *DOCUMENTME Constructor for the TransparenteSoftReference object @@ -65,6 +66,10 @@ */ protected void init(Object o){ hash = o.hashCode(); + toString = o.toString(); + if(toString == null) { + toString = o.getClass().getName() + '@' + Integer.toHexString(hash); + } } /** @@ -96,4 +101,9 @@ public int hashCode() { return hash; } + + public String toString() { + return toString; + } + } Index: lutinutil/src/java/org/codelutin/util/TransparenteWeakReference.java diff -u lutinutil/src/java/org/codelutin/util/TransparenteWeakReference.java:1.2 lutinutil/src/java/org/codelutin/util/TransparenteWeakReference.java:1.3 --- lutinutil/src/java/org/codelutin/util/TransparenteWeakReference.java:1.2 Wed Oct 5 20:23:46 2005 +++ lutinutil/src/java/org/codelutin/util/TransparenteWeakReference.java Thu Oct 27 16:28:00 2005 @@ -22,9 +22,9 @@ * * @author Benjamin Poussin * Copyright Code Lutin -* @version $Revision: 1.2 $ +* @version $Revision: 1.3 $ * -* Mise a jour: $Date: 2005/10/05 20:23:46 $ +* Mise a jour: $Date: 2005/10/27 16:28:00 $ * par : $Author: bpoussin $ */ package org.codelutin.util; @@ -43,6 +43,7 @@ public class TransparenteWeakReference extends WeakReference { protected int hash = 0; + protected String toString = null; /** *DOCUMENTME Constructor for the TransparenteWeakReference object @@ -65,6 +66,13 @@ */ protected void init(Object o){ hash = o.hashCode(); + toString = o.toString(); + if(toString == null) { + toString = o.getClass().getName() + '@' + Integer.toHexString(hash); + } + if(toString.length() > 100) { + toString = toString.substring(0, 100) + "..."; + } } /** @@ -93,4 +101,9 @@ public int hashCode() { return hash; } + + public String toString() { + return toString; + } + }