Table of Contents

Class ForegroundOnlyStopwatchSource

Namespace
Homa.Sdk.Foundation
Assembly
Homa.Sdk.Foundation.dll

This observes unity focus state, to not include time the app spends in the background in metrics.

public class ForegroundOnlyStopwatchSource : IStopwatchSource
Inheritance
ForegroundOnlyStopwatchSource
Implements
Inherited Members

Fields

SharedInstance

Shared instance allows for sharing stopwatch references using names between multiple domains without passing references directly.

public static ForegroundOnlyStopwatchSource SharedInstance

Field Value

ForegroundOnlyStopwatchSource

Methods

Create()

Create a new local stopwatch without starting.

public IStopwatch Create()

Returns

IStopwatch

Get(string)

Retrieve a named stopwatch if it exists.

public IStopwatch Get(string name)

Parameters

name string

Name used in Start(string) to start the stopwatch.

Returns

IStopwatch

Start(string)

Start a named stopwatch. If one with a given name exists, restarts it.

public IStopwatch Start(string name)

Parameters

name string

Name to identify the stopwatch

Returns

IStopwatch

StartNew()

Start a new local stopwatch.

public IStopwatch StartNew()

Returns

IStopwatch