예제 #1
0
    def updatePipeline(self, localId, medleyXml):
        root = ElementTree.fromstring(self.pipelineForKey[int(localId)])
        changed, root2 = self.update_xml(localId, ElementTree.fromstring(medleyXml))
      
        if not changed: return localId

        ppipe = ElementTree.tostring(root2)
        pdimm = self.dimensionsForKey[int(localId)]
        pmid = self.moduleIdsForKey[int(localId)]
        pnames = self.namesForKey[int(localId)]
		
        pinstance = unserialize(ppipe, Pipeline)

        self.deleteCell(localId)
        newId = self.dispatchPipeline(pinstance, pnames[0], pnames[1], pmid, pdimm)   

        return str(newId)
예제 #2
0
    def updatePipeline(self, localId, medleyXml):
        root = ElementTree.fromstring(self.pipelineForKey[int(localId)])
        changed, root2 = self.update_xml(localId,
                                         ElementTree.fromstring(medleyXml))

        if not changed: return localId

        ppipe = ElementTree.tostring(root2)
        pdimm = self.dimensionsForKey[int(localId)]
        pmid = self.moduleIdsForKey[int(localId)]
        pnames = self.namesForKey[int(localId)]

        pinstance = unserialize(ppipe, Pipeline)

        self.deleteCell(localId)
        newId = self.dispatchPipeline(pinstance, pnames[0], pnames[1], pmid,
                                      pdimm)

        return str(newId)
예제 #3
0
    def executePipeline(self,pipeline):
        from core.db.io import unserialize
        from core.vistrail.pipeline import Pipeline
        from core.interpreter.default import get_default_interpreter as getDefaultInterpreter
        from core.utils import DummyView
        import api

        tabController = self.spreadsheetWindow.get_current_tab_controller()
        pip = unserialize(str(pipeline), Pipeline)
#        print " **** Client-%s ---Received Pipeline--- modules:" % str( self.dimensions )
#        for module in pip.module_list:
#            print "     ", str(module.id)
        self.current_pipeline = pip
        interpreter = getDefaultInterpreter()
        kwargs = { "locator":           None,
                   "current_version":   None,
                   "view":              DummyView(),
                   "aliases":           {} }
        interpreter.execute( pip, **kwargs )
        print "Finished Executing Pipeline"
예제 #4
0
    def executePipeline(self, pipeline):
        from core.db.io import unserialize
        from core.vistrail.pipeline import Pipeline
        from core.interpreter.default import get_default_interpreter as getDefaultInterpreter
        from core.utils import DummyView
        import api

        tabController = self.spreadsheetWindow.get_current_tab_controller()
        pip = unserialize(str(pipeline), Pipeline)
        #        print " **** Client-%s ---Received Pipeline--- modules:" % str( self.dimensions )
        #        for module in pip.module_list:
        #            print "     ", str(module.id)
        self.current_pipeline = pip
        interpreter = getDefaultInterpreter()
        kwargs = {
            "locator": None,
            "current_version": None,
            "view": DummyView(),
            "aliases": {}
        }
        interpreter.execute(pip, **kwargs)
        print "Finished Executing Pipeline"