Media   A
last analyzed

Complexity

Total Complexity 11

Size/Duplication

Total Lines 160
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 2
Bugs 1 Features 0
Metric Value
wmc 11
c 2
b 1
f 0
lcom 0
cbo 0
dl 0
loc 160
rs 10

11 Methods

Rating   Name   Duplication   Size   Complexity  
A getId() 0 4 1
A getName() 0 4 1
A getFile() 0 4 1
A getMediableModel() 0 4 1
A getMediableId() 0 4 1
A getFileData() 0 4 1
A setFileData() 0 4 1
A setName() 0 6 1
A setFile() 0 6 1
A setMediableModel() 0 6 1
A setMediableId() 0 6 1
1
<?php
2
3
namespace Mykees\MediaBundle\Entity;
4
5
use Doctrine\ORM\Mapping as ORM;
6
7
/**
8
 * Media
9
 *
10
 * @ORM\Table()
11
 * @ORM\Entity(repositoryClass="Mykees\MediaBundle\Repository\MediaRepository")
12
 */
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()
61
    {
62
        return $this->id;
63
    }
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()
84
    {
85
        return $this->name;
86
    }
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()
107
    {
108
        return $this->file;
109
    }
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()
130
    {
131
        return $this->model;
132
    }
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()
153
    {
154
        return $this->modelId;
155
    }
156
157
    /**
158
     * @return mixed
159
     */
160
    public function getFileData()
161
    {
162
        return $this->fileData;
163
    }
164
165
    /**
166
     * @param mixed $fileData
167
     */
168
    public function setFileData($fileData)
169
    {
170
        $this->fileData = $fileData;
171
    }
172
}
173