XJC not generting bindings in episode files for simple Types

View: New views
8 Messages — Rating Filter:   Alert me  

XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi

  I have a simple Type and while calling XJC to compile the same I instruct xjc to create the episode file. After the call the java type corresponding to the simple type gets created , but the episode file genearted does not have the bindings for the same.  Is there any workaround for this or any argument which would force the proper binding creation for simple types in the generated episode file ?  

My command
-----------------------
xjc -episode a.episode s1.xsd


My XSD
-------------

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://www.ebay.com/marketplace/services" xmlns:tns="http://www.ebay.com/marketplace/services" version="1.0.0">
        <xs:simpleType name="S1">
                <xs:annotation>
                        <xs:documentation>
                                Documentation goes here.
                        </xs:documentation>
                </xs:annotation>
                <xs:restriction base="xs:string">
            <xs:enumeration value="On" />
            <xs:enumeration value="Off" />
  </xs:restriction>
        </xs:simpleType>
</xs:schema>


The generated episode
---------------------------------

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<bindings version="2.1" xmlns="http://java.sun.com/xml/ns/jaxb">
  <!--

This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.1.2-b01-fcs
See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>
Any modifications to this file will be lost upon recompilation of the source schema.
Generated on: 2008.10.31 at 10:38:54 PM MST

  --></bindings>


_________________________________________________________
[Message sent by forum member 'arajmony' (arajmony)]

http://forums.java.net/jive/thread.jspa?messageID=314334

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

*push*

Are there any news on this topic?

I've got the same problem and I don't want to create the episode-file by hand.

I use JaxB 2.1.11
[Message sent by forum member 'derjust' (derjust)]

http://forums.java.net/jive/thread.jspa?messageID=350368

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

A related problem is that if the simpleType is created as a result of an Episode parsing, and its class is forcibly entered into a Bindings.xjb as if it had been put there by the Episode, the instruction is ignored and new instances of the type are compiled.
[Message sent by forum member 'sisjon912' (sisjon912)]

http://forums.java.net/jive/thread.jspa?messageID=355448

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Although XJC [2.1.9] does not create simpleType entries in Episode files, and although XJC [2.1.9] does not honor simpleType class specifications in Binding files, WsImport [2.1.5] will honor similar simpleType specifications in Binding files.

I imagine that wsimport must use xjc in some way while doing its processing. so this really seems anomalous.

Has anyone a definitive response for whether this is a bug or a feature?
[Message sent by forum member 'sisjon912' (sisjon912)]

http://forums.java.net/jive/thread.jspa?messageID=355704

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

This is also impacting me.  Anyone on the JAXB team comment on this?

Ben
[Message sent by forum member 'bentomasini' (ben.tomasini@...)]

http://forums.java.net/jive/thread.jspa?messageID=369688

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I have opened a bug and linked back to this thread:

https://jaxb.dev.java.net/issues/show_bug.cgi?id=708

Ben
[Message sent by forum member 'bentomasini' (ben.tomasini@...)]

http://forums.java.net/jive/thread.jspa?messageID=369689

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I think I found the issue in the code.  The plugin for the episode parser iterates over all of the classes in the model, but not all of the enums.  I am working on a patch now that will correct this.

Ben
[Message sent by forum member 'bentomasini' (ben.tomasini@...)]

http://forums.java.net/jive/thread.jspa?messageID=369698

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...


Re: XJC not generting bindings in episode files for simple Types

by metro-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Patch submitted.
[Message sent by forum member 'bentomasini' (ben.tomasini@...)]

http://forums.java.net/jive/thread.jspa?messageID=369999

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@...
For additional commands, e-mail: users-help@...