9.3 Identifying, Adding and Removing Flattened Attributes

Without complex type metadata, user input is required to add the flattened attributes. With the addition of complex type metadata, the attributes can be added automatically on definition of the complex type attribute.

The addition of new flattened attributes occurs when the Complex Type Attribute property is set.

The new flattened attributes have null expressions, since they do not directly reference upstream attributes, but are derived from an upstream attribute of a complex type. The name of the flattened attribute can match the name of the complex type member. However, if the flattened attribute receives a different name due to a name conflict with another attribute, the attribute tag property is used to identify the complex type member. If the flattened attribute name is changed manually, ensure that the tag property is set to the name of the complex type member.

For example, consider a complex type attribute full_name which contains member attributes first_name and last_name. When full_name is selected as the complex type attribute, two new flattened attributes, first_name and last_name, are created. If attribute last_name is changed to lname, its tag is set to last_name to identify the complex type member name to be used in code generation.

A user may not wish to flatten all the attributes of the collection of a complex type. Extra attributes can be deleted.