An Eclipse plug-in for working with MapStruct
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
build-config
org.mapstruct.eclipse.feature
org.mapstruct.eclipse.repository
org.mapstruct.eclipse
parent
.gitattributes
.gitignore
LICENSE.txt
README.md
copyright.txt
pom.xml
still-completion-1.png
still-quickfix-1.png
still-quickfix-2.png

README.md

mapstruct-eclipse

An Eclipse plug-in for working with MapStruct

Eclipse Update Site

Current Features

Code-Completions

  • Completion of target and source properties in @Mapping annotation for bean mappings
  • Completion of target and source enum constants in @ValueMapping annotations for enum mappings
  • Completion of componentModel values in @Mapper annotation

Quick-Fixes

  • Quick-Fixes for error/warning message "Unmapped target property: ...":
    • Ignore unmapped target property adds @Mapping( target = "prop", ignore = true ) to the method
  • Quick-Fixes for error message "Can't map property X prop to Y prop. Consider to declare/implement a mapping method ...":
    • Add method: Y toY(X prop) adds an appropriate method declaration to the mapper.
    • Ignore unmapped target property adds @Mapping( target = "prop", ignore = true ) to the method.

Screenshots

Completion for Properties and Enum Constants

Code completion for properties and enum constants

Quick Fix to Add Missing Property Mapping Method

Quick Fix to add missing property mapping method

Quick Fix to Ignore an Unmapped Property

Quick Fix to ignore an unmapped property

Links