
public class SourceReference extends AbstractReference
It contains the source parameter, and all individual (nested) property entries. So consider the following mapping method:
@Mapping(source = "in.propA.propB" target = "propC") TypeB mappingMethod(TypeA in);Then:
parameter will describe inpropertyEntries[0] will describe propApropertyEntries[1] will describe propBAbstractReference.isValid() will return true when when no problems are detected during building.| Modifier and Type | Class and Description |
|---|---|
static class |
SourceReference.BuilderFromMapping
Builds a
SourceReference from an @Mappping. |
static class |
SourceReference.BuilderFromProperty
Builds a
SourceReference from a property. |
static class |
SourceReference.BuilderFromSourceReference
Builds a
SourceReference from a property. |
| Modifier and Type | Method and Description |
|---|---|
SourceReference |
pop() |
List<SourceReference> |
push(TypeFactory typeFactory,
FormattingMessager messager,
Method method) |
getDeepestProperty, getDeepestPropertyName, getElementNames, getParameter, getPropertyEntries, getShallowestProperty, getShallowestPropertyName, isNested, isValid, toStringpublic SourceReference pop()
public List<SourceReference> push(TypeFactory typeFactory, FormattingMessager messager, Method method)
Copyright © 2012-2021 MapStruct Authors; All rights reserved. Released under the Apache Software License 2.0.