Great. That's good for me too, since whatever you add will be easy enough for me to incorporate in our work and I'll give you my +1 now for adding it to Cayenne :-)

Please pinch anything from it you find useful. Without thinking about it deeply though, it does seem possible that this API could be generified to be more useful, although in 99% of cases a user will want integer database values and string user interface values.

Ari




On 28/02/2008, at 3:01 AM, Michael Gentry wrote:

Ari, I took a glance at the code you sent me and on first look, it
appears to be similar to what I did for my Cayenne 1.2/2.0 enum
support (using Java 1.4 only, though) and the current stuff I'm
adding.  I'll get to work on it again in the next few days, but wanted
to give you a little feedback.

Thanks,

/dev/mrg


On Mon, Feb 25, 2008 at 5:44 PM, Aristedes Maniatis <[EMAIL PROTECTED]> wrote:

On 26/02/2008, at 1:43 AM, Michael Gentry wrote:

I did some work on extended enumerations (where the DB value can be
defined) this weekend

Interesting. If this list passes through my attachments, I've included
some classes from our ROP project which might help give you another
example of how this might be used. They are ExtendedTypeIntegerEnum
which is an interface implemented by IntegerEnumType (server side
only) and ClassCostType (an example enumeration which is available to
both client and server).






The naming and docs could be better but it works pretty well. Despite
the copyright headers, you have permission to use any bits of this you
find useful. As you can see, the approach is quite similar: a
persistent value and a display value (for popup menus for instance)
declared in the constructor.


Ari




-------------------------->
ish
http://www.ish.com.au
Level 1, 30 Wilson Street Newtown 2042 Australia
phone +61 2 9550 5001   fax +61 2 9550 4001
GPG fingerprint CBFB 84B4 738D 4E87 5E5C  5EFA EF6A 7D2E 3E49 102A









-------------------------->
ish
http://www.ish.com.au
Level 1, 30 Wilson Street Newtown 2042 Australia
phone +61 2 9550 5001   fax +61 2 9550 4001
GPG fingerprint CBFB 84B4 738D 4E87 5E5C  5EFA EF6A 7D2E 3E49 102A


Reply via email to