PromptValidatorContext<T> Class
- java.
lang. Object - com.
microsoft. bot. dialogs. prompts. PromptValidatorContext<T>
- com.
Type Parameters
- T
Type for this Context
public class PromptValidatorContext<T>
Contains context information for a {@link PromptValidator{T}} .
Constructor Summary
| Constructor | Description |
|---|---|
| PromptValidatorContext(TurnContext turnContext, PromptRecognizerResult<T> recognized, Map<String,Object> state, PromptOptions options) |
Create a Prompt |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
| int |
getAttemptCount()
Gets the number of times this instance of the prompt has been executed. |
|
Turn |
getContext()
Gets the TurnContext for the current turn of conversation with the user. |
|
Prompt |
getOptions()
Gets the PromptOptions used for this recognition attempt. |
|
Prompt |
getRecognized()
Gets the {@link Prompt |
| java.util.Map<java.lang.String,java.lang.Object> |
getState()
Gets state for the associated prompt instance. |
Methods inherited from java.lang.Object
Constructor Details
PromptValidatorContext
public PromptValidatorContext(TurnContext turnContext, PromptRecognizerResult
Create a PromptValidatorContext Instance.
Parameters:
Method Details
getAttemptCount
public int getAttemptCount()
Gets the number of times this instance of the prompt has been executed. This count is set when the prompt is added to the dialog stack.
Returns:
getContext
public TurnContext getContext()
Gets the TurnContext for the current turn of conversation with the user.
Returns:
getOptions
public PromptOptions getOptions()
Gets the PromptOptions used for this recognition attempt.
Returns:
getRecognized
public PromptRecognizerResult
Gets the {@link PromptRecognizerResult{T}} returned from the prompt's recognition attempt.
Returns:
getState
public Map
Gets state for the associated prompt instance.
Returns: