XES - XML Encoded Source
It seems to me that it would be useful to have a standardised way to encode
source code in XML form. This could be used for the following:
- When encoded an XSLT script XES could then be used to translate the code
into other forms, such as:
- Conversion to other languages, XSLT might not easily do a complete conversion
without error, but it could at least do the first step and take some of
the drudgery out of human conversion.
- Generation of documentation such as UML
diagrams and other diagrams possibly in SVG
- XES could be a good intermediate format for code generators.
- XES can hold code in a format where the first parsing stage of compiling
has already been done, this would allow:
- code to be more quickly compiled on the fly.
- Open Source code to be distributed in this form with Linux so that it
can be compiled more quickly and with less errors than distributing it
- To allow some small level of language independence in code distributing
code without loosing any information.
- XES could define an intermediate language, like Java or C# intermediate
code, which is more like the source code but could still be interpreted at
- XES could provide a much better way to mix scripting code in with XML data.
- XES could provide a more general way to define algorithms together with
the data it is acting on.
An explanation of the requrements for the schema
is shown here.
- XES stores source code in XML format.
- This should contain full source code including comments.
- It should be optimised for machine reading (since users are unlikely to
type XML by hand).
- The number of elements and the complexity should be minimised.
- The design should be optimised to allow the fastest possible translation,
compiling or interpretation of code.
- It should code the syntax of the language, but not necessarily things like:
does the laguage have garbage collection, does the language support multiple
inheritance. XES should support any combination of these things, perhaps there
could be a global attribute to say whether these are true or not.
For example, where a method is called it should be linked back as easily as
possible to the definition of the method and its class definition, even if there
is late binding due to virtual classes.
|Correspondence about this page
Book Shop - Further reading.
Where I can, I have put links to Amazon for books that are relevant to
the subject, click on the appropriate country flag to get more details
of the book or to buy it from them.
Other Java books
Commercial Software Shop
Where I can, I have put links to Amazon for commercial software, not
directly related to this site, but related to the subject being discussed,
click on the appropriate country flag to get more details of the software
or to buy it from them.
Can this page be improved?
Please send me any improvements to
here. I would appreciate ideas to make the pages more useful including
error correction, ideas for new pages, improvements to wording. It helps
if you quote the full URL of the page.
I am working on a project which uses these principles, if you would like
to help me with this you are welcome to join in, here:
for xml encoding: http://sourceforge.net/projects/xes/
This site may have errors. Don't use for critical systems.
Copyright (c) 1998-2006 Martin John Baker - All rights reserved.