Share via


ComplexPropertyBuilder<TComplex> Class

Definition

Provides a simple API for configuring an IMutableEntityType.

public class ComplexPropertyBuilder<TComplex> : Microsoft.EntityFrameworkCore.Metadata.Builders.ComplexPropertyBuilder
type ComplexPropertyBuilder<'Complex> = class
    inherit ComplexPropertyBuilder
Public Class ComplexPropertyBuilder(Of TComplex)
Inherits ComplexPropertyBuilder

Type Parameters

TComplex

The complex type being configured.

Inheritance
ComplexPropertyBuilder<TComplex>

Remarks

Instances of this class are returned from methods when using the ModelBuilder API and it is not designed to be directly constructed in your application code.

Constructors

ComplexPropertyBuilder<TComplex>(IMutableComplexProperty)

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

Properties

Metadata

The complex property being configured.

(Inherited from ComplexPropertyBuilder)
PropertyBuilder

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

(Inherited from ComplexPropertyBuilder)
TypeBuilder

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

(Inherited from ComplexPropertyBuilder)

Methods

ComplexProperty(String, Action<ComplexPropertyBuilder>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty(String)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
ComplexProperty(Type, String, Action<ComplexPropertyBuilder>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty(Type, String, String, Action<ComplexPropertyBuilder>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty(Type, String, String)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
ComplexProperty(Type, String)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
ComplexProperty<TProperty>(Expression<Func<TComplex,TProperty>>, Action<ComplexPropertyBuilder<TProperty>>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty<TProperty>(Expression<Func<TComplex,TProperty>>, String, Action<ComplexPropertyBuilder<TProperty>>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty<TProperty>(Expression<Func<TComplex,TProperty>>, String)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty<TProperty>(Expression<Func<TComplex,TProperty>>)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty<TProperty>(String, Action<ComplexPropertyBuilder<TProperty>>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty<TProperty>(String, String, Action<ComplexPropertyBuilder<TProperty>>)

Configures a complex property of the complex type. If no property with the given name exists, then a new property will be added.

ComplexProperty<TProperty>(String, String)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
ComplexProperty<TProperty>(String)

Returns an object that can be used to configure a complex property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
HasChangeTrackingStrategy(ChangeTrackingStrategy)

Configures the ChangeTrackingStrategy to be used for this entity type. This strategy indicates how the context detects changes to properties for an instance of the entity type.

HasField(String)

Sets the backing field to use for this property.

HasPropertyAnnotation(String, Object)

Adds or updates an annotation on the entity type. If an annotation with the key specified in annotation already exists its value will be updated.

HasTypeAnnotation(String, Object)

Adds or updates an annotation on the entity type. If an annotation with the key specified in annotation already exists its value will be updated.

Ignore(Expression<Func<TComplex,Object>>)

Excludes the given property from the entity type. This method is typically used to remove properties or navigations from the entity type that were added by convention.

Ignore(String)

Excludes the given property from the entity type. This method is typically used to remove properties or navigations from the entity type that were added by convention.

IndexerProperty(Type, String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
IndexerProperty<TProperty>(String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
IsRequired(Boolean)

Configures whether this property must have a value assigned or null is a valid value. A property can only be configured as non-required if it is based on a CLR type that can be assigned null.

PrimitiveCollection(String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
PrimitiveCollection(Type, String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
PrimitiveCollection<TProperty>(Expression<Func<TComplex,TProperty>>)

Returns an object that can be used to configure a primitive collection property of the entity type. If the specified property is not already part of the model, it will be added.

PrimitiveCollection<TProperty>(String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
Property(String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
Property(Type, String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
Property<TProperty>(Expression<Func<TComplex,TProperty>>)

Returns an object that can be used to configure a property of the entity type. If the specified property is not already part of the model, it will be added.

Property<TProperty>(String)

Returns an object that can be used to configure a property of the complex type. If no property with the given name exists, then a new property will be added.

(Inherited from ComplexPropertyBuilder)
UseDefaultPropertyAccessMode(PropertyAccessMode)

Sets the PropertyAccessMode to use for all properties of this entity type.

UsePropertyAccessMode(PropertyAccessMode)

Sets the PropertyAccessMode to use for this property.

Explicit Interface Implementations

IInfrastructure<IConventionComplexPropertyBuilder>.Instance

Gets the internal builder being used to configure the complex property.

(Inherited from ComplexPropertyBuilder)
IInfrastructure<IConventionComplexTypeBuilder>.Instance

Gets the internal builder being used to configure the complex type.

(Inherited from ComplexPropertyBuilder)

Extension Methods

GetInfrastructure<T>(IInfrastructure<T>)

Gets the value from a property that is being hidden using IInfrastructure<T>.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

Applies to