Open uglycustard opened 9 years ago
E.g.:
ClassOne {
ClassTwo propClassTwo
}
ClassTwo (abstract) {
ClassThree propClassThree
}
ClassThree {
String prop
}
Possible solutions:
ClassOneBuilder
withPropClassTwo(Builder<ClassTwo> propClassTwo)
ClassThreeBuilder
withProp(String prop)
i.e. still traverse the properties of the abstract class for other classes that a builder could be generated for, but don't generate a builder for the abstract class?
or
generate a builder for the abstract class, but make it abstract also with an abstract method that returns an instance of the target class - therefore any non-abstract properties on that abstract class can have a with method generated in the abstract builder allowing sub classes to supply the implementation.
BG is generating builder for abstract class which doesn't compile as it cannot be constructed without specifying a class body.