The purpose of the harvest library is to assist in retrieving and displaying objects from an Emdros database.

For the moment, there are four components to the Emdros "harvest" library:

  1. A "RenderObjects" class, which supports reading of objects into memory, producing a document from the objects read. The document can be XML-based, but need not be.

  2. A "RenderXML" module, which supports SAX-parser-based parsing of XML and rendering into something else, probably HTML.

  3. A "full text search" module (harvest_fts).

  4. A "full text search version 2" module (harvest_fts2).

The idea is to use the "RenderObjects" module for retrieving the objects from an Emdros database. These objects are then rendered into a document by the "RenderObjects" module, according to a pre-defined model, and driven by a user-supplied "stylesheet" telling the "RenderObjects" engine what to do. The output of this process is a document, i.e., a string containing a representation of the objects read. This document may or may not be XML, but if it is, then the "RenderXML" module may be used to transform the document to something else.

The idea of the "RenderXML" module is to take the XML produced by "RenderObjects" and produce something else -- probably HTML, but it could be any other format. The output is, again, a document in the form of a string. Again, a "stylesheet" is used to tell the "RenderXML" what to do.

JSON stylesheets

As mentioned, both of the above modules use user-supplied "stylesheets" in order to know what to do. These "stylesheets" are based on the JSON data interchange language.

For more information about JSON, please visit:

JSON is a very simple language, and should be easy to learn. An implementation of JSON is provided in the libemdf library, so no external dependencies are needed for this.

Previous:Part IV: Harvest library
Up:Part IV: Harvest library
Next:Emdros's JSON implementation