Last active
December 30, 2015 06:29
-
-
Save tobiascoetzee/7789832 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ValidationChecker(): | |
def __init__(self, validationContext, validationsFile, validationsModule): | |
self.Context = validationContext | |
self.Errors = {} | |
self.__validationsTree = self.__LoadFile(validationsFile) | |
self.__module = __import__(validationsModule) | |
def __LoadFile(self, validationsFile): | |
base = '' | |
source = os.path.join(base, 'data', 'validations', validationsFile) | |
logdebug('Loading validation file: %s' % source) | |
tree = etree.ElementTree() | |
tree.parse(source) | |
return tree |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment