ITableBase.IsOptional Method

Definition

Overloads

IsOptional(IEntityType)

Gets the value indicating whether an entity of the given type might not be present in a row.

IsOptional(ITypeBase)

Gets the value indicating whether an entity of the given type might not be present in a row.

IsOptional(IEntityType)

Source:
ITableBase.cs

Gets the value indicating whether an entity of the given type might not be present in a row.

C#
public bool IsOptional (Microsoft.EntityFrameworkCore.Metadata.IEntityType entityType);

Parameters

entityType
IEntityType

Returns

Applies to

Entity Framework Core 7.0 and other versions
Product Versions
Entity Framework Core 5.0, 6.0, 7.0

IsOptional(ITypeBase)

Source:
ITableBase.cs
Source:
ITableBase.cs

Gets the value indicating whether an entity of the given type might not be present in a row.

C#
public bool IsOptional (Microsoft.EntityFrameworkCore.Metadata.ITypeBase typeBase);

Parameters

typeBase
ITypeBase

Returns

Applies to

Entity Framework Core 9.0 and Entity Framework Core 8.0
Product Versions
Entity Framework Core 8.0, 9.0