cbarlin / cbarlin/advanced-record-utils
Generate sealed interface structure for builder
- Dominant language
- Java
- Stars
- 3
- Forks
- 0
- Avg merge
- 1m
- Merged PRs (30d)
- 5
Description
I was thinking about how best to enforce that a potential `StagedBuilder` and/or `SetOnlyOnceBuilder` allows everything that the base `Builder` allows ( e.g. If a user has `setTimeToNow` methods enabled that should be on all builders).
Current thinking:
- each component of the original record generates an interface that defines all the builder operations that need to be implemented
- the interface structure is sealed so it must be implemented and can't be externally used
- it should probably be as private as possible so it's not as impactful on end-users
This could also be used to:
- have an option like `builderInterface` which takes in a name and list of records that will share a common interface
Contributor guide
Assessment
This issue has not been assessed yet.