Class RouteMatch
- Namespace
- Yarp.ReverseProxy.Configuration
- Assembly
- Yarp.ReverseProxy.dll
Describes the matching criteria for a route.
public sealed record RouteMatch : IEquatable<RouteMatch>
- Inheritance
-
RouteMatch
- Implements
- Inherited Members
Constructors
RouteMatch()
public RouteMatch()
Properties
Headers
Only match requests that contain all of these headers.
public IReadOnlyList<RouteHeader>? Headers { get; init; }
Property Value
Hosts
Only match requests with the given Host header. Supports wildcards and ports. For unicode host names, do not use punycode.
public IReadOnlyList<string>? Hosts { get; init; }
Property Value
Methods
Only match requests that use these optional HTTP methods. E.g. GET, POST.
public IReadOnlyList<string>? Methods { get; init; }
Property Value
Path
Only match requests with the given Path pattern.
public string? Path { get; init; }
Property Value
QueryParameters
Only match requests that contain all of these query parameters.
public IReadOnlyList<RouteQueryParameter>? QueryParameters { get; init; }
Property Value
Methods
Equals(object?)
public override bool Equals(object? obj)
Parameters
obj
object
Returns
Equals(RouteMatch?)
public bool Equals(RouteMatch? other)
Parameters
other
RouteMatch
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
<Clone>$()
public RouteMatch <Clone>$()
Returns
Operators
operator ==(RouteMatch?, RouteMatch?)
public static bool operator ==(RouteMatch? left, RouteMatch? right)
Parameters
left
RouteMatchright
RouteMatch
Returns
operator !=(RouteMatch?, RouteMatch?)
public static bool operator !=(RouteMatch? left, RouteMatch? right)
Parameters
left
RouteMatchright
RouteMatch