Package io.envoyproxy.envoy.api.v2.core
Interface SocketAddressOrBuilder
-
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
SocketAddress
,SocketAddress.Builder
public interface SocketAddressOrBuilder extends com.google.protobuf.MessageOrBuilder
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
getAddress()
The address for this socket.com.google.protobuf.ByteString
getAddressBytes()
The address for this socket.boolean
getIpv4Compat()
When binding to an IPv6 address above, this enables `IPv4 compatibility <https://tools.ietf.org/html/rfc3493#page-11>`_.String
getNamedPort()
This is only valid if :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>` is specified below and the named resolver is capable of named port resolution.com.google.protobuf.ByteString
getNamedPortBytes()
This is only valid if :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>` is specified below and the named resolver is capable of named port resolution.SocketAddress.PortSpecifierCase
getPortSpecifierCase()
int
getPortValue()
uint32 port_value = 3 [(.validate.rules) = { ... }
SocketAddress.Protocol
getProtocol()
.envoy.api.v2.core.SocketAddress.Protocol protocol = 1 [(.validate.rules) = { ... }
int
getProtocolValue()
.envoy.api.v2.core.SocketAddress.Protocol protocol = 1 [(.validate.rules) = { ... }
String
getResolverName()
The name of the custom resolver.com.google.protobuf.ByteString
getResolverNameBytes()
The name of the custom resolver.boolean
hasNamedPort()
This is only valid if :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>` is specified below and the named resolver is capable of named port resolution.boolean
hasPortValue()
uint32 port_value = 3 [(.validate.rules) = { ... }
-
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
-
-
-
Method Detail
-
getProtocolValue
int getProtocolValue()
.envoy.api.v2.core.SocketAddress.Protocol protocol = 1 [(.validate.rules) = { ... }
- Returns:
- The enum numeric value on the wire for protocol.
-
getProtocol
SocketAddress.Protocol getProtocol()
.envoy.api.v2.core.SocketAddress.Protocol protocol = 1 [(.validate.rules) = { ... }
- Returns:
- The protocol.
-
getAddress
String getAddress()
The address for this socket. :ref:`Listeners <config_listeners>` will bind to the address. An empty address is not allowed. Specify ``0.0.0.0`` or ``::`` to bind to any address. [#comment:TODO(zuercher) reinstate when implemented: It is possible to distinguish a Listener address via the prefix/suffix matching in :ref:`FilterChainMatch <envoy_api_msg_listener.FilterChainMatch>`.] When used within an upstream :ref:`BindConfig <envoy_api_msg_core.BindConfig>`, the address controls the source address of outbound connections. For :ref:`clusters <envoy_api_msg_Cluster>`, the cluster type determines whether the address must be an IP (*STATIC* or *EDS* clusters) or a hostname resolved by DNS (*STRICT_DNS* or *LOGICAL_DNS* clusters). Address resolution can be customized via :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>`.
string address = 2 [(.validate.rules) = { ... }
- Returns:
- The address.
-
getAddressBytes
com.google.protobuf.ByteString getAddressBytes()
The address for this socket. :ref:`Listeners <config_listeners>` will bind to the address. An empty address is not allowed. Specify ``0.0.0.0`` or ``::`` to bind to any address. [#comment:TODO(zuercher) reinstate when implemented: It is possible to distinguish a Listener address via the prefix/suffix matching in :ref:`FilterChainMatch <envoy_api_msg_listener.FilterChainMatch>`.] When used within an upstream :ref:`BindConfig <envoy_api_msg_core.BindConfig>`, the address controls the source address of outbound connections. For :ref:`clusters <envoy_api_msg_Cluster>`, the cluster type determines whether the address must be an IP (*STATIC* or *EDS* clusters) or a hostname resolved by DNS (*STRICT_DNS* or *LOGICAL_DNS* clusters). Address resolution can be customized via :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>`.
string address = 2 [(.validate.rules) = { ... }
- Returns:
- The bytes for address.
-
hasPortValue
boolean hasPortValue()
uint32 port_value = 3 [(.validate.rules) = { ... }
- Returns:
- Whether the portValue field is set.
-
getPortValue
int getPortValue()
uint32 port_value = 3 [(.validate.rules) = { ... }
- Returns:
- The portValue.
-
hasNamedPort
boolean hasNamedPort()
This is only valid if :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>` is specified below and the named resolver is capable of named port resolution.
string named_port = 4;
- Returns:
- Whether the namedPort field is set.
-
getNamedPort
String getNamedPort()
This is only valid if :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>` is specified below and the named resolver is capable of named port resolution.
string named_port = 4;
- Returns:
- The namedPort.
-
getNamedPortBytes
com.google.protobuf.ByteString getNamedPortBytes()
This is only valid if :ref:`resolver_name <envoy_api_field_core.SocketAddress.resolver_name>` is specified below and the named resolver is capable of named port resolution.
string named_port = 4;
- Returns:
- The bytes for namedPort.
-
getResolverName
String getResolverName()
The name of the custom resolver. This must have been registered with Envoy. If this is empty, a context dependent default applies. If the address is a concrete IP address, no resolution will occur. If address is a hostname this should be set for resolution other than DNS. Specifying a custom resolver with *STRICT_DNS* or *LOGICAL_DNS* will generate an error at runtime.
string resolver_name = 5;
- Returns:
- The resolverName.
-
getResolverNameBytes
com.google.protobuf.ByteString getResolverNameBytes()
The name of the custom resolver. This must have been registered with Envoy. If this is empty, a context dependent default applies. If the address is a concrete IP address, no resolution will occur. If address is a hostname this should be set for resolution other than DNS. Specifying a custom resolver with *STRICT_DNS* or *LOGICAL_DNS* will generate an error at runtime.
string resolver_name = 5;
- Returns:
- The bytes for resolverName.
-
getIpv4Compat
boolean getIpv4Compat()
When binding to an IPv6 address above, this enables `IPv4 compatibility <https://tools.ietf.org/html/rfc3493#page-11>`_. Binding to ``::`` will allow both IPv4 and IPv6 connections, with peer IPv4 addresses mapped into IPv6 space as ``::FFFF:<IPv4-address>``.
bool ipv4_compat = 6;
- Returns:
- The ipv4Compat.
-
getPortSpecifierCase
SocketAddress.PortSpecifierCase getPortSpecifierCase()
-
-