C# 클래스 ServiceStack.HttpResponseExtensionsInternal

파일 보기 프로젝트 열기: ServiceStack/ServiceStack 1 사용 예제들

공개 메소드들

메소드 설명
ApplyGlobalResponseHeaders ( this httpRes ) : void
ShouldWriteGlobalHeaders ( IResponse httpRes ) : bool
WriteBytesToResponse ( this res, byte responseBytes, string contentType ) : void
WriteError ( this httpRes, Exception ex, int statusCode = 500, string errorMessage = null, string contentType = null ) : System.Threading.Tasks.Task
WriteError ( this httpRes, IRequest httpReq, object dto, string errorMessage ) : void
WriteError ( this httpRes, object dto, string errorMessage ) : void
WriteErrorBody ( this httpRes, Exception ex ) : System.Threading.Tasks.Task

When HTTP Headers have already been written and only the Body can be written

WriteErrorToResponse ( this httpRes, IRequest httpReq, string contentType, string operationName, string errorMessage, Exception ex, int statusCode ) : System.Threading.Tasks.Task
WriteToOutputStream ( IResponse response, object result, byte bodyPrefix, byte bodySuffix ) : bool
WriteToResponse ( this httpRes, IRequest httpReq, object result ) : Task
WriteToResponse ( this httpRes, IRequest httpReq, object result, byte bodyPrefix, byte bodySuffix ) : Task
WriteToResponse ( this httpRes, object result, ResponseSerializerDelegate serializer, IRequest serializationContext ) : Task
WriteToResponse ( this response, object result, ResponseSerializerDelegate defaultAction, IRequest request, byte bodyPrefix, byte bodySuffix ) : Task

Writes to response. Response headers are customizable by implementing IHasOptions an returning Dictionary of Http headers.

WriteToResponse ( this httpRes, object result, string contentType ) : Task

비공개 메소드들

메소드 설명
HandleCustomErrorHandler ( this httpRes, IRequest httpReq, string contentType, int statusCode, object errorDto ) : bool
HandleResponseWriteException ( this originalEx, IRequest request, IResponse response, string defaultContentType ) : Task
ToErrorResponse ( this ex ) : ServiceStack.ErrorResponse

메소드 상세

ApplyGlobalResponseHeaders() 공개 정적인 메소드

public static ApplyGlobalResponseHeaders ( this httpRes ) : void
httpRes this
리턴 void

ShouldWriteGlobalHeaders() 공개 정적인 메소드

public static ShouldWriteGlobalHeaders ( IResponse httpRes ) : bool
httpRes IResponse
리턴 bool

WriteBytesToResponse() 공개 정적인 메소드

public static WriteBytesToResponse ( this res, byte responseBytes, string contentType ) : void
res this
responseBytes byte
contentType string
리턴 void

WriteError() 공개 정적인 메소드

public static WriteError ( this httpRes, Exception ex, int statusCode = 500, string errorMessage = null, string contentType = null ) : System.Threading.Tasks.Task
httpRes this
ex System.Exception
statusCode int
errorMessage string
contentType string
리턴 System.Threading.Tasks.Task

WriteError() 공개 정적인 메소드

public static WriteError ( this httpRes, IRequest httpReq, object dto, string errorMessage ) : void
httpRes this
httpReq IRequest
dto object
errorMessage string
리턴 void

WriteError() 공개 정적인 메소드

public static WriteError ( this httpRes, object dto, string errorMessage ) : void
httpRes this
dto object
errorMessage string
리턴 void

WriteErrorBody() 공개 정적인 메소드

When HTTP Headers have already been written and only the Body can be written
public static WriteErrorBody ( this httpRes, Exception ex ) : System.Threading.Tasks.Task
httpRes this
ex System.Exception
리턴 System.Threading.Tasks.Task

WriteErrorToResponse() 공개 정적인 메소드

public static WriteErrorToResponse ( this httpRes, IRequest httpReq, string contentType, string operationName, string errorMessage, Exception ex, int statusCode ) : System.Threading.Tasks.Task
httpRes this
httpReq IRequest
contentType string
operationName string
errorMessage string
ex System.Exception
statusCode int
리턴 System.Threading.Tasks.Task

WriteToOutputStream() 공개 정적인 메소드

public static WriteToOutputStream ( IResponse response, object result, byte bodyPrefix, byte bodySuffix ) : bool
response IResponse
result object
bodyPrefix byte
bodySuffix byte
리턴 bool

WriteToResponse() 공개 정적인 메소드

public static WriteToResponse ( this httpRes, IRequest httpReq, object result ) : Task
httpRes this
httpReq IRequest
result object
리턴 Task

WriteToResponse() 공개 정적인 메소드

public static WriteToResponse ( this httpRes, IRequest httpReq, object result, byte bodyPrefix, byte bodySuffix ) : Task
httpRes this
httpReq IRequest
result object
bodyPrefix byte
bodySuffix byte
리턴 Task

WriteToResponse() 공개 정적인 메소드

public static WriteToResponse ( this httpRes, object result, ResponseSerializerDelegate serializer, IRequest serializationContext ) : Task
httpRes this
result object
serializer ResponseSerializerDelegate
serializationContext IRequest
리턴 Task

WriteToResponse() 공개 정적인 메소드

Writes to response. Response headers are customizable by implementing IHasOptions an returning Dictionary of Http headers.
public static WriteToResponse ( this response, object result, ResponseSerializerDelegate defaultAction, IRequest request, byte bodyPrefix, byte bodySuffix ) : Task
response this The response.
result object Whether or not it was implicity handled by ServiceStack's built-in handlers.
defaultAction ResponseSerializerDelegate The default action.
request IRequest The serialization context.
bodyPrefix byte Add prefix to response body if any
bodySuffix byte Add suffix to response body if any
리턴 Task

WriteToResponse() 공개 정적인 메소드

public static WriteToResponse ( this httpRes, object result, string contentType ) : Task
httpRes this
result object
contentType string
리턴 Task