public final class RequestContextExporter extends Object
RequestContext to Map.| Modifier and Type | Method and Description |
|---|---|
Map<String,io.netty.util.AttributeKey<?>> |
attributes()
Returns all
AttributeKeys in the export list. |
static RequestContextExporterBuilder |
builder()
Returns a newly created
RequestContextExporterBuilder. |
Set<BuiltInProperty> |
builtIns()
Returns all
BuiltInPropertys in the export list. |
boolean |
containsAttribute(io.netty.util.AttributeKey<?> key)
Returns
true if the specified AttributeKey is in the export list. |
boolean |
containsBuiltIn(BuiltInProperty property)
Returns
true if the specified BuiltInProperty is in the export list. |
boolean |
containsHttpRequestHeader(CharSequence name)
Returns
true if the specified HTTP request header name is in the export list. |
boolean |
containsHttpResponseHeader(CharSequence name)
Returns
true if the specified HTTP response header name is in the export list. |
Map<String,String> |
export()
Returns a
Map whose key is an export key set through add*() in
RequestContextExporterBuilder and value is extracted from RequestContext. |
Map<String,String> |
export(RequestContext ctx)
Returns a
Map whose key is an export key set through add*() in
RequestContextExporterBuilder and value is extracted from the specified RequestContext. |
Set<io.netty.util.AsciiString> |
httpRequestHeaders()
Returns all HTTP request header names in the export list.
|
Set<io.netty.util.AsciiString> |
httpResponseHeaders()
Returns all HTTP response header names in the export list.
|
public static RequestContextExporterBuilder builder()
RequestContextExporterBuilder.public boolean containsAttribute(io.netty.util.AttributeKey<?> key)
true if the specified AttributeKey is in the export list.public boolean containsHttpRequestHeader(CharSequence name)
true if the specified HTTP request header name is in the export list.public boolean containsHttpResponseHeader(CharSequence name)
true if the specified HTTP response header name is in the export list.public boolean containsBuiltIn(BuiltInProperty property)
true if the specified BuiltInProperty is in the export list.public Set<BuiltInProperty> builtIns()
BuiltInPropertys in the export list.public Map<String,io.netty.util.AttributeKey<?>> attributes()
AttributeKeys in the export list.Map whose key is an alias and value is an AttributeKeypublic Set<io.netty.util.AsciiString> httpRequestHeaders()
public Set<io.netty.util.AsciiString> httpResponseHeaders()
public Map<String,String> export()
Map whose key is an export key set through add*() in
RequestContextExporterBuilder and value is extracted from RequestContext.
Note that this method returns an empty Map if current RequestContext is null.public Map<String,String> export(RequestContext ctx)
Map whose key is an export key set through add*() in
RequestContextExporterBuilder and value is extracted from the specified RequestContext.Copyright © 2020 LeanCloud. All rights reserved.