Location.php 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <?php
  2. namespace MapBundle\Entity;
  3. use Doctrine\ORM\Mapping as ORM;
  4. use ExtraDataBundle\Entity\Traits\ExtraDataTrait;
  5. /**
  6. * @ORM\Table
  7. * @ORM\Entity
  8. */
  9. class Location
  10. {
  11. use ExtraDataTrait;
  12. /**
  13. * @var int
  14. *
  15. * @ORM\Column(name="id", type="integer")
  16. * @ORM\Id
  17. * @ORM\GeneratedValue(strategy="AUTO")
  18. */
  19. private $id;
  20. /**
  21. * @var int
  22. *
  23. * @ORM\Column(type="integer", nullable=true)
  24. */
  25. private $mapId;
  26. /**
  27. * @var int
  28. *
  29. * @ORM\Column(type="integer", nullable=true)
  30. */
  31. private $objectTypeId;
  32. /**
  33. * @return string
  34. */
  35. public function getData()
  36. {
  37. return array(
  38. 'mapId' => $this->mapId,
  39. 'extraData' => $this->jsonExtraData(),
  40. );
  41. }
  42. /**
  43. * Get id
  44. *
  45. * @return int
  46. */
  47. public function getId()
  48. {
  49. return $this->id;
  50. }
  51. /**
  52. * Set mapId
  53. *
  54. * @param integer $mapId
  55. *
  56. * @return Location
  57. */
  58. public function setMapId($mapId = null)
  59. {
  60. $this->mapId = $mapId;
  61. return $this;
  62. }
  63. /**
  64. * Get mapId
  65. *
  66. * @return int
  67. */
  68. public function getMapId()
  69. {
  70. return $this->mapId;
  71. }
  72. /**
  73. * Set objectTypeId
  74. *
  75. * @param integer $objectTypeId
  76. *
  77. * @return Location
  78. */
  79. public function setObjectTypeId($objectTypeId = null)
  80. {
  81. $this->objectTypeId = $objectTypeId;
  82. return $this;
  83. }
  84. /**
  85. * Get objectTypeId
  86. *
  87. * @return int
  88. */
  89. public function getObjectTypeId()
  90. {
  91. return $this->objectTypeId;
  92. }
  93. }