rama creada apartir de master en j

This commit is contained in:
jrojas
2026-06-26 10:29:23 +02:00
parent 319fd3dfb0
commit c1517fda87
2810 changed files with 1927392 additions and 25392 deletions
+14 -4
View File
@@ -2,6 +2,12 @@
namespace adas_core.Domain.Utils;
/// <summary>
/// Provides a set of static utility methods for authentication-related operations.
/// </summary>
/// <remarks>
/// This class is sealed and cannot be inherited.
/// </remarks>
public sealed class AuthUtils
{
private LoginResponse _loginResponse = new();
@@ -37,11 +43,15 @@ public sealed class AuthUtils
private static AuthUtils InternalInstance { get; set; }
public static AuthUtils Instance => InternalInstance;
/// <summary>
/// Retrieves the current <see cref="LoginResponse"/> in a thread-safe manner by acquiring a lock on the underlying field.
/// </summary>
/// <returns>The current <see cref="LoginResponse"/> instance.</returns>
public LoginResponse GetLoginResponse()
{
lock (_loginResponse)
{
return _loginResponse;
lock (_loginResponse)
{
return _loginResponse;
}
}
}
}