Uploaded image for project: 'XMLBeans'
  1. XMLBeans
  2. XMLBEANS-414

error cvc-complex-type.2.1: Element 'XXXX' with empty content type cannot have text or element content.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Version 2.4
    • None
    • Binding, Compiler, Validator
    • None
    • Windows XP, jdk1.5.0_17

    Description

      I have the following piece of xml wich it's validated ok with AltovaXML tools and others but it isn't validated by xmlbeans and java files generated don't allow get value/text for given and family elements.
      ....
      <name>
      <given>JOSUE</given>
      <family>RODRIGUEZ</family>
      <family>GOMEZ</family>
      </name>
      .....

      When I try validate it I get :

      error cvc-complex-type.2.1: Element 'given@urn:hl7-org:v3' with empty content type cannot have text or element content.
      error cvc-complex-type.2.1: Element 'family@urn:hl7-org:v3' with empty content type cannot have text or element content.
      error cvc-complex-type.2.1: Element 'family@urn:hl7-org:v3' with empty content type cannot have text or element content.

      The fragments of xsd of "name" elements are (HL7 standards datatypes schema) ... :

      <xs:complexType name="en.given" mixed="true">
      <xs:complexContent>
      <xs:restriction base="ENXP">
      <xs:attribute name="partType" type="EntityNamePartType" fixed="GIV"/>
      </xs:restriction>
      </xs:complexContent>
      </xs:complexType>

      <xs:complexType name="ENXP" mixed="true">
      <xs:annotation>
      <xs:documentation>
      A character string token representing a part of a name.
      May have a type code signifying the role of the part in
      the whole entity name, and a qualifier code for more detail
      about the name part type. Typical name parts for person
      names are given names, and family names, titles, etc.
      </xs:documentation>
      </xs:annotation>
      <xs:complexContent>
      <xs:extension base="ST">
      <xs:attribute name="partType" type="EntityNamePartType">
      <xs:annotation>
      <xs:documentation>
      Indicates whether the name part is a given name, family
      name, prefix, suffix, etc.
      </xs:documentation>
      </xs:annotation>
      </xs:attribute>
      <xs:attribute name="qualifier" use="optional" type="set_EntityNamePartQualifier">
      <xs:annotation>
      <xs:documentation> is a set of codes each of which specifies
      a certain subcategory of the name part in addition to
      the main name part type. For example, a given name may
      be flagged as a nickname, a family name may be a
      pseudonym or a name of public records.
      </xs:documentation>
      </xs:annotation>
      </xs:attribute>
      </xs:extension>
      </xs:complexContent>
      </xs:complexType>

      <xs:complexType name="EN" mixed="true">
      <xs:annotation>
      <xs:documentation>
      A name for a person, organization, place or thing. A
      sequence of name parts, such as given name or family
      name, prefix, suffix, etc. Examples for entity name
      values are "Jim Bob Walton, Jr.", "Health Level Seven,
      Inc.", "Lake Tahoe", etc. An entity name may be as simple
      as a character string or may consist of several entity name
      parts, such as, "Jim", "Bob", "Walton", and "Jr.", "Health
      Level Seven" and "Inc.", "Lake" and "Tahoe".
      </xs:documentation>
      </xs:annotation>
      <xs:complexContent>
      <xs:extension base="ANY">
      <xs:sequence>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
      <xs:element name="delimiter" type="en.delimiter"/>
      <xs:element name="family" type="en.family"/>
      <xs:element name="given" type="en.given"/>
      <xs:element name="prefix" type="en.prefix"/>
      <xs:element name="suffix" type="en.suffix"/>
      </xs:choice>
      <xs:element name="validTime" minOccurs="0" maxOccurs="1" type="IVL_TS">
      <xs:annotation>
      <xs:documentation>
      An interval of time specifying the time during which
      the name is or was used for the entity. This
      accomodates the fact that people change names for
      people, places and things.
      </xs:documentation>
      </xs:annotation>
      </xs:element>
      </xs:sequence>
      <xs:attribute name="use" use="optional" type="set_EntityNameUse">
      <xs:annotation>
      <xs:documentation>
      A set of codes advising a system or user which name
      in a set of like names to select for a given purpose.
      A name without specific use code might be a default
      name useful for any purpose, but a name with a specific
      use code would be preferred for that respective purpose.
      </xs:documentation>
      </xs:annotation>
      </xs:attribute>
      </xs:extension>
      </xs:complexContent>
      </xs:complexType>

      <xs:simpleType name="EntityNamePartType">
      <xs:restriction base="cs">
      <xs:enumeration value="DEL"/>
      <xs:enumeration value="FAM"/>
      <xs:enumeration value="GIV"/>
      <xs:enumeration value="PFX"/>
      <xs:enumeration value="SFX"/>
      </xs:restriction>
      </xs:simpleType>

      <xs:simpleType name="cs">
      <xs:annotation>
      <xs:documentation>
      Coded data in its simplest form, consists of a code.
      The code system and code system version is fixed by
      the context in which the value occurs. is used
      for coded attributes that have a single HL7-defined
      value set.
      </xs:documentation>
      </xs:annotation>
      <xs:restriction base="xs:token">
      <xs:pattern value="[^\s]+"/>
      </xs:restriction>
      </xs:simpleType>

      Attachments

        Activity

          People

            Unassigned Unassigned
            jajmenez Jose A. Jimenez
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: