Map<String, Object> model = new HashMap<>();
model.put("devHost", devHost);
model.put("devPort", devPort);
FileObject sourceFile = filer.createResource(
StandardLocation.SOURCE_OUTPUT, "", "gwt-proxy.properties");
OutputStream output1 = sourceFile.openOutputStream();
FileObject sourceFile2 = filer.createResource(
StandardLocation.SOURCE_OUTPUT, "", "upload-proxy.properties");
OutputStream output2 = sourceFile2.openOutputStream();
FileObject sourceFile3 = filer.createResource(
StandardLocation.SOURCE_OUTPUT, "", "patch-proxy.properties");
OutputStream output3 = sourceFile3.openOutputStream();
FileObject sourceFile4 = filer.createResource(
StandardLocation.SOURCE_OUTPUT, "", "logout.properties");
OutputStream output4 = sourceFile4.openOutputStream();
new TemplateProcessor().process("gwt.proxy.tmpl", model, output1);
new TemplateProcessor().process("gwt.proxy.upload.tmpl", model, output2);
new TemplateProcessor().process("gwt.proxy.patch.tmpl", model, output3);
new TemplateProcessor().process("gwt.proxy.logout.tmpl", model, output4);