This pull-requests adds support for AttributeGroup to xsd-parser.
The implementation has three main impacts:
RsFile has a new collection to store AttributeGroup definitions;
Global AttributeGroups are parsed as Structs and their attributes as StructFields;
Structs have a new collection of Aliases for the attribute groups they implement;
The parsing of non-global AttributeGroup is implemented in all elements allowed to contain an AttributeGroup: extension, restriction and complexType.
With this implementation, the structs generated for types referencing an AttributeGroup have all the fields provided by the AttributeGroup. No struct is generated for the AttributeGroup itself, which seems correct since AttributeGroups cannot appear as such in a XML file.
This pull-requests adds support for
AttributeGroup
to xsd-parser.The implementation has three main impacts:
RsFile
has a new collection to storeAttributeGroup
definitions;AttributeGroup
s are parsed asStruct
s and their attributes asStructField
s;Struct
s have a new collection ofAlias
es for the attribute groups they implement;AttributeGroup
is implemented in all elements allowed to contain anAttributeGroup
:extension
,restriction
andcomplexType
.With this implementation, the
struct
s generated for types referencing anAttributeGroup
have all the fields provided by theAttributeGroup
. Nostruct
is generated for theAttributeGroup
itself, which seems correct sinceAttributeGroup
s cannot appear as such in a XML file.