Code Duplication    Length = 9-9 lines in 10 locations

src/Entity/Content.php 1 location

@@ 28-36 (lines=9) @@
25
   *
26
   * @return \Acquia\LiftClient\Entity\Content
27
   */
28
  public function setId($id)
29
  {
30
      if (!is_string($id)) {
31
          throw new LiftSdkException('Argument must be an instance of string.');
32
      }
33
      $this['id'] = $id;
34
35
      return $this;
36
  }
37
38
  /**
39
   * Gets the 'id' parameter.

src/Entity/Goal.php 3 locations

@@ 29-37 (lines=9) @@
26
     *
27
     * @return \Acquia\LiftClient\Entity\Goal
28
     */
29
    public function setId($id)
30
    {
31
        if (!is_string($id)) {
32
            throw new LiftSdkException('Argument must be an instance of string.');
33
        }
34
        $this['id'] = $id;
35
36
        return $this;
37
    }
38
39
    /**
40
     * Gets the 'id' parameter.
@@ 58-66 (lines=9) @@
55
     *
56
     * @return \Acquia\LiftClient\Entity\Goal
57
     */
58
    public function setName($name)
59
    {
60
        if (!is_string($name)) {
61
            throw new LiftSdkException('Argument must be an instance of string.');
62
        }
63
        $this['name'] = $name;
64
65
        return $this;
66
    }
67
68
    /**
69
     * Gets the 'name' parameter.
@@ 88-96 (lines=9) @@
85
     *
86
     * @return \Acquia\LiftClient\Entity\Goal
87
     */
88
    public function setDescription($description)
89
    {
90
        if (!is_string($description)) {
91
            throw new LiftSdkException('Argument must be an instance of string.');
92
        }
93
        $this['description'] = $description;
94
95
        return $this;
96
    }
97
98
    /**
99
     * Gets the 'description' parameter.

src/Entity/Probability.php 1 location

@@ 28-36 (lines=9) @@
25
   *
26
   * @return \Acquia\LiftClient\Entity\Probability
27
   */
28
  public function setContentId($contentId)
29
  {
30
      if (!is_string($contentId)) {
31
          throw new LiftSdkException('Argument must be an instance of string.');
32
      }
33
      $this['id'] = $contentId;
34
35
      return $this;
36
  }
37
38
  /**
39
   * Gets the 'id' parameter.

src/Entity/Rule.php 4 locations

@@ 29-37 (lines=9) @@
26
     *
27
     * @return \Acquia\LiftClient\Entity\Rule
28
     */
29
    public function setId($id)
30
    {
31
        if (!is_string($id)) {
32
            throw new LiftSdkException('Argument must be an instance of string.');
33
        }
34
        $this['id'] = $id;
35
36
        return $this;
37
    }
38
39
    /**
40
     * Gets the 'id' parameter.
@@ 58-66 (lines=9) @@
55
     *
56
     * @return \Acquia\LiftClient\Entity\Rule
57
     */
58
    public function setLabel($label)
59
    {
60
        if (!is_string($label)) {
61
            throw new LiftSdkException('Argument must be an instance of string.');
62
        }
63
        $this['label'] = $label;
64
65
        return $this;
66
    }
67
68
    /**
69
     * Gets the 'label' parameter.
@@ 87-95 (lines=9) @@
84
     *
85
     * @return \Acquia\LiftClient\Entity\Rule
86
     */
87
    public function setDescription($description)
88
    {
89
        if (!is_string($description)) {
90
            throw new LiftSdkException('Argument must be an instance of string.');
91
        }
92
        $this['description'] = $description;
93
94
        return $this;
95
    }
96
97
    /**
98
     * Gets the 'description' parameter.
@@ 210-218 (lines=9) @@
207
     *
208
     * @return \Acquia\LiftClient\Entity\Rule
209
     */
210
    public function setSegment($segment)
211
    {
212
        if (!is_string($segment)) {
213
            throw new LiftSdkException('Argument must be an instance of integer.');
214
        }
215
        $this['segment'] = $segment;
216
217
        return $this;
218
    }
219
220
    /**
221
     * Gets the 'segment' parameter.

src/Entity/ViewMode.php 1 location

@@ 28-36 (lines=9) @@
25
   *
26
   * @return \Acquia\LiftClient\Entity\ViewMode
27
   */
28
  public function setId($id)
29
  {
30
      if (!is_string($id)) {
31
          throw new LiftSdkException('Argument must be an instance of string.');
32
      }
33
      $this['id'] = $id;
34
35
      return $this;
36
  }
37
38
  /**
39
   * Gets the 'id' parameter.