ControllerBase.PhysicalFile Methode
Definition
Wichtig
Einige Informationen beziehen sich auf Vorabversionen, die vor dem Release ggf. grundlegend überarbeitet werden. Microsoft übernimmt hinsichtlich der hier bereitgestellten Informationen keine Gewährleistungen, seien sie ausdrücklich oder konkludent.
Überlädt
PhysicalFile(String, String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue, Boolean) |
Gibt die von |
PhysicalFile(String, String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue) |
Gibt die von |
PhysicalFile(String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue, Boolean) |
Gibt die von |
PhysicalFile(String, String, String, Boolean) |
Gibt die von |
PhysicalFile(String, String) |
Gibt die von |
PhysicalFile(String, String, String) |
Gibt die von |
PhysicalFile(String, String, Boolean) |
Gibt die von |
PhysicalFile(String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue) |
Gibt die von |
PhysicalFile(String, String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue, Boolean)
Gibt die von physicalPath
(Status200OK), als Inhaltstyp angegebene contentType
Datei und den als vorgeschlagenen Dateinamen angegebenen fileDownloadName
zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, System::String ^ fileDownloadName, Nullable<DateTimeOffset> lastModified, Microsoft::Net::Http::Headers::EntityTagHeaderValue ^ entityTag, bool enableRangeProcessing);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string fileDownloadName, DateTimeOffset? lastModified, Microsoft.Net.Http.Headers.EntityTagHeaderValue entityTag, bool enableRangeProcessing);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string? fileDownloadName, DateTimeOffset? lastModified, Microsoft.Net.Http.Headers.EntityTagHeaderValue entityTag, bool enableRangeProcessing);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PhysicalFile : string * string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, fileDownloadName As String, lastModified As Nullable(Of DateTimeOffset), entityTag As EntityTagHeaderValue, enableRangeProcessing As Boolean) As PhysicalFileResult
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- fileDownloadName
- String
Der vorgeschlagene Dateiname.
- lastModified
- Nullable<DateTimeOffset>
Der DateTimeOffset des Zeitpunkts, zu dem die Datei zuletzt geändert wurde.
- entityTag
- EntityTagHeaderValue
Die EntityTagHeaderValue der Datei zugeordnete.
- enableRangeProcessing
- Boolean
Legen Sie auf fest true
, um die Verarbeitung von Bereichsanforderungen zu aktivieren.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue)
Gibt die von physicalPath
(Status200OK), als Inhaltstyp angegebene contentType
Datei und den als vorgeschlagenen Dateinamen angegebenen fileDownloadName
zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, System::String ^ fileDownloadName, Nullable<DateTimeOffset> lastModified, Microsoft::Net::Http::Headers::EntityTagHeaderValue ^ entityTag);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string fileDownloadName, DateTimeOffset? lastModified, Microsoft.Net.Http.Headers.EntityTagHeaderValue entityTag);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string? fileDownloadName, DateTimeOffset? lastModified, Microsoft.Net.Http.Headers.EntityTagHeaderValue entityTag);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PhysicalFile : string * string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, fileDownloadName As String, lastModified As Nullable(Of DateTimeOffset), entityTag As EntityTagHeaderValue) As PhysicalFileResult
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- fileDownloadName
- String
Der vorgeschlagene Dateiname.
- lastModified
- Nullable<DateTimeOffset>
Der DateTimeOffset des Zeitpunkts, zu dem die Datei zuletzt geändert wurde.
- entityTag
- EntityTagHeaderValue
Die EntityTagHeaderValue der Datei zugeordnete.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue, Boolean)
Gibt die von physicalPath
(Status200OK) angegebene Datei und die als Inhaltstyp angegebene contentType
datei zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, Nullable<DateTimeOffset> lastModified, Microsoft::Net::Http::Headers::EntityTagHeaderValue ^ entityTag, bool enableRangeProcessing);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, DateTimeOffset? lastModified, Microsoft.Net.Http.Headers.EntityTagHeaderValue entityTag, bool enableRangeProcessing);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PhysicalFile : string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, lastModified As Nullable(Of DateTimeOffset), entityTag As EntityTagHeaderValue, enableRangeProcessing As Boolean) As PhysicalFileResult
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- lastModified
- Nullable<DateTimeOffset>
Der DateTimeOffset des Zeitpunkts, zu dem die Datei zuletzt geändert wurde.
- entityTag
- EntityTagHeaderValue
Die EntityTagHeaderValue der Datei zugeordnete.
- enableRangeProcessing
- Boolean
Legen Sie auf fest true
, um die Verarbeitung von Bereichsanforderungen zu aktivieren.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String, String, Boolean)
Gibt die von physicalPath
(Status200OK) angegebene Datei mit dem als Inhaltstyp und contentType
dem fileDownloadName
angegebenen als vorgeschlagenen Dateinamen zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, System::String ^ fileDownloadName, bool enableRangeProcessing);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string fileDownloadName, bool enableRangeProcessing);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string? fileDownloadName, bool enableRangeProcessing);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PhysicalFile : string * string * string * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * string * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, fileDownloadName As String, enableRangeProcessing As Boolean) As PhysicalFileResult
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- fileDownloadName
- String
Der vorgeschlagene Dateiname.
- enableRangeProcessing
- Boolean
Legen Sie auf fest true
, um die Verarbeitung von Bereichsanforderungen zu aktivieren.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String)
Gibt die von physicalPath
(Status200OK) angegebene Datei mit dem als Inhaltstyp angegebenen contentType
zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType);
[<Microsoft.AspNetCore.Mvc.NonAction>]
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
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String, String)
Gibt die von physicalPath
(Status200OK) angegebene Datei mit dem als Inhaltstyp und contentType
dem fileDownloadName
angegebenen als vorgeschlagenen Dateinamen zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, System::String ^ fileDownloadName);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string fileDownloadName);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, string? fileDownloadName);
[<Microsoft.AspNetCore.Mvc.NonAction>]
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
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- fileDownloadName
- String
Der vorgeschlagene Dateiname.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String, Boolean)
Gibt die von physicalPath
(Status200OK) angegebene Datei mit dem als Inhaltstyp angegebenen contentType
zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, bool enableRangeProcessing);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, bool enableRangeProcessing);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PhysicalFile : string * string * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * bool -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, enableRangeProcessing As Boolean) As PhysicalFileResult
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- enableRangeProcessing
- Boolean
Legen Sie auf fest true
, um die Verarbeitung von Bereichsanforderungen zu aktivieren.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
PhysicalFile(String, String, Nullable<DateTimeOffset>, EntityTagHeaderValue)
Gibt die von physicalPath
(Status200OK) angegebene Datei und die als Inhaltstyp angegebene contentType
datei zurück.
Dies unterstützt Bereichsanforderungen (Status206PartialContent oder Status416RangeNotSatisfiable , wenn der Bereich nicht zufriedenstellend ist).
public:
virtual Microsoft::AspNetCore::Mvc::PhysicalFileResult ^ PhysicalFile(System::String ^ physicalPath, System::String ^ contentType, Nullable<DateTimeOffset> lastModified, Microsoft::Net::Http::Headers::EntityTagHeaderValue ^ entityTag);
[Microsoft.AspNetCore.Mvc.NonAction]
public virtual Microsoft.AspNetCore.Mvc.PhysicalFileResult PhysicalFile (string physicalPath, string contentType, DateTimeOffset? lastModified, Microsoft.Net.Http.Headers.EntityTagHeaderValue entityTag);
[<Microsoft.AspNetCore.Mvc.NonAction>]
abstract member PhysicalFile : string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
override this.PhysicalFile : string * string * Nullable<DateTimeOffset> * Microsoft.Net.Http.Headers.EntityTagHeaderValue -> Microsoft.AspNetCore.Mvc.PhysicalFileResult
Public Overridable Function PhysicalFile (physicalPath As String, contentType As String, lastModified As Nullable(Of DateTimeOffset), entityTag As EntityTagHeaderValue) As PhysicalFileResult
Parameter
- physicalPath
- String
Der Pfad zur Datei. Der Pfad muss ein absoluter Pfad sein.
- contentType
- String
Der Inhaltstyp der Datei.
- lastModified
- Nullable<DateTimeOffset>
Der DateTimeOffset des Zeitpunkts, zu dem die Datei zuletzt geändert wurde.
- entityTag
- EntityTagHeaderValue
Die EntityTagHeaderValue der Datei zugeordnete.
Gibt zurück
Die für die Antwort erstellte PhysicalFileResult .
- Attribute
Gilt für:
Feedback
https://aka.ms/ContentUserFeedback.
Bald verfügbar: Im Laufe des Jahres 2024 werden wir GitHub-Issues stufenweise als Feedbackmechanismus für Inhalte abbauen und durch ein neues Feedbacksystem ersetzen. Weitere Informationen finden Sie unterFeedback senden und anzeigen für