public void Compute(char @operator, int operand) { Command command = new CalculatorCommand(this.calculator, @operator, operand); command.Execute(); this.commands.Add(command); this.current++; }
public int Compute(char @operator, int operand) { Command command = new CalculatorCommand(_calculator, @operator, operand); int res = command.Execute(); _commands.Add(command); _current++; return(res); }
public void Compute(char @operator, int operand) { Command command = new CalculatorCommand(_calculator, @operator, operand); command.Execute(); _commands.Add(command); _current++; }
public void Compute(char @operator, int operand) { //TODO 「♠コマンドの処理を集約・引数でコマンドの種別を切り替える(オプション引数的な感じ)」 Command command = new CalculatorCommand(_calculator, @operator, operand); command.Execute(); _commands.Add(command); _current++; }
public void Compute(char mathematicalOperator, int value) { UndoableOperation command = new CalculatorCommand(Calculator, mathematicalOperator, value); command.Execute(); ExecutedCommands.Add(command); _numberOfCommands++; }
public void Compute(char @operator, int operand) { // Create command operation and execute it Behavioral.Command.AbstractCommand.Command command = new CalculatorCommand(_calculator, @operator, operand); command.Execute(); // Add command to undo list _commandsRepository.Add(command); _currentLevel++; }
public void Compute(char @operator, int operand) { // Create command operation and execute it Command command = new CalculatorCommand(_calculator, @operator, operand); command.Execute(); // Add command to undo list _commands.Add(command); _current++; }
public void Compute(char @operator, int operand) { // Create command operation and execute it Command command = new CalculatorCommand(_calculator, @operator, operand); command.Execute(); // Remove the Redo items _commands.RemoveRange(_current, _commands.Count - _current); // Add command to undo list _commands.Add(command); _current++; }