<?php

namespace App\Classes\Modules\Jobs\DataTransferObjects;

use App\Classes\General\Interfaces\DataTransferObject;

class ListGenericJobObject implements DataTransferObject
{
    /** @var string */
    private $name;

    /** @var array */
    private $payload;

    /** @var string */
    private $jobId;

    /** @var string */
    private $requestSignature;

    /** @var string */
    private $resultSignature;

    /** @var object */
    private $userInfo;

    /** @var string */
    private $jobCommandName;

    /** @var string */
    private $jobCommand;

    public function __construct(string $name, array $payload, string $requestSignature, ?string $resultSignature, string $jobId, object $userInfo = null)
    {
        $this->name = $name;
        $this->payload = $payload;
        $this->jobId = $jobId;
        $this->requestSignature = $requestSignature;
        $this->resultSignature = $resultSignature;
        $this->userInfo = $userInfo;
    }

    /**
     * @return string
     */
    public function getName(): string
    {
        return $this->name;
    }

    /**
     * @return array
     */
    public function getPayload(): array
    {
        return $this->payload;
    }

    /**
     * @return string
     */
    public function getJobId(): string
    {
        return $this->jobId;
    }

    /**
     * @return string
     */
    public function getRequestSignature(): string
    {
        return $this->requestSignature;
    }

    /**
     * @return string
     */
    public function getResultSignature(): ?string
    {
        return $this->resultSignature;
    }

    /**
     * @return object
     */
    public function getUserInfo(): object
    {
        return $this->userInfo;
    }

    /**
     * @return string
     */
    public function getJobCommandName(): string
    {
        return $this->jobCommandName;
    }

    /**
     * @return string
     */
    public function getJobCommand(): string
    {
        return $this->jobCommand;
    }


    public function setJobCommandName(string $jobCommandName)
    {
        $this->jobCommandName = $jobCommandName;
    }

    public function setJobCommand(string $jobCommand)
    {
        $this->jobCommand = $jobCommand;
    }

}
