updating stubs to have fluent setters and retaining deprecated methods

This commit is contained in:
Ganesh Hegde
2013-05-28 10:15:29 +05:30
parent 50b09bdbde
commit 86643ec2df
26 changed files with 1388 additions and 404 deletions

View File

@@ -9,6 +9,7 @@ class Address extends \PPModel {
*/ */
public function setLine1($line1) { public function setLine1($line1) {
$this->line1 = $line1; $this->line1 = $line1;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Address extends \PPModel {
return $this->line1; return $this->line1;
} }
/** /**
* Optional line 2 of the Address (eg. suite, apt #, etc.). * Optional line 2 of the Address (eg. suite, apt #, etc.).
* @param string $line2 * @param string $line2
*/ */
public function setLine2($line2) { public function setLine2($line2) {
$this->line2 = $line2; $this->line2 = $line2;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class Address extends \PPModel {
return $this->line2; return $this->line2;
} }
/** /**
* City name. * City name.
* @param string $city * @param string $city
*/ */
public function setCity($city) { public function setCity($city) {
$this->city = $city; $this->city = $city;
return $this;
} }
/** /**
@@ -51,12 +56,14 @@ class Address extends \PPModel {
return $this->city; return $this->city;
} }
/** /**
* 2 letter country code. * 2 letter country code.
* @param string $country_code * @param string $country_code
*/ */
public function setCountryCode($country_code) { public function setCountryCode($country_code) {
$this->country_code = $country_code; $this->country_code = $country_code;
return $this;
} }
/** /**
@@ -67,12 +74,27 @@ class Address extends \PPModel {
return $this->country_code; return $this->country_code;
} }
/**
* Deprecated method
*/
public function setCountry_code($country_code) {
$this->country_code = $country_code;
return $this;
}
/**
* Deprecated method
*/
public function getCountry_code() {
return $this->country_code;
}
/** /**
* Zip code or equivalent is usually required for countries that have them. For list of countries that do not have postal codes please refer to http://en.wikipedia.org/wiki/Postal_code. * Zip code or equivalent is usually required for countries that have them. For list of countries that do not have postal codes please refer to http://en.wikipedia.org/wiki/Postal_code.
* @param string $postal_code * @param string $postal_code
*/ */
public function setPostalCode($postal_code) { public function setPostalCode($postal_code) {
$this->postal_code = $postal_code; $this->postal_code = $postal_code;
return $this;
} }
/** /**
@@ -83,12 +105,27 @@ class Address extends \PPModel {
return $this->postal_code; return $this->postal_code;
} }
/**
* Deprecated method
*/
public function setPostal_code($postal_code) {
$this->postal_code = $postal_code;
return $this;
}
/**
* Deprecated method
*/
public function getPostal_code() {
return $this->postal_code;
}
/** /**
* 2 letter code for US states, and the equivalent for other countries. * 2 letter code for US states, and the equivalent for other countries.
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -99,12 +136,14 @@ class Address extends \PPModel {
return $this->state; return $this->state;
} }
/** /**
* Phone number in E.123 format. * Phone number in E.123 format.
* @param string $phone * @param string $phone
*/ */
public function setPhone($phone) { public function setPhone($phone) {
$this->phone = $phone; $this->phone = $phone;
return $this;
} }
/** /**
@@ -115,4 +154,5 @@ class Address extends \PPModel {
return $this->phone; return $this->phone;
} }
} }

View File

@@ -9,6 +9,7 @@ class Amount extends \PPModel {
*/ */
public function setCurrency($currency) { public function setCurrency($currency) {
$this->currency = $currency; $this->currency = $currency;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Amount extends \PPModel {
return $this->currency; return $this->currency;
} }
/** /**
* Total amount charged from the Payer account (or card) to Payee. In case of a refund, this is the refunded amount to the original Payer from Payee account. * Total amount charged from the Payer account (or card) to Payee. In case of a refund, this is the refunded amount to the original Payer from Payee account.
* @param string $total * @param string $total
*/ */
public function setTotal($total) { public function setTotal($total) {
$this->total = $total; $this->total = $total;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class Amount extends \PPModel {
return $this->total; return $this->total;
} }
/** /**
* Additional details of the payment amount. * Additional details of the payment amount.
* @param PayPal\Api\Details $details * @param PayPal\Api\Details $details
*/ */
public function setDetails($details) { public function setDetails($details) {
$this->details = $details; $this->details = $details;
return $this;
} }
/** /**
@@ -51,4 +56,5 @@ class Amount extends \PPModel {
return $this->details; return $this->details;
} }
} }

View File

@@ -23,6 +23,7 @@ class Authorization extends \PPModel implements IResource {
*/ */
public function setId($id) { public function setId($id) {
$this->id = $id; $this->id = $id;
return $this;
} }
/** /**
@@ -33,12 +34,14 @@ class Authorization extends \PPModel implements IResource {
return $this->id; return $this->id;
} }
/** /**
* Time the resource was created. * Time the resource was created.
* @param string $create_time * @param string $create_time
*/ */
public function setCreateTime($create_time) { public function setCreateTime($create_time) {
$this->create_time = $create_time; $this->create_time = $create_time;
return $this;
} }
/** /**
@@ -49,12 +52,27 @@ class Authorization extends \PPModel implements IResource {
return $this->create_time; return $this->create_time;
} }
/**
* Deprecated method
*/
public function setCreate_time($create_time) {
$this->create_time = $create_time;
return $this;
}
/**
* Deprecated method
*/
public function getCreate_time() {
return $this->create_time;
}
/** /**
* Time the resource was last updated. * Time the resource was last updated.
* @param string $update_time * @param string $update_time
*/ */
public function setUpdateTime($update_time) { public function setUpdateTime($update_time) {
$this->update_time = $update_time; $this->update_time = $update_time;
return $this;
} }
/** /**
@@ -65,12 +83,27 @@ class Authorization extends \PPModel implements IResource {
return $this->update_time; return $this->update_time;
} }
/**
* Deprecated method
*/
public function setUpdate_time($update_time) {
$this->update_time = $update_time;
return $this;
}
/**
* Deprecated method
*/
public function getUpdate_time() {
return $this->update_time;
}
/** /**
* Amount being authorized for. * Amount being authorized for.
* @param PayPal\Api\Amount $amount * @param PayPal\Api\Amount $amount
*/ */
public function setAmount($amount) { public function setAmount($amount) {
$this->amount = $amount; $this->amount = $amount;
return $this;
} }
/** /**
@@ -81,12 +114,14 @@ class Authorization extends \PPModel implements IResource {
return $this->amount; return $this->amount;
} }
/** /**
* State of the authorization transaction. * State of the authorization transaction.
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -97,12 +132,14 @@ class Authorization extends \PPModel implements IResource {
return $this->state; return $this->state;
} }
/** /**
* ID of the Payment resource that this transaction is based on. * ID of the Payment resource that this transaction is based on.
* @param string $parent_payment * @param string $parent_payment
*/ */
public function setParentPayment($parent_payment) { public function setParentPayment($parent_payment) {
$this->parent_payment = $parent_payment; $this->parent_payment = $parent_payment;
return $this;
} }
/** /**
@@ -113,12 +150,27 @@ class Authorization extends \PPModel implements IResource {
return $this->parent_payment; return $this->parent_payment;
} }
/**
* Deprecated method
*/
public function setParent_payment($parent_payment) {
$this->parent_payment = $parent_payment;
return $this;
}
/**
* Deprecated method
*/
public function getParent_payment() {
return $this->parent_payment;
}
/** /**
* Date/Time until which funds may be captured against this resource. * Date/Time until which funds may be captured against this resource.
* @param string $valid_until * @param string $valid_until
*/ */
public function setValidUntil($valid_until) { public function setValidUntil($valid_until) {
$this->valid_until = $valid_until; $this->valid_until = $valid_until;
return $this;
} }
/** /**
@@ -129,6 +181,20 @@ class Authorization extends \PPModel implements IResource {
return $this->valid_until; return $this->valid_until;
} }
/**
* Deprecated method
*/
public function setValid_until($valid_until) {
$this->valid_until = $valid_until;
return $this;
}
/**
* Deprecated method
*/
public function getValid_until() {
return $this->valid_until;
}
/** /**
* *
* @array * @array
@@ -136,6 +202,7 @@ class Authorization extends \PPModel implements IResource {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -147,6 +214,7 @@ class Authorization extends \PPModel implements IResource {
} }
public static function get($authorizationId, $apiContext = null) { public static function get($authorizationId, $apiContext = null) {
if (($authorizationId == null) || (strlen($authorizationId) <= 0)) { if (($authorizationId == null) || (strlen($authorizationId) <= 0)) {
throw new \InvalidArgumentException("authorizationId cannot be null or empty"); throw new \InvalidArgumentException("authorizationId cannot be null or empty");

View File

@@ -23,6 +23,7 @@ class Capture extends \PPModel implements IResource {
*/ */
public function setId($id) { public function setId($id) {
$this->id = $id; $this->id = $id;
return $this;
} }
/** /**
@@ -33,12 +34,14 @@ class Capture extends \PPModel implements IResource {
return $this->id; return $this->id;
} }
/** /**
* Time the resource was created. * Time the resource was created.
* @param string $create_time * @param string $create_time
*/ */
public function setCreateTime($create_time) { public function setCreateTime($create_time) {
$this->create_time = $create_time; $this->create_time = $create_time;
return $this;
} }
/** /**
@@ -49,12 +52,27 @@ class Capture extends \PPModel implements IResource {
return $this->create_time; return $this->create_time;
} }
/**
* Deprecated method
*/
public function setCreate_time($create_time) {
$this->create_time = $create_time;
return $this;
}
/**
* Deprecated method
*/
public function getCreate_time() {
return $this->create_time;
}
/** /**
* Time the resource was last updated. * Time the resource was last updated.
* @param string $update_time * @param string $update_time
*/ */
public function setUpdateTime($update_time) { public function setUpdateTime($update_time) {
$this->update_time = $update_time; $this->update_time = $update_time;
return $this;
} }
/** /**
@@ -65,12 +83,27 @@ class Capture extends \PPModel implements IResource {
return $this->update_time; return $this->update_time;
} }
/**
* Deprecated method
*/
public function setUpdate_time($update_time) {
$this->update_time = $update_time;
return $this;
}
/**
* Deprecated method
*/
public function getUpdate_time() {
return $this->update_time;
}
/** /**
* Amount being captured. If no amount is specified, amount is used from the authorization being captured. If amount is same as the amount that's authorized for, the state of the authorization changes to captured. If not, the state of the authorization changes to partially_captured. Alternatively, you could indicate a final capture by seting the is_final_capture flag to true. * Amount being captured. If no amount is specified, amount is used from the authorization being captured. If amount is same as the amount that's authorized for, the state of the authorization changes to captured. If not, the state of the authorization changes to partially_captured. Alternatively, you could indicate a final capture by seting the is_final_capture flag to true.
* @param PayPal\Api\Amount $amount * @param PayPal\Api\Amount $amount
*/ */
public function setAmount($amount) { public function setAmount($amount) {
$this->amount = $amount; $this->amount = $amount;
return $this;
} }
/** /**
@@ -81,12 +114,14 @@ class Capture extends \PPModel implements IResource {
return $this->amount; return $this->amount;
} }
/** /**
* whether this is a final capture for the given authorization or not. If it's final, all the remaining funds held by the authorization, will be released in the funding instrument. * whether this is a final capture for the given authorization or not. If it's final, all the remaining funds held by the authorization, will be released in the funding instrument.
* @param boolean $is_final_capture * @param boolean $is_final_capture
*/ */
public function setIsFinalCapture($is_final_capture) { public function setIsFinalCapture($is_final_capture) {
$this->is_final_capture = $is_final_capture; $this->is_final_capture = $is_final_capture;
return $this;
} }
/** /**
@@ -97,12 +132,27 @@ class Capture extends \PPModel implements IResource {
return $this->is_final_capture; return $this->is_final_capture;
} }
/**
* Deprecated method
*/
public function setIs_final_capture($is_final_capture) {
$this->is_final_capture = $is_final_capture;
return $this;
}
/**
* Deprecated method
*/
public function getIs_final_capture() {
return $this->is_final_capture;
}
/** /**
* State of the capture transaction. * State of the capture transaction.
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -113,12 +163,14 @@ class Capture extends \PPModel implements IResource {
return $this->state; return $this->state;
} }
/** /**
* ID of the Payment resource that this transaction is based on. * ID of the Payment resource that this transaction is based on.
* @param string $parent_payment * @param string $parent_payment
*/ */
public function setParentPayment($parent_payment) { public function setParentPayment($parent_payment) {
$this->parent_payment = $parent_payment; $this->parent_payment = $parent_payment;
return $this;
} }
/** /**
@@ -129,6 +181,20 @@ class Capture extends \PPModel implements IResource {
return $this->parent_payment; return $this->parent_payment;
} }
/**
* Deprecated method
*/
public function setParent_payment($parent_payment) {
$this->parent_payment = $parent_payment;
return $this;
}
/**
* Deprecated method
*/
public function getParent_payment() {
return $this->parent_payment;
}
/** /**
* *
* @array * @array
@@ -136,6 +202,7 @@ class Capture extends \PPModel implements IResource {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -147,6 +214,7 @@ class Capture extends \PPModel implements IResource {
} }
public static function get($captureId, $apiContext = null) { public static function get($captureId, $apiContext = null) {
if (($captureId == null) || (strlen($captureId) <= 0)) { if (($captureId == null) || (strlen($captureId) <= 0)) {
throw new \InvalidArgumentException("captureId cannot be null or empty"); throw new \InvalidArgumentException("captureId cannot be null or empty");

View File

@@ -23,6 +23,7 @@ class CreditCard extends \PPModel implements IResource {
*/ */
public function setId($id) { public function setId($id) {
$this->id = $id; $this->id = $id;
return $this;
} }
/** /**
@@ -33,12 +34,14 @@ class CreditCard extends \PPModel implements IResource {
return $this->id; return $this->id;
} }
/** /**
* Card number. * Card number.
* @param string $number * @param string $number
*/ */
public function setNumber($number) { public function setNumber($number) {
$this->number = $number; $this->number = $number;
return $this;
} }
/** /**
@@ -49,12 +52,14 @@ class CreditCard extends \PPModel implements IResource {
return $this->number; return $this->number;
} }
/** /**
* Type of the Card (eg. Visa, Mastercard, etc.). * Type of the Card (eg. Visa, Mastercard, etc.).
* @param string $type * @param string $type
*/ */
public function setType($type) { public function setType($type) {
$this->type = $type; $this->type = $type;
return $this;
} }
/** /**
@@ -65,12 +70,14 @@ class CreditCard extends \PPModel implements IResource {
return $this->type; return $this->type;
} }
/** /**
* card expiry month with value 1 - 12. * card expiry month with value 1 - 12.
* @param integer $expire_month * @param integer $expire_month
*/ */
public function setExpireMonth($expire_month) { public function setExpireMonth($expire_month) {
$this->expire_month = $expire_month; $this->expire_month = $expire_month;
return $this;
} }
/** /**
@@ -81,12 +88,27 @@ class CreditCard extends \PPModel implements IResource {
return $this->expire_month; return $this->expire_month;
} }
/**
* Deprecated method
*/
public function setExpire_month($expire_month) {
$this->expire_month = $expire_month;
return $this;
}
/**
* Deprecated method
*/
public function getExpire_month() {
return $this->expire_month;
}
/** /**
* 4 digit card expiry year * 4 digit card expiry year
* @param integer $expire_year * @param integer $expire_year
*/ */
public function setExpireYear($expire_year) { public function setExpireYear($expire_year) {
$this->expire_year = $expire_year; $this->expire_year = $expire_year;
return $this;
} }
/** /**
@@ -97,12 +119,27 @@ class CreditCard extends \PPModel implements IResource {
return $this->expire_year; return $this->expire_year;
} }
/**
* Deprecated method
*/
public function setExpire_year($expire_year) {
$this->expire_year = $expire_year;
return $this;
}
/**
* Deprecated method
*/
public function getExpire_year() {
return $this->expire_year;
}
/** /**
* Card validation code. Only supported when making a Payment but not when saving a credit card for future use. * Card validation code. Only supported when making a Payment but not when saving a credit card for future use.
* @param string $cvv2 * @param string $cvv2
*/ */
public function setCvv2($cvv2) { public function setCvv2($cvv2) {
$this->cvv2 = $cvv2; $this->cvv2 = $cvv2;
return $this;
} }
/** /**
@@ -113,12 +150,14 @@ class CreditCard extends \PPModel implements IResource {
return $this->cvv2; return $this->cvv2;
} }
/** /**
* Card holder's first name. * Card holder's first name.
* @param string $first_name * @param string $first_name
*/ */
public function setFirstName($first_name) { public function setFirstName($first_name) {
$this->first_name = $first_name; $this->first_name = $first_name;
return $this;
} }
/** /**
@@ -129,12 +168,27 @@ class CreditCard extends \PPModel implements IResource {
return $this->first_name; return $this->first_name;
} }
/**
* Deprecated method
*/
public function setFirst_name($first_name) {
$this->first_name = $first_name;
return $this;
}
/**
* Deprecated method
*/
public function getFirst_name() {
return $this->first_name;
}
/** /**
* Card holder's last name. * Card holder's last name.
* @param string $last_name * @param string $last_name
*/ */
public function setLastName($last_name) { public function setLastName($last_name) {
$this->last_name = $last_name; $this->last_name = $last_name;
return $this;
} }
/** /**
@@ -145,12 +199,27 @@ class CreditCard extends \PPModel implements IResource {
return $this->last_name; return $this->last_name;
} }
/**
* Deprecated method
*/
public function setLast_name($last_name) {
$this->last_name = $last_name;
return $this;
}
/**
* Deprecated method
*/
public function getLast_name() {
return $this->last_name;
}
/** /**
* Billing Address associated with this card. * Billing Address associated with this card.
* @param PayPal\Api\Address $billing_address * @param PayPal\Api\Address $billing_address
*/ */
public function setBillingAddress($billing_address) { public function setBillingAddress($billing_address) {
$this->billing_address = $billing_address; $this->billing_address = $billing_address;
return $this;
} }
/** /**
@@ -161,12 +230,27 @@ class CreditCard extends \PPModel implements IResource {
return $this->billing_address; return $this->billing_address;
} }
/**
* Deprecated method
*/
public function setBilling_address($billing_address) {
$this->billing_address = $billing_address;
return $this;
}
/**
* Deprecated method
*/
public function getBilling_address() {
return $this->billing_address;
}
/** /**
* A unique identifier of the payer generated and provided by the facilitator. This is required when creating or using a tokenized funding instrument. * A unique identifier of the payer generated and provided by the facilitator. This is required when creating or using a tokenized funding instrument.
* @param string $payer_id * @param string $payer_id
*/ */
public function setPayerId($payer_id) { public function setPayerId($payer_id) {
$this->payer_id = $payer_id; $this->payer_id = $payer_id;
return $this;
} }
/** /**
@@ -177,12 +261,27 @@ class CreditCard extends \PPModel implements IResource {
return $this->payer_id; return $this->payer_id;
} }
/**
* Deprecated method
*/
public function setPayer_id($payer_id) {
$this->payer_id = $payer_id;
return $this;
}
/**
* Deprecated method
*/
public function getPayer_id() {
return $this->payer_id;
}
/** /**
* State of the funding instrument. * State of the funding instrument.
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -193,12 +292,14 @@ class CreditCard extends \PPModel implements IResource {
return $this->state; return $this->state;
} }
/** /**
* Date/Time until this resource can be used fund a payment. * Date/Time until this resource can be used fund a payment.
* @param string $valid_until * @param string $valid_until
*/ */
public function setValidUntil($valid_until) { public function setValidUntil($valid_until) {
$this->valid_until = $valid_until; $this->valid_until = $valid_until;
return $this;
} }
/** /**
@@ -209,6 +310,20 @@ class CreditCard extends \PPModel implements IResource {
return $this->valid_until; return $this->valid_until;
} }
/**
* Deprecated method
*/
public function setValid_until($valid_until) {
$this->valid_until = $valid_until;
return $this;
}
/**
* Deprecated method
*/
public function getValid_until() {
return $this->valid_until;
}
/** /**
* *
* @array * @array
@@ -216,6 +331,7 @@ class CreditCard extends \PPModel implements IResource {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -227,6 +343,7 @@ class CreditCard extends \PPModel implements IResource {
} }
public function create($apiContext = null) { public function create($apiContext = null) {
$payLoad = $this->toJSON(); $payLoad = $this->toJSON();
if ($apiContext == null) { if ($apiContext == null) {

View File

@@ -8,8 +8,9 @@ class CreditCardHistory extends \PPModel {
* @array * @array
* @param PayPal\Api\CreditCard $credit-cards * @param PayPal\Api\CreditCard $credit-cards
*/ */
public function setCreditCards($credit-cards) { public function setCreditCards($credit_cards) {
$this->credit-cards = $credit-cards; $this->credit_cards = $credit_cards;
return $this;
} }
/** /**
@@ -20,12 +21,27 @@ class CreditCardHistory extends \PPModel {
return $this->credit-cards; return $this->credit-cards;
} }
/**
* Deprecated method
*/
public function setCredit_cards($credit_cards) {
$this->credit_cards = $credit_cards;
return $this;
}
/**
* Deprecated method
*/
public function getCredit_cards() {
return $this->credit-cards;
}
/** /**
* Number of items returned in each range of results. Note that the last results range could have fewer items than the requested number of items. * Number of items returned in each range of results. Note that the last results range could have fewer items than the requested number of items.
* @param integer $count * @param integer $count
*/ */
public function setCount($count) { public function setCount($count) {
$this->count = $count; $this->count = $count;
return $this;
} }
/** /**
@@ -36,12 +52,14 @@ class CreditCardHistory extends \PPModel {
return $this->count; return $this->count;
} }
/** /**
* Identifier of the next element to get the next range of results. * Identifier of the next element to get the next range of results.
* @param string $next_id * @param string $next_id
*/ */
public function setNextId($next_id) { public function setNextId($next_id) {
$this->next_id = $next_id; $this->next_id = $next_id;
return $this;
} }
/** /**
@@ -52,4 +70,18 @@ class CreditCardHistory extends \PPModel {
return $this->next_id; return $this->next_id;
} }
/**
* Deprecated method
*/
public function setNext_id($next_id) {
$this->next_id = $next_id;
return $this;
}
/**
* Deprecated method
*/
public function getNext_id() {
return $this->next_id;
}
} }

View File

@@ -9,6 +9,7 @@ class CreditCardToken extends \PPModel {
*/ */
public function setCreditCardId($credit_card_id) { public function setCreditCardId($credit_card_id) {
$this->credit_card_id = $credit_card_id; $this->credit_card_id = $credit_card_id;
return $this;
} }
/** /**
@@ -19,12 +20,27 @@ class CreditCardToken extends \PPModel {
return $this->credit_card_id; return $this->credit_card_id;
} }
/**
* Deprecated method
*/
public function setCredit_card_id($credit_card_id) {
$this->credit_card_id = $credit_card_id;
return $this;
}
/**
* Deprecated method
*/
public function getCredit_card_id() {
return $this->credit_card_id;
}
/** /**
* The unique identifier of the payer used when saving this credit card using /vault/credit-card API. * The unique identifier of the payer used when saving this credit card using /vault/credit-card API.
* @param string $payer_id * @param string $payer_id
*/ */
public function setPayerId($payer_id) { public function setPayerId($payer_id) {
$this->payer_id = $payer_id; $this->payer_id = $payer_id;
return $this;
} }
/** /**
@@ -35,12 +51,27 @@ class CreditCardToken extends \PPModel {
return $this->payer_id; return $this->payer_id;
} }
/**
* Deprecated method
*/
public function setPayer_id($payer_id) {
$this->payer_id = $payer_id;
return $this;
}
/**
* Deprecated method
*/
public function getPayer_id() {
return $this->payer_id;
}
/** /**
* Last 4 digits of the card number from the saved card. * Last 4 digits of the card number from the saved card.
* @param string $last4 * @param string $last4
*/ */
public function setLast4($last4) { public function setLast4($last4) {
$this->last4 = $last4; $this->last4 = $last4;
return $this;
} }
/** /**
@@ -51,12 +82,14 @@ class CreditCardToken extends \PPModel {
return $this->last4; return $this->last4;
} }
/** /**
* Type of the Card (eg. visa, mastercard, etc.) from the saved card. Please note that the values are always in lowercase and not meant to be used directly for display. * Type of the Card (eg. visa, mastercard, etc.) from the saved card. Please note that the values are always in lowercase and not meant to be used directly for display.
* @param string $type * @param string $type
*/ */
public function setType($type) { public function setType($type) {
$this->type = $type; $this->type = $type;
return $this;
} }
/** /**
@@ -67,12 +100,14 @@ class CreditCardToken extends \PPModel {
return $this->type; return $this->type;
} }
/** /**
* card expiry month from the saved card with value 1 - 12 * card expiry month from the saved card with value 1 - 12
* @param integer $expire_month * @param integer $expire_month
*/ */
public function setExpireMonth($expire_month) { public function setExpireMonth($expire_month) {
$this->expire_month = $expire_month; $this->expire_month = $expire_month;
return $this;
} }
/** /**
@@ -83,12 +118,27 @@ class CreditCardToken extends \PPModel {
return $this->expire_month; return $this->expire_month;
} }
/**
* Deprecated method
*/
public function setExpire_month($expire_month) {
$this->expire_month = $expire_month;
return $this;
}
/**
* Deprecated method
*/
public function getExpire_month() {
return $this->expire_month;
}
/** /**
* 4 digit card expiry year from the saved card * 4 digit card expiry year from the saved card
* @param integer $expire_year * @param integer $expire_year
*/ */
public function setExpireYear($expire_year) { public function setExpireYear($expire_year) {
$this->expire_year = $expire_year; $this->expire_year = $expire_year;
return $this;
} }
/** /**
@@ -99,4 +149,18 @@ class CreditCardToken extends \PPModel {
return $this->expire_year; return $this->expire_year;
} }
/**
* Deprecated method
*/
public function setExpire_year($expire_year) {
$this->expire_year = $expire_year;
return $this;
}
/**
* Deprecated method
*/
public function getExpire_year() {
return $this->expire_year;
}
} }

View File

@@ -9,6 +9,7 @@ class Details extends \PPModel {
*/ */
public function setShipping($shipping) { public function setShipping($shipping) {
$this->shipping = $shipping; $this->shipping = $shipping;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Details extends \PPModel {
return $this->shipping; return $this->shipping;
} }
/** /**
* Sub-total (amount) of items being paid for. * Sub-total (amount) of items being paid for.
* @param string $subtotal * @param string $subtotal
*/ */
public function setSubtotal($subtotal) { public function setSubtotal($subtotal) {
$this->subtotal = $subtotal; $this->subtotal = $subtotal;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class Details extends \PPModel {
return $this->subtotal; return $this->subtotal;
} }
/** /**
* Amount being charged as tax. * Amount being charged as tax.
* @param string $tax * @param string $tax
*/ */
public function setTax($tax) { public function setTax($tax) {
$this->tax = $tax; $this->tax = $tax;
return $this;
} }
/** /**
@@ -51,12 +56,14 @@ class Details extends \PPModel {
return $this->tax; return $this->tax;
} }
/** /**
* Fee charged by PayPal. In case of a refund, this is the fee amount refunded to the original receipient of the payment. * Fee charged by PayPal. In case of a refund, this is the fee amount refunded to the original receipient of the payment.
* @param string $fee * @param string $fee
*/ */
public function setFee($fee) { public function setFee($fee) {
$this->fee = $fee; $this->fee = $fee;
return $this;
} }
/** /**
@@ -67,4 +74,5 @@ class Details extends \PPModel {
return $this->fee; return $this->fee;
} }
} }

View File

@@ -9,6 +9,7 @@ class FundingInstrument extends \PPModel {
*/ */
public function setCreditCard($credit_card) { public function setCreditCard($credit_card) {
$this->credit_card = $credit_card; $this->credit_card = $credit_card;
return $this;
} }
/** /**
@@ -19,12 +20,27 @@ class FundingInstrument extends \PPModel {
return $this->credit_card; return $this->credit_card;
} }
/**
* Deprecated method
*/
public function setCredit_card($credit_card) {
$this->credit_card = $credit_card;
return $this;
}
/**
* Deprecated method
*/
public function getCredit_card() {
return $this->credit_card;
}
/** /**
* Credit Card information. * Credit Card information.
* @param PayPal\Api\CreditCardToken $credit_card_token * @param PayPal\Api\CreditCardToken $credit_card_token
*/ */
public function setCreditCardToken($credit_card_token) { public function setCreditCardToken($credit_card_token) {
$this->credit_card_token = $credit_card_token; $this->credit_card_token = $credit_card_token;
return $this;
} }
/** /**
@@ -35,4 +51,18 @@ class FundingInstrument extends \PPModel {
return $this->credit_card_token; return $this->credit_card_token;
} }
/**
* Deprecated method
*/
public function setCredit_card_token($credit_card_token) {
$this->credit_card_token = $credit_card_token;
return $this;
}
/**
* Deprecated method
*/
public function getCredit_card_token() {
return $this->credit_card_token;
}
} }

View File

@@ -10,6 +10,7 @@ class HyperSchema extends \PPModel {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -20,12 +21,14 @@ class HyperSchema extends \PPModel {
return $this->links; return $this->links;
} }
/** /**
* *
* @param string $fragmentResolution * @param string $fragmentResolution
*/ */
public function setFragmentResolution($fragmentResolution) { public function setFragmentResolution($fragmentResolution) {
$this->fragmentResolution = $fragmentResolution; $this->fragmentResolution = $fragmentResolution;
return $this;
} }
/** /**
@@ -36,12 +39,27 @@ class HyperSchema extends \PPModel {
return $this->fragmentResolution; return $this->fragmentResolution;
} }
/**
* Deprecated method
*/
public function setFragmentresolution($fragmentResolution) {
$this->fragmentResolution = $fragmentResolution;
return $this;
}
/**
* Deprecated method
*/
public function getFragmentresolution() {
return $this->fragmentResolution;
}
/** /**
* *
* @param boolean $readonly * @param boolean $readonly
*/ */
public function setReadonly($readonly) { public function setReadonly($readonly) {
$this->readonly = $readonly; $this->readonly = $readonly;
return $this;
} }
/** /**
@@ -52,12 +70,14 @@ class HyperSchema extends \PPModel {
return $this->readonly; return $this->readonly;
} }
/** /**
* *
* @param string $contentEncoding * @param string $contentEncoding
*/ */
public function setContentEncoding($contentEncoding) { public function setContentEncoding($contentEncoding) {
$this->contentEncoding = $contentEncoding; $this->contentEncoding = $contentEncoding;
return $this;
} }
/** /**
@@ -68,12 +88,27 @@ class HyperSchema extends \PPModel {
return $this->contentEncoding; return $this->contentEncoding;
} }
/**
* Deprecated method
*/
public function setContentencoding($contentEncoding) {
$this->contentEncoding = $contentEncoding;
return $this;
}
/**
* Deprecated method
*/
public function getContentencoding() {
return $this->contentEncoding;
}
/** /**
* *
* @param string $pathStart * @param string $pathStart
*/ */
public function setPathStart($pathStart) { public function setPathStart($pathStart) {
$this->pathStart = $pathStart; $this->pathStart = $pathStart;
return $this;
} }
/** /**
@@ -84,12 +119,27 @@ class HyperSchema extends \PPModel {
return $this->pathStart; return $this->pathStart;
} }
/**
* Deprecated method
*/
public function setPathstart($pathStart) {
$this->pathStart = $pathStart;
return $this;
}
/**
* Deprecated method
*/
public function getPathstart() {
return $this->pathStart;
}
/** /**
* *
* @param string $mediaType * @param string $mediaType
*/ */
public function setMediaType($mediaType) { public function setMediaType($mediaType) {
$this->mediaType = $mediaType; $this->mediaType = $mediaType;
return $this;
} }
/** /**
@@ -100,4 +150,18 @@ class HyperSchema extends \PPModel {
return $this->mediaType; return $this->mediaType;
} }
/**
* Deprecated method
*/
public function setMediatype($mediaType) {
$this->mediaType = $mediaType;
return $this;
}
/**
* Deprecated method
*/
public function getMediatype() {
return $this->mediaType;
}
} }

View File

@@ -9,6 +9,7 @@ class Item extends \PPModel {
*/ */
public function setQuantity($quantity) { public function setQuantity($quantity) {
$this->quantity = $quantity; $this->quantity = $quantity;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Item extends \PPModel {
return $this->quantity; return $this->quantity;
} }
/** /**
* Name of the item. * Name of the item.
* @param string $name * @param string $name
*/ */
public function setName($name) { public function setName($name) {
$this->name = $name; $this->name = $name;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class Item extends \PPModel {
return $this->name; return $this->name;
} }
/** /**
* Cost of the item. * Cost of the item.
* @param string $price * @param string $price
*/ */
public function setPrice($price) { public function setPrice($price) {
$this->price = $price; $this->price = $price;
return $this;
} }
/** /**
@@ -51,12 +56,14 @@ class Item extends \PPModel {
return $this->price; return $this->price;
} }
/** /**
* 3-letter Currency Code * 3-letter Currency Code
* @param string $currency * @param string $currency
*/ */
public function setCurrency($currency) { public function setCurrency($currency) {
$this->currency = $currency; $this->currency = $currency;
return $this;
} }
/** /**
@@ -67,12 +74,14 @@ class Item extends \PPModel {
return $this->currency; return $this->currency;
} }
/** /**
* Number or code to identify the item in your catalog/records. * Number or code to identify the item in your catalog/records.
* @param string $sku * @param string $sku
*/ */
public function setSku($sku) { public function setSku($sku) {
$this->sku = $sku; $this->sku = $sku;
return $this;
} }
/** /**
@@ -83,4 +92,5 @@ class Item extends \PPModel {
return $this->sku; return $this->sku;
} }
} }

View File

@@ -10,6 +10,7 @@ class ItemList extends \PPModel {
*/ */
public function setItems($items) { public function setItems($items) {
$this->items = $items; $this->items = $items;
return $this;
} }
/** /**
@@ -20,12 +21,14 @@ class ItemList extends \PPModel {
return $this->items; return $this->items;
} }
/** /**
* Shipping address. * Shipping address.
* @param PayPal\Api\ShippingAddress $shipping_address * @param PayPal\Api\ShippingAddress $shipping_address
*/ */
public function setShippingAddress($shipping_address) { public function setShippingAddress($shipping_address) {
$this->shipping_address = $shipping_address; $this->shipping_address = $shipping_address;
return $this;
} }
/** /**
@@ -36,4 +39,18 @@ class ItemList extends \PPModel {
return $this->shipping_address; return $this->shipping_address;
} }
/**
* Deprecated method
*/
public function setShipping_address($shipping_address) {
$this->shipping_address = $shipping_address;
return $this;
}
/**
* Deprecated method
*/
public function getShipping_address() {
return $this->shipping_address;
}
} }

View File

@@ -9,6 +9,7 @@ class Links extends \PPModel {
*/ */
public function setHref($href) { public function setHref($href) {
$this->href = $href; $this->href = $href;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Links extends \PPModel {
return $this->href; return $this->href;
} }
/** /**
* *
* @param string $rel * @param string $rel
*/ */
public function setRel($rel) { public function setRel($rel) {
$this->rel = $rel; $this->rel = $rel;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class Links extends \PPModel {
return $this->rel; return $this->rel;
} }
/** /**
* *
* @param PayPal\Api\HyperSchema $targetSchema * @param PayPal\Api\HyperSchema $targetSchema
*/ */
public function setTargetSchema($targetSchema) { public function setTargetSchema($targetSchema) {
$this->targetSchema = $targetSchema; $this->targetSchema = $targetSchema;
return $this;
} }
/** /**
@@ -51,12 +56,27 @@ class Links extends \PPModel {
return $this->targetSchema; return $this->targetSchema;
} }
/**
* Deprecated method
*/
public function setTargetschema($targetSchema) {
$this->targetSchema = $targetSchema;
return $this;
}
/**
* Deprecated method
*/
public function getTargetschema() {
return $this->targetSchema;
}
/** /**
* *
* @param string $method * @param string $method
*/ */
public function setMethod($method) { public function setMethod($method) {
$this->method = $method; $this->method = $method;
return $this;
} }
/** /**
@@ -67,12 +87,14 @@ class Links extends \PPModel {
return $this->method; return $this->method;
} }
/** /**
* *
* @param string $enctype * @param string $enctype
*/ */
public function setEnctype($enctype) { public function setEnctype($enctype) {
$this->enctype = $enctype; $this->enctype = $enctype;
return $this;
} }
/** /**
@@ -83,12 +105,14 @@ class Links extends \PPModel {
return $this->enctype; return $this->enctype;
} }
/** /**
* *
* @param PayPal\Api\HyperSchema $schema * @param PayPal\Api\HyperSchema $schema
*/ */
public function setSchema($schema) { public function setSchema($schema) {
$this->schema = $schema; $this->schema = $schema;
return $this;
} }
/** /**
@@ -99,4 +123,5 @@ class Links extends \PPModel {
return $this->schema; return $this->schema;
} }
} }

View File

@@ -9,6 +9,7 @@ class Payee extends \PPModel {
*/ */
public function setEmail($email) { public function setEmail($email) {
$this->email = $email; $this->email = $email;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Payee extends \PPModel {
return $this->email; return $this->email;
} }
/** /**
* Encrypted PayPal Account identifier for the Payee. * Encrypted PayPal Account identifier for the Payee.
* @param string $merchant_id * @param string $merchant_id
*/ */
public function setMerchantId($merchant_id) { public function setMerchantId($merchant_id) {
$this->merchant_id = $merchant_id; $this->merchant_id = $merchant_id;
return $this;
} }
/** /**
@@ -35,12 +38,27 @@ class Payee extends \PPModel {
return $this->merchant_id; return $this->merchant_id;
} }
/**
* Deprecated method
*/
public function setMerchant_id($merchant_id) {
$this->merchant_id = $merchant_id;
return $this;
}
/**
* Deprecated method
*/
public function getMerchant_id() {
return $this->merchant_id;
}
/** /**
* Phone number (in E.123 format) associated with the Payee's PayPal Account. If the provided phont number is not associated with any PayPal Account, the payee can only receiver PayPal Wallet Payments. Direct Credit Card Payments will be denied due to card compliance requirements. * Phone number (in E.123 format) associated with the Payee's PayPal Account. If the provided phont number is not associated with any PayPal Account, the payee can only receiver PayPal Wallet Payments. Direct Credit Card Payments will be denied due to card compliance requirements.
* @param string $phone * @param string $phone
*/ */
public function setPhone($phone) { public function setPhone($phone) {
$this->phone = $phone; $this->phone = $phone;
return $this;
} }
/** /**
@@ -51,4 +69,5 @@ class Payee extends \PPModel {
return $this->phone; return $this->phone;
} }
} }

View File

@@ -9,6 +9,7 @@ class Payer extends \PPModel {
*/ */
public function setPaymentMethod($payment_method) { public function setPaymentMethod($payment_method) {
$this->payment_method = $payment_method; $this->payment_method = $payment_method;
return $this;
} }
/** /**
@@ -19,6 +20,20 @@ class Payer extends \PPModel {
return $this->payment_method; return $this->payment_method;
} }
/**
* Deprecated method
*/
public function setPayment_method($payment_method) {
$this->payment_method = $payment_method;
return $this;
}
/**
* Deprecated method
*/
public function getPayment_method() {
return $this->payment_method;
}
/** /**
* List of funding instruments from where the funds of the current payment come from. Typically a credit card. * List of funding instruments from where the funds of the current payment come from. Typically a credit card.
* @array * @array
@@ -26,6 +41,7 @@ class Payer extends \PPModel {
*/ */
public function setFundingInstruments($funding_instruments) { public function setFundingInstruments($funding_instruments) {
$this->funding_instruments = $funding_instruments; $this->funding_instruments = $funding_instruments;
return $this;
} }
/** /**
@@ -36,12 +52,27 @@ class Payer extends \PPModel {
return $this->funding_instruments; return $this->funding_instruments;
} }
/**
* Deprecated method
*/
public function setFunding_instruments($funding_instruments) {
$this->funding_instruments = $funding_instruments;
return $this;
}
/**
* Deprecated method
*/
public function getFunding_instruments() {
return $this->funding_instruments;
}
/** /**
* Information related to the Payer. In case of PayPal Wallet payment, this information will be filled in by PayPal after the user approves the payment using their PayPal Wallet. * Information related to the Payer. In case of PayPal Wallet payment, this information will be filled in by PayPal after the user approves the payment using their PayPal Wallet.
* @param PayPal\Api\PayerInfo $payer_info * @param PayPal\Api\PayerInfo $payer_info
*/ */
public function setPayerInfo($payer_info) { public function setPayerInfo($payer_info) {
$this->payer_info = $payer_info; $this->payer_info = $payer_info;
return $this;
} }
/** /**
@@ -52,4 +83,18 @@ class Payer extends \PPModel {
return $this->payer_info; return $this->payer_info;
} }
/**
* Deprecated method
*/
public function setPayer_info($payer_info) {
$this->payer_info = $payer_info;
return $this;
}
/**
* Deprecated method
*/
public function getPayer_info() {
return $this->payer_info;
}
} }

View File

@@ -9,6 +9,7 @@ class PayerInfo extends \PPModel {
*/ */
public function setEmail($email) { public function setEmail($email) {
$this->email = $email; $this->email = $email;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class PayerInfo extends \PPModel {
return $this->email; return $this->email;
} }
/** /**
* First Name of the Payer from their PayPal Account. * First Name of the Payer from their PayPal Account.
* @param string $first_name * @param string $first_name
*/ */
public function setFirstName($first_name) { public function setFirstName($first_name) {
$this->first_name = $first_name; $this->first_name = $first_name;
return $this;
} }
/** /**
@@ -35,12 +38,27 @@ class PayerInfo extends \PPModel {
return $this->first_name; return $this->first_name;
} }
/**
* Deprecated method
*/
public function setFirst_name($first_name) {
$this->first_name = $first_name;
return $this;
}
/**
* Deprecated method
*/
public function getFirst_name() {
return $this->first_name;
}
/** /**
* Last Name of the Payer from their PayPal Account. * Last Name of the Payer from their PayPal Account.
* @param string $last_name * @param string $last_name
*/ */
public function setLastName($last_name) { public function setLastName($last_name) {
$this->last_name = $last_name; $this->last_name = $last_name;
return $this;
} }
/** /**
@@ -51,12 +69,27 @@ class PayerInfo extends \PPModel {
return $this->last_name; return $this->last_name;
} }
/**
* Deprecated method
*/
public function setLast_name($last_name) {
$this->last_name = $last_name;
return $this;
}
/**
* Deprecated method
*/
public function getLast_name() {
return $this->last_name;
}
/** /**
* PayPal assigned Payer ID. * PayPal assigned Payer ID.
* @param string $payer_id * @param string $payer_id
*/ */
public function setPayerId($payer_id) { public function setPayerId($payer_id) {
$this->payer_id = $payer_id; $this->payer_id = $payer_id;
return $this;
} }
/** /**
@@ -67,12 +100,27 @@ class PayerInfo extends \PPModel {
return $this->payer_id; return $this->payer_id;
} }
/**
* Deprecated method
*/
public function setPayer_id($payer_id) {
$this->payer_id = $payer_id;
return $this;
}
/**
* Deprecated method
*/
public function getPayer_id() {
return $this->payer_id;
}
/** /**
* Phone number representing the Payer. * Phone number representing the Payer.
* @param string $phone * @param string $phone
*/ */
public function setPhone($phone) { public function setPhone($phone) {
$this->phone = $phone; $this->phone = $phone;
return $this;
} }
/** /**
@@ -83,12 +131,14 @@ class PayerInfo extends \PPModel {
return $this->phone; return $this->phone;
} }
/** /**
* Shipping address of the Payer from their PayPal Account. * Shipping address of the Payer from their PayPal Account.
* @param PayPal\Api\Address $shipping_address * @param PayPal\Api\Address $shipping_address
*/ */
public function setShippingAddress($shipping_address) { public function setShippingAddress($shipping_address) {
$this->shipping_address = $shipping_address; $this->shipping_address = $shipping_address;
return $this;
} }
/** /**
@@ -99,4 +149,18 @@ class PayerInfo extends \PPModel {
return $this->shipping_address; return $this->shipping_address;
} }
/**
* Deprecated method
*/
public function setShipping_address($shipping_address) {
$this->shipping_address = $shipping_address;
return $this;
}
/**
* Deprecated method
*/
public function getShipping_address() {
return $this->shipping_address;
}
} }

View File

@@ -23,6 +23,7 @@ class Payment extends \PPModel implements IResource {
*/ */
public function setId($id) { public function setId($id) {
$this->id = $id; $this->id = $id;
return $this;
} }
/** /**
@@ -33,12 +34,14 @@ class Payment extends \PPModel implements IResource {
return $this->id; return $this->id;
} }
/** /**
* Time the resource was created. * Time the resource was created.
* @param string $create_time * @param string $create_time
*/ */
public function setCreateTime($create_time) { public function setCreateTime($create_time) {
$this->create_time = $create_time; $this->create_time = $create_time;
return $this;
} }
/** /**
@@ -49,12 +52,27 @@ class Payment extends \PPModel implements IResource {
return $this->create_time; return $this->create_time;
} }
/**
* Deprecated method
*/
public function setCreate_time($create_time) {
$this->create_time = $create_time;
return $this;
}
/**
* Deprecated method
*/
public function getCreate_time() {
return $this->create_time;
}
/** /**
* Time the resource was last updated. * Time the resource was last updated.
* @param string $update_time * @param string $update_time
*/ */
public function setUpdateTime($update_time) { public function setUpdateTime($update_time) {
$this->update_time = $update_time; $this->update_time = $update_time;
return $this;
} }
/** /**
@@ -65,12 +83,27 @@ class Payment extends \PPModel implements IResource {
return $this->update_time; return $this->update_time;
} }
/**
* Deprecated method
*/
public function setUpdate_time($update_time) {
$this->update_time = $update_time;
return $this;
}
/**
* Deprecated method
*/
public function getUpdate_time() {
return $this->update_time;
}
/** /**
* Intent of the payment - Sale or Authorization or Order. * Intent of the payment - Sale or Authorization or Order.
* @param string $intent * @param string $intent
*/ */
public function setIntent($intent) { public function setIntent($intent) {
$this->intent = $intent; $this->intent = $intent;
return $this;
} }
/** /**
@@ -81,12 +114,14 @@ class Payment extends \PPModel implements IResource {
return $this->intent; return $this->intent;
} }
/** /**
* Source of the funds for this payment represented by a PayPal account or a direct credit card. * Source of the funds for this payment represented by a PayPal account or a direct credit card.
* @param PayPal\Api\Payer $payer * @param PayPal\Api\Payer $payer
*/ */
public function setPayer($payer) { public function setPayer($payer) {
$this->payer = $payer; $this->payer = $payer;
return $this;
} }
/** /**
@@ -97,6 +132,7 @@ class Payment extends \PPModel implements IResource {
return $this->payer; return $this->payer;
} }
/** /**
* A payment can have more than one transaction, with each transaction establishing a contract between the payer and a payee * A payment can have more than one transaction, with each transaction establishing a contract between the payer and a payee
* @array * @array
@@ -104,6 +140,7 @@ class Payment extends \PPModel implements IResource {
*/ */
public function setTransactions($transactions) { public function setTransactions($transactions) {
$this->transactions = $transactions; $this->transactions = $transactions;
return $this;
} }
/** /**
@@ -114,12 +151,14 @@ class Payment extends \PPModel implements IResource {
return $this->transactions; return $this->transactions;
} }
/** /**
* state of the payment * state of the payment
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -130,12 +169,14 @@ class Payment extends \PPModel implements IResource {
return $this->state; return $this->state;
} }
/** /**
* Redirect urls required only when using payment_method as PayPal - the only settings supported are return and cancel urls. * Redirect urls required only when using payment_method as PayPal - the only settings supported are return and cancel urls.
* @param PayPal\Api\RedirectUrls $redirect_urls * @param PayPal\Api\RedirectUrls $redirect_urls
*/ */
public function setRedirectUrls($redirect_urls) { public function setRedirectUrls($redirect_urls) {
$this->redirect_urls = $redirect_urls; $this->redirect_urls = $redirect_urls;
return $this;
} }
/** /**
@@ -146,6 +187,20 @@ class Payment extends \PPModel implements IResource {
return $this->redirect_urls; return $this->redirect_urls;
} }
/**
* Deprecated method
*/
public function setRedirect_urls($redirect_urls) {
$this->redirect_urls = $redirect_urls;
return $this;
}
/**
* Deprecated method
*/
public function getRedirect_urls() {
return $this->redirect_urls;
}
/** /**
* *
* @array * @array
@@ -153,6 +208,7 @@ class Payment extends \PPModel implements IResource {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -164,6 +220,7 @@ class Payment extends \PPModel implements IResource {
} }
public function create($apiContext = null) { public function create($apiContext = null) {
$payLoad = $this->toJSON(); $payLoad = $this->toJSON();
if ($apiContext == null) { if ($apiContext == null) {

View File

@@ -9,6 +9,7 @@ class PaymentExecution extends \PPModel {
*/ */
public function setPayerId($payer_id) { public function setPayerId($payer_id) {
$this->payer_id = $payer_id; $this->payer_id = $payer_id;
return $this;
} }
/** /**
@@ -19,6 +20,20 @@ class PaymentExecution extends \PPModel {
return $this->payer_id; return $this->payer_id;
} }
/**
* Deprecated method
*/
public function setPayer_id($payer_id) {
$this->payer_id = $payer_id;
return $this;
}
/**
* Deprecated method
*/
public function getPayer_id() {
return $this->payer_id;
}
/** /**
* If the amount needs to be updated after obtaining the PayPal Payer info (eg. shipping address), it can be updated using this element. * If the amount needs to be updated after obtaining the PayPal Payer info (eg. shipping address), it can be updated using this element.
* @array * @array
@@ -26,6 +41,7 @@ class PaymentExecution extends \PPModel {
*/ */
public function setTransactions($transactions) { public function setTransactions($transactions) {
$this->transactions = $transactions; $this->transactions = $transactions;
return $this;
} }
/** /**
@@ -36,4 +52,5 @@ class PaymentExecution extends \PPModel {
return $this->transactions; return $this->transactions;
} }
} }

View File

@@ -10,6 +10,7 @@ class PaymentHistory extends \PPModel {
*/ */
public function setPayments($payments) { public function setPayments($payments) {
$this->payments = $payments; $this->payments = $payments;
return $this;
} }
/** /**
@@ -20,12 +21,14 @@ class PaymentHistory extends \PPModel {
return $this->payments; return $this->payments;
} }
/** /**
* Number of items returned in each range of results. Note that the last results range could have fewer items than the requested number of items. * Number of items returned in each range of results. Note that the last results range could have fewer items than the requested number of items.
* @param integer $count * @param integer $count
*/ */
public function setCount($count) { public function setCount($count) {
$this->count = $count; $this->count = $count;
return $this;
} }
/** /**
@@ -36,12 +39,14 @@ class PaymentHistory extends \PPModel {
return $this->count; return $this->count;
} }
/** /**
* Identifier of the next element to get the next range of results. * Identifier of the next element to get the next range of results.
* @param string $next_id * @param string $next_id
*/ */
public function setNextId($next_id) { public function setNextId($next_id) {
$this->next_id = $next_id; $this->next_id = $next_id;
return $this;
} }
/** /**
@@ -52,4 +57,18 @@ class PaymentHistory extends \PPModel {
return $this->next_id; return $this->next_id;
} }
/**
* Deprecated method
*/
public function setNext_id($next_id) {
$this->next_id = $next_id;
return $this;
}
/**
* Deprecated method
*/
public function getNext_id() {
return $this->next_id;
}
} }

View File

@@ -9,6 +9,7 @@ class RedirectUrls extends \PPModel {
*/ */
public function setReturnUrl($return_url) { public function setReturnUrl($return_url) {
$this->return_url = $return_url; $this->return_url = $return_url;
return $this;
} }
/** /**
@@ -19,12 +20,27 @@ class RedirectUrls extends \PPModel {
return $this->return_url; return $this->return_url;
} }
/**
* Deprecated method
*/
public function setReturn_url($return_url) {
$this->return_url = $return_url;
return $this;
}
/**
* Deprecated method
*/
public function getReturn_url() {
return $this->return_url;
}
/** /**
* Url where the payer would be redirected to after canceling the payment. * Url where the payer would be redirected to after canceling the payment.
* @param string $cancel_url * @param string $cancel_url
*/ */
public function setCancelUrl($cancel_url) { public function setCancelUrl($cancel_url) {
$this->cancel_url = $cancel_url; $this->cancel_url = $cancel_url;
return $this;
} }
/** /**
@@ -35,4 +51,18 @@ class RedirectUrls extends \PPModel {
return $this->cancel_url; return $this->cancel_url;
} }
/**
* Deprecated method
*/
public function setCancel_url($cancel_url) {
$this->cancel_url = $cancel_url;
return $this;
}
/**
* Deprecated method
*/
public function getCancel_url() {
return $this->cancel_url;
}
} }

View File

@@ -23,6 +23,7 @@ class Refund extends \PPModel implements IResource {
*/ */
public function setId($id) { public function setId($id) {
$this->id = $id; $this->id = $id;
return $this;
} }
/** /**
@@ -33,12 +34,14 @@ class Refund extends \PPModel implements IResource {
return $this->id; return $this->id;
} }
/** /**
* Time the resource was created. * Time the resource was created.
* @param string $create_time * @param string $create_time
*/ */
public function setCreateTime($create_time) { public function setCreateTime($create_time) {
$this->create_time = $create_time; $this->create_time = $create_time;
return $this;
} }
/** /**
@@ -49,12 +52,27 @@ class Refund extends \PPModel implements IResource {
return $this->create_time; return $this->create_time;
} }
/**
* Deprecated method
*/
public function setCreate_time($create_time) {
$this->create_time = $create_time;
return $this;
}
/**
* Deprecated method
*/
public function getCreate_time() {
return $this->create_time;
}
/** /**
* Details including both refunded amount (to Payer) and refunded fee (to Payee).If amount is not specified, it's assumed to be full refund. * Details including both refunded amount (to Payer) and refunded fee (to Payee).If amount is not specified, it's assumed to be full refund.
* @param PayPal\Api\Amount $amount * @param PayPal\Api\Amount $amount
*/ */
public function setAmount($amount) { public function setAmount($amount) {
$this->amount = $amount; $this->amount = $amount;
return $this;
} }
/** /**
@@ -65,12 +83,14 @@ class Refund extends \PPModel implements IResource {
return $this->amount; return $this->amount;
} }
/** /**
* State of the refund transaction. * State of the refund transaction.
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -81,12 +101,14 @@ class Refund extends \PPModel implements IResource {
return $this->state; return $this->state;
} }
/** /**
* ID of the Sale transaction being refunded. * ID of the Sale transaction being refunded.
* @param string $sale_id * @param string $sale_id
*/ */
public function setSaleId($sale_id) { public function setSaleId($sale_id) {
$this->sale_id = $sale_id; $this->sale_id = $sale_id;
return $this;
} }
/** /**
@@ -97,12 +119,27 @@ class Refund extends \PPModel implements IResource {
return $this->sale_id; return $this->sale_id;
} }
/**
* Deprecated method
*/
public function setSale_id($sale_id) {
$this->sale_id = $sale_id;
return $this;
}
/**
* Deprecated method
*/
public function getSale_id() {
return $this->sale_id;
}
/** /**
* ID of the Capture transaction being refunded. * ID of the Capture transaction being refunded.
* @param string $capture_id * @param string $capture_id
*/ */
public function setCaptureId($capture_id) { public function setCaptureId($capture_id) {
$this->capture_id = $capture_id; $this->capture_id = $capture_id;
return $this;
} }
/** /**
@@ -113,12 +150,27 @@ class Refund extends \PPModel implements IResource {
return $this->capture_id; return $this->capture_id;
} }
/**
* Deprecated method
*/
public function setCapture_id($capture_id) {
$this->capture_id = $capture_id;
return $this;
}
/**
* Deprecated method
*/
public function getCapture_id() {
return $this->capture_id;
}
/** /**
* ID of the Payment resource that this transaction is based on. * ID of the Payment resource that this transaction is based on.
* @param string $parent_payment * @param string $parent_payment
*/ */
public function setParentPayment($parent_payment) { public function setParentPayment($parent_payment) {
$this->parent_payment = $parent_payment; $this->parent_payment = $parent_payment;
return $this;
} }
/** /**
@@ -129,6 +181,20 @@ class Refund extends \PPModel implements IResource {
return $this->parent_payment; return $this->parent_payment;
} }
/**
* Deprecated method
*/
public function setParent_payment($parent_payment) {
$this->parent_payment = $parent_payment;
return $this;
}
/**
* Deprecated method
*/
public function getParent_payment() {
return $this->parent_payment;
}
/** /**
* *
* @array * @array
@@ -136,6 +202,7 @@ class Refund extends \PPModel implements IResource {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -147,6 +214,7 @@ class Refund extends \PPModel implements IResource {
} }
public static function get($refundId, $apiContext = null) { public static function get($refundId, $apiContext = null) {
if (($refundId == null) || (strlen($refundId) <= 0)) { if (($refundId == null) || (strlen($refundId) <= 0)) {
throw new \InvalidArgumentException("refundId cannot be null or empty"); throw new \InvalidArgumentException("refundId cannot be null or empty");

View File

@@ -9,6 +9,7 @@ class RelatedResources extends \PPModel {
*/ */
public function setSale($sale) { public function setSale($sale) {
$this->sale = $sale; $this->sale = $sale;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class RelatedResources extends \PPModel {
return $this->sale; return $this->sale;
} }
/** /**
* An authorization transaction * An authorization transaction
* @param PayPal\Api\Authorization $authorization * @param PayPal\Api\Authorization $authorization
*/ */
public function setAuthorization($authorization) { public function setAuthorization($authorization) {
$this->authorization = $authorization; $this->authorization = $authorization;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class RelatedResources extends \PPModel {
return $this->authorization; return $this->authorization;
} }
/** /**
* A capture transaction * A capture transaction
* @param PayPal\Api\Capture $capture * @param PayPal\Api\Capture $capture
*/ */
public function setCapture($capture) { public function setCapture($capture) {
$this->capture = $capture; $this->capture = $capture;
return $this;
} }
/** /**
@@ -51,12 +56,14 @@ class RelatedResources extends \PPModel {
return $this->capture; return $this->capture;
} }
/** /**
* A refund transaction * A refund transaction
* @param PayPal\Api\Refund $refund * @param PayPal\Api\Refund $refund
*/ */
public function setRefund($refund) { public function setRefund($refund) {
$this->refund = $refund; $this->refund = $refund;
return $this;
} }
/** /**
@@ -67,4 +74,5 @@ class RelatedResources extends \PPModel {
return $this->refund; return $this->refund;
} }
} }

View File

@@ -23,6 +23,7 @@ class Sale extends \PPModel implements IResource {
*/ */
public function setId($id) { public function setId($id) {
$this->id = $id; $this->id = $id;
return $this;
} }
/** /**
@@ -33,12 +34,14 @@ class Sale extends \PPModel implements IResource {
return $this->id; return $this->id;
} }
/** /**
* Time the resource was created. * Time the resource was created.
* @param string $create_time * @param string $create_time
*/ */
public function setCreateTime($create_time) { public function setCreateTime($create_time) {
$this->create_time = $create_time; $this->create_time = $create_time;
return $this;
} }
/** /**
@@ -49,12 +52,27 @@ class Sale extends \PPModel implements IResource {
return $this->create_time; return $this->create_time;
} }
/**
* Deprecated method
*/
public function setCreate_time($create_time) {
$this->create_time = $create_time;
return $this;
}
/**
* Deprecated method
*/
public function getCreate_time() {
return $this->create_time;
}
/** /**
* Time the resource was last updated. * Time the resource was last updated.
* @param string $update_time * @param string $update_time
*/ */
public function setUpdateTime($update_time) { public function setUpdateTime($update_time) {
$this->update_time = $update_time; $this->update_time = $update_time;
return $this;
} }
/** /**
@@ -65,12 +83,27 @@ class Sale extends \PPModel implements IResource {
return $this->update_time; return $this->update_time;
} }
/**
* Deprecated method
*/
public function setUpdate_time($update_time) {
$this->update_time = $update_time;
return $this;
}
/**
* Deprecated method
*/
public function getUpdate_time() {
return $this->update_time;
}
/** /**
* Amount being collected. * Amount being collected.
* @param PayPal\Api\Amount $amount * @param PayPal\Api\Amount $amount
*/ */
public function setAmount($amount) { public function setAmount($amount) {
$this->amount = $amount; $this->amount = $amount;
return $this;
} }
/** /**
@@ -81,12 +114,14 @@ class Sale extends \PPModel implements IResource {
return $this->amount; return $this->amount;
} }
/** /**
* State of the sale transaction. * State of the sale transaction.
* @param string $state * @param string $state
*/ */
public function setState($state) { public function setState($state) {
$this->state = $state; $this->state = $state;
return $this;
} }
/** /**
@@ -97,12 +132,14 @@ class Sale extends \PPModel implements IResource {
return $this->state; return $this->state;
} }
/** /**
* ID of the Payment resource that this transaction is based on. * ID of the Payment resource that this transaction is based on.
* @param string $parent_payment * @param string $parent_payment
*/ */
public function setParentPayment($parent_payment) { public function setParentPayment($parent_payment) {
$this->parent_payment = $parent_payment; $this->parent_payment = $parent_payment;
return $this;
} }
/** /**
@@ -113,6 +150,20 @@ class Sale extends \PPModel implements IResource {
return $this->parent_payment; return $this->parent_payment;
} }
/**
* Deprecated method
*/
public function setParent_payment($parent_payment) {
$this->parent_payment = $parent_payment;
return $this;
}
/**
* Deprecated method
*/
public function getParent_payment() {
return $this->parent_payment;
}
/** /**
* *
* @array * @array
@@ -120,6 +171,7 @@ class Sale extends \PPModel implements IResource {
*/ */
public function setLinks($links) { public function setLinks($links) {
$this->links = $links; $this->links = $links;
return $this;
} }
/** /**
@@ -131,6 +183,7 @@ class Sale extends \PPModel implements IResource {
} }
public static function get($saleId, $apiContext = null) { public static function get($saleId, $apiContext = null) {
if (($saleId == null) || (strlen($saleId) <= 0)) { if (($saleId == null) || (strlen($saleId) <= 0)) {
throw new \InvalidArgumentException("saleId cannot be null or empty"); throw new \InvalidArgumentException("saleId cannot be null or empty");

View File

@@ -9,6 +9,7 @@ class ShippingAddress extends Address {
*/ */
public function setRecipientName($recipient_name) { public function setRecipientName($recipient_name) {
$this->recipient_name = $recipient_name; $this->recipient_name = $recipient_name;
return $this;
} }
/** /**
@@ -19,4 +20,18 @@ class ShippingAddress extends Address {
return $this->recipient_name; return $this->recipient_name;
} }
/**
* Deprecated method
*/
public function setRecipient_name($recipient_name) {
$this->recipient_name = $recipient_name;
return $this;
}
/**
* Deprecated method
*/
public function getRecipient_name() {
return $this->recipient_name;
}
} }

View File

@@ -9,6 +9,7 @@ class Transaction extends \PPModel {
*/ */
public function setAmount($amount) { public function setAmount($amount) {
$this->amount = $amount; $this->amount = $amount;
return $this;
} }
/** /**
@@ -19,12 +20,14 @@ class Transaction extends \PPModel {
return $this->amount; return $this->amount;
} }
/** /**
* Recepient of the funds in this transaction. * Recepient of the funds in this transaction.
* @param PayPal\Api\Payee $payee * @param PayPal\Api\Payee $payee
*/ */
public function setPayee($payee) { public function setPayee($payee) {
$this->payee = $payee; $this->payee = $payee;
return $this;
} }
/** /**
@@ -35,12 +38,14 @@ class Transaction extends \PPModel {
return $this->payee; return $this->payee;
} }
/** /**
* Description of what is being paid for. * Description of what is being paid for.
* @param string $description * @param string $description
*/ */
public function setDescription($description) { public function setDescription($description) {
$this->description = $description; $this->description = $description;
return $this;
} }
/** /**
@@ -51,12 +56,14 @@ class Transaction extends \PPModel {
return $this->description; return $this->description;
} }
/** /**
* List of items being paid for. * List of items being paid for.
* @param PayPal\Api\ItemList $item_list * @param PayPal\Api\ItemList $item_list
*/ */
public function setItemList($item_list) { public function setItemList($item_list) {
$this->item_list = $item_list; $this->item_list = $item_list;
return $this;
} }
/** /**
@@ -67,6 +74,20 @@ class Transaction extends \PPModel {
return $this->item_list; return $this->item_list;
} }
/**
* Deprecated method
*/
public function setItem_list($item_list) {
$this->item_list = $item_list;
return $this;
}
/**
* Deprecated method
*/
public function getItem_list() {
return $this->item_list;
}
/** /**
* List of financial transactions (Sale, Authorization, Capture, Refund) related to the payment. * List of financial transactions (Sale, Authorization, Capture, Refund) related to the payment.
* @array * @array
@@ -74,6 +95,7 @@ class Transaction extends \PPModel {
*/ */
public function setRelatedResources($related_resources) { public function setRelatedResources($related_resources) {
$this->related_resources = $related_resources; $this->related_resources = $related_resources;
return $this;
} }
/** /**
@@ -84,6 +106,20 @@ class Transaction extends \PPModel {
return $this->related_resources; return $this->related_resources;
} }
/**
* Deprecated method
*/
public function setRelated_resources($related_resources) {
$this->related_resources = $related_resources;
return $this;
}
/**
* Deprecated method
*/
public function getRelated_resources() {
return $this->related_resources;
}
/** /**
* Additional transactions for complex payment (Parallel and Chained) scenarios. * Additional transactions for complex payment (Parallel and Chained) scenarios.
* @array * @array
@@ -91,6 +127,7 @@ class Transaction extends \PPModel {
*/ */
public function setTransactions($transactions) { public function setTransactions($transactions) {
$this->transactions = $transactions; $this->transactions = $transactions;
return $this;
} }
/** /**
@@ -101,4 +138,5 @@ class Transaction extends \PPModel {
return $this->transactions; return $this->transactions;
} }
} }

View File

@@ -9,6 +9,7 @@ class Transactions extends \PPModel {
*/ */
public function setAmount($amount) { public function setAmount($amount) {
$this->amount = $amount; $this->amount = $amount;
return $this;
} }
/** /**
@@ -19,4 +20,5 @@ class Transactions extends \PPModel {
return $this->amount; return $this->amount;
} }
} }