15.6. Beyond This BookAs mentioned at the start of this chapter, there are open source programs that allow users to edit Excel and Word documents. It is natural to wonder whether any of these can also be used programmatically. The answer is a limited yes. In particular, OpenOffice provides a set of Java APIs by which an external program can invoke Chapter 9. An advantage to this approach is that the program needs to know nothing about Excel per se and can concentrate on building XML. An additional advantage is that OpenOffice already supports Word, and it supports a greater subset of Excel than POI does, including formulas.POI is also in the process of moving to an XML-based system. The HSSF serializer, the code responsible for translating to and from the binary BIFF8 representation, is moving to Apache Cocoon. Cocoon is a toolkit that enables components to be assembled into an XML pipeline. When this move is completed, it will be possible to feed an XML document to Cocoon and get an Excel file out, and vice versa. Pipeline components can also pull data from a database and inject it into XML prior to translation to Excel. Cocoon is discussed in Chapter 20. |