<?php declare(strict_types=1);

namespace API\Batch;

use Helpers\Trad\ITrad;
use PDO;
use Psr\Container\ContainerInterface;
use Psr\Http\Message\ServerRequestInterface;
use Skeleton\Router;

abstract class BatchDefault
{
    public function __construct(
        protected ContainerInterface $contenaire,
        protected PDO $pdo,
        protected ServerRequestInterface $request,
        protected ITrad $trad,
        protected Router $router
    ) {
    }

    /**
     * Summary of getParsedBody
     * @return array<mixed>
     */
    protected function getParsedBody(): array
    {
        return (array) $this->request->getParsedBody();
    }
}
