Class TokenServiceGrpc.TokenServiceBlockingV2Stub

java.lang.Object
io.grpc.stub.AbstractStub<TokenServiceGrpc.TokenServiceBlockingV2Stub>
io.grpc.stub.AbstractBlockingStub<TokenServiceGrpc.TokenServiceBlockingV2Stub>
com.hedera.hashgraph.sdk.proto.TokenServiceGrpc.TokenServiceBlockingV2Stub
Enclosing class:
TokenServiceGrpc

public static final class TokenServiceGrpc.TokenServiceBlockingV2Stub extends io.grpc.stub.AbstractBlockingStub<TokenServiceGrpc.TokenServiceBlockingV2Stub>
A stub to allow clients to do synchronous rpc calls to service TokenService.

 Transactions and queries for the Token Service
 
  • Method Details

    • build

      protected TokenServiceGrpc.TokenServiceBlockingV2Stub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions)
      Specified by:
      build in class io.grpc.stub.AbstractStub<TokenServiceGrpc.TokenServiceBlockingV2Stub>
    • createToken

      public TransactionResponse createToken(Transaction request) throws io.grpc.StatusException
      
       Create a new token.
       
      Throws:
      io.grpc.StatusException
    • updateToken

      public TransactionResponse updateToken(Transaction request) throws io.grpc.StatusException
      
       Update a token.
       
      Throws:
      io.grpc.StatusException
    • mintToken

      public TransactionResponse mintToken(Transaction request) throws io.grpc.StatusException
      
       Mint one or more tokens to the treasury account.
       <p>
       This MAY specify a quantity of fungible/common tokens or
       a list of specific non-fungible/unique tokes, but
       MUST NOT specify both.
       
      Throws:
      io.grpc.StatusException
    • burnToken

      public TransactionResponse burnToken(Transaction request) throws io.grpc.StatusException
      
       Burn one or more tokens from the treasury account.
       <p>
       This MAY specify a quantity of fungible/common tokens or
       a list of specific non-fungible/unique tokes, but
       MUST NOT specify both.
       
      Throws:
      io.grpc.StatusException
    • deleteToken

      public TransactionResponse deleteToken(Transaction request) throws io.grpc.StatusException
      
       Delete a token.
       
      Throws:
      io.grpc.StatusException
    • wipeTokenAccount

      public TransactionResponse wipeTokenAccount(Transaction request) throws io.grpc.StatusException
      
       Wipe one or more tokens from an identified Account.
       <p>
       This MAY specify a quantity of fungible/common tokens or
       a list of specific non-fungible/unique tokes, but
       MUST NOT specify both.
       
      Throws:
      io.grpc.StatusException
    • freezeTokenAccount

      public TransactionResponse freezeTokenAccount(Transaction request) throws io.grpc.StatusException
      
       Freeze the transfer of tokens to or from an identified Account.
       
      Throws:
      io.grpc.StatusException
    • unfreezeTokenAccount

      public TransactionResponse unfreezeTokenAccount(Transaction request) throws io.grpc.StatusException
      
       Unfreeze the transfer of tokens to or from an identified Account.
       
      Throws:
      io.grpc.StatusException
    • grantKycToTokenAccount

      public TransactionResponse grantKycToTokenAccount(Transaction request) throws io.grpc.StatusException
      
       Assert that KYC requirements are met for a specific account with
       respect to a specific token.
       
      Throws:
      io.grpc.StatusException
    • revokeKycFromTokenAccount

      public TransactionResponse revokeKycFromTokenAccount(Transaction request) throws io.grpc.StatusException
      
       Assert that KYC requirements are _not_ met for a specific account with
       respect to a specific token.
       
      Throws:
      io.grpc.StatusException
    • associateTokens

      public TransactionResponse associateTokens(Transaction request) throws io.grpc.StatusException
      
       Associate one or more tokens to an account.
       
      Throws:
      io.grpc.StatusException
    • dissociateTokens

      public TransactionResponse dissociateTokens(Transaction request) throws io.grpc.StatusException
      
       Dissociate one or more tokens from an account.
       
      Throws:
      io.grpc.StatusException
    • updateTokenFeeSchedule

      public TransactionResponse updateTokenFeeSchedule(Transaction request) throws io.grpc.StatusException
      
       Update the custom fee schedule for a token.
       
      Throws:
      io.grpc.StatusException
    • getTokenInfo

      public Response getTokenInfo(Query request) throws io.grpc.StatusException
      
       Retrieve the detail characteristics for a token.
       <p>
       This query SHALL return information for the token type as a whole.<br/>
       This query SHALL NOT return information for individual tokens.
       
      Throws:
      io.grpc.StatusException
    • getTokenNftInfo

      public Response getTokenNftInfo(Query request) throws io.grpc.StatusException
      
       Retrieve the metadata for a specific non-fungible/unique token.<br/>
       The NFT to query is identified by token identifier and serial number.
       <p>
       This query SHALL return token metadata and, if an allowance is defined,
       the designated "spender" account for the queried NFT.
       
      Throws:
      io.grpc.StatusException
    • pauseToken

      public TransactionResponse pauseToken(Transaction request) throws io.grpc.StatusException
      
       Pause a token.
       
      Throws:
      io.grpc.StatusException
    • unpauseToken

      public TransactionResponse unpauseToken(Transaction request) throws io.grpc.StatusException
      
       Unpause (resume) a token.
       
      Throws:
      io.grpc.StatusException
    • updateNfts

      public TransactionResponse updateNfts(Transaction request) throws io.grpc.StatusException
      
       Update multiple non-fungible/unique tokens (NFTs) in a collection.<br/>
       The NFTs are identified by token identifier and one or more
       serial numbers.
       <p>
       This transaction SHALL update NFT metadata only.<br/>
       This transaction MUST be signed by the token `metadata_key`.
       
      Throws:
      io.grpc.StatusException
    • rejectToken

      public TransactionResponse rejectToken(Transaction request) throws io.grpc.StatusException
      
       Reject one or more tokens.
       <p>
       This transaction SHALL transfer the full balance of one or more tokens
       from the requesting account to the treasury for each token.<br/>
       This transfer SHALL NOT charge any custom fee or royalty defined for
       the token(s) to be rejected.<br/>
       ### Effects on success
       <ul>
         <li>If the rejected token is fungible/common, the requesting account
             SHALL have a balance of 0 for the rejected token.<br/>
             The treasury balance SHALL increase by the amount that the
             requesting account decreased.</li>
         <li>If the rejected token is non-fungible/unique the requesting
             account SHALL NOT hold the specific serialized token that
             is rejected.<br/>
             The treasury account SHALL hold each specific serialized token
             that was rejected.</li>
       </li>
       
      Throws:
      io.grpc.StatusException
    • airdropTokens

      public TransactionResponse airdropTokens(Transaction request) throws io.grpc.StatusException
      
       Airdrop one or more tokens to one or more accounts.
       <p>
       This transaction SHALL distribute tokens from the balance of one or
       more sending account(s) to the balance of one or more
       recipient accounts.<br/>
       Accounts SHALL receive the tokens in one of four ways.
       <ul>
         <li>An account already associated to the token to be distributed
             SHALL receive the airdropped tokens immediately to the
             recipient account balance.</li>
         <li>An account with available automatic association slots SHALL
             be automatically associated to the token, and SHALL
             immediately receive the airdropped tokens to the recipient
             account balance.</li>
         <li>An account with "receiver signature required" set SHALL have
             a "Pending Airdrop" created and MUST claim that airdrop with
             a `claimAirdrop` transaction.</li>
         <li>An account with no available automatic association slots SHALL
             have a "Pending Airdrop" created and MUST claim that airdrop
             with a `claimAirdrop` transaction. </li>
       </ul>
       Any airdrop that completes immediately SHALL be irreversible.<br/>
       Any airdrop that results in a "Pending Airdrop" MAY be canceled via
       a `cancelAirdrop` transaction.<br/>
       All transfer fees (including custom fees and royalties), as well as
       the rent cost for the first auto-renewal period for any
       automatic-association slot occupied by the airdropped tokens,
       SHALL be charged to the account submitting this transaction.
       
      Throws:
      io.grpc.StatusException
    • cancelAirdrop

      public TransactionResponse cancelAirdrop(Transaction request) throws io.grpc.StatusException
      
       Cancel one or more pending airdrops.
       <p>
       This transaction MUST be signed by _each_ account *sending* an
       airdrop to be canceled.
       
      Throws:
      io.grpc.StatusException
    • claimAirdrop

      public TransactionResponse claimAirdrop(Transaction request) throws io.grpc.StatusException
      
       Claim one or more pending airdrops.
       <p>
       This transaction MUST be signed by _each_ account **receiving**
       an airdrop to be claimed.<br>
       If a "Sender" lacks sufficient balance to fulfill the airdrop at
       the time the claim is made, that claim SHALL fail.
       
      Throws:
      io.grpc.StatusException