Class SetterWrapperForCollectionsAndMapsWithNullCheck

All Implemented Interfaces:
Assignment, Writable
Direct Known Subclasses:
ExistingInstanceSetterWrapperForCollectionsAndMaps, NewInstanceSetterWrapperForCollectionsAndMaps

public class SetterWrapperForCollectionsAndMapsWithNullCheck extends WrapperForCollectionsAndMaps
This wrapper handles the situation where an assignment is done via the setter and a null check is needed. This is needed when a direct assignment is used, or if the user has chosen the appropriate strategy
Author:
Sjaak Derksen
  • Constructor Details

    • SetterWrapperForCollectionsAndMapsWithNullCheck

      public SetterWrapperForCollectionsAndMapsWithNullCheck(Assignment decoratedAssignment, List<Type> thrownTypesToExclude, Type targetType, TypeFactory typeFactory, boolean fieldAssignment)
  • Method Details

    • getImportTypes

      public Set<Type> getImportTypes()
      Description copied from class: ModelElement
      Returns a set containing those Types referenced by this model element for which an import statement needs to be declared.
      Specified by:
      getImportTypes in interface Assignment
      Overrides:
      getImportTypes in class AssignmentWrapper
      Returns:
      A set with type referenced by this model element. Must not be null.
    • isDirectAssignment

      public boolean isDirectAssignment()
    • isEnumSet

      public boolean isEnumSet()