games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of saga-sdk-proto Show documentation
Show all versions of saga-sdk-proto Show documentation
Saga SDK for Java game servers
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: streams/currency/definition.proto
package games.mythical.saga.sdk.proto.streams.currency;
/**
* Protobuf type {@code saga.rpc.streams.currency.CurrencyUpdate}
*/
public final class CurrencyUpdate extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:saga.rpc.streams.currency.CurrencyUpdate)
CurrencyUpdateOrBuilder {
private static final long serialVersionUID = 0L;
// Use CurrencyUpdate.newBuilder() to construct.
private CurrencyUpdate(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private CurrencyUpdate() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new CurrencyUpdate();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return games.mythical.saga.sdk.proto.streams.currency.Definition.internal_static_saga_rpc_streams_currency_CurrencyUpdate_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return games.mythical.saga.sdk.proto.streams.currency.Definition.internal_static_saga_rpc_streams_currency_CurrencyUpdate_fieldAccessorTable
.ensureFieldAccessorsInitialized(
games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.class, games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.Builder.class);
}
private int updateCase_ = 0;
private java.lang.Object update_;
public enum UpdateCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
ERROR(1),
STATUS_UPDATE(2),
UPDATE_NOT_SET(0);
private final int value;
private UpdateCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static UpdateCase valueOf(int value) {
return forNumber(value);
}
public static UpdateCase forNumber(int value) {
switch (value) {
case 1: return ERROR;
case 2: return STATUS_UPDATE;
case 0: return UPDATE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public UpdateCase
getUpdateCase() {
return UpdateCase.forNumber(
updateCase_);
}
public static final int ERROR_FIELD_NUMBER = 1;
/**
* .saga.common.ErrorData error = 1;
* @return Whether the error field is set.
*/
@java.lang.Override
public boolean hasError() {
return updateCase_ == 1;
}
/**
* .saga.common.ErrorData error = 1;
* @return The error.
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.common.ErrorData getError() {
if (updateCase_ == 1) {
return (games.mythical.saga.sdk.proto.common.ErrorData) update_;
}
return games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance();
}
/**
* .saga.common.ErrorData error = 1;
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.common.ErrorDataOrBuilder getErrorOrBuilder() {
if (updateCase_ == 1) {
return (games.mythical.saga.sdk.proto.common.ErrorData) update_;
}
return games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance();
}
public static final int STATUS_UPDATE_FIELD_NUMBER = 2;
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
* @return Whether the statusUpdate field is set.
*/
@java.lang.Override
public boolean hasStatusUpdate() {
return updateCase_ == 2;
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
* @return The statusUpdate.
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate getStatusUpdate() {
if (updateCase_ == 2) {
return (games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_;
}
return games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance();
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdateOrBuilder getStatusUpdateOrBuilder() {
if (updateCase_ == 2) {
return (games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_;
}
return games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance();
}
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 (updateCase_ == 1) {
output.writeMessage(1, (games.mythical.saga.sdk.proto.common.ErrorData) update_);
}
if (updateCase_ == 2) {
output.writeMessage(2, (games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (updateCase_ == 1) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, (games.mythical.saga.sdk.proto.common.ErrorData) update_);
}
if (updateCase_ == 2) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, (games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate)) {
return super.equals(obj);
}
games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate other = (games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate) obj;
if (!getUpdateCase().equals(other.getUpdateCase())) return false;
switch (updateCase_) {
case 1:
if (!getError()
.equals(other.getError())) return false;
break;
case 2:
if (!getStatusUpdate()
.equals(other.getStatusUpdate())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
switch (updateCase_) {
case 1:
hash = (37 * hash) + ERROR_FIELD_NUMBER;
hash = (53 * hash) + getError().hashCode();
break;
case 2:
hash = (37 * hash) + STATUS_UPDATE_FIELD_NUMBER;
hash = (53 * hash) + getStatusUpdate().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate 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 games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate 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 games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate 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(games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate 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 saga.rpc.streams.currency.CurrencyUpdate}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:saga.rpc.streams.currency.CurrencyUpdate)
games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdateOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return games.mythical.saga.sdk.proto.streams.currency.Definition.internal_static_saga_rpc_streams_currency_CurrencyUpdate_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return games.mythical.saga.sdk.proto.streams.currency.Definition.internal_static_saga_rpc_streams_currency_CurrencyUpdate_fieldAccessorTable
.ensureFieldAccessorsInitialized(
games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.class, games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.Builder.class);
}
// Construct using games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
if (errorBuilder_ != null) {
errorBuilder_.clear();
}
if (statusUpdateBuilder_ != null) {
statusUpdateBuilder_.clear();
}
updateCase_ = 0;
update_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return games.mythical.saga.sdk.proto.streams.currency.Definition.internal_static_saga_rpc_streams_currency_CurrencyUpdate_descriptor;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate getDefaultInstanceForType() {
return games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.getDefaultInstance();
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate build() {
games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate buildPartial() {
games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate result = new games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate(this);
if (updateCase_ == 1) {
if (errorBuilder_ == null) {
result.update_ = update_;
} else {
result.update_ = errorBuilder_.build();
}
}
if (updateCase_ == 2) {
if (statusUpdateBuilder_ == null) {
result.update_ = update_;
} else {
result.update_ = statusUpdateBuilder_.build();
}
}
result.updateCase_ = updateCase_;
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 games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate) {
return mergeFrom((games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate other) {
if (other == games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate.getDefaultInstance()) return this;
switch (other.getUpdateCase()) {
case ERROR: {
mergeError(other.getError());
break;
}
case STATUS_UPDATE: {
mergeStatusUpdate(other.getStatusUpdate());
break;
}
case UPDATE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
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 {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getErrorFieldBuilder().getBuilder(),
extensionRegistry);
updateCase_ = 1;
break;
} // case 10
case 18: {
input.readMessage(
getStatusUpdateFieldBuilder().getBuilder(),
extensionRegistry);
updateCase_ = 2;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int updateCase_ = 0;
private java.lang.Object update_;
public UpdateCase
getUpdateCase() {
return UpdateCase.forNumber(
updateCase_);
}
public Builder clearUpdate() {
updateCase_ = 0;
update_ = null;
onChanged();
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
games.mythical.saga.sdk.proto.common.ErrorData, games.mythical.saga.sdk.proto.common.ErrorData.Builder, games.mythical.saga.sdk.proto.common.ErrorDataOrBuilder> errorBuilder_;
/**
* .saga.common.ErrorData error = 1;
* @return Whether the error field is set.
*/
@java.lang.Override
public boolean hasError() {
return updateCase_ == 1;
}
/**
* .saga.common.ErrorData error = 1;
* @return The error.
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.common.ErrorData getError() {
if (errorBuilder_ == null) {
if (updateCase_ == 1) {
return (games.mythical.saga.sdk.proto.common.ErrorData) update_;
}
return games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance();
} else {
if (updateCase_ == 1) {
return errorBuilder_.getMessage();
}
return games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance();
}
}
/**
* .saga.common.ErrorData error = 1;
*/
public Builder setError(games.mythical.saga.sdk.proto.common.ErrorData value) {
if (errorBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
update_ = value;
onChanged();
} else {
errorBuilder_.setMessage(value);
}
updateCase_ = 1;
return this;
}
/**
* .saga.common.ErrorData error = 1;
*/
public Builder setError(
games.mythical.saga.sdk.proto.common.ErrorData.Builder builderForValue) {
if (errorBuilder_ == null) {
update_ = builderForValue.build();
onChanged();
} else {
errorBuilder_.setMessage(builderForValue.build());
}
updateCase_ = 1;
return this;
}
/**
* .saga.common.ErrorData error = 1;
*/
public Builder mergeError(games.mythical.saga.sdk.proto.common.ErrorData value) {
if (errorBuilder_ == null) {
if (updateCase_ == 1 &&
update_ != games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance()) {
update_ = games.mythical.saga.sdk.proto.common.ErrorData.newBuilder((games.mythical.saga.sdk.proto.common.ErrorData) update_)
.mergeFrom(value).buildPartial();
} else {
update_ = value;
}
onChanged();
} else {
if (updateCase_ == 1) {
errorBuilder_.mergeFrom(value);
} else {
errorBuilder_.setMessage(value);
}
}
updateCase_ = 1;
return this;
}
/**
* .saga.common.ErrorData error = 1;
*/
public Builder clearError() {
if (errorBuilder_ == null) {
if (updateCase_ == 1) {
updateCase_ = 0;
update_ = null;
onChanged();
}
} else {
if (updateCase_ == 1) {
updateCase_ = 0;
update_ = null;
}
errorBuilder_.clear();
}
return this;
}
/**
* .saga.common.ErrorData error = 1;
*/
public games.mythical.saga.sdk.proto.common.ErrorData.Builder getErrorBuilder() {
return getErrorFieldBuilder().getBuilder();
}
/**
* .saga.common.ErrorData error = 1;
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.common.ErrorDataOrBuilder getErrorOrBuilder() {
if ((updateCase_ == 1) && (errorBuilder_ != null)) {
return errorBuilder_.getMessageOrBuilder();
} else {
if (updateCase_ == 1) {
return (games.mythical.saga.sdk.proto.common.ErrorData) update_;
}
return games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance();
}
}
/**
* .saga.common.ErrorData error = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
games.mythical.saga.sdk.proto.common.ErrorData, games.mythical.saga.sdk.proto.common.ErrorData.Builder, games.mythical.saga.sdk.proto.common.ErrorDataOrBuilder>
getErrorFieldBuilder() {
if (errorBuilder_ == null) {
if (!(updateCase_ == 1)) {
update_ = games.mythical.saga.sdk.proto.common.ErrorData.getDefaultInstance();
}
errorBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
games.mythical.saga.sdk.proto.common.ErrorData, games.mythical.saga.sdk.proto.common.ErrorData.Builder, games.mythical.saga.sdk.proto.common.ErrorDataOrBuilder>(
(games.mythical.saga.sdk.proto.common.ErrorData) update_,
getParentForChildren(),
isClean());
update_ = null;
}
updateCase_ = 1;
onChanged();;
return errorBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate, games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.Builder, games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdateOrBuilder> statusUpdateBuilder_;
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
* @return Whether the statusUpdate field is set.
*/
@java.lang.Override
public boolean hasStatusUpdate() {
return updateCase_ == 2;
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
* @return The statusUpdate.
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate getStatusUpdate() {
if (statusUpdateBuilder_ == null) {
if (updateCase_ == 2) {
return (games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_;
}
return games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance();
} else {
if (updateCase_ == 2) {
return statusUpdateBuilder_.getMessage();
}
return games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance();
}
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
public Builder setStatusUpdate(games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate value) {
if (statusUpdateBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
update_ = value;
onChanged();
} else {
statusUpdateBuilder_.setMessage(value);
}
updateCase_ = 2;
return this;
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
public Builder setStatusUpdate(
games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.Builder builderForValue) {
if (statusUpdateBuilder_ == null) {
update_ = builderForValue.build();
onChanged();
} else {
statusUpdateBuilder_.setMessage(builderForValue.build());
}
updateCase_ = 2;
return this;
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
public Builder mergeStatusUpdate(games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate value) {
if (statusUpdateBuilder_ == null) {
if (updateCase_ == 2 &&
update_ != games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance()) {
update_ = games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.newBuilder((games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_)
.mergeFrom(value).buildPartial();
} else {
update_ = value;
}
onChanged();
} else {
if (updateCase_ == 2) {
statusUpdateBuilder_.mergeFrom(value);
} else {
statusUpdateBuilder_.setMessage(value);
}
}
updateCase_ = 2;
return this;
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
public Builder clearStatusUpdate() {
if (statusUpdateBuilder_ == null) {
if (updateCase_ == 2) {
updateCase_ = 0;
update_ = null;
onChanged();
}
} else {
if (updateCase_ == 2) {
updateCase_ = 0;
update_ = null;
}
statusUpdateBuilder_.clear();
}
return this;
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
public games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.Builder getStatusUpdateBuilder() {
return getStatusUpdateFieldBuilder().getBuilder();
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdateOrBuilder getStatusUpdateOrBuilder() {
if ((updateCase_ == 2) && (statusUpdateBuilder_ != null)) {
return statusUpdateBuilder_.getMessageOrBuilder();
} else {
if (updateCase_ == 2) {
return (games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_;
}
return games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance();
}
}
/**
* .saga.rpc.streams.currency.CurrencyStatusUpdate status_update = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate, games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.Builder, games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdateOrBuilder>
getStatusUpdateFieldBuilder() {
if (statusUpdateBuilder_ == null) {
if (!(updateCase_ == 2)) {
update_ = games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.getDefaultInstance();
}
statusUpdateBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate, games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate.Builder, games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdateOrBuilder>(
(games.mythical.saga.sdk.proto.streams.currency.CurrencyStatusUpdate) update_,
getParentForChildren(),
isClean());
update_ = null;
}
updateCase_ = 2;
onChanged();;
return statusUpdateBuilder_;
}
@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:saga.rpc.streams.currency.CurrencyUpdate)
}
// @@protoc_insertion_point(class_scope:saga.rpc.streams.currency.CurrencyUpdate)
private static final games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate();
}
public static games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public CurrencyUpdate parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.currency.CurrencyUpdate getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}