mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-08-11 21:52:11 +00:00
26 lines
621 B
C#
26 lines
621 B
C#
namespace AIStudio.Tools.Web;
|
|
|
|
public enum WebPageAccessBlockReason
|
|
{
|
|
UNSPECIFIED,
|
|
UNSUPPORTED_SCHEME,
|
|
LOCAL_HOST_NAME,
|
|
NEVER_ALLOWED_ADDRESS,
|
|
PRIVATE_HOST_NOT_ALLOWED,
|
|
INSUFFICIENT_PROVIDER_CONFIDENCE,
|
|
}
|
|
|
|
public sealed class WebPageAccessBlockedException : Exception
|
|
{
|
|
public WebPageAccessBlockedException(string message) : this(message, WebPageAccessBlockReason.UNSPECIFIED)
|
|
{
|
|
}
|
|
|
|
public WebPageAccessBlockedException(string message, WebPageAccessBlockReason reason) : base(message)
|
|
{
|
|
this.Reason = reason;
|
|
}
|
|
|
|
public WebPageAccessBlockReason Reason { get; }
|
|
}
|