-
Notifications
You must be signed in to change notification settings - Fork 2
Home
RETA (Requirement Engineering Traceability Analysis) can read any source of documents or code, extracts the requirements and requirement references, and analyses them for generate the traceability matrix.
Requirement and references are extracted from documents using regular expression. You can find documentation on the web and for example here : https://docs.oracle.com/javase/8/docs/api/java/util/regex/Pattern.html#construct
So, if your requirements are formatted like this in your document :
REQ_RETA_SRS_NNNN_v - summary
content
REQ_END
Where "NNNN" is the requirement number, "v" the version, "label" the summary description and "content" the detailed description.
Then, regular expression to match requirement start may be :
^[ \t]*REQ_(RETA_SRS_\d+)_(\w+)[\s-]+(.*)$
And regular expression to match requirement end may be :
^[ \t]*REQ_END[ \t]*$
Bracket will capture part of text which will be used, for example, for identify the requirement reference using "Id" attribute (https://docs.oracle.com/javase/8/docs/api/java/util/regex/Pattern.html#cg).
For done this, you must identify each capture group using "Index of regular expression groups in requirement starts" table and "Index of regular expression groups in references" table.
In this sample "Id" attribute must be set to 1 for capture "RETA_SRS_NNNN".
Attribute "Version" may be fixed to 2 and attribute "Summary" to 3.