Compartir a través de


StaticFileExtensions.UseStaticFiles Método

Definición

Sobrecargas

UseStaticFiles(IApplicationBuilder)

Habilita el servicio de archivos estáticos para la ruta de acceso de solicitud actual.

UseStaticFiles(IApplicationBuilder, StaticFileOptions)

Habilita el envío de archivos estáticos con las opciones dadas

UseStaticFiles(IApplicationBuilder, String)

Habilita el servicio de archivos estáticos para la ruta de acceso de solicitud especificada.

UseStaticFiles(IApplicationBuilder)

Source:
StaticFileExtensions.cs
Source:
StaticFileExtensions.cs
Source:
StaticFileExtensions.cs

Habilita el servicio de archivos estáticos para la ruta de acceso de solicitud actual.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Builder::IApplicationBuilder ^ UseStaticFiles(Microsoft::AspNetCore::Builder::IApplicationBuilder ^ app);
public static Microsoft.AspNetCore.Builder.IApplicationBuilder UseStaticFiles (this Microsoft.AspNetCore.Builder.IApplicationBuilder app);
static member UseStaticFiles : Microsoft.AspNetCore.Builder.IApplicationBuilder -> Microsoft.AspNetCore.Builder.IApplicationBuilder
<Extension()>
Public Function UseStaticFiles (app As IApplicationBuilder) As IApplicationBuilder

Parámetros

Devoluciones

Comentarios

Los archivos se sirven desde la ruta de acceso especificada en WebRootPath o WebRootFileProvider en la subcarpeta "wwwroot".

Se aplica a

UseStaticFiles(IApplicationBuilder, StaticFileOptions)

Source:
StaticFileExtensions.cs
Source:
StaticFileExtensions.cs
Source:
StaticFileExtensions.cs

Habilita el envío de archivos estáticos con las opciones dadas

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Builder::IApplicationBuilder ^ UseStaticFiles(Microsoft::AspNetCore::Builder::IApplicationBuilder ^ app, Microsoft::AspNetCore::Builder::StaticFileOptions ^ options);
public static Microsoft.AspNetCore.Builder.IApplicationBuilder UseStaticFiles (this Microsoft.AspNetCore.Builder.IApplicationBuilder app, Microsoft.AspNetCore.Builder.StaticFileOptions options);
static member UseStaticFiles : Microsoft.AspNetCore.Builder.IApplicationBuilder * Microsoft.AspNetCore.Builder.StaticFileOptions -> Microsoft.AspNetCore.Builder.IApplicationBuilder
<Extension()>
Public Function UseStaticFiles (app As IApplicationBuilder, options As StaticFileOptions) As IApplicationBuilder

Parámetros

Devoluciones

Se aplica a

UseStaticFiles(IApplicationBuilder, String)

Source:
StaticFileExtensions.cs
Source:
StaticFileExtensions.cs
Source:
StaticFileExtensions.cs

Habilita el servicio de archivos estáticos para la ruta de acceso de solicitud especificada.

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Builder::IApplicationBuilder ^ UseStaticFiles(Microsoft::AspNetCore::Builder::IApplicationBuilder ^ app, System::String ^ requestPath);
public static Microsoft.AspNetCore.Builder.IApplicationBuilder UseStaticFiles (this Microsoft.AspNetCore.Builder.IApplicationBuilder app, string requestPath);
static member UseStaticFiles : Microsoft.AspNetCore.Builder.IApplicationBuilder * string -> Microsoft.AspNetCore.Builder.IApplicationBuilder
<Extension()>
Public Function UseStaticFiles (app As IApplicationBuilder, requestPath As String) As IApplicationBuilder

Parámetros

requestPath
String

Ruta de acceso de solicitud relativa.

Devoluciones

Comentarios

Los archivos se sirven desde la ruta de acceso especificada en WebRootPath o WebRootFileProvider en la subcarpeta "wwwroot".

Se aplica a