Filip Hrisafov
710f8e67fc
[maven-release-plugin] prepare for next development iteration
2021-01-31 13:49:15 +01:00
Filip Hrisafov
1ca7c7b5c8
[maven-release-plugin] prepare release 1.4.2.Final
2021-01-31 13:49:14 +01:00
Filip Hrisafov
bef3482af5
#2250 , #2324 Do not throw error when qualifier is missing on iterable mapping
...
With this change we are relaxing the error handling when qualifiers are used in `@Mapping`
and we allow defining qualifiers for collections / array mapping to mean the same as if it was defined on `@IterableMapping`
i.e. apply the qualifier on the element mapping
2021-01-31 12:46:15 +01:00
Sjaak Derksen
0c51f7a5aa
#2278 inherited property ignored due to ignore on nested level ( #2332 )
...
Co-authored-by: sjaakd <sjaakderksen@zonnet.nl>
2021-01-31 12:39:56 +01:00
Filip Hrisafov
15b3469f04
#2301 Implicitly ignore forward inherited mappings from different method types
2021-01-31 12:39:39 +01:00
Filip Hrisafov
e6479dce87
#2293 Use MapperConfig instead of MappingConfig in the documentation
2021-01-31 12:39:25 +01:00
Filip Hrisafov
628ff175e0
#2253 remove unmapped source properties when source parameter is directly mapped
2020-11-08 10:04:31 +01:00
Filip Hrisafov
934d096fb4
#2263 Fix IndexOutOfBoundsException when resolving TypeVar to a Type
2020-11-08 10:04:27 +01:00
Filip Hrisafov
e8713fb432
#2251 Fix incorrect code generated for constructor mapping from implicit source parameter matching
2020-11-01 17:17:56 +01:00
Filip Hrisafov
b90c0a9f07
#2244 Mark mapstruct-processor jar as Spring-Boot-Jar-Type: annotation-processor
...
Doing this would make sure that starting from Spring Boot 2.4 the mapstruct-processor will not be included in the fat jar produced by the Spring Boot maven plugin if people have it as a maven provided dependency.
This is an alternative if people are not using the maven-compiler-plugin annotationProcessorPaths
2020-11-01 17:17:40 +01:00
Filip Hrisafov
7e16aa05c0
#2245 Local variable should be created when using default value
2020-11-01 17:17:29 +01:00
Filip Hrisafov
74d06fea5d
#2233 Allow generic of generics in types when matching
...
e.g. method signature such as
<T> T fromOptional(Optional<T> optional)
when T resolves to another generic class such as Collection<String>
2020-10-21 17:00:05 +02:00
Filip Hrisafov
6102d0cc8e
#2236 Different nested target mappings should generate different intermediate methods
...
Make sure that MappingReferences are taken into consideration when comparing whether 2 mapping methods are equal.
This makes sure that when using nested target mappings that have the same property mappings, but different mappings 2 distinct methods will be created
2020-10-18 22:31:08 +02:00
Filip Hrisafov
58dbaee472
[maven-release-plugin] prepare for next development iteration
2020-10-11 09:35:30 +02:00
Filip Hrisafov
d8f22f8311
[maven-release-plugin] prepare release 1.4.1.Final
2020-10-11 09:35:30 +02:00
Filip Hrisafov
53a5c34ed6
#2206 , #2214 , #2220 : Source property should be correctly determined when only target is defined
...
When having multiple source properties and only target is defined then the same rules should be applied as if there was no mapping:
* First we check for a matching property in any of the source type
* Second we check if the parameter name matches
2020-10-10 09:44:01 +02:00
Filip Hrisafov
a5f49e591e
#2221 : Fix configuration inheritance when there are multiple matching source parameters of the same type
2020-10-10 09:43:30 +02:00
Filip Hrisafov
823b5edd9f
#2213 : primitive arrays should be directly mapped (we are cloning them anyways)
...
Additionally fix problem when annotations `ElementType.TYPE_USE` not handled correctly for javac
2020-10-03 16:54:01 +02:00
Filip Hrisafov
233fc6de98
#2215 : Avoid NPE in IntelliJ EAP 2020.3
...
Starting from IntelliJ 2020.3 (Build 203.4203.26) the ProcessingEnvironment is wrapped in a Proxy class by IntelliJ.
MapStruct should gracefully handle that and not throw an NPE.
Additionally, we should do best effort to put the used compiler in the generated annotation info
2020-10-03 16:47:31 +02:00
Jasper Vandemalle
4480e0f367
Fix minor typos
2020-10-03 00:35:28 +02:00
Filip Hrisafov
eb5b8bb71e
[maven-release-plugin] prepare for next development iteration
2020-09-26 10:20:47 +02:00
Filip Hrisafov
9973b92ccb
[maven-release-plugin] prepare release 1.4.0.Final
2020-09-26 10:20:45 +02:00
Filip Hrisafov
060f17e3e2
#2125 Report an error when source parameter could not be determined from target mapping
2020-09-21 07:55:45 +02:00
Filip Hrisafov
e17e744b20
Dependency upgrades
...
Upgrades:
* Maven Enforcer Plugin to 3.0.0-M3
* Maven Surefire Plugin to 3.0.0-M5
* Maven Checkstyle Plugin to 3.1.1
* Maven Bundle Plugin to 5.1.1
* Jacoco Maven Plugin to 0.8.6
* Checkstyle to 8.36.1
* JUnit Jipiter to 5.7.0
* AssertJ to 3.17.2
* Guava to 29.0-jre
Fix AssertJ breaking changes
Use Java 8 or Apache Commons IO instead of Guava where possible
Update GitHub Actions to use JDK 14 and JDK 15-ea
2020-09-20 11:37:23 +02:00
Filip Hrisafov
52ab22bbd8
#2197 Strip leading underscores and digits when sanitizing identifier name
2020-09-20 09:46:41 +02:00
Sjaak Derksen
427f5023ef
#2195 @Beanmapping#resultType should be used to construct return type also if it's a builder ( #2196 )
2020-09-06 16:12:01 +02:00
Filip Hrisafov
8b22654abd
[maven-release-plugin] prepare for next development iteration
2020-08-30 16:31:45 +02:00
Filip Hrisafov
c962962546
[maven-release-plugin] prepare release 1.4.0.CR1
2020-08-30 16:31:44 +02:00
Sjaak Derksen
e0eb0f6bb8
#2164 parameter matching should be done based on name when source name is absent ( #2193 )
2020-08-30 12:49:09 +02:00
Filip Hrisafov
7dcbef349d
#2169 Add support for defining a custom unexpected value mapping exception
...
Expose definition via:
* `@EnumMapping`
* `@Mapper`
* `@MapperConfig`
* `EnumMappingStrategy` SPI
Rename `EnumNamingStrategy` to `EnumMappingStrategy`
2020-08-29 13:53:30 +02:00
Filip Hrisafov
a9451b1159
#2185 Fix StackOverflow error when recursive use of mapper in Mapper#uses
2020-08-29 11:56:02 +02:00
Filip Hrisafov
c1feafef4c
#2177 Mapping into a generic class / record with a typed constructor argument should work
2020-08-29 11:22:18 +02:00
Filip Hrisafov
3ce9786cf6
#2174 Forged methods should inherit all thrown exceptions from their property mappings
2020-08-29 08:59:20 +02:00
Filip Hrisafov
ed16d62a91
#2170 Make sure that an import is created for constructor mapping defined variables
2020-08-02 09:36:22 +02:00
Filip Hrisafov
609824037b
#2167 Add missing @since 1.4 to new interfaces, classes and methods
2020-08-01 11:43:46 +02:00
Sjaak Derksen
2e2c20fed7
#2161 use short names instead of FQN's in error messages ( #2166 )
2020-07-24 23:19:47 +02:00
Filip Hrisafov
ef4bfc9aad
[maven-release-plugin] prepare for next development iteration
2020-07-19 18:10:13 +02:00
Filip Hrisafov
1d223284c2
[maven-release-plugin] prepare release 1.4.0.Beta3
2020-07-19 18:10:12 +02:00
Filip Hrisafov
0495cb7fa7
#2149 Do not allow using BeanMapping(ignoreByDefault = true) in combination with Mapping(target = ".")
...
This fixes an ArrayIndexOutOfBoundsException when they were used together
2020-07-19 16:19:52 +02:00
Filip Hrisafov
28017e2b0c
Add test case for demonstrating how the ignoreByDefault can be overridden from the base configuration
2020-07-19 16:19:52 +02:00
Sjaak Derksen
36349c49e9
#2156 ambiguous mapping message: location and limit # candidates ( #2162 )
2020-07-19 15:40:30 +02:00
Filip Hrisafov
cb432fa61b
#2150 Change the rules for how a constructor for mapping is picked
...
New rules:
1. Constructor annotated with @Default (from any package) has highest precedence
2. If there is a single public constructor then it would be used to construct the object
3. If a parameterless constructor exists then it would be used to construct the object, and the other constructors will be ignored
2020-07-18 18:53:32 +02:00
Filip Hrisafov
6aa39ff428
#2142 : Strip leading underscore when sanitizing identifier name
2020-07-18 11:35:25 +02:00
Sjaak Derksen
2a849dca12
#2145 fixing 2 step mapping methods (refactoring) ( #2146 )
2020-07-18 01:12:21 +02:00
Sjaak Derksen
74f281fa3e
#2135 improved messages for not able to select qualified method ( #2141 )
...
* #2135 improved messages for not able to select qualified method
2020-07-18 01:12:15 +02:00
Sjaak Derksen
c0d88f86bf
#2139 reproducer ( #2140 )
...
* #2139 reproducer
* #2139 solution
* #2139 license
2020-07-18 01:12:11 +02:00
Filip Hrisafov
2fede3583d
[maven-release-plugin] prepare for next development iteration
2020-07-18 01:12:05 +02:00
Filip Hrisafov
fc4f65ddb6
[maven-release-plugin] prepare release 1.4.0.Beta2
2020-07-05 23:11:41 +02:00
Sjaak Derksen
12ac348609
#2136 performance improvement 2 step mappings ( #2138 )
2020-07-04 22:06:30 +02:00
Sjaak Derksen
1ce282362c
#2101 inherited properties need to be analysed against redefined properties when inheriting mappings ( #2103 )
2020-07-04 21:50:20 +02:00