History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: IDEA-19154
Type: Usability Problem Usability Problem
Status: Open Open
Assignee: Gregory Shrago
Reporter: Taras Tielkes
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
IDEA: Feedback

Don't mark unused setters grey for entity persistent properties

Created: 15 Aug 08 01:59   Updated: 15 Aug 08 14:39
Component/s: J2EE.EJB3, J2EE.Hibernate

Build: 8,714
Severity: High


 Description  « Hide
Using Hibernate 3.x with JPA annoatations.

We want to restrict visibility for some @Entity setters, declaring them with private or package level accessibility.
IDEA marks the setters as unused.

However, they are used by Hibernate. When the entity is loaded, Hibernate will initialize the entity using the (restricted scope) setters.

It would be better if setters referring to a persistent property of an entity were excluded from usage checks.



 All   Comments   Work Log   Change History      Sort Order:
Stephen Friedrich - 15 Aug 08 11:24
Agree, but of course only for persistent properties where the accessors are annotated.
If the entity uses annotations on the fields then the setters are indeed unused.

Taras Tielkes - 15 Aug 08 13:23
Stephen, that's right.