gump-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aj...@apache.org
Subject svn commit: r158597 - in gump/trunk/python/gump: core/model/builder.py core/model/depend.py core/model/object.py util/domutils.py
Date Tue, 22 Mar 2005 11:46:28 GMT
Author: ajack
Date: Tue Mar 22 03:46:26 2005
New Revision: 158597

URL: http://svn.apache.org/viewcvs?view=rev&rev=158597
Log:
Respect runtime="false" (not assume all runtime settings are true)

Modified:
    gump/trunk/python/gump/core/model/builder.py
    gump/trunk/python/gump/core/model/depend.py
    gump/trunk/python/gump/core/model/object.py
    gump/trunk/python/gump/util/domutils.py

Modified: gump/trunk/python/gump/core/model/builder.py
URL: http://svn.apache.org/viewcvs/gump/trunk/python/gump/core/model/builder.py?view=diff&r1=158596&r2=158597
==============================================================================
--- gump/trunk/python/gump/core/model/builder.py (original)
+++ gump/trunk/python/gump/core/model/builder.py Tue Mar 22 03:46:26 2005
@@ -154,7 +154,7 @@
         ids=getDomAttributeValue(pdom,'id','')
 
         # Runtime?
-        runtime=hasDomAttribute(pdom,'runtime')
+        runtime=domAttributeIsTrue(pdom,'runtime')
 
         if workspace.hasProject(projectName): 
                         

Modified: gump/trunk/python/gump/core/model/depend.py
URL: http://svn.apache.org/viewcvs/gump/trunk/python/gump/core/model/depend.py?view=diff&r1=158596&r2=158597
==============================================================================
--- gump/trunk/python/gump/core/model/depend.py (original)
+++ gump/trunk/python/gump/core/model/depend.py Tue Mar 22 03:46:26 2005
@@ -66,11 +66,6 @@
     
     annotation = None # 'Expressed Dependency'
     
-    # :TODO: I hate this line of code!!!!
-    # :TODO:#2: I really hate this code, we ought not be trying
-    # to acess the delegate. We do so to check for existence
-    # but w/o value. Not good. Really gotta re-write that XML
-    # loading/merging stuff.
     noclasspath=hasDomChild(ddom,'noclasspath')    
         
     # Construct the dependency

Modified: gump/trunk/python/gump/core/model/object.py
URL: http://svn.apache.org/viewcvs/gump/trunk/python/gump/core/model/object.py?view=diff&r1=158596&r2=158597
==============================================================================
--- gump/trunk/python/gump/core/model/object.py (original)
+++ gump/trunk/python/gump/core/model/object.py Tue Mar 22 03:46:26 2005
@@ -156,6 +156,9 @@
         Annotatable.dump(self,indent,output)
     
     # Helper methods
+    def domAttributeIsTrue(self,name):
+        return domAttributeIsTrue(self.element,name)
+        
     def hasDomAttribute(self,name):
         return hasDomAttribute(self.element,name)
     

Modified: gump/trunk/python/gump/util/domutils.py
URL: http://svn.apache.org/viewcvs/gump/trunk/python/gump/util/domutils.py?view=diff&r1=158596&r2=158597
==============================================================================
--- gump/trunk/python/gump/util/domutils.py (original)
+++ gump/trunk/python/gump/util/domutils.py Tue Mar 22 03:46:26 2005
@@ -165,6 +165,11 @@
     if element.hasAttributes():
         return element.hasAttribute(name)
     return False
+    
+def domAttributeIsTrue(element,name):
+    return hasDomAttribute(element,name) and \
+               getDomAttributeValue(element.name) in ['true','True']
+     
 
 def getDomAttributeValue(element,name,default=None):
     return element.getAttribute(name) or default



Mime
View raw message