Skip to content

Instantly share code, notes, and snippets.

View costr's full-sized avatar
📈

Adam Costenbader costr

📈
View GitHub Profile
@costr
costr / ExecutionTimeLogger.cs
Last active July 8, 2021 21:02
Execution time logging in C# with usings
using System;
using System.Diagnostics;
namespace Tools.Debugging
{
public class ExecutionTimeLogger : IDisposable
{
private readonly Stopwatch watch;
private readonly string _titleForWhatIsBeingTracked;
private readonly string _callingMethodName;
@osmyn
osmyn / FileHelper.cs
Last active January 4, 2019 21:12
File utilities
using BusinessLogic.Utilities.Interfaces;
using System;
using System.Collections.Generic;
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using BusinessLogic.Logging;
myDBContext.Database.Log = message => System.Diagnostics.Debug.WriteLine(message);