你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

CallClientState interface

代理 StatefulCallClient的所有状态数据的容器。 如果已创建 callAgent,则将自动提供 call、callsEnded、incomingCalls 和 incomingCallsEnded 状态。 deviceManager 最初将为空,直到填充后看到 DeviceManagerState。 userId 状态为方便开发人员提供,完全由开发人员控制和设置。

属性

callAgent

的 <xref:%40azure%2Fcommunication-calling%23CallAgent>代理。 请查看 CallAgentState

calls

<xref:%40azure%2Fcommunication-calling%23CallAgent.calls>作为具有 CallState CallState 字段的 对象的代理。 它由 键 <xref:%40azure%2Fcommunication-calling%23Call.id>。 请注意,这可能会 <xref:%40azure%2Fcommunication-calling%23Call.id> 更改。 不应缓存 ID 本身,而应缓存整个 <xref:%40azure%2Fcommunication-calling%23Call> ID,然后使用包含的 ID 在此映射中查找数据。

callsEnded

已结束的调用存储在此处,因此可以检查 callEndReason。 它是一个具有 <xref:%40azure%2Fcommunication-calling%23Call.id> 键和 CallState 值的对象。 只有 <xref:MAX_CALL_HISTORY_LENGTH> 调用保留在历史记录中。 如果需要,将逐出最早的调用。

deviceManager

的 <xref:%40azure%2Fcommunication-calling%23DeviceManager>代理。 请查看 DeviceManagerState

incomingCalls

作为具有<xref:IncomingCall>字段的 <xref:%40azure%2Fcommunication-calling%23IncomingCall> 对象的代理。 它由 键 <xref:%40azure%2Fcommunication-calling%23IncomingCall.id>。

incomingCallsEnded

已结束的传入呼叫存储在此处,因此可以检查 callEndReason。 它是作为具有 <xref:%40azure%2Fcommunication-calling%23Call.id> 键和 <xref:IncomingCall> 值的 对象。 只有 <xref:MAX_CALL_HISTORY_LENGTH> 调用保留在历史记录中。 如果需要,将逐出最早的调用。

latestErrors

存储每个 API 方法的最新错误。 有关详细信息,请参阅 {@Link CallErrors} 的文档。

userId

存储 userId。 这不由 使用 StatefulCallClient ,此处提供是为了方便开发人员访问 userId。 必须在 初始化 StatefulCallClient时传入 。 完全由开发人员控制。

属性详细信息

callAgent

的 <xref:%40azure%2Fcommunication-calling%23CallAgent>代理。 请查看 CallAgentState

callAgent?: CallAgentState

属性值

calls

<xref:%40azure%2Fcommunication-calling%23CallAgent.calls>作为具有 CallState CallState 字段的 对象的代理。 它由 键 <xref:%40azure%2Fcommunication-calling%23Call.id>。 请注意,这可能会 <xref:%40azure%2Fcommunication-calling%23Call.id> 更改。 不应缓存 ID 本身,而应缓存整个 <xref:%40azure%2Fcommunication-calling%23Call> ID,然后使用包含的 ID 在此映射中查找数据。

calls: [key: string]: CallState

属性值

[key: string]: CallState

callsEnded

已结束的调用存储在此处,因此可以检查 callEndReason。 它是一个具有 <xref:%40azure%2Fcommunication-calling%23Call.id> 键和 CallState 值的对象。 只有 <xref:MAX_CALL_HISTORY_LENGTH> 调用保留在历史记录中。 如果需要,将逐出最早的调用。

callsEnded: [key: string]: CallState

属性值

[key: string]: CallState

deviceManager

的 <xref:%40azure%2Fcommunication-calling%23DeviceManager>代理。 请查看 DeviceManagerState

deviceManager: DeviceManagerState

属性值

incomingCalls

作为具有<xref:IncomingCall>字段的 <xref:%40azure%2Fcommunication-calling%23IncomingCall> 对象的代理。 它由 键 <xref:%40azure%2Fcommunication-calling%23IncomingCall.id>。

incomingCalls: [key: string]: IncomingCallState

属性值

[key: string]: IncomingCallState

incomingCallsEnded

已结束的传入呼叫存储在此处,因此可以检查 callEndReason。 它是作为具有 <xref:%40azure%2Fcommunication-calling%23Call.id> 键和 <xref:IncomingCall> 值的 对象。 只有 <xref:MAX_CALL_HISTORY_LENGTH> 调用保留在历史记录中。 如果需要,将逐出最早的调用。

incomingCallsEnded: [key: string]: IncomingCallState

属性值

[key: string]: IncomingCallState

latestErrors

存储每个 API 方法的最新错误。 有关详细信息,请参阅 {@Link CallErrors} 的文档。

latestErrors: CallErrors

属性值

userId

存储 userId。 这不由 使用 StatefulCallClient ,此处提供是为了方便开发人员访问 userId。 必须在 初始化 StatefulCallClient时传入 。 完全由开发人员控制。

userId: CommunicationIdentifierKind

属性值

CommunicationIdentifierKind