public SendPulseTimingEvent ( RaygunPulseEventType eventType, string name, long milliseconds ) : void | ||
eventType | RaygunPulseEventType | The type of event that occurred. |
name | string | The name of the event resource such as the view name or URL of a network call. |
milliseconds | long | The duration of the event in milliseconds. |
Результат | void |
public void SendPulseTimingEvent(RaygunPulseEventType eventType, string name, long milliseconds)
{
if (_activeBatch == null) {
_activeBatch = new PulseEventBatch (this);
}
if (_activeBatch != null && !_activeBatch.IsLocked) {
if (_sessionId == null) {
SendPulseSessionEvent (RaygunPulseSessionEventType.SessionStart);
}
PendingEvent pendingEvent = new PendingEvent (eventType, name, milliseconds, _sessionId);
_activeBatch.Add (pendingEvent);
} else {
ThreadPool.QueueUserWorkItem (c => SendPulseTimingEventCore (eventType, name, milliseconds));
}
}
private static void OnDidBecomeActive(NSNotification notification) { //Console.WriteLine("SESSION START"); _raygunClient.SendPulseSessionEvent(RaygunPulseSessionEventType.SessionStart); if (_lastViewName != null) { _raygunClient.SendPulseTimingEvent(RaygunPulseEventType.ViewLoaded, _lastViewName, 0); } }