Sign in Join
Wiki copytemporary

fcl-xml: what changed

Revision 0 to 1. Removed lines have a minus sign; added lines have a plus sign.

Title: fcl-xml

OldNewLine
1+The package FCL-XML contains units that parse XML and HTML files to DOM, and can render the DOM tree to HTML, XHTML and XML.
2+
3+Most notably the HTML part still needs some work.
4+
5+## Units
6+
7+| Unit | Unit group | Comment |
8+|----|----|----|
9+| [[dom]] | \- | Implements the DOM level 2 Core specification and some of the DOM level 3 Core properties/methods. |
10+| [[dom html]] | \- | DOM extensions for HTML, THTMLDocument |
11+| [[dtdmodel]] | \- | Classes represententing the DTD (document type definition), used by xmlread and dom. |
12+| htmldefs | \- | Contains basic HTML declarations. |
13+| [[htmlelements]] | \- | Implements a DOM for HTML content. Contains a TDOMElement descendent for all valid HTML 4.1 tags. |
14+| [[htmlwriter]] | \- | Implements a verified HTML producer. |
15+| [[htmwrite]] | \- | Writes a DOM structure as UTF-8 encoded HTML data into file or stream. |
16+| [[sax]] | \- | Base classes for a parser after [SAX](https://en.wikipedia.org/wiki/_Simple_API_for_XML) model. |
17+| [[sax html]] | \- | HTML plugin (implementation) for the html SAX parser. |
18+| [[sax xml]] | \- | XML plugin for the SAX parser. |
19+| [[xhtml]] | \- | XHTML helper classes(?) |
20+| [[xmlcfg]] | \- | Implements TXMLConfig class, which enables applications to store their configuration data in XML files. |
21+| [[xmlconf]] | \- | An improved version of xmlcfg, based on DOMString instead of AnsiString. Provides better Unicode support, faster/smaller code due to absense of conversions, and TRegistry-like OpenKey/CloseKey methods. |
22+| [[xmliconv]] | \- | Registers an any-to-UTF-16 decoder based on libiconv ([[iconvenc]] package) |
23+| [[xmliconv windows]] | \- | Registers an any-to-UTF-16 decoder based on libiconv (windows dependant iconv header), Windows version. (still uses iconv!) |
24+| [[xmlread]] | \- | Provides routines and classes to read XML data from a file or stream into DOM. |
25+| [[xmlstreaming]] | \- | (Not functional) An initial attempt to support standard component streaming in XML format. The working variant of this unit is available in Lazarus (components/codetools/laz_xmlstreaming.pas). |
26+| [[xmlutils]] | \- | Implements utility functions and classes that are used by other units in the package. |
27+| [[xmlwrite]] | \- | Writes a DOM structure as XML data into a file or stream. It can deal both with XML files and XML fragments. |
28+| [[xpath]] | \- | Just an XPath implementation. Should be fairly completed, but there hasn't been further development recently. |
29+| [[xmlreader]] | \- | Contains TXMLReader, an abstract base class for .NET style streamed XML reading. |
30+| [[xmltextreader]] | \- | Contains TXMLTextReader, a TXMLReader descendant which parses text. This is the core of XML reading functionality. |
31+
32+Include files
33+
34+| include file | comment |
35+|----|----|
36+| names.inc | Included by xmlutils. Contains character tables for XML names. |
37+| tagsimpl.inc | |
38+| tagsintf.inc | contains all possible tags for htmlelements |
39+| wtagsimpl.inc | |
40+| wtagsintf.inc | contains all possible tags for htmlwriter |
41+| xpathkw.inc | contains the perfect hash function for XPath keywords |
42+| | |
43+
44+## Notes
45+
46+- beware, both dom_html and htmlelements seem to define a THTMLDocument class.
47+- The nodemanager of DOM is not Delphi (2009 in my case) compatible, which can lead to strange crashes when attempting to free code. This might have to do with different minimal size of an object.
48+
49+## Tutorial
50+
51+- Here: [[XML Tutorial]]
52+
53+## Links
54+
55+- [Dom specs](http://www.w3.org/DOM/DOMTR)
56+- [Sax based html parser](http://htmlparser.sourceforge.net/) (Java)
57+- [The Sax project](http://www.saxproject.org/) (Java)
58+
59+## Cleanup
60+
61+- lots of "dynamic" methods. Afaik FPC doesn't implement it (always virtual iirc), since it was mainly needed in 16-bit envs. Fixed in r13382
62+- ifdef usedynarrays in sax.pp is so 1.0.x
63+
64+## See also
65+
66+- [[Package List|Packages List]]
67+
68+---
69+*From the Free Pascal wiki, page "fcl-xml", as it stood on 2022-08-06 after a change by Kai Burghardt, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).*
70+Category: FCL
71+Category: Packages
72+Category: XML

Back to history