src/CourseBundle/Entity/CChatConversation.php
<?php
declare(strict_types=1);
/* For licensing terms, see /license.txt */
namespace Chamilo\CourseBundle\Entity;
use Chamilo\CoreBundle\Entity\AbstractResource;
use Chamilo\CoreBundle\Entity\ResourceInterface;
use Chamilo\CourseBundle\Repository\CChatConversationRepository;
use Doctrine\ORM\Mapping as ORM;
use Stringable;
/**
* CChatConversation.
*/
#[ORM\Table(name: 'c_chat_conversation')]
#[ORM\Entity(repositoryClass: CChatConversationRepository::class)]
class CChatConversation extends AbstractResource implements ResourceInterface, Stringable
{
#[ORM\Column(name: 'id', type: 'integer')]
#[ORM\Id]
#[ORM\GeneratedValue]
protected ?int $id = null;
#[ORM\Column(name: 'title', type: 'string', length: 255, nullable: true)]
protected ?string $title = null;
public function __toString(): string
{
return $this->getTitle();
}
public function getId(): int
{
return $this->id;
}
public function getTitle(): string
{
return $this->title;
}
public function setTitle(string $title): self
{
$this->title = $title;
return $this;
}
/**
* Resource identifier.
*/
public function getResourceIdentifier(): int
{
return $this->getId();
}
public function getResourceName(): string
{
return $this->getTitle();
}
public function setResourceName(string $name): self
{
return $this->setTitle($name);
}
}