A common logic that I see when making object classes is that developers often map classes on a 1:1 assosiation to their DB tables.
For ex, if my DB has 3 tables:
Table_a, Table_b and Table_c,
then, I can create 3 object classes, like Class_a, Class_b and Class_c, with each class having fields corrosponding to one particular table.
Now, from what I read about EF, when you provide a DB to an EF model, it creates the classes and DAL for you, but its mapping logic is not necessarily 1:1 like the above. I think that it somehow combines fields from multiple tables into one class, so that you can end up with fewre number of object classes that the number of tables in your DB, even though all your tables are represented properly and correctly.
Does this mapping logic work by considering tables related by foreign key relationships and combining these into same class, while keeping unrelated tables in other class? Is the foreign key relation the only thing needed to be considered when creating object classes? Or is there some other logic of doing this? Can I manually do what EF does?