parent
5deb30eefe
commit
57c6e07617
@ -0,0 +1,132 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Entity;
|
||||||
|
|
||||||
|
use App\Repository\EmojiRepository;
|
||||||
|
use Doctrine\ORM\Mapping as ORM;
|
||||||
|
|
||||||
|
#[ORM\Entity(repositoryClass: EmojiRepository::class)]
|
||||||
|
class Emoji
|
||||||
|
{
|
||||||
|
#[ORM\Id]
|
||||||
|
#[ORM\GeneratedValue]
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?int $id = null;
|
||||||
|
|
||||||
|
#[ORM\Column(length: 255)]
|
||||||
|
private ?string $nom = null;
|
||||||
|
|
||||||
|
#[ORM\Column(length: 255)]
|
||||||
|
private ?string $code = null;
|
||||||
|
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?float $force = null;
|
||||||
|
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?float $robustesse = null;
|
||||||
|
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?float $intelligence = null;
|
||||||
|
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?float $vitesse = null;
|
||||||
|
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?int $nbCombatGagne = null;
|
||||||
|
|
||||||
|
#[ORM\Column]
|
||||||
|
private ?int $rarete = null;
|
||||||
|
|
||||||
|
public function getId(): ?int
|
||||||
|
{
|
||||||
|
return $this->id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getNom(): ?string
|
||||||
|
{
|
||||||
|
return $this->nom;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setNom(string $nom): self
|
||||||
|
{
|
||||||
|
$this->nom = $nom;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getCode(): ?string
|
||||||
|
{
|
||||||
|
return $this->code;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setCode(string $code): self
|
||||||
|
{
|
||||||
|
$this->code = $code;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getForce(): ?float
|
||||||
|
{
|
||||||
|
return $this->force;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setForce(float $force): self
|
||||||
|
{
|
||||||
|
$this->force = $force;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getRobustesse(): ?float
|
||||||
|
{
|
||||||
|
return $this->robustesse;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setRobustesse(float $robustesse): self
|
||||||
|
{
|
||||||
|
$this->robustesse = $robustesse;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getIntelligence(): ?float
|
||||||
|
{
|
||||||
|
return $this->intelligence;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setIntelligence(float $intelligence): self
|
||||||
|
{
|
||||||
|
$this->intelligence = $intelligence;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getVitesse(): ?float
|
||||||
|
{
|
||||||
|
return $this->vitesse;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setVitesse(float $vitesse): self
|
||||||
|
{
|
||||||
|
$this->vitesse = $vitesse;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getNbCombatGagne(): ?int
|
||||||
|
{
|
||||||
|
return $this->nbCombatGagne;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setNbCombatGagne(int $nbCombatGagne): self
|
||||||
|
{
|
||||||
|
$this->nbCombatGagne = $nbCombatGagne;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getRarete(): ?int
|
||||||
|
{
|
||||||
|
return $this->rarete;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setRarete(int $rarete): self
|
||||||
|
{
|
||||||
|
$this->rarete = $rarete;
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,48 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Repository;
|
||||||
|
|
||||||
|
use App\Entity\Emoji;
|
||||||
|
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
|
||||||
|
use Doctrine\Persistence\ManagerRegistry;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @extends ServiceEntityRepository<Emoji>
|
||||||
|
*
|
||||||
|
* @method Emoji|null find($id, $lockMode = null, $lockVersion = null)
|
||||||
|
* @method Emoji|null findOneBy(array $criteria, array $orderBy = null)
|
||||||
|
* @method Emoji[] findAll()
|
||||||
|
* @method Emoji[] findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null)
|
||||||
|
*/
|
||||||
|
class EmojiRepository extends ServiceEntityRepository
|
||||||
|
{
|
||||||
|
public function __construct(ManagerRegistry $registry)
|
||||||
|
{
|
||||||
|
parent::__construct($registry, Emoji::class);
|
||||||
|
}
|
||||||
|
|
||||||
|
// /**
|
||||||
|
// * @return Emoji[] Returns an array of Emoji objects
|
||||||
|
// */
|
||||||
|
// public function findByExampleField($value): array
|
||||||
|
// {
|
||||||
|
// return $this->createQueryBuilder('e')
|
||||||
|
// ->andWhere('e.exampleField = :val')
|
||||||
|
// ->setParameter('val', $value)
|
||||||
|
// ->orderBy('e.id', 'ASC')
|
||||||
|
// ->setMaxResults(10)
|
||||||
|
// ->getQuery()
|
||||||
|
// ->getResult()
|
||||||
|
// ;
|
||||||
|
// }
|
||||||
|
|
||||||
|
// public function findOneBySomeField($value): ?Emoji
|
||||||
|
// {
|
||||||
|
// return $this->createQueryBuilder('e')
|
||||||
|
// ->andWhere('e.exampleField = :val')
|
||||||
|
// ->setParameter('val', $value)
|
||||||
|
// ->getQuery()
|
||||||
|
// ->getOneOrNullResult()
|
||||||
|
// ;
|
||||||
|
// }
|
||||||
|
}
|
Loading…
Reference in new issue