[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wink-dev
Subject:    [jira] Commented: (WINK-325) Allow
From:       "Kaloyan Kolev (JIRA)" <jira () apache ! org>
Date:       2010-10-29 13:06:20
Message-ID: 3601164.140991288357580271.JavaMail.jira () thor
[Download RAW message or body]


    [ https://issues.apache.org/jira/browse/WINK-325?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12926265#action_12926265 \
] 

Kaloyan Kolev commented on WINK-325:
------------------------------------

I am reconfiguring Jackson to use jax-b annotations with priority as follows:

{code}
ObjectMapper mapper = new ObjectMapper();
mapper.getSerializationConfig().setSerializationInclusion(Inclusion.NON_NULL);
AnnotationIntrospector pair =
        new AnnotationIntrospector.Pair(new JaxbAnnotationIntrospector(),
                                      new JacksonAnnotationIntrospector());
 mapper.getDeserializationConfig().setAnnotationIntrospector(pair);
 mapper.getSerializationConfig().setAnnotationIntrospector(pair);
 this.jacksonProvider = new JacksonJaxbJsonProvider();
jacksonProvider.setMapper(mapper);
{code}

Do you think that might cause the problem?

Btw, overriding the getOtherAttributes() is not very convenient as then I will have \
to extend all the Atom types I use (AtomFeed, AtomEntry, etc.)

Thanks.

> Allow AtomCommonAttributes#otherAttributes and \
>                 AtomCommonAttributesSimpleContent#otherAttributes to be lazy \
>                 initialized.
> ------------------------------------------------------------------------------------------------------------------------
>  
> Key: WINK-325
> URL: https://issues.apache.org/jira/browse/WINK-325
> Project: Wink
> Issue Type: Improvement
> Components: Common
> Affects Versions: 1.1.2
> Reporter: Kaloyan Kolev
> Priority: Trivial
> Fix For: 1.1.2
> 
> 
> I am using the Jackson provider to serialize an AtomText which extends \
> AtomCommonAttributes.  For as simple input as:
> {code}
> return new AtomText("someValue");
> {code}
> I get:
> {code}
> {
> "otherAttributes" : {
> },
> "type" : "text",
> "value" : "someValue"
> }
> {code}
> AtomCommonAttributes#otherAttributes is accessed as in the rest of the Atom* beans. \
> Is it possible to allow the map to be lazily initialized when the \
> AtomCommonAttributes#getOtherAttributes() method is called like in the rest? I can \
> see this is also relevant for the AtomCommonAttributesSimpleContent class, so \
> updating the summary. Thanks.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic