XFA Specification
Chapter 8, Dynamic Forms
Data Binding for Dynamic Forms
272
Template DOM
Members
Form DOM
Members
Date
Date
Member
occur.initial = “3”
Member[0]
First
First
Last
Member[1]
Last
First
Last
Member[2]
First
Last
Relationship between the DOMs of the membership form after an empty merge
Greedy Matching
Once the data binding process has introduced a subform into the Form DOM, and the number of
occurrences is variable, the data binding process tries to match the full permitted number of siblings to
the data. This is referred to as
greedy matching.
But some of the matches may be indirect matches. These
indirect matches sometimes lead to non-intuitive results. For example, consider the following template
fragment from a passport application:
<template>
<subform name="application">
<subform name="sponsor">
<occur max="7"/> <!-- up to seven sponsors -->
<field name="last"> … </field> <!-- sponsor's last name -->
</subform>
<field name="last"> … </field> <!-- applicant's last name -->
</subform>
</template>
This template is merged with the following data:
<application>
<last>Abbot</last>
Home Index Bookmark Pages
Pages: Home Index All Pages