Open redcatbear opened 5 years ago
@kaklakariada, could you please take care of this one?
Detection of ReqM2 is already implemented. If the root element of an XML file is not <specdocument>
, the observed log message is printed and further processing is stopped. However the XML file is parsed until the end without processing any events. We can fix this by throwing an exception (and catching it later) as described in the documentation of XMLReader.parse().
Is your feature request related to a problem? Please describe. OFT auto-detects files by extension. Unfortunately ReqM2's extension is to generic (
.xml
) this leads to other XML files unnecessarily being scanned, which has two consequences:Describe the solution you'd like When an XML file is about to be imported, OFT should check whether it really contains ReqM2 content. This comes in two variants at the moment:
Describe alternatives you've considered
.reqm2
): While being perfect for OFT this has the downside that it breaks compatibility and also that XML Editors don't know this extensions by default..reqm2.xml
): Works for OFT and XML editors. Downsides are that it is clunky and still breaks compatibility.Additional context This is an excerpt of example error output: