Definition
Assembly: Microsoft.OData.Mcp.Core.dll Namespace: Microsoft.OData.Mcp.Core.Configuration Inheritance: System.ObjectSyntax
Summary
CORS (Cross-Origin Resource Sharing) configuration.Constructors
.ctor
Syntax
.ctor Inherited
Inherited from
objectSyntax
Properties
AllowCredentials
Gets or sets a value indicating whether credentials are allowed.Syntax
Property Value
Type:bool
AllowedHeaders
Gets or sets the allowed headers.Syntax
Property Value
Type:System.Collections.Generic.List<string>
AllowedMethods
Gets or sets the allowed methods.Syntax
Property Value
Type:System.Collections.Generic.List<string>
AllowedOrigins
Gets or sets the allowed origins.Syntax
Property Value
Type:System.Collections.Generic.List<string>
Enabled
Gets or sets a value indicating whether CORS is enabled.Syntax
Property Value
Type:bool
MaxAge
Gets or sets the maximum age for preflight requests.Syntax
Property Value
Type:System.TimeSpan
Methods
Clone
Creates a copy of this configuration.Syntax
Returns
Type:Microsoft.OData.Mcp.Core.Configuration.CorsConfiguration
A new instance with the same settings.
Equals Inherited Virtual
Inherited from
objectSyntax
Parameters
| Name | Type | Description |
|---|---|---|
obj | object? | - |
Returns
Type:bool
Equals Inherited
Inherited from
objectSyntax
Parameters
| Name | Type | Description |
|---|---|---|
objA | object? | - |
objB | object? | - |
Returns
Type:bool
GetHashCode Inherited Virtual
Inherited from
objectSyntax
Returns
Type:int
GetType Inherited
Inherited from
objectSyntax
Returns
Type:System.Type
MemberwiseClone Inherited
Inherited from
objectSyntax
Returns
Type:object
MergeWith
Merges another configuration into this one.Syntax
Parameters
| Name | Type | Description |
|---|---|---|
other | Microsoft.OData.Mcp.Core.Configuration.CorsConfiguration | The configuration to merge. |
ReferenceEquals Inherited
Inherited from
objectSyntax
Parameters
| Name | Type | Description |
|---|---|---|
objA | object? | - |
objB | object? | - |
Returns
Type:bool
ToString Inherited Virtual
Inherited from
objectSyntax
Returns
Type:string?
Validate
Validates the CORS configuration.Syntax
Returns
Type:System.Collections.Generic.IEnumerable<string>
Validation errors.