<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:foo">
   <xs:simpleType name="TimeOrDateTimeType">
      <xs:union memberTypes="xs:dateTime xs:time" />
   </xs:simpleType>
</xs:schema>