def removeCommandFromQueue(self, commandId): for function in self.queue: if commandId == function.getId(): self.queue.remove(function) return True current = functionDivider.getFunctionDivider().currentCommandObject if current is not None and current.getId() == commandId: functionDivider.getFunctionDivider().interuptCurrentCommand() return True return False
def getAllCommandOutputsInQueue(self): output = [command.output() for command in self.queue] current = functionDivider.getFunctionDivider().currentCommandObject if current is not None: output.insert(0, current.output()) return output
def cancelCurrentCommand(self): if functionDivider.getFunctionDivider().interuptCurrentCommand() is not None and len(self.queue) > 0: self.queue.pop(0)