I need to find which table is mapped to an EntityTypeConfiguration class.
For example:
public class PersonMap : EntityTypeConfiguration<Person>
{
public PersonMap()
{
...
this.ToTable("Persons");
....
}
}
I need something like reverse mapping:
var map=new PersonMap();
string table =map.GetMappedTableName();
How can I achieve this?
Add the field to PersonMap:
Access it like so:
If you may not know the type of map, use an interface:
Access like so: