|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectpaypalnvp.fields.Payment
public final class Payment
Payment Details Type Fields. For simple paymets use constructor with amount field. If you want to set tax, or more options, use Constructor that takes PaymentItem array.
Constructor Summary | |
---|---|
Payment(PaymentItem[] items)
Create Payment from supplied items. |
|
Payment(java.lang.String amount)
You are adviced to use Payment(PaymentItem[] itmes) contructor, where you can specify all items individually, add individual descriptions, recurring payments etc. |
|
Payment(java.lang.String amount,
EbayPaymentItem[] items)
Create Payment from supplied ebay items. |
Method Summary | |
---|---|
java.util.Map<java.lang.String,java.lang.String> |
getNVPRequest()
Creates and returns part of the nvp (name value pair) request containing request values |
void |
setAllowedPaymentMethod(java.lang.String method)
The payment method type. |
void |
setButtonSource(java.lang.String source)
An identification code for use by third-party applications to identify transactions. |
void |
setCurrency(Currency currency)
A three-character currency code. |
void |
setCustomField(java.lang.String field)
A free-form field for your own use. |
void |
setDescription(java.lang.String description)
Description of items the customer is purchasing. |
void |
setHandlingAmount(java.lang.String amount)
Total handling costs for this order. |
void |
setInsuranceAmount(java.lang.String amount)
Total shipping insurance costs for this order. |
void |
setInsuranceAmount(java.lang.String amount,
boolean insuranceOption)
Total shipping insurance costs for this order. |
void |
setInvoiceNumber(java.lang.String invoiceNumber)
Your own invoice or tracking number. |
void |
setNote(java.lang.String note)
Note to the seller. |
void |
setNotifyUrl(java.lang.String url)
Your URL for receiving Instant Payment Notification (IPN) about this transaction. |
void |
setShippingAmount(java.lang.String amount)
Total shipping costs for this order. |
void |
setShippingDiscount(java.lang.String discount)
Shipping discount for this order, specified as a negative number. |
void |
setTransactionId(java.lang.String transactionId)
Transaction identification number of the transaction that was created. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Payment(java.lang.String amount) throws java.lang.IllegalArgumentException
amount
- Limitations: Must not exceed $10,000 USD in any
currency. No currency symbol. Must have two decimal
places, decimal separator must be a period (.), and no
thousands separator.
java.lang.IllegalArgumentException
public Payment(PaymentItem[] items) throws java.lang.IllegalArgumentException
items
-
java.lang.IllegalArgumentException
public Payment(java.lang.String amount, EbayPaymentItem[] items) throws java.lang.IllegalArgumentException
amount
- Set this field to 0 if the transaction does not include
a one-time purchase; for example, when you set up a
billing agreement for a recurring payment that is not
immediately charged.
Limitations: Must not exceed $10,000 USD in any
currency. No currency symbol. Must have two decimal
places, decimal separator must be a period (.), and no
thousands separator.amount
- items
-
java.lang.IllegalArgumentException
Method Detail |
---|
public void setCurrency(Currency currency)
currency
- public void setShippingAmount(java.lang.String amount) throws java.lang.IllegalArgumentException
amount
-
java.lang.IllegalArgumentException
public void setInsuranceAmount(java.lang.String amount) throws java.lang.IllegalArgumentException
amount
-
java.lang.IllegalArgumentException
public void setInsuranceAmount(java.lang.String amount, boolean insuranceOption) throws java.lang.IllegalArgumentException
amount
- insuranceOption
- If true, the Insurance drop-down on the PayPal
Review page displays the string ‘Yes’ and the
insurance amount.
java.lang.IllegalArgumentException
public void setShippingDiscount(java.lang.String discount) throws java.lang.IllegalArgumentException
discount
-
java.lang.IllegalArgumentException
public void setHandlingAmount(java.lang.String amount) throws java.lang.IllegalArgumentException
amount
-
java.lang.IllegalArgumentException
public void setDescription(java.lang.String description) throws java.lang.IllegalArgumentException
description
-
java.lang.IllegalArgumentException
public void setCustomField(java.lang.String field) throws java.lang.IllegalArgumentException
field
-
java.lang.IllegalArgumentException
public void setInvoiceNumber(java.lang.String invoiceNumber) throws java.lang.IllegalArgumentException
invoiceNumber
-
java.lang.IllegalArgumentException
public void setButtonSource(java.lang.String source) throws java.lang.IllegalArgumentException
source
-
java.lang.IllegalArgumentException
public void setNotifyUrl(java.lang.String url) throws java.lang.IllegalArgumentException
DoExpressCheckoutPayment
. This value is ignored when set in
SetExpressCheckout
or GetExpressCheckoutDetails
. Character length and limitations: 2,048 single-byte alphanumeric
characters
url
-
java.lang.IllegalArgumentException
public void setNote(java.lang.String note) throws java.lang.IllegalArgumentException
note
-
java.lang.IllegalArgumentException
public void setTransactionId(java.lang.String transactionId)
transactionId
- public void setAllowedPaymentMethod(java.lang.String method)
InstantPaymentOnly.
method
- public java.util.Map<java.lang.String,java.lang.String> getNVPRequest()
RequestFields
getNVPRequest
in interface RequestFields
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |