r1282 - in topia/trunk/topia-persistence/src/main/java/org/codelutin/topia: event framework persistence persistence/hibernate
Author: chatellier Date: 2008-12-17 13:08:56 +0000 (Wed, 17 Dec 2008) New Revision: 1282 Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/event/TopiaEntitiesVetoable.java topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/framework/TopiaContextImplementor.java topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaDAO.java topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaEntity.java topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaId.java topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/hibernate/FlatFilePersister.java Log: Fix javadoc Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/event/TopiaEntitiesVetoable.java =================================================================== --- topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/event/TopiaEntitiesVetoable.java 2008-12-17 11:20:34 UTC (rev 1281) +++ topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/event/TopiaEntitiesVetoable.java 2008-12-17 13:08:56 UTC (rev 1282) @@ -30,6 +30,6 @@ */ public interface TopiaEntitiesVetoable extends EventListener { - public <E extends TopiaEntity> List<E> load(TopiaEntitiesEvent event); + public <E extends TopiaEntity> List<E> load(TopiaEntitiesEvent<E> event); } Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/framework/TopiaContextImplementor.java =================================================================== --- topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/framework/TopiaContextImplementor.java 2008-12-17 11:20:34 UTC (rev 1281) +++ topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/framework/TopiaContextImplementor.java 2008-12-17 13:08:56 UTC (rev 1282) @@ -93,7 +93,7 @@ * * @param <E> * @param entityClass - * @return + * @return a doa * @throws TopiaException */ public <E extends TopiaEntity> TopiaDAO<E> getDAO(Class<E> entityClass) Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaDAO.java =================================================================== --- topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaDAO.java 2008-12-17 11:20:34 UTC (rev 1281) +++ topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaDAO.java 2008-12-17 13:08:56 UTC (rev 1282) @@ -37,8 +37,6 @@ import org.codelutin.topia.TopiaException; import org.codelutin.topia.event.TopiaEntityListener; import org.codelutin.topia.event.TopiaEntityVetoable; -import org.codelutin.topia.event.TopiaTransactionListener; -import org.codelutin.topia.event.TopiaTransactionVetoable; import org.codelutin.topia.framework.TopiaContextImplementor; /** @@ -50,16 +48,18 @@ /** * When TopiaContextImpl create the TopiaDAOHibernate, it must call this method just - * after + * after. * - * @param entityClass + * @param context context + * @param entityClass entity class + * @throws TopiaException */ public void init(TopiaContextImplementor context, Class<Entity> entityClass) throws TopiaException; /** * Return class of entity managed by this DAO - * @return + * @return entity managed by this DAO */ public abstract Class<Entity> getEntityClass(); @@ -69,14 +69,21 @@ public abstract TopiaContextImplementor getContext(); /** - * appelé lorsque le context a eu un commit de fait + * Appelé lorsque le context a eu un commit de fait. + * * TODO il faudrait peut-etre plutot faire un commit a deux phase * car plusieurs type de persistence peuvent etre melangé, et il * serait bien que si l'une echoué les autres echoue aussi. + * + * @throws TopiaException */ public void commitTransaction() throws TopiaException; - /** appelé lorsque le context a eu un commit de fait */ + /** + * Appelé lorsque le context a eu un rollback de fait. + * + * @throws TopiaException + */ public void rollbackTransaction() throws TopiaException; /** @@ -122,7 +129,7 @@ /** * TODO modifier l'implantation pour faire un simple count sur la base * - * @return + * @return la taille de ? * @throws TopiaException */ public abstract int size() throws TopiaException; @@ -132,7 +139,7 @@ * cle naturelle est une entre de la map passe en argument. * * @param keys la liste des champs de la cle naturelle avec leur valeur - * @return + * @return l'entite trouvé * @throws TopiaException */ public abstract Entity findByPrimaryKey(Map<String, Object> keys) @@ -144,7 +151,7 @@ * dans l'ordre de declaration dans le fichier de mapping * * @param k l'objet cle naturelle de la classe - * @return + * @return l'entité trouvé * @throws TopiaException */ public abstract Entity findByPrimaryKey(Object... k) throws TopiaException; @@ -158,7 +165,7 @@ * @param value * @param others les autres proprietes doivent aller par 2 propertyName, * value - * @return + * @return l'entité trouvé * @throws TopiaException */ public abstract Entity findByProperties(String propertyName, Object value, @@ -176,7 +183,7 @@ * @param value * @param others les autres proprietes doivent aller par 2 propertyName, * value - * @return + * @return l'entité trouvé * @throws TopiaException */ public abstract List<Entity> findAllByProperties(String propertyName, @@ -191,6 +198,10 @@ /** * Cherche et renvoie la première entité trouvée dont les propriétés en clé * de Map contiennent toutes les valeurs de la Collection. + * + * @param properties + * @return l'entité trouvé + * @throws TopiaException */ public abstract Entity findContainsProperties( Map<String, Collection> properties) throws TopiaException; @@ -198,6 +209,12 @@ /** * Cherche et renvoie la première entité trouvée dont la propriété * propertyName contient values, ainsi de suite avec others. + * + * @param propertyName + * @param values + * @param others + * @return l'entité trouvé + * @throws TopiaException */ public abstract Entity findContainsProperties(String propertyName, Collection values, Object... others) throws TopiaException; @@ -205,6 +222,10 @@ /** * Cherche et renvoie la première entité trouvée dont les propriétés en clé * de Map contiennent toutes les valeurs de la Collection. + * + * @param properties + * @return l'entité trouvé + * @throws TopiaException */ public abstract List<Entity> findAllContainsProperties( Map<String, Collection> properties) throws TopiaException; @@ -212,14 +233,23 @@ /** * Cherche et renvoie toutes les entités trouvées dont la propriété * propertyName contient values, ainsi de suite avec others. + * + * @param propertyName + * @param values + * @param others + * @return l'entité trouvé + * @throws TopiaException */ public abstract List<Entity> findAllContainsProperties(String propertyName, Collection values, Object... others) throws TopiaException; /** - * Retourne les permissions a verifier pour l'acces a l'entite pour le service Taas + * Retourne les permissions a verifier pour l'acces a l'entite pour le service Taas. + * * @param topiaId topiaId d'une entite + * @param actions * @return la liste des permissions + * @throws TopiaException */ public List<Permission> getRequestPermission(String topiaId, int actions) throws TopiaException; Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaEntity.java =================================================================== --- topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaEntity.java 2008-12-17 11:20:34 UTC (rev 1281) +++ topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaEntity.java 2008-12-17 13:08:56 UTC (rev 1282) @@ -60,7 +60,7 @@ public Date getTopiaCreateDate(); /** - * @param topiaCreateTime The topiaCreateTime to set. + * @param topiaCreatedate the topiaCreateTime to set. */ public void setTopiaCreateDate(Date topiaCreatedate); Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaId.java =================================================================== --- topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaId.java 2008-12-17 11:20:34 UTC (rev 1281) +++ topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/TopiaId.java 2008-12-17 13:08:56 UTC (rev 1282) @@ -73,6 +73,9 @@ /** * Cree un topiaId pour une certaine classe + * + * @param clazz + * @return a generated topiaId */ public static String create(Class clazz) { if (!clazz.isInterface()) { @@ -88,9 +91,12 @@ } /** - * Extrait la classe du topiaId - * @throws ClassNotFoundException - */ + * Extrait la classe du topiaId. + * + * @param topiaId + * @return class + * @throws TopiaNotFoundException + */ public static Class getClassName(String topiaId) throws TopiaNotFoundException { String classname = getClassNameAsString(topiaId); @@ -105,10 +111,10 @@ /** * Return class name id topiaId is id, and empty string if topiaId is - * not an id + * not an id. * * @param topiaId - * @return + * @return class name */ public static String getClassNameAsString(String topiaId) { String result = ""; @@ -122,7 +128,10 @@ /** * Verifie si l'id passé en paramètre est bien un Id topia, c-a-d si la * forme est bien classname#timemillis#random et si le classname est - * celui d'une classe valide, c-a-d que le systeme arrive a trouver + * celui d'une classe valide, c-a-d que le systeme arrive a trouver. + * + * @param topiaId + * @return is valid topiaId */ public static boolean isValidId(String topiaId) { try { Modified: topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/hibernate/FlatFilePersister.java =================================================================== --- topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/hibernate/FlatFilePersister.java 2008-12-17 11:20:34 UTC (rev 1281) +++ topia/trunk/topia-persistence/src/main/java/org/codelutin/topia/persistence/hibernate/FlatFilePersister.java 2008-12-17 13:08:56 UTC (rev 1282) @@ -506,7 +506,6 @@ } /** - * @see EntityPersister#getCache() */ public CacheConcurrencyStrategy getCache() { return null;
participants (1)
-
chatellier@users.labs.libre-entreprise.org