StaticFileExtensions.UseStaticFiles Metode
Definisi
Penting
Beberapa informasi terkait produk prarilis yang dapat diubah secara signifikan sebelum dirilis. Microsoft tidak memberikan jaminan, tersirat maupun tersurat, sehubungan dengan informasi yang diberikan di sini.
Overload
UseStaticFiles(IApplicationBuilder) |
Mengaktifkan penyajian file statis untuk jalur permintaan saat ini |
UseStaticFiles(IApplicationBuilder, StaticFileOptions) |
Mengaktifkan penyajian file statis dengan opsi yang diberikan |
UseStaticFiles(IApplicationBuilder, String) |
Mengaktifkan penyajian file statis untuk jalur permintaan yang diberikan |
UseStaticFiles(IApplicationBuilder)
- Sumber:
- StaticFileExtensions.cs
- Sumber:
- StaticFileExtensions.cs
- Sumber:
- StaticFileExtensions.cs
Mengaktifkan penyajian file statis untuk jalur permintaan saat ini
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
Parameter
Mengembalikan
Keterangan
File disajikan dari jalur yang ditentukan di WebRootPath atau WebRootFileProvider default ke subfolder 'wwwroot'.
Berlaku untuk
UseStaticFiles(IApplicationBuilder, StaticFileOptions)
- Sumber:
- StaticFileExtensions.cs
- Sumber:
- StaticFileExtensions.cs
- Sumber:
- StaticFileExtensions.cs
Mengaktifkan penyajian file statis dengan opsi yang diberikan
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
Parameter
- options
- StaticFileOptions
Mengembalikan
Berlaku untuk
UseStaticFiles(IApplicationBuilder, String)
- Sumber:
- StaticFileExtensions.cs
- Sumber:
- StaticFileExtensions.cs
- Sumber:
- StaticFileExtensions.cs
Mengaktifkan penyajian file statis untuk jalur permintaan yang diberikan
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
Parameter
- requestPath
- String
Jalur permintaan relatif.
Mengembalikan
Keterangan
File disajikan dari jalur yang ditentukan di WebRootPath atau WebRootFileProvider default ke subfolder 'wwwroot'.