Hi Folks, Before I get to my question, please allow me to share a short story.
Early versions of Fortran did not have high-level programming language constructs such as while-loops, so some smart person came along and created RATFOR (Rational Fortran), which extended Fortran with several high-level constructs. That
person then created a preprocessor which converted programs expressed in RATFOR into equivalent Fortran programs. For example, here is a RATFOR program that uses the high-level while-loop construct: while (getc(c) != EOF) The RATFOR preprocessor converts it to this equivalent Fortran code: 10 if (getc(c) .eq. EOF goto 20 Now for my question. Question: How to represent step-by-step procedures in XML? The XML representation must be:
What follows is a real-world example to illustrate my question. I have a file named ARPT.xml which contains a list of records for all the airports in the world. Each record contains data about an airport.
I have another file named NAV.xml which contains a list of records for all the navigation aids (navaids) in the world. Each record contains data about a navaid.
Some navaids are placed in locations to help airplanes fly between airports. Other navaids are placed in locations to help airplanes fly in and out of airports. Some airports are close to each other, so some navaids are used by more than one airport. In some cases, the same navaid is used by airports in different countries; for example, at the US-Canada border there might be a navaid that is shared
between airports in the US and Canada. Since a navaid may be used by more than one airport, there is a file named ANAV.xml that is intermediary between ARPT.xml and NAV.xml; it maps a nav ID and country ID to the navaid records for the airport. In other words, there is a level
of indirection to obtaining the navaid records for an airport. We use the airport ID from ARPT.xml as a foreign key into ANAV.xml to obtain a set of ANAV records, and for each ANAV record, we use its nav ID and country ID as a composite foreign key into NAV.xml.
The selected NAV records are the airport’s navaids. How to represent in XML the procedure for obtaining the navaid records for an airport?
You might wonder, “Why create an XML representation of a
procedure?” The answer is threefold:
Here is one possible XML representation of the procedure: <Procedure> Readers may recognize that as XSLT code, minus the xsl namespace prefix. That XML representation is simply not acceptable. It probably can be understood by a developer who knows XSLT, but to most developers and to most managers it is pure gibberish. It is analogous to the Fortran shown about.
I am seeking a high-level XML representation, one that is understandable by a manager and at the same time is sufficiently detailed that it can be executed, or I can write a preprocessor which converts it into equivalent lower-level programming
language code (analogous to how the RATFOR preprocessor converts programs written in the high-level RATFOR into equivalent low-level Fortran). I seek your suggestions on a high-level XML representation of the airport/navaid procedure I described. /Roger |