Examples of AmountTransaction


Examples of org.gsm.oneapi.responsebean.payment.AmountTransaction

       
        String serverReferenceCode="ABC-123";
 
        String resourceURL=getRequestHostnameAndContext(request)+request.getServletPath()+"/1/payment/"+(endUserId!=null?urlEncode(endUserId):"")+"/transactions/amount"+(referenceCode!=null?("/"+urlEncode(serverReferenceCode)):"");
       
        AmountTransaction rd=new AmountTransaction();
       
        rd.setClientCorrelator(clientCorrelator);
        rd.setEndUserId(endUserId);
        AmountTransaction.PaymentAmount.ChargingInformation charge=new AmountTransaction.PaymentAmount.ChargingInformation();
        charge.setAmount(amount);
        charge.setCurrency(currency);
        charge.setDescription(description);
       
        AmountTransaction.PaymentAmount payment=new AmountTransaction.PaymentAmount();
        payment.setChargingInformation(charge);
       
        payment.setTotalAmountCharged(amount);
       
        rd.setPaymentAmount(payment);
        rd.setReferenceCode(referenceCode);
        if (callbackURL==null) {
          rd.setTransactionOperationStatus(transactionOperationStatus);
        } else {
          rd.setTransactionOperationStatus("Processing");
        }
        rd.setResourceURL(resourceURL);
        rd.setClientCorrelator(clientCorrelator);
        rd.setServerReferenceCode(serverReferenceCode);
         
        ObjectMapper mapper=new ObjectMapper();     
        String jsonResponse="{\"amountTransaction\":"+mapper.writeValueAsString(rd)+"}";
 
        if (callbackURL==null) {
View Full Code Here

Examples of org.gsm.oneapi.responsebean.payment.AmountTransaction

 
        String serverReferenceCode="ABC-123";
 
        String resourceURL=getRequestHostnameAndContext(request)+request.getServletPath()+"/1/payment/"+(endUserId!=null?urlEncode(endUserId):"")+"/transactions/amount"+(referenceCode!=null?("/"+urlEncode(serverReferenceCode)):"");
       
        AmountTransaction rd=new AmountTransaction();
       
        rd.setClientCorrelator(clientCorrelator);
        rd.setEndUserId(endUserId);
        AmountTransaction.PaymentAmount.ChargingInformation charge=new AmountTransaction.PaymentAmount.ChargingInformation();
        charge.setAmount(amount);
        charge.setCurrency(currency);
        charge.setDescription(description);
       
        AmountTransaction.PaymentAmount payment=new AmountTransaction.PaymentAmount();
        payment.setChargingInformation(charge);
       
        payment.setTotalAmountCharged(amount);
       
        rd.setPaymentAmount(payment);
        rd.setReferenceCode(referenceCode);
        rd.setTransactionOperationStatus(transactionOperationStatus);
        rd.setResourceURL(resourceURL);
        rd.setClientCorrelator(clientCorrelator);
        rd.setServerReferenceCode(serverReferenceCode);

        ObjectMapper mapper=new ObjectMapper();     
        String jsonResponse="{\"amountTransaction\":"+mapper.writeValueAsString(rd)+"}";
 
        sendJSONResponse(response, jsonResponse, OK, resourceURL);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.