PromptValidatorContext<T> 類別
- java.
lang. Object - com.
microsoft. bot. dialogs. prompts. PromptValidatorContext<T>
- com.
類型參數
- T
此內容的類型
public class PromptValidatorContext
包含 {@link PromptValidator{T}} 的內容資訊。
建構函式摘要
| 建構函式 | Description |
|---|---|
| PromptValidatorContext(TurnContext turnContext, PromptRecognizerResult<T> recognized, Map<String,Object> state, PromptOptions options) |
|
方法摘要
| 修飾詞與類型 | 方法與描述 |
|---|---|
| int |
getAttemptCount()
取得執行這個提示實例的次數。 |
|
Turn |
getContext()
取得目前與使用者交談回合的 TurnContext。 |
|
Prompt |
getOptions()
取得用於這個辨識嘗試的 PromptOptions。 |
|
Prompt |
getRecognized()
取得從提示辨識嘗試傳回的 {@link Prompt |
| java.util.Map<java.lang.String,java.lang.Object> |
getState()
取得相關聯提示實例的狀態。 |
方法繼承來源 java.lang.Object
建構函式詳細資料
PromptValidatorContext
public PromptValidatorContext(TurnContext turnContext, PromptRecognizerResult
建立 PromptValidatorContext 實例。
參數:
方法詳細資料
getAttemptCount
public int getAttemptCount()
取得執行這個提示實例的次數。 當提示新增至對話框堆疊時,就會設定此計數。
傳回:
getContext
getOptions
getRecognized
public PromptRecognizerResult
取得從提示辨識嘗試傳回的 {@link PromptRecognizerResult{T}} 。
傳回:
getState
public Map
取得相關聯提示實例的狀態。
傳回: