Свойство | Тип | Описание | |
---|---|---|---|
parentReaderContext | RichCommandLineContext |
Метод | Описание | |
---|---|---|
CanAssist ( RichCommandLineContext parentContext ) : bool |
Always returns true. When overrided in a derived class the derived class can provide custom logic to determine whether or not this assist provider can assist.
|
|
ClearMenu ( RichCommandLineContext notUsed ) : void |
Clears the menu from the console
|
|
ContextAssistSearch ( ) : System |
Initializes the search assist class
|
|
DrawMenu ( RichCommandLineContext parentContext ) : ContextAssistResult |
Writes the prompt message and takes over the console until the user makes a selection or cancels via the escape key. This method never returns a NoOp result.
|
|
OnKeyboardInput ( RichCommandLineContext parentReaderContext, |
This is not implemented because this assist provider always takes over the console during the draw menu.
|
|
Search ( IConsoleProvider console = null, bool allowCancel = true ) : ContextAssistSearchResult |
Performs a standalone search and cleans up the menu at the end.
|
Метод | Описание | |
---|---|---|
GetResults ( string searchString ) : List |
When implemented in the derived class, gets search results that match the search string. This ONLY gets called if SupportsAsync returns false.
|
|
GetResultsAsync ( string searchString ) : Task
|
When implemented in the derived class, gets search results that match the search string asynchronously. This ONLY gets called if SupportsAsync returns true.
|
Метод | Описание | |
---|---|---|
DoSearch ( string searchString ) : void | ||
DoSearchInternal ( RichCommandLineContext parentContext, IConsoleProvider standaloneConsole, bool allowCancel ) : void | ||
RedrawSearchResults ( ) : void | ||
_MoveSelectedIndex ( int amount ) : void | ||
_SearchReader_HandleEnterKey ( RichCommandLineContext searchReaderContext ) : void | ||
_SearchReader_HandleKeyPressed ( RichCommandLineContext searchReaderContext ) : void |
public CanAssist ( RichCommandLineContext parentContext ) : bool | ||
parentContext | RichCommandLineContext | context about the parent reader that we may be assisting |
Результат | bool |
public ClearMenu ( RichCommandLineContext notUsed ) : void | ||
notUsed | RichCommandLineContext | |
Результат | void |
public DrawMenu ( RichCommandLineContext parentContext ) : ContextAssistResult | ||
parentContext | RichCommandLineContext | context about the parent reader that we are assisting |
Результат | ContextAssistResult |
protected abstract GetResults ( string searchString ) : List |
||
searchString | string | the search string entered by the user |
Результат | List |
protected abstract GetResultsAsync ( string searchString ) : Task
|
||
searchString | string | the search string entered by the user |
Результат | Task
|
public OnKeyboardInput ( RichCommandLineContext parentReaderContext, |
||
parentReaderContext | RichCommandLineContext | not implemented |
keyPress | not implemented | |
Результат | ContextAssistResult |
public Search ( IConsoleProvider console = null, bool allowCancel = true ) : ContextAssistSearchResult | ||
console | IConsoleProvider | Optionally choose a custom console target |
allowCancel | bool | if true, users can cancel the search by pressing the escape key. If false, the escape key does nothing. |
Результат | ContextAssistSearchResult |