-
Notifications
You must be signed in to change notification settings - Fork 6
Mappers
Adrien LAUER edited this page Feb 23, 2017
·
2 revisions
A mapper is a Coffig component type responsible for mapping nodes to a specific Java type. A mapper implements the org.seedstack.coffig.spi.ConfigurationMapper
interface.
To register a mapper programmatically, you create an instance of the evaluator and add it as a parameter to the withMappers()
Coffig builder method:
Coffig.builder()
.withMappers(new MyMapper())
.build();
You can also register a mapper automatically by adding its fully qualified class name in META-INF/services/org.seedstack.coffig.spi.ConfigurationMapper
:
org.myorg.myapp.MyMapper