Table of Contents

Class UriExtensions

Namespace
Sitecore.AspNetCore.SDK.LayoutService.Client.Extensions
Assembly
Sitecore.AspNetCore.SDK.LayoutService.Client.dll

Extension methods for Uri.

public static class UriExtensions
Inheritance
UriExtensions
Inherited Members

Methods

AddQueryString(Uri?, string, string)

Adds a query string to the Uri.

public static Uri? AddQueryString(this Uri? uri, string key, string value)

Parameters

uri Uri

The original Uri.

key string

The key to use.

value string

The value to use. This will be UrlEncoded.

Returns

Uri

New Uri with the query or the original if uri is null or key is null, empty or whitespace.