Completed
Push — develop ( b182bc...7df659 )
by
unknown
10s
created

PreferredJob   A

Complexity

Total Complexity 13

Size/Duplication

Total Lines 122
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 3
Bugs 0 Features 1
Metric Value
wmc 13
lcom 0
cbo 2
dl 0
loc 122
rs 10
c 3
b 0
f 1

13 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A setTypeOfApplication() 0 5 1
A getTypeOfApplication() 0 4 1
A setDesiredJob() 0 5 1
A getDesiredJob() 0 4 1
A setDesiredLocation() 0 5 1
A getDesiredLocation() 0 4 1
A setDesiredLocations() 0 5 1
A getDesiredLocations() 0 4 1
A setWillingnessToTravel() 0 5 1
A getWillingnessToTravel() 0 4 1
A setExpectedSalary() 0 5 1
A getExpectedSalary() 0 4 1
1
<?php
2
/**
3
 * YAWIK
4
 *
5
 * @filesource
6
 * @copyright (c) 2013 - 2016 Cross Solution (http://cross-solution.de)
7
 * @license   MIT
8
 */
9
10
namespace Cv\Entity;
11
12
use Core\Entity\AbstractIdentifiableEntity;
13
use Doctrine\Common\Collections\ArrayCollection;
14
use Doctrine\Common\Collections\Collection;
15
use Doctrine\ODM\MongoDB\Mapping\Annotations as ODM;
16
17
/**
18
 * @ODM\EmbeddedDocument
19
 */
20
class PreferredJob extends AbstractIdentifiableEntity implements PreferredJobInterface
21
{
22
    /**
23
     * @var array
24
     * @ODM\Collection
25
     */
26
    protected $typeOfApplication = array();
27
28
    /**
29
     * @var string
30
     * @ODM\Field(type="string")
31
     */
32
    protected $desiredJob;
33
    
34
    /**
35
     * @var string
36
     * @ODM\Field(type="string")
37
     **/
38
    protected $desiredLocation;
39
40
    /**
41
     * @var Collection
42
     * @ODM\EmbedMany(targetDocument="\Cv\Entity\Location")
43
     **/
44
    protected $desiredLocations;
45
46
47
    /**
48
     * willingness to travel,
49
     *
50
     * yes, no, bedingt
51
     *
52
     * @ODM\Field(type="string") */
53
    protected $willingnessToTravel;
54
55
56
    /** expectedSalary
57
     * @ODM\Field(type="string") */
58
    protected $expectedSalary;
59
60
    public function __construct()
61
    {
62
        $this->desiredLocations = new ArrayCollection();
63
    }
64
65
    /**
66
     * Apply for a job, internship or studies
67
     *
68
     * @param   array $typeOfApplication
69
     * @return  $this
70
     */
71
    public function setTypeOfApplication(array $typeOfApplication)
72
    {
73
        $this->typeOfApplication = $typeOfApplication;
74
        return $this;
75
    }
76
77
    /**
78
     * Gets the type of an Application
79
     *
80
     * @return array
81
     */
82
    public function getTypeOfApplication()
83
    {
84
        return $this->typeOfApplication;
85
    }
86
    
87
    public function setDesiredJob($desiredJob)
88
    {
89
        $this->desiredJob=$desiredJob;
90
        return $this;
91
    }
92
    
93
    public function getDesiredJob()
94
    {
95
        return $this->desiredJob;
96
    }
97
98
    public function setDesiredLocation($desiredLocation)
99
    {
100
        $this->desiredLocation=$desiredLocation;
101
        return $this;
102
    }
103
104
    public function getDesiredLocation()
105
    {
106
        return $this->desiredLocation;
107
    }
108
109
    public function setDesiredLocations(Collection $desiredLocations)
110
    {
111
        $this->desiredLocation = $desiredLocations;
0 ignored issues
show
Documentation Bug introduced by
It seems like $desiredLocations of type object<Doctrine\Common\Collections\Collection> is incompatible with the declared type string of property $desiredLocation.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
112
        return $this;
113
    }
114
115
    public function getDesiredLocations()
116
    {
117
        return $this->desiredLocations;
118
    }
119
    
120
    public function setWillingnessToTravel($willingnessToTravel)
121
    {
122
        $this->willingnessToTravel=$willingnessToTravel;
123
        return $this;
124
    }
125
    
126
    public function getWillingnessToTravel()
127
    {
128
        return $this->willingnessToTravel;
129
    }
130
131
    public function setExpectedSalary($expectedSalary)
132
    {
133
        $this->expectedSalary=$expectedSalary;
134
        return $this;
135
    }
136
137
    public function getExpectedSalary()
138
    {
139
        return $this->expectedSalary;
140
    }
141
}
142