...

/

Using Domain Entities as an Input or Output Model

Using Domain Entities as an Input or Output Model

Learn how to use domain entities as an input or output model in your projects.

If we have an Account domain entity and an incoming port SendMoneyUseCase, we might be tempted to use the entity as the input and/or output model of the incoming port, as the figure below shows:

Using domain entities as input model

The incoming port has a dependency to the domain entity. The consequence of this is that we’ve added another reason for the Account entity to change. ...