C# 클래스 Affecto.WebApi.Toolkit.Responses.FileResult

Http action result for returning files in a way browsers will recognize (and prompt user for open/download)
상속: IHttpActionResult
파일 보기 프로젝트 열기: affecto/dotnet-WebApi.Toolkit

공개 메소드들

메소드 설명
ExecuteAsync ( CancellationToken cancellationToken ) : Task

Creates an T:System.Net.Http.HttpResponseMessage asynchronously.

FileResult ( Stream content, string filename ) : System.IO

Initializes new FileResult. Tries to parse mime content type from filename.

FileResult ( Stream content, string filename, string contentType ) : System.IO

Initializes new FileResult

메소드 상세

ExecuteAsync() 공개 메소드

Creates an T:System.Net.Http.HttpResponseMessage asynchronously.
public ExecuteAsync ( CancellationToken cancellationToken ) : Task
cancellationToken System.Threading.CancellationToken The token to monitor for cancellation requests.
리턴 Task

FileResult() 공개 메소드

Initializes new FileResult. Tries to parse mime content type from filename.
public FileResult ( Stream content, string filename ) : System.IO
content System.IO.Stream File content
filename string File name, should include extension for mime mapping to work.
리턴 System.IO

FileResult() 공개 메소드

Initializes new FileResult
public FileResult ( Stream content, string filename, string contentType ) : System.IO
content System.IO.Stream File content
filename string File name
contentType string Mime content type for file
리턴 System.IO