com.hederahashgraph.api.proto.java.FractionalFee Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: custom_fees.proto
package com.hederahashgraph.api.proto.java;
/**
*
**
* A fraction of the transferred units of a token to assess as a fee. The amount assessed will never
* be less than the given minimum_amount, and never greater than the given maximum_amount. The
* denomination is always units of the token to which this fractional fee is attached.
*
*
* Protobuf type {@code proto.FractionalFee}
*/
public final class FractionalFee extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:proto.FractionalFee)
FractionalFeeOrBuilder {
private static final long serialVersionUID = 0L;
// Use FractionalFee.newBuilder() to construct.
private FractionalFee(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private FractionalFee() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new FractionalFee();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private FractionalFee(
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.Fraction.Builder subBuilder = null;
if (fractionalAmount_ != null) {
subBuilder = fractionalAmount_.toBuilder();
}
fractionalAmount_ = input.readMessage(com.hederahashgraph.api.proto.java.Fraction.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(fractionalAmount_);
fractionalAmount_ = subBuilder.buildPartial();
}
break;
}
case 16: {
minimumAmount_ = input.readInt64();
break;
}
case 24: {
maximumAmount_ = input.readInt64();
break;
}
case 32: {
netOfTransfers_ = input.readBool();
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.CustomFees.internal_static_proto_FractionalFee_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hederahashgraph.api.proto.java.CustomFees.internal_static_proto_FractionalFee_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hederahashgraph.api.proto.java.FractionalFee.class, com.hederahashgraph.api.proto.java.FractionalFee.Builder.class);
}
public static final int FRACTIONAL_AMOUNT_FIELD_NUMBER = 1;
private com.hederahashgraph.api.proto.java.Fraction fractionalAmount_;
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
* @return Whether the fractionalAmount field is set.
*/
@java.lang.Override
public boolean hasFractionalAmount() {
return fractionalAmount_ != null;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
* @return The fractionalAmount.
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.Fraction getFractionalAmount() {
return fractionalAmount_ == null ? com.hederahashgraph.api.proto.java.Fraction.getDefaultInstance() : fractionalAmount_;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
@java.lang.Override
public com.hederahashgraph.api.proto.java.FractionOrBuilder getFractionalAmountOrBuilder() {
return getFractionalAmount();
}
public static final int MINIMUM_AMOUNT_FIELD_NUMBER = 2;
private long minimumAmount_;
/**
*
**
* The minimum amount to assess
*
*
* int64 minimum_amount = 2;
* @return The minimumAmount.
*/
@java.lang.Override
public long getMinimumAmount() {
return minimumAmount_;
}
public static final int MAXIMUM_AMOUNT_FIELD_NUMBER = 3;
private long maximumAmount_;
/**
*
**
* The maximum amount to assess (zero implies no maximum)
*
*
* int64 maximum_amount = 3;
* @return The maximumAmount.
*/
@java.lang.Override
public long getMaximumAmount() {
return maximumAmount_;
}
public static final int NET_OF_TRANSFERS_FIELD_NUMBER = 4;
private boolean netOfTransfers_;
/**
*
**
* If true, assesses the fee to the sender, so the receiver gets the full amount from the token
* transfer list, and the sender is charged an additional fee; if false, the receiver does NOT get
* the full amount, but only what is left over after paying the fractional fee
*
*
* bool net_of_transfers = 4;
* @return The netOfTransfers.
*/
@java.lang.Override
public boolean getNetOfTransfers() {
return netOfTransfers_;
}
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 (fractionalAmount_ != null) {
output.writeMessage(1, getFractionalAmount());
}
if (minimumAmount_ != 0L) {
output.writeInt64(2, minimumAmount_);
}
if (maximumAmount_ != 0L) {
output.writeInt64(3, maximumAmount_);
}
if (netOfTransfers_ != false) {
output.writeBool(4, netOfTransfers_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (fractionalAmount_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getFractionalAmount());
}
if (minimumAmount_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, minimumAmount_);
}
if (maximumAmount_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(3, maximumAmount_);
}
if (netOfTransfers_ != false) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(4, netOfTransfers_);
}
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.FractionalFee)) {
return super.equals(obj);
}
com.hederahashgraph.api.proto.java.FractionalFee other = (com.hederahashgraph.api.proto.java.FractionalFee) obj;
if (hasFractionalAmount() != other.hasFractionalAmount()) return false;
if (hasFractionalAmount()) {
if (!getFractionalAmount()
.equals(other.getFractionalAmount())) return false;
}
if (getMinimumAmount()
!= other.getMinimumAmount()) return false;
if (getMaximumAmount()
!= other.getMaximumAmount()) return false;
if (getNetOfTransfers()
!= other.getNetOfTransfers()) 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 (hasFractionalAmount()) {
hash = (37 * hash) + FRACTIONAL_AMOUNT_FIELD_NUMBER;
hash = (53 * hash) + getFractionalAmount().hashCode();
}
hash = (37 * hash) + MINIMUM_AMOUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getMinimumAmount());
hash = (37 * hash) + MAXIMUM_AMOUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getMaximumAmount());
hash = (37 * hash) + NET_OF_TRANSFERS_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getNetOfTransfers());
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.hederahashgraph.api.proto.java.FractionalFee parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hederahashgraph.api.proto.java.FractionalFee 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.FractionalFee parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hederahashgraph.api.proto.java.FractionalFee 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.FractionalFee parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hederahashgraph.api.proto.java.FractionalFee 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.FractionalFee parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.hederahashgraph.api.proto.java.FractionalFee 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.FractionalFee parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.hederahashgraph.api.proto.java.FractionalFee 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.FractionalFee 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.FractionalFee 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.FractionalFee 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 fraction of the transferred units of a token to assess as a fee. The amount assessed will never
* be less than the given minimum_amount, and never greater than the given maximum_amount. The
* denomination is always units of the token to which this fractional fee is attached.
*
*
* Protobuf type {@code proto.FractionalFee}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:proto.FractionalFee)
com.hederahashgraph.api.proto.java.FractionalFeeOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hederahashgraph.api.proto.java.CustomFees.internal_static_proto_FractionalFee_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hederahashgraph.api.proto.java.CustomFees.internal_static_proto_FractionalFee_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hederahashgraph.api.proto.java.FractionalFee.class, com.hederahashgraph.api.proto.java.FractionalFee.Builder.class);
}
// Construct using com.hederahashgraph.api.proto.java.FractionalFee.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();
if (fractionalAmountBuilder_ == null) {
fractionalAmount_ = null;
} else {
fractionalAmount_ = null;
fractionalAmountBuilder_ = null;
}
minimumAmount_ = 0L;
maximumAmount_ = 0L;
netOfTransfers_ = false;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.hederahashgraph.api.proto.java.CustomFees.internal_static_proto_FractionalFee_descriptor;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.FractionalFee getDefaultInstanceForType() {
return com.hederahashgraph.api.proto.java.FractionalFee.getDefaultInstance();
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.FractionalFee build() {
com.hederahashgraph.api.proto.java.FractionalFee result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.hederahashgraph.api.proto.java.FractionalFee buildPartial() {
com.hederahashgraph.api.proto.java.FractionalFee result = new com.hederahashgraph.api.proto.java.FractionalFee(this);
if (fractionalAmountBuilder_ == null) {
result.fractionalAmount_ = fractionalAmount_;
} else {
result.fractionalAmount_ = fractionalAmountBuilder_.build();
}
result.minimumAmount_ = minimumAmount_;
result.maximumAmount_ = maximumAmount_;
result.netOfTransfers_ = netOfTransfers_;
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.FractionalFee) {
return mergeFrom((com.hederahashgraph.api.proto.java.FractionalFee)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.hederahashgraph.api.proto.java.FractionalFee other) {
if (other == com.hederahashgraph.api.proto.java.FractionalFee.getDefaultInstance()) return this;
if (other.hasFractionalAmount()) {
mergeFractionalAmount(other.getFractionalAmount());
}
if (other.getMinimumAmount() != 0L) {
setMinimumAmount(other.getMinimumAmount());
}
if (other.getMaximumAmount() != 0L) {
setMaximumAmount(other.getMaximumAmount());
}
if (other.getNetOfTransfers() != false) {
setNetOfTransfers(other.getNetOfTransfers());
}
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.FractionalFee parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.hederahashgraph.api.proto.java.FractionalFee) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private com.hederahashgraph.api.proto.java.Fraction fractionalAmount_;
private com.google.protobuf.SingleFieldBuilderV3<
com.hederahashgraph.api.proto.java.Fraction, com.hederahashgraph.api.proto.java.Fraction.Builder, com.hederahashgraph.api.proto.java.FractionOrBuilder> fractionalAmountBuilder_;
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
* @return Whether the fractionalAmount field is set.
*/
public boolean hasFractionalAmount() {
return fractionalAmountBuilder_ != null || fractionalAmount_ != null;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
* @return The fractionalAmount.
*/
public com.hederahashgraph.api.proto.java.Fraction getFractionalAmount() {
if (fractionalAmountBuilder_ == null) {
return fractionalAmount_ == null ? com.hederahashgraph.api.proto.java.Fraction.getDefaultInstance() : fractionalAmount_;
} else {
return fractionalAmountBuilder_.getMessage();
}
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
public Builder setFractionalAmount(com.hederahashgraph.api.proto.java.Fraction value) {
if (fractionalAmountBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
fractionalAmount_ = value;
onChanged();
} else {
fractionalAmountBuilder_.setMessage(value);
}
return this;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
public Builder setFractionalAmount(
com.hederahashgraph.api.proto.java.Fraction.Builder builderForValue) {
if (fractionalAmountBuilder_ == null) {
fractionalAmount_ = builderForValue.build();
onChanged();
} else {
fractionalAmountBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
public Builder mergeFractionalAmount(com.hederahashgraph.api.proto.java.Fraction value) {
if (fractionalAmountBuilder_ == null) {
if (fractionalAmount_ != null) {
fractionalAmount_ =
com.hederahashgraph.api.proto.java.Fraction.newBuilder(fractionalAmount_).mergeFrom(value).buildPartial();
} else {
fractionalAmount_ = value;
}
onChanged();
} else {
fractionalAmountBuilder_.mergeFrom(value);
}
return this;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
public Builder clearFractionalAmount() {
if (fractionalAmountBuilder_ == null) {
fractionalAmount_ = null;
onChanged();
} else {
fractionalAmount_ = null;
fractionalAmountBuilder_ = null;
}
return this;
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
public com.hederahashgraph.api.proto.java.Fraction.Builder getFractionalAmountBuilder() {
onChanged();
return getFractionalAmountFieldBuilder().getBuilder();
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
public com.hederahashgraph.api.proto.java.FractionOrBuilder getFractionalAmountOrBuilder() {
if (fractionalAmountBuilder_ != null) {
return fractionalAmountBuilder_.getMessageOrBuilder();
} else {
return fractionalAmount_ == null ?
com.hederahashgraph.api.proto.java.Fraction.getDefaultInstance() : fractionalAmount_;
}
}
/**
*
**
* The fraction of the transferred units to assess as a fee
*
*
* .proto.Fraction fractional_amount = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.hederahashgraph.api.proto.java.Fraction, com.hederahashgraph.api.proto.java.Fraction.Builder, com.hederahashgraph.api.proto.java.FractionOrBuilder>
getFractionalAmountFieldBuilder() {
if (fractionalAmountBuilder_ == null) {
fractionalAmountBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.hederahashgraph.api.proto.java.Fraction, com.hederahashgraph.api.proto.java.Fraction.Builder, com.hederahashgraph.api.proto.java.FractionOrBuilder>(
getFractionalAmount(),
getParentForChildren(),
isClean());
fractionalAmount_ = null;
}
return fractionalAmountBuilder_;
}
private long minimumAmount_ ;
/**
*
**
* The minimum amount to assess
*
*
* int64 minimum_amount = 2;
* @return The minimumAmount.
*/
@java.lang.Override
public long getMinimumAmount() {
return minimumAmount_;
}
/**
*
**
* The minimum amount to assess
*
*
* int64 minimum_amount = 2;
* @param value The minimumAmount to set.
* @return This builder for chaining.
*/
public Builder setMinimumAmount(long value) {
minimumAmount_ = value;
onChanged();
return this;
}
/**
*
**
* The minimum amount to assess
*
*
* int64 minimum_amount = 2;
* @return This builder for chaining.
*/
public Builder clearMinimumAmount() {
minimumAmount_ = 0L;
onChanged();
return this;
}
private long maximumAmount_ ;
/**
*
**
* The maximum amount to assess (zero implies no maximum)
*
*
* int64 maximum_amount = 3;
* @return The maximumAmount.
*/
@java.lang.Override
public long getMaximumAmount() {
return maximumAmount_;
}
/**
*
**
* The maximum amount to assess (zero implies no maximum)
*
*
* int64 maximum_amount = 3;
* @param value The maximumAmount to set.
* @return This builder for chaining.
*/
public Builder setMaximumAmount(long value) {
maximumAmount_ = value;
onChanged();
return this;
}
/**
*
**
* The maximum amount to assess (zero implies no maximum)
*
*
* int64 maximum_amount = 3;
* @return This builder for chaining.
*/
public Builder clearMaximumAmount() {
maximumAmount_ = 0L;
onChanged();
return this;
}
private boolean netOfTransfers_ ;
/**
*
**
* If true, assesses the fee to the sender, so the receiver gets the full amount from the token
* transfer list, and the sender is charged an additional fee; if false, the receiver does NOT get
* the full amount, but only what is left over after paying the fractional fee
*
*
* bool net_of_transfers = 4;
* @return The netOfTransfers.
*/
@java.lang.Override
public boolean getNetOfTransfers() {
return netOfTransfers_;
}
/**
*
**
* If true, assesses the fee to the sender, so the receiver gets the full amount from the token
* transfer list, and the sender is charged an additional fee; if false, the receiver does NOT get
* the full amount, but only what is left over after paying the fractional fee
*
*
* bool net_of_transfers = 4;
* @param value The netOfTransfers to set.
* @return This builder for chaining.
*/
public Builder setNetOfTransfers(boolean value) {
netOfTransfers_ = value;
onChanged();
return this;
}
/**
*
**
* If true, assesses the fee to the sender, so the receiver gets the full amount from the token
* transfer list, and the sender is charged an additional fee; if false, the receiver does NOT get
* the full amount, but only what is left over after paying the fractional fee
*
*
* bool net_of_transfers = 4;
* @return This builder for chaining.
*/
public Builder clearNetOfTransfers() {
netOfTransfers_ = false;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:proto.FractionalFee)
}
// @@protoc_insertion_point(class_scope:proto.FractionalFee)
private static final com.hederahashgraph.api.proto.java.FractionalFee DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.hederahashgraph.api.proto.java.FractionalFee();
}
public static com.hederahashgraph.api.proto.java.FractionalFee getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public FractionalFee parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new FractionalFee(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.FractionalFee getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}