Maps to UML TaggedValues named “selector” and “field” of a UML Attribute representing key, keyRef, or unique. The “selector” tag has a value representing the “xpath” and “field," a list of values representing the field “xpath”. ID values shall be skipped and annotation documentation will be applied to the tagged value according to the annotation rule(see Annotation). For the values annotation field, documentation shall be merged into one.
A state element is defined, which contains a code child and some vehicle and person children. A vehicle in turn has a plateNumber attribute, which is an integer, and a state attribute. State's code s are a key for them within the document. Vehicle's plateNumber s are a key for them within states, and state and plateNumber is asserted to be a key for vehicle within the document as a whole. Furthermore, a person element has an empty car child, with regState and regPlate attributes, which are then asserted together to refer to vehicles via the carRef constraint. The requirement that a vehicle's state match its containing state's code is not expressed here.
For selector and field UML model example, see Keyref.