/// <summary> /// Generate possible completions of this argument that start with the /// provided string prefix. /// </summary> /// <param name="tokens">The set of tokens in the input being completed. /// </param> /// <param name="indexOfTokenToComplete">The 0-based index of the token /// to complete.</param> /// <param name="valueToComplete">The prefix string.</param> /// <param name="inProgressParsedObject">Optionally, the object /// resulting from parsing and processing the tokens before the one /// being completed.</param> /// <returns>Possible completions.</returns> public IEnumerable <string> GetCompletions(IReadOnlyList <string> tokens, int indexOfTokenToComplete, string valueToComplete, object inProgressParsedObject) { var context = new ArgumentCompletionContext { ParseContext = _argumentParseContext, Tokens = tokens, TokenIndex = indexOfTokenToComplete, InProgressParsedObject = inProgressParsedObject, CaseSensitive = _setAttribute.CaseSensitive }; return(ArgumentType.GetCompletions(context, valueToComplete)); }