I have a pretty large set of Java classes, many that stem from each other. I want to know how to specify in the java code (with an annotation) when a certain property of a class is limited. For example, a vehicle.java class should only be able to have 1 manufacturer and 2-4 wheels.
I have come across minOccurs and maxOccurs in generated XML schemas, but I'm not sure what anootations in java code caused these to appear.
I tried putting @XmlElement(name"manufacturer", minOccurs="0") in my java code in the Car class, but minOccurs throws an error.
Thanks.