• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need "ant" JAXB-GEN generated classes to automatically "implements Serializable"

 
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have xsd like below:

<xs:element name="metroList">
<xs:complexType>
<xs:sequence>
<xs:element ref="clusterList" maxOccurs="1" minOccurs="1"/>
<xs:element ref="defaultThresholds" maxOccurs="1" minOccurs="1"/>
<xs:element ref="metroInfo" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="clusterList">
<xs:complexType>
<xs:sequence>
<xs:element ref="clusterInfo" maxOccurs="unbounded" minOccurs="1"/>
</xs:sequence>
</xs:complexType>
</xs:element>

and i am generating classes with following ant script

<taskdef name="xjc" classname="com.sun.tools.xjc.XJCTask" classpathref="compile.classpath" />
<target name="jaxb-gen">
<xjc target="${generated}" schema="${src.xml}/metroList.xsd" removeOldOutput="yes"
package="com.metro">
<produces dir="${generated}/com/metro" includes="**/*" />
</xjc>
</target>


i want the generated classes to automatically "implements Serializable".

Your help will be really appreciated.

Thank You.
Have a Nice Time.

-Santosh
 
Sheriff
Posts: 22783
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Moving to our Ant / build tools forum.
 
reply
    Bookmark Topic Watch Topic
  • New Topic