Condividi tramite


Classe TraceReplay

The TraceReplay object is a Replay object that represents the replay operation for trace log files and trace tables.

Gerarchia di ereditarietà

System.Object
  Microsoft.SqlServer.Management.Trace.TraceReplay

Spazio dei nomi  Microsoft.SqlServer.Management.Trace
Assembly:  Microsoft.SqlServer.ConnectionInfoExtended (in Microsoft.SqlServer.ConnectionInfoExtended.dll)

Sintassi

'Dichiarazione
<ComVisibleAttribute(False)> _
Public Class TraceReplay _
    Implements IDisposable
'Utilizzo
Dim instance As TraceReplay
[ComVisibleAttribute(false)]
public class TraceReplay : IDisposable
[ComVisibleAttribute(false)]
public ref class TraceReplay : IDisposable
[<ComVisibleAttribute(false)>]
type TraceReplay =  
    class 
        interface IDisposable 
    end
public class TraceReplay implements IDisposable

Nel tipo TraceReplay sono esposti i membri seguenti.

Costruttori

  Nome Descrizione
Metodo pubblico TraceReplay Initializes a new instance of the TraceReplay class.

In alto

Proprietà

  Nome Descrizione
Proprietà pubblica Connection Gets or sets the connection with an instance of SQL Server.
Proprietà pubblica Options Gets or sets the configuration options for replaying the trace.
Proprietà pubblica OutputFile Gets or sets the name of an optional file to which trace replay output is streamed.
Proprietà pubblica OutputTable Gets or sets the name of an optional table to which trace replay output is streamed.
Proprietà pubblica Source Gets or sets the TraceReader object that contains the trace to be replayed.

In alto

Metodi

  Nome Descrizione
Metodo pubblico Dispose Deletes the trace information.
Metodo pubblico Equals Ereditato da Object.
Metodo protetto Finalize Completes the trace replay. Esegue l'override di Object.Finalize().
Metodo pubblico GetHashCode Ereditato da Object.
Metodo pubblico GetType Ereditato da Object.
Metodo protetto MemberwiseClone Ereditato da Object.
Metodo pubblico Pause Pauses the trace replay.
Metodo pubblico Start Starts the trace replay.
Metodo pubblico Stop Stops the trace replay.
Metodo pubblico ToString Ereditato da Object.

In alto

Eventi

  Nome Descrizione
Evento pubblico ReplayEvent Invokes the handler before an event is replayed.
Evento pubblico ReplayPause Invokes the handler before a replayed trace is paused.
Evento pubblico ReplayResultEvent Invokes the handler before a result is returned from a replayed event.
Evento pubblico ReplayStart Invokes the handler before a replayed trace is started.
Evento pubblico ReplayStop Invokes the handler before a replayed trace is stopped.

In alto

Osservazioni

With the TraceReplay object you can:

  • Replay events a from a trace log file or trace table.

  • Modify trace data as it is replayed.

In addition to the Trace and Replay objects, the trace log file can be accessed manually with Guida di riferimento a SQL Server Profiler or using a set of Transact-SQL stored procedures called Introduzione a Traccia SQL.

Thread Safety

Tutti i membri statici pubblici (Shared in Microsoft Visual Basic) di questo tipo sono sicuri per le operazioni a thread multipli. Non è invece garantita la sicurezza dei membri dell'istanza.

Esempi

Readme_Tracer

Protezione dei thread

I membri static (Shared in Visual Basic) pubblici di questo tipo sono affidabili. Non è invece garantita la sicurezza dei membri dell'istanza.

Vedere anche

Riferimento

Spazio dei nomi Microsoft.SqlServer.Management.Trace

Altre risorse

Flag di traccia (Transact-SQL)

Modelli e autorizzazioni di SQL Server Profiler