6.17 cls.system
 - isDocumentValid function added