类 PaymentController


  • public class PaymentController
    extends java.lang.Object
    The payment controller is the wrapper class for accessing the payment module.
    • 方法概要

      所有方法 实例方法 具体方法 
      修饰符和类型 方法 说明
      Order getBackupOrder​(int orderId)
      Get the order information of the backup by the order id.
      java.util.List<Order> getOrders​(java.lang.String subscription)
      Get the orders by the subscription type.
      Receipt getReceipt​(int orderId)
      Get the receipt by the order id.
      java.util.List<Receipt> getReceipts()
      Get the receipts belongs to the current user.
      Order getVaultOrder​(int orderId)
      Get the order information of the vault by the order id.
      java.lang.String getVersion()
      Get the version of the payment module.
      Order placeOrder​(java.lang.String subscription, java.lang.String pricingName)
      This is for creating the payment order which upgrades the pricing plan of the vault or the backup.
      Receipt settleOrder​(int orderId)
      Pay the order by the order id and the transaction id.
      • 从类继承的方法 java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • 构造器详细资料

    • 方法详细资料

      • placeOrder

        public Order placeOrder​(java.lang.String subscription,
                                java.lang.String pricingName)
                         throws HiveException
        This is for creating the payment order which upgrades the pricing plan of the vault or the backup.
        参数:
        subscription - The value is "vault" or "backup".
        pricingName - The pricing plan name.
        返回:
        The details of the order.
        抛出:
        HiveException - The error comes from the hive node.
      • settleOrder

        public Receipt settleOrder​(int orderId)
                            throws HiveException
        Pay the order by the order id and the transaction id.
        参数:
        orderId - The order id of payment contract
        返回:
        The order which is the proof of the payment of the order for the user.
        抛出:
        HiveException - The error comes from the hive node.
      • getVaultOrder

        public Order getVaultOrder​(int orderId)
                            throws HiveException
        Get the order information of the vault by the order id.
        参数:
        orderId - of payment contract
        返回:
        The details of the order.
        抛出:
        HiveException - The error comes from the hive node.
      • getBackupOrder

        public Order getBackupOrder​(int orderId)
                             throws HiveException
        Get the order information of the backup by the order id.
        参数:
        orderId - of payment contract
        返回:
        The details of the order.
        抛出:
        HiveException - The error comes from the hive node.
      • getOrders

        public java.util.List<Order> getOrders​(java.lang.String subscription)
                                        throws HiveException
        Get the orders by the subscription type.
        参数:
        subscription - The value is "vault" or "backup".
        返回:
        The order list, MUST not empty.
        抛出:
        HiveException - The error comes from the hive node.
      • getReceipt

        public Receipt getReceipt​(int orderId)
                           throws HiveException
        Get the receipt by the order id.
        参数:
        orderId - The order id.
        返回:
        The details of the receipt.
        抛出:
        HiveException - The error comes from the hive node.
      • getReceipts

        public java.util.List<Receipt> getReceipts()
                                            throws HiveException
        Get the receipts belongs to the current user.
        返回:
        The details of the receipt.
        抛出:
        HiveException - The error comes from the hive node.
      • getVersion

        public java.lang.String getVersion()
                                    throws HiveException
        Get the version of the payment module.
        返回:
        The version.
        抛出:
        HiveException - The error comes from the hive node.