FAQ
ERXKey is in cayenne 4.0 and is called Property and the default templates
create them for you.
On Mon, Sep 14, 2015 at 3:42 PM Joseph Senecal wrote:


Can you give us a short summary of what features Wonder would bring to a
Cayenne developer?

My favorite Project Wonder extension for EOF would be the automatically
generated ERXKeys.

The Project Wonder template would generate a base class with all the
getters and setters for a class (business logic would be in the super
class). In addition to the getters and setters, these base classes included
fetch methods that returned a List of that class type instead of an untyped
list. Also they included an ERXKey for each field or relation in the class.

ERXKeys could be used to easily generate qualifiers (Queries) or sort
orderings. These could easily be combined to generate more complex queries.
In addition, ERXKeys could be used to fetch a particular field out of every
record in a list of DB objects, returning a list of values. And since the
ERXKey was defined with the field type, the returned list was correctly
typed.

Example:
List<Foobar> data =
Foobar.fetch(Foobar.FOO.eq(10).and(Foobar.BAR.eq(“NOW”)));
List<String> fieldData = Foobar.FOO_BAR.arrayValueInObject(data);

Joe

Search Discussions

Discussion Posts

Previous

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 11 of 11 | next ›
Discussion Overview
groupuser @
categoriescayenne
postedSep 12, '15 at 1:04p
activeSep 15, '15 at 12:38a
posts11
users7
websitecayenne.apache.org

People

Translate

site design / logo © 2021 Grokbase