johnzon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matthew Broadhead <>
Subject mixed object array
Date Thu, 08 Sep 2016 09:56:27 GMT
I am using TomEE 7.0.1 which is now defaulting to Johnzon where on 1.7.x 
the default was jettison.  i have a specific case where i am using jaxb 
annotations to specify a mixed object array where elements in the array 
can be for example ObjectType1 or ObjectType2.  using jettison it worked 
fine across jaxrs

@XmlElements({ @XmlElement(name = "objectType1", type = ObjectType1.class),
                         @XmlElement(name = "objectType2", type = 
ObjectType2.class) })
public List getObjectBlocks() {
         return objectBlocks;

I would be happy to use Johnzon instead of Jettison if it could provide 
an annotation that addresses this issue however i cannot find much 
documentation about johnzon.  or maybe johnzon has a way of supporting jaxb?

View raw message