com.google.checkout.orderprocessing
Class ChargeOrderRequest

java.lang.Object
  extended by com.google.checkout.AbstractCheckoutRequest
      extended by com.google.checkout.orderprocessing.AbstractOrderProcessingRequest
          extended by com.google.checkout.orderprocessing.ChargeOrderRequest

public class ChargeOrderRequest
extends AbstractOrderProcessingRequest

This class contains methods that construct <charge-order> API requests.

Author:
Charles Dang (cdang@google.com)

Field Summary
 
Fields inherited from class com.google.checkout.AbstractCheckoutRequest
merchantInfo
 
Constructor Summary
ChargeOrderRequest(MerchantInfo merchantInfo)
          Constructor which takes an instance of MechantInfo and the Google order
ChargeOrderRequest(MerchantInfo merchantInfo, java.lang.String googleOrderNumber)
          Constructor which takes an instance of merchantInfo and the Google order number.
ChargeOrderRequest(MerchantInfo merchantInfo, java.lang.String googleOrderNumber, float amount)
          Constructor which takes an instance of MerchantInfo, the Google order number and the amount to be charged.
 
Method Summary
 float getAmount()
          Return the charge amount, which is the value of the <amount> tag.
 void setAmount(float amount)
          Set the charge amount, which is the value of the <amount> tag.
 
Methods inherited from class com.google.checkout.orderprocessing.AbstractOrderProcessingRequest
getGoogleOrderNo, getGoogleOrderNumber, setGoogleOrderNo, setGoogleOrderNumber
 
Methods inherited from class com.google.checkout.AbstractCheckoutRequest
getDocument, getPostUrl, getRoot, getXml, getXmlPretty, send
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChargeOrderRequest

public ChargeOrderRequest(MerchantInfo merchantInfo)
Constructor which takes an instance of MechantInfo and the Google order

Parameters:
merchantInfo - The merchant's information.

ChargeOrderRequest

public ChargeOrderRequest(MerchantInfo merchantInfo,
                          java.lang.String googleOrderNumber)
Constructor which takes an instance of merchantInfo and the Google order number.

Parameters:
merchantInfo - The merchant's information.
googleOrderNumber - The Google order number.

ChargeOrderRequest

public ChargeOrderRequest(MerchantInfo merchantInfo,
                          java.lang.String googleOrderNumber,
                          float amount)
Constructor which takes an instance of MerchantInfo, the Google order number and the amount to be charged.

Parameters:
merchantInfo - The merchant's information.
googleOrderNumber - The Google order number.
amount - The amount to charge.
Method Detail

getAmount

public float getAmount()
Return the charge amount, which is the value of the <amount> tag.

Returns:
The charge amount.

setAmount

public void setAmount(float amount)
Set the charge amount, which is the value of the <amount> tag.

Parameters:
amount - The charge amount.