Doesnt it break data design? Why not using the em if it is what you need?
One doesnt prevent the other.
Le 9 déc. 2015 23:12, "Marvin Toll" <[email protected]> a écrit :

> Without having the benefit of "test driving" the change, it seems to make
> a lot of sense to me.  Any approach enabling direct access to the (native)
> JPA API can only be beneficial when it is impossible to imagine all of the
> different use cases that might emerge for hundreds of developers over the
> next decade.
>
> _Marvin
>
> -----Original Message-----
> From: Harald Wellmann [mailto:[email protected]]
> Sent: Wednesday, December 9, 2015 4:26 PM
> To: [email protected]
> Subject: EntityRepository + EntityManagerDelegate
>
> For the benefit of all DS Data users who prefer persist() and merge() over
> save(), I propose to extend the Data API by something like this:
>
>
> public interface FullEntityRepository<E, PK extends Serializable>
>      extends EntityRepository<E, PK>, EntityManagerDelegate<E> {
> }
>
>
> public abstract class AbstractFullEntityRepository<E, PK extends
> Serializable>
>      extends AbstractEntityRepository<E, PK>
>      implements EntityManagerDelegate<E> {
>
> }
>
> I don't really care about the exact class names (Full, Extended, you
> name it), the point is that end users can simply write
>
> public interface CustomerRepository extends
> FullEntityRepository<Customer, Long> {}
>
> to get access to all EntityManager methods.
>
> What do you think?
>
> Regards,
> Harald
>
>

Reply via email to