Class FeeComponents.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<FeeComponents,FeeComponents.Builder>
com.google.protobuf.GeneratedMessageLite.Builder<FeeComponents,FeeComponents.Builder>
com.hedera.hashgraph.sdk.proto.FeeComponents.Builder
All Implemented Interfaces:
com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, FeeComponentsOrBuilder, Cloneable
Enclosing class:
FeeComponents

public static final class FeeComponents.Builder extends com.google.protobuf.GeneratedMessageLite.Builder<FeeComponents,FeeComponents.Builder> implements FeeComponentsOrBuilder
 *
 A set of values the nodes use in determining transaction and query fees, and
 constants involved in fee calculations.

 Nodes SHALL multiply the amount of "resources" allocated to a transaction or
 query by the corresponding price to calculate the appropriate fee. Units are
 one-thousandth of a `tinyCent`. The "resource" allocations SHALL be estimated
 based on transaction characteristics and current network state, and MAY be
 further adjusted based on network load and congestion.

 This SHALL be used, in different contexts, for the cost _factors_ used to
 calculate charged amounts, for the resource accumulation, and for actual
 amounts to be charged.<br/>
 Amounts recorded here MUST be converted to tinybar according to the
 current active `ExchangeRate` for the network.
 
Protobuf type proto.FeeComponents
  • Field Summary

    Fields inherited from class com.google.protobuf.GeneratedMessageLite.Builder

    instance
  • Method Summary

    Modifier and Type
    Method
    Description
    * Response memory: "bytes per response".<br/> The fee for data retrieved from memory to deliver a response, measured in bytes
    * Bandwidth: "bytes per transaction".<br/> The fee for bandwidth consumed by a transaction, measured in bytes
    * Base: "constant fee".<br/> A baseline constant contribution to total fee.
    * Compute: Ethereum term for a derivative EVM compute resource.<br/> The fee of computation for a smart contract transaction.
    * Base: "maximum total fee".
    * Base: "minimum total fee".
    * Memory: "RAM byte-hours".<br/> The fee for RAM required to process a transaction, measured in byte-hours
    * Disk: "storage byte-hours".<br/> The fee for storage required by a transaction, measured in byte-hours
    * Response disk: "storage bytes per response".<br/> The fee for data retrieved from disk to deliver a response, measured in bytes
    * Ad valorem: "transferred value".<br/> The fee for HBAR transferred by a transaction.
    * Signatures: "validations per transaction".<br/> The fee for signature verifications required by a transaction
    long
    * Response memory: "bytes per response".<br/> The fee for data retrieved from memory to deliver a response, measured in bytes
    long
    * Bandwidth: "bytes per transaction".<br/> The fee for bandwidth consumed by a transaction, measured in bytes
    long
    * Base: "constant fee".<br/> A baseline constant contribution to total fee.
    long
    * Compute: Ethereum term for a derivative EVM compute resource.<br/> The fee of computation for a smart contract transaction.
    long
    * Base: "maximum total fee".
    long
    * Base: "minimum total fee".
    long
    * Memory: "RAM byte-hours".<br/> The fee for RAM required to process a transaction, measured in byte-hours
    long
    * Disk: "storage byte-hours".<br/> The fee for storage required by a transaction, measured in byte-hours
    long
    * Response disk: "storage bytes per response".<br/> The fee for data retrieved from disk to deliver a response, measured in bytes
    long
    * Ad valorem: "transferred value".<br/> The fee for HBAR transferred by a transaction.
    long
    * Signatures: "validations per transaction".<br/> The fee for signature verifications required by a transaction
    setBpr(long value)
    * Response memory: "bytes per response".<br/> The fee for data retrieved from memory to deliver a response, measured in bytes
    setBpt(long value)
    * Bandwidth: "bytes per transaction".<br/> The fee for bandwidth consumed by a transaction, measured in bytes
    setConstant(long value)
    * Base: "constant fee".<br/> A baseline constant contribution to total fee.
    setGas(long value)
    * Compute: Ethereum term for a derivative EVM compute resource.<br/> The fee of computation for a smart contract transaction.
    setMax(long value)
    * Base: "maximum total fee".
    setMin(long value)
    * Base: "minimum total fee".
    setRbh(long value)
    * Memory: "RAM byte-hours".<br/> The fee for RAM required to process a transaction, measured in byte-hours
    setSbh(long value)
    * Disk: "storage byte-hours".<br/> The fee for storage required by a transaction, measured in byte-hours
    setSbpr(long value)
    * Response disk: "storage bytes per response".<br/> The fee for data retrieved from disk to deliver a response, measured in bytes
    setTv(long value)
    * Ad valorem: "transferred value".<br/> The fee for HBAR transferred by a transaction.
    setVpt(long value)
    * Signatures: "validations per transaction".<br/> The fee for signature verifications required by a transaction

    Methods inherited from class com.google.protobuf.GeneratedMessageLite.Builder

    build, buildPartial, clear, clone, copyOnWrite, copyOnWriteInternal, getDefaultInstanceForType, internalMergeFrom, isInitialized, mergeFrom, mergeFrom, mergeFrom, mergeFrom

    Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder

    addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder

    getDefaultInstanceForType, isInitialized
  • Method Details

    • getMin

      public long getMin()
       *
       Base: "minimum total fee".
       <p>
       The calculated fee MUST be greater than this value.
       
      int64 min = 1;
      Specified by:
      getMin in interface FeeComponentsOrBuilder
      Returns:
      The min.
    • setMin

      public FeeComponents.Builder setMin(long value)
       *
       Base: "minimum total fee".
       <p>
       The calculated fee MUST be greater than this value.
       
      int64 min = 1;
      Parameters:
      value - The min to set.
      Returns:
      This builder for chaining.
    • clearMin

      public FeeComponents.Builder clearMin()
       *
       Base: "minimum total fee".
       <p>
       The calculated fee MUST be greater than this value.
       
      int64 min = 1;
      Returns:
      This builder for chaining.
    • getMax

      public long getMax()
       *
       Base: "maximum total fee".
       <p>
       The calculated fee MUST be less than this value.
       
      int64 max = 2;
      Specified by:
      getMax in interface FeeComponentsOrBuilder
      Returns:
      The max.
    • setMax

      public FeeComponents.Builder setMax(long value)
       *
       Base: "maximum total fee".
       <p>
       The calculated fee MUST be less than this value.
       
      int64 max = 2;
      Parameters:
      value - The max to set.
      Returns:
      This builder for chaining.
    • clearMax

      public FeeComponents.Builder clearMax()
       *
       Base: "maximum total fee".
       <p>
       The calculated fee MUST be less than this value.
       
      int64 max = 2;
      Returns:
      This builder for chaining.
    • getConstant

      public long getConstant()
       *
       Base: "constant fee".<br/>
       A baseline constant contribution to total fee.
       
      int64 constant = 3;
      Specified by:
      getConstant in interface FeeComponentsOrBuilder
      Returns:
      The constant.
    • setConstant

      public FeeComponents.Builder setConstant(long value)
       *
       Base: "constant fee".<br/>
       A baseline constant contribution to total fee.
       
      int64 constant = 3;
      Parameters:
      value - The constant to set.
      Returns:
      This builder for chaining.
    • clearConstant

      public FeeComponents.Builder clearConstant()
       *
       Base: "constant fee".<br/>
       A baseline constant contribution to total fee.
       
      int64 constant = 3;
      Returns:
      This builder for chaining.
    • getBpt

      public long getBpt()
       *
       Bandwidth: "bytes per transaction".<br/>
       The fee for bandwidth consumed by a transaction, measured in bytes
       
      int64 bpt = 4;
      Specified by:
      getBpt in interface FeeComponentsOrBuilder
      Returns:
      The bpt.
    • setBpt

      public FeeComponents.Builder setBpt(long value)
       *
       Bandwidth: "bytes per transaction".<br/>
       The fee for bandwidth consumed by a transaction, measured in bytes
       
      int64 bpt = 4;
      Parameters:
      value - The bpt to set.
      Returns:
      This builder for chaining.
    • clearBpt

      public FeeComponents.Builder clearBpt()
       *
       Bandwidth: "bytes per transaction".<br/>
       The fee for bandwidth consumed by a transaction, measured in bytes
       
      int64 bpt = 4;
      Returns:
      This builder for chaining.
    • getVpt

      public long getVpt()
       *
       Signatures: "validations per transaction".<br/>
       The fee for signature verifications required by a transaction
       
      int64 vpt = 5;
      Specified by:
      getVpt in interface FeeComponentsOrBuilder
      Returns:
      The vpt.
    • setVpt

      public FeeComponents.Builder setVpt(long value)
       *
       Signatures: "validations per transaction".<br/>
       The fee for signature verifications required by a transaction
       
      int64 vpt = 5;
      Parameters:
      value - The vpt to set.
      Returns:
      This builder for chaining.
    • clearVpt

      public FeeComponents.Builder clearVpt()
       *
       Signatures: "validations per transaction".<br/>
       The fee for signature verifications required by a transaction
       
      int64 vpt = 5;
      Returns:
      This builder for chaining.
    • getRbh

      public long getRbh()
       *
       Memory: "RAM byte-hours".<br/>
       The fee for RAM required to process a transaction,
       measured in byte-hours
       
      int64 rbh = 6;
      Specified by:
      getRbh in interface FeeComponentsOrBuilder
      Returns:
      The rbh.
    • setRbh

      public FeeComponents.Builder setRbh(long value)
       *
       Memory: "RAM byte-hours".<br/>
       The fee for RAM required to process a transaction,
       measured in byte-hours
       
      int64 rbh = 6;
      Parameters:
      value - The rbh to set.
      Returns:
      This builder for chaining.
    • clearRbh

      public FeeComponents.Builder clearRbh()
       *
       Memory: "RAM byte-hours".<br/>
       The fee for RAM required to process a transaction,
       measured in byte-hours
       
      int64 rbh = 6;
      Returns:
      This builder for chaining.
    • getSbh

      public long getSbh()
       *
       Disk: "storage byte-hours".<br/>
       The fee for storage required by a transaction, measured in byte-hours
       
      int64 sbh = 7;
      Specified by:
      getSbh in interface FeeComponentsOrBuilder
      Returns:
      The sbh.
    • setSbh

      public FeeComponents.Builder setSbh(long value)
       *
       Disk: "storage byte-hours".<br/>
       The fee for storage required by a transaction, measured in byte-hours
       
      int64 sbh = 7;
      Parameters:
      value - The sbh to set.
      Returns:
      This builder for chaining.
    • clearSbh

      public FeeComponents.Builder clearSbh()
       *
       Disk: "storage byte-hours".<br/>
       The fee for storage required by a transaction, measured in byte-hours
       
      int64 sbh = 7;
      Returns:
      This builder for chaining.
    • getGas

      public long getGas()
       *
       Compute: Ethereum term for a derivative EVM compute resource.<br/>
       The fee of computation for a smart contract transaction. The value of
       gas is set by a conversion rate, and is regularly updated to reflect
       reasonable and customary costs.
       
      int64 gas = 8;
      Specified by:
      getGas in interface FeeComponentsOrBuilder
      Returns:
      The gas.
    • setGas

      public FeeComponents.Builder setGas(long value)
       *
       Compute: Ethereum term for a derivative EVM compute resource.<br/>
       The fee of computation for a smart contract transaction. The value of
       gas is set by a conversion rate, and is regularly updated to reflect
       reasonable and customary costs.
       
      int64 gas = 8;
      Parameters:
      value - The gas to set.
      Returns:
      This builder for chaining.
    • clearGas

      public FeeComponents.Builder clearGas()
       *
       Compute: Ethereum term for a derivative EVM compute resource.<br/>
       The fee of computation for a smart contract transaction. The value of
       gas is set by a conversion rate, and is regularly updated to reflect
       reasonable and customary costs.
       
      int64 gas = 8;
      Returns:
      This builder for chaining.
    • getTv

      public long getTv()
       *
       Ad valorem: "transferred value".<br/>
       The fee for HBAR transferred by a transaction.
       
      int64 tv = 9;
      Specified by:
      getTv in interface FeeComponentsOrBuilder
      Returns:
      The tv.
    • setTv

      public FeeComponents.Builder setTv(long value)
       *
       Ad valorem: "transferred value".<br/>
       The fee for HBAR transferred by a transaction.
       
      int64 tv = 9;
      Parameters:
      value - The tv to set.
      Returns:
      This builder for chaining.
    • clearTv

      public FeeComponents.Builder clearTv()
       *
       Ad valorem: "transferred value".<br/>
       The fee for HBAR transferred by a transaction.
       
      int64 tv = 9;
      Returns:
      This builder for chaining.
    • getBpr

      public long getBpr()
       *
       Response memory: "bytes per response".<br/>
       The fee for data retrieved from memory to deliver a response,
       measured in bytes
       
      int64 bpr = 10;
      Specified by:
      getBpr in interface FeeComponentsOrBuilder
      Returns:
      The bpr.
    • setBpr

      public FeeComponents.Builder setBpr(long value)
       *
       Response memory: "bytes per response".<br/>
       The fee for data retrieved from memory to deliver a response,
       measured in bytes
       
      int64 bpr = 10;
      Parameters:
      value - The bpr to set.
      Returns:
      This builder for chaining.
    • clearBpr

      public FeeComponents.Builder clearBpr()
       *
       Response memory: "bytes per response".<br/>
       The fee for data retrieved from memory to deliver a response,
       measured in bytes
       
      int64 bpr = 10;
      Returns:
      This builder for chaining.
    • getSbpr

      public long getSbpr()
       *
       Response disk: "storage bytes per response".<br/>
       The fee for data retrieved from disk to deliver a response,
       measured in bytes
       
      int64 sbpr = 11;
      Specified by:
      getSbpr in interface FeeComponentsOrBuilder
      Returns:
      The sbpr.
    • setSbpr

      public FeeComponents.Builder setSbpr(long value)
       *
       Response disk: "storage bytes per response".<br/>
       The fee for data retrieved from disk to deliver a response,
       measured in bytes
       
      int64 sbpr = 11;
      Parameters:
      value - The sbpr to set.
      Returns:
      This builder for chaining.
    • clearSbpr

      public FeeComponents.Builder clearSbpr()
       *
       Response disk: "storage bytes per response".<br/>
       The fee for data retrieved from disk to deliver a response,
       measured in bytes
       
      int64 sbpr = 11;
      Returns:
      This builder for chaining.