Example #1
0
 def _getAttributes(self):
     attributes = {}
     for index, value in enumerate(self._xpath('@*') or []):
         attrname = TX.xmlAttrName2PyAttrName(
             self._xpath('name(@*[%d])' % (index + 1)))
         attributes[attrname] = TX.xmlValue2PyValue(
             value, self.C.XSL_XMLCONVERSIONS)
     return attributes
Example #2
0
 def _getAttributes(self):
     attributes = {}
     for index, value in enumerate(self._xpath('@*') or []):
         attrname = TX.xmlAttrName2PyAttrName(self._xpath('name(@*[%d])' % (index + 1)))
         attributes[attrname] = TX.xmlValue2PyValue(value, self.C.XSL_XMLCONVERSIONS)
     return attributes
Example #3
0
 def _set(self, key, value):
     tree = self._getTree()
     if tree is not None:
         key = TX.xmlAttrName2PyAttrName(key)
         tree.set(key, ` value `)
Example #4
0
 def _set(self, key, value):
     tree = self._getTree()
     if tree is not None:
         key = TX.xmlAttrName2PyAttrName(key)
         tree.set(key, `value`)