Sisk

Constructor

CrossOriginResourceSharingHeaders constructor

Namespace
Sisk.Core.Entity
Assembly
Sisk.Core.dll

CrossOriginResourceSharingHeaders() #

Creates an empty CrossOriginResourceSharingHeaders instance with no predefined CORS headers.

C#
public CrossOriginResourceSharingHeaders()

CrossOriginResourceSharingHeaders(string?, string[]?, string[]?, string[]?, string[]?, TimeSpan?, bool) #

Initializes a new instance of the CrossOriginResourceSharingHeaders class with the specified CORS headers.

C#
public CrossOriginResourceSharingHeaders(string? allowOrigin = null, string[]? allowOrigins = null, string[]? allowMethods = null, string[]? allowHeaders = null, string[]? exposeHeaders = null, TimeSpan? maxAge = null, bool allowCredentials = false)

Parameters #

allowOrigin string?

The value of the Access-Control-Allow-Origin header.

allowOrigins string[]?

The values of the Access-Control-Allow-Origin header.

allowMethods string[]?

The values of the Access-Control-Allow-Methods header.

allowHeaders string[]?

The values of the Access-Control-Allow-Headers header.

exposeHeaders string[]?

The values of the Access-Control-Expose-Headers header.

maxAge TimeSpan?

The value of the Access-Control-Max-Age header.

allowCredentials bool

The value of the Access-Control-Allow-Credentials header.

Type to search the documentation and the API reference.