Skip to content

Commit

Permalink
Update all services (#706)
Browse files Browse the repository at this point in the history
* [reformat][adyen-sdk-automation] automated change

* style(fmt): code formatted

* removed unittest using removed ClassicCheckoutSDK

---------

Co-authored-by: AdyenAutomationBot <Adyen Automation [email protected]>
Co-authored-by: Djoyke Reijans <[email protected]>
  • Loading branch information
3 people authored Nov 18, 2024
1 parent 58db956 commit 257655a
Show file tree
Hide file tree
Showing 73 changed files with 4,176 additions and 11,083 deletions.
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php

/**
* Adyen Checkout API
* Configuration API
*
* The version of the OpenAPI document: 71
* The version of the OpenAPI document: 2
* Generated by: https://openapi-generator.tech
* OpenAPI Generator version: 6.0.1
*
Expand All @@ -13,21 +13,21 @@
*/


namespace Adyen\Model\Checkout;
namespace Adyen\Model\BalancePlatform;

use \ArrayAccess;
use Adyen\Model\Checkout\ObjectSerializer;
use Adyen\Model\BalancePlatform\ObjectSerializer;

/**
* Avs Class Doc Comment
* AmountNonZeroDecimalsRequirement Class Doc Comment
*
* @category Class
* @package Adyen
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
* @implements \ArrayAccess<string, mixed>
*/
class Avs implements ModelInterface, ArrayAccess, \JsonSerializable
class AmountNonZeroDecimalsRequirement implements ModelInterface, ArrayAccess, \JsonSerializable
{
public const DISCRIMINATOR = null;

Expand All @@ -36,16 +36,16 @@ class Avs implements ModelInterface, ArrayAccess, \JsonSerializable
*
* @var string
*/
protected static $openAPIModelName = 'Avs';
protected static $openAPIModelName = 'AmountNonZeroDecimalsRequirement';

/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $openAPITypes = [
'addressEditable' => 'bool',
'enabled' => 'string'
'description' => 'string',
'type' => 'string'
];

/**
Expand All @@ -56,8 +56,8 @@ class Avs implements ModelInterface, ArrayAccess, \JsonSerializable
* @psalm-var array<string, string|null>
*/
protected static $openAPIFormats = [
'addressEditable' => null,
'enabled' => null
'description' => null,
'type' => null
];

/**
Expand All @@ -66,8 +66,8 @@ class Avs implements ModelInterface, ArrayAccess, \JsonSerializable
* @var boolean[]
*/
protected static $openAPINullables = [
'addressEditable' => false,
'enabled' => false
'description' => false,
'type' => false
];

/**
Expand Down Expand Up @@ -156,8 +156,8 @@ public function isNullableSetToNull(string $property): bool
* @var string[]
*/
protected static $attributeMap = [
'addressEditable' => 'addressEditable',
'enabled' => 'enabled'
'description' => 'description',
'type' => 'type'
];

/**
Expand All @@ -166,8 +166,8 @@ public function isNullableSetToNull(string $property): bool
* @var string[]
*/
protected static $setters = [
'addressEditable' => 'setAddressEditable',
'enabled' => 'setEnabled'
'description' => 'setDescription',
'type' => 'setType'
];

/**
Expand All @@ -176,8 +176,8 @@ public function isNullableSetToNull(string $property): bool
* @var string[]
*/
protected static $getters = [
'addressEditable' => 'getAddressEditable',
'enabled' => 'getEnabled'
'description' => 'getDescription',
'type' => 'getType'
];

/**
Expand Down Expand Up @@ -221,21 +221,17 @@ public function getModelName()
return self::$openAPIModelName;
}

public const ENABLED_YES = 'yes';
public const ENABLED_NO = 'no';
public const ENABLED_AUTOMATIC = 'automatic';
public const TYPE_AMOUNT_NON_ZERO_DECIMALS_REQUIREMENT = 'amountNonZeroDecimalsRequirement';

/**
* Gets allowable values of the enum
*
* @return string[]
*/
public function getEnabledAllowableValues()
public function getTypeAllowableValues()
{
return [
self::ENABLED_YES,
self::ENABLED_NO,
self::ENABLED_AUTOMATIC,
self::TYPE_AMOUNT_NON_ZERO_DECIMALS_REQUIREMENT,
];
}
/**
Expand All @@ -253,8 +249,8 @@ public function getEnabledAllowableValues()
*/
public function __construct(array $data = null)
{
$this->setIfExists('addressEditable', $data ?? [], null);
$this->setIfExists('enabled', $data ?? [], null);
$this->setIfExists('description', $data ?? [], null);
$this->setIfExists('type', $data ?? [], null);
}

/**
Expand Down Expand Up @@ -284,11 +280,14 @@ public function listInvalidProperties()
{
$invalidProperties = [];

$allowedValues = $this->getEnabledAllowableValues();
if (!is_null($this->container['enabled']) && !in_array($this->container['enabled'], $allowedValues, true)) {
if ($this->container['type'] === null) {
$invalidProperties[] = "'type' can't be null";
}
$allowedValues = $this->getTypeAllowableValues();
if (!is_null($this->container['type']) && !in_array($this->container['type'], $allowedValues, true)) {
$invalidProperties[] = sprintf(
"invalid value '%s' for 'enabled', must be one of '%s'",
$this->container['enabled'],
"invalid value '%s' for 'type', must be one of '%s'",
$this->container['type'],
implode("', '", $allowedValues)
);
}
Expand All @@ -309,59 +308,59 @@ public function valid()


/**
* Gets addressEditable
* Gets description
*
* @return bool|null
* @return string|null
*/
public function getAddressEditable()
public function getDescription()
{
return $this->container['addressEditable'];
return $this->container['description'];
}

/**
* Sets addressEditable
* Sets description
*
* @param bool|null $addressEditable Indicates whether the shopper is allowed to modify the billing address for the current payment request.
* @param string|null $description Specifies for which routes the amount in a transfer request must have no non-zero decimal places, so the transfer can only be processed if the amount consists of round numbers.
*
* @return self
*/
public function setAddressEditable($addressEditable)
public function setDescription($description)
{
$this->container['addressEditable'] = $addressEditable;
$this->container['description'] = $description;

return $this;
}

/**
* Gets enabled
* Gets type
*
* @return string|null
* @return string
*/
public function getEnabled()
public function getType()
{
return $this->container['enabled'];
return $this->container['type'];
}

/**
* Sets enabled
* Sets type
*
* @param string|null $enabled Specifies whether the shopper should enter their billing address during checkout. Allowed values: * yes — Perform AVS checks for every card payment. * automatic — Perform AVS checks only when required to optimize the conversion rate. * no — Do not perform AVS checks.
* @param string $type **amountNonZeroDecimalsRequirement**
*
* @return self
*/
public function setEnabled($enabled)
public function setType($type)
{
$allowedValues = $this->getEnabledAllowableValues();
if (!in_array($enabled, $allowedValues, true)) {
$allowedValues = $this->getTypeAllowableValues();
if (!in_array($type, $allowedValues, true)) {
throw new \InvalidArgumentException(
sprintf(
"Invalid value '%s' for 'enabled', must be one of '%s'",
$enabled,
"Invalid value '%s' for 'type', must be one of '%s'",
$type,
implode("', '", $allowedValues)
)
);
}
$this->container['enabled'] = $enabled;
$this->container['type'] = $type;

return $this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,7 @@ public function getModelName()
public const REASON_PENDING_APPROVAL = 'pendingApproval';
public const REASON_PENDING_EXECUTION = 'pendingExecution';
public const REASON_REFUSED_BY_COUNTERPARTY_BANK = 'refusedByCounterpartyBank';
public const REASON_REFUSED_BY_CUSTOMER = 'refusedByCustomer';
public const REASON_ROUTE_NOT_FOUND = 'routeNotFound';
public const REASON_SCA_FAILED = 'scaFailed';
public const REASON_TRANSFER_INSTRUMENT_DOES_NOT_EXIST = 'transferInstrumentDoesNotExist';
Expand Down Expand Up @@ -384,6 +385,7 @@ public function getReasonAllowableValues()
self::REASON_PENDING_APPROVAL,
self::REASON_PENDING_EXECUTION,
self::REASON_REFUSED_BY_COUNTERPARTY_BANK,
self::REASON_REFUSED_BY_CUSTOMER,
self::REASON_ROUTE_NOT_FOUND,
self::REASON_SCA_FAILED,
self::REASON_TRANSFER_INSTRUMENT_DOES_NOT_EXIST,
Expand Down
Loading

0 comments on commit 257655a

Please sign in to comment.