<?php
namespace App\Entity;
use App\Repository\CompteurRepository;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity(repositoryClass=CompteurRepository::class)
*/
class Compteur
{
/**
* @ORM\Id
* @ORM\GeneratedValue
* @ORM\Column(type="integer")
*/
private $id;
/**
* @ORM\Column(type="string", length=255)
*/
private $icon;
/**
* @ORM\Column(type="integer")
*/
private $chiffre;
/**
* @ORM\Column(type="text")
*/
private $texte;
public function getId(): ?int
{
return $this->id;
}
public function getIcon(): ?string
{
return $this->icon;
}
public function setIcon(string $icon): self
{
$vars = explode('/',$icon);
if(isset($vars[4])){
$vars[4] = 80;
}
$icon = implode('/',$vars);
$this->icon = $icon;
return $this;
}
public function getChiffre(): ?int
{
return $this->chiffre;
}
public function setChiffre(int $chiffre): self
{
$this->chiffre = $chiffre;
return $this;
}
public function getTexte(): ?string
{
return $this->texte;
}
public function setTexte(string $texte): self
{
$this->texte = $texte;
return $this;
}
}