You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Christophe Lombart (JIRA)" <ji...@apache.org> on 2008/05/21 22:47:56 UTC
[jira] Resolved: (JCR-1286) FilterImpl.getStringValue() does not
use custom converter class specified in @Field annotation
[ https://issues.apache.org/jira/browse/JCR-1286?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Christophe Lombart resolved JCR-1286.
-------------------------------------
Resolution: Fixed
Fix Version/s: 1.5
>From now, the Filter is using the converter if it is specified in the mapping definition.
Let me know if something is wrong
Thanks
> FilterImpl.getStringValue() does not use custom converter class specified in @Field annotation
> ----------------------------------------------------------------------------------------------
>
> Key: JCR-1286
> URL: https://issues.apache.org/jira/browse/JCR-1286
> Project: Jackrabbit
> Issue Type: Bug
> Components: jackrabbit-ocm
> Affects Versions: 1.4
> Environment: jackrabbit-ocm-1.4-20071210.145858-1
> java version "1.5.0_13"
> Reporter: Paul Mietz Egli
> Assignee: Christophe Lombart
> Fix For: 1.5
>
>
> I have a POJO with the following field:
> @Field(converter = LocaleConverter.class)
> private Locale locale;
> When I attempt to query for objects based on this field, I get a NullPointerException:
> java.lang.NullPointerException
> at org.apache.jackrabbit.ocm.query.impl.FilterImpl.getStringValue(FilterImpl.java:281)
> at org.apache.jackrabbit.ocm.query.impl.FilterImpl.addEqualTo(FilterImpl.java:129)
> FilterImpl should preferentially use the atomic type converter defined in the @Field annotation to convert the value, then fallback to the global converters. Converting the Locale to a string for use in the query is a workaround, but the logic for string conversion should only reside in my LocaleConverter class.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.