Interface ITableBase
- Namespace
- Microsoft.EntityFrameworkCore.Metadata
- Assembly
- Microsoft.EntityFrameworkCore.Relational.dll
Represents a table-like object in the database.
public interface ITableBase : IAnnotatable
Properties
Columns
Gets the columns defined for this table.
IEnumerable<IColumnBase> Columns { get; }
Property Value
EntityTypeMappings
Gets the entity type mappings.
IEnumerable<ITableMappingBase> EntityTypeMappings { get; }
Property Value
IsShared
Gets the value indicating whether multiple entity types are sharing the rows in the table.
bool IsShared { get; }
Property Value
Model
Gets the database model.
IRelationalModel Model { get; }
Property Value
Name
Gets the name of the table in the database.
string Name { get; }
Property Value
Schema
Gets the schema of the table in the database.
string Schema { get; }
Property Value
Methods
FindColumn(IProperty)
Gets the column mapped to the given property. Returns null if no column is mapped to the given property.
IColumnBase FindColumn(IProperty property)
Parameters
property
IProperty
Returns
FindColumn(string)
Gets the column with the given name. Returns null if no column with the given name is defined.
IColumnBase FindColumn(string name)
Parameters
name
string
Returns
GetReferencingRowInternalForeignKeys(IEntityType)
Gets the foreign keys referencing the given entity type from other entity types sharing this table.
IEnumerable<IForeignKey> GetReferencingRowInternalForeignKeys(IEntityType entityType)
Parameters
entityType
IEntityType
Returns
- IEnumerable<IForeignKey>
GetRowInternalForeignKeys(IEntityType)
Gets the foreign keys for the given entity type that point to other entity types sharing this table.
IEnumerable<IForeignKey> GetRowInternalForeignKeys(IEntityType entityType)
Parameters
entityType
IEntityType
Returns
- IEnumerable<IForeignKey>
IsOptional(IEntityType)
Gets the value indicating whether an entity of the given type might not be present in a row.
bool IsOptional(IEntityType entityType)
Parameters
entityType
IEntityType