games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest 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: api/currency/definition.proto
package games.mythical.saga.sdk.proto.api.currency;
/**
*
* Issue currency call
*
*
* Protobuf type {@code saga.api.currency.IssueCurrencyRequest}
*/
public final class IssueCurrencyRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:saga.api.currency.IssueCurrencyRequest)
IssueCurrencyRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use IssueCurrencyRequest.newBuilder() to construct.
private IssueCurrencyRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private IssueCurrencyRequest() {
currencyTypeId_ = "";
userAmounts_ = java.util.Collections.emptyList();
idempotencyId_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new IssueCurrencyRequest();
}
@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.api.currency.Definition.internal_static_saga_api_currency_IssueCurrencyRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return games.mythical.saga.sdk.proto.api.currency.Definition.internal_static_saga_api_currency_IssueCurrencyRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.class, games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.Builder.class);
}
public static final int CURRENCY_TYPE_ID_FIELD_NUMBER = 1;
private volatile java.lang.Object currencyTypeId_;
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @return The currencyTypeId.
*/
@java.lang.Override
public java.lang.String getCurrencyTypeId() {
java.lang.Object ref = currencyTypeId_;
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();
currencyTypeId_ = s;
return s;
}
}
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @return The bytes for currencyTypeId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getCurrencyTypeIdBytes() {
java.lang.Object ref = currencyTypeId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
currencyTypeId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int USER_AMOUNTS_FIELD_NUMBER = 2;
private java.util.List userAmounts_;
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
@java.lang.Override
public java.util.List getUserAmountsList() {
return userAmounts_;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
@java.lang.Override
public java.util.List extends games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder>
getUserAmountsOrBuilderList() {
return userAmounts_;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
@java.lang.Override
public int getUserAmountsCount() {
return userAmounts_.size();
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.api.currency.UserAmountProto getUserAmounts(int index) {
return userAmounts_.get(index);
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder getUserAmountsOrBuilder(
int index) {
return userAmounts_.get(index);
}
public static final int IDEMPOTENCY_ID_FIELD_NUMBER = 3;
private volatile java.lang.Object idempotencyId_;
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @return The idempotencyId.
*/
@java.lang.Override
public java.lang.String getIdempotencyId() {
java.lang.Object ref = idempotencyId_;
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();
idempotencyId_ = s;
return s;
}
}
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @return The bytes for idempotencyId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getIdempotencyIdBytes() {
java.lang.Object ref = idempotencyId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
idempotencyId_ = 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 (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(currencyTypeId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, currencyTypeId_);
}
for (int i = 0; i < userAmounts_.size(); i++) {
output.writeMessage(2, userAmounts_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(idempotencyId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, idempotencyId_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(currencyTypeId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, currencyTypeId_);
}
for (int i = 0; i < userAmounts_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, userAmounts_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(idempotencyId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, idempotencyId_);
}
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.api.currency.IssueCurrencyRequest)) {
return super.equals(obj);
}
games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest other = (games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest) obj;
if (!getCurrencyTypeId()
.equals(other.getCurrencyTypeId())) return false;
if (!getUserAmountsList()
.equals(other.getUserAmountsList())) return false;
if (!getIdempotencyId()
.equals(other.getIdempotencyId())) return false;
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();
hash = (37 * hash) + CURRENCY_TYPE_ID_FIELD_NUMBER;
hash = (53 * hash) + getCurrencyTypeId().hashCode();
if (getUserAmountsCount() > 0) {
hash = (37 * hash) + USER_AMOUNTS_FIELD_NUMBER;
hash = (53 * hash) + getUserAmountsList().hashCode();
}
hash = (37 * hash) + IDEMPOTENCY_ID_FIELD_NUMBER;
hash = (53 * hash) + getIdempotencyId().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest 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;
}
/**
*
* Issue currency call
*
*
* Protobuf type {@code saga.api.currency.IssueCurrencyRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:saga.api.currency.IssueCurrencyRequest)
games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return games.mythical.saga.sdk.proto.api.currency.Definition.internal_static_saga_api_currency_IssueCurrencyRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return games.mythical.saga.sdk.proto.api.currency.Definition.internal_static_saga_api_currency_IssueCurrencyRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.class, games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.Builder.class);
}
// Construct using games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
currencyTypeId_ = "";
if (userAmountsBuilder_ == null) {
userAmounts_ = java.util.Collections.emptyList();
} else {
userAmounts_ = null;
userAmountsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
idempotencyId_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return games.mythical.saga.sdk.proto.api.currency.Definition.internal_static_saga_api_currency_IssueCurrencyRequest_descriptor;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest getDefaultInstanceForType() {
return games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.getDefaultInstance();
}
@java.lang.Override
public games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest build() {
games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest buildPartial() {
games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest result = new games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest(this);
int from_bitField0_ = bitField0_;
result.currencyTypeId_ = currencyTypeId_;
if (userAmountsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
userAmounts_ = java.util.Collections.unmodifiableList(userAmounts_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.userAmounts_ = userAmounts_;
} else {
result.userAmounts_ = userAmountsBuilder_.build();
}
result.idempotencyId_ = idempotencyId_;
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.api.currency.IssueCurrencyRequest) {
return mergeFrom((games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest other) {
if (other == games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest.getDefaultInstance()) return this;
if (!other.getCurrencyTypeId().isEmpty()) {
currencyTypeId_ = other.currencyTypeId_;
onChanged();
}
if (userAmountsBuilder_ == null) {
if (!other.userAmounts_.isEmpty()) {
if (userAmounts_.isEmpty()) {
userAmounts_ = other.userAmounts_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureUserAmountsIsMutable();
userAmounts_.addAll(other.userAmounts_);
}
onChanged();
}
} else {
if (!other.userAmounts_.isEmpty()) {
if (userAmountsBuilder_.isEmpty()) {
userAmountsBuilder_.dispose();
userAmountsBuilder_ = null;
userAmounts_ = other.userAmounts_;
bitField0_ = (bitField0_ & ~0x00000001);
userAmountsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getUserAmountsFieldBuilder() : null;
} else {
userAmountsBuilder_.addAllMessages(other.userAmounts_);
}
}
}
if (!other.getIdempotencyId().isEmpty()) {
idempotencyId_ = other.idempotencyId_;
onChanged();
}
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: {
currencyTypeId_ = input.readStringRequireUtf8();
break;
} // case 10
case 18: {
games.mythical.saga.sdk.proto.api.currency.UserAmountProto m =
input.readMessage(
games.mythical.saga.sdk.proto.api.currency.UserAmountProto.parser(),
extensionRegistry);
if (userAmountsBuilder_ == null) {
ensureUserAmountsIsMutable();
userAmounts_.add(m);
} else {
userAmountsBuilder_.addMessage(m);
}
break;
} // case 18
case 26: {
idempotencyId_ = input.readStringRequireUtf8();
break;
} // case 26
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 bitField0_;
private java.lang.Object currencyTypeId_ = "";
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @return The currencyTypeId.
*/
public java.lang.String getCurrencyTypeId() {
java.lang.Object ref = currencyTypeId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
currencyTypeId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @return The bytes for currencyTypeId.
*/
public com.google.protobuf.ByteString
getCurrencyTypeIdBytes() {
java.lang.Object ref = currencyTypeId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
currencyTypeId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @param value The currencyTypeId to set.
* @return This builder for chaining.
*/
public Builder setCurrencyTypeId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
currencyTypeId_ = value;
onChanged();
return this;
}
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @return This builder for chaining.
*/
public Builder clearCurrencyTypeId() {
currencyTypeId_ = getDefaultInstance().getCurrencyTypeId();
onChanged();
return this;
}
/**
*
* Currency Type the currency to issue belongs to
*
*
* string currency_type_id = 1;
* @param value The bytes for currencyTypeId to set.
* @return This builder for chaining.
*/
public Builder setCurrencyTypeIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
currencyTypeId_ = value;
onChanged();
return this;
}
private java.util.List userAmounts_ =
java.util.Collections.emptyList();
private void ensureUserAmountsIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
userAmounts_ = new java.util.ArrayList(userAmounts_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
games.mythical.saga.sdk.proto.api.currency.UserAmountProto, games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder, games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder> userAmountsBuilder_;
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public java.util.List getUserAmountsList() {
if (userAmountsBuilder_ == null) {
return java.util.Collections.unmodifiableList(userAmounts_);
} else {
return userAmountsBuilder_.getMessageList();
}
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public int getUserAmountsCount() {
if (userAmountsBuilder_ == null) {
return userAmounts_.size();
} else {
return userAmountsBuilder_.getCount();
}
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public games.mythical.saga.sdk.proto.api.currency.UserAmountProto getUserAmounts(int index) {
if (userAmountsBuilder_ == null) {
return userAmounts_.get(index);
} else {
return userAmountsBuilder_.getMessage(index);
}
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder setUserAmounts(
int index, games.mythical.saga.sdk.proto.api.currency.UserAmountProto value) {
if (userAmountsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureUserAmountsIsMutable();
userAmounts_.set(index, value);
onChanged();
} else {
userAmountsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder setUserAmounts(
int index, games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder builderForValue) {
if (userAmountsBuilder_ == null) {
ensureUserAmountsIsMutable();
userAmounts_.set(index, builderForValue.build());
onChanged();
} else {
userAmountsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder addUserAmounts(games.mythical.saga.sdk.proto.api.currency.UserAmountProto value) {
if (userAmountsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureUserAmountsIsMutable();
userAmounts_.add(value);
onChanged();
} else {
userAmountsBuilder_.addMessage(value);
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder addUserAmounts(
int index, games.mythical.saga.sdk.proto.api.currency.UserAmountProto value) {
if (userAmountsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureUserAmountsIsMutable();
userAmounts_.add(index, value);
onChanged();
} else {
userAmountsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder addUserAmounts(
games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder builderForValue) {
if (userAmountsBuilder_ == null) {
ensureUserAmountsIsMutable();
userAmounts_.add(builderForValue.build());
onChanged();
} else {
userAmountsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder addUserAmounts(
int index, games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder builderForValue) {
if (userAmountsBuilder_ == null) {
ensureUserAmountsIsMutable();
userAmounts_.add(index, builderForValue.build());
onChanged();
} else {
userAmountsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder addAllUserAmounts(
java.lang.Iterable extends games.mythical.saga.sdk.proto.api.currency.UserAmountProto> values) {
if (userAmountsBuilder_ == null) {
ensureUserAmountsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, userAmounts_);
onChanged();
} else {
userAmountsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder clearUserAmounts() {
if (userAmountsBuilder_ == null) {
userAmounts_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
userAmountsBuilder_.clear();
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public Builder removeUserAmounts(int index) {
if (userAmountsBuilder_ == null) {
ensureUserAmountsIsMutable();
userAmounts_.remove(index);
onChanged();
} else {
userAmountsBuilder_.remove(index);
}
return this;
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder getUserAmountsBuilder(
int index) {
return getUserAmountsFieldBuilder().getBuilder(index);
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder getUserAmountsOrBuilder(
int index) {
if (userAmountsBuilder_ == null) {
return userAmounts_.get(index); } else {
return userAmountsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public java.util.List extends games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder>
getUserAmountsOrBuilderList() {
if (userAmountsBuilder_ != null) {
return userAmountsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(userAmounts_);
}
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder addUserAmountsBuilder() {
return getUserAmountsFieldBuilder().addBuilder(
games.mythical.saga.sdk.proto.api.currency.UserAmountProto.getDefaultInstance());
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder addUserAmountsBuilder(
int index) {
return getUserAmountsFieldBuilder().addBuilder(
index, games.mythical.saga.sdk.proto.api.currency.UserAmountProto.getDefaultInstance());
}
/**
*
* Users to issue currency to
*
*
* repeated .saga.api.currency.UserAmountProto user_amounts = 2;
*/
public java.util.List
getUserAmountsBuilderList() {
return getUserAmountsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
games.mythical.saga.sdk.proto.api.currency.UserAmountProto, games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder, games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder>
getUserAmountsFieldBuilder() {
if (userAmountsBuilder_ == null) {
userAmountsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
games.mythical.saga.sdk.proto.api.currency.UserAmountProto, games.mythical.saga.sdk.proto.api.currency.UserAmountProto.Builder, games.mythical.saga.sdk.proto.api.currency.UserAmountProtoOrBuilder>(
userAmounts_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
userAmounts_ = null;
}
return userAmountsBuilder_;
}
private java.lang.Object idempotencyId_ = "";
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @return The idempotencyId.
*/
public java.lang.String getIdempotencyId() {
java.lang.Object ref = idempotencyId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
idempotencyId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @return The bytes for idempotencyId.
*/
public com.google.protobuf.ByteString
getIdempotencyIdBytes() {
java.lang.Object ref = idempotencyId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
idempotencyId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @param value The idempotencyId to set.
* @return This builder for chaining.
*/
public Builder setIdempotencyId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
idempotencyId_ = value;
onChanged();
return this;
}
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @return This builder for chaining.
*/
public Builder clearIdempotencyId() {
idempotencyId_ = getDefaultInstance().getIdempotencyId();
onChanged();
return this;
}
/**
*
* Unique id to ensure request is processed only once
*
*
* string idempotency_id = 3;
* @param value The bytes for idempotencyId to set.
* @return This builder for chaining.
*/
public Builder setIdempotencyIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
idempotencyId_ = 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:saga.api.currency.IssueCurrencyRequest)
}
// @@protoc_insertion_point(class_scope:saga.api.currency.IssueCurrencyRequest)
private static final games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest();
}
public static games.mythical.saga.sdk.proto.api.currency.IssueCurrencyRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public IssueCurrencyRequest 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.api.currency.IssueCurrencyRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}