org.glassfish.grizzly.http.server.Request.getParameterMap()方法的使用及代码示例

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

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

Request.getParameterMap介绍

[英]Returns a java.util.Map of the parameters of this request. Request parameters are extra information sent with the request. For HTTP servlets, parameters are contained in the query string or posted form data.
[中]返回一个java。util。此请求的参数映射。请求参数是随请求发送的额外信息。对于HTTP servlet,参数包含在查询字符串或发布的表单数据中。

代码示例

代码示例来源:origin: javaee/grizzly

@Override
  public Map<String, String[]> run() {
    return request.getParameterMap();
  }        
}

代码示例来源:origin: javaee/grizzly

@Override
  public Map<String, String[]> run() {
    return request.getParameterMap();
  }        
}

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

@Override
  public Map<String, String[]> run() {
    return request.getParameterMap();
  }        
}

代码示例来源:origin: javaee/grizzly

@Override
  public Map<String, String[]> run() {
    return request.getParameterMap();
  }        
}

代码示例来源:origin: javaee/grizzly

@Override
  public Map<String, String[]> run() {
    return request.getParameterMap();
  }        
}

代码示例来源:origin: javaee/grizzly

@Override
  public Map<String, String[]> run() {
    return request.getParameterMap();
  }        
}

代码示例来源:origin: javaee/grizzly

/**
 * {@inheritDoc}
 */
@Override
public Map<String, String[]> getParameterMap() {
  if (request == null) {
    throw new IllegalStateException("Null request object");
  }
  if (System.getSecurityManager() != null){
    return AccessController.doPrivileged(
      new GetParameterMapPrivilegedAction());        
  } else {
    return request.getParameterMap();
  }
}

代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server

/**
 * {@inheritDoc}
 */
@Override
public Map<String, String[]> getParameterMap() {
  if (request == null) {
    throw new IllegalStateException("Null request object");
  }
  if (System.getSecurityManager() != null){
    return AccessController.doPrivileged(
      new GetParameterMapPrivilegedAction());        
  } else {
    return request.getParameterMap();
  }
}

代码示例来源:origin: javaee/grizzly

/**
 * {@inheritDoc}
 */
@Override
public Map<String, String[]> getParameterMap() {
  if (request == null) {
    throw new IllegalStateException("Null request object");
  }
  if (System.getSecurityManager() != null){
    return AccessController.doPrivileged(
      new GetParameterMapPrivilegedAction());        
  } else {
    return request.getParameterMap();
  }
}

代码示例来源:origin: javaee/grizzly

/**
 * {@inheritDoc}
 */
@Override
public Map<String, String[]> getParameterMap() {
  if (request == null) {
    throw new IllegalStateException("Null request object");
  }
  if (System.getSecurityManager() != null){
    return AccessController.doPrivileged(
      new GetParameterMapPrivilegedAction());        
  } else {
    return request.getParameterMap();
  }
}

代码示例来源:origin: javaee/grizzly

/**
 * {@inheritDoc}
 */
@Override
public Map<String, String[]> getParameterMap() {
  if (request == null) {
    throw new IllegalStateException("Null request object");
  }
  if (System.getSecurityManager() != null){
    return AccessController.doPrivileged(
      new GetParameterMapPrivilegedAction());        
  } else {
    return request.getParameterMap();
  }
}

代码示例来源:origin: javaee/grizzly

/**
 * {@inheritDoc}
 */
@Override
public Map<String, String[]> getParameterMap() {
  if (request == null) {
    throw new IllegalStateException("Null request object");
  }
  if (System.getSecurityManager() != null){
    return AccessController.doPrivileged(
      new GetParameterMapPrivilegedAction());        
  } else {
    return request.getParameterMap();
  }
}

代码示例来源:origin: ch.squaredesk.nova/http

private static RequestInfo httpSpecificInfoFrom(Request request) throws Exception {
  Map<String, String> parameters = new HashMap<>();
  for (Map.Entry<String, String[]> entry : request.getParameterMap().entrySet()) {
    String[] valueList = entry.getValue();
    String valueToPass = null;
    if (valueList != null && valueList.length > 0) {
      valueToPass = valueList[0];
    }
    parameters.put(entry.getKey(), valueToPass);
  }
  return new RequestInfo(
      convert(request.getMethod()), parameters);
}

代码示例来源:origin: com.xebialabs.restito/restito

/**
 * Factory method
 */
public static Call fromRequest(final Request request) {
  Call call = new Call();
  call.request = request;
  call.method = request.getMethod();
  call.authorization = request.getAuthorization();
  call.uri = request.getRequestURI();
  call.contentType = request.getContentType();
  call.url = request.getRequestURL().toString();
  for (String headerName : request.getHeaderNames()) {
    List<String> headers = new ArrayList<>();
    request.getHeaders(headerName).forEach(headers::add);
    call.headers.put(headerName, headers);
  }
  call.parameters = new HashMap<>(request.getParameterMap());
  try {
    call.postBody = request.getPostBody(999999).toStringContent(Charset.defaultCharset());
  } catch (IOException e) {
    throw new RuntimeException("Problem reading Post Body of HTTP call");
  }
  return call;
}

代码示例来源:origin: org.activecomponents.jadex/jadex-platform-extension-webservice-desktop-grizzly

targetparams[0] = SInvokeHelper.convertMultiMap(greq.getParameterMap());
((Map<String, String>)targetparams[0]).putAll(extractCallerValues(greq));

相关文章

Request类方法