[hibernate-issues] [Hibernate-JIRA] Commented: (ANN-527) reference a target entity (in a collection) by entity name

Armin Haaf (JIRA) noreply at atlassian.com
Wed Feb 14 03:04:40 EST 2007


    [ http://opensource.atlassian.com/projects/hibernate/browse/ANN-527?page=comments#action_26109 ] 

Armin Haaf commented on ANN-527:
--------------------------------

> Why don't you make setters private, that hides them too. 

The interface is to hide them, not to make them unusable!

> "you loose the possibilty to avoid inheritance mapping if not needed."
> I don't understand the need for that

If someone wants to exchange the implementation of an entity.





> reference a target entity (in a collection) by entity name
> ----------------------------------------------------------
>
>          Key: ANN-527
>          URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-527
>      Project: Hibernate Annotations
>         Type: New Feature

>   Components: binder
>     Reporter: Armin Haaf

>
>
> It is only possible to reference a targetEntity by class.
> @ManyToMany(targetEntity = TestImpl.class)
> List<Test> myList;
> This makes it impossible to exchange TestImpl.class implemention by another implemention by the mappings definition.
> It would be helpful to reference a targetEntity by name.
> @ManyToMany(targetEntityName = "Test")
> This would help a lot to implement moduls and frameworks.
> Another way to support this would be to search for a implementation of the collection elements (which are typically Interfaces) in the mapped entities 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira




More information about the hibernate-issues mailing list