private void buildNewInstanceMethodForConstructorOrFactoryMethodDelegation ( MethodSpec . Builder newInstanceMethodBuilder , MethodSpec createMethod ) { String param = String . format ( "%s%s.deserialize(reader, ctx)" , INSTANCE_BUILDER_DESERIALIZER_PREFIX , String . format ( INSTANCE_BUILDER_VARIABLE_FORMAT , 0 ) ) ; newInstanceMethodBuilder . addStatement ( "return new $T($N($L), bufferedProperties)" , parameterizedName ( Instance . class , beanInfo . getType ( ) ) , createMethod , param ) ; }
Generate the instance builder class body for a constructor or factory method with delegation .