| 1 | <?php |
||
| 13 | class Media |
||
| 14 | { |
||
| 15 | /** |
||
| 16 | * @var integer |
||
| 17 | * |
||
| 18 | * @ORM\Column(name="id", type="integer") |
||
| 19 | * @ORM\Id |
||
| 20 | * @ORM\GeneratedValue(strategy="AUTO") |
||
| 21 | */ |
||
| 22 | private $id; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @var string |
||
| 26 | * |
||
| 27 | * @ORM\Column(name="name", type="string", length=255) |
||
| 28 | */ |
||
| 29 | private $name; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * @var string |
||
| 33 | * |
||
| 34 | * @ORM\Column(name="file", type="string", length=255) |
||
| 35 | */ |
||
| 36 | private $file; |
||
| 37 | |||
| 38 | /** |
||
| 39 | * @var string |
||
| 40 | * |
||
| 41 | * @ORM\Column(name="model", type="string", length=80) |
||
| 42 | */ |
||
| 43 | private $model; |
||
| 44 | |||
| 45 | /** |
||
| 46 | * @var integer |
||
| 47 | * |
||
| 48 | * @ORM\Column(name="model_id", type="integer") |
||
| 49 | */ |
||
| 50 | private $modelId; |
||
| 51 | |||
| 52 | private $fileData; |
||
| 53 | |||
| 54 | |||
| 55 | /** |
||
| 56 | * Get id |
||
| 57 | * |
||
| 58 | * @return integer |
||
| 59 | */ |
||
| 60 | public function getId() |
||
| 64 | |||
| 65 | /** |
||
| 66 | * Set name |
||
| 67 | * |
||
| 68 | * @param string $name |
||
| 69 | * @return Media |
||
| 70 | */ |
||
| 71 | public function setName($name) |
||
| 72 | { |
||
| 73 | $this->name = $name; |
||
| 74 | |||
| 75 | return $this; |
||
| 76 | } |
||
| 77 | |||
| 78 | /** |
||
| 79 | * Get name |
||
| 80 | * |
||
| 81 | * @return string |
||
| 82 | */ |
||
| 83 | public function getName() |
||
| 87 | |||
| 88 | /** |
||
| 89 | * Set file |
||
| 90 | * |
||
| 91 | * @param string $file |
||
| 92 | * @return Media |
||
| 93 | */ |
||
| 94 | public function setFile($file) |
||
| 95 | { |
||
| 96 | $this->file = $file; |
||
| 97 | |||
| 98 | return $this; |
||
| 99 | } |
||
| 100 | |||
| 101 | /** |
||
| 102 | * Get file |
||
| 103 | * |
||
| 104 | * @return string |
||
| 105 | */ |
||
| 106 | public function getFile() |
||
| 110 | |||
| 111 | /** |
||
| 112 | * Set model |
||
| 113 | * |
||
| 114 | * @param string $model |
||
| 115 | * @return Media |
||
| 116 | */ |
||
| 117 | public function setMediableModel($model) |
||
| 118 | { |
||
| 119 | $this->model = $model; |
||
| 120 | |||
| 121 | return $this; |
||
| 122 | } |
||
| 123 | |||
| 124 | /** |
||
| 125 | * Get model |
||
| 126 | * |
||
| 127 | * @return string |
||
| 128 | */ |
||
| 129 | public function getMediableModel() |
||
| 133 | |||
| 134 | /** |
||
| 135 | * Set modelId |
||
| 136 | * |
||
| 137 | * @param integer $modelId |
||
| 138 | * @return Media |
||
| 139 | */ |
||
| 140 | public function setMediableId($modelId) |
||
| 141 | { |
||
| 142 | $this->modelId = $modelId; |
||
| 143 | |||
| 144 | return $this; |
||
| 145 | } |
||
| 146 | |||
| 147 | /** |
||
| 148 | * Get modelId |
||
| 149 | * |
||
| 150 | * @return integer |
||
| 151 | */ |
||
| 152 | public function getMediableId() |
||
| 156 | |||
| 157 | /** |
||
| 158 | * @return mixed |
||
| 159 | */ |
||
| 160 | public function getFileData() |
||
| 164 | |||
| 165 | /** |
||
| 166 | * @param mixed $fileData |
||
| 167 | */ |
||
| 168 | public function setFileData($fileData) |
||
| 172 | } |
||
| 173 |