Interface EndpointListDecoder<T>
- Type Parameters:
T
- the type of the file in Central Dogma
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Decodes the content of a file in Central Dogma into a list of
Endpoint
s.-
Field Summary
Modifier and TypeFieldDescriptionstatic final EndpointListDecoder
<JsonNode> DefaultEndpointListDecoder
implementation forJsonNode
.static final EndpointListDecoder
<String> DefaultEndpointListDecoder
implementation forString
. -
Method Summary
-
Field Details
-
JSON
DefaultEndpointListDecoder
implementation forJsonNode
. Retrieved object must be a JSON array (which has format as"[\"segment1\", \"segment2\"]"
) Each segment represents an endpoint whose format is<host>[:<port_number>[:weight]]
, such as:"foo.com"
- default port number, default weight (1000)"bar.com:8080
- port number 8080, default weight (1000)"10.0.2.15:0:500
- default port number, weight 500"192.168.1.2:8443:700
- port number 8443, weight 700
-
TEXT
DefaultEndpointListDecoder
implementation forString
. Retrieved object must be a string which is a list of segments separated by a newline character. Each segment represents an endpoint whose format is<host>[:<port_number>[:weight]]
, such as:"foo.com"
- default port number, default weight (1000)"bar.com:8080
- port number 8080, default weight (1000)"10.0.2.15:0:500
- default port number, weight 500"192.168.1.2:8443:700
- port number 8443, weight 700
-
-
Method Details