Gender code based on xs:nonNegativeInteger
<?xml version="1.0"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.java2s.com" xmlns="http://www.java2s.com" elementFormDefault="qualified"> <xs:simpleType name="realworld_GenderCode"> <xs:restriction base="xs:nonNegativeInteger"> <xs:enumeration value="0" /> <!-- Not Known --> <xs:enumeration value="1" /> <!-- Male --> <xs:enumeration value="2" /> <!-- Female --> <xs:enumeration value="3" /> <!-- Male-to-Female Transsexual --> <xs:enumeration value="4" /> <!-- Female-to-Male Transsexual --> <xs:enumeration value="5" /> <!-- True Neuter --> <xs:enumeration value="9" /> <!-- Not Specified --> </xs:restriction> </xs:simpleType> </xs:schema>