com.google.apphosting.base.protos.SpanKindOuterClass Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: span_kind.proto
package com.google.apphosting.base.protos;
public final class SpanKindOuterClass {
private SpanKindOuterClass() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
/**
*
* SpanKind distinguishes spans generated in a particular context.
* For example, two spans with the same name, one with the kind RPC_CLIENT,
* and the other with RPC_SERVER can indicate the queueing latency associated
* with the span.
*
*
* Protobuf enum {@code cloud_trace.SpanKind}
*/
public enum SpanKind
implements com.google.protobuf.ProtocolMessageEnum {
/**
*
* Default value if the span type is unknown or has no representation. Maps
* to SPAN_KIND_UNSPECIFIED in API v1 and v2.
*
*
* SPAN_DEFAULT = 0;
*/
SPAN_DEFAULT(0),
/**
*
* Indicates that the span is a server-side handler of an rpc or other remote
* network request. Maps to RPC_SERVER in API v1 and SERVER in API v2.
*
*
* RPC_SERVER = 1;
*/
RPC_SERVER(1),
/**
*
* Indicates that the span is the client-side wrapper around an rpc or other
* remote request. Maps to RPC_CLIENT in API v1 and CLIENT in API v2.
*
*
* RPC_CLIENT = 2;
*/
RPC_CLIENT(2),
/**
*
* Indicates an internal or "local" span. Maps to SPAN_KIND_UNSPECIFIED in API
* v1 and INTERNAL in API v2.
*
*
* INTERNAL = 3;
*/
INTERNAL(3),
/**
*
* Indicates a producer sending a message to a broker. Maps to
* SPAN_KIND_UNSPECIFIED in API v1 and PRODUCER in API v2.
*
*
* PRODUCER = 4;
*/
PRODUCER(4),
/**
*
* Indicates a consumer recieving a message from a broker. Maps to
* SPAN_KIND_UNSPECIFIED in API v1 and CONSUMER in API v2.
*
*
* CONSUMER = 5;
*/
CONSUMER(5),
;
/**
*
* Default value if the span type is unknown or has no representation. Maps
* to SPAN_KIND_UNSPECIFIED in API v1 and v2.
*
*
* SPAN_DEFAULT = 0;
*/
public static final int SPAN_DEFAULT_VALUE = 0;
/**
*
* Indicates that the span is a server-side handler of an rpc or other remote
* network request. Maps to RPC_SERVER in API v1 and SERVER in API v2.
*
*
* RPC_SERVER = 1;
*/
public static final int RPC_SERVER_VALUE = 1;
/**
*
* Indicates that the span is the client-side wrapper around an rpc or other
* remote request. Maps to RPC_CLIENT in API v1 and CLIENT in API v2.
*
*
* RPC_CLIENT = 2;
*/
public static final int RPC_CLIENT_VALUE = 2;
/**
*
* Indicates an internal or "local" span. Maps to SPAN_KIND_UNSPECIFIED in API
* v1 and INTERNAL in API v2.
*
*
* INTERNAL = 3;
*/
public static final int INTERNAL_VALUE = 3;
/**
*
* Indicates a producer sending a message to a broker. Maps to
* SPAN_KIND_UNSPECIFIED in API v1 and PRODUCER in API v2.
*
*
* PRODUCER = 4;
*/
public static final int PRODUCER_VALUE = 4;
/**
*
* Indicates a consumer recieving a message from a broker. Maps to
* SPAN_KIND_UNSPECIFIED in API v1 and CONSUMER in API v2.
*
*
* CONSUMER = 5;
*/
public static final int CONSUMER_VALUE = 5;
public final int getNumber() {
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static SpanKind valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static SpanKind forNumber(int value) {
switch (value) {
case 0: return SPAN_DEFAULT;
case 1: return RPC_SERVER;
case 2: return RPC_CLIENT;
case 3: return INTERNAL;
case 4: return PRODUCER;
case 5: return CONSUMER;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
SpanKind> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public SpanKind findValueByNumber(int number) {
return SpanKind.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor() {
return com.google.apphosting.base.protos.SpanKindOuterClass.getDescriptor().getEnumTypes().get(0);
}
private static final SpanKind[] VALUES = values();
public static SpanKind valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
return VALUES[desc.getIndex()];
}
private final int value;
private SpanKind(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:cloud_trace.SpanKind)
}
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor
descriptor;
static {
java.lang.String[] descriptorData = {
"\n\017span_kind.proto\022\013cloud_trace*f\n\010SpanKi" +
"nd\022\020\n\014SPAN_DEFAULT\020\000\022\016\n\nRPC_SERVER\020\001\022\016\n\n" +
"RPC_CLIENT\020\002\022\014\n\010INTERNAL\020\003\022\014\n\010PRODUCER\020\004" +
"\022\014\n\010CONSUMER\020\005B#\n!com.google.apphosting." +
"base.protos"
};
descriptor = com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
});
}
// @@protoc_insertion_point(outer_class_scope)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy