You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Connected.Framework/Connected.Services/Authorization/ServiceAuthorizationResult.cs

22 lines
512 B

namespace Connected.Services.Authorization
{
public class ServiceAuthorizationResult
{
public ServiceAuthorizationResult()
{
Message = SR.PolicyAuthorizationFailed;
}
public ServiceAuthorizationResult(string message)
{
Message = message;
}
public string Message { get; set; }
public static ServiceAuthorizationResult Default(Attribute sender, object policy)
{
return new ServiceAuthorizationResult($"{SR.PolicyAuthorizationFailed} ({sender.GetType().Name}.{policy})");
}
}
}