Table of Contents

Class QueryStringExtensions

Namespace
MassTransit.Internals
Assembly
MassTransit.Abstractions.dll
public static class QueryStringExtensions
Inheritance
QueryStringExtensions
Inherited Members

Methods

GetValueFromQueryString<T>(Uri, string, T)

public static T GetValueFromQueryString<T>(this Uri uri, string key, T defaultValue) where T : struct

Parameters

uri Uri
key string
defaultValue T

Returns

T

Type Parameters

T

ParseHostPath(Uri)

Parse the host path, which on a host address might be a virtual host, a scope, etc.

public static string ParseHostPath(this Uri address)

Parameters

address Uri

Returns

string

ParseHostPathAndEntityName(Uri, out string?, out string?)

Parse the host path and entity name from the address

public static void ParseHostPathAndEntityName(this Uri address, out string? hostPath, out string? entityName)

Parameters

address Uri
hostPath string
entityName string

SplitQueryString(Uri)

Split the query string into an enumerable stream of tuples

public static IEnumerable<(string, string?)> SplitQueryString(this Uri address)

Parameters

address Uri

Returns

IEnumerable<(string, string)>

TryGetValueFromQueryString(Uri, string, out string?)

public static bool TryGetValueFromQueryString(this Uri uri, string key, out string? value)

Parameters

uri Uri
key string
value string

Returns

bool