CosmosJsonIdConvention Classe
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Convenzione che configura il mapping delle proprietà PK e/o discriminatorie alla proprietà JSON 'id'.
[System.Runtime.CompilerServices.Nullable(0)]
public class CosmosJsonIdConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.IDiscriminatorPropertySetConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeAnnotationChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IEntityTypeBaseTypeChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IForeignKeyOwnershipChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IKeyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IKeyRemovedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IModelAnnotationChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyAnnotationChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.IPropertyRemovedConvention
[<System.Runtime.CompilerServices.Nullable(0)>]
type CosmosJsonIdConvention = class
interface IEntityTypeAddedConvention
interface IConvention
interface IEntityTypeBaseTypeChangedConvention
interface IEntityTypeAnnotationChangedConvention
interface IForeignKeyOwnershipChangedConvention
interface IKeyAddedConvention
interface IKeyRemovedConvention
interface IPropertyAddedConvention
interface IPropertyRemovedConvention
interface IPropertyAnnotationChangedConvention
interface IModelAnnotationChangedConvention
interface IDiscriminatorPropertySetConvention
Public Class CosmosJsonIdConvention
Implements IDiscriminatorPropertySetConvention, IEntityTypeAddedConvention, IEntityTypeAnnotationChangedConvention, IEntityTypeBaseTypeChangedConvention, IForeignKeyOwnershipChangedConvention, IKeyAddedConvention, IKeyRemovedConvention, IModelAnnotationChangedConvention, IPropertyAddedConvention, IPropertyAnnotationChangedConvention, IPropertyRemovedConvention
- Ereditarietà
-
CosmosJsonIdConvention
- Attributi
- Implementazioni
-
IConvention IDiscriminatorPropertySetConvention IEntityTypeAddedConvention IEntityTypeAnnotationChangedConvention IEntityTypeBaseTypeChangedConvention IForeignKeyOwnershipChangedConvention IKeyAddedConvention IKeyRemovedConvention IModelAnnotationChangedConvention IPropertyAddedConvention IPropertyAnnotationChangedConvention IPropertyRemovedConvention
Commenti
Per altre informazioni ed esempi, vedere Convenzioni di compilazione di modelli e Accesso a Azure Cosmos DB con EF Core.
Costruttori
| Nome | Descrizione |
|---|---|
| CosmosJsonIdConvention(ProviderConventionSetBuilderDependencies, IJsonIdDefinitionFactory) |
Crea una nuova istanza di CosmosJsonIdConvention. |
Campi
| Nome | Descrizione |
|---|---|
| DefaultIdPropertyName |
Si tratta di un'API interna che supporta l'infrastruttura Entity Framework Core e non è soggetta agli stessi standard di compatibilità delle API pubbliche. Può essere modificato o rimosso senza preavviso in alcuna versione. È consigliabile usarlo direttamente nel codice con estrema cautela e sapere che questa operazione può causare errori dell'applicazione durante l'aggiornamento a una nuova versione Entity Framework Core. |
| IdPropertyJsonName |
Si tratta di un'API interna che supporta l'infrastruttura Entity Framework Core e non è soggetta agli stessi standard di compatibilità delle API pubbliche. Può essere modificato o rimosso senza preavviso in alcuna versione. È consigliabile usarlo direttamente nel codice con estrema cautela e sapere che questa operazione può causare errori dell'applicazione durante l'aggiornamento a una nuova versione Entity Framework Core. |
Proprietà
| Nome | Descrizione |
|---|---|
| DefinitionFactory |
Factory per creare un Microsoft.EntityFrameworkCore.Cosmos.Metadata.Internal.IJsonIdDefinition oggetto per ogni tipo di entità. |
| Dependencies |
Dipendenze per questo servizio. |