comments, cleanup and added DocumentType property to AP_Document base.