I am trying to create custom mapper in external class to map String to Integer. the map method is called successfully when it is defined in the mapper ...
I am trying to create custom mapper in external class to map String to Integer. the map method is called successfully when it is defined in the mapper ...
In my spring boot project I have a Document class that has a bi-directional OneToOne relationship to an Invoice class, which share the same ID. Docum ...
I want to use MapperB inside MapperA's default method Similar to this question: How can I use another mapping from different class in mapstruct Howe ...
I need to use Mapstruct and this error is comming up. *APPLICATION FAILED TO START Description: Field userMapper in com.mycomp.myappapi.service.Us ...
STS is showing the message "Updating Maven Project: (75%)" at the bottom right corner and never ends that for hours (literally). It happens when I ad ...
I want to make childComments nested in root comments. I did it. But the problem is that mention field = null in childComments but other fields are dis ...
at the moment I have a solution using @AfterMapping, but I want to get rid of this approach in favor of qualifiedByName and do the mapping in the fi ...
How could I use a HashMap<String, MyObjectSource> as source to an object? Here is my target object: Here is my object source: Here is my ...
I want to map second und third parameter in the @mappings as the source , but it never works. If I do mapToDto(myEntity, "Hello", "WorldLong") Hell ...
I want to create unit test that handle an exception when dto fields != entity fields. And print missing and extra fields. Is it possible to make it wi ...
I'm trying to convert a List<String> to the below DomainUpdate object. The DomainUpdate object contains a List of Domains and a Domain just have ...
Does anyone know why mapStruct doesn't allow DTO class to have less elements than the ENTITY class. for example I have this entity : public class Pr ...
I have a source POJO and a target POJO, with 10 fields having getters and setters. If I use MapStruct to map source POJO to target POJO, a precomp ...
I should return several fields from ShipmentResponseDto.cargo.packaging.lastMeasurements as null if shipping.status==Status.Opened. Like this: I wa ...
I have Car: id brand model owner And CarDTO: id brand model In my service class I'm passing additional parameter "owner" and I ...
We are using Mapstruct in our project for mapping entities to the response we send through the rest api. For most parts, it is working. but we have on ...
I have a spring boot application with mapstruct where I get this warning on the maven-compiler-plugin testCompile phase: [WARNING] The following o ...
Is there a way to prevent MapStruct from creating an object if the source is null? Existing answers I've found explain how to do it with the object b ...
I am trying to use MapStruct alongside with QueryDsl,Spring Boot 3 and Java 17 but it seems like the maven-compiler-plugin I use for MapStruct prevent ...
my problem seems easy, but may be I'm doing something wrong. this is mapper class with @Named("toLocationListCommon") bean which suppose to be used in ...