An attribute describes an XML attribute, or any simple element within a message.
Attributes are provided to simplify the modeling of XML messages - if none of your messages use the XML physical format, you should consider using simple elements instead.
The most common use for an attribute is to model an XML attribute within an XML message. In this scenario, each attribute which can appear in the XML message has a corresponding attribute in the logical message definition.
Sometimes a message needs to be parsed as XML but written in another physical format (Custom Wire Format or Tagged Delimited String Format). In this case, any attributes in the message will be treated exactly like simple elements with the same properties.
Attributes can be global or local.
A global attribute can be used in more than one place in the message model. It must be given a unique name by which it can be referenced.
A local attribute is defined in one position within one complex type, and is not available for reuse elsewhere in the message model.
Attributes can be defined as optional, required or prohibited. Attributes are not allowed to repeat. For further information, see Cardinality: optional, repeating and mandatory elements.
An attribute can be given a default value, so that if the attribute is missing from the input message, the default will be used. Alternatively, a fixed value can be defined, and the attribute will always take that value.
An attribute's value can be constrained by using value constraints which define the range of legal values for the attribute. The value constraints are actually associated with the simple type on which the attribute is based. For further details, see Message model objects: simple types.
In the message definition file, an attribute is modeled as an XML schema attribute declaration. Fixed and default values are modeled using a value constraint on the attribute. Value constraints are modeled as facets on the attribute's simple type.
Notices |
Trademarks |
Downloads |
Library |
Support |
Feedback
![]() ![]() |
ad10420_ |