<?php


namespace App\Entities\PetCliente;

use App\Utils\Builder;

class PetClienteBuilder implements Builder
{
    private $id;
    private $id_pet;
    private $id_cliente;

    /**
     * @param mixed $id
     * @return PetClienteBuilder
     */
    public function setId($id)
    {
        $this->id = $id;
        return $this;
    }

    /**
     * @param mixed $id_pet
     * @return PetClienteBuilder
     */
    public function setIdPet($id_pet)
    {
        $this->id_pet = $id_pet;
        return $this;
    }

    /**
     * @param mixed $id_cliente
     * @return PetClienteBuilder
     */
    public function setIdCliente($id_cliente)
    {
        $this->id_cliente = $id_cliente;
        return $this;
    }

    public function build() : PetCliente
    {
        $assistente = new PetCliente();
        if (isset($this->id)) {
            $assistente->setId($this->id);
        }
        if (isset($this->id_pet)) {
            $assistente->setIdPet($this->id_pet);
        }
        if (isset($this->id_cliente)) {
            $assistente->setIdCliente($this->id_cliente);
        }

        return $assistente;
    }

}