Additional metadata for Hexagonal Architecture's `@Port`s and `@Adapter`s
odrotbohm opened this issue · 0 comments
For documentation purposes, it would be nice to be able to declare a port or adapter's logical name and description in the annotation. This could be used to place human-readable flavors of their domain semantics right with the code that could be extracted into developer documentation.
name()
– defaults to the package or type name.description()
– defaults to the Javadoc of either the package or type
This especially becomes interesting if there's not a 1:1 mapping between, for example, port and type. Using the same port names would allow them to be grouped and displayed in docs. Assume some API / SPI split of some application feature that could use different packages to place the corresponding types in them but define a single place (the @(Primary|Secondary)Port
annotation on the package-info.java
) to define a human-readable description of each of them.
Follow-up of #71.