Expected behavior
MappingConstants.THROW_EXCEPTION ("<THROW_EXCEPTION>") allows throwing an exception for particular value mappings. For instance:
@ValueMapping(target = "APPLE", source = "Apple")
@ValueMapping(target = "BANANA", source = "Banana")
@ValueMapping(target = MappingConstants.THROW_EXCEPTION, source = MappingConstants.ANY_UNMAPPED)
Fruit mapFruit(String fruit);
However, this constant is not referenced in the MapStruct reference guide.
Actual behavior
I would expect to see this explained in the reference guide. In my particular use case, I didn't see any references in the Mapping enum to enum types section.
Steps to reproduce the problem
Open the reference guide. Notice that there are no references to either <THROW_EXCEPTION> or MappingConstants.THROW_EXCEPTION.
MapStruct Version
MapStruct 1.5.3
Expected behavior
MappingConstants.THROW_EXCEPTION("<THROW_EXCEPTION>") allows throwing an exception for particular value mappings. For instance:However, this constant is not referenced in the MapStruct reference guide.
Actual behavior
I would expect to see this explained in the reference guide. In my particular use case, I didn't see any references in the Mapping enum to enum types section.
Steps to reproduce the problem
Open the reference guide. Notice that there are no references to either
<THROW_EXCEPTION>orMappingConstants.THROW_EXCEPTION.MapStruct Version
MapStruct 1.5.3