{"hidden":false,"children":[{"configs":{"itemId":"module"},"expanded":true,"children":[{"configs":{"quoted":"true","itemId":"text","js":"response.setCharacterEncoding('utf-8');\n//使用response.getWriter()或response.getOutputStream()获取writer/outputStream输出数据后，\n//必须使用response.flushBuffer();显式提交。否则系统会尝试再次获取outputStream来输出模块的框架脚本而抛出\n//\"getWriter() has already been called for this response\" 异常。\nresponse.getWriter().print('text');\nresponse.flushBuffer(); //必须使用此方法立即提交\n//输出数据在ServerScript中建议使用\napp.send(anyObject);\n//输出数据在Java中建议使用\nWebUtil.send(response, anyObject);\n//使用writer.println和app.send提交的区别为前者通过writer可分批输出，后者为一次性提交（并具有gzip压缩等功能，效率高）\n// app.send('Client Script');\n// app.send(inputStream);\n// app.send(bytes);\n// app.send(object);"},"expanded":false,"children":[],"type":"string"},{"configs":{"layout":"fit","itemId":"viewport1"},"expanded":true,"children":[{"configs":{"itemId":"xwl1","file":"m?xwl=sys/dialog/dev/script-editor"},"expanded":false,"children":[],"type":"xwl"}],"type":"viewport","events":{"afterrender":"app.xwl1.setValue(\"{#text#}\", null, true);"}}],"type":"module"}],"roles":{"default":1,"demo":1},"title":"输出至客户端","iconCls":"","inframe":false,"pageLink":""}