Table of Contents

Class Watch

Namespace
Ecng.Common
Assembly
Ecng.Common.dll

Provides utility methods for timing the execution of code.

public static class Watch
Inheritance
Watch
Inherited Members

Methods

Do(Action)

Executes the specified action, measures its execution time, and returns the elapsed time.

public static TimeSpan Do(Action action)

Parameters

action Action

The action to execute.

Returns

TimeSpan

A TimeSpan representing the elapsed time during the execution of the action.