Skip to content
Advertisement

Tag: domain-driven-design

What nested class type is best suitable for Domain Events?

I am following Domain Driven Design and Clean/ Hexagonal architecture in my Java microservice. I have domain events declared in my aggregate root class as non-static nested classes. My question is whether these classes should be static nested classes or non-static nested classes(inner classes)? I used non-static nested classes but IntelliJ IDEA suggests to make them static. According to the

Advertisement