Class ContractDeleteTransactionBody.Builder

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

public static final class ContractDeleteTransactionBody.Builder extends com.google.protobuf.GeneratedMessageLite.Builder<ContractDeleteTransactionBody,ContractDeleteTransactionBody.Builder> implements ContractDeleteTransactionBodyOrBuilder
 *
 Delete a smart contract, and transfer any remaining HBAR balance to a
 designated account.

 If this call succeeds then all subsequent calls to that smart contract
 SHALL execute the `0x0` opcode, as required for EVM equivalence.

 ### Requirements
 - An account or smart contract MUST be designated to receive all remaining
 account balances.
 - The smart contract MUST have an admin key set. If the contract does not
 have `admin_key` set, then this transaction SHALL fail and response code
 `MODIFYING_IMMUTABLE_CONTRACT` SHALL be set.
 - If `admin_key` is, or contains, an empty `KeyList` key, it SHALL be
 treated the same as an admin key that is not set.
 - The `Key` set for `admin_key` on the smart contract MUST have a valid
 signature set on this transaction.
 - The designated receiving account MAY have `receiver_sig_required` set. If
 that field is set, the receiver account MUST also sign this transaction.
 - The field `permanent_removal` MUST NOT be set. That field is reserved for
 internal system use when purging the smart contract from state. Any user
 transaction with that field set SHALL be rejected and a response code
 `PERMANENT_REMOVAL_REQUIRES_SYSTEM_INITIATION` SHALL be set.

 ### Block Stream Effects
 None
 
Protobuf type proto.ContractDeleteTransactionBody
  • Method Details

    • getObtainersCase

      Specified by:
      getObtainersCase in interface ContractDeleteTransactionBodyOrBuilder
    • clearObtainers

      public ContractDeleteTransactionBody.Builder clearObtainers()
    • hasContractID

      public boolean hasContractID()
       *
       The id of the contract to be deleted.
       <p>
       This field is REQUIRED.
       
      .proto.ContractID contractID = 1;
      Specified by:
      hasContractID in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      Whether the contractID field is set.
    • getContractID

      public ContractID getContractID()
       *
       The id of the contract to be deleted.
       <p>
       This field is REQUIRED.
       
      .proto.ContractID contractID = 1;
      Specified by:
      getContractID in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      The contractID.
    • setContractID

      public ContractDeleteTransactionBody.Builder setContractID(ContractID value)
       *
       The id of the contract to be deleted.
       <p>
       This field is REQUIRED.
       
      .proto.ContractID contractID = 1;
    • setContractID

      public ContractDeleteTransactionBody.Builder setContractID(ContractID.Builder builderForValue)
       *
       The id of the contract to be deleted.
       <p>
       This field is REQUIRED.
       
      .proto.ContractID contractID = 1;
    • mergeContractID

      public ContractDeleteTransactionBody.Builder mergeContractID(ContractID value)
       *
       The id of the contract to be deleted.
       <p>
       This field is REQUIRED.
       
      .proto.ContractID contractID = 1;
    • clearContractID

      public ContractDeleteTransactionBody.Builder clearContractID()
       *
       The id of the contract to be deleted.
       <p>
       This field is REQUIRED.
       
      .proto.ContractID contractID = 1;
    • hasTransferAccountID

      public boolean hasTransferAccountID()
       *
       An Account ID recipient.
       <p>
       This account SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.AccountID transferAccountID = 2;
      Specified by:
      hasTransferAccountID in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      Whether the transferAccountID field is set.
    • getTransferAccountID

      public AccountID getTransferAccountID()
       *
       An Account ID recipient.
       <p>
       This account SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.AccountID transferAccountID = 2;
      Specified by:
      getTransferAccountID in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      The transferAccountID.
    • setTransferAccountID

      public ContractDeleteTransactionBody.Builder setTransferAccountID(AccountID value)
       *
       An Account ID recipient.
       <p>
       This account SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.AccountID transferAccountID = 2;
    • setTransferAccountID

      public ContractDeleteTransactionBody.Builder setTransferAccountID(AccountID.Builder builderForValue)
       *
       An Account ID recipient.
       <p>
       This account SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.AccountID transferAccountID = 2;
    • mergeTransferAccountID

      public ContractDeleteTransactionBody.Builder mergeTransferAccountID(AccountID value)
       *
       An Account ID recipient.
       <p>
       This account SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.AccountID transferAccountID = 2;
    • clearTransferAccountID

      public ContractDeleteTransactionBody.Builder clearTransferAccountID()
       *
       An Account ID recipient.
       <p>
       This account SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.AccountID transferAccountID = 2;
    • hasTransferContractID

      public boolean hasTransferContractID()
       *
       A contract ID recipient.
       <p>
       This contract SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.ContractID transferContractID = 3;
      Specified by:
      hasTransferContractID in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      Whether the transferContractID field is set.
    • getTransferContractID

      public ContractID getTransferContractID()
       *
       A contract ID recipient.
       <p>
       This contract SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.ContractID transferContractID = 3;
      Specified by:
      getTransferContractID in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      The transferContractID.
    • setTransferContractID

      public ContractDeleteTransactionBody.Builder setTransferContractID(ContractID value)
       *
       A contract ID recipient.
       <p>
       This contract SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.ContractID transferContractID = 3;
    • setTransferContractID

      public ContractDeleteTransactionBody.Builder setTransferContractID(ContractID.Builder builderForValue)
       *
       A contract ID recipient.
       <p>
       This contract SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.ContractID transferContractID = 3;
    • mergeTransferContractID

      public ContractDeleteTransactionBody.Builder mergeTransferContractID(ContractID value)
       *
       A contract ID recipient.
       <p>
       This contract SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.ContractID transferContractID = 3;
    • clearTransferContractID

      public ContractDeleteTransactionBody.Builder clearTransferContractID()
       *
       A contract ID recipient.
       <p>
       This contract SHALL receive all HBAR and other tokens still owned by
       the contract that is removed.
       
      .proto.ContractID transferContractID = 3;
    • getPermanentRemoval

      public boolean getPermanentRemoval()
       *
       A flag indicating that this transaction is "synthetic"; initiated by the
       node software.
       <p>
       The consensus nodes create such "synthetic" transactions to both to
       properly manage state changes and to communicate those changes to other
       systems via the Block Stream.<br/>
       A user-initiated transaction MUST NOT set this flag.
       
      bool permanent_removal = 4;
      Specified by:
      getPermanentRemoval in interface ContractDeleteTransactionBodyOrBuilder
      Returns:
      The permanentRemoval.
    • setPermanentRemoval

      public ContractDeleteTransactionBody.Builder setPermanentRemoval(boolean value)
       *
       A flag indicating that this transaction is "synthetic"; initiated by the
       node software.
       <p>
       The consensus nodes create such "synthetic" transactions to both to
       properly manage state changes and to communicate those changes to other
       systems via the Block Stream.<br/>
       A user-initiated transaction MUST NOT set this flag.
       
      bool permanent_removal = 4;
      Parameters:
      value - The permanentRemoval to set.
      Returns:
      This builder for chaining.
    • clearPermanentRemoval

      public ContractDeleteTransactionBody.Builder clearPermanentRemoval()
       *
       A flag indicating that this transaction is "synthetic"; initiated by the
       node software.
       <p>
       The consensus nodes create such "synthetic" transactions to both to
       properly manage state changes and to communicate those changes to other
       systems via the Block Stream.<br/>
       A user-initiated transaction MUST NOT set this flag.
       
      bool permanent_removal = 4;
      Returns:
      This builder for chaining.