Freigeben über


CosmosPropertyBuilderExtensions.CanSetIsVector Method

Definition

Returns a value indicating whether the vector type can be set.

[System.Diagnostics.CodeAnalysis.Experimental("EF9103")]
public static bool CanSetIsVector (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder propertyBuilder, Microsoft.Azure.Cosmos.DistanceFunction distanceFunction, int dimensions, bool fromDataAnnotation = false);
[<System.Diagnostics.CodeAnalysis.Experimental("EF9103")>]
static member CanSetIsVector : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder * Microsoft.Azure.Cosmos.DistanceFunction * int * bool -> bool
<Extension()>
Public Function CanSetIsVector (propertyBuilder As IConventionPropertyBuilder, distanceFunction As DistanceFunction, dimensions As Integer, Optional fromDataAnnotation As Boolean = false) As Boolean

Parameters

propertyBuilder
IConventionPropertyBuilder

The builder for the property being configured.

distanceFunction
DistanceFunction

The distance function for a vector comparisons.

dimensions
Int32

The number of dimensions in the vector.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

true if the vector type can be set.

Attributes

Remarks

See Modeling entity types and relationships, and Accessing Azure Cosmos DB with EF Core for more information and examples.

Applies to