public static final class AttributeContext.Peer extends GeneratedMessageV3 implements AttributeContext.PeerOrBuilder
This message defines attributes for a node that handles a network request.
The node can be either a service or an application that sends, forwards,
or receives the request. Service peers should fill in
principal
and labels
as appropriate.
Protobuf type google.rpc.context.AttributeContext.Peer
Inheritance
Object > AbstractMessageLite<MessageType,BuilderType> > AbstractMessage > GeneratedMessageV3 > AttributeContext.PeerImplements
AttributeContext.PeerOrBuilderStatic Fields
IP_FIELD_NUMBER
public static final int IP_FIELD_NUMBER
Type | Description |
int |
LABELS_FIELD_NUMBER
public static final int LABELS_FIELD_NUMBER
Type | Description |
int |
PORT_FIELD_NUMBER
public static final int PORT_FIELD_NUMBER
Type | Description |
int |
PRINCIPAL_FIELD_NUMBER
public static final int PRINCIPAL_FIELD_NUMBER
Type | Description |
int |
REGION_CODE_FIELD_NUMBER
public static final int REGION_CODE_FIELD_NUMBER
Type | Description |
int |
Static Methods
getDefaultInstance()
public static AttributeContext.Peer getDefaultInstance()
Type | Description |
AttributeContext.Peer |
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Type | Description |
Descriptor |
newBuilder()
public static AttributeContext.Peer.Builder newBuilder()
Type | Description |
AttributeContext.Peer.Builder |
newBuilder(AttributeContext.Peer prototype)
public static AttributeContext.Peer.Builder newBuilder(AttributeContext.Peer prototype)
Name | Description |
prototype | AttributeContext.Peer |
Type | Description |
AttributeContext.Peer.Builder |
parseDelimitedFrom(InputStream input)
public static AttributeContext.Peer parseDelimitedFrom(InputStream input)
Name | Description |
input | InputStream |
Type | Description |
AttributeContext.Peer |
Type | Description |
IOException |
parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static AttributeContext.Peer parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Name | Description |
input | InputStream |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
AttributeContext.Peer |
Type | Description |
IOException |
parseFrom(byte[] data)
public static AttributeContext.Peer parseFrom(byte[] data)
Name | Description |
data | byte[] |
Type | Description |
AttributeContext.Peer |
Type | Description |
InvalidProtocolBufferException |
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static AttributeContext.Peer parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Name | Description |
data | byte[] |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
AttributeContext.Peer |
Type | Description |
InvalidProtocolBufferException |
parseFrom(ByteString data)
public static AttributeContext.Peer parseFrom(ByteString data)
Name | Description |
data | ByteString |
Type | Description |
AttributeContext.Peer |
Type | Description |
InvalidProtocolBufferException |
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static AttributeContext.Peer parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Name | Description |
data | ByteString |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
AttributeContext.Peer |
Type | Description |
InvalidProtocolBufferException |
parseFrom(CodedInputStream input)
public static AttributeContext.Peer parseFrom(CodedInputStream input)
Name | Description |
input | CodedInputStream |
Type | Description |
AttributeContext.Peer |
Type | Description |
IOException |
parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static AttributeContext.Peer parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Name | Description |
input | CodedInputStream |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
AttributeContext.Peer |
Type | Description |
IOException |
parseFrom(InputStream input)
public static AttributeContext.Peer parseFrom(InputStream input)
Name | Description |
input | InputStream |
Type | Description |
AttributeContext.Peer |
Type | Description |
IOException |
parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static AttributeContext.Peer parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Name | Description |
input | InputStream |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
AttributeContext.Peer |
Type | Description |
IOException |
parseFrom(ByteBuffer data)
public static AttributeContext.Peer parseFrom(ByteBuffer data)
Name | Description |
data | ByteBuffer |
Type | Description |
AttributeContext.Peer |
Type | Description |
InvalidProtocolBufferException |
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static AttributeContext.Peer parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Name | Description |
data | ByteBuffer |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
AttributeContext.Peer |
Type | Description |
InvalidProtocolBufferException |
parser()
public static Parser<AttributeContext.Peer> parser()
Type | Description |
Parser<Peer> |
Methods
containsLabels(String key)
public boolean containsLabels(String key)
The labels associated with the peer.
map<string, string> labels = 6;
Name | Description |
key | String |
Type | Description |
boolean |
equals(Object obj)
public boolean equals(Object obj)
Name | Description |
obj | Object |
Type | Description |
boolean |
getDefaultInstanceForType()
public AttributeContext.Peer getDefaultInstanceForType()
Type | Description |
AttributeContext.Peer |
getIp()
public String getIp()
The IP address of the peer.
string ip = 1;
Type | Description |
String | The ip. |
getIpBytes()
public ByteString getIpBytes()
The IP address of the peer.
string ip = 1;
Type | Description |
ByteString | The bytes for ip. |
getLabels()
public Map<String,String> getLabels()
Use #getLabelsMap() instead.
Type | Description |
Map<String,String> |
getLabelsCount()
public int getLabelsCount()
The labels associated with the peer.
map<string, string> labels = 6;
Type | Description |
int |
getLabelsMap()
public Map<String,String> getLabelsMap()
The labels associated with the peer.
map<string, string> labels = 6;
Type | Description |
Map<String,String> |
getLabelsOrDefault(String key, String defaultValue)
public String getLabelsOrDefault(String key, String defaultValue)
The labels associated with the peer.
map<string, string> labels = 6;
Name | Description |
key | String |
defaultValue | String |
Type | Description |
String |
getLabelsOrThrow(String key)
public String getLabelsOrThrow(String key)
The labels associated with the peer.
map<string, string> labels = 6;
Name | Description |
key | String |
Type | Description |
String |
getParserForType()
public Parser<AttributeContext.Peer> getParserForType()
Type | Description |
Parser<Peer> |
getPort()
public long getPort()
The network port of the peer.
int64 port = 2;
Type | Description |
long | The port. |
getPrincipal()
public String getPrincipal()
The identity of this peer. Similar to Request.auth.principal
, but
relative to the peer instead of the request. For example, the
idenity associated with a load balancer that forwared the request.
string principal = 7;
Type | Description |
String | The principal. |
getPrincipalBytes()
public ByteString getPrincipalBytes()
The identity of this peer. Similar to Request.auth.principal
, but
relative to the peer instead of the request. For example, the
idenity associated with a load balancer that forwared the request.
string principal = 7;
Type | Description |
ByteString | The bytes for principal. |
getRegionCode()
public String getRegionCode()
The CLDR country/region code associated with the above IP address.
If the IP address is private, the region_code
should reflect the
physical location where this peer is running.
string region_code = 8;
Type | Description |
String | The regionCode. |
getRegionCodeBytes()
public ByteString getRegionCodeBytes()
The CLDR country/region code associated with the above IP address.
If the IP address is private, the region_code
should reflect the
physical location where this peer is running.
string region_code = 8;
Type | Description |
ByteString | The bytes for regionCode. |
getSerializedSize()
public int getSerializedSize()
Type | Description |
int |
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Type | Description |
UnknownFieldSet |
hashCode()
public int hashCode()
Type | Description |
int |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Type | Description |
FieldAccessorTable |
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Name | Description |
number | int |
Type | Description |
MapField |
isInitialized()
public final boolean isInitialized()
Type | Description |
boolean |
newBuilderForType()
public AttributeContext.Peer.Builder newBuilderForType()
Type | Description |
AttributeContext.Peer.Builder |
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected AttributeContext.Peer.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Name | Description |
parent | BuilderParent |
Type | Description |
AttributeContext.Peer.Builder |
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Name | Description |
unused | UnusedPrivateParameter |
Type | Description |
Object |
toBuilder()
public AttributeContext.Peer.Builder toBuilder()
Type | Description |
AttributeContext.Peer.Builder |
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Name | Description |
output | CodedOutputStream |
Type | Description |
IOException |