本文整理了Java中org.eclipse.jetty.util.MultiMap.entrySet()
方法的一些代码示例,展示了MultiMap.entrySet()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。MultiMap.entrySet()
方法的具体详情如下:
包路径:org.eclipse.jetty.util.MultiMap
类名称:MultiMap
方法名:entrySet
暂无
代码示例来源:origin: jphp-group/jphp
@Signature
public Memory queryParameters() {
request.getParameterMap();
MultiMap<String> parameters = request.getQueryParameters();
if (parameters != null) {
ArrayMemory result = ArrayMemory.createHashed(parameters.size());
for (Map.Entry<String, List<String>> entry : parameters.entrySet()) {
List<String> value = entry.getValue();
if (value == null || value.isEmpty()) {
result.putAsKeyString(entry.getKey(), Memory.NULL);
} else if (value.size() == 1) {
result.putAsKeyString(entry.getKey(), StringMemory.valueOf(value.get(0)));
} else {
result.putAsKeyString(entry.getKey(), ArrayMemory.ofStringCollection(value));
}
}
return result;
} else {
return new ArrayMemory().toConstant();
}
}
代码示例来源:origin: org.eclipse.jetty/jetty-util
@Override
public String toString()
Iterator<Entry<String, List<V>>> iter = entrySet().iterator();
StringBuilder sb = new StringBuilder();
sb.append('{');
代码示例来源:origin: org.eclipse.jetty/jetty-util
for(Map.Entry<String,List<V>> entry: entrySet())
代码示例来源:origin: org.eclipse.jetty/jetty-util
for(Map.Entry<String, List<String>> entry: map.entrySet())
代码示例来源:origin: org.eclipse.jetty/jetty-util
/**
* Merge values.
*
* @param map
* the map to overlay on top of this one, merging together values if needed.
* @return true if an existing key was merged with potentially new values, false if either no change was made, or there were only new keys.
*/
public boolean addAllValues(MultiMap<V> map)
{
boolean merged = false;
if ((map == null) || (map.isEmpty()))
{
// done
return merged;
}
for (Map.Entry<String, List<V>> entry : map.entrySet())
{
String name = entry.getKey();
List<V> values = entry.getValue();
if (this.containsKey(name))
{
merged = true;
}
this.addValues(name,values);
}
return merged;
}
代码示例来源:origin: com.yahoo.vespa/jdisc_http_service
private static Map<String, List<String>> getUriQueryParameters(URI uri) {
MultiMap<String> queryParameters = new MultiMap<>();
new HttpURI(uri).decodeQueryTo(queryParameters);
// Do a deep copy so we do not leak Jetty classes outside
Map<String, List<String>> deepCopiedQueryParameters = new HashMap<>();
for (Map.Entry<String, List<String>> entry : queryParameters.entrySet()) {
deepCopiedQueryParameters.put(entry.getKey(), new ArrayList<>(entry.getValue()));
}
return deepCopiedQueryParameters;
}
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
@Override
public String toString()
Iterator<Entry<String, List<V>>> iter = entrySet().iterator();
StringBuilder sb = new StringBuilder();
sb.append('{');
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
@Override
public String toString()
Iterator<Entry<String, List<V>>> iter = entrySet().iterator();
StringBuilder sb = new StringBuilder();
sb.append('{');
代码示例来源:origin: jenkinsci/winstone
@Override
public String toString()
Iterator<Entry<String, List<V>>> iter = entrySet().iterator();
StringBuilder sb = new StringBuilder();
sb.append('{');
代码示例来源:origin: Nextdoor/bender
@Override
public String toString()
Iterator<Entry<String, List<V>>> iter = entrySet().iterator();
StringBuilder sb = new StringBuilder();
sb.append('{');
代码示例来源:origin: Nextdoor/bender
for(Map.Entry<String,List<V>> entry: entrySet())
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
for(Map.Entry<String,List<V>> entry: entrySet())
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
for(Map.Entry<String,List<V>> entry: entrySet())
代码示例来源:origin: jenkinsci/winstone
for(Map.Entry<String,List<V>> entry: entrySet())
代码示例来源:origin: ZapBlasterson/crushpaper
parameters = new HashMap<String, String[]>();
final Iterator<Map.Entry<String, List<String>>> iter = tempParameters
.entrySet().iterator();
while (iter.hasNext()) {
final Map.Entry<String, List<String>> e = iter.next();
代码示例来源:origin: Nextdoor/bender
/**
* Merge values.
*
* @param map
* the map to overlay on top of this one, merging together values if needed.
* @return true if an existing key was merged with potentially new values, false if either no change was made, or there were only new keys.
*/
public boolean addAllValues(MultiMap<V> map)
{
boolean merged = false;
if ((map == null) || (map.isEmpty()))
{
// done
return merged;
}
for (Map.Entry<String, List<V>> entry : map.entrySet())
{
String name = entry.getKey();
List<V> values = entry.getValue();
if (this.containsKey(name))
{
merged = true;
}
this.addValues(name,values);
}
return merged;
}
代码示例来源:origin: com.ovea.tajin.server/tajin-server-jetty9
/**
* Merge values.
*
* @param the
* map to overlay on top of this one, merging together values if needed.
* @return true if an existing key was merged with potentially new values, false if either no change was made, or there were only new keys.
*/
public boolean addAllValues(MultiMap<V> map)
{
boolean merged = false;
if ((map == null) || (map.isEmpty()))
{
// done
return merged;
}
for (Map.Entry<String, List<V>> entry : map.entrySet())
{
String name = entry.getKey();
List<V> values = entry.getValue();
if (this.containsKey(name))
{
merged = true;
}
this.addValues(name,values);
}
return merged;
}
代码示例来源:origin: com.ovea.tajin.servers/tajin-server-jetty9
/**
* Merge values.
*
* @param the
* map to overlay on top of this one, merging together values if needed.
* @return true if an existing key was merged with potentially new values, false if either no change was made, or there were only new keys.
*/
public boolean addAllValues(MultiMap<V> map)
{
boolean merged = false;
if ((map == null) || (map.isEmpty()))
{
// done
return merged;
}
for (Map.Entry<String, List<V>> entry : map.entrySet())
{
String name = entry.getKey();
List<V> values = entry.getValue();
if (this.containsKey(name))
{
merged = true;
}
this.addValues(name,values);
}
return merged;
}
代码示例来源:origin: jenkinsci/winstone
/**
* Merge values.
*
* @param map
* the map to overlay on top of this one, merging together values if needed.
* @return true if an existing key was merged with potentially new values, false if either no change was made, or there were only new keys.
*/
public boolean addAllValues(MultiMap<V> map)
{
boolean merged = false;
if ((map == null) || (map.isEmpty()))
{
// done
return merged;
}
for (Map.Entry<String, List<V>> entry : map.entrySet())
{
String name = entry.getKey();
List<V> values = entry.getValue();
if (this.containsKey(name))
{
merged = true;
}
this.addValues(name,values);
}
return merged;
}
代码示例来源:origin: Nextdoor/bender
for (Map.Entry<String, List<String>> entry : mergedQueryParams.entrySet())
内容来源于网络,如有侵权,请联系作者删除!