<?php
namespace App\Entity\Core\Textbook;
use App\Entity\User\User;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Table('textbook_session_flag')]
#[ORM\Entity]
class TextbookSessionFlag
{
/**
* @var int
*/
#[ORM\Id]
#[ORM\Column(name: 'id', type: 'integer')]
#[ORM\GeneratedValue(strategy: 'AUTO')]
private $id;
/**
* @var User
*/
#[ORM\JoinColumn(name: 'student', nullable: false)]
#[ORM\ManyToOne(targetEntity: User::class)]
private $student;
/**
* @var TextbookSession
*/
#[ORM\JoinColumn(name: 'textbook_session', nullable: false)]
#[ORM\ManyToOne(targetEntity: TextbookSession::class)]
private $textbookSession;
/**
* @var TextbookElement
*/
#[ORM\JoinColumn(name: 'textbook_element', nullable: false)]
#[ORM\ManyToOne(targetEntity: TextbookElement::class)]
private $textbookElement;
/**
* @var string
*/
#[ORM\Column(type: 'text', nullable: true)]
private $message;
public function __construct($student, $textbookSession, $textbookElement, $message)
{
$this->student = $student;
$this->textbookSession = $textbookSession;
$this->textbookElement = $textbookElement;
$this->message = $message;
}
public function getId(): int
{
return $this->id;
}
public function getTextbookElement(): TextbookElement
{
return $this->textbookElement;
}
public function getMessage(): ?string
{
return $this->message;
}
}