When writing custom code, it's handy to be able to pass basic types and let something generate a CodeBlock
for us. Having to deal with the attribute being null
(and then writing null
) is also something that should be reusable.
Comment From: snicoll
Perhaps a ValueCodeGenerator
interface with a default implementation that can load customizations from the classpath could a good first step. Looking at this need, it matches what #31427 is requesting. Devil in the details if we move this to spring-core
I am sure but we'll see how far we can go.