You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by rm...@apache.org on 2011/08/06 19:46:03 UTC
svn commit: r1154559 -
/openejb/trunk/openejb3/examples/dynamic-dao-implementation/README.md
Author: rmannibucau
Date: Sat Aug 6 17:46:02 2011
New Revision: 1154559
URL: http://svn.apache.org/viewvc?rev=1154559&view=rev
Log:
indenting items in README
Modified:
openejb/trunk/openejb3/examples/dynamic-dao-implementation/README.md
Modified: openejb/trunk/openejb3/examples/dynamic-dao-implementation/README.md
URL: http://svn.apache.org/viewvc/openejb/trunk/openejb3/examples/dynamic-dao-implementation/README.md?rev=1154559&r1=1154558&r2=1154559&view=diff
==============================================================================
--- openejb/trunk/openejb3/examples/dynamic-dao-implementation/README.md (original)
+++ openejb/trunk/openejb3/examples/dynamic-dao-implementation/README.md Sat Aug 6 17:46:02 2011
@@ -7,14 +7,14 @@ OpenEBJ support EJB annotations on inter
The interface has to be annotated with @PersistenceContext to define which EntityManager to use.
Methods should respect these conventions:
-* void save(Foo foo): persist foo
-* Foo update(Foo foo): merge foo
-* void delete(Foo foo): remove foo, if foo is detached it tries to attach it
-* Collection<Foo>|Foo namedQuery(String name[, Map<String, ?> params, int first, int max]): run the named query called name, params contains bindings, first and max are used for magination. Last three parameters are optionnals
-* Collection<Foo>|Foo nativeQuery(String name[, Map<String, ?> params, int first, int max]): run the native query called name, params contains bindings, first and max are used for magination. Last three parameters are optionnals
-* Collection<Foo>|Foo query(String value [, Map<String, ?> params, int first, int max]): run the query put as first parameter, params contains bindings, first and max are used for magination. Last three parameters are optionnals
-* Collection<Foo> findAll([int first, int max]): find all Foo, parameters are used for pagination
-* Collection<Foo> findByBar1AndBar2AndBar3(<bar 1 type> bar1, <bar 2 type> bar2, <bar3 type> bar3 [, int first, int max]): find all Foo with specified field values for bar1, bar2, bar3.
+ * void save(Foo foo): persist foo
+ * Foo update(Foo foo): merge foo
+ * void delete(Foo foo): remove foo, if foo is detached it tries to attach it
+ * Collection<Foo>|Foo namedQuery(String name[, Map<String, ?> params, int first, int max]): run the named query called name, params contains bindings, first and max are used for magination. Last three parameters are optionnals
+ * Collection<Foo>|Foo nativeQuery(String name[, Map<String, ?> params, int first, int max]): run the native query called name, params contains bindings, first and max are used for magination. Last three parameters are optionnals
+ * Collection<Foo>|Foo query(String value [, Map<String, ?> params, int first, int max]): run the query put as first parameter, params contains bindings, first and max are used for magination. Last three parameters are optionnals
+ * Collection<Foo> findAll([int first, int max]): find all Foo, parameters are used for pagination
+ * Collection<Foo> findByBar1AndBar2AndBar3(<bar 1 type> bar1, <bar 2 type> bar2, <bar3 type> bar3 [, int first, int max]): find all Foo with specified field values for bar1, bar2, bar3.
Dynamic finder can have as much as you want field constraints. For String like is used and for other type equals is used. See UserDao for an example and DynamicUserDaoTest for an usage example.