Condividi tramite


HealthMonitoringSection.HeartbeatInterval Proprietà

Definizione

Ottiene o imposta l'intervallo usato dal dominio dell'applicazione quando genera l'evento WebHeartbeatEvent.

public:
 property TimeSpan HeartbeatInterval { TimeSpan get(); void set(TimeSpan value); };
[System.ComponentModel.TypeConverter(typeof(System.Configuration.TimeSpanSecondsConverter))]
[System.Configuration.ConfigurationProperty("heartbeatInterval", DefaultValue="00:00:00")]
[System.Configuration.TimeSpanValidator(MaxValueString="24.20:31:23", MinValueString="00:00:00")]
public TimeSpan HeartbeatInterval { get; set; }
[<System.ComponentModel.TypeConverter(typeof(System.Configuration.TimeSpanSecondsConverter))>]
[<System.Configuration.ConfigurationProperty("heartbeatInterval", DefaultValue="00:00:00")>]
[<System.Configuration.TimeSpanValidator(MaxValueString="24.20:31:23", MinValueString="00:00:00")>]
member this.HeartbeatInterval : TimeSpan with get, set
Public Property HeartbeatInterval As TimeSpan

Valore della proprietà

TimeSpan

Intervallo usato dal dominio dell'applicazione quando genera l'evento WebHeartbeatEvent.

Attributi

Esempio

Nell'esempio di codice riportato di seguito viene illustrato come utilizzare la proprietà HeartbeatInterval. Questo esempio di codice fa parte di un esempio più grande fornito per la HealthMonitoringSection classe.


// Get the current HeartBeatInterval property value.
TimeSpan heartBeatIntervalValue = healthMonitoringSection.HeartbeatInterval;

// Set the HeartBeatInterval property to
// TimeSpan.Parse("00:10:00").
healthMonitoringSection.HeartbeatInterval = TimeSpan.Parse("00:10:00");

' Get the current HeartBeatInterval property value.
Dim heartBeatIntervalValue As TimeSpan = healthMonitoringSection.HeartbeatInterval

' Set the HeartBeatInterval property to
' TimeSpan.Parse("00:10:00").
healthMonitoringSection.HeartbeatInterval = TimeSpan.Parse("00:10:00")

Commenti

Se il TimeSpan valore è zero tick, non WebHeartbeatEvent viene generato alcun evento.

Si applica a