src/Entity/RecipeIngredients.php line 18

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * RecipeIngredients
  6.  *
  7.  * @ORM\Table(name="recipe_ingredients", indexes={
  8.  *     @ORM\Index(name="recipe_id", columns={"recipe_id"}),
  9.  *     @ORM\Index(name="ingredient_id", columns={"ingredient_id"}),
  10.  *     @ORM\Index(name="quantity", columns={"quantity"}),
  11.  *     @ORM\Index(name="removed", columns={"removed"})
  12.  * })
  13.  * @ORM\Entity(repositoryClass="App\Repository\RecipeIngredientsRepository")
  14.  */
  15. class RecipeIngredients
  16. {
  17.     /**
  18.      * @var int
  19.      *
  20.      * @ORM\Column(name="id", type="integer", options={"unsigned"=true})
  21.      * @ORM\Id
  22.      * @ORM\GeneratedValue(strategy="AUTO")
  23.      */
  24.     private $id;
  25.     /**
  26.      * @var int
  27.      *
  28.      * @ORM\Column(name="recipe_id", type="integer", options={"unsigned"=true})
  29.      */
  30.     private $recipeId;
  31.     /**
  32.      * @var int
  33.      *
  34.      * @ORM\Column(name="ingredient_id", type="integer", options={"unsigned"=true})
  35.      */
  36.     private $ingredientId;
  37.     /**
  38.      * @var int
  39.      *
  40.      * @ORM\Column(name="quantity", type="float", options={"unsigned"=true})
  41.      */
  42.     private $quantity;
  43.     /**
  44.      * @var bool
  45.      *
  46.      * @ORM\Column(name="removed", type="boolean", options={"default" : false})
  47.      */
  48.     private $removed;
  49.     /**
  50.      * Get id
  51.      *
  52.      * @return int
  53.      */
  54.     public function getId()
  55.     {
  56.         return $this->id;
  57.     }
  58.     /**
  59.      * Set recipeId
  60.      *
  61.      * @param integer $recipeId
  62.      *
  63.      * @return RecipeIngredients
  64.      */
  65.     public function setRecipeId($recipeId)
  66.     {
  67.         $this->recipeId $recipeId;
  68.         return $this;
  69.     }
  70.     /**
  71.      * Get recipeId
  72.      *
  73.      * @return int
  74.      */
  75.     public function getRecipeId()
  76.     {
  77.         return $this->recipeId;
  78.     }
  79.     /**
  80.      * Set ingredientId
  81.      *
  82.      * @param integer $ingredientId
  83.      *
  84.      * @return RecipeIngredients
  85.      */
  86.     public function setIngredientId($ingredientId)
  87.     {
  88.         $this->ingredientId $ingredientId;
  89.         return $this;
  90.     }
  91.     /**
  92.      * Get ingredientId
  93.      *
  94.      * @return int
  95.      */
  96.     public function getIngredientId()
  97.     {
  98.         return $this->ingredientId;
  99.     }
  100.     /**
  101.      * Set quantity
  102.      *
  103.      * @param integer $quantity
  104.      *
  105.      * @return RecipeIngredients
  106.      */
  107.     public function setQuantity($quantity)
  108.     {
  109.         $this->quantity $quantity;
  110.         return $this;
  111.     }
  112.     /**
  113.      * Get quantity
  114.      *
  115.      * @return int
  116.      */
  117.     public function getQuantity()
  118.     {
  119.         return $this->quantity;
  120.     }
  121.     /**
  122.      * Set removed
  123.      *
  124.      * @param boolean $removed
  125.      *
  126.      * @return RecipeIngredients
  127.      */
  128.     public function setRemoved($removed)
  129.     {
  130.         $this->removed $removed;
  131.         return $this;
  132.     }
  133.     /**
  134.      * Get removed
  135.      *
  136.      * @return bool
  137.      */
  138.     public function getRemoved()
  139.     {
  140.         return $this->removed;
  141.     }
  142. }