A complex attribute may come from a class with subclasses. If only a certain subclass is permitted, i.e., if the options are restricted to a single subclass, it is specified using RestrictedDomain. Similarly, if a simple attribute is speciified in a class as coming from the domain String, a subclass definition may restrict the length of the character string.