GlobbingUrlBuilder Class

Summary

Utility methods for @!:ITagHelper-‘s that support attributes containing file globbing patterns.

Syntax

public class GlobbingUrlBuilder

GitHub

View on GitHub

class Microsoft.AspNet.Mvc.TagHelpers.Internal.GlobbingUrlBuilder

Constructors

GlobbingUrlBuilder(IFileProvider, IMemoryCache, PathString)

Creates a new [Microsoft.AspNet.Mvc.TagHelpers.Internal.GlobbingUrlBuilder](Microsoft.AspNet.Mvc.TagHelpers.Internal.GlobbingUrlBuilder.yml).

Arguments:
  • fileProvider (IFileProvider) – The file provider.
  • cache (IMemoryCache) – The cache.
  • requestPathBase (PathString) – The request path base.
public GlobbingUrlBuilder(IFileProvider fileProvider, IMemoryCache cache, PathString requestPathBase)

Properties

Cache()

The @!:IMemoryCache- to cache globbing results in.

Return type:IMemoryCache
public IMemoryCache Cache { get; }
FileProvider()

The @!:IFileProvider- used to watch for changes to file globbing results.

Return type:IFileProvider
public IFileProvider FileProvider { get; }
RequestPathBase()

The base path of the current request (i.e. @!:HttpRequest.PathBase-).

Return type:PathString
public PathString RequestPathBase { get; }

Methods

BuildUrlList(System.String, System.String, System.String)

Builds a list of URLs.

Arguments:
  • staticUrl (System.String) – The statically declared URL. This will always be added to the result.
  • includePattern (System.String) – The file globbing include pattern.
  • excludePattern (System.String) – The file globbing exclude pattern.
Return type:

System.Collections.Generic.IEnumerable{System.String}

Returns:

The list of URLs

public virtual IEnumerable<string> BuildUrlList(string staticUrl, string includePattern, string excludePattern)