Миграция на php8.1

* enum-ы теперь enum-ы, а не говно -- теперь всё переведено на них, где это было возможно
* некоторые свойства классов объявлены в конструкторе
* некоторые классы перемещены в корневой неймспейс
* исправлен код-стайл, вычищен некоторый мусор, выправлены тесты... работы над этим продолжаются
This commit is contained in:
2022-12-15 00:19:55 +08:00
parent 692ae43f9f
commit 4157ab68f5
120 changed files with 1098 additions and 1401 deletions

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при пустом наименовании дополнительного реквизита пользователя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при пустом наименовании дополнительного реквизита пользователя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при пустом номере документа коррекции

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать пустой email

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при пустом наименовании предмета расчёта

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,10 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use JetBrains\PhpStorm\Pure;
/**
* Исключение, возникающее при наличии некорректных объектов в коллекции
*/
@@ -23,6 +26,7 @@ class InvalidEntityInCollectionException extends AtolException
* @param string $expected_class
* @param mixed $actual
*/
#[Pure]
public function __construct(string $collection_class, string $expected_class, mixed $actual)
{
if (is_object($actual)) {

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Enums\Enum;
use JetBrains\PhpStorm\Pure;
/**
* Исключение, возникающее при ошибке валидации перечислимых значений
@@ -26,14 +27,12 @@ class InvalidEnumValueException extends AtolException
* @param string $message
* @param array $ffd_tags
*/
#[Pure]
public function __construct(string $enum, mixed $value, string $message = '', array $ffd_tags = [])
{
/** @var $enum Enum */
$own_message = (
empty($value)
? "Значение из $enum не может быть пустым."
: "Некорректное значение $enum::$value."
) . " Допустимые значения: " . implode(', ', $enum::toArray());
parent::__construct($message ?: $own_message, $ffd_tags ?: $enum::getFfdTags());
$own_message = empty($value)
? "Значение $enum не может быть пустым."
: "Некорректное значение $enum::$value.";
parent::__construct($message ?: $own_message, $ffd_tags /*?: static::$ffd_tags*/);
}
}

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
/**

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке установки слишком большой суммы оплаты

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,13 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\{
Constraints,
Ffd105Tags};
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинное наименование дополнительного реквизита чека

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,13 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\{
Constraints,
Ffd105Tags};
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинное наименование дополнительного реквизита пользователя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,13 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\{
Constraints,
Ffd105Tags};
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинное значение дополнительного реквизита пользователя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке указать слишком длинный callback_url

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинное имя кассира

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинный телефон или email покупателя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинное наименование покупателя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинный email

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,13 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use JetBrains\PhpStorm\Pure;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке указать слишком длинный код товара
@@ -21,7 +20,6 @@ use JetBrains\PhpStorm\Pure;
class TooLongItemCodeException extends TooLongException
{
protected float $max = Constraints::MAX_LENGTH_ITEM_CODE;
protected array $ffd_tags = [Ffd105Tags::ITEM_NOMENCLATURE_CODE];
/**
* Конструктор
@@ -29,7 +27,6 @@ class TooLongItemCodeException extends TooLongException
* @param string $name
* @param string $code
*/
#[Pure]
public function __construct(string $name, string $code)
{
parent::__construct($code, "Слишком длинный код товара '$name'");

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,14 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\{
Constraints,
Ffd105Tags
};
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинное имя

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке указать слишком длинный логин ККТ

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинную единицу измерения предмета расчёта

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке указать слишком длинный пароль ККТ

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,14 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\{
Constraints,
Ffd105Tags
};
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинную операцию для платёжного агента

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинный адрес места расчётов

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,12 +8,12 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constants\Ffd105Tags;
use AtolOnline\Constraints;
use AtolOnline\Ffd105Tags;
/**
* Исключение, возникающее при попытке указать слишком длинный дополнительный реквизит

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,7 +8,7 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке добавить слишком много предметов расчёта в массив

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке добавить слишком много платежей в массив

View File

@@ -1,4 +1,5 @@
<?php
/*
* Copyright (c) 2020-2021 Антон Аксенов (Anthony Axenov)
*
@@ -7,11 +8,11 @@
* https://github.com/anthonyaxenov/atol-online/blob/master/LICENSE
*/
declare(strict_types = 1);
declare(strict_types=1);
namespace AtolOnline\Exceptions;
use AtolOnline\Constants\Constraints;
use AtolOnline\Constraints;
/**
* Исключение, возникающее при попытке добавить слишком много ставок НДС в документ