Jordan Zimmerman
4ff80fb20c
[maven-release-plugin] prepare for next development iteration
2022-08-02 05:05:19 +02:00
Jordan Zimmerman
abfc12bdb0
[maven-release-plugin] prepare release record-builder-34
record-builder-34
2022-08-02 05:05:14 +02:00
Jordan Zimmerman
6c0fac0dff
[maven-release-plugin] rollback the release of record-builder-34
2022-08-02 05:04:43 +02:00
Jordan Zimmerman
ae527cd8e5
[maven-release-plugin] prepare release record-builder-34
2022-08-02 05:04:20 +02:00
Jordan Zimmerman
73ba62057a
[maven-release-plugin] rollback the release of record-builder-34
2022-08-02 05:03:00 +02:00
Jordan Zimmerman
87998aba68
[maven-release-plugin] prepare for next development iteration
2022-08-02 05:02:28 +02:00
Jordan Zimmerman
04a0904d3f
[maven-release-plugin] prepare release record-builder-34
2022-08-02 05:02:23 +02:00
Johannes
aa072af8e1
Performance feature: copy collections only when they were changed. Fixes #114 . ( #118 )
2022-06-19 21:17:09 +01:00
Jordan Zimmerman
b435b5d3fd
Revert "TYPE_USE annotations were being ignored ( #115 )"
...
This reverts commit d3c1bb36f3 .
A bug was found - the PR needs more work
2022-06-13 08:37:24 +01:00
Jordan Zimmerman
d3c1bb36f3
TYPE_USE annotations were being ignored (#115 )
...
Java's DAG for annotations processors doesn't contain `TYPE_USE` annotations
on the Element for some reason. However, they are on the type. So, use the
type instead.
Note due to limitations of JavaPoet this doesn't fix `TYPE_USE` annotations on
parameterized types or array components. If we want to address those we will need
changes in JavaPoet which has been dormant for a very long time.
Fixes #113
Relates to #111
2022-06-12 08:56:32 +01:00
Lovro Pandžić
c3719326c9
Use Optional.ofNullable() to check for null values
...
Fixes #107
2022-05-10 16:06:12 +01:00
Jordan Zimmerman
661d0818c0
_FromWith class was missing @Generated on methods/ctor
2022-04-08 09:15:59 +01:00
Jordan Zimmerman
79bc8396f2
Update README.md
2022-04-08 09:03:30 +01:00
Jordan Zimmerman
b2149622e4
Update README.md
2022-04-08 09:01:07 +01:00
Jordan Zimmerman
0718e37f76
[maven-release-plugin] prepare for next development iteration
2022-04-08 08:35:12 +01:00
Jordan Zimmerman
d112a1b352
[maven-release-plugin] prepare release record-builder-33
record-builder-33
2022-04-08 08:35:07 +01:00
Jordan Zimmerman
86093b6bad
Make the functional static builder optional ( #105 )
...
Closes #100
2022-04-08 08:33:46 +01:00
Jordan Zimmerman
7b6ad4d7ba
Generated equals() and the default with() method were missing generic angle brackets causing compiler warnings ( #102 )
...
Closes #101
2022-04-08 08:29:55 +01:00
Jordan Zimmerman
cd059f1207
Options/changes so that Jacoco checks don't fail ( #104 )
...
- Added new optional Annotation `@RecordBuilderGenerated` - Jacoco ignores
classes with any annotation names "*Generated*" but it needs to be class retained.
For backward compatibility this annotation is not added by default (though it's been
added to `@RecordBuilderFull`). There is a new option to enable it.
- The from with method now uses an internal static class instead of an anonymous
inner class so that the annotation can be on this as well. This new class's name
is configurable in the options.
Thanks to user @madisparn for initial PR and issue report.
Fixes #87
2022-04-07 12:21:50 +01:00
Jordan Zimmerman
642dd01421
Don't include @Valid on base interfaces ( #99 )
...
The validation API doesn't accept `@Valid` on base interfaces. Filter
them out.
Fixes #97
2022-03-21 10:06:02 +00:00
Mads Baardsgaard
efd1a6b0d4
Add flag to add concrete setters for optionals ( #94 )
...
* Add flag to add concrete setters for optionals
* Add another test with concrete optionals disabled
2022-03-21 09:08:00 +00:00
Mads Baardsgaard
b525eddc76
Make withers and getters optional features ( #95 )
...
* Make withers and getters optional features
* Add example record with wither and getter disabled
2022-03-21 08:51:42 +00:00
Jordan Zimmerman
d3828eda74
Fix NPE for uninitialized non-null collection ( #98 )
...
Closes #91
Co-authored-by: Clément MATHIEU <clement@unportant.info >
2022-03-20 10:46:39 +00:00
Jordan Zimmerman
fef69af183
[maven-release-plugin] prepare for next development iteration
2022-02-04 11:45:10 +00:00
Jordan Zimmerman
99f9639b82
[maven-release-plugin] prepare release record-builder-32
record-builder-32
2022-02-04 11:45:05 +00:00
Mads Baardsgaard
43bc65e258
Add configurable method name prefixes to builders ( #86 )
...
Add configurable Bean interface to add prefixed getters to record
2022-02-02 17:44:57 +00:00
Jordan Zimmerman
bae1b771b7
[maven-release-plugin] prepare for next development iteration
2022-01-25 11:06:05 +00:00
Jordan Zimmerman
1dd00b2c65
[maven-release-plugin] prepare release record-builder-31
record-builder-31
2022-01-25 11:06:01 +00:00
Jordan Zimmerman
3b34b5dee3
[maven-release-plugin] prepare for next development iteration
2022-01-25 10:59:50 +00:00
Jordan Zimmerman
7248bad2bd
[maven-release-plugin] prepare release record-builder-30
record-builder-30
2022-01-25 10:59:45 +00:00
Jordan Zimmerman
7e494d8753
Optional functional methods for With
...
When enabled, some functional methods are added to the `With` nested
class.
E.g.
```java
@RecordBuilder
record MyRecord<T>(String name, T value, int qty) implements MyRecordBuilder.With<T> {}
...
MyRecord<Thing> r = ...
var other = r.map((name, value, qty) -> new Other(...));
```
2022-01-22 09:17:15 +00:00
Madis Pärn
3954499d4b
Allow components stream method to work with null fields ( #85 )
...
Co-authored-by: Madis Parn <madis.parn@topia.com >
2022-01-22 07:56:39 +00:00
Jordan Zimmerman
13959dee2a
[maven-release-plugin] prepare for next development iteration
2021-11-03 08:51:54 +00:00
Jordan Zimmerman
af759c0570
[maven-release-plugin] prepare release record-builder-29
record-builder-29
2021-11-03 08:51:47 +00:00
Jordan Zimmerman
9a7d73e78c
Support options on includes
2021-11-03 08:44:51 +00:00
Jordan Zimmerman
3b8c3ff9e3
Remove Java 15 support
...
Java 15 has been EOL for a while now. No need to continue supporting
it.
Closes #78
2021-10-21 19:00:46 +01:00
Jordan Zimmerman
9943667af1
Add support for static from() that returns a Wither
...
Useful for when you can't add the With interface to your record.
Static method takes a record as an argument and returns a With
instance.
2021-10-19 20:24:10 +01:00
Stefan Kuhn
b0c8f10711
fix: build
2021-10-19 19:42:04 +01:00
Stefan Kuhn
0d3c2f37c1
chore: update test to use annotation processor discovery
2021-10-19 19:42:04 +01:00
Stefan Kuhn
eabcb2f179
doc: update maven usage, so that the default annotation processors discovery process is not disabled
2021-10-19 19:42:04 +01:00
Jordan Zimmerman
5fef81191d
[maven-release-plugin] prepare for next development iteration
2021-10-07 10:14:58 +01:00
Jordan Zimmerman
8dbec027e4
[maven-release-plugin] prepare release record-builder-28
record-builder-28
2021-10-07 10:14:53 +01:00
Jordan Zimmerman
ef09d68b78
[maven-release-plugin] prepare for next development iteration
2021-10-07 10:11:59 +01:00
Jordan Zimmerman
0a608f3b20
[maven-release-plugin] prepare release record-builder-27-java15
record-builder-27-java15
2021-10-07 10:11:54 +01:00
Jordan Zimmerman
3494d01b2b
Added link to SingleItemsBuilder gist
2021-10-07 08:35:46 +01:00
Jordan Zimmerman
584bdf4a25
Support single item collection builders
...
When `addSingleItemCollectionBuilders()` is enabled in options, collection types (`List`, `Set` and `Map`)
are handled specially. The setters for these types now create an internal collection and
items are added to that collection. Additionally, "adder" methods prefixed with
`singleItemBuilderPrefix()` are created to add single items to these collections.
Closes #73
2021-10-07 08:35:17 +01:00
Jordan Zimmerman
9268c295fe
Add RecordBuilderFull
...
- Add `@RecordBuilderFull` which will have most optional features enabled
- Change `@RecordBuilder.Template` to be `RetentionPolicy.CLASS`
2021-10-07 08:35:17 +01:00
Jordan Zimmerman
0d2fe2ffe7
Optionally include all records from a list of packages
...
Closes #67
2021-10-07 08:35:17 +01:00
Jordan Zimmerman
71e22042e9
Add Java 17 build
2021-10-07 08:35:17 +01:00
Jordan Zimmerman
3c8e305002
Use Map.entry() instead of AbstractMap.SimpleEntry
...
Closes #68
2021-10-07 08:35:17 +01:00