[Mpuls-commits] r6147 - waska/trunk/waskaweb/lib
scm-commit at wald.intevation.org
scm-commit at wald.intevation.org
Thu Dec 13 14:15:03 CET 2012
Author: torsten
Date: 2012-12-13 14:15:03 +0100 (Thu, 13 Dec 2012)
New Revision: 6147
Added:
waska/trunk/waskaweb/lib/app_globals.py
Log:
Generate rules when loading the formed
Added: waska/trunk/waskaweb/lib/app_globals.py
===================================================================
--- waska/trunk/waskaweb/lib/app_globals.py (rev 0)
+++ waska/trunk/waskaweb/lib/app_globals.py 2012-12-13 13:15:03 UTC (rev 6147)
@@ -0,0 +1,13 @@
+"""The application's Globals object"""
+import os
+import logging
+import mpulsweb.lib.app_globals
+from formed.meta.io.document import openDocument
+log = logging.getLogger(__name__)
+
+class Globals(mpulsweb.lib.app_globals.Globals):
+ def _load_formedtree_from_file(self, formed_file):
+ # Build FormedTree. This tree will work as template for all cases
+ log.debug("loading formedtree definition with rules for JMD from %r",
+ formed_file)
+ return openDocument(formed_file, generate_rules=True)
More information about the Mpuls-commits
mailing list