Class SourceReference
java.lang.Object
org.mapstruct.ap.internal.model.beanmapping.AbstractReference
org.mapstruct.ap.internal.model.beanmapping.SourceReference
This class describes the source side of a property mapping.
It contains the source parameter, and all individual (nested) property entries. So consider the following mapping method:
@Mapping(target = "propC", source = "in.propA.propB") TypeB mappingMethod(TypeA in);Then:
parameterwill describeinpropertyEntries[0]will describepropApropertyEntries[1]will describepropB
AbstractReference.isValid() will return true when no problems are detected during building.- Author:
- Sjaak Derksen, Filip Hrisafov
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classBuilds aSourceReferencefrom an@Mappping.static classBuilds aSourceReferencefrom a property.static classBuilds aSourceReferencefrom a property. -
Method Summary
Modifier and TypeMethodDescriptionpop()push(TypeFactory typeFactory, FormattingMessager messager, Method method) withParameter(Parameter parameter) Methods inherited from class org.mapstruct.ap.internal.model.beanmapping.AbstractReference
getDeepestProperty, getDeepestPropertyName, getElementNames, getParameter, getPropertyEntries, getShallowestProperty, getShallowestPropertyName, isNested, isValid, toString
-
Method Details
-
pop
-
push
public List<SourceReference> push(TypeFactory typeFactory, FormattingMessager messager, Method method) -
withParameter
-