DiagnosticSource.StartActivity(Activity, Object) Método

Definición

Inicia Activity y escribe un evento de inicio.Starts an Activity and writes a start event.

public:
 System::Diagnostics::Activity ^ StartActivity(System::Diagnostics::Activity ^ activity, System::Object ^ args);
public System.Diagnostics.Activity StartActivity (System.Diagnostics.Activity activity, object? args);
public System.Diagnostics.Activity StartActivity (System.Diagnostics.Activity activity, object args);
member this.StartActivity : System.Diagnostics.Activity * obj -> System.Diagnostics.Activity
Public Function StartActivity (activity As Activity, args As Object) As Activity

Parámetros

activity
Activity

Activity que se va a iniciar.The Activity to be started.

args
Object

Objeto que representa el valor que se va a pasar como una carga para el evento.An object that represent the value being passed as a payload for the event.

Devoluciones

Activity

Actividad iniciada para un encadenamiento práctico.The started activity for convenient chaining.

Comentarios

ActivityDescribe la operación lógica, su contexto y la relación primaria; el flujo actual Activity atraviesa el procesamiento de la operación.The Activity describes the logical operation, its context, and parent relation; the current Activity flows through the operation processing.

Este método inicia el determinado Activity , mantiene una Activity.Current actividad global y Activity.Parent para el determinado Activity y notifica a los consumidores que se ha Activity iniciado un nuevo.This method starts the given Activity, maintains a global Activity.Current and Activity.Parent activity for the given Activity, and notifies consumers that a new Activity was started. Los consumidores pueden tener acceso Activity.Current para agregar y aumentar la telemetría.Consumers can access Activity.Current to add context and/or augment telemetry.

Los productores pueden pasar detalles adicionales al consumidor en la carga.Producers may pass additional details to the consumer in the payload.

Se aplica a