Package org.jmolecules.ddd.annotation
Annotation Type Module
-
@Retention(RUNTIME) @Target({PACKAGE,ANNOTATION_TYPE}) @Documented public @interface Module
Identifies a DDD module.
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.String
description
A human readable description for the module.java.lang.String
id
A stable identifier for the module.java.lang.String
name
A human readable name for the module.java.lang.String
value
An alias forname()
.
-
-
-
Element Detail
-
id
java.lang.String id
A stable identifier for the module. If not defined, an identifier will be derived from the annotated element, usually a package. That allows tooling to derive name and description by applying some kind of convention to the identifier.Assuming a package
com.acme.myapp.module
annotated withModule
, tooling could use a resource bundle to lookup the keyscom.acme.myapp.module._name
andcom.acme.myapp.module_description
to resolve name and description respectively.- Returns:
- Default:
- ""
-
-
-
name
java.lang.String name
A human readable name for the module. Might be overridden by an external resolution mechanism viaid()
. Tooling should prevent bothvalue()
andname()
from being configured at the same time. If in doubt, the value defined inname()
will be preferred.- Returns:
- See Also:
id()
- Default:
- ""
-
-