API-3DPrint/src/Composant/User/Domain/User.php

128 lines
2.1 KiB
PHP

<?php
namespace App\Composant\User\Domain;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity, ORM\Table(name:"users")]
class User
{
#[ORM\Id, ORM\GeneratedValue(strategy: 'AUTO')]
#[ORM\Column(type:Types::INTEGER)]
private int $id;
#[ORM\Column(type:Types::STRING, length:255)]
private string $lastname;
private string $firstname;
private int $roleId;
private float $kwhPrice;
private float $hourlyCost;
public function __construct()
{
}
/**
* @return float
*/
public function getKwhPrice(): float
{
return $this->kwhPrice;
}
/**
* @param float $kwhPrice
*/
public function setKwhPrice(float $kwhPrice): void
{
$this->kwhPrice = $kwhPrice;
}
/**
* @return float
*/
public function getHourlyCost(): float
{
return $this->hourlyCost;
}
/**
* @param float $hourlyCost
*/
public function setHourlyCost(float $hourlyCost): void
{
$this->hourlyCost = $hourlyCost;
}
/**
* @return int
*/
public function getRoleId(): int
{
return $this->roleId;
}
/**
* @param int $roleId
*/
public function setRoleId(int $roleId): void
{
$this->roleId = $roleId;
}
/**
* @return string
*/
public function getLastname(): string
{
return $this->lastname;
}
/**
* @param string $lastname
*/
public function setLastname(string $lastname): void
{
$this->lastname = $lastname;
}
/**
* @return string
*/
public function getFirstname(): string
{
return $this->firstname;
}
/**
* @param string $firstname
*/
public function setFirstname(string $firstname): void
{
$this->firstname = $firstname;
}
/**
* @return int
*/
public function getId(): int
{
return $this->id;
}
/**
* @param int $id
*/
public function setId(int $id): void
{
$this->id = $id;
}
}