[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
How to assess the correctness of a Format1 --> Format2 mapping?
- From: Roger L Costello <costello@mitre.org>
- To: "xml-dev@lists.xml.org" <xml-dev@lists.xml.org>
- Date: Mon, 23 Jan 2023 19:23:58 +0000
Hi Folks,
There exists a proprietary data format called Format1.
A smart group of people created a non-proprietary data format called Format2. It's used to store the same kinds of data as Format1. Of course, Format2 uses different fields and structures.
I defined a mapping from Format1 to Format2.
I want to know if my Format1 --> Format2 mapping is correct.
Here's my idea on how to ascertain the correctness of the Format1 --> Format2 mapping:
Use a technology to parse Format1 instances to XML and to parse Format2 instances to XML. Compare the resulting XML's. If they are identical, then the mapping is correct.
Data Format Description Language (DFDL) is a standard language for parsing data formats. Here's the idea using DFDL:
- Create a DFDL schema for Format1.
- Create a DFDL schema for Format2.
- Design the DFDL schemas to produce the same XML format.
- To ascertain the correctness of the Format1 --> Format2 mapping do this:
- Use the Format1 DFDL schema to parse a Format1 document to XML.
- Use the Format2 DFDL schema to parse a Format2 document to XML.
- Compare the XML's:
- If they are identical, then the mapping is correct.
- If they are within a certain tolerance, then the mapping is correct.
E.g. of an acceptable tolerance: the Format2 XML omits an
optional element.
- Otherwise the mapping is not correct.
Am I thinking clearly about this problem (ascertain the correctness of the Format1 --> Format2 mapping)?
Is mapping instances of the Format1 and Format2 data formats to a common XML format logical?
What are the flaws in my thinking?
/Roger
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]