<?php

declare(strict_types=1);

/*
 * This file is part of the Ferienpass package.
 *
 * (c) Richard Henkenjohann <richard@ferienpass.online>
 *
 * For more information visit the project website <https://ferienpass.online>
 * or the documentation under <https://docs.ferienpass.online>.
 */

namespace Ferienpass\CoreBundle\Entity\Participant;

use Doctrine\Common\Collections\Collection;
use Ferienpass\CoreBundle\Entity\AccessCode;
use Ferienpass\CoreBundle\Entity\Attendance;
use Ferienpass\CoreBundle\Entity\Consent;
use Ferienpass\CoreBundle\Entity\Edition;
use Ferienpass\CoreBundle\Entity\FriendCode;
use Ferienpass\CoreBundle\Entity\ParticipantLog;
use Ferienpass\CoreBundle\Entity\User;
use Symfony\Component\Uid\Uuid;

interface ParticipantInterface
{
    public function getId(): ?int;

    public function getUuid(): Uuid;

    public function getName(): string;

    public function getFirstname(): ?string;

    public function getLastname(): ?string;

    public function getDateOfBirth(): ?\DateTimeInterface;

    public function getAge(?\DateTimeInterface $atDate = null): ?int;

    public function getUser(): ?User;

    /** @var Collection<int, Attendance> */
    public function getAttendances(): Collection;

    public function addAttendance(Attendance $attendance): void;

    public function removeAttendance(Attendance $attendance): void;

    /** @var Collection<int, ParticipantLog> */
    public function getActivity(): Collection;

    public function addActivity(ParticipantLog $log): void;

    public function removeActivity(ParticipantLog $log): void;

    /** @var Collection<int, Consent> */
    public function getConsents(): Collection;

    public function addConsent(Consent $consent): void;

    public function removeConsent(Consent $consent): void;

    /** @var Collection<int, Attendance> */
    public function getAttendancesNotWithdrawn(?Edition $edition = null, $includedCancelled = true): Collection;

    /** @var Collection<int, Attendance> */
    public function getAttendancesNotHidden(?Edition $edition = null, $includedCancelled = true): Collection;

    /** @var Collection<int, FriendCode> */
    public function getFriendCodes(): Collection;

    public function addFriendCode(?FriendCode $code): void;

    public function removeFriendCode(FriendCode $code): void;

    /** @var Collection<int, AccessCode> */
    public function getAccessCodes(): Collection;

    public function addAccessCode(?AccessCode $code): void;

    public function removeAccessCode(AccessCode $code): void;

    public function addDuplicate(self $duplicate, string $type): void;

    public function getPostalCode(): ?string;

    public function getEmail(): ?string;

    public function getMobile(): ?string;

    public function getPhone(): ?string;
}
