2007

Table Of Contents
Name-Value Pair API Developer Guide and Reference April 2007 107
The Java SDK
Sample Applications
Sample Applications
The PayPal SDK includes sample applications in the SDK_root/samples directory. Each
subdirectory comes with a README file that explains how to set up the application.
EWPProfile interface This interface defines the basic information that PayPal needs to
know about a user of PayPal’s Encrypted Website Payments (EWP)
service. Developers must create an instance of EWPProfile for each
account that generates the encrypted button code; for single-merchant
users this will just be a single instance). PayPal provides a basic
implementation class called DefaultEWPProfile suitable for the needs
of most SDK developers. However, you are free to write a custom
implementation if you need functionality the default class does not
offer.
ProfileFactory class This class creates both APIProfile and EWPProfile objects. It
contains static methods that handle the instantiation and construction
of profile objects.
Profiles class This data class represents all profiles the SDK knows about. It
contains two collections, one for APIProfiles and one for
EWPProfiles. This class is provided to ProfileHandler to save profile
data and returned from ProfileHandler to retrieve profile data.
T
ABLE D.6 PayPal SDK for Java: Sample Code in SDK_root/samples
Subdirectory Descrption
Cert API certificates used by the sample applications
JSP JavaScript implementation for Apache Tomcat of the
following PayPal APIs:
z Express Checkout for final sale and for authorization
z TransactionSearch
z GetTransactionDetails
z RefundTransaction
SampleApp Native Java application to call TransactionSearch, and
GetTransactionDetails
T
ABLE D.5 Interface and Classes for SDK Profiles (Continued)
Interface/Class Descriptions