After a long review process with HP's Open Source Review Board, a colleague and I have been given permission to release the source code for our HTML Generator project under the MIT License. What is this HTML Generator I speak of? Well, continue reading to find out.
Under the hood, the HTML Generator uses Java Objects to represent each HTML element, or tag. For example, a <div> element is represented using a Div object. Similarly, developers can set attributes on these nodes using a setAttribute() method for each object. An HTML page, or hierarchy, is built by creating a set of element objects and appending them to each other in the correct order. To convert an HTML Generator object hierarchy into a String which can be sent to a web-browser, the developer should call the write() method on the top-level element. The resulting String is well-formed HTML."
Eventually, we expect to enhance the HTML Generator engine to strictly adhere to the HTML 4 Document Type Definition (DTD). I'm looking forward to finally submitting this project to Google Code or Sourceforge; we haven't decided yet which source management tool to use. Either way, it's going to be great to get this Java code out there and then add support for other languages like PHP and Perl.


Did you find this post helpful, or at least, interesting?