games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate 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/item/definition.proto
package games.mythical.saga.sdk.proto.streams.item;
/**
*
* Results from an Item status update gRPC stream call
*
*
* Protobuf type {@code saga.rpc.streams.item.ItemStatusUpdate}
*/
public final class ItemStatusUpdate extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:saga.rpc.streams.item.ItemStatusUpdate)
ItemStatusUpdateOrBuilder {
private static final long serialVersionUID = 0L;
// Use ItemStatusUpdate.newBuilder() to construct.
private ItemStatusUpdate(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ItemStatusUpdate() {
inventoryId_ = "";
itemTypeId_ = "";
oauthId_ = "";
metadataUrl_ = "";
itemState_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ItemStatusUpdate();
}
@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.item.Definition.internal_static_saga_rpc_streams_item_ItemStatusUpdate_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return games.mythical.saga.sdk.proto.streams.item.Definition.internal_static_saga_rpc_streams_item_ItemStatusUpdate_fieldAccessorTable
.ensureFieldAccessorsInitialized(
games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.class, games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.Builder.class);
}
public static final int INVENTORY_ID_FIELD_NUMBER = 1;
private volatile java.lang.Object inventoryId_;
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @return The inventoryId.
*/
@java.lang.Override
public java.lang.String getInventoryId() {
java.lang.Object ref = inventoryId_;
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();
inventoryId_ = s;
return s;
}
}
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @return The bytes for inventoryId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getInventoryIdBytes() {
java.lang.Object ref = inventoryId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
inventoryId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int ITEM_TYPE_ID_FIELD_NUMBER = 2;
private volatile java.lang.Object itemTypeId_;
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @return The itemTypeId.
*/
@java.lang.Override
public java.lang.String getItemTypeId() {
java.lang.Object ref = itemTypeId_;
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();
itemTypeId_ = s;
return s;
}
}
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @return The bytes for itemTypeId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getItemTypeIdBytes() {
java.lang.Object ref = itemTypeId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
itemTypeId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int OAUTH_ID_FIELD_NUMBER = 3;
private volatile java.lang.Object oauthId_;
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @return The oauthId.
*/
@java.lang.Override
public java.lang.String getOauthId() {
java.lang.Object ref = oauthId_;
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();
oauthId_ = s;
return s;
}
}
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @return The bytes for oauthId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getOauthIdBytes() {
java.lang.Object ref = oauthId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
oauthId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int TOKEN_ID_FIELD_NUMBER = 4;
private long tokenId_;
/**
* int64 token_id = 4;
* @return The tokenId.
*/
@java.lang.Override
public long getTokenId() {
return tokenId_;
}
public static final int METADATA_URL_FIELD_NUMBER = 5;
private volatile java.lang.Object metadataUrl_;
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @return The metadataUrl.
*/
@java.lang.Override
public java.lang.String getMetadataUrl() {
java.lang.Object ref = metadataUrl_;
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();
metadataUrl_ = s;
return s;
}
}
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @return The bytes for metadataUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getMetadataUrlBytes() {
java.lang.Object ref = metadataUrl_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
metadataUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int ITEM_STATE_FIELD_NUMBER = 8;
private int itemState_;
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @return The enum numeric value on the wire for itemState.
*/
@java.lang.Override public int getItemStateValue() {
return itemState_;
}
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @return The itemState.
*/
@java.lang.Override public games.mythical.saga.sdk.proto.common.item.ItemState getItemState() {
@SuppressWarnings("deprecation")
games.mythical.saga.sdk.proto.common.item.ItemState result = games.mythical.saga.sdk.proto.common.item.ItemState.valueOf(itemState_);
return result == null ? games.mythical.saga.sdk.proto.common.item.ItemState.UNRECOGNIZED : result;
}
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(inventoryId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, inventoryId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(itemTypeId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, itemTypeId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(oauthId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, oauthId_);
}
if (tokenId_ != 0L) {
output.writeInt64(4, tokenId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(metadataUrl_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, metadataUrl_);
}
if (itemState_ != games.mythical.saga.sdk.proto.common.item.ItemState.FAILED.getNumber()) {
output.writeEnum(8, itemState_);
}
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(inventoryId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, inventoryId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(itemTypeId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, itemTypeId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(oauthId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, oauthId_);
}
if (tokenId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(4, tokenId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(metadataUrl_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, metadataUrl_);
}
if (itemState_ != games.mythical.saga.sdk.proto.common.item.ItemState.FAILED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(8, itemState_);
}
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.item.ItemStatusUpdate)) {
return super.equals(obj);
}
games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate other = (games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate) obj;
if (!getInventoryId()
.equals(other.getInventoryId())) return false;
if (!getItemTypeId()
.equals(other.getItemTypeId())) return false;
if (!getOauthId()
.equals(other.getOauthId())) return false;
if (getTokenId()
!= other.getTokenId()) return false;
if (!getMetadataUrl()
.equals(other.getMetadataUrl())) return false;
if (itemState_ != other.itemState_) 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) + INVENTORY_ID_FIELD_NUMBER;
hash = (53 * hash) + getInventoryId().hashCode();
hash = (37 * hash) + ITEM_TYPE_ID_FIELD_NUMBER;
hash = (53 * hash) + getItemTypeId().hashCode();
hash = (37 * hash) + OAUTH_ID_FIELD_NUMBER;
hash = (53 * hash) + getOauthId().hashCode();
hash = (37 * hash) + TOKEN_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getTokenId());
hash = (37 * hash) + METADATA_URL_FIELD_NUMBER;
hash = (53 * hash) + getMetadataUrl().hashCode();
hash = (37 * hash) + ITEM_STATE_FIELD_NUMBER;
hash = (53 * hash) + itemState_;
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate 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.item.ItemStatusUpdate parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate 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.item.ItemStatusUpdate parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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.item.ItemStatusUpdate 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;
}
/**
*
* Results from an Item status update gRPC stream call
*
*
* Protobuf type {@code saga.rpc.streams.item.ItemStatusUpdate}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:saga.rpc.streams.item.ItemStatusUpdate)
games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdateOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return games.mythical.saga.sdk.proto.streams.item.Definition.internal_static_saga_rpc_streams_item_ItemStatusUpdate_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return games.mythical.saga.sdk.proto.streams.item.Definition.internal_static_saga_rpc_streams_item_ItemStatusUpdate_fieldAccessorTable
.ensureFieldAccessorsInitialized(
games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.class, games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.Builder.class);
}
// Construct using games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
inventoryId_ = "";
itemTypeId_ = "";
oauthId_ = "";
tokenId_ = 0L;
metadataUrl_ = "";
itemState_ = 0;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return games.mythical.saga.sdk.proto.streams.item.Definition.internal_static_saga_rpc_streams_item_ItemStatusUpdate_descriptor;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate getDefaultInstanceForType() {
return games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.getDefaultInstance();
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate build() {
games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate buildPartial() {
games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate result = new games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate(this);
result.inventoryId_ = inventoryId_;
result.itemTypeId_ = itemTypeId_;
result.oauthId_ = oauthId_;
result.tokenId_ = tokenId_;
result.metadataUrl_ = metadataUrl_;
result.itemState_ = itemState_;
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.item.ItemStatusUpdate) {
return mergeFrom((games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate other) {
if (other == games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate.getDefaultInstance()) return this;
if (!other.getInventoryId().isEmpty()) {
inventoryId_ = other.inventoryId_;
onChanged();
}
if (!other.getItemTypeId().isEmpty()) {
itemTypeId_ = other.itemTypeId_;
onChanged();
}
if (!other.getOauthId().isEmpty()) {
oauthId_ = other.oauthId_;
onChanged();
}
if (other.getTokenId() != 0L) {
setTokenId(other.getTokenId());
}
if (!other.getMetadataUrl().isEmpty()) {
metadataUrl_ = other.metadataUrl_;
onChanged();
}
if (other.itemState_ != 0) {
setItemStateValue(other.getItemStateValue());
}
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: {
inventoryId_ = input.readStringRequireUtf8();
break;
} // case 10
case 18: {
itemTypeId_ = input.readStringRequireUtf8();
break;
} // case 18
case 26: {
oauthId_ = input.readStringRequireUtf8();
break;
} // case 26
case 32: {
tokenId_ = input.readInt64();
break;
} // case 32
case 42: {
metadataUrl_ = input.readStringRequireUtf8();
break;
} // case 42
case 64: {
itemState_ = input.readEnum();
break;
} // case 64
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 java.lang.Object inventoryId_ = "";
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @return The inventoryId.
*/
public java.lang.String getInventoryId() {
java.lang.Object ref = inventoryId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
inventoryId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @return The bytes for inventoryId.
*/
public com.google.protobuf.ByteString
getInventoryIdBytes() {
java.lang.Object ref = inventoryId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
inventoryId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @param value The inventoryId to set.
* @return This builder for chaining.
*/
public Builder setInventoryId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
inventoryId_ = value;
onChanged();
return this;
}
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @return This builder for chaining.
*/
public Builder clearInventoryId() {
inventoryId_ = getDefaultInstance().getInventoryId();
onChanged();
return this;
}
/**
*
* Game's unique Id for the Item
*
*
* string inventory_id = 1;
* @param value The bytes for inventoryId to set.
* @return This builder for chaining.
*/
public Builder setInventoryIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
inventoryId_ = value;
onChanged();
return this;
}
private java.lang.Object itemTypeId_ = "";
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @return The itemTypeId.
*/
public java.lang.String getItemTypeId() {
java.lang.Object ref = itemTypeId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
itemTypeId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @return The bytes for itemTypeId.
*/
public com.google.protobuf.ByteString
getItemTypeIdBytes() {
java.lang.Object ref = itemTypeId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
itemTypeId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @param value The itemTypeId to set.
* @return This builder for chaining.
*/
public Builder setItemTypeId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
itemTypeId_ = value;
onChanged();
return this;
}
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @return This builder for chaining.
*/
public Builder clearItemTypeId() {
itemTypeId_ = getDefaultInstance().getItemTypeId();
onChanged();
return this;
}
/**
*
* Game's ItemTypeId for the ItemType for this Item
*
*
* string item_type_id = 2;
* @param value The bytes for itemTypeId to set.
* @return This builder for chaining.
*/
public Builder setItemTypeIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
itemTypeId_ = value;
onChanged();
return this;
}
private java.lang.Object oauthId_ = "";
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @return The oauthId.
*/
public java.lang.String getOauthId() {
java.lang.Object ref = oauthId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
oauthId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @return The bytes for oauthId.
*/
public com.google.protobuf.ByteString
getOauthIdBytes() {
java.lang.Object ref = oauthId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
oauthId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @param value The oauthId to set.
* @return This builder for chaining.
*/
public Builder setOauthId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
oauthId_ = value;
onChanged();
return this;
}
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @return This builder for chaining.
*/
public Builder clearOauthId() {
oauthId_ = getDefaultInstance().getOauthId();
onChanged();
return this;
}
/**
*
* User for this Item
*
*
* string oauth_id = 3;
* @param value The bytes for oauthId to set.
* @return This builder for chaining.
*/
public Builder setOauthIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
oauthId_ = value;
onChanged();
return this;
}
private long tokenId_ ;
/**
* int64 token_id = 4;
* @return The tokenId.
*/
@java.lang.Override
public long getTokenId() {
return tokenId_;
}
/**
* int64 token_id = 4;
* @param value The tokenId to set.
* @return This builder for chaining.
*/
public Builder setTokenId(long value) {
tokenId_ = value;
onChanged();
return this;
}
/**
* int64 token_id = 4;
* @return This builder for chaining.
*/
public Builder clearTokenId() {
tokenId_ = 0L;
onChanged();
return this;
}
private java.lang.Object metadataUrl_ = "";
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @return The metadataUrl.
*/
public java.lang.String getMetadataUrl() {
java.lang.Object ref = metadataUrl_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
metadataUrl_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @return The bytes for metadataUrl.
*/
public com.google.protobuf.ByteString
getMetadataUrlBytes() {
java.lang.Object ref = metadataUrl_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
metadataUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @param value The metadataUrl to set.
* @return This builder for chaining.
*/
public Builder setMetadataUrl(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
metadataUrl_ = value;
onChanged();
return this;
}
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @return This builder for chaining.
*/
public Builder clearMetadataUrl() {
metadataUrl_ = getDefaultInstance().getMetadataUrl();
onChanged();
return this;
}
/**
*
* Metadata address
*
*
* string metadata_url = 5;
* @param value The bytes for metadataUrl to set.
* @return This builder for chaining.
*/
public Builder setMetadataUrlBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
metadataUrl_ = value;
onChanged();
return this;
}
private int itemState_ = 0;
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @return The enum numeric value on the wire for itemState.
*/
@java.lang.Override public int getItemStateValue() {
return itemState_;
}
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @param value The enum numeric value on the wire for itemState to set.
* @return This builder for chaining.
*/
public Builder setItemStateValue(int value) {
itemState_ = value;
onChanged();
return this;
}
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @return The itemState.
*/
@java.lang.Override
public games.mythical.saga.sdk.proto.common.item.ItemState getItemState() {
@SuppressWarnings("deprecation")
games.mythical.saga.sdk.proto.common.item.ItemState result = games.mythical.saga.sdk.proto.common.item.ItemState.valueOf(itemState_);
return result == null ? games.mythical.saga.sdk.proto.common.item.ItemState.UNRECOGNIZED : result;
}
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @param value The itemState to set.
* @return This builder for chaining.
*/
public Builder setItemState(games.mythical.saga.sdk.proto.common.item.ItemState value) {
if (value == null) {
throw new NullPointerException();
}
itemState_ = value.getNumber();
onChanged();
return this;
}
/**
*
* State of the Item, see ItemState
*
*
* .saga.proto.common.item.ItemState item_state = 8;
* @return This builder for chaining.
*/
public Builder clearItemState() {
itemState_ = 0;
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.rpc.streams.item.ItemStatusUpdate)
}
// @@protoc_insertion_point(class_scope:saga.rpc.streams.item.ItemStatusUpdate)
private static final games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate();
}
public static games.mythical.saga.sdk.proto.streams.item.ItemStatusUpdate getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ItemStatusUpdate 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.item.ItemStatusUpdate getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}