user = $user; $this->teamId = $teamId; $this->role = $role; } /** * @return string */ public function getRole(): string { return $this->role; } /** * @return int */ public function getTeamId(): int { return $this->teamId; } /** * @return User */ public function getUser(): User { return $this->user; } public function jsonSerialize() { return get_object_vars($this); } }