Posts

In this article we discover the possibilities of Document Script fragments when dealing with complex requirements for document geneneration templates in Sparx Enterprise Architect.

The request

The other day I got a difficult request for a document generation template. At this client they are documenting Use Case scenarios using the structured scenario editor in EA. Each scenario step can be linked to a requirement element.

Each Requirement could have one or more constraints

Based on these scenarios the customer wanted to generate a test scenario document that contained a table like this

StepStep descriptionRequirementRequirement constraints
1User chooses to make a new reservation
2System show the reservation screen where the user can enter Begin, Endate and Roomtype
3User enters begindate and enddate or the numbers of nightsREQ_RV_ 403 Reservation periodInvariant: StartDate < Enddate
Post-condition: A reservation must have a reservation period in the future

The first three columns are available in the standard point and click templates, but the problematic part is the Requirement constraints.… Read more