mirror of
https://github.com/wabbajack-tools/wabbajack.git
synced 2024-08-30 18:42:17 +00:00
23 lines
499 B
C#
23 lines
499 B
C#
|
using System;
|
|||
|
using System.Threading.Tasks;
|
|||
|
|
|||
|
namespace Wabbajack.Common
|
|||
|
{
|
|||
|
public class LogTime : IAsyncDisposable
|
|||
|
{
|
|||
|
private readonly string _message;
|
|||
|
private readonly DateTime _start;
|
|||
|
|
|||
|
public LogTime(string message)
|
|||
|
{
|
|||
|
_message = message;
|
|||
|
_start = DateTime.UtcNow;
|
|||
|
}
|
|||
|
|
|||
|
public async ValueTask DisposeAsync()
|
|||
|
{
|
|||
|
Utils.Log($"Log Time: {_message} {DateTime.UtcNow - _start}");
|
|||
|
}
|
|||
|
}
|
|||
|
}
|