Table of Contents

Enum ProtocolUriScheme

Namespace
Cuemon.AspNetCore.Razor.TagHelpers
Assembly
Cuemon.AspNetCore.Razor.TagHelpers.dll

Defines protocol URI schemes for static resource related operations.

public enum ProtocolUriScheme

Fields

Http = 2

Specifies that the URI scheme is Hypertext Transfer Protocol (HTTP).

Https = 3

Specifies that the URI scheme is Secure Hypertext Transfer Protocol (HTTPS).

None = 0

Specifies that the URI scheme is not defined.

Relative = 1

Specifies that the URI scheme is protocol-relative (//).

Examples

The following example demonstrates how to use the enum when configuring tag helper options.

using Cuemon.AspNetCore.Razor.TagHelpers;
using System;

namespace DocfxExamples;

public class ProtocolUriSchemeExample
{
    public void Demonstrate()
    {
        var options = new CdnTagHelperOptions
        {
            Scheme = ProtocolUriScheme.Https,
            BaseUrl = "cdn.example.com"
        };

        var formatted = options.GetFormattedBaseUrl();
        Console.WriteLine(formatted); // Output: https://cdn.example.com/

}
}