Table of Contents

Class PathTransformExtensions

Namespace
Yarp.ReverseProxy.Transforms
Assembly
Yarp.ReverseProxy.dll

Extensions for adding path transforms.

public static class PathTransformExtensions
Inheritance
PathTransformExtensions
Inherited Members

Methods

AddPathPrefix(TransformBuilderContext, PathString)

Adds the transform which will prefix the request path with the given value.

public static TransformBuilderContext AddPathPrefix(this TransformBuilderContext context, PathString prefix)

Parameters

context TransformBuilderContext
prefix PathString

Returns

TransformBuilderContext

AddPathRemovePrefix(TransformBuilderContext, PathString)

Adds the transform which will remove the matching prefix from the request path.

public static TransformBuilderContext AddPathRemovePrefix(this TransformBuilderContext context, PathString prefix)

Parameters

context TransformBuilderContext
prefix PathString

Returns

TransformBuilderContext

AddPathRouteValues(TransformBuilderContext, PathString)

Clones the route and adds the transform which will set the request path with the given value.

public static TransformBuilderContext AddPathRouteValues(this TransformBuilderContext context, PathString pattern)

Parameters

context TransformBuilderContext
pattern PathString

Returns

TransformBuilderContext

AddPathSet(TransformBuilderContext, PathString)

Adds the transform which sets the request path with the given value.

public static TransformBuilderContext AddPathSet(this TransformBuilderContext context, PathString path)

Parameters

context TransformBuilderContext
path PathString

Returns

TransformBuilderContext

WithTransformPathPrefix(RouteConfig, PathString)

Clones the route and adds the transform which will prefix the request path with the given value.

public static RouteConfig WithTransformPathPrefix(this RouteConfig route, PathString prefix)

Parameters

route RouteConfig
prefix PathString

Returns

RouteConfig

WithTransformPathRemovePrefix(RouteConfig, PathString)

Clones the route and adds the transform which will remove the matching prefix from the request path.

public static RouteConfig WithTransformPathRemovePrefix(this RouteConfig route, PathString prefix)

Parameters

route RouteConfig
prefix PathString

Returns

RouteConfig

WithTransformPathRouteValues(RouteConfig, PathString)

Clones the route and adds the transform which will set the request path with the given value.

public static RouteConfig WithTransformPathRouteValues(this RouteConfig route, PathString pattern)

Parameters

route RouteConfig
pattern PathString

Returns

RouteConfig

WithTransformPathSet(RouteConfig, PathString)

Clones the route and adds the transform which sets the request path with the given value.

public static RouteConfig WithTransformPathSet(this RouteConfig route, PathString path)

Parameters

route RouteConfig
path PathString

Returns

RouteConfig