String (@NotNull String singularName, @NotNull BuilderInfo info) { final String codeBlockTemplate = """ if({0}==null)'{'throw new NullPointerException("{0} cannot be null");'}' if (this.{0} == null) this.{0} = {1}.{2};\s this.{0}.addAll({0}); return {3};"""; return MessageFormat.format(codeBlockTemplate, singularName, typeCollectionQualifiedName, sortedCollection ? "naturalOrder()" : "builder()", info.getBuilderChainResult()); }