com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: crypto_approve_allowance.proto
package com.hederahashgraph.api.proto.java;
/**
*
**
* Creates one or more hbar/token approved allowances <b>relative to the owner account specified in the allowances of
* this transaction</b>. Each allowance grants a spender the right to transfer a pre-determined amount of the owner's
* hbar/token to any other account of the spender's choice. If the owner is not specified in any allowance, the payer
* of transaction is considered to be the owner for that particular allowance.
* Setting the amount to zero in CryptoAllowance or TokenAllowance will remove the respective allowance for the spender.
*
* (So if account <tt>0.0.X</tt> pays for this transaction and owner is not specified in the allowance,
* then at consensus each spender account will have new allowances to spend hbar or tokens from <tt>0.0.X</tt>).
*
*
* Protobuf type {@code proto.CryptoApproveAllowanceTransactionBody}
*/
public final class CryptoApproveAllowanceTransactionBody extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:proto.CryptoApproveAllowanceTransactionBody)
CryptoApproveAllowanceTransactionBodyOrBuilder {
private static final long serialVersionUID = 0L;
// Use CryptoApproveAllowanceTransactionBody.newBuilder() to construct.
private CryptoApproveAllowanceTransactionBody(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private CryptoApproveAllowanceTransactionBody() {
cryptoAllowances_ = java.util.Collections.emptyList();
nftAllowances_ = java.util.Collections.emptyList();
tokenAllowances_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new CryptoApproveAllowanceTransactionBody();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private CryptoApproveAllowanceTransactionBody(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
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: {
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
cryptoAllowances_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000001;
}
cryptoAllowances_.add(
input.readMessage(com.hederahashgraph.api.proto.java.CryptoAllowance.parser(), extensionRegistry));
break;
}
case 18: {
if (!((mutable_bitField0_ & 0x00000002) != 0)) {
nftAllowances_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
nftAllowances_.add(
input.readMessage(com.hederahashgraph.api.proto.java.NftAllowance.parser(), extensionRegistry));
break;
}
case 26: {
if (!((mutable_bitField0_ & 0x00000004) != 0)) {
tokenAllowances_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000004;
}
tokenAllowances_.add(
input.readMessage(com.hederahashgraph.api.proto.java.TokenAllowance.parser(), extensionRegistry));
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 {
if (((mutable_bitField0_ & 0x00000001) != 0)) {
cryptoAllowances_ = java.util.Collections.unmodifiableList(cryptoAllowances_);
}
if (((mutable_bitField0_ & 0x00000002) != 0)) {
nftAllowances_ = java.util.Collections.unmodifiableList(nftAllowances_);
}
if (((mutable_bitField0_ & 0x00000004) != 0)) {
tokenAllowances_ = java.util.Collections.unmodifiableList(tokenAllowances_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hederahashgraph.api.proto.java.CryptoApproveAllowance.internal_static_proto_CryptoApproveAllowanceTransactionBody_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hederahashgraph.api.proto.java.CryptoApproveAllowance.internal_static_proto_CryptoApproveAllowanceTransactionBody_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.class, com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.Builder.class);
}
public static final int CRYPTOALLOWANCES_FIELD_NUMBER = 1;
private java.util.List cryptoAllowances_;
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
@java.lang.Override
public java.util.List getCryptoAllowancesList() {
return cryptoAllowances_;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
@java.lang.Override
public java.util.List extends com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder>
getCryptoAllowancesOrBuilderList() {
return cryptoAllowances_;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
@java.lang.Override
public int getCryptoAllowancesCount() {
return cryptoAllowances_.size();
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.CryptoAllowance getCryptoAllowances(int index) {
return cryptoAllowances_.get(index);
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder getCryptoAllowancesOrBuilder(
int index) {
return cryptoAllowances_.get(index);
}
public static final int NFTALLOWANCES_FIELD_NUMBER = 2;
private java.util.List nftAllowances_;
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
@java.lang.Override
public java.util.List getNftAllowancesList() {
return nftAllowances_;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
@java.lang.Override
public java.util.List extends com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder>
getNftAllowancesOrBuilderList() {
return nftAllowances_;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
@java.lang.Override
public int getNftAllowancesCount() {
return nftAllowances_.size();
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.NftAllowance getNftAllowances(int index) {
return nftAllowances_.get(index);
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder getNftAllowancesOrBuilder(
int index) {
return nftAllowances_.get(index);
}
public static final int TOKENALLOWANCES_FIELD_NUMBER = 3;
private java.util.List tokenAllowances_;
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
@java.lang.Override
public java.util.List getTokenAllowancesList() {
return tokenAllowances_;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
@java.lang.Override
public java.util.List extends com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder>
getTokenAllowancesOrBuilderList() {
return tokenAllowances_;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
@java.lang.Override
public int getTokenAllowancesCount() {
return tokenAllowances_.size();
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.TokenAllowance getTokenAllowances(int index) {
return tokenAllowances_.get(index);
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder getTokenAllowancesOrBuilder(
int index) {
return tokenAllowances_.get(index);
}
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 {
for (int i = 0; i < cryptoAllowances_.size(); i++) {
output.writeMessage(1, cryptoAllowances_.get(i));
}
for (int i = 0; i < nftAllowances_.size(); i++) {
output.writeMessage(2, nftAllowances_.get(i));
}
for (int i = 0; i < tokenAllowances_.size(); i++) {
output.writeMessage(3, tokenAllowances_.get(i));
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < cryptoAllowances_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, cryptoAllowances_.get(i));
}
for (int i = 0; i < nftAllowances_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, nftAllowances_.get(i));
}
for (int i = 0; i < tokenAllowances_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, tokenAllowances_.get(i));
}
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.CryptoApproveAllowanceTransactionBody)) {
return super.equals(obj);
}
com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody other = (com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody) obj;
if (!getCryptoAllowancesList()
.equals(other.getCryptoAllowancesList())) return false;
if (!getNftAllowancesList()
.equals(other.getNftAllowancesList())) return false;
if (!getTokenAllowancesList()
.equals(other.getTokenAllowancesList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getCryptoAllowancesCount() > 0) {
hash = (37 * hash) + CRYPTOALLOWANCES_FIELD_NUMBER;
hash = (53 * hash) + getCryptoAllowancesList().hashCode();
}
if (getNftAllowancesCount() > 0) {
hash = (37 * hash) + NFTALLOWANCES_FIELD_NUMBER;
hash = (53 * hash) + getNftAllowancesList().hashCode();
}
if (getTokenAllowancesCount() > 0) {
hash = (37 * hash) + TOKENALLOWANCES_FIELD_NUMBER;
hash = (53 * hash) + getTokenAllowancesList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody 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.CryptoApproveAllowanceTransactionBody 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;
}
/**
*
**
* Creates one or more hbar/token approved allowances <b>relative to the owner account specified in the allowances of
* this transaction</b>. Each allowance grants a spender the right to transfer a pre-determined amount of the owner's
* hbar/token to any other account of the spender's choice. If the owner is not specified in any allowance, the payer
* of transaction is considered to be the owner for that particular allowance.
* Setting the amount to zero in CryptoAllowance or TokenAllowance will remove the respective allowance for the spender.
*
* (So if account <tt>0.0.X</tt> pays for this transaction and owner is not specified in the allowance,
* then at consensus each spender account will have new allowances to spend hbar or tokens from <tt>0.0.X</tt>).
*
*
* Protobuf type {@code proto.CryptoApproveAllowanceTransactionBody}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:proto.CryptoApproveAllowanceTransactionBody)
com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBodyOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hederahashgraph.api.proto.java.CryptoApproveAllowance.internal_static_proto_CryptoApproveAllowanceTransactionBody_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hederahashgraph.api.proto.java.CryptoApproveAllowance.internal_static_proto_CryptoApproveAllowanceTransactionBody_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.class, com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.Builder.class);
}
// Construct using com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getCryptoAllowancesFieldBuilder();
getNftAllowancesFieldBuilder();
getTokenAllowancesFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (cryptoAllowancesBuilder_ == null) {
cryptoAllowances_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
} else {
cryptoAllowancesBuilder_.clear();
}
if (nftAllowancesBuilder_ == null) {
nftAllowances_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
} else {
nftAllowancesBuilder_.clear();
}
if (tokenAllowancesBuilder_ == null) {
tokenAllowances_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
} else {
tokenAllowancesBuilder_.clear();
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.hederahashgraph.api.proto.java.CryptoApproveAllowance.internal_static_proto_CryptoApproveAllowanceTransactionBody_descriptor;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody getDefaultInstanceForType() {
return com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.getDefaultInstance();
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody build() {
com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody buildPartial() {
com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody result = new com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody(this);
int from_bitField0_ = bitField0_;
if (cryptoAllowancesBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
cryptoAllowances_ = java.util.Collections.unmodifiableList(cryptoAllowances_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.cryptoAllowances_ = cryptoAllowances_;
} else {
result.cryptoAllowances_ = cryptoAllowancesBuilder_.build();
}
if (nftAllowancesBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
nftAllowances_ = java.util.Collections.unmodifiableList(nftAllowances_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.nftAllowances_ = nftAllowances_;
} else {
result.nftAllowances_ = nftAllowancesBuilder_.build();
}
if (tokenAllowancesBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0)) {
tokenAllowances_ = java.util.Collections.unmodifiableList(tokenAllowances_);
bitField0_ = (bitField0_ & ~0x00000004);
}
result.tokenAllowances_ = tokenAllowances_;
} else {
result.tokenAllowances_ = tokenAllowancesBuilder_.build();
}
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.CryptoApproveAllowanceTransactionBody) {
return mergeFrom((com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody other) {
if (other == com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody.getDefaultInstance()) return this;
if (cryptoAllowancesBuilder_ == null) {
if (!other.cryptoAllowances_.isEmpty()) {
if (cryptoAllowances_.isEmpty()) {
cryptoAllowances_ = other.cryptoAllowances_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.addAll(other.cryptoAllowances_);
}
onChanged();
}
} else {
if (!other.cryptoAllowances_.isEmpty()) {
if (cryptoAllowancesBuilder_.isEmpty()) {
cryptoAllowancesBuilder_.dispose();
cryptoAllowancesBuilder_ = null;
cryptoAllowances_ = other.cryptoAllowances_;
bitField0_ = (bitField0_ & ~0x00000001);
cryptoAllowancesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getCryptoAllowancesFieldBuilder() : null;
} else {
cryptoAllowancesBuilder_.addAllMessages(other.cryptoAllowances_);
}
}
}
if (nftAllowancesBuilder_ == null) {
if (!other.nftAllowances_.isEmpty()) {
if (nftAllowances_.isEmpty()) {
nftAllowances_ = other.nftAllowances_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureNftAllowancesIsMutable();
nftAllowances_.addAll(other.nftAllowances_);
}
onChanged();
}
} else {
if (!other.nftAllowances_.isEmpty()) {
if (nftAllowancesBuilder_.isEmpty()) {
nftAllowancesBuilder_.dispose();
nftAllowancesBuilder_ = null;
nftAllowances_ = other.nftAllowances_;
bitField0_ = (bitField0_ & ~0x00000002);
nftAllowancesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getNftAllowancesFieldBuilder() : null;
} else {
nftAllowancesBuilder_.addAllMessages(other.nftAllowances_);
}
}
}
if (tokenAllowancesBuilder_ == null) {
if (!other.tokenAllowances_.isEmpty()) {
if (tokenAllowances_.isEmpty()) {
tokenAllowances_ = other.tokenAllowances_;
bitField0_ = (bitField0_ & ~0x00000004);
} else {
ensureTokenAllowancesIsMutable();
tokenAllowances_.addAll(other.tokenAllowances_);
}
onChanged();
}
} else {
if (!other.tokenAllowances_.isEmpty()) {
if (tokenAllowancesBuilder_.isEmpty()) {
tokenAllowancesBuilder_.dispose();
tokenAllowancesBuilder_ = null;
tokenAllowances_ = other.tokenAllowances_;
bitField0_ = (bitField0_ & ~0x00000004);
tokenAllowancesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getTokenAllowancesFieldBuilder() : null;
} else {
tokenAllowancesBuilder_.addAllMessages(other.tokenAllowances_);
}
}
}
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.CryptoApproveAllowanceTransactionBody parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private java.util.List cryptoAllowances_ =
java.util.Collections.emptyList();
private void ensureCryptoAllowancesIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
cryptoAllowances_ = new java.util.ArrayList(cryptoAllowances_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.CryptoAllowance, com.hederahashgraph.api.proto.java.CryptoAllowance.Builder, com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder> cryptoAllowancesBuilder_;
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public java.util.List getCryptoAllowancesList() {
if (cryptoAllowancesBuilder_ == null) {
return java.util.Collections.unmodifiableList(cryptoAllowances_);
} else {
return cryptoAllowancesBuilder_.getMessageList();
}
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public int getCryptoAllowancesCount() {
if (cryptoAllowancesBuilder_ == null) {
return cryptoAllowances_.size();
} else {
return cryptoAllowancesBuilder_.getCount();
}
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public com.hederahashgraph.api.proto.java.CryptoAllowance getCryptoAllowances(int index) {
if (cryptoAllowancesBuilder_ == null) {
return cryptoAllowances_.get(index);
} else {
return cryptoAllowancesBuilder_.getMessage(index);
}
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder setCryptoAllowances(
int index, com.hederahashgraph.api.proto.java.CryptoAllowance value) {
if (cryptoAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.set(index, value);
onChanged();
} else {
cryptoAllowancesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder setCryptoAllowances(
int index, com.hederahashgraph.api.proto.java.CryptoAllowance.Builder builderForValue) {
if (cryptoAllowancesBuilder_ == null) {
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.set(index, builderForValue.build());
onChanged();
} else {
cryptoAllowancesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder addCryptoAllowances(com.hederahashgraph.api.proto.java.CryptoAllowance value) {
if (cryptoAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.add(value);
onChanged();
} else {
cryptoAllowancesBuilder_.addMessage(value);
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder addCryptoAllowances(
int index, com.hederahashgraph.api.proto.java.CryptoAllowance value) {
if (cryptoAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.add(index, value);
onChanged();
} else {
cryptoAllowancesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder addCryptoAllowances(
com.hederahashgraph.api.proto.java.CryptoAllowance.Builder builderForValue) {
if (cryptoAllowancesBuilder_ == null) {
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.add(builderForValue.build());
onChanged();
} else {
cryptoAllowancesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder addCryptoAllowances(
int index, com.hederahashgraph.api.proto.java.CryptoAllowance.Builder builderForValue) {
if (cryptoAllowancesBuilder_ == null) {
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.add(index, builderForValue.build());
onChanged();
} else {
cryptoAllowancesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder addAllCryptoAllowances(
java.lang.Iterable extends com.hederahashgraph.api.proto.java.CryptoAllowance> values) {
if (cryptoAllowancesBuilder_ == null) {
ensureCryptoAllowancesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, cryptoAllowances_);
onChanged();
} else {
cryptoAllowancesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder clearCryptoAllowances() {
if (cryptoAllowancesBuilder_ == null) {
cryptoAllowances_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
cryptoAllowancesBuilder_.clear();
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public Builder removeCryptoAllowances(int index) {
if (cryptoAllowancesBuilder_ == null) {
ensureCryptoAllowancesIsMutable();
cryptoAllowances_.remove(index);
onChanged();
} else {
cryptoAllowancesBuilder_.remove(index);
}
return this;
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public com.hederahashgraph.api.proto.java.CryptoAllowance.Builder getCryptoAllowancesBuilder(
int index) {
return getCryptoAllowancesFieldBuilder().getBuilder(index);
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder getCryptoAllowancesOrBuilder(
int index) {
if (cryptoAllowancesBuilder_ == null) {
return cryptoAllowances_.get(index); } else {
return cryptoAllowancesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public java.util.List extends com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder>
getCryptoAllowancesOrBuilderList() {
if (cryptoAllowancesBuilder_ != null) {
return cryptoAllowancesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(cryptoAllowances_);
}
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public com.hederahashgraph.api.proto.java.CryptoAllowance.Builder addCryptoAllowancesBuilder() {
return getCryptoAllowancesFieldBuilder().addBuilder(
com.hederahashgraph.api.proto.java.CryptoAllowance.getDefaultInstance());
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public com.hederahashgraph.api.proto.java.CryptoAllowance.Builder addCryptoAllowancesBuilder(
int index) {
return getCryptoAllowancesFieldBuilder().addBuilder(
index, com.hederahashgraph.api.proto.java.CryptoAllowance.getDefaultInstance());
}
/**
*
**
* List of hbar allowances approved by the account owner.
*
*
* repeated .proto.CryptoAllowance cryptoAllowances = 1;
*/
public java.util.List
getCryptoAllowancesBuilderList() {
return getCryptoAllowancesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.CryptoAllowance, com.hederahashgraph.api.proto.java.CryptoAllowance.Builder, com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder>
getCryptoAllowancesFieldBuilder() {
if (cryptoAllowancesBuilder_ == null) {
cryptoAllowancesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.CryptoAllowance, com.hederahashgraph.api.proto.java.CryptoAllowance.Builder, com.hederahashgraph.api.proto.java.CryptoAllowanceOrBuilder>(
cryptoAllowances_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
cryptoAllowances_ = null;
}
return cryptoAllowancesBuilder_;
}
private java.util.List nftAllowances_ =
java.util.Collections.emptyList();
private void ensureNftAllowancesIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
nftAllowances_ = new java.util.ArrayList(nftAllowances_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.NftAllowance, com.hederahashgraph.api.proto.java.NftAllowance.Builder, com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder> nftAllowancesBuilder_;
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public java.util.List getNftAllowancesList() {
if (nftAllowancesBuilder_ == null) {
return java.util.Collections.unmodifiableList(nftAllowances_);
} else {
return nftAllowancesBuilder_.getMessageList();
}
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public int getNftAllowancesCount() {
if (nftAllowancesBuilder_ == null) {
return nftAllowances_.size();
} else {
return nftAllowancesBuilder_.getCount();
}
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public com.hederahashgraph.api.proto.java.NftAllowance getNftAllowances(int index) {
if (nftAllowancesBuilder_ == null) {
return nftAllowances_.get(index);
} else {
return nftAllowancesBuilder_.getMessage(index);
}
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder setNftAllowances(
int index, com.hederahashgraph.api.proto.java.NftAllowance value) {
if (nftAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNftAllowancesIsMutable();
nftAllowances_.set(index, value);
onChanged();
} else {
nftAllowancesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder setNftAllowances(
int index, com.hederahashgraph.api.proto.java.NftAllowance.Builder builderForValue) {
if (nftAllowancesBuilder_ == null) {
ensureNftAllowancesIsMutable();
nftAllowances_.set(index, builderForValue.build());
onChanged();
} else {
nftAllowancesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder addNftAllowances(com.hederahashgraph.api.proto.java.NftAllowance value) {
if (nftAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNftAllowancesIsMutable();
nftAllowances_.add(value);
onChanged();
} else {
nftAllowancesBuilder_.addMessage(value);
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder addNftAllowances(
int index, com.hederahashgraph.api.proto.java.NftAllowance value) {
if (nftAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureNftAllowancesIsMutable();
nftAllowances_.add(index, value);
onChanged();
} else {
nftAllowancesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder addNftAllowances(
com.hederahashgraph.api.proto.java.NftAllowance.Builder builderForValue) {
if (nftAllowancesBuilder_ == null) {
ensureNftAllowancesIsMutable();
nftAllowances_.add(builderForValue.build());
onChanged();
} else {
nftAllowancesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder addNftAllowances(
int index, com.hederahashgraph.api.proto.java.NftAllowance.Builder builderForValue) {
if (nftAllowancesBuilder_ == null) {
ensureNftAllowancesIsMutable();
nftAllowances_.add(index, builderForValue.build());
onChanged();
} else {
nftAllowancesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder addAllNftAllowances(
java.lang.Iterable extends com.hederahashgraph.api.proto.java.NftAllowance> values) {
if (nftAllowancesBuilder_ == null) {
ensureNftAllowancesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, nftAllowances_);
onChanged();
} else {
nftAllowancesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder clearNftAllowances() {
if (nftAllowancesBuilder_ == null) {
nftAllowances_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
nftAllowancesBuilder_.clear();
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public Builder removeNftAllowances(int index) {
if (nftAllowancesBuilder_ == null) {
ensureNftAllowancesIsMutable();
nftAllowances_.remove(index);
onChanged();
} else {
nftAllowancesBuilder_.remove(index);
}
return this;
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public com.hederahashgraph.api.proto.java.NftAllowance.Builder getNftAllowancesBuilder(
int index) {
return getNftAllowancesFieldBuilder().getBuilder(index);
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder getNftAllowancesOrBuilder(
int index) {
if (nftAllowancesBuilder_ == null) {
return nftAllowances_.get(index); } else {
return nftAllowancesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public java.util.List extends com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder>
getNftAllowancesOrBuilderList() {
if (nftAllowancesBuilder_ != null) {
return nftAllowancesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(nftAllowances_);
}
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public com.hederahashgraph.api.proto.java.NftAllowance.Builder addNftAllowancesBuilder() {
return getNftAllowancesFieldBuilder().addBuilder(
com.hederahashgraph.api.proto.java.NftAllowance.getDefaultInstance());
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public com.hederahashgraph.api.proto.java.NftAllowance.Builder addNftAllowancesBuilder(
int index) {
return getNftAllowancesFieldBuilder().addBuilder(
index, com.hederahashgraph.api.proto.java.NftAllowance.getDefaultInstance());
}
/**
*
**
* List of non-fungible token allowances approved by the account owner.
*
*
* repeated .proto.NftAllowance nftAllowances = 2;
*/
public java.util.List
getNftAllowancesBuilderList() {
return getNftAllowancesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.NftAllowance, com.hederahashgraph.api.proto.java.NftAllowance.Builder, com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder>
getNftAllowancesFieldBuilder() {
if (nftAllowancesBuilder_ == null) {
nftAllowancesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.NftAllowance, com.hederahashgraph.api.proto.java.NftAllowance.Builder, com.hederahashgraph.api.proto.java.NftAllowanceOrBuilder>(
nftAllowances_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
nftAllowances_ = null;
}
return nftAllowancesBuilder_;
}
private java.util.List tokenAllowances_ =
java.util.Collections.emptyList();
private void ensureTokenAllowancesIsMutable() {
if (!((bitField0_ & 0x00000004) != 0)) {
tokenAllowances_ = new java.util.ArrayList(tokenAllowances_);
bitField0_ |= 0x00000004;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.TokenAllowance, com.hederahashgraph.api.proto.java.TokenAllowance.Builder, com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder> tokenAllowancesBuilder_;
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public java.util.List getTokenAllowancesList() {
if (tokenAllowancesBuilder_ == null) {
return java.util.Collections.unmodifiableList(tokenAllowances_);
} else {
return tokenAllowancesBuilder_.getMessageList();
}
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public int getTokenAllowancesCount() {
if (tokenAllowancesBuilder_ == null) {
return tokenAllowances_.size();
} else {
return tokenAllowancesBuilder_.getCount();
}
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public com.hederahashgraph.api.proto.java.TokenAllowance getTokenAllowances(int index) {
if (tokenAllowancesBuilder_ == null) {
return tokenAllowances_.get(index);
} else {
return tokenAllowancesBuilder_.getMessage(index);
}
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder setTokenAllowances(
int index, com.hederahashgraph.api.proto.java.TokenAllowance value) {
if (tokenAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTokenAllowancesIsMutable();
tokenAllowances_.set(index, value);
onChanged();
} else {
tokenAllowancesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder setTokenAllowances(
int index, com.hederahashgraph.api.proto.java.TokenAllowance.Builder builderForValue) {
if (tokenAllowancesBuilder_ == null) {
ensureTokenAllowancesIsMutable();
tokenAllowances_.set(index, builderForValue.build());
onChanged();
} else {
tokenAllowancesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder addTokenAllowances(com.hederahashgraph.api.proto.java.TokenAllowance value) {
if (tokenAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTokenAllowancesIsMutable();
tokenAllowances_.add(value);
onChanged();
} else {
tokenAllowancesBuilder_.addMessage(value);
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder addTokenAllowances(
int index, com.hederahashgraph.api.proto.java.TokenAllowance value) {
if (tokenAllowancesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTokenAllowancesIsMutable();
tokenAllowances_.add(index, value);
onChanged();
} else {
tokenAllowancesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder addTokenAllowances(
com.hederahashgraph.api.proto.java.TokenAllowance.Builder builderForValue) {
if (tokenAllowancesBuilder_ == null) {
ensureTokenAllowancesIsMutable();
tokenAllowances_.add(builderForValue.build());
onChanged();
} else {
tokenAllowancesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder addTokenAllowances(
int index, com.hederahashgraph.api.proto.java.TokenAllowance.Builder builderForValue) {
if (tokenAllowancesBuilder_ == null) {
ensureTokenAllowancesIsMutable();
tokenAllowances_.add(index, builderForValue.build());
onChanged();
} else {
tokenAllowancesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder addAllTokenAllowances(
java.lang.Iterable extends com.hederahashgraph.api.proto.java.TokenAllowance> values) {
if (tokenAllowancesBuilder_ == null) {
ensureTokenAllowancesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, tokenAllowances_);
onChanged();
} else {
tokenAllowancesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder clearTokenAllowances() {
if (tokenAllowancesBuilder_ == null) {
tokenAllowances_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
} else {
tokenAllowancesBuilder_.clear();
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public Builder removeTokenAllowances(int index) {
if (tokenAllowancesBuilder_ == null) {
ensureTokenAllowancesIsMutable();
tokenAllowances_.remove(index);
onChanged();
} else {
tokenAllowancesBuilder_.remove(index);
}
return this;
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public com.hederahashgraph.api.proto.java.TokenAllowance.Builder getTokenAllowancesBuilder(
int index) {
return getTokenAllowancesFieldBuilder().getBuilder(index);
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder getTokenAllowancesOrBuilder(
int index) {
if (tokenAllowancesBuilder_ == null) {
return tokenAllowances_.get(index); } else {
return tokenAllowancesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public java.util.List extends com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder>
getTokenAllowancesOrBuilderList() {
if (tokenAllowancesBuilder_ != null) {
return tokenAllowancesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(tokenAllowances_);
}
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public com.hederahashgraph.api.proto.java.TokenAllowance.Builder addTokenAllowancesBuilder() {
return getTokenAllowancesFieldBuilder().addBuilder(
com.hederahashgraph.api.proto.java.TokenAllowance.getDefaultInstance());
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public com.hederahashgraph.api.proto.java.TokenAllowance.Builder addTokenAllowancesBuilder(
int index) {
return getTokenAllowancesFieldBuilder().addBuilder(
index, com.hederahashgraph.api.proto.java.TokenAllowance.getDefaultInstance());
}
/**
*
**
* List of fungible token allowances approved by the account owner.
*
*
* repeated .proto.TokenAllowance tokenAllowances = 3;
*/
public java.util.List
getTokenAllowancesBuilderList() {
return getTokenAllowancesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.TokenAllowance, com.hederahashgraph.api.proto.java.TokenAllowance.Builder, com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder>
getTokenAllowancesFieldBuilder() {
if (tokenAllowancesBuilder_ == null) {
tokenAllowancesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.hederahashgraph.api.proto.java.TokenAllowance, com.hederahashgraph.api.proto.java.TokenAllowance.Builder, com.hederahashgraph.api.proto.java.TokenAllowanceOrBuilder>(
tokenAllowances_,
((bitField0_ & 0x00000004) != 0),
getParentForChildren(),
isClean());
tokenAllowances_ = null;
}
return tokenAllowancesBuilder_;
}
@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.CryptoApproveAllowanceTransactionBody)
}
// @@protoc_insertion_point(class_scope:proto.CryptoApproveAllowanceTransactionBody)
private static final com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody();
}
public static com.hederahashgraph.api.proto.java.CryptoApproveAllowanceTransactionBody getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public CryptoApproveAllowanceTransactionBody parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new CryptoApproveAllowanceTransactionBody(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.CryptoApproveAllowanceTransactionBody getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy