For more information, load ./doc/readme.html. 'coure that's incomplete too.

Directories:
	doc:
		where you will find more documentation
	dtds:
		static DTDs. one should not assume they are valid
	examples:
		example XML files
	lib:
		script interface to IcXmlReport, IcXmlInter, etc.
	src:
		this dir does not currently exist, but SWIG-interface to libxml2 impl
	tests:
		where you'll find tests. you can run tests with "make test"

Files:
	main.tcl:
		does things like load or test this module
	Makefile:
		you can do a "make test" currently.


Requires:
	tdom Tcl-package (www.tdom.org)


Testing:
	make test


Future enhancements:
	fill out IcXmlInter with for tree-queries, add tDomImpl stuff as necessary.
	in ./src/ create a C/libxml2/SWIG-wrapped impl of what is currently in lib/ so we can do this through C-libs.

#--------------------------------------------------------------------------------------------------------------------

What/Where
----------

I have been working on a module called:
    ic_xml
which I now use in several contexts. It is primarily for the generation of:
    xml & html reports

-----------------------------------------------------------------------

Why
---

I have written it:

    o so that we can quickly-view (in HTML) and batch-compare (in XML) meshing(, etc.) results in automated contexts like regression testing or batch-surface-meshing

    o with the idea that sooner or later our userbase will be loading geometries, setting bcs, and verifying a mesh-report while the solver is working, perhaps never seeing the mesh. They can put that report in their records or attach it to the solver results.

Some info here:
    http://www.icemcfd.com:8080/Bugzilla/show_bug.cgi?id=7900

-----------------------------------------------------------------------

Current uses
------------

--> Batch Surf (3.0)

    After "Generate mesh" is finished, you can view an HTML file with an <assembly_report> comprising a <mesh_report> of each part meshed. Attached is an example for a single-part run. (The report includes too much info right now, but...) This will make "Review meshed parts" used more selectively.

    The HTML is (XLST-)generated from an XML file which we can use for regression testing the batch-surface mesher. I have yet to write the compare function of the files, but we could makes sure that xml_file_a reports as good mesh foreach part in xml_file_b by looking at the <mesh_quality> section of each.
    
    Later, I will add a <weld_report> element to the <assembly_report>, based on the info in the current weld-report.


--> ic_regression

    The ic_regression test module will write out an XML file which matches MBU's (current) TestBench format, logging the results and execution time of the test, etc. Later, this module will be able to compare canonical a <mesh_report> to ensure that <mesh_quality> etc. is at least as good, making regression testing of meshers a lot smarter.


--> med/ai_env

There is a proc (med_batch/reports_funcs.tcl) that works like:

    ic_reports_write_mesh_report $subsetname test.xml -format xml
    ic_reports_write_mesh_report FILE test.html -format html \
        -domain project1.uns

This function is used by the batch-mesher (mesh_quad.tcl), but as it becomes useful, perhaps you'd want a button in the UI.

Just don't do anything like add non-mesh data (like boco's) to the <mesh_report>, rather define a <project_report> that includes a <mesh_report> and add new elements from there (<bc_report>, etc.).


--> iceboard_meshing (gmake test)

If you do:

    cd /path/to/iceboard_meshing ; gmake test $various_vars

it will test all of the regression models and create a single (assembly) HTML report of the meshes created foreach model so you can see at-a-glance what breaks, what gets too many elements now, which meshes end up with ORFN shells, etc.

--------------------------------------------------------------

Support
-------
Only linux and windows are supported right now, since I have yet to compile the tdom/expat parser (www.tdom.org; use cvs head since v.0.7.8 has a bug we encountered) on other plats. HP is next, then SGI. Also I should recompile the windows version to be 0.8.0 instead of 0.7.8.

The libs are at:
    5.0-linux/lib/libtdom0.8.0.so
    5.0-win\bin\libtdom0.7.8-win32.dll

If some other parser is implemented to conform to the ic_xml/lib/ic_xml_inter.tcl procs, then you need only initialize IcXmlInter with the name of that parser (assuming that name mapped to a source file implementation in IcXmlInter).

--------------------------------------------------------------

Style
-----
You can mess around with the CSS defs (printed to each HTML file) but be careful about modifying the ic_xml/style/generic.css since it's supposed to be, well, generic.

XSL-transforms are also in ic_xml/style/ and govern what from XML gets put into the HTML and how. Info on w3c.org.
