Repository pattern – using information from other repositories

I am trying to understand what is the proper approach when the objects generated from a Repository have a reference to objects which are responsible for another Repository.

Let’s say I have terminals which can have a list of possible quantities assigned and each quantity has a type. In this case I have 3 repositories TerminalsRepository, QuantitiesRepository, and QuantityTypeRepositories.

How should I populate the quantities information for the terminals and the type information for the quantities? Should the repositories use internally the other repositories or is there a better way to achieve that (for example a service method is retrieving the terminals and then populating the needed data)?

Go to Source
Author: djvuk