forked from LiveCarta/PayPal-PHP-Server-SDK
Release 0.7.0
Beta Release 0.7.0 including: - Bug fixes - Updated model/function names - Updated models to reflect changes in APIs
This commit is contained in:
@@ -10,6 +10,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace PaypalServerSdkLib\Models;
|
||||
|
||||
use PaypalServerSdkLib\ApiHelper;
|
||||
use stdClass;
|
||||
|
||||
/**
|
||||
@@ -246,8 +247,8 @@ class Authorization implements \JsonSerializable
|
||||
/**
|
||||
* Returns Expiration Time.
|
||||
* The date and time, in [Internet date and time format](https://tools.ietf.org/html/rfc3339#section-5.
|
||||
* 6). Seconds are required while fractional seconds are optional.<blockquote><strong>Note:</strong>
|
||||
* The regular expression provides guidance but does not reject all invalid dates.</blockquote>
|
||||
* 6). Seconds are required while fractional seconds are optional. Note: The regular expression
|
||||
* provides guidance but does not reject all invalid dates.
|
||||
*/
|
||||
public function getExpirationTime(): ?string
|
||||
{
|
||||
@@ -257,8 +258,8 @@ class Authorization implements \JsonSerializable
|
||||
/**
|
||||
* Sets Expiration Time.
|
||||
* The date and time, in [Internet date and time format](https://tools.ietf.org/html/rfc3339#section-5.
|
||||
* 6). Seconds are required while fractional seconds are optional.<blockquote><strong>Note:</strong>
|
||||
* The regular expression provides guidance but does not reject all invalid dates.</blockquote>
|
||||
* 6). Seconds are required while fractional seconds are optional. Note: The regular expression
|
||||
* provides guidance but does not reject all invalid dates.
|
||||
*
|
||||
* @maps expiration_time
|
||||
*/
|
||||
@@ -294,8 +295,8 @@ class Authorization implements \JsonSerializable
|
||||
/**
|
||||
* Returns Create Time.
|
||||
* The date and time, in [Internet date and time format](https://tools.ietf.org/html/rfc3339#section-5.
|
||||
* 6). Seconds are required while fractional seconds are optional.<blockquote><strong>Note:</strong>
|
||||
* The regular expression provides guidance but does not reject all invalid dates.</blockquote>
|
||||
* 6). Seconds are required while fractional seconds are optional. Note: The regular expression
|
||||
* provides guidance but does not reject all invalid dates.
|
||||
*/
|
||||
public function getCreateTime(): ?string
|
||||
{
|
||||
@@ -305,8 +306,8 @@ class Authorization implements \JsonSerializable
|
||||
/**
|
||||
* Sets Create Time.
|
||||
* The date and time, in [Internet date and time format](https://tools.ietf.org/html/rfc3339#section-5.
|
||||
* 6). Seconds are required while fractional seconds are optional.<blockquote><strong>Note:</strong>
|
||||
* The regular expression provides guidance but does not reject all invalid dates.</blockquote>
|
||||
* 6). Seconds are required while fractional seconds are optional. Note: The regular expression
|
||||
* provides guidance but does not reject all invalid dates.
|
||||
*
|
||||
* @maps create_time
|
||||
*/
|
||||
@@ -318,8 +319,8 @@ class Authorization implements \JsonSerializable
|
||||
/**
|
||||
* Returns Update Time.
|
||||
* The date and time, in [Internet date and time format](https://tools.ietf.org/html/rfc3339#section-5.
|
||||
* 6). Seconds are required while fractional seconds are optional.<blockquote><strong>Note:</strong>
|
||||
* The regular expression provides guidance but does not reject all invalid dates.</blockquote>
|
||||
* 6). Seconds are required while fractional seconds are optional. Note: The regular expression
|
||||
* provides guidance but does not reject all invalid dates.
|
||||
*/
|
||||
public function getUpdateTime(): ?string
|
||||
{
|
||||
@@ -329,8 +330,8 @@ class Authorization implements \JsonSerializable
|
||||
/**
|
||||
* Sets Update Time.
|
||||
* The date and time, in [Internet date and time format](https://tools.ietf.org/html/rfc3339#section-5.
|
||||
* 6). Seconds are required while fractional seconds are optional.<blockquote><strong>Note:</strong>
|
||||
* The regular expression provides guidance but does not reject all invalid dates.</blockquote>
|
||||
* 6). Seconds are required while fractional seconds are optional. Note: The regular expression
|
||||
* provides guidance but does not reject all invalid dates.
|
||||
*
|
||||
* @maps update_time
|
||||
*/
|
||||
@@ -339,6 +340,32 @@ class Authorization implements \JsonSerializable
|
||||
$this->updateTime = $updateTime;
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts the Authorization object to a human-readable string representation.
|
||||
*
|
||||
* @return string The string representation of the Authorization object.
|
||||
*/
|
||||
public function __toString(): string
|
||||
{
|
||||
return ApiHelper::stringify(
|
||||
'Authorization',
|
||||
[
|
||||
'status' => $this->status,
|
||||
'statusDetails' => $this->statusDetails,
|
||||
'id' => $this->id,
|
||||
'amount' => $this->amount,
|
||||
'invoiceId' => $this->invoiceId,
|
||||
'customId' => $this->customId,
|
||||
'networkTransactionReference' => $this->networkTransactionReference,
|
||||
'sellerProtection' => $this->sellerProtection,
|
||||
'expirationTime' => $this->expirationTime,
|
||||
'links' => $this->links,
|
||||
'createTime' => $this->createTime,
|
||||
'updateTime' => $this->updateTime
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Encode this object to JSON
|
||||
*
|
||||
@@ -352,7 +379,7 @@ class Authorization implements \JsonSerializable
|
||||
{
|
||||
$json = [];
|
||||
if (isset($this->status)) {
|
||||
$json['status'] = AuthorizationStatus::checkValue($this->status);
|
||||
$json['status'] = $this->status;
|
||||
}
|
||||
if (isset($this->statusDetails)) {
|
||||
$json['status_details'] = $this->statusDetails;
|
||||
|
||||
Reference in New Issue
Block a user