Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // src/Product.php
- namespace App\Entity;
- use Doctrine\ORM\Mapping as ORM;
- /**
- * @ORM\Entity
- * @ORM\Table(name="products")
- */
- class Product
- {
- /**
- * @ORM\Id
- * @ORM\Column(type="integer")
- * @ORM\GeneratedValue
- */
- protected $id;
- /**
- * @ORM\Column(type="string")
- */
- protected $name;
- // .. (other code)
- public function getId()
- {
- return $this->id;
- }
- public function getName()
- {
- return $this->name;
- }
- public function setName($name)
- {
- $this->name = $name;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment