org.eclipse.jetty.server.Request.setQueryString()方法的使用及代码示例

x33g5p2x  于2022-01-28 转载在 其他  
字(5.6k)|赞(0)|评价(0)|浏览(146)

本文整理了Java中org.eclipse.jetty.server.Request.setQueryString方法的一些代码示例,展示了Request.setQueryString的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Request.setQueryString方法的具体详情如下:
包路径:org.eclipse.jetty.server.Request
类名称:Request
方法名:setQueryString

Request.setQueryString介绍

暂无

代码示例

代码示例来源:origin: org.eclipse.jetty/jetty-rewrite

/**
 * This method will add _query to the requests's queryString and also combine it with existing queryStrings in
 * the request. However it won't take care for duplicate. E.g. if request.getQueryString contains a parameter
 * <code>param1 = true</code> and _query will contain <code>param1=false</code> the result will be <code>param1=true&amp;param1=false</code>.
 * To cover this use case some more complex pattern matching is necessary. We can implement this if there's use
 * cases.
 *
 * @param request the request
 * @param oldURI the old URI
 * @param newURI the new URI
 * @throws IOException if unable to apply the URI
 */
@Override
public void applyURI(Request request, String oldURI, String newURI) throws IOException
{
  if (_query == null)
  {
    request.setURIPathQuery(newURI);
  }
  else
  {
    String queryString = request.getQueryString();
    if (queryString != null)
      queryString = queryString + "&" + _query;
    else
      queryString = _query;
    request.setURIPathQuery(newURI);
    request.setQueryString(queryString);
  }
}

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server

_request.setUri(new HttpURI(uri));
_request.setPathInfo(outerRequest.getRequestURI());
_request.setQueryString(outerRequest.getQueryString());
_request.setProtocol(outerRequest.getProtocol());

代码示例来源:origin: Nextdoor/bender

setQueryString(mergedQuery.toString());

代码示例来源:origin: at.bestsolution.efxclipse.eclipse/org.eclipse.jetty.server

setQueryString(oldQuery);
else if (oldQuery==null)
  setQueryString(newQuery);
else
  setQueryString(mergedQuery.toString());

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server

setQueryString(query);

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp

setQueryString(query);

代码示例来源:origin: org.eclipse.jetty/server

setQueryString(query);

代码示例来源:origin: org.eclipse.jetty/jetty-rewrite

@Override
public void applyURI(Request request, String oldURI, String newURI) throws IOException
{
  if (_query==null)
  {
    request.setURIPathQuery(newURI);
  }
  else
  {
    String query=(String)request.getAttribute("org.eclipse.jetty.rewrite.handler.RewriteRegexRule.Q");
    
    if (!_queryGroup && request.getQueryString()!=null)
      query=request.getQueryString()+"&"+query;
    request.setURIPathQuery(newURI);
    request.setQueryString(query);
  }
}

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server

setQueryString(query);

代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9

setQueryString(query);

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server

public void applyURI(Request request, String oldTarget, String newTarget) throws IOException
{
  if (_query==null)
  {
    request.setRequestURI(newTarget);
  }
  else
  {
    String query=(String)request.getAttribute("org.eclipse.jetty.rewrite.handler.RewriteRegexRule.Q");
    
    if (!_queryGroup && request.getQueryString()!=null)
      query=request.getQueryString()+"&"+query;
    HttpURI uri=new HttpURI(newTarget+"?"+query);
    request.setUri(uri);
    request.setRequestURI(newTarget);
    request.setQueryString(query);
  }
}

代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9

@Override
public void applyURI(Request request, String oldTarget, String newTarget) throws IOException
{
  if (_query==null)
  {
    request.setRequestURI(newTarget);
  }
  else
  {
    String query=(String)request.getAttribute("org.eclipse.jetty.rewrite.handler.RewriteRegexRule.Q");
    
    if (!_queryGroup && request.getQueryString()!=null)
      query=request.getQueryString()+"&"+query;
    HttpURI uri=new HttpURI(newTarget+"?"+query);
    request.setUri(uri);
    request.setRequestURI(newTarget);
    request.setQueryString(query);
  }
}

代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9

setQueryString(query);

代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9

@Override
public void applyURI(Request request, String oldTarget, String newTarget) throws IOException
{
  if (_query==null)
  {
    request.setRequestURI(newTarget);
  }
  else
  {
    String query=(String)request.getAttribute("org.eclipse.jetty.rewrite.handler.RewriteRegexRule.Q");
    
    if (!_queryGroup && request.getQueryString()!=null)
      query=request.getQueryString()+"&"+query;
    HttpURI uri=new HttpURI(newTarget+"?"+query);
    request.setUri(uri);
    request.setRequestURI(newTarget);
    request.setQueryString(query);
  }
}

代码示例来源:origin: Nextdoor/bender

baseRequest.setServletPath(old_servlet_path);
baseRequest.setPathInfo(old_path_info);
baseRequest.setQueryString(old_query);
baseRequest.setQueryParameters(old_query_params);
baseRequest.resetParameters();

代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9

baseRequest.setAttributes(old_attr);
baseRequest.setParameters(old_params);
baseRequest.setQueryString(old_query);
baseRequest.setDispatcherType(old_type);

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp

baseRequest.setAttributes(old_attr);
baseRequest.setParameters(old_params);
baseRequest.setQueryString(old_query);
baseRequest.setDispatcherType(old_type);

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus

baseRequest.setAttributes(old_attr);
baseRequest.setParameters(old_params);
baseRequest.setQueryString(old_query);
baseRequest.setDispatcherType(old_type);

代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server

baseRequest.setAttributes(old_attr);
baseRequest.setParameters(old_params);
baseRequest.setQueryString(old_query);
baseRequest.setDispatcherType(old_type);

代码示例来源:origin: org.eclipse.jetty/server

baseRequest.setAttributes(old_attr);
baseRequest.setParameters(old_params);
baseRequest.setQueryString(old_query);
baseRequest.setDispatcherType(old_type);

相关文章

Request类方法