All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.hederahashgraph.api.proto.java.TokenReference Maven / Gradle / Ivy

There is a newer version: 0.57.1
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: token_reject.proto

package com.hederahashgraph.api.proto.java;

/**
 * 
 **
 * A union token identifier.
 * Identify a fungible/common token type, or a single non-fungible/unique token serial.
 * 
* * Protobuf type {@code proto.TokenReference} */ public final class TokenReference extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:proto.TokenReference) TokenReferenceOrBuilder { private static final long serialVersionUID = 0L; // Use TokenReference.newBuilder() to construct. private TokenReference(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private TokenReference() { } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new TokenReference(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private TokenReference( 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 10: { com.hederahashgraph.api.proto.java.TokenID.Builder subBuilder = null; if (tokenIdentifierCase_ == 1) { subBuilder = ((com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_).toBuilder(); } tokenIdentifier_ = input.readMessage(com.hederahashgraph.api.proto.java.TokenID.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_); tokenIdentifier_ = subBuilder.buildPartial(); } tokenIdentifierCase_ = 1; break; } case 18: { com.hederahashgraph.api.proto.java.NftID.Builder subBuilder = null; if (tokenIdentifierCase_ == 2) { subBuilder = ((com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_).toBuilder(); } tokenIdentifier_ = input.readMessage(com.hederahashgraph.api.proto.java.NftID.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom((com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_); tokenIdentifier_ = subBuilder.buildPartial(); } tokenIdentifierCase_ = 2; 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 com.hederahashgraph.api.proto.java.TokenReject.internal_static_proto_TokenReference_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.hederahashgraph.api.proto.java.TokenReject.internal_static_proto_TokenReference_fieldAccessorTable .ensureFieldAccessorsInitialized( com.hederahashgraph.api.proto.java.TokenReference.class, com.hederahashgraph.api.proto.java.TokenReference.Builder.class); } private int tokenIdentifierCase_ = 0; private java.lang.Object tokenIdentifier_; public enum TokenIdentifierCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { FUNGIBLE_TOKEN(1), NFT(2), TOKENIDENTIFIER_NOT_SET(0); private final int value; private TokenIdentifierCase(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 TokenIdentifierCase valueOf(int value) { return forNumber(value); } public static TokenIdentifierCase forNumber(int value) { switch (value) { case 1: return FUNGIBLE_TOKEN; case 2: return NFT; case 0: return TOKENIDENTIFIER_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public TokenIdentifierCase getTokenIdentifierCase() { return TokenIdentifierCase.forNumber( tokenIdentifierCase_); } public static final int FUNGIBLE_TOKEN_FIELD_NUMBER = 1; /** *
   **
   * A fungible/common token type.
   * 
* * .proto.TokenID fungible_token = 1; * @return Whether the fungibleToken field is set. */ @java.lang.Override public boolean hasFungibleToken() { return tokenIdentifierCase_ == 1; } /** *
   **
   * A fungible/common token type.
   * 
* * .proto.TokenID fungible_token = 1; * @return The fungibleToken. */ @java.lang.Override public com.hederahashgraph.api.proto.java.TokenID getFungibleToken() { if (tokenIdentifierCase_ == 1) { return (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance(); } /** *
   **
   * A fungible/common token type.
   * 
* * .proto.TokenID fungible_token = 1; */ @java.lang.Override public com.hederahashgraph.api.proto.java.TokenIDOrBuilder getFungibleTokenOrBuilder() { if (tokenIdentifierCase_ == 1) { return (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance(); } public static final int NFT_FIELD_NUMBER = 2; /** *
   **
   * A single specific serialized non-fungible/unique token.
   * 
* * .proto.NftID nft = 2; * @return Whether the nft field is set. */ @java.lang.Override public boolean hasNft() { return tokenIdentifierCase_ == 2; } /** *
   **
   * A single specific serialized non-fungible/unique token.
   * 
* * .proto.NftID nft = 2; * @return The nft. */ @java.lang.Override public com.hederahashgraph.api.proto.java.NftID getNft() { if (tokenIdentifierCase_ == 2) { return (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.NftID.getDefaultInstance(); } /** *
   **
   * A single specific serialized non-fungible/unique token.
   * 
* * .proto.NftID nft = 2; */ @java.lang.Override public com.hederahashgraph.api.proto.java.NftIDOrBuilder getNftOrBuilder() { if (tokenIdentifierCase_ == 2) { return (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.NftID.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 (tokenIdentifierCase_ == 1) { output.writeMessage(1, (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_); } if (tokenIdentifierCase_ == 2) { output.writeMessage(2, (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (tokenIdentifierCase_ == 1) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_); } if (tokenIdentifierCase_ == 2) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_); } 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 com.hederahashgraph.api.proto.java.TokenReference)) { return super.equals(obj); } com.hederahashgraph.api.proto.java.TokenReference other = (com.hederahashgraph.api.proto.java.TokenReference) obj; if (!getTokenIdentifierCase().equals(other.getTokenIdentifierCase())) return false; switch (tokenIdentifierCase_) { case 1: if (!getFungibleToken() .equals(other.getFungibleToken())) return false; break; case 2: if (!getNft() .equals(other.getNft())) return false; break; case 0: default: } 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(); switch (tokenIdentifierCase_) { case 1: hash = (37 * hash) + FUNGIBLE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getFungibleToken().hashCode(); break; case 2: hash = (37 * hash) + NFT_FIELD_NUMBER; hash = (53 * hash) + getNft().hashCode(); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hederahashgraph.api.proto.java.TokenReference parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.hederahashgraph.api.proto.java.TokenReference 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 com.hederahashgraph.api.proto.java.TokenReference parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.hederahashgraph.api.proto.java.TokenReference 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 com.hederahashgraph.api.proto.java.TokenReference parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.hederahashgraph.api.proto.java.TokenReference 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(com.hederahashgraph.api.proto.java.TokenReference 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; } /** *
   **
   * A union token identifier.
   * Identify a fungible/common token type, or a single non-fungible/unique token serial.
   * 
* * Protobuf type {@code proto.TokenReference} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:proto.TokenReference) com.hederahashgraph.api.proto.java.TokenReferenceOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.hederahashgraph.api.proto.java.TokenReject.internal_static_proto_TokenReference_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.hederahashgraph.api.proto.java.TokenReject.internal_static_proto_TokenReference_fieldAccessorTable .ensureFieldAccessorsInitialized( com.hederahashgraph.api.proto.java.TokenReference.class, com.hederahashgraph.api.proto.java.TokenReference.Builder.class); } // Construct using com.hederahashgraph.api.proto.java.TokenReference.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(); tokenIdentifierCase_ = 0; tokenIdentifier_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.hederahashgraph.api.proto.java.TokenReject.internal_static_proto_TokenReference_descriptor; } @java.lang.Override public com.hederahashgraph.api.proto.java.TokenReference getDefaultInstanceForType() { return com.hederahashgraph.api.proto.java.TokenReference.getDefaultInstance(); } @java.lang.Override public com.hederahashgraph.api.proto.java.TokenReference build() { com.hederahashgraph.api.proto.java.TokenReference result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.hederahashgraph.api.proto.java.TokenReference buildPartial() { com.hederahashgraph.api.proto.java.TokenReference result = new com.hederahashgraph.api.proto.java.TokenReference(this); if (tokenIdentifierCase_ == 1) { if (fungibleTokenBuilder_ == null) { result.tokenIdentifier_ = tokenIdentifier_; } else { result.tokenIdentifier_ = fungibleTokenBuilder_.build(); } } if (tokenIdentifierCase_ == 2) { if (nftBuilder_ == null) { result.tokenIdentifier_ = tokenIdentifier_; } else { result.tokenIdentifier_ = nftBuilder_.build(); } } result.tokenIdentifierCase_ = tokenIdentifierCase_; 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 com.hederahashgraph.api.proto.java.TokenReference) { return mergeFrom((com.hederahashgraph.api.proto.java.TokenReference)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.hederahashgraph.api.proto.java.TokenReference other) { if (other == com.hederahashgraph.api.proto.java.TokenReference.getDefaultInstance()) return this; switch (other.getTokenIdentifierCase()) { case FUNGIBLE_TOKEN: { mergeFungibleToken(other.getFungibleToken()); break; } case NFT: { mergeNft(other.getNft()); break; } case TOKENIDENTIFIER_NOT_SET: { break; } } 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 { com.hederahashgraph.api.proto.java.TokenReference parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.hederahashgraph.api.proto.java.TokenReference) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int tokenIdentifierCase_ = 0; private java.lang.Object tokenIdentifier_; public TokenIdentifierCase getTokenIdentifierCase() { return TokenIdentifierCase.forNumber( tokenIdentifierCase_); } public Builder clearTokenIdentifier() { tokenIdentifierCase_ = 0; tokenIdentifier_ = null; onChanged(); return this; } private com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.TokenID, com.hederahashgraph.api.proto.java.TokenID.Builder, com.hederahashgraph.api.proto.java.TokenIDOrBuilder> fungibleTokenBuilder_; /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; * @return Whether the fungibleToken field is set. */ @java.lang.Override public boolean hasFungibleToken() { return tokenIdentifierCase_ == 1; } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; * @return The fungibleToken. */ @java.lang.Override public com.hederahashgraph.api.proto.java.TokenID getFungibleToken() { if (fungibleTokenBuilder_ == null) { if (tokenIdentifierCase_ == 1) { return (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance(); } else { if (tokenIdentifierCase_ == 1) { return fungibleTokenBuilder_.getMessage(); } return com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance(); } } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ public Builder setFungibleToken(com.hederahashgraph.api.proto.java.TokenID value) { if (fungibleTokenBuilder_ == null) { if (value == null) { throw new NullPointerException(); } tokenIdentifier_ = value; onChanged(); } else { fungibleTokenBuilder_.setMessage(value); } tokenIdentifierCase_ = 1; return this; } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ public Builder setFungibleToken( com.hederahashgraph.api.proto.java.TokenID.Builder builderForValue) { if (fungibleTokenBuilder_ == null) { tokenIdentifier_ = builderForValue.build(); onChanged(); } else { fungibleTokenBuilder_.setMessage(builderForValue.build()); } tokenIdentifierCase_ = 1; return this; } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ public Builder mergeFungibleToken(com.hederahashgraph.api.proto.java.TokenID value) { if (fungibleTokenBuilder_ == null) { if (tokenIdentifierCase_ == 1 && tokenIdentifier_ != com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance()) { tokenIdentifier_ = com.hederahashgraph.api.proto.java.TokenID.newBuilder((com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_) .mergeFrom(value).buildPartial(); } else { tokenIdentifier_ = value; } onChanged(); } else { if (tokenIdentifierCase_ == 1) { fungibleTokenBuilder_.mergeFrom(value); } fungibleTokenBuilder_.setMessage(value); } tokenIdentifierCase_ = 1; return this; } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ public Builder clearFungibleToken() { if (fungibleTokenBuilder_ == null) { if (tokenIdentifierCase_ == 1) { tokenIdentifierCase_ = 0; tokenIdentifier_ = null; onChanged(); } } else { if (tokenIdentifierCase_ == 1) { tokenIdentifierCase_ = 0; tokenIdentifier_ = null; } fungibleTokenBuilder_.clear(); } return this; } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ public com.hederahashgraph.api.proto.java.TokenID.Builder getFungibleTokenBuilder() { return getFungibleTokenFieldBuilder().getBuilder(); } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ @java.lang.Override public com.hederahashgraph.api.proto.java.TokenIDOrBuilder getFungibleTokenOrBuilder() { if ((tokenIdentifierCase_ == 1) && (fungibleTokenBuilder_ != null)) { return fungibleTokenBuilder_.getMessageOrBuilder(); } else { if (tokenIdentifierCase_ == 1) { return (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance(); } } /** *
     **
     * A fungible/common token type.
     * 
* * .proto.TokenID fungible_token = 1; */ private com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.TokenID, com.hederahashgraph.api.proto.java.TokenID.Builder, com.hederahashgraph.api.proto.java.TokenIDOrBuilder> getFungibleTokenFieldBuilder() { if (fungibleTokenBuilder_ == null) { if (!(tokenIdentifierCase_ == 1)) { tokenIdentifier_ = com.hederahashgraph.api.proto.java.TokenID.getDefaultInstance(); } fungibleTokenBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.TokenID, com.hederahashgraph.api.proto.java.TokenID.Builder, com.hederahashgraph.api.proto.java.TokenIDOrBuilder>( (com.hederahashgraph.api.proto.java.TokenID) tokenIdentifier_, getParentForChildren(), isClean()); tokenIdentifier_ = null; } tokenIdentifierCase_ = 1; onChanged();; return fungibleTokenBuilder_; } private com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.NftID, com.hederahashgraph.api.proto.java.NftID.Builder, com.hederahashgraph.api.proto.java.NftIDOrBuilder> nftBuilder_; /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; * @return Whether the nft field is set. */ @java.lang.Override public boolean hasNft() { return tokenIdentifierCase_ == 2; } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; * @return The nft. */ @java.lang.Override public com.hederahashgraph.api.proto.java.NftID getNft() { if (nftBuilder_ == null) { if (tokenIdentifierCase_ == 2) { return (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.NftID.getDefaultInstance(); } else { if (tokenIdentifierCase_ == 2) { return nftBuilder_.getMessage(); } return com.hederahashgraph.api.proto.java.NftID.getDefaultInstance(); } } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ public Builder setNft(com.hederahashgraph.api.proto.java.NftID value) { if (nftBuilder_ == null) { if (value == null) { throw new NullPointerException(); } tokenIdentifier_ = value; onChanged(); } else { nftBuilder_.setMessage(value); } tokenIdentifierCase_ = 2; return this; } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ public Builder setNft( com.hederahashgraph.api.proto.java.NftID.Builder builderForValue) { if (nftBuilder_ == null) { tokenIdentifier_ = builderForValue.build(); onChanged(); } else { nftBuilder_.setMessage(builderForValue.build()); } tokenIdentifierCase_ = 2; return this; } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ public Builder mergeNft(com.hederahashgraph.api.proto.java.NftID value) { if (nftBuilder_ == null) { if (tokenIdentifierCase_ == 2 && tokenIdentifier_ != com.hederahashgraph.api.proto.java.NftID.getDefaultInstance()) { tokenIdentifier_ = com.hederahashgraph.api.proto.java.NftID.newBuilder((com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_) .mergeFrom(value).buildPartial(); } else { tokenIdentifier_ = value; } onChanged(); } else { if (tokenIdentifierCase_ == 2) { nftBuilder_.mergeFrom(value); } nftBuilder_.setMessage(value); } tokenIdentifierCase_ = 2; return this; } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ public Builder clearNft() { if (nftBuilder_ == null) { if (tokenIdentifierCase_ == 2) { tokenIdentifierCase_ = 0; tokenIdentifier_ = null; onChanged(); } } else { if (tokenIdentifierCase_ == 2) { tokenIdentifierCase_ = 0; tokenIdentifier_ = null; } nftBuilder_.clear(); } return this; } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ public com.hederahashgraph.api.proto.java.NftID.Builder getNftBuilder() { return getNftFieldBuilder().getBuilder(); } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ @java.lang.Override public com.hederahashgraph.api.proto.java.NftIDOrBuilder getNftOrBuilder() { if ((tokenIdentifierCase_ == 2) && (nftBuilder_ != null)) { return nftBuilder_.getMessageOrBuilder(); } else { if (tokenIdentifierCase_ == 2) { return (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_; } return com.hederahashgraph.api.proto.java.NftID.getDefaultInstance(); } } /** *
     **
     * A single specific serialized non-fungible/unique token.
     * 
* * .proto.NftID nft = 2; */ private com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.NftID, com.hederahashgraph.api.proto.java.NftID.Builder, com.hederahashgraph.api.proto.java.NftIDOrBuilder> getNftFieldBuilder() { if (nftBuilder_ == null) { if (!(tokenIdentifierCase_ == 2)) { tokenIdentifier_ = com.hederahashgraph.api.proto.java.NftID.getDefaultInstance(); } nftBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.NftID, com.hederahashgraph.api.proto.java.NftID.Builder, com.hederahashgraph.api.proto.java.NftIDOrBuilder>( (com.hederahashgraph.api.proto.java.NftID) tokenIdentifier_, getParentForChildren(), isClean()); tokenIdentifier_ = null; } tokenIdentifierCase_ = 2; onChanged();; return nftBuilder_; } @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.TokenReference) } // @@protoc_insertion_point(class_scope:proto.TokenReference) private static final com.hederahashgraph.api.proto.java.TokenReference DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.hederahashgraph.api.proto.java.TokenReference(); } public static com.hederahashgraph.api.proto.java.TokenReference getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public TokenReference parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new TokenReference(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 com.hederahashgraph.api.proto.java.TokenReference getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy