Home » Developer & Programmer » JDeveloper, Java & XML » How to change type of a field in Jaxb into a generic wildcard
How to change type of a field in Jaxb into a generic wildcard [message #489952] Thu, 20 January 2011 03:48
chanveil
Messages: 22
Registered: December 2010
Junior Member
Hi there,

I am trying to write a JAXB plugin where the plugin will convert a fields type into a more generic type using wildcards. As an example I want to convert the following variable generated by JAXB

List<Shape> shapes = new ArrayList<Shape>();

to be more generic type using Java unknown wildcard ? into the following

List<? extends Shape> shapes = new ArrayList<Shape>();

Im trying to use the CodeModel API to do this but cant seem to get a grasp of the API and how it works to do what I want above

A step in the right direction would be appreciated.

Cheers
Previous Topic: Parsing XML containing array of data
Next Topic: How to reflect xml changes without restart tomcat
Goto Forum:
  


Current Time: Thu Nov 21 11:40:47 CST 2024