共用方式為


TelemetryContext 類別

定義

表示將遙測傳送至 Application Insights 服務的內容。

public ref class TelemetryContext sealed : Microsoft::VisualStudio::ApplicationInsights::DataContracts::IJsonSerializable
public sealed class TelemetryContext : Microsoft.VisualStudio.ApplicationInsights.DataContracts.IJsonSerializable
type TelemetryContext = class
    interface IJsonSerializable
Public NotInheritable Class TelemetryContext
Implements IJsonSerializable
繼承
TelemetryContext
實作

建構函式

TelemetryContext()

初始化 TelemetryContext 類別的新執行個體。

屬性

Component

取得 物件,描述這個 TelemetryContext所追蹤的元件。

Device

取得物件,描述這個 TelemetryContext所追蹤的裝置。

InstrumentationKey

取得或設定這個 TelemetryContext中所記錄之所有ITelemetry物件的預設檢測金鑰。

Location

取得 物件,描述這個 TelemetryContext所追蹤的位置。

Operation

取得 物件,描述這個 TelemetryContext所追蹤的作業。

Properties

取得應用程式定義屬性值的字典。

Session

取得物件,描述這個 TelemetryContext所追蹤的用戶會話。

User

取得物件,描述這個 TelemetryContext所追蹤的使用者。

明確介面實作

IJsonSerializable.Serialize(IJsonWriter)

以 JSON 格式串行化此物件。 這是 Common Schema 2.0 數據流所使用的。 一般架構 4 不會使用標記,並在 TelemetryHelper:WriteEnvelopeProperties 中寫入 iKey,因為它使用不同的格式

擴充方法

GetInternalContext(TelemetryContext)

會傳回 TelemetryContext 的內部內容。

適用於