paypalnvp.request
Class TransactionSearch

java.lang.Object
  extended by paypalnvp.request.TransactionSearch
All Implemented Interfaces:
java.io.Serializable, Request

public final class TransactionSearch
extends java.lang.Object
implements Request

Instance is used for TransactionSearch request. It searches transaction history for transactions that meet the specified criteria.

See Also:
Serialized Form

Nested Class Summary
static class TransactionSearch.TransactionStatus
          Transaction status.
static class TransactionSearch.TranscationClass
          Classification of transaction
 
Constructor Summary
TransactionSearch(java.util.Date startDate)
           
 
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
 java.util.Map<java.lang.String,java.lang.String> getNVPResponse()
          Return response from paypal.
 void setAmount(java.lang.String amount)
          Search by transaction amount.
 void setAuctionItemNumber(java.lang.String item)
          Search by auction item number of the purchased goods.
 void setCreditCardNumber(java.lang.String acct)
          Search by credit card number, as set by you for the original transaction.
 void setCurrency(Currency currency)
          Search by currency code.
 void setEmail(java.lang.String email)
          Search by the buyer's email address.
 void setEndDate(java.util.Date endDate)
           
 void setInvoiceId(java.lang.String id)
          Search by invoice identification key, as set by you for the original transaction.
 void setNVPResponse(java.util.Map<java.lang.String,java.lang.String> nvpResponse)
          Setter for nvp (name value pair) response
 void setPayerName(PayerName payerName)
          Set payer names fields
 void setReceiptId(java.lang.String id)
          Search by the PayPal Account Optional receipt ID.
 void setReceiverEmail(java.lang.String email)
          Search by the receiver's email address.
 void setStatus(TransactionSearch.TransactionStatus status)
          Search by transaction status
 void setTransaction(TransactionSearch.TranscationClass transactionClass)
          Search by classification of transaction.
 void setTransactionId(java.lang.String id)
          Search by the transaction ID.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TransactionSearch

public TransactionSearch(java.util.Date startDate)
                  throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException
Method Detail

setEndDate

public void setEndDate(java.util.Date endDate)
Parameters:
endDate - The latest transaction date to be included in the search

setEmail

public void setEmail(java.lang.String email)
              throws java.lang.IllegalArgumentException
Search by the buyer's email address. Email argument has to be valid email and less than 127 characters, otherwise exception is thrown.

Parameters:
email - maximum 127 single-byte alphanumeric characters.
Throws:
java.lang.IllegalArgumentException

setReceiverEmail

public void setReceiverEmail(java.lang.String email)
                      throws java.lang.IllegalArgumentException
Search by the receiver's email address. If the merchant account has only one email, this is the primary email. Can also be a non-primary email. Email has to be valid, otherwise exception is thrown.

Parameters:
email -
Throws:
java.lang.IllegalArgumentException

setReceiptId

public void setReceiptId(java.lang.String id)
Search by the PayPal Account Optional receipt ID.

Parameters:
id -

setTransactionId

public void setTransactionId(java.lang.String id)
                      throws java.lang.IllegalArgumentException
Search by the transaction ID. The returned results are from the merchant's transaction records. Character length and limitations: 19 single-byte characters maximum.

Parameters:
id -
Throws:
java.lang.IllegalArgumentException

setInvoiceId

public void setInvoiceId(java.lang.String id)
                  throws java.lang.IllegalArgumentException
Search by invoice identification key, as set by you for the original transaction. This field searches the records for items sold by the merchant, not the items purchased. Note: No wildcards are allowed. Character length and limitations: 127 single-byte characters maximum.

Parameters:
id -
Throws:
java.lang.IllegalArgumentException

setCreditCardNumber

public void setCreditCardNumber(java.lang.String acct)
                         throws java.lang.IllegalArgumentException
Search by credit card number, as set by you for the original transaction. This field searches the records for items sold by the merchant, not the items purchased. Note: No wildcards are allowed. Character length and limitations: Must be at least 11 and no more than 25 single-byte numeric characters maximum. Special punctuation, such as dashes or spaces, is ignored.

Parameters:
acct -
Throws:
java.lang.IllegalArgumentException

setAuctionItemNumber

public void setAuctionItemNumber(java.lang.String item)
Search by auction item number of the purchased goods.

Parameters:
item -

setTransaction

public void setTransaction(TransactionSearch.TranscationClass transactionClass)
Search by classification of transaction. Some kinds of possible classes of transactions are not searchable with this field. You cannot search for bank transfer withdrawals, for example.

Parameters:
transactionClass -

setAmount

public void setAmount(java.lang.String amount)
               throws java.lang.IllegalArgumentException
Search by transaction amount.

Parameters:
amount -
Throws:
java.lang.IllegalArgumentException

setCurrency

public void setCurrency(Currency currency)
Search by currency code.

Parameters:
currency -

setStatus

public void setStatus(TransactionSearch.TransactionStatus status)
Search by transaction status

Parameters:
status -

setPayerName

public void setPayerName(PayerName payerName)
Set payer names fields

Parameters:
payerName -

getNVPRequest

public java.util.Map<java.lang.String,java.lang.String> getNVPRequest()
Description copied from interface: Request
Creates and returns part of the nvp (name value pair) request containing request values

Specified by:
getNVPRequest in interface Request
Returns:
part of the nvp request as a Map

setNVPResponse

public void setNVPResponse(java.util.Map<java.lang.String,java.lang.String> nvpResponse)
Description copied from interface: Request
Setter for nvp (name value pair) response

Specified by:
setNVPResponse in interface Request

getNVPResponse

public java.util.Map<java.lang.String,java.lang.String> getNVPResponse()
Description copied from interface: Request
Return response from paypal. If response is not set/received returns empty Map.

Specified by:
getNVPResponse in interface Request
Returns:
response from paypal as a Map

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object