*/ #[ORM\OneToMany(targetEntity: MovieRole::class, mappedBy: 'actor')] private Collection $movieRoles; #[ORM\Column(nullable: true)] private ?int $tmdbId = null; #[ORM\Column(options: ['default' => false])] private bool $awardsImported = false; /** @var Collection */ #[ORM\OneToMany(targetEntity: Award::class, mappedBy: 'actor')] private Collection $awards; public function __construct() { $this->movieRoles = new ArrayCollection(); $this->awards = new ArrayCollection(); } public function getId(): ?int { return $this->id; } public function getName(): string { return $this->name; } public function setName(string $name): static { $this->name = $name; return $this; } public function getPopularity(): ?float { return $this->popularity; } public function setPopularity(?float $popularity): static { $this->popularity = $popularity; return $this; } /** * @return Collection */ public function getMovieRoles(): Collection { return $this->movieRoles; } public function addMovieRole(MovieRole $movieRole): static { if (!$this->movieRoles->contains($movieRole)) { $this->movieRoles->add($movieRole); $movieRole->setActor($this); } return $this; } public function removeMovieRole(MovieRole $movieRole): static { if ($this->movieRoles->removeElement($movieRole)) { // set the owning side to null (unless already changed) if ($movieRole->getActor() === $this) { $movieRole->setActor(null); } } return $this; } public function getTmdbId(): ?int { return $this->tmdbId; } public function setTmdbId(?int $tmdbId): static { $this->tmdbId = $tmdbId; return $this; } public function isAwardsImported(): bool { return $this->awardsImported; } public function setAwardsImported(bool $awardsImported): static { $this->awardsImported = $awardsImported; return $this; } /** @return Collection */ public function getAwards(): Collection { return $this->awards; } }