コード例 #1
0
ファイル: introspect.py プロジェクト: imfog/TACTIC-Handler
    def execute(self):

        # create an xml document
        xml_impl = getDOMImplementation()
        doc = xml_impl.createDocument(None, "session", None)
        root = doc.documentElement

        # go through the tactic
        tactic_nodes = self.util.get_all_tactic_nodes()
        tactic_nodes.sort()
        for tactic_node in tactic_nodes:
            node_data = NodeData(tactic_node)
            ref_node = node_data.get_ref_node()
            root.appendChild(ref_node)

        self.xml = doc.toxml()
        return self.xml
コード例 #2
0
ファイル: introspect.py プロジェクト: Southpaw-TACTIC/TACTIC
    def execute(self):


        # create an xml document
        xml_impl = getDOMImplementation()
        doc = xml_impl.createDocument(None, "session", None)
        root = doc.documentElement

        # go through the tactic
        tactic_nodes = self.util.get_all_tactic_nodes() 
        tactic_nodes.sort()
        for tactic_node in tactic_nodes:
            node_data = NodeData(tactic_node)
            ref_node = node_data.get_ref_node()
            root.appendChild(ref_node)

        self.xml = doc.toxml()
        return self.xml
コード例 #3
0
ファイル: session.py プロジェクト: rajubuddha/TACTIC
    def introspect(my):
        '''introspect the session and create a session xml from it'''
        # create an xml document
        xml_impl = getDOMImplementation()
        my.doc = xml_impl.createDocument(None, "session", None)
        my.root = my.doc.documentElement

        # go through the tactic
        tactic_nodes = my.util.get_all_tactic_nodes()
        tactic_nodes.sort()
        for tactic_node in tactic_nodes:

            node_data = NodeData(tactic_node)
            ref_node = node_data.get_ref_node()

            # set some more info on the ref node
            ref_node.setAttribute("tactic_node", tactic_node)
            my.root.appendChild(ref_node)

        my.xml = my.doc.toprettyxml()
        return my.xml
コード例 #4
0
ファイル: session.py プロジェクト: 2gDigitalPost/tactic_src
    def introspect(my):
        '''introspect the session and create a session xml from it'''
        # create an xml document
        xml_impl = getDOMImplementation()
        my.doc = xml_impl.createDocument(None, "session", None)
        my.root = my.doc.documentElement

        # go through the tactic
        tactic_nodes = my.util.get_all_tactic_nodes() 
        tactic_nodes.sort()
        for tactic_node in tactic_nodes:

            node_data = NodeData(tactic_node)
            ref_node = node_data.get_ref_node()

            # set some more info on the ref node
            ref_node.setAttribute("tactic_node", tactic_node)
            my.root.appendChild(ref_node)

        my.xml = my.doc.toprettyxml()
        return my.xml