public class GetterWrapperForCollectionsAndMaps extends WrapperForCollectionsAndMaps
MappingTarget
before adding the source entries. The goal is that the same collection / map
is used as target.
Nothing can be added if the getter on the target returns null.Assignment.AssignmentType
Writable.Context
fieldAssignment
Constructor and Description |
---|
GetterWrapperForCollectionsAndMaps(Assignment decoratedAssignment,
List<Type> thrownTypesToExclude,
Type targetType,
boolean fieldAssignment) |
Modifier and Type | Method and Description |
---|---|
Set<Type> |
getImportTypes()
Returns a set containing those
Type s referenced by this model element for which an import statement needs
to be declared. |
getNullCheckLocalVarName, getNullCheckLocalVarType, getThrownTypes
createUniqueVarName, getAssignment, getSourceLocalVarName, getSourceLoopVarName, getSourceParameterName, getSourcePresenceCheckerReference, getSourceReference, getSourceType, getType, isCallingUpdateMethod, isFieldAssignment, isSourceReferenceParameter, setAssignment, setSourceLocalVarName, setSourceLoopVarName
getTemplateName, getTemplateNameForClass, write
public GetterWrapperForCollectionsAndMaps(Assignment decoratedAssignment, List<Type> thrownTypesToExclude, Type targetType, boolean fieldAssignment)
decoratedAssignment
- source RHSthrownTypesToExclude
- set of types to exclude from re-throwingtargetType
- the target typefieldAssignment
- true when this the assignment is to a field rather than via accessorspublic Set<Type> getImportTypes()
ModelElement
Type
s referenced by this model element for which an import statement needs
to be declared.getImportTypes
in interface Assignment
getImportTypes
in class AssignmentWrapper
null
.Copyright © 2012-2021 MapStruct Authors; All rights reserved. Released under the Apache Software License 2.0.