Class BillTo
Billing address is Cardholder's address information.
Following example shows how to use BillTo.
................. // inv is the Invoice object. ................. *// Set the Billing Address details. BillTo bill = new BillTo(); bill.setBillToStreet( "123 Main St."); bill.setBillToZip("12345"); inv.setBillTo (bill); .................
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()This method copies the common contents from billing to shipping address.protected voidGets the cityGets the Company Name.Gets the Billing Country.Gets the Billing Email.Gets the Billing FaxGets the first name.Gets the Billing HomePhone.Gets the last name.Gets the middle name.Gets the billing phone number.Gets the Billing Phone2.Gets the StateGets the Billing Street.Gets the Billing Street2.Gets the Billing Zip.protected Contextprotected StringBufferGets the Requestbuffer used for creating the actual request string.voidsetBillToCity(String billToCity) Sets the cityvoidsetBillToCompanyName(String billToCompanyName) Sets the Company Name.voidsetBillToCountry(String billToCountry) Sets the Billing Country.voidsetBillToEmail(String billToEmail) Sets the Billing Email.voidsetBillToFax(String billToFax) Sets the Billing FaxvoidsetBillToFirstName(String billToFirstName) Sets the first name.voidsetBillToHomePhone(String billToHomePhone) Sets the Billing HomePhone.voidsetBillToLastName(String billToLastName) Sets the last name.voidsetBillToMiddleName(String billToMiddleName) Sets the middle name.voidsetBillToPhone(String billToPhone) Sets the billing phone number.voidsetBillToPhone2(String billToPhone2) Sets the Billing Phone2.voidsetBillToState(String billToState) Sets the StatevoidsetBillToStreet(String billToStreet) Sets the Billing Street.voidsetBillToStreet2(String billToStreet2) Sets the Billing Street.voidsetBillToZip(String billToZip) Sets the Billing Zip.protected voidsetContext(Context context) protected voidsetRequestBuffer(StringBuffer value) sets the StringBuffer to hold the request string.Methods inherited from class paypal.payflow.Address
getAddressCity, getAddressCountry, getAddressEmail, getAddressFax, getAddressFirstName, getAddressLastName, getAddressMiddleName, getAddressPhone, getAddressPhone2, getAddressState, getAddressStreet, getAddressStreet2, getAddressZip, setAddressCity, setAddressCountry, setAddressEmail, setAddressFax, setAddressFirstName, setAddressLastName, setAddressMiddleName, setAddressPhone, setAddressPhone2, setAddressState, setAddressStreet, setAddressStreet2, setAddressZip
-
Constructor Details
-
BillTo
public BillTo()Constructor.Billing address is Cardholder's address information.
-
-
Method Details
-
getBillToStreet
Gets the Billing Street.Cardholder's billing street address (used for AVS and reporting).
- Returns:
- String
Maps to Payflow Parameter: BILLTOSTREET
-
setBillToStreet
Sets the Billing Street.Cardholder's billing street address (used for AVS and reporting).
- Parameters:
billToStreet- StringMaps to Payflow Parameter: BILLTOSTREET
-
getBillToStreet2
Gets the Billing Street2.Cardholder's billing 2nd line street address.
- Returns:
- String
Maps to Payflow Parameter: BILLTOSTREET2
-
setBillToStreet2
Sets the Billing Street.Cardholder's billing 2nd line street address.
- Parameters:
billToStreet2- StringMaps to Payflow Parameter: BILLTOSTREET2
-
getBillToCity
Gets the cityCardholder's billing city.
- Returns:
- String
Maps to Payflow Parameter: BILLTOCITY
-
setBillToCity
Sets the cityCardholder's billing city.
- Parameters:
billToCity- StringMaps to Payflow Parameter: BILLTOCITY
-
getBillToState
Gets the StateCardholder's billing state code.
- Returns:
- String
Maps to Payflow Parameter: BILLTOSTATE
-
setBillToState
Sets the StateCardholder's billing state code.
- Parameters:
billToState- StringMaps to Payflow Parameter: BILLTOSTATE
-
getBillToZip
Gets the Billing Zip.Account holder's 5- to 9-digit postal code (called ZIP code in the USA). Do not use spaces, dashes, or non-numeric characters. The postal code is verified by the AVS service.
- Returns:
- String
Maps to Payflow Parameter: BILLTOZIP
-
setBillToZip
Sets the Billing Zip.UAccount holder's 5- to 9-digit postal code (called ZIP code in the USA). Do not use spaces, dashes, or non-numeric characters. The postal code is verified by the AVS service.
- Parameters:
billToZip- StringMaps to Payflow Parameter: BILLTOZIP
-
getBillToFirstName
Gets the first name.Cardholder's first name.
- Returns:
- firstName String
Maps to Payflow Parameter: BILLTOFIRSTNAME
-
setBillToFirstName
Sets the first name.Cardholder's first name.
- Parameters:
billToFirstName- StringMaps to Payflow Parameter: BILLTOFIRSTNAME
-
getBillToMiddleName
Gets the middle name.Cardholder's middle name.
- Returns:
- billToMiddleName String
Maps to Payflow Parameter: BILLTOMIDDLENAME
-
setBillToMiddleName
Sets the middle name.Cardholder's middle name.
- Parameters:
billToMiddleName- StringMaps to Payflow Parameter: BILLTOMIDDLENAME
-
getBillToLastName
Gets the last name.Cardholder's last name.
- Returns:
- BillToLastName String
Maps to Payflow Parameter: BILLTOLASTNAME
-
setBillToLastName
Sets the last name.Cardholder's last name.
- Parameters:
billToLastName- StringMaps to Payflow Parameter: BILLTOLASTNAME
-
getBillToPhone
Gets the billing phone number.Cardholder's telephone number.
- Returns:
- billToPhone String
Maps to Payflow Parameter: PHONENUM
-
setBillToPhone
Sets the billing phone number.Cardholder's telephone number.
- Parameters:
billToPhone- StringMaps to Payflow Parameter: PHONENUM
-
getBillToPhone2
Gets the Billing Phone2.Cardholder's 2nd telephone number.
- Returns:
- billToPhone2 String
Maps to Payflow Parameter: BILLTOPHONE2
-
setBillToPhone2
Sets the Billing Phone2.Cardholder's 2nd telephone number.
- Parameters:
billToPhone2- StringMaps to Payflow Parameter: BILLTOPHONE2
-
getBillToFax
Gets the Billing FaxCardholder's fax address.
- Returns:
- fax String
Maps to Payflow Parameter: BILLTOFAX
-
setBillToFax
Sets the Billing FaxCardholder's fax address.
- Parameters:
billToFax- StringMaps to Payflow Parameter: BILLTOFAX
-
getBillToEmail
Gets the Billing Email.Cardholder's e-mail address
- Returns:
- email String
Maps to Payflow Parameter: BILLTOEMAIL
-
setBillToEmail
Sets the Billing Email.Cardholder's e-mail address
- Parameters:
billToEmail- StringMaps to Payflow Parameter: BILLTOEMAIL
-
getBillToCountry
Gets the Billing Country.Cardholder's billing country code
- Returns:
- billToCountry String
Maps to Payflow Parameter: BILLTOCOUNTRY
-
setBillToCountry
Sets the Billing Country.Cardholder's billing country code
- Parameters:
billToCountry- StringMaps to Payflow Parameter: BILLTOCOUNTRY
-
getBillToHomePhone
Gets the Billing HomePhone.Cardholder's home telephone number.
- Returns:
- homePhone String
Maps to Payflow Parameter: HOMEPHONE
-
setBillToHomePhone
Sets the Billing HomePhone.Cardholder's home telephone number.
- Parameters:
billToHomePhone- StringMaps to Payflow Parameter: HOMEPHONE
-
getBillToCompanyName
Gets the Company Name.- Returns:
- String
Maps to Payflow Parameter: COMPANYNAME
-
setBillToCompanyName
Sets the Company Name.- Parameters:
billToCompanyName- StringMaps to Payflow Parameter: COMPANYNAME
-
copy
This method copies the common contents from billing to shipping address.This method can be used to populate the shipping addresses directly from the billing addresses when both are the same.
- Returns:
- shipTo ShipTo
................
//bill is the object of
//billTo populated with
//the billing addresses.
................
*
ShipTo ship; *
//Populate shipping addresses //from billing addresses. ship = bill.copy(); *
................
-
generateRequest
protected void generateRequest() -
getContext
-
setContext
-
getRequestBuffer
Gets the Requestbuffer used for creating the actual request string.- Returns:
- mRequestBuffer StringBuffer
-
setRequestBuffer
sets the StringBuffer to hold the request string.- Parameters:
value- StringBuffer
-