inContextOf

public static Model inContextOf<T>(Class<? extends T> rawClass)

Obtains the instance which belongs to the Bounded Context of the passed class.

The method tries to obtain the context from the annotations of the package "hierarchy" to which the class belongs. If no annotation found, test-only will be created.

See also

BoundedContext