NonNullableReferencePropertyConvention Klasa

Definicja

Konwencja, która konfiguruje właściwości typów innych niż null zgodnie z wymaganiami.

public class NonNullableReferencePropertyConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.NonNullableConventionBase, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyFieldChangedConvention
public class NonNullableReferencePropertyConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.NonNullableConventionBase, Microsoft.EntityFrameworkCore.Metadata.Conventions.IComplexPropertyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IComplexPropertyFieldChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyFieldChangedConvention
type NonNullableReferencePropertyConvention = class
    inherit NonNullableConventionBase
    interface IPropertyAddedConvention
    interface IConvention
    interface IPropertyFieldChangedConvention
type NonNullableReferencePropertyConvention = class
    inherit NonNullableConventionBase
    interface IPropertyAddedConvention
    interface IConvention
    interface IPropertyFieldChangedConvention
    interface IComplexPropertyAddedConvention
    interface IComplexPropertyFieldChangedConvention
Public Class NonNullableReferencePropertyConvention
Inherits NonNullableConventionBase
Implements IPropertyAddedConvention, IPropertyFieldChangedConvention
Public Class NonNullableReferencePropertyConvention
Inherits NonNullableConventionBase
Implements IComplexPropertyAddedConvention, IComplexPropertyFieldChangedConvention, IPropertyAddedConvention, IPropertyFieldChangedConvention
Dziedziczenie
NonNullableReferencePropertyConvention
Implementuje

Uwagi

Aby uzyskać więcej informacji i przykłady, zobacz Konwencje tworzenia modeli .

Konstruktory

NonNullableReferencePropertyConvention(ProviderConventionSetBuilderDependencies)

Tworzy nowe wystąpienie klasy NonNullableReferencePropertyConvention.

Właściwości

Dependencies

Zależności dla tej usługi.

(Odziedziczone po NonNullableConventionBase)

Metody

IsNonNullableReferenceType(IConventionModelBuilder, MemberInfo)

Zwraca wartość wskazującą, czy typ elementu członkowskiego jest typem referencyjnym bez wartości null.

(Odziedziczone po NonNullableConventionBase)
ProcessComplexPropertyAdded(IConventionComplexPropertyBuilder, IConventionContext<IConventionComplexPropertyBuilder>)

Wywoływana po dodaniu właściwości złożonej do obiektu przypominającego typ.

ProcessComplexPropertyFieldChanged(IConventionComplexPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

Wywoływane po zmianie pola zapasowego dla właściwości złożonej.

ProcessModelFinalized(IConventionModelBuilder, IConventionContext<IConventionModelBuilder>)

Wywoływane po sfinalizowaniu modelu. Usuwa adnotację stanu buforowanego używaną przez tę konwencję.

(Odziedziczone po NonNullableConventionBase)
ProcessModelFinalizing(IConventionModelBuilder, IConventionContext<IConventionModelBuilder>)

Wywoływana, gdy model jest finalizowany.

(Odziedziczone po NonNullableConventionBase)
ProcessPropertyAdded(IConventionPropertyBuilder, IConventionContext<IConventionPropertyBuilder>)

Wywoływane po dodaniu właściwości do typu jednostki.

ProcessPropertyFieldChanged(IConventionPropertyBuilder, FieldInfo, FieldInfo, IConventionContext<FieldInfo>)

Wywoływane po zmianie pola zapasowego właściwości.

TryGetNullabilityInfo(IConventionModelBuilder, MemberInfo, NullabilityInfo)

Zwraca wartość wskazującą, czy typ elementu członkowskiego jest typem referencyjnym bez wartości null.

(Odziedziczone po NonNullableConventionBase)

Dotyczy