Home » Categories » Solutions by Business Process » E-Business » XML |
Template Attributes |
Article Number: 1817 | Rating: Unrated | Last Updated: Thu, Jun 22, 2023 at 4:56 PM
|
Datafile Software Template Attributes Attributes are used in XML files to provide extra information about the data in that element. They are specified by the schema designer, and take the form word="value". E.g: <BuyersOrderNumber Preserve="true"> The Preserve="true" attribute here was created to say that this element must be returned intact in any reply message — so it is as much a note to the schema designer of any reply message in this case. Or again: <OrderLine Action="Add"> The "Action” attribute here could have a value of "Add”, "Change” or "Delete”, which this time determines how the element is to be treated by the receiving trading partner. Attributes are always contained within the opening element tag, and their value is always enclosed within quotes after an equals sign. There is no limit to the number of attributes that can be defined for an element, but any one attribute can be used only once. Datafile Attributes Datafile uses attributes in the XML template as a way to tell our XML processor how to process this element (and any child elements). These attributes are not passed to the output XML file, nor expected to be present in an incoming one. Datafile template attributes that are not recognised as Datafile-defined ones — in other words the attributes specified by the schema designer — are passed unchanged into any output XML file. If an attribute is present in an incoming file, but is not included in the Datafile template, then the element is processed as though the attribute was not present. Where different processes are to be invoked according to the value of the attribute — as you would expect with the "OrderLine” element above — then the Datafile template must include an element (and any child element set) for each of the possible attribute values. |
Attachments
There are no attachments for this article.
|
Diagnostic XML File Print
Viewed 3123 times since Mon, Jul 9, 2012
“Escaped” Data Characters
Viewed 2887 times since Mon, Jul 9, 2012
Checking an XML Template
Viewed 1484 times since Mon, Jul 9, 2012
flag
Viewed 1364 times since Mon, Jul 9, 2012
Template Wizard
Viewed 1503 times since Mon, Jul 9, 2012
Sending/Receiving XML Files
Viewed 1749 times since Tue, Jul 10, 2012
match
Viewed 1402 times since Mon, Jul 9, 2012
Date and Time
Viewed 1380 times since Mon, Jul 9, 2012
General Lookup File - Appendix 6
Viewed 1445 times since Tue, Jul 10, 2012
Send XML Acknowledgements, Send XML Delivery Notifications
Viewed 1458 times since Thu, Jul 5, 2012
|