def db_change_connection(self, connection):
        self.is_dirty = True
        try:
            i = self.db_connections_inverted_id_index[connection._db_id]
        except __HOLE__:
            found = False
            for i in xrange(len(self._db_connections)):
                if self._db_connections[i]._db_id == connection._db_id:
                    self._db_connections[i] = connection
                    found = True
                    break
            if not found:
                self.db_add_connection(connection)
                return
        self._db_connections[i] = connection
        self.db_connections_id_index[connection._db_id] = connection
dataset/ETHPy150Open VisTrails/VisTrails/vistrails/db/versions/v0_9_1/domain/auto_gen.py/DBWorkflow.db_change_connection