Show / Hide Table of Contents

Class TraceTarget

Represents the location traces will be sent to. The Trace API only supports projects.

Inheritance
System.Object
TraceTarget
Inherited Members
System.Object.ToString()
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Google.Cloud.Diagnostics.Common
Assembly: Google.Cloud.Diagnostics.Common.dll
Syntax
public sealed class TraceTarget

Properties

ProjectId

The Google Cloud Platform project Id.

Declaration
public string ProjectId { get; }
Property Value
Type Description
System.String

Methods

ForProject(String)

Creates a TraceTarget instance for sending trace entries to a GCP project.

Declaration
public static TraceTarget ForProject(string projectId)
Parameters
Type Name Description
System.String projectId
Returns
Type Description
TraceTarget

GetFullTraceName(String)

Gets the full trace name. See: https://cloud.google.com/logging/docs/reference/v2/rest/v2/LogEntry

Declaration
public string GetFullTraceName(string traceId)
Parameters
Type Name Description
System.String traceId

The id of the trace.

Returns
Type Description
System.String
Back to top