Share via


PrimitiveCollectionBuilder.ValueGeneratedOnAdd Method

Definition

Configures a property to have a value generated only when saving a new entity, unless a non-null, non-temporary value has been set, in which case the set value will be saved instead. The value may be generated by a client-side value generator or may be generated by the database as part of saving the entity.

public virtual Microsoft.EntityFrameworkCore.Metadata.Builders.PrimitiveCollectionBuilder ValueGeneratedOnAdd ();
abstract member ValueGeneratedOnAdd : unit -> Microsoft.EntityFrameworkCore.Metadata.Builders.PrimitiveCollectionBuilder
override this.ValueGeneratedOnAdd : unit -> Microsoft.EntityFrameworkCore.Metadata.Builders.PrimitiveCollectionBuilder
Public Overridable Function ValueGeneratedOnAdd () As PrimitiveCollectionBuilder

Returns

The same builder instance so that multiple configuration calls can be chained.

Applies to