[
https://issues.apache.org/jira/browse/JDO-510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12514571
]
Craig Russell commented on JDO-510:
-----------------------------------
I agree. We can add a Persistent[ ] members() default {} to @PersistenceCapable
to do this easily enough. We can use the @Persistent(name="superclassName" ...)
with whatever overrides are needed.
But note that the spec doesn't allow for changing the persistenceModifier of a
superclass field or property. From 18.15, " The persistence-modifier attribute
can be specified only for fields declared in the Java class, and not fields
inherited from superclasses. " But mapping certainly can be overridden.
> Remove @Field and @Property and replace them with @Persistent
> -------------------------------------------------------------
>
> Key: JDO-510
> URL: https://issues.apache.org/jira/browse/JDO-510
> Project: JDO
> Issue Type: New Feature
> Components: api2
> Reporter: Craig Russell
> Assignee: Craig Russell
> Fix For: JDO 2 maintenance release 1
>
> Attachments: jdo-510.patch
>
>
> Annotations are different from xml ways that make it impossible to refer to
> persistent fields and properties in the same way. We started out thinking
> that we could simply map the xml field to annotations @Field and xml property
> to @Property but could not refer to multiples in a sane way.
> This change removes @Field and @Property and replaces them with @Persistent.
> Other annotations that refer to these are changed so that they refer to
> members instead of to fields or properties.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.