def createXmlNode( self, document ): node = super( SourceCodeProvider, self ).createXmlNode( document ) pluginInfo = document.createElement( "pluginInfo" ) info = self.getRevisionInfo() pluginInfo.attributes["revision"] = unicode( info.revision ) pluginInfo.attributes["committerName"] = unicode( info.committerName ) pluginInfo.attributes["committerEmail"] = unicode( info.committerEmail ) pluginInfo.attributes["commitTime"] = unicode( info.commitTime ) pluginInfo.attributes["commitTimeReadable"] = unicode( info.commitTimeReadable ) create_child_node( document, pluginInfo, "commitMessage", unicode( info.commitMessage ) ) node.appendChild( pluginInfo ) return node
def createXmlNode( self, document, recursive = True ): """Create XML node for this object Feel free to overwrite in subclasses to add more details""" node = document.createElement( self.getTagName() ) node.attributes["name"] = self.getName() node.attributes["bases"] = " ".join( self.getBaseClassNames() ) node.attributes["relativeLinkTarget"] = str ( self.getRelativeLinkTarget()[0] ) node.attributes["relativeLinkTargetDescription"] = str ( self.getRelativeLinkTarget()[1] ) create_child_node( document, node, "objectdescription", self.getObjectDescription() if self.getObjectDescription() else "" ) create_child_node( document, node, "objectstatus", self.getObjectStatus() if self.getObjectStatus() else "" ) return node
def createXmlNode(self, document): node = super(Action, self).createXmlNode(document) node.attributes["finished"] = str(self.didFinish()) node.attributes["started"] = str(self.wasStarted()) node.attributes["timing"] = str(self.__timeKeeper.deltaString()) node.attributes["returncode"] = str(self.getResult()) stderr, stdout = self._getOutput() create_child_node(document, node, "stderr", to_unicode_or_bust(stderr)) create_child_node(document, node, "stdout", to_unicode_or_bust(stdout)) create_child_node(document, node, "logdescription", self.getLogDescription()) return node