Share via


PageModel.PhysicalFile Yöntem

Tanım

Aşırı Yüklemeler

PhysicalFile(String, String)

() tarafından physicalPathStatus200OKbelirtilen ve İçerik Türü olarak belirtilen contentType dosyayı döndürür.

PhysicalFile(String, String, String)

() tarafından physicalPathStatus200OKbelirtilen ve content-Type olarak belirtilen contentType ve önerilen dosya adı olarak belirtilen fileDownloadName dosyayı döndürür.

PhysicalFile(String, String)

Kaynak:
PageModel.cs
Kaynak:
PageModel.cs

() tarafından physicalPathStatus200OKbelirtilen ve İçerik Türü olarak belirtilen contentType dosyayı döndürür.

public:
 virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType);
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType);
abstract member PhysicalFile : string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String) As PhysicalFileResult

Parametreler

physicalPath
String

Döndürülecek dosyanın fiziksel yolu.

contentType
String

Dosyanın İçerik Türü.

Döndürülenler

Yanıt için oluşturulan PhysicalFileResult .

Şunlara uygulanır

PhysicalFile(String, String, String)

Kaynak:
PageModel.cs
Kaynak:
PageModel.cs

() tarafından physicalPathStatus200OKbelirtilen ve content-Type olarak belirtilen contentType ve önerilen dosya adı olarak belirtilen fileDownloadName dosyayı döndürür.

public:
 virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, System::String ^ fileDownloadName);
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string fileDownloadName);
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string? fileDownloadName);
abstract member PhysicalFile : string * string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * string -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, fileDownloadName As String) As PhysicalFileResult

Parametreler

physicalPath
String

Döndürülecek dosyanın fiziksel yolu.

contentType
String

Dosyanın İçerik Türü.

fileDownloadName
String

Önerilen dosya adı.

Döndürülenler

Yanıt için oluşturulan PhysicalFileResult .

Şunlara uygulanır