Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
org.apache.pulsar.functions.proto.Request Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: Request.proto
package org.apache.pulsar.functions.proto;
public final class Request {
private Request() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
public interface ServiceRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:proto.ServiceRequest)
com.google.protobuf.MessageOrBuilder {
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return The enum numeric value on the wire for serviceRequestType.
*/
int getServiceRequestTypeValue();
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return The serviceRequestType.
*/
org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType getServiceRequestType();
/**
* string requestId = 2;
* @return The requestId.
*/
java.lang.String getRequestId();
/**
* string requestId = 2;
* @return The bytes for requestId.
*/
com.google.protobuf.ByteString
getRequestIdBytes();
/**
* .proto.FunctionMetaData functionMetaData = 3;
* @return Whether the functionMetaData field is set.
*/
boolean hasFunctionMetaData();
/**
* .proto.FunctionMetaData functionMetaData = 3;
* @return The functionMetaData.
*/
org.apache.pulsar.functions.proto.Function.FunctionMetaData getFunctionMetaData();
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
org.apache.pulsar.functions.proto.Function.FunctionMetaDataOrBuilder getFunctionMetaDataOrBuilder();
/**
* string workerId = 4;
* @return The workerId.
*/
java.lang.String getWorkerId();
/**
* string workerId = 4;
* @return The bytes for workerId.
*/
com.google.protobuf.ByteString
getWorkerIdBytes();
}
/**
* Protobuf type {@code proto.ServiceRequest}
*/
public static final class ServiceRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:proto.ServiceRequest)
ServiceRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use ServiceRequest.newBuilder() to construct.
private ServiceRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) {
super(builder);
}
private ServiceRequest() {
serviceRequestType_ = 0;
requestId_ = "";
workerId_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ServiceRequest();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private ServiceRequest(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
int rawValue = input.readEnum();
serviceRequestType_ = rawValue;
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
requestId_ = s;
break;
}
case 26: {
org.apache.pulsar.functions.proto.Function.FunctionMetaData.Builder subBuilder = null;
if (functionMetaData_ != null) {
subBuilder = functionMetaData_.toBuilder();
}
functionMetaData_ = input.readMessage(org.apache.pulsar.functions.proto.Function.FunctionMetaData.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(functionMetaData_);
functionMetaData_ = subBuilder.buildPartial();
}
break;
}
case 34: {
java.lang.String s = input.readStringRequireUtf8();
workerId_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.apache.pulsar.functions.proto.Request.internal_static_proto_ServiceRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.apache.pulsar.functions.proto.Request.internal_static_proto_ServiceRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.apache.pulsar.functions.proto.Request.ServiceRequest.class, org.apache.pulsar.functions.proto.Request.ServiceRequest.Builder.class);
}
/**
* Protobuf enum {@code proto.ServiceRequest.ServiceRequestType}
*/
public enum ServiceRequestType
implements com.google.protobuf.ProtocolMessageEnum {
/**
* UPDATE = 0;
*/
UPDATE(0),
/**
* DELETE = 1;
*/
DELETE(1),
/**
* INITIALIZE = 2;
*/
INITIALIZE(2),
UNRECOGNIZED(-1),
;
/**
* UPDATE = 0;
*/
public static final int UPDATE_VALUE = 0;
/**
* DELETE = 1;
*/
public static final int DELETE_VALUE = 1;
/**
* INITIALIZE = 2;
*/
public static final int INITIALIZE_VALUE = 2;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
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 ServiceRequestType 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 ServiceRequestType forNumber(int value) {
switch (value) {
case 0: return UPDATE;
case 1: return DELETE;
case 2: return INITIALIZE;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
ServiceRequestType> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public ServiceRequestType findValueByNumber(int number) {
return ServiceRequestType.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
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 org.apache.pulsar.functions.proto.Request.ServiceRequest.getDescriptor().getEnumTypes().get(0);
}
private static final ServiceRequestType[] VALUES = values();
public static ServiceRequestType valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private ServiceRequestType(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:proto.ServiceRequest.ServiceRequestType)
}
public static final int SERVICEREQUESTTYPE_FIELD_NUMBER = 1;
private int serviceRequestType_;
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return The enum numeric value on the wire for serviceRequestType.
*/
@java.lang.Override public int getServiceRequestTypeValue() {
return serviceRequestType_;
}
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return The serviceRequestType.
*/
@java.lang.Override public org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType getServiceRequestType() {
@SuppressWarnings("deprecation")
org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType result = org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType.valueOf(serviceRequestType_);
return result == null ? org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType.UNRECOGNIZED : result;
}
public static final int REQUESTID_FIELD_NUMBER = 2;
private volatile java.lang.Object requestId_;
/**
* string requestId = 2;
* @return The requestId.
*/
@java.lang.Override
public java.lang.String getRequestId() {
java.lang.Object ref = requestId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
requestId_ = s;
return s;
}
}
/**
* string requestId = 2;
* @return The bytes for requestId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getRequestIdBytes() {
java.lang.Object ref = requestId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
requestId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int FUNCTIONMETADATA_FIELD_NUMBER = 3;
private org.apache.pulsar.functions.proto.Function.FunctionMetaData functionMetaData_;
/**
* .proto.FunctionMetaData functionMetaData = 3;
* @return Whether the functionMetaData field is set.
*/
@java.lang.Override
public boolean hasFunctionMetaData() {
return functionMetaData_ != null;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
* @return The functionMetaData.
*/
@java.lang.Override
public org.apache.pulsar.functions.proto.Function.FunctionMetaData getFunctionMetaData() {
return functionMetaData_ == null ? org.apache.pulsar.functions.proto.Function.FunctionMetaData.getDefaultInstance() : functionMetaData_;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
@java.lang.Override
public org.apache.pulsar.functions.proto.Function.FunctionMetaDataOrBuilder getFunctionMetaDataOrBuilder() {
return getFunctionMetaData();
}
public static final int WORKERID_FIELD_NUMBER = 4;
private volatile java.lang.Object workerId_;
/**
* string workerId = 4;
* @return The workerId.
*/
@java.lang.Override
public java.lang.String getWorkerId() {
java.lang.Object ref = workerId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
workerId_ = s;
return s;
}
}
/**
* string workerId = 4;
* @return The bytes for workerId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getWorkerIdBytes() {
java.lang.Object ref = workerId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
workerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (serviceRequestType_ != org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType.UPDATE.getNumber()) {
output.writeEnum(1, serviceRequestType_);
}
if (!getRequestIdBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, requestId_);
}
if (functionMetaData_ != null) {
output.writeMessage(3, getFunctionMetaData());
}
if (!getWorkerIdBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, workerId_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (serviceRequestType_ != org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType.UPDATE.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, serviceRequestType_);
}
if (!getRequestIdBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, requestId_);
}
if (functionMetaData_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getFunctionMetaData());
}
if (!getWorkerIdBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, workerId_);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof org.apache.pulsar.functions.proto.Request.ServiceRequest)) {
return super.equals(obj);
}
org.apache.pulsar.functions.proto.Request.ServiceRequest other = (org.apache.pulsar.functions.proto.Request.ServiceRequest) obj;
if (serviceRequestType_ != other.serviceRequestType_) return false;
if (!getRequestId()
.equals(other.getRequestId())) return false;
if (hasFunctionMetaData() != other.hasFunctionMetaData()) return false;
if (hasFunctionMetaData()) {
if (!getFunctionMetaData()
.equals(other.getFunctionMetaData())) return false;
}
if (!getWorkerId()
.equals(other.getWorkerId())) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SERVICEREQUESTTYPE_FIELD_NUMBER;
hash = (53 * hash) + serviceRequestType_;
hash = (37 * hash) + REQUESTID_FIELD_NUMBER;
hash = (53 * hash) + getRequestId().hashCode();
if (hasFunctionMetaData()) {
hash = (37 * hash) + FUNCTIONMETADATA_FIELD_NUMBER;
hash = (53 * hash) + getFunctionMetaData().hashCode();
}
hash = (37 * hash) + WORKERID_FIELD_NUMBER;
hash = (53 * hash) + getWorkerId().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(org.apache.pulsar.functions.proto.Request.ServiceRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code proto.ServiceRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:proto.ServiceRequest)
org.apache.pulsar.functions.proto.Request.ServiceRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return org.apache.pulsar.functions.proto.Request.internal_static_proto_ServiceRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return org.apache.pulsar.functions.proto.Request.internal_static_proto_ServiceRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
org.apache.pulsar.functions.proto.Request.ServiceRequest.class, org.apache.pulsar.functions.proto.Request.ServiceRequest.Builder.class);
}
// Construct using org.apache.pulsar.functions.proto.Request.ServiceRequest.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
serviceRequestType_ = 0;
requestId_ = "";
if (functionMetaDataBuilder_ == null) {
functionMetaData_ = null;
} else {
functionMetaData_ = null;
functionMetaDataBuilder_ = null;
}
workerId_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return org.apache.pulsar.functions.proto.Request.internal_static_proto_ServiceRequest_descriptor;
}
@java.lang.Override
public org.apache.pulsar.functions.proto.Request.ServiceRequest getDefaultInstanceForType() {
return org.apache.pulsar.functions.proto.Request.ServiceRequest.getDefaultInstance();
}
@java.lang.Override
public org.apache.pulsar.functions.proto.Request.ServiceRequest build() {
org.apache.pulsar.functions.proto.Request.ServiceRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public org.apache.pulsar.functions.proto.Request.ServiceRequest buildPartial() {
org.apache.pulsar.functions.proto.Request.ServiceRequest result = new org.apache.pulsar.functions.proto.Request.ServiceRequest(this);
result.serviceRequestType_ = serviceRequestType_;
result.requestId_ = requestId_;
if (functionMetaDataBuilder_ == null) {
result.functionMetaData_ = functionMetaData_;
} else {
result.functionMetaData_ = functionMetaDataBuilder_.build();
}
result.workerId_ = workerId_;
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof org.apache.pulsar.functions.proto.Request.ServiceRequest) {
return mergeFrom((org.apache.pulsar.functions.proto.Request.ServiceRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(org.apache.pulsar.functions.proto.Request.ServiceRequest other) {
if (other == org.apache.pulsar.functions.proto.Request.ServiceRequest.getDefaultInstance()) return this;
if (other.serviceRequestType_ != 0) {
setServiceRequestTypeValue(other.getServiceRequestTypeValue());
}
if (!other.getRequestId().isEmpty()) {
requestId_ = other.requestId_;
onChanged();
}
if (other.hasFunctionMetaData()) {
mergeFunctionMetaData(other.getFunctionMetaData());
}
if (!other.getWorkerId().isEmpty()) {
workerId_ = other.workerId_;
onChanged();
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
org.apache.pulsar.functions.proto.Request.ServiceRequest parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (org.apache.pulsar.functions.proto.Request.ServiceRequest) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int serviceRequestType_ = 0;
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return The enum numeric value on the wire for serviceRequestType.
*/
@java.lang.Override public int getServiceRequestTypeValue() {
return serviceRequestType_;
}
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @param value The enum numeric value on the wire for serviceRequestType to set.
* @return This builder for chaining.
*/
public Builder setServiceRequestTypeValue(int value) {
serviceRequestType_ = value;
onChanged();
return this;
}
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return The serviceRequestType.
*/
@java.lang.Override
public org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType getServiceRequestType() {
@SuppressWarnings("deprecation")
org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType result = org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType.valueOf(serviceRequestType_);
return result == null ? org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType.UNRECOGNIZED : result;
}
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @param value The serviceRequestType to set.
* @return This builder for chaining.
*/
public Builder setServiceRequestType(org.apache.pulsar.functions.proto.Request.ServiceRequest.ServiceRequestType value) {
if (value == null) {
throw new NullPointerException();
}
serviceRequestType_ = value.getNumber();
onChanged();
return this;
}
/**
* .proto.ServiceRequest.ServiceRequestType serviceRequestType = 1;
* @return This builder for chaining.
*/
public Builder clearServiceRequestType() {
serviceRequestType_ = 0;
onChanged();
return this;
}
private java.lang.Object requestId_ = "";
/**
* string requestId = 2;
* @return The requestId.
*/
public java.lang.String getRequestId() {
java.lang.Object ref = requestId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
requestId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string requestId = 2;
* @return The bytes for requestId.
*/
public com.google.protobuf.ByteString
getRequestIdBytes() {
java.lang.Object ref = requestId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
requestId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string requestId = 2;
* @param value The requestId to set.
* @return This builder for chaining.
*/
public Builder setRequestId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
requestId_ = value;
onChanged();
return this;
}
/**
* string requestId = 2;
* @return This builder for chaining.
*/
public Builder clearRequestId() {
requestId_ = getDefaultInstance().getRequestId();
onChanged();
return this;
}
/**
* string requestId = 2;
* @param value The bytes for requestId to set.
* @return This builder for chaining.
*/
public Builder setRequestIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
requestId_ = value;
onChanged();
return this;
}
private org.apache.pulsar.functions.proto.Function.FunctionMetaData functionMetaData_;
private com.google.protobuf.SingleFieldBuilderV3<
org.apache.pulsar.functions.proto.Function.FunctionMetaData, org.apache.pulsar.functions.proto.Function.FunctionMetaData.Builder, org.apache.pulsar.functions.proto.Function.FunctionMetaDataOrBuilder> functionMetaDataBuilder_;
/**
* .proto.FunctionMetaData functionMetaData = 3;
* @return Whether the functionMetaData field is set.
*/
public boolean hasFunctionMetaData() {
return functionMetaDataBuilder_ != null || functionMetaData_ != null;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
* @return The functionMetaData.
*/
public org.apache.pulsar.functions.proto.Function.FunctionMetaData getFunctionMetaData() {
if (functionMetaDataBuilder_ == null) {
return functionMetaData_ == null ? org.apache.pulsar.functions.proto.Function.FunctionMetaData.getDefaultInstance() : functionMetaData_;
} else {
return functionMetaDataBuilder_.getMessage();
}
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
public Builder setFunctionMetaData(org.apache.pulsar.functions.proto.Function.FunctionMetaData value) {
if (functionMetaDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
functionMetaData_ = value;
onChanged();
} else {
functionMetaDataBuilder_.setMessage(value);
}
return this;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
public Builder setFunctionMetaData(
org.apache.pulsar.functions.proto.Function.FunctionMetaData.Builder builderForValue) {
if (functionMetaDataBuilder_ == null) {
functionMetaData_ = builderForValue.build();
onChanged();
} else {
functionMetaDataBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
public Builder mergeFunctionMetaData(org.apache.pulsar.functions.proto.Function.FunctionMetaData value) {
if (functionMetaDataBuilder_ == null) {
if (functionMetaData_ != null) {
functionMetaData_ =
org.apache.pulsar.functions.proto.Function.FunctionMetaData.newBuilder(functionMetaData_).mergeFrom(value).buildPartial();
} else {
functionMetaData_ = value;
}
onChanged();
} else {
functionMetaDataBuilder_.mergeFrom(value);
}
return this;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
public Builder clearFunctionMetaData() {
if (functionMetaDataBuilder_ == null) {
functionMetaData_ = null;
onChanged();
} else {
functionMetaData_ = null;
functionMetaDataBuilder_ = null;
}
return this;
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
public org.apache.pulsar.functions.proto.Function.FunctionMetaData.Builder getFunctionMetaDataBuilder() {
onChanged();
return getFunctionMetaDataFieldBuilder().getBuilder();
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
public org.apache.pulsar.functions.proto.Function.FunctionMetaDataOrBuilder getFunctionMetaDataOrBuilder() {
if (functionMetaDataBuilder_ != null) {
return functionMetaDataBuilder_.getMessageOrBuilder();
} else {
return functionMetaData_ == null ?
org.apache.pulsar.functions.proto.Function.FunctionMetaData.getDefaultInstance() : functionMetaData_;
}
}
/**
* .proto.FunctionMetaData functionMetaData = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
org.apache.pulsar.functions.proto.Function.FunctionMetaData, org.apache.pulsar.functions.proto.Function.FunctionMetaData.Builder, org.apache.pulsar.functions.proto.Function.FunctionMetaDataOrBuilder>
getFunctionMetaDataFieldBuilder() {
if (functionMetaDataBuilder_ == null) {
functionMetaDataBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
org.apache.pulsar.functions.proto.Function.FunctionMetaData, org.apache.pulsar.functions.proto.Function.FunctionMetaData.Builder, org.apache.pulsar.functions.proto.Function.FunctionMetaDataOrBuilder>(
getFunctionMetaData(),
getParentForChildren(),
isClean());
functionMetaData_ = null;
}
return functionMetaDataBuilder_;
}
private java.lang.Object workerId_ = "";
/**
* string workerId = 4;
* @return The workerId.
*/
public java.lang.String getWorkerId() {
java.lang.Object ref = workerId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
workerId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string workerId = 4;
* @return The bytes for workerId.
*/
public com.google.protobuf.ByteString
getWorkerIdBytes() {
java.lang.Object ref = workerId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
workerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string workerId = 4;
* @param value The workerId to set.
* @return This builder for chaining.
*/
public Builder setWorkerId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
workerId_ = value;
onChanged();
return this;
}
/**
* string workerId = 4;
* @return This builder for chaining.
*/
public Builder clearWorkerId() {
workerId_ = getDefaultInstance().getWorkerId();
onChanged();
return this;
}
/**
* string workerId = 4;
* @param value The bytes for workerId to set.
* @return This builder for chaining.
*/
public Builder setWorkerIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
workerId_ = value;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:proto.ServiceRequest)
}
// @@protoc_insertion_point(class_scope:proto.ServiceRequest)
private static final org.apache.pulsar.functions.proto.Request.ServiceRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new org.apache.pulsar.functions.proto.Request.ServiceRequest();
}
public static org.apache.pulsar.functions.proto.Request.ServiceRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ServiceRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new ServiceRequest(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public org.apache.pulsar.functions.proto.Request.ServiceRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_proto_ServiceRequest_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_proto_ServiceRequest_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor
descriptor;
static {
java.lang.String[] descriptorData = {
"\n\rRequest.proto\022\005proto\032\016Function.proto\"\354" +
"\001\n\016ServiceRequest\022D\n\022serviceRequestType\030" +
"\001 \001(\0162(.proto.ServiceRequest.ServiceRequ" +
"estType\022\021\n\trequestId\030\002 \001(\t\0221\n\020functionMe" +
"taData\030\003 \001(\0132\027.proto.FunctionMetaData\022\020\n" +
"\010workerId\030\004 \001(\t\"<\n\022ServiceRequestType\022\n\n" +
"\006UPDATE\020\000\022\n\n\006DELETE\020\001\022\016\n\nINITIALIZE\020\002B,\n" +
"!org.apache.pulsar.functions.protoB\007Requ" +
"estb\006proto3"
};
descriptor = com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
org.apache.pulsar.functions.proto.Function.getDescriptor(),
});
internal_static_proto_ServiceRequest_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_proto_ServiceRequest_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_proto_ServiceRequest_descriptor,
new java.lang.String[] { "ServiceRequestType", "RequestId", "FunctionMetaData", "WorkerId", });
org.apache.pulsar.functions.proto.Function.getDescriptor();
}
// @@protoc_insertion_point(outer_class_scope)
}