Class TokenContractRPCClient


  • public class TokenContractRPCClient
    extends ContractRPCClient
    Starcoin Token 相关json-rpc接口的封装。
    Since:
    1.1.6
    Author:
    fanngyuan
    • Constructor Detail

      • TokenContractRPCClient

        public TokenContractRPCClient​(URL baseUrl)
    • Method Detail

      • getTokenMarketCap

        public BigInteger getTokenMarketCap​(String tokenTypeTag)
                                     throws com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
        获取某个 token 的市场容量
        Throws:
        com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
      • getTreasurBalance

        public BigInteger getTreasurBalance​(String tokenTypeTag)
                                     throws com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
        用于获取某个 token 在国库中的数量
        Throws:
        com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
      • getTokenCurrentSupply

        public BigInteger getTokenCurrentSupply​(String tokenTypeTag)
                                         throws com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
        获取某个 token 的实际供应量
        Throws:
        com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
      • getSTCMarketCap

        public BigInteger getSTCMarketCap()
                                   throws com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
        用于获取 STC 的市场容量
        Throws:
        com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
      • getSTCTreasurBalance

        public BigInteger getSTCTreasurBalance()
                                        throws com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
        用于获取 STC 在国库中的数量
        Throws:
        com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
      • getSTCCurrentSupply

        public BigInteger getSTCCurrentSupply()
                                       throws com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException
        获取 STC 的实际供应量
        Throws:
        com.thetransactioncompany.jsonrpc2.client.JSONRPC2SessionException