botbuilder-azure-blobs package
类
| BlobsStorage |
BlobsStorage 提供 Azure Blob 存储支持的 存储 实现 |
| BlobsTranscriptStore |
BlobsTranscriptStore 是一个 TranscriptStore,用于在 Azure Blob 存储中持久保存脚本 |
接口
| BlobsStorageOptions |
BlobsStorage 的可选设置 |
| BlobsTranscriptStoreOptions |
BlobsTranscriptStore 的可选设置 |
类型别名
| IgnoreError |
描述忽略错误函数 |
函数
| ignore |
包装承诺并提供一个函数来决定是否忽略错误类型 |
| is |
忽略与一组状态代码匹配的 RestErrors。 |
| sanitize |
确保 |
函数详细信息
ignoreError<T>(Promise<T>, IgnoreError)
包装承诺并提供一个函数来决定是否忽略错误类型
function ignoreError<T>(promise: Promise<T>, ignore: IgnoreError): Promise<T | null>
参数
- promise
-
Promise<T>
等待的承诺
- ignore
- IgnoreError
如果应忽略错误,则返回 true 的方法
返回
Promise<T | null>
在忽略任何匹配错误后解析为 T 或 null 的承诺
isStatusCodeError(number[])
忽略与一组状态代码匹配的 RestErrors。
function isStatusCodeError(codes: number[]): IgnoreError
参数
- codes
-
number[]
不应被视为错误的 HTTP 状态代码
返回
一个函数,如果它表示忽略的状态代码之一,则接受错误并返回 true
sanitizeBlobKey(string, BlobsTranscriptStoreOptions)
确保 key 已正确清理 Azure Blob 存储密钥。 它应该经过 URI 编码,不超过 1024 个字符,并且包含不超过 254 个斜杠(“/”)字符。
function sanitizeBlobKey(key: string, options?: BlobsTranscriptStoreOptions): string
参数
- key
-
string
要清理的字符串 Blob 密钥
- options
- BlobsTranscriptStoreOptions
BlobsTranscriptStore 的可选设置
返回
string
清理 Blob 密钥