Code Duplication    Length = 78-78 lines in 2 locations

src/API/Model/NumericBoost.php 1 location

@@ 5-82 (lines=78) @@
2
3
namespace GroupByInc\API\Model;
4
5
class NumericBoost
6
{
7
  /**
8
   * @var string
9
   */
10
  private $name;
11
12
  /**
13
   * @var boolean
14
   */
15
  private $inverted;
16
17
  /**
18
   * @var double
19
   */
20
  private $strength = 1.0;
21
22
  /**
23
   * @return string The name of this Numeric Boost
24
   */
25
  public function getName()
26
  {
27
    return $this->name;
28
  }
29
30
  /**
31
   * Set the name of this Numeric Boost
32
   *
33
   * @param $name   string to be the name of this Numeric Boost
34
   * @return        NumericBoost
35
   */
36
  public function setName($name)
37
  {
38
    $this->name = $name;
39
    return $this;
40
  }
41
42
  /**
43
   * @return boolean Whether this is an inverted Numeric Boost
44
   */
45
  public function isInverted()
46
  {
47
    return $this->inverted;
48
  }
49
50
  /**
51
   * Set this Numeric Boost to inverted
52
   *
53
   * @param $inverted    boolean True if this is to be an iverted Numeric Boost, false otherwise
54
   * @return             NumericBoost
55
   */
56
  public function setInverted($inverted)
57
  {
58
    $this->inverted = $inverted;
59
    return $this;
60
  }
61
62
  /**
63
   * @return double The strength of this Numeric Boost
64
   */
65
  public function getStrength()
66
  {
67
    return $this->strength;
68
  }
69
70
  /**
71
   * Set the strength of this Numeric Boost
72
   *
73
   * @param $strength  double value to be the strength of this Numeric Boost
74
   * @return        NumericBoost
75
   */
76
  public function setStrength($strength)
77
  {
78
    $this->strength = $strength;
79
    return $this;
80
  }
81
82
}

src/API/Request/NumericBoost.php 1 location

@@ 7-84 (lines=78) @@
4
5
use JMS\Serializer\Annotation as JMS;
6
7
class NumericBoost
8
{
9
  /**
10
   * @var string
11
   * @JMS\Type("string")
12
   */
13
  private $name;
14
15
  /**
16
   * @var boolean
17
   * @JMS\Type("boolean")
18
   */
19
  private $inverted;
20
21
  /**
22
   * @var double
23
   * @JMS\Type("double")
24
   */
25
  private $strength = 1.0;
26
27
  /**
28
   * @return string The name of this Numeric Boost
29
   */
30
  public function getName()
31
  {
32
    return $this->name;
33
  }
34
35
  /**
36
   * Set the name of this Numeric Boost
37
   *
38
   * @param $name    string to be the name of this Numeric Boost
39
   * @return        NumericBoost
40
   */
41
  public function setName($name)
42
  {
43
    $this->name = $name;
44
    return $this;
45
  }
46
47
  /**
48
   * @return boolean Whether this is an inverted Numeric Boost
49
   */
50
  public function isInverted()
51
  {
52
    return $this->inverted;
53
  }
54
55
  /**
56
   * Set this Numeric Boost to inverted
57
   *
58
   * @param $inverted    boolean True if this is to be an iverted Numeric Boost, false otherwise
59
   * @return            NumericBoost
60
   */
61
  public function setInverted($inverted)
62
  {
63
    $this->inverted = $inverted;
64
    return $this;
65
  }
66
67
  /**
68
   * @return double The strength of this Numeric Boost
69
   */
70
  public function getStrength()
71
  {
72
    return $this->strength;
73
  }
74
75
  /**
76
   * Set the strength of this Numeric Boost
77
   *
78
   * @param $strength  double value to be the strength of this Numeric Boost
79
   * @return        NumericBoost
80
   */
81
  public function setStrength($strength)
82
  {
83
    $this->strength = $strength;
84
    return $this;
85
  }
86
87
}