Enums can implement interfaces. You could add a new interface called
CayenneEnum or some such. Maybe something like:
public interface CayenneEnum<T>
{
public T getValue();
public Object fromValue(T value);
}
This isn't necessarily any more invasive than the rest of the framework.
Granted, now the user has to implement something, but that'd be a
requirement to implement value storage anyway.
--
Kevin
On 1/16/08 12:49 PM, "Andrus Adamchik" <[EMAIL PROTECTED]> wrote:
> Sorry for the email flood... I jumped the gun on enums. It will be
> inconsistent with the best Cayenne tradition of keeping the mapping
> completely separate form the code. So I'd say we'd have to map the
> stuff below in the DataMap... so we will have to add yet another
> mapping primitive :-/
>
> Andrus