using System.Net;
namespace adas_core.Domain.Exceptions;
///
/// Represents a business exception that is thrown when a requested user cannot be found.
///
///
/// Inherits from to signal user lookup failures within the business domain.
///
///
public class UserNotFoundException : BusinessException
{
///
/// Initializes a new instance of the class with a status code and a message identifying the missing .
///
/// The username of the user that could not be found.
///
public UserNotFoundException(string username) :
base(HttpStatusCode.NotFound, $"USER with username {username} not found")
{
}
///
/// Initializes a new instance of the class with the username that could not be found and a wrapped inner .
///
/// The username that was not found.
/// The inner that caused this exception to be raised.
///
public UserNotFoundException(string username, Exception exception) : base(
$"USER with username {username} not found", exception)
{
}
}