Table of Contents

Class AspNetHttpResponse

Namespace
ComponentSpace.Saml2.Bindings
Assembly
ComponentSpace.Saml2.dll

Represents an ASP.NET HTTP response for use with the SAML bindings.

public class AspNetHttpResponse : IHttpResponse
Inheritance
AspNetHttpResponse
Implements
Inherited Members

Constructors

AspNetHttpResponse(IHttpContextAccessor)

Initializes a new instance of the AspNetHttpResponse class.

public AspNetHttpResponse(IHttpContextAccessor httpContextAccessor)

Parameters

httpContextAccessor IHttpContextAccessor

The HTTP context accessor.

Properties

Body

Gets the HTTP body.

The body is automatically URL encoded.

public virtual Stream Body { get; }

Property Value

Stream

The HTTP body.

ContentType

Gets or sets the content type.

public virtual string ContentType { get; set; }

Property Value

string

The content type.

Methods

AddCookie(string, string, CookieOptions)

Adds a cookie.

public virtual void AddCookie(string cookieName, string cookieValue, CookieOptions cookieOptions)

Parameters

cookieName string

The cookie name.

cookieValue string

The cookie value.

cookieOptions CookieOptions

The optional cookie options.

AddHeader(string, StringValues)

Adds a header.

public virtual void AddHeader(string headerName, StringValues headerValues)

Parameters

headerName string

The header name.

headerValues StringValues

The header values.

Redirect(string)

Redirects to the specified URL.

public virtual void Redirect(string url)

Parameters

url string

The URL.