« Return to Thread: Any reason why an ObjectTypeConverter can't live on a package?

Re: Any reason why an ObjectTypeConverter can't live on a package?

by tware :: Rate this Message:

Reply to Author | View in Thread

Hi Laird,

   Any ObjectTypeConverter you define should be usable on any class in the same
persistence unit.

   We have tried to mimic the JPA-style of annotations when adding our own
annotations.  In this case, the way we do things is somewhat similar to the way
they do ID generation.  (i.e. The Converter can be defined on an Type, Method or
Field, but is usable outside of that place)

   I agree that this is a little confusing from the point of view of how you
organize your code and there may be some kind of enhancement request worth
entering here either for the JPA spec, or for EclipseLink.

-Tom

Laird Nelson wrote:

> http://wiki.eclipse.org/Using_EclipseLink_JPA_Extensions_(ELUG)#How_to_Use_the_.40ObjectTypeConverter_Annotation 
> indicates that the ObjectTypeConverter annotation can only be applied to
> a Type or Method or Field.
>
> Any reason why this annotation cannot also live at the package level?  
> It would be very nice to be able to reference a common
> ObjectTypeConverter from several classes in the same package.
>
> Best,
> Laird
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> eclipselink-users mailing list
> eclipselink-users@...
> https://dev.eclipse.org/mailman/listinfo/eclipselink-users
_______________________________________________
eclipselink-users mailing list
eclipselink-users@...
https://dev.eclipse.org/mailman/listinfo/eclipselink-users

 « Return to Thread: Any reason why an ObjectTypeConverter can't live on a package?