Tridion SDL uses XML schema definitions to define content stored in Tridion components. XSD can use constraints / faces or indicators to limit the validity for XML nodes.
Chris Summers accidentally discovered some of these in the learning process, in particular, we can establish indicators minOccursand maxOccursin SDL Tridion in 2011:
<xsd:element name="someField" minOccurs="2" maxOccurs="5" type="xsd:normalizedString">
Andrei Marchuk mentions additional options in the same post:
Indicators
Limitations
FractionDigitsMaxLengthMinLengthPatternTotalDigits
Btw, are these XSD-specific?
IsMaxValueExclusiveIsMinValueExclusive
How can I get the constraints * in the following Tridion schema (source)? *
<xsd:schema xmlns="http://createandbreak.net/schema/example" xmlns:tcmi="http://www.tridion.com/ContentManager/5.0/Instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://createandbreak.net/schema/example">
<xsd:import namespace="http://www.tridion.com/ContentManager/5.0/Instance"></xsd:import>
<xsd:annotation>
<xsd:appinfo>
<tcm:Labels xmlns:tcm="http://www.tridion.com/ContentManager/5.0">
<tcm:Label ElementName="someField" Metadata="false">someField</tcm:Label>
</tcm:Labels>
</xsd:appinfo>
</xsd:annotation>
<xsd:element name="Content">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="someField" minOccurs="2" maxOccurs="5" type="xsd:normalizedString">
<xsd:annotation>
<xsd:appinfo>
<tcm:ExtensionXml xmlns:tcm="http://www.tridion.com/ContentManager/5.0"></tcm:ExtensionXml>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
W3Schools, XSD , 5 :
<xs:element name="prodid">
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:pattern value="[0-9][0-9][0-9][0-9][0-9]"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
xs xsd, , XSD (Tridion).