Author: tchemit Date: 2010-02-22 10:54:12 +0100 (Mon, 22 Feb 2010) New Revision: 1811 Modified: trunk/topia-persistence/src/main/java/org/nuiton/topia/persistence/util/TopiaEntityBinder.java Log: let TopiaEntityBinder still implements Loador contract to make easier migration (and breaks no client code) Modified: trunk/topia-persistence/src/main/java/org/nuiton/topia/persistence/util/TopiaEntityBinder.java =================================================================== --- trunk/topia-persistence/src/main/java/org/nuiton/topia/persistence/util/TopiaEntityBinder.java 2010-02-21 20:39:35 UTC (rev 1810) +++ trunk/topia-persistence/src/main/java/org/nuiton/topia/persistence/util/TopiaEntityBinder.java 2010-02-22 09:54:12 UTC (rev 1811) @@ -20,9 +20,12 @@ */ package org.nuiton.topia.persistence.util; +import org.apache.commons.lang.NotImplementedException; import org.nuiton.topia.persistence.TopiaEntity; import org.nuiton.util.beans.Binder; +import java.util.Map; + /** * A {@link Binder} dedicated to {@link TopiaEntity} dealing with technical * values. @@ -30,11 +33,14 @@ * There is an internal sate {@link #empty} to deal with default values of * properties of an entity. * + * <b>Note:</b> Should remove {@link Loador} contract soon (let it form the + * the moment for application using * @author tchemit < chemit@codelutin.com > * @param <E> the type of entity * @since 2.3.0 */ -public class TopiaEntityBinder<E extends TopiaEntity> extends Binder<E, E> { +public class TopiaEntityBinder<E extends TopiaEntity> extends Binder<E, E> + implements Loador<E>{ private static final long serialVersionUID = 1L; protected E empty; @@ -52,4 +58,15 @@ } copy(source, target); } + + @Override + public Map<String, Object> obtainProgperties(E from) { + throw new NotImplementedException("the method 'obtainProgperties' is" + + " no more implemented"); + } + + @Override + public void load(E from, E dst, boolean tech) { + copy(from,dst,tech); + } } \ No newline at end of file