2021-06-16 18:41:05 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Core\Entity;
|
|
|
|
|
|
|
|
use App\Repository\Entity\FileInformationRepository;
|
|
|
|
use Doctrine\ORM\Mapping as ORM;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @ORM\Entity(repositoryClass=FileInformationRepository::class)
|
|
|
|
*/
|
|
|
|
class FileInformation implements EntityInterface
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* @ORM\Id
|
|
|
|
* @ORM\GeneratedValue(strategy="NONE")
|
2021-06-22 11:46:05 +02:00
|
|
|
* @ORM\Column(type="string", length=96, unique=true)
|
2021-06-16 18:41:05 +02:00
|
|
|
*/
|
|
|
|
protected $id;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @ORM\Column(type="text", nullable=true)
|
|
|
|
*/
|
|
|
|
protected $attributes;
|
|
|
|
|
|
|
|
public function getId(): ?string
|
|
|
|
{
|
|
|
|
return $this->id;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function setId(string $id): self
|
|
|
|
{
|
|
|
|
$this->id = $id;
|
|
|
|
|
|
|
|
return $this;
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getAttributes()
|
|
|
|
{
|
2021-09-09 13:57:54 +02:00
|
|
|
return (array) json_decode($this->attributes, true);
|
2021-06-16 18:41:05 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
public function setAttributes($attributes): self
|
|
|
|
{
|
|
|
|
$this->attributes = json_encode($attributes);
|
|
|
|
|
|
|
|
return $this;
|
|
|
|
}
|
|
|
|
}
|