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

com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody Maven / Gradle / Ivy

The newest version!
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: crypto_transfer.proto

// Protobuf Java Version: 3.25.3
package com.hedera.hashgraph.sdk.proto;

/**
 * 
 **
 * Transfers cryptocurrency among two or more accounts by making the desired adjustments to their
 * balances. Each transfer list can specify up to 10 adjustments. Each negative amount is withdrawn
 * from the corresponding account (a sender), and each positive one is added to the corresponding
 * account (a receiver). The amounts list must sum to zero. Each amount is a number of tinybars
 * (there are 100,000,000 tinybars in one hbar).  If any sender account fails to have sufficient
 * hbars, then the entire transaction fails, and none of those transfers occur, though the
 * transaction fee is still charged. This transaction must be signed by the keys for all the sending
 * accounts, and for any receiving accounts that have receiverSigRequired == true. The signatures
 * are in the same order as the accounts, skipping those accounts that don't need a signature. 
 * 
* * Protobuf type {@code proto.CryptoTransferTransactionBody} */ public final class CryptoTransferTransactionBody extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:proto.CryptoTransferTransactionBody) CryptoTransferTransactionBodyOrBuilder { private static final long serialVersionUID = 0L; // Use CryptoTransferTransactionBody.newBuilder() to construct. private CryptoTransferTransactionBody(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private CryptoTransferTransactionBody() { tokenTransfers_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new CryptoTransferTransactionBody(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.hedera.hashgraph.sdk.proto.CryptoTransfer.internal_static_proto_CryptoTransferTransactionBody_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.hedera.hashgraph.sdk.proto.CryptoTransfer.internal_static_proto_CryptoTransferTransactionBody_fieldAccessorTable .ensureFieldAccessorsInitialized( com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.class, com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.Builder.class); } private int bitField0_; public static final int TRANSFERS_FIELD_NUMBER = 1; private com.hedera.hashgraph.sdk.proto.TransferList transfers_; /** *
   **
   * The desired hbar balance adjustments
   * 
* * .proto.TransferList transfers = 1; * @return Whether the transfers field is set. */ @java.lang.Override public boolean hasTransfers() { return ((bitField0_ & 0x00000001) != 0); } /** *
   **
   * The desired hbar balance adjustments
   * 
* * .proto.TransferList transfers = 1; * @return The transfers. */ @java.lang.Override public com.hedera.hashgraph.sdk.proto.TransferList getTransfers() { return transfers_ == null ? com.hedera.hashgraph.sdk.proto.TransferList.getDefaultInstance() : transfers_; } /** *
   **
   * The desired hbar balance adjustments
   * 
* * .proto.TransferList transfers = 1; */ @java.lang.Override public com.hedera.hashgraph.sdk.proto.TransferListOrBuilder getTransfersOrBuilder() { return transfers_ == null ? com.hedera.hashgraph.sdk.proto.TransferList.getDefaultInstance() : transfers_; } public static final int TOKENTRANSFERS_FIELD_NUMBER = 2; @SuppressWarnings("serial") private java.util.List tokenTransfers_; /** *
   **
   * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
   * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
   * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
   * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ @java.lang.Override public java.util.List getTokenTransfersList() { return tokenTransfers_; } /** *
   **
   * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
   * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
   * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
   * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ @java.lang.Override public java.util.List getTokenTransfersOrBuilderList() { return tokenTransfers_; } /** *
   **
   * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
   * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
   * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
   * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ @java.lang.Override public int getTokenTransfersCount() { return tokenTransfers_.size(); } /** *
   **
   * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
   * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
   * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
   * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ @java.lang.Override public com.hedera.hashgraph.sdk.proto.TokenTransferList getTokenTransfers(int index) { return tokenTransfers_.get(index); } /** *
   **
   * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
   * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
   * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
   * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ @java.lang.Override public com.hedera.hashgraph.sdk.proto.TokenTransferListOrBuilder getTokenTransfersOrBuilder( int index) { return tokenTransfers_.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 { if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(1, getTransfers()); } for (int i = 0; i < tokenTransfers_.size(); i++) { output.writeMessage(2, tokenTransfers_.get(i)); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(1, getTransfers()); } for (int i = 0; i < tokenTransfers_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, tokenTransfers_.get(i)); } 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 com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody)) { return super.equals(obj); } com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody other = (com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody) obj; if (hasTransfers() != other.hasTransfers()) return false; if (hasTransfers()) { if (!getTransfers() .equals(other.getTransfers())) return false; } if (!getTokenTransfersList() .equals(other.getTokenTransfersList())) 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(); if (hasTransfers()) { hash = (37 * hash) + TRANSFERS_FIELD_NUMBER; hash = (53 * hash) + getTransfers().hashCode(); } if (getTokenTransfersCount() > 0) { hash = (37 * hash) + TOKENTRANSFERS_FIELD_NUMBER; hash = (53 * hash) + getTokenTransfersList().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody 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.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody 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.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody 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.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody 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; } /** *
   **
   * Transfers cryptocurrency among two or more accounts by making the desired adjustments to their
   * balances. Each transfer list can specify up to 10 adjustments. Each negative amount is withdrawn
   * from the corresponding account (a sender), and each positive one is added to the corresponding
   * account (a receiver). The amounts list must sum to zero. Each amount is a number of tinybars
   * (there are 100,000,000 tinybars in one hbar).  If any sender account fails to have sufficient
   * hbars, then the entire transaction fails, and none of those transfers occur, though the
   * transaction fee is still charged. This transaction must be signed by the keys for all the sending
   * accounts, and for any receiving accounts that have receiverSigRequired == true. The signatures
   * are in the same order as the accounts, skipping those accounts that don't need a signature. 
   * 
* * Protobuf type {@code proto.CryptoTransferTransactionBody} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:proto.CryptoTransferTransactionBody) com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBodyOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.hedera.hashgraph.sdk.proto.CryptoTransfer.internal_static_proto_CryptoTransferTransactionBody_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.hedera.hashgraph.sdk.proto.CryptoTransfer.internal_static_proto_CryptoTransferTransactionBody_fieldAccessorTable .ensureFieldAccessorsInitialized( com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.class, com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.Builder.class); } // Construct using com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { getTransfersFieldBuilder(); getTokenTransfersFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; transfers_ = null; if (transfersBuilder_ != null) { transfersBuilder_.dispose(); transfersBuilder_ = null; } if (tokenTransfersBuilder_ == null) { tokenTransfers_ = java.util.Collections.emptyList(); } else { tokenTransfers_ = null; tokenTransfersBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000002); return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.hedera.hashgraph.sdk.proto.CryptoTransfer.internal_static_proto_CryptoTransferTransactionBody_descriptor; } @java.lang.Override public com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody getDefaultInstanceForType() { return com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.getDefaultInstance(); } @java.lang.Override public com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody build() { com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody buildPartial() { com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody result = new com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody result) { if (tokenTransfersBuilder_ == null) { if (((bitField0_ & 0x00000002) != 0)) { tokenTransfers_ = java.util.Collections.unmodifiableList(tokenTransfers_); bitField0_ = (bitField0_ & ~0x00000002); } result.tokenTransfers_ = tokenTransfers_; } else { result.tokenTransfers_ = tokenTransfersBuilder_.build(); } } private void buildPartial0(com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody result) { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000001) != 0)) { result.transfers_ = transfersBuilder_ == null ? transfers_ : transfersBuilder_.build(); to_bitField0_ |= 0x00000001; } result.bitField0_ |= to_bitField0_; } @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.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody) { return mergeFrom((com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody other) { if (other == com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody.getDefaultInstance()) return this; if (other.hasTransfers()) { mergeTransfers(other.getTransfers()); } if (tokenTransfersBuilder_ == null) { if (!other.tokenTransfers_.isEmpty()) { if (tokenTransfers_.isEmpty()) { tokenTransfers_ = other.tokenTransfers_; bitField0_ = (bitField0_ & ~0x00000002); } else { ensureTokenTransfersIsMutable(); tokenTransfers_.addAll(other.tokenTransfers_); } onChanged(); } } else { if (!other.tokenTransfers_.isEmpty()) { if (tokenTransfersBuilder_.isEmpty()) { tokenTransfersBuilder_.dispose(); tokenTransfersBuilder_ = null; tokenTransfers_ = other.tokenTransfers_; bitField0_ = (bitField0_ & ~0x00000002); tokenTransfersBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getTokenTransfersFieldBuilder() : null; } else { tokenTransfersBuilder_.addAllMessages(other.tokenTransfers_); } } } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { input.readMessage( getTransfersFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000001; break; } // case 10 case 18: { com.hedera.hashgraph.sdk.proto.TokenTransferList m = input.readMessage( com.hedera.hashgraph.sdk.proto.TokenTransferList.parser(), extensionRegistry); if (tokenTransfersBuilder_ == null) { ensureTokenTransfersIsMutable(); tokenTransfers_.add(m); } else { tokenTransfersBuilder_.addMessage(m); } break; } // case 18 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private com.hedera.hashgraph.sdk.proto.TransferList transfers_; private com.google.protobuf.SingleFieldBuilderV3< com.hedera.hashgraph.sdk.proto.TransferList, com.hedera.hashgraph.sdk.proto.TransferList.Builder, com.hedera.hashgraph.sdk.proto.TransferListOrBuilder> transfersBuilder_; /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; * @return Whether the transfers field is set. */ public boolean hasTransfers() { return ((bitField0_ & 0x00000001) != 0); } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; * @return The transfers. */ public com.hedera.hashgraph.sdk.proto.TransferList getTransfers() { if (transfersBuilder_ == null) { return transfers_ == null ? com.hedera.hashgraph.sdk.proto.TransferList.getDefaultInstance() : transfers_; } else { return transfersBuilder_.getMessage(); } } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ public Builder setTransfers(com.hedera.hashgraph.sdk.proto.TransferList value) { if (transfersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } transfers_ = value; } else { transfersBuilder_.setMessage(value); } bitField0_ |= 0x00000001; onChanged(); return this; } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ public Builder setTransfers( com.hedera.hashgraph.sdk.proto.TransferList.Builder builderForValue) { if (transfersBuilder_ == null) { transfers_ = builderForValue.build(); } else { transfersBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000001; onChanged(); return this; } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ public Builder mergeTransfers(com.hedera.hashgraph.sdk.proto.TransferList value) { if (transfersBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0) && transfers_ != null && transfers_ != com.hedera.hashgraph.sdk.proto.TransferList.getDefaultInstance()) { getTransfersBuilder().mergeFrom(value); } else { transfers_ = value; } } else { transfersBuilder_.mergeFrom(value); } if (transfers_ != null) { bitField0_ |= 0x00000001; onChanged(); } return this; } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ public Builder clearTransfers() { bitField0_ = (bitField0_ & ~0x00000001); transfers_ = null; if (transfersBuilder_ != null) { transfersBuilder_.dispose(); transfersBuilder_ = null; } onChanged(); return this; } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ public com.hedera.hashgraph.sdk.proto.TransferList.Builder getTransfersBuilder() { bitField0_ |= 0x00000001; onChanged(); return getTransfersFieldBuilder().getBuilder(); } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ public com.hedera.hashgraph.sdk.proto.TransferListOrBuilder getTransfersOrBuilder() { if (transfersBuilder_ != null) { return transfersBuilder_.getMessageOrBuilder(); } else { return transfers_ == null ? com.hedera.hashgraph.sdk.proto.TransferList.getDefaultInstance() : transfers_; } } /** *
     **
     * The desired hbar balance adjustments
     * 
* * .proto.TransferList transfers = 1; */ private com.google.protobuf.SingleFieldBuilderV3< com.hedera.hashgraph.sdk.proto.TransferList, com.hedera.hashgraph.sdk.proto.TransferList.Builder, com.hedera.hashgraph.sdk.proto.TransferListOrBuilder> getTransfersFieldBuilder() { if (transfersBuilder_ == null) { transfersBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.hedera.hashgraph.sdk.proto.TransferList, com.hedera.hashgraph.sdk.proto.TransferList.Builder, com.hedera.hashgraph.sdk.proto.TransferListOrBuilder>( getTransfers(), getParentForChildren(), isClean()); transfers_ = null; } return transfersBuilder_; } private java.util.List tokenTransfers_ = java.util.Collections.emptyList(); private void ensureTokenTransfersIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { tokenTransfers_ = new java.util.ArrayList(tokenTransfers_); bitField0_ |= 0x00000002; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.hedera.hashgraph.sdk.proto.TokenTransferList, com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder, com.hedera.hashgraph.sdk.proto.TokenTransferListOrBuilder> tokenTransfersBuilder_; /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public java.util.List getTokenTransfersList() { if (tokenTransfersBuilder_ == null) { return java.util.Collections.unmodifiableList(tokenTransfers_); } else { return tokenTransfersBuilder_.getMessageList(); } } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public int getTokenTransfersCount() { if (tokenTransfersBuilder_ == null) { return tokenTransfers_.size(); } else { return tokenTransfersBuilder_.getCount(); } } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public com.hedera.hashgraph.sdk.proto.TokenTransferList getTokenTransfers(int index) { if (tokenTransfersBuilder_ == null) { return tokenTransfers_.get(index); } else { return tokenTransfersBuilder_.getMessage(index); } } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder setTokenTransfers( int index, com.hedera.hashgraph.sdk.proto.TokenTransferList value) { if (tokenTransfersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureTokenTransfersIsMutable(); tokenTransfers_.set(index, value); onChanged(); } else { tokenTransfersBuilder_.setMessage(index, value); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder setTokenTransfers( int index, com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder builderForValue) { if (tokenTransfersBuilder_ == null) { ensureTokenTransfersIsMutable(); tokenTransfers_.set(index, builderForValue.build()); onChanged(); } else { tokenTransfersBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder addTokenTransfers(com.hedera.hashgraph.sdk.proto.TokenTransferList value) { if (tokenTransfersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureTokenTransfersIsMutable(); tokenTransfers_.add(value); onChanged(); } else { tokenTransfersBuilder_.addMessage(value); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder addTokenTransfers( int index, com.hedera.hashgraph.sdk.proto.TokenTransferList value) { if (tokenTransfersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureTokenTransfersIsMutable(); tokenTransfers_.add(index, value); onChanged(); } else { tokenTransfersBuilder_.addMessage(index, value); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder addTokenTransfers( com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder builderForValue) { if (tokenTransfersBuilder_ == null) { ensureTokenTransfersIsMutable(); tokenTransfers_.add(builderForValue.build()); onChanged(); } else { tokenTransfersBuilder_.addMessage(builderForValue.build()); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder addTokenTransfers( int index, com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder builderForValue) { if (tokenTransfersBuilder_ == null) { ensureTokenTransfersIsMutable(); tokenTransfers_.add(index, builderForValue.build()); onChanged(); } else { tokenTransfersBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder addAllTokenTransfers( java.lang.Iterable values) { if (tokenTransfersBuilder_ == null) { ensureTokenTransfersIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, tokenTransfers_); onChanged(); } else { tokenTransfersBuilder_.addAllMessages(values); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder clearTokenTransfers() { if (tokenTransfersBuilder_ == null) { tokenTransfers_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); } else { tokenTransfersBuilder_.clear(); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public Builder removeTokenTransfers(int index) { if (tokenTransfersBuilder_ == null) { ensureTokenTransfersIsMutable(); tokenTransfers_.remove(index); onChanged(); } else { tokenTransfersBuilder_.remove(index); } return this; } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder getTokenTransfersBuilder( int index) { return getTokenTransfersFieldBuilder().getBuilder(index); } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public com.hedera.hashgraph.sdk.proto.TokenTransferListOrBuilder getTokenTransfersOrBuilder( int index) { if (tokenTransfersBuilder_ == null) { return tokenTransfers_.get(index); } else { return tokenTransfersBuilder_.getMessageOrBuilder(index); } } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public java.util.List getTokenTransfersOrBuilderList() { if (tokenTransfersBuilder_ != null) { return tokenTransfersBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(tokenTransfers_); } } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder addTokenTransfersBuilder() { return getTokenTransfersFieldBuilder().addBuilder( com.hedera.hashgraph.sdk.proto.TokenTransferList.getDefaultInstance()); } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder addTokenTransfersBuilder( int index) { return getTokenTransfersFieldBuilder().addBuilder( index, com.hedera.hashgraph.sdk.proto.TokenTransferList.getDefaultInstance()); } /** *
     **
     * The desired token unit balance adjustments; if any custom fees are assessed, the ledger will
     * try to deduct them from the payer of this CryptoTransfer, resolving the transaction to
     * INSUFFICIENT_PAYER_BALANCE_FOR_CUSTOM_FEE if this is not possible
     * 
* * repeated .proto.TokenTransferList tokenTransfers = 2; */ public java.util.List getTokenTransfersBuilderList() { return getTokenTransfersFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.hedera.hashgraph.sdk.proto.TokenTransferList, com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder, com.hedera.hashgraph.sdk.proto.TokenTransferListOrBuilder> getTokenTransfersFieldBuilder() { if (tokenTransfersBuilder_ == null) { tokenTransfersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.hedera.hashgraph.sdk.proto.TokenTransferList, com.hedera.hashgraph.sdk.proto.TokenTransferList.Builder, com.hedera.hashgraph.sdk.proto.TokenTransferListOrBuilder>( tokenTransfers_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); tokenTransfers_ = null; } return tokenTransfersBuilder_; } @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.CryptoTransferTransactionBody) } // @@protoc_insertion_point(class_scope:proto.CryptoTransferTransactionBody) private static final com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody(); } public static com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public CryptoTransferTransactionBody 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 com.hedera.hashgraph.sdk.proto.CryptoTransferTransactionBody getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy