Compare commits
5 Commits
mapstruct-
...
mapstruct-
| Author | SHA1 | Date | |
|---|---|---|---|
| a1ade490d6 | |||
| 6a44d5783f | |||
| 1ca7aa772f | |||
| 980f8d90c7 | |||
| 5116a0741b |
38
README.md
38
README.md
@ -2,13 +2,31 @@
|
||||
|
||||
Additional DefaultAccessorNamingStrategy to support fluent API withXYZ setters.
|
||||
|
||||
[](https://github.com/mapstruct/mapstruct/blob/master/LICENSE.txt)
|
||||
|
||||
* [What is MapStruct?](#what-is-mapstruct)
|
||||
* [Features](#features)
|
||||
* [Usage](#usage)
|
||||
* [Example](#example)
|
||||
* [Requirements](#requirements)
|
||||
* [Building from Source](#building-from-source)
|
||||
* [Licensing](#licensing)
|
||||
|
||||
## What is MapStruct?
|
||||
|
||||
MapStruct is a Java [annotation processor](https://docs.oracle.com/javase/6/docs/technotes/guides/apt/index.html) for the generation of type-safe and performant mappers for Java bean classes.
|
||||
|
||||
To learn more about MapStruct have a look at the [mapstruct](https://github.com/mapstruct/mapstruct) repository or the [website](https://mapstruct.org/)
|
||||
|
||||
## Features
|
||||
|
||||
Mapstruct default naming strategy detects the methods `withFirstName` and `withLastName` (see example below) as extra
|
||||
target fields and therefore cause an error, when the mapper is annotated with
|
||||
`unmappedTargetPolicy = ReportingPolicy.ERROR`.
|
||||
|
||||
The additional naming strategy makes Mapstruct ignore the withXYZ setters.
|
||||
|
||||
## Installation
|
||||
## Usage
|
||||
|
||||
To use the extended naming strategy, just include it as project dependency alongside with mapstruct.
|
||||
|
||||
@ -18,12 +36,12 @@ To use the extended naming strategy, just include it as project dependency along
|
||||
<dependency>
|
||||
<groupId>org.mapstruct</groupId>
|
||||
<artifactId>mapstruct</artifactId>
|
||||
<version>1.4.2.Final</version>
|
||||
<version>1.5.5.Final</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>de.muehlencord.mapstruct</groupId>
|
||||
<artifactId>mapstruct-support</artifactId>
|
||||
<version>1.4.2</version>
|
||||
<version>1.5.5</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
```
|
||||
@ -71,3 +89,17 @@ public class Person {
|
||||
|
||||
```
|
||||
|
||||
## Requirements
|
||||
|
||||
The MapStruct plugin requires Java 11 or later
|
||||
|
||||
## Building from Source
|
||||
mapstruct-support uses maven as build system. Simple execute
|
||||
|
||||
```shell
|
||||
mvn clean install
|
||||
```
|
||||
|
||||
## Licensing
|
||||
|
||||
The MapStruct plugin is licensed under the Apache License, Version 2.0 (the "License"); you may not use it except in compliance with the License. You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0.
|
||||
|
||||
4
copyright.txt
Normal file
4
copyright.txt
Normal file
@ -0,0 +1,4 @@
|
||||
Contributors
|
||||
============
|
||||
|
||||
Joern Muehlencord - https://github.com/jomu78
|
||||
18
pom.xml
18
pom.xml
@ -4,14 +4,16 @@
|
||||
|
||||
<groupId>de.muehlencord.mapstruct</groupId>
|
||||
<artifactId>mapstruct-support</artifactId>
|
||||
<version>1.5.5</version>
|
||||
<version>1.6.3</version>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>11</maven.compiler.source>
|
||||
<maven.compiler.target>11</maven.compiler.target>
|
||||
<maven.compiler.release>11</maven.compiler.release>
|
||||
<java.version>21</java.version>
|
||||
<maven.compiler.source>21</maven.compiler.source>
|
||||
<maven.compiler.target>21</maven.compiler.target>
|
||||
<maven.compiler.release>21</maven.compiler.release>
|
||||
|
||||
<mapstruct.version>1.5.5.Final</mapstruct.version>
|
||||
<mapstruct.version>1.6.3</mapstruct.version>
|
||||
<maven-release-plugin.version>3.1.1</maven-release-plugin.version>
|
||||
</properties>
|
||||
|
||||
<inceptionYear>2021</inceptionYear>
|
||||
@ -38,7 +40,7 @@
|
||||
<scm>
|
||||
<connection>scm:git:https://jomu.timelord.de/git/jomu/mapstruct-support</connection>
|
||||
<developerConnection>scm:git:git@jomu.timelord.de:jomu/mapstruct-support.git</developerConnection>
|
||||
<tag>mapstruct-support-1.5.5</tag>
|
||||
<tag>mapstruct-support-1.6.3</tag>
|
||||
</scm>
|
||||
|
||||
<developers>
|
||||
@ -67,9 +69,9 @@
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<version>3.0.0-M6</version>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
<version>${maven-release-plugin.version}</version>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
Reference in New Issue
Block a user