SqlServerEntityTypeBuilderExtensions.IsMemoryOptimized Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
IsMemoryOptimized(EntityTypeBuilder, Boolean) |
Obsolete.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized. |
IsMemoryOptimized(OwnedNavigationBuilder, Boolean) |
Obsolete.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized. |
IsMemoryOptimized(IConventionEntityTypeBuilder, Nullable<Boolean>, Boolean) |
Configures the table that the entity maps to when targeting SQL Server as memory-optimized. |
IsMemoryOptimized<TEntity,TRelatedEntity>(OwnedNavigationBuilder<TEntity,TRelatedEntity>, Boolean) |
Obsolete.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized. |
IsMemoryOptimized<TEntity>(EntityTypeBuilder<TEntity>, Boolean) |
Obsolete.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized. |
IsMemoryOptimized(EntityTypeBuilder, Boolean)
Caution
Configure this using ToTable(t => t.IsMemoryOptimized()) instead.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized.
public static Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder IsMemoryOptimized (this Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder entityTypeBuilder, bool memoryOptimized = true);
[System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")]
public static Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder IsMemoryOptimized (this Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder entityTypeBuilder, bool memoryOptimized = true);
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder
[<System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")>]
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder
<Extension()>
Public Function IsMemoryOptimized (entityTypeBuilder As EntityTypeBuilder, Optional memoryOptimized As Boolean = true) As EntityTypeBuilder
Parameters
- entityTypeBuilder
- EntityTypeBuilder
The builder for the entity type being configured.
- memoryOptimized
- Boolean
A value indicating whether the table is memory-optimized.
Returns
The same builder instance so that multiple calls can be chained.
- Attributes
Remarks
See Using SQL Server memory-optimized tables with EF Core for more information and examples.
Applies to
IsMemoryOptimized(OwnedNavigationBuilder, Boolean)
Caution
Configure this using ToTable(t => t.IsMemoryOptimized()) instead.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized.
public static Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder IsMemoryOptimized (this Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder collectionOwnershipBuilder, bool memoryOptimized = true);
[System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")]
public static Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder IsMemoryOptimized (this Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder collectionOwnershipBuilder, bool memoryOptimized = true);
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder
[<System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")>]
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder
<Extension()>
Public Function IsMemoryOptimized (collectionOwnershipBuilder As OwnedNavigationBuilder, Optional memoryOptimized As Boolean = true) As OwnedNavigationBuilder
Parameters
- collectionOwnershipBuilder
- OwnedNavigationBuilder
The builder for the entity type being configured.
- memoryOptimized
- Boolean
A value indicating whether the table is memory-optimized.
Returns
The same builder instance so that multiple calls can be chained.
- Attributes
Remarks
See Using SQL Server memory-optimized tables with EF Core for more information and examples.
Applies to
IsMemoryOptimized(IConventionEntityTypeBuilder, Nullable<Boolean>, Boolean)
Configures the table that the entity maps to when targeting SQL Server as memory-optimized.
public static Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder IsMemoryOptimized (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder entityTypeBuilder, bool? memoryOptimized, bool fromDataAnnotation = false);
public static Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder? IsMemoryOptimized (this Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder entityTypeBuilder, bool? memoryOptimized, bool fromDataAnnotation = false);
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder * Nullable<bool> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionEntityTypeBuilder
<Extension()>
Public Function IsMemoryOptimized (entityTypeBuilder As IConventionEntityTypeBuilder, memoryOptimized As Nullable(Of Boolean), Optional fromDataAnnotation As Boolean = false) As IConventionEntityTypeBuilder
Parameters
- entityTypeBuilder
- IConventionEntityTypeBuilder
The builder for the entity type being configured.
- fromDataAnnotation
- Boolean
Indicates whether the configuration was specified using a data annotation.
Returns
The same builder instance if the configuration was applied,
null
otherwise.
Remarks
See Using SQL Server memory-optimized tables with EF Core for more information and examples.
Applies to
IsMemoryOptimized<TEntity,TRelatedEntity>(OwnedNavigationBuilder<TEntity,TRelatedEntity>, Boolean)
Caution
Configure this using ToTable(t => t.IsMemoryOptimized()) instead.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized.
public static Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<TEntity,TRelatedEntity> IsMemoryOptimized<TEntity,TRelatedEntity> (this Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<TEntity,TRelatedEntity> collectionOwnershipBuilder, bool memoryOptimized = true) where TEntity : class where TRelatedEntity : class;
[System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")]
public static Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<TEntity,TRelatedEntity> IsMemoryOptimized<TEntity,TRelatedEntity> (this Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<TEntity,TRelatedEntity> collectionOwnershipBuilder, bool memoryOptimized = true) where TEntity : class where TRelatedEntity : class;
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<'Entity, 'RelatedEntity (requires 'Entity : null and 'RelatedEntity : null)> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<'Entity, 'RelatedEntity (requires 'Entity : null and 'RelatedEntity : null)> (requires 'Entity : null and 'RelatedEntity : null)
[<System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")>]
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<'Entity, 'RelatedEntity (requires 'Entity : null and 'RelatedEntity : null)> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.OwnedNavigationBuilder<'Entity, 'RelatedEntity (requires 'Entity : null and 'RelatedEntity : null)> (requires 'Entity : null and 'RelatedEntity : null)
<Extension()>
Public Function IsMemoryOptimized(Of TEntity As Class, TRelatedEntity As Class) (collectionOwnershipBuilder As OwnedNavigationBuilder(Of TEntity, TRelatedEntity), Optional memoryOptimized As Boolean = true) As OwnedNavigationBuilder(Of TEntity, TRelatedEntity)
Type Parameters
- TEntity
The entity type being configured.
- TRelatedEntity
The entity type that this relationship targets.
Parameters
- collectionOwnershipBuilder
- OwnedNavigationBuilder<TEntity,TRelatedEntity>
The builder for the entity type being configured.
- memoryOptimized
- Boolean
A value indicating whether the table is memory-optimized.
Returns
The same builder instance so that multiple calls can be chained.
- Attributes
Remarks
See Using SQL Server memory-optimized tables with EF Core for more information and examples.
Applies to
IsMemoryOptimized<TEntity>(EntityTypeBuilder<TEntity>, Boolean)
Caution
Configure this using ToTable(t => t.IsMemoryOptimized()) instead.
Configures the table that the entity maps to when targeting SQL Server as memory-optimized.
public static Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<TEntity> IsMemoryOptimized<TEntity> (this Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<TEntity> entityTypeBuilder, bool memoryOptimized = true) where TEntity : class;
[System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")]
public static Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<TEntity> IsMemoryOptimized<TEntity> (this Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<TEntity> entityTypeBuilder, bool memoryOptimized = true) where TEntity : class;
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<'Entity (requires 'Entity : null)> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<'Entity (requires 'Entity : null)> (requires 'Entity : null)
[<System.Obsolete("Configure this using ToTable(t => t.IsMemoryOptimized()) instead.")>]
static member IsMemoryOptimized : Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<'Entity (requires 'Entity : null)> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.EntityTypeBuilder<'Entity (requires 'Entity : null)> (requires 'Entity : null)
<Extension()>
Public Function IsMemoryOptimized(Of TEntity As Class) (entityTypeBuilder As EntityTypeBuilder(Of TEntity), Optional memoryOptimized As Boolean = true) As EntityTypeBuilder(Of TEntity)
Type Parameters
- TEntity
The entity type being configured.
Parameters
- entityTypeBuilder
- EntityTypeBuilder<TEntity>
The builder for the entity type being configured.
- memoryOptimized
- Boolean
A value indicating whether the table is memory-optimized.
Returns
The same builder instance so that multiple calls can be chained.
- Attributes
Remarks
See Using SQL Server memory-optimized tables with EF Core for more information and examples.
Applies to
Entity Framework