public IDecorationCommandImplementation Get(IFileManipulationCommand command) { if (command is IDeleteCommand) return new DeleteCommand(command as IDeleteCommand); if (command is ICopyCommand) return new CopyCommand(command as ICopyCommand); throw new ArgumentException(); }
public IDecorationCommandImplementation Get(IFileManipulationCommand command) { if (command is IDeleteCommand) { return(new DeleteCommand(command as IDeleteCommand)); } if (command is ICopyCommand) { return(new CopyCommand(command as ICopyCommand)); } throw new ArgumentException(); }