Re-wrote the library to use a Document. Took the xml generation code out of the "models" and placed it all in the Document Object.