Open thomaspeugeot opened 4 months ago
"REQ-IF" is an element and a complex type
<xsd:element name="REQ-IF" type="REQIF:REQ-IF"/>
...
<xsd:complexType name="REQ-IF">
<xsd:sequence>
...
<xsd:element maxOccurs="1" minOccurs="1" name="CORE-CONTENT">
<xsd:complexType>
<xsd:choice maxOccurs="1" minOccurs="1">
<xsd:element name="REQ-IF-CONTENT" type="REQIF:REQ-IF-CONTENT"/>
</xsd:choice>
</xsd:complexType>
</xsd:element>
...
</xsd:sequence>
<xsd:attribute ref="xml:lang" use="optional"/>
</xsd:complexType>
xsd says the type is defined a sequence of 3 element, 2 mandatory and one optionnel. The "REQ-IF-CONTENT" type is complex as well.
it seems xgen generates a struct for the element and a type for the complexType
<SPEC-OBJECT
IDENTIFIER="_xen_QMkhEee8KsfWrp9EJQ"
LAST-CHANGE="2017-11-14T15:44:26.000+02:00"
LONG-NAME="Requirement-1">
<VALUES>
</VALUES>
<xsd:complexType name="SPEC-OBJECT">
<xsd:all>
<xsd:element maxOccurs="1" minOccurs="0" name="VALUES">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded" minOccurs="0">
<xsd:element name="ATTRIBUTE-VALUE-BOOLEAN" type="REQIF:ATTRIBUTE-VALUE-BOOLEAN"/>
<xsd:element name="ATTRIBUTE-VALUE-DATE" type="REQIF:ATTRIBUTE-VALUE-DATE"/>
<xsd:element name="ATTRIBUTE-VALUE-ENUMERATION" type="REQIF:ATTRIBUTE-VALUE-ENUMERATION"/>
<xsd:element name="ATTRIBUTE-VALUE-INTEGER" type="REQIF:ATTRIBUTE-VALUE-INTEGER"/>
<xsd:element name="ATTRIBUTE-VALUE-REAL" type="REQIF:ATTRIBUTE-VALUE-REAL"/>
<xsd:element name="ATTRIBUTE-VALUE-STRING" type="REQIF:ATTRIBUTE-VALUE-STRING"/>
<xsd:element name="ATTRIBUTE-VALUE-XHTML" type="REQIF:ATTRIBUTE-VALUE-XHTML"/>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:all>
</xsd:complexType>
We have
that follows definition of xsd
In the go model, it is
so, since gong does not support slice of strings, we loose the link