public class MapBasedEndpointContext extends AddressEndpointContext
| Modifier and Type | Field and Description |
|---|---|
static String |
KEY_PREFIX_NONE_CRITICAL
Prefix for none critical attributes.
|
ID_TRUNC_LENGTH| Constructor and Description |
|---|
MapBasedEndpointContext(InetSocketAddress peerAddress,
Principal peerIdentity,
Map<String,String> attributes)
Creates a new endpoint context with correlation context support.
|
MapBasedEndpointContext(InetSocketAddress peerAddress,
Principal peerIdentity,
String... attributes)
Creates a context for a socket address, authenticated identity and
arbitrary key/value pairs.
|
MapBasedEndpointContext(InetSocketAddress peerAddress,
String virtualHost,
Principal peerIdentity,
Map<String,String> attributes)
Creates a new endpoint context with correlation context support.
|
MapBasedEndpointContext(InetSocketAddress peerAddress,
String virtualHost,
Principal peerIdentity,
String... attributes)
Creates a context for a socket address, authenticated identity and
arbitrary key/value pairs.
|
| Modifier and Type | Method and Description |
|---|---|
static MapBasedEndpointContext |
addEntries(EndpointContext context,
String... attributes)
Add entries to endpoint context.
|
Map<String,String> |
entries()
Gets a Set of a Map.Entry which contains the key-value pair of the
CorrelationContext.
|
String |
get(String key)
Gets a value from this context.
|
boolean |
hasCriticalEntries()
Check, if the correlation information contained, contains critical
entries relevant for matching.
|
String |
toString() |
getPeerAddress, getPeerAddressAsString, getPeerIdentity, getVirtualHostpublic static final String KEY_PREFIX_NONE_CRITICAL
hasCriticalEntries().public MapBasedEndpointContext(InetSocketAddress peerAddress, Principal peerIdentity, String... attributes)
peerAddress - peer address of endpoint contextpeerIdentity - peer identity of endpoint contextattributes - list of attributes (key/value pairs, e.g. key_1,
value_1, key_2, value_2 ...)NullPointerException - if provided peer address is null,
the provided attributes is null, or one of the
attributes is null.IllegalArgumentException - if provided attributes list has odd size
or contains a duplicate key.public MapBasedEndpointContext(InetSocketAddress peerAddress, String virtualHost, Principal peerIdentity, String... attributes)
peerAddress - peer address of endpoint contextvirtualHost - the name of the virtual host at the peerpeerIdentity - peer identity of endpoint contextattributes - list of attributes (key/value pairs, e.g. key_1,
value_1, key_2, value_2 ...)NullPointerException - if provided peer address is null,
the provided attributes is null, or one of the
attributes is null.IllegalArgumentException - if provided attributes list has odd size
or contains a duplicate key.public MapBasedEndpointContext(InetSocketAddress peerAddress, Principal peerIdentity, Map<String,String> attributes)
peerAddress - peer address of endpoint contextpeerIdentity - peer identity of endpoint contextattributes - map of attributesNullPointerException - if provided peer address, or attributes map
is null.public MapBasedEndpointContext(InetSocketAddress peerAddress, String virtualHost, Principal peerIdentity, Map<String,String> attributes)
peerAddress - peer address of endpoint contextvirtualHost - the name of the virtual host at the peerpeerIdentity - peer identity of endpoint contextattributes - map of attributesNullPointerException - if provided peer address, or attributes map
is null.public String get(String key)
AddressEndpointContextget in interface EndpointContextget in class AddressEndpointContextkey - the key to retrieve the value for.nullpublic Map<String,String> entries()
AddressEndpointContextentries in interface EndpointContextentries in class AddressEndpointContextpublic boolean hasCriticalEntries()
EndpointContexthasCriticalEntries in interface EndpointContexthasCriticalEntries in class AddressEndpointContexttrue, if critical entries contained, and no new
connection could match the correlation context provided in this
instance. false, if a new connection may match this
correlation context.public String toString()
toString in class AddressEndpointContextpublic static MapBasedEndpointContext addEntries(EndpointContext context, String... attributes)
context - original endpoint context.attributes - list of attributes (key/value pairs, e.g. key_1,
value_1, key_2, value_2 ...)NullPointerException - if the provided attributes is null,
or one of the attributes is null.IllegalArgumentException - if provided attributes list has odd size
or contains a duplicate key.Copyright © 2019 Eclipse Foundation. All rights reserved.