<?php

/**
 * Class GetReturnByWaybill
 *
 * @package Octolize\DhlPolska\API\WebApi\Method
 */
namespace DhlPolskaVendor\Octolize\DhlPolska\API\WebApi\Method;

use DhlPolskaVendor\Octolize\DhlPolska\API\AuthDataInterface;
use DhlPolskaVendor\Octolize\DhlPolska\API\WebApi\Struct\ReturnItemToPrint;
use JsonSerializable;
/**
 * GetReturnByWaybill structure.
 */
class GetReturnByWaybill implements JsonSerializable
{
    /**
     * @var AuthDataInterface
     */
    private AuthDataInterface $auth_data;
    /**
     * @var ReturnItemToPrint[]
     */
    private array $items_to_print;
    /**
     * GetReturnByWaybill constructor.
     *
     * @param AuthDataInterface   $auth_data      .
     * @param ReturnItemToPrint[] $items_to_print .
     */
    public function __construct(AuthDataInterface $auth_data, array $items_to_print)
    {
        $this->auth_data = $auth_data;
        $this->items_to_print = $items_to_print;
    }
    /**
     * @return array
     */
    public function jsonSerialize(): array
    {
        return ['authData' => $this->auth_data, 'itemsToPrint' => $this->items_to_print];
    }
}
