MVC: “User” model gets big and crowded. Should methods that do CRUD operations on one-to-many relationship data be in different models?
In most MVC web projects there is a User class. Many times a user has something else in a one-to-many relationship, i.e. orders.
MVC: “User” model gets big and crowded. Should methods that do CRUD operations on one-to-many relationship data be in different models?
In most MVC web projects there is a User class. Many times a user has something else in a one-to-many relationship, i.e. orders.
MVC: “User” model gets big and crowded. Should methods that do CRUD operations on one-to-many relationship data be in different models?
In most MVC web projects there is a User class. Many times a user has something else in a one-to-many relationship, i.e. orders.
MVC: “User” model gets big and crowded. Should methods that do CRUD operations on one-to-many relationship data be in different models?
In most MVC web projects there is a User class. Many times a user has something else in a one-to-many relationship, i.e. orders.
Should POCO domain classes contain collections?
The question title is not good, but I couldn’t think of a way to word it better.
Should POCO domain classes contain collections?
The question title is not good, but I couldn’t think of a way to word it better.
Relation between objects
For a few weeks I’ve been thinking about relation between objects – not especially OOP’s objects. For instance in C++, we’re used to representing that by layering pointers or container of pointers in the structure that needs an access to the other object. If an object A
needs to have an access to B
, it’s not uncommon to find a B *pB
in A
.
Relation between objects
For a few weeks I’ve been thinking about relation between objects – not especially OOP’s objects. For instance in C++, we’re used to representing that by layering pointers or container of pointers in the structure that needs an access to the other object. If an object A
needs to have an access to B
, it’s not uncommon to find a B *pB
in A
.
Pattern to safely establish a one to one bidirectional relationship
Let suppose we have 2 classes, Pilot
and Plane
, being in an optional one-to-one relationship. So a Plane
might have a pilot when it’s flying, but when it’s standing in its hangar, it has none. Similar for the Pilot
.
Pattern to safely establish a one to one bidirectional relationship
Let suppose we have 2 classes, Pilot
and Plane
, being in an optional one-to-one relationship. So a Plane
might have a pilot when it’s flying, but when it’s standing in its hangar, it has none. Similar for the Pilot
.