microsoft/healthcare-shared-components
Publicmirrored from https://github.com/microsoft/healthcare-shared-componentsAvailable
src/Microsoft.Health.Core/ActionTimerExtensions.cs
18lines · modecode
| 1 | // ------------------------------------------------------------------------------------------------- |
| 2 | // Copyright (c) Microsoft Corporation. All rights reserved. |
| 3 | // Licensed under the MIT License (MIT). See LICENSE in the repo root for license information. |
| 4 | // ------------------------------------------------------------------------------------------------- |
| 5 | |
| 6 | using System; |
| 7 | using Microsoft.Extensions.Logging; |
| 8 | |
| 9 | namespace Microsoft.Health.Core |
| 10 | { |
| 11 | public static class ActionTimerExtensions |
| 12 | { |
| 13 | public static IDisposable BeginTimedScope(this ILogger logger, string scopeName) |
| 14 | { |
| 15 | return new ActionTimer(logger, scopeName); |
| 16 | } |
| 17 | } |
| 18 | } |