When you examined each travel document, you identified
pages that are required and optional.
For example, in car rental documents:
- The rental agreement page is required.
- The insurance page is optional.
For travel documents with multiple pages, there might be requirements
for the number or order of pages of each document type. This table
summarizes the structure of each travel document type.
| Document Type |
Page Type |
Number |
Required? |
Order |
| Car Rental |
|
Any number per batch |
No |
Any position within batch |
| |
Rental Agreement |
One per document |
Yes |
Must be first in document |
| |
Optional Insurance |
One per document |
No |
Must be second in document |
| Hotel |
|
Any number per batch |
No |
Any position within batch |
| |
Room_Receipt |
One per document |
Yes |
Must be first in document |
| |
Meals |
Any number per document |
No |
Cannot be first in document |
| |
Other_Charges |
Any number per document |
No |
Cannot be first in document |
| Flight |
|
Any number per batch |
No |
Any position within batch |
| |
Air_Ticket |
One per document |
Yes |
Must be first in document |
This structural information is an important element of the
design requirements that you use when you implement the application's
document hierarchy. When you implement the document assembly stage
of the workflow, you use this information to determine whether the
pages in the batch meet the structural requirements.
The assumption for the sample application is that you are entering
batches of mixed travel documents with multiple, consecutive pages
that are in the correct order. For example, a batch might include
any number of car rental documents, flight documents, and hotel documents.
Also, the pages within each document are consecutive and in the correct
order. If the batch meets the structural requirements, then the application
assembles the documents automatically. However, if the batch contains
orphan pages or pages that do not meet the rules for document integrity,
then operator intervention is required.
In the following example, the batch does
not contain any errors, and no operator intervention is required.| Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
| Rental Agreement |
Optional Insurance |
Air Ticket |
Room Receipt |
Room Receipt |
Meals |
Rental Agreement |
Optional Insurance |
Air Ticket |
In
this second example, the batch contains three errors and requires
operator intervention.| Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
Page type |
| Optional Insurance (1) |
Room Receipt |
Room Receipt |
Air Ticket |
Meals (2) |
Rental Agreement |
Optional Insurance (3) |
Optional Insurance (3) |
Air Ticket |
- Orphaned optional insurance page must follow a rental agreement
page.
- Orphaned meals page must follow a room receipt page.
- Two optional insurance pages are not allowed in a Car Rental document.