[
https://issues.apache.org/jira/browse/JDO-751?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15155124#comment-15155124
]
Renato Garcia commented on JDO-751:
-----------------------------------
{quote}
MemberMetadata.getFieldType should return "Optional<Address>". I don't see the
problem with type erasure, since the metamodel uses strings to represent types.
{quote}
It would certainly work, but this would be inconsistent with containers i.e.
collections/maps/arrays, which are also parameterized types just like
Optional<T>, thus creating a special case just to support Optional. In my
opinion this would be not justifiable when you could just use the existing
approach for containers.
> Support for Java8 Optional
> --------------------------
>
> Key: JDO-751
> URL: https://issues.apache.org/jira/browse/JDO-751
> Project: JDO
> Issue Type: New Feature
> Components: specification, tck
> Reporter: Andy Jefferson
>
> java.util.Optional provides a feature that is available in other languages.
> Since JDO 3.2 will be for Java8+ then it makes sense to add support for this
> as a "supported persistable type"
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)