Using the JXC ant schema generation task, I cannot make it ignore the enumeration. I have several enumerations that are used internally to indicate values ββof type or minor values ββthat are not relevant to the generated XML.
I can exclude the field using enum as @XmlTransient to exclude it from the object's schema, but the simpleType descriptor is still created for enumeration!
Example:
public class CustomerType { @XmlTransient public enum IsolationLevel { ALL, SAME_TYPE, SELECTED } @XmlTransient private Long id; @XmlValue private String name; @XmlTransient private IsolationLevel isolation = IsolationLevel.ALL; }
Generated circuit:
<xs:simpleType name="isolationLevel"> <xs:restriction base="xs:string"> <xs:enumeration value="ALL"/> <xs:enumeration value="SAME_TYPE"/> <xs:enumeration value="SELECTED"/> </xs:restriction> </xs:simpleType>
Anyone have any ideas on how to get JXC to ignore the enumeration? It is not used by any XML-mapped property or field, and the enumeration itself is marked @XmlTransient - why is it still part of my schema?
source share