Returns an enumerated value from the SCHEMADERIVATIONMETHOD declarations. The possible values are SCHEMADERIVATIONMETHOD_EXTENSION and SCHEMADERIVATIONMETHOD_RESTRICTION. The returned value is the derived-by type that will cause a substitution group affiliation to fail.
You create a substitution group affiliation by adding the substitutionGroup
attribute to an <element>
declaration. When the substitutionGroupExclusion
attribute is set to "extension"
and the affiliated element has been derived by extension, substitution will not work. When the substitutionGroupExclusion
attribute is set to "restriction"
and the affiliated element has been derived by restriction, substitution will not work. When both "extension"
and "restriction"
are set as values for the substitutionGroupExclusion
attribute, no substitution is allowed for the elements in the affiliation group.
The following example shows an XML Schema document that is not valid because 'eleB'
cannot nominate 'eleA'
as the head of its substitution group affiliation.
<xsd:schema xmlns:xsd='http://www.w3.org/2001/XMLSchema'> <xsd:element name='eleA' type='xsd:string'final
='restriction'/> <xsd:element name='eleB'substitutionGroup
='eleA'> <xsd:simpleType> <xsd:restriction base='xsd:string'> <xsd:maxLength value='20' /> </xsd:restriction> </xsd:simpleType> </xsd:element> <xsd:element name='eleSeq'> <xsd:complexType> <xsd:sequence> <xsd:element ref='eleA' /> <xsd:element ref='eleB' /> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema>
var enuSubstitutionGroupExclusions = oISchemaAttribute. substitutionGroupExclusions;
None.
SCHEMADERIVATIONMETHOD_EXTENSION SCHEMADERIVATIONMETHOD_RESTRICTION
SCHEMADERIVATIONMETHOD_ALL
enuSubstitutionGroupExclusions = oISchemaAttribute. substitutionGroupExclusions
None.
SCHEMADERIVATIONMETHOD_EXTENSION SCHEMADERIVATIONMETHOD_RESTRICTION
SCHEMADERIVATIONMETHOD_ALL
HRESULT get_substitutionGroupExclusions(SCHEMADERIVATIONMETHOD* substitutionGroupExclusions);
SCHEMADERIVATIONMETHOD_RESTRICTION
SCHEMADERIVATIONMETHOD_ALL
substitutionsGroupExclusions
parameter is NULL.To view reference information for Visual Basic or C/C++ only, click the Language Filter button in the upper-left corner of the page.
Applies to: ISchemaElement Interface