本文整理汇总了Java中javax.portlet.ResourceURL类的典型用法代码示例。如果您正苦于以下问题:Java ResourceURL类的具体用法?Java ResourceURL怎么用?Java ResourceURL使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ResourceURL类属于javax.portlet包,在下文中一共展示了ResourceURL类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests5_SPEC2_19_IncThenForwardServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests5_SPEC2_19_IncThenForwardServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:25,代码来源:DispatcherTests5_SPEC2_19_IncThenForwardServletResource.java
示例2: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"SigTestsURL_BaseURL_SIGResourceResurl\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(
" document.getElementById(\"SigTestsURL_BaseURL_SIGResourceResurl\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例3: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"SigTestsURL_BaseURL_SIGResourceRenurl\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(
" document.getElementById(\"SigTestsURL_BaseURL_SIGResourceRenurl\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例4: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"SigTestsURL_BaseURL_SIGResourceActurl\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(
" document.getElementById(\"SigTestsURL_BaseURL_SIGResourceActurl\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例5: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherReqRespTests1_SPEC2_19_ForwardJSPResourceResponse\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherReqRespTests1_SPEC2_19_ForwardJSPResourceResponse\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:26,代码来源:DispatcherReqRespTests1_SPEC2_19_ForwardJSPResourceResponse.java
示例6: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests6_SPEC2_19_FwdThenForwardServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests6_SPEC2_19_FwdThenForwardServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:25,代码来源:DispatcherTests6_SPEC2_19_FwdThenForwardServletResource.java
示例7: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests6_SPEC2_19_FwdThenIncludeServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests6_SPEC2_19_FwdThenIncludeServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:25,代码来源:DispatcherTests6_SPEC2_19_FwdThenIncludeServletResource.java
示例8: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
PrintWriter writer = portletResp.getWriter();
writer.write(
"<div id=\"AnnotationPortletConfigTests_SPEC2_28_AsynchronousSupport\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(
" document.getElementById(\"AnnotationPortletConfigTests_SPEC2_28_AsynchronousSupport\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(
" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:26,代码来源:AnnotationPortletConfigTests_SPEC2_28_AsynchronousSupport.java
示例9: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests_SPEC2_19_DispatchServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests_SPEC2_19_DispatchServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例10: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests_SPEC2_19_ForwardServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests_SPEC2_19_ForwardServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例11: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests_SPEC2_19_IncludeServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests_SPEC2_19_IncludeServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例12: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"ResponseTests_MimeResponse_ApiResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(ResourceURL.PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"ResponseTests_MimeResponse_ApiResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
示例13: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherReqRespTests4_SPEC2_19_IncludeServletResourceResponse\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherReqRespTests4_SPEC2_19_IncludeServletResourceResponse\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:26,代码来源:DispatcherReqRespTests4_SPEC2_19_IncludeServletResourceResponse.java
示例14: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp)
throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherReqRespTests3_SPEC2_19_IncludeJSPResourceResponse\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherReqRespTests3_SPEC2_19_IncludeJSPResourceResponse\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:26,代码来源:DispatcherReqRespTests3_SPEC2_19_IncludeJSPResourceResponse.java
示例15: render
import javax.portlet.ResourceURL; //导入依赖的package包/类
@Override
public void render(RenderRequest portletReq, RenderResponse portletResp) throws PortletException, IOException {
long tid = Thread.currentThread().getId();
portletReq.setAttribute(THREADID_ATTR, tid);
PrintWriter writer = portletResp.getWriter();
writer.write("<div id=\"DispatcherTests5_SPEC2_19_IncThenIncludeServletResource\">no resource output.</div>\n");
ResourceURL resurl = portletResp.createResourceURL();
resurl.setCacheability(PAGE);
writer.write("<script>\n");
writer.write("(function () {\n");
writer.write(" var xhr = new XMLHttpRequest();\n");
writer.write(" xhr.onreadystatechange=function() {\n");
writer.write(" if (xhr.readyState==4 && xhr.status==200) {\n");
writer.write(" document.getElementById(\"DispatcherTests5_SPEC2_19_IncThenIncludeServletResource\").innerHTML=xhr.responseText;\n");
writer.write(" }\n");
writer.write(" };\n");
writer.write(" xhr.open(\"GET\",\"" + resurl.toString() + "\",true);\n");
writer.write(" xhr.send();\n");
writer.write("})();\n");
writer.write("</script>\n");
}
开发者ID:apache,项目名称:portals-pluto,代码行数:25,代码来源:DispatcherTests5_SPEC2_19_IncThenIncludeServletResource.java