public List <String> TabComplete(ICommandSender sender, string alias, string[] args) { Debug.Assert(sender != null, "Sender cannot be null"); Debug.Assert(args != null, "Arguments cannot be null"); Debug.Assert(alias != null, "Alias cannot be null"); List <string> completions = null; try { if (completer != null) { completions = completer.OnTabComplete(sender, this, alias, args); } if (completions == null && executor is ITabCompleter) { completions = ((ITabCompleter)executor).OnTabComplete(sender, this, alias, args); } } catch (Exception ex) { var message = new StringBuilder(); message.Append("Unhandled exception during tab completion for command '/").Append(alias).Append(' '); foreach (String arg in args) { message.Append(arg).Append(' '); } message.Remove(message.Length - 1, message.Length).Append("' in plugin ").Append(owningPlugin.GetPluginInfo().FullName); throw new CommandException(message.ToString(), ex); } if (completions == null) { return(base.TabComplete(sender, alias, args)); } return(completions); }