本文整理了Java中org.apache.catalina.Context.getEncodedPath()
方法的一些代码示例,展示了Context.getEncodedPath()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Context.getEncodedPath()
方法的具体详情如下:
包路径:org.apache.catalina.Context
类名称:Context
方法名:getEncodedPath
[英]Return the URL encoded context path, using UTF-8.
[中]使用UTF-8返回URL编码的上下文路径。
代码示例来源:origin: org.osivia.portal.core/osivia-portal-jbossas-jbossweb-lib
/* */ protected void configureSessionCookie(Cookie cookie)
/* */ {
/* 2339 */ cookie.setMaxAge(-1);
/* 2340 */ String contextPath = null;
/* 2341 */ if ((!this.connector.getEmptySessionPath()) && (getContext() != null)) {
/* 2342 */ contextPath = getContext().getEncodedPath();
/* */ }
/* 2344 */ if ((contextPath != null) && (contextPath.length() > 0))
/* 2345 */ cookie.setPath(contextPath);
/* */ else {
/* 2347 */ cookie.setPath("/");
/* */ }
/* 2349 */ if (isSecure())
/* 2350 */ cookie.setSecure(true);
/* */ }
/* */
代码示例来源:origin: tomcat/catalina
/**
* Configures the given JSESSIONID cookie.
*
* @param cookie The JSESSIONID cookie to be configured
*/
protected void configureSessionCookie(Cookie cookie) {
cookie.setMaxAge(-1);
String contextPath = null;
if (!connector.getEmptySessionPath() && (getContext() != null)) {
contextPath = getContext().getEncodedPath();
}
if ((contextPath != null) && (contextPath.length() > 0)) {
cookie.setPath(contextPath);
} else {
cookie.setPath("/");
}
if (isSecure()) {
cookie.setSecure(true);
}
}
代码示例来源:origin: stackoverflow.com
contextPath = ctxt.getSessionCookiePath();
} else {
contextPath = ctxt.getEncodedPath();
代码示例来源:origin: org.apache.tomcat/tomcat-catalina
contextPath = context.getEncodedPath();
代码示例来源:origin: codefollower/Tomcat-Research
contextPath = context.getEncodedPath();
代码示例来源:origin: org.apache.geronimo.ext.tomcat/catalina
contextPath = context.getEncodedPath();
代码示例来源:origin: com.ovea.tajin.server/tajin-server-tomcat7
contextPath = context.getEncodedPath();
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
contextPath = context.getEncodedPath();
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
contextPath = context.getEncodedPath();
代码示例来源:origin: org.apache.catalina/com.springsource.org.apache.catalina
contextPath = context.getEncodedPath();
代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core
contextPath = context.getEncodedPath();
代码示例来源:origin: jboss.web/jbossweb
cookie.setPath(context.getSessionCookie().getPath());
} else {
String contextPath = context.getEncodedPath();
if ("".equals(contextPath)) {
contextPath = "/";
代码示例来源:origin: org.jboss.jbossas/jboss-as-tomcat
String contextPath = context.getEncodedPath();
if ("".equals(contextPath))
代码示例来源:origin: org.jboss.web/jbossweb
cookie.setPath(context.getSessionCookie().getPath());
} else {
String contextPath = context.getEncodedPath();
if ("".equals(contextPath)) {
contextPath = "/";
代码示例来源:origin: com.tomitribe.tribestream/tribestream-container
request.getMethod(),
request.getContextPath(),
request.getContext().getEncodedPath(),
request.getRequestURI(),
String.valueOf(request.getRequestURL()),
代码示例来源:origin: codefollower/Tomcat-Research
urlString.insert(0, request.getContext().getEncodedPath());
代码示例来源:origin: jboss.web/jbossweb
urlString.insert(0, request.getContext().getEncodedPath());
代码示例来源:origin: org.jboss.web/jbossweb
urlString.insert(0, request.getContext().getEncodedPath());
代码示例来源:origin: org.apache.tomcat/tomcat-catalina
urlStringEncoded.insert(0, request.getContext().getEncodedPath());
代码示例来源:origin: org.ops4j.pax.tipi/org.ops4j.pax.tipi.tomcat-embed-core
urlStringEncoded.insert(0, request.getContext().getEncodedPath());
内容来源于网络,如有侵权,请联系作者删除!