AyCode.Core/AyCode.Utils/Extensions/README.md

833 B

Extensions

String, DateTime, and lock utility extensions.

Key Files

  • StringExtensions.csIsNullOrEmpty(), IsNullOrWhiteSpace() (with [NotNullWhen]), FirstLetterToUpper(), MixCharacters() (interleaves two char sequences: ABC+DEF→ADBECF).
  • DateTimeExtension.csIsNullOrEmpty() for DateTime/DateTime?, IsEqualSqlDateTime2() for SQL Server datetime2 precision comparison.
  • LockExtensions.csusing pattern for locks: mutex.UseWaitOne(), semaphore.UseWait(), semaphore.UseWaitAsync(). Returns IDisposable wrappers that auto-release on dispose.

LLM Maintenance: If you modify code in this folder, update this README to reflect the changes. If you notice the README content does not match the current code, automatically update the README to match the code.