Code Duplication    Length = 11-11 lines in 3 locations

src/Entity/Goal.php 3 locations

@@ 139-149 (lines=11) @@
136
     *                                                       Throws an exception if the argument given does not match the expected set of
137
     *                                                       values
138
     */
139
    public function setRuleIds(array $ruleIds)
140
    {
141
        if (Utility::arrayDepth($ruleIds) > 1) {
142
            throw new LiftSdkException('Rule Ids argument is more than 1 level deep.');
143
        }
144
145
        // Set only the array values to the rule_ids property.
146
        $this['rule_ids'] = array_values($ruleIds);
147
148
        return $this;
149
    }
150
151
    /**
152
     * Gets the 'rule_ids' parameter.
@@ 175-185 (lines=11) @@
172
     *                                                       Throws an exception if the argument given does not match the expected set of
173
     *                                                       values
174
     */
175
    public function setSiteIds(array $siteIds)
176
    {
177
        if (Utility::arrayDepth($siteIds) > 1) {
178
            throw new LiftSdkException('site_ids argument is more than 1 level deep.');
179
        }
180
181
        // Set only the array values to the rule_ids property.
182
        $this['site_ids'] = array_values($siteIds);
183
184
        return $this;
185
    }
186
187
    /**
188
     * Gets the 'site_ids' parameter.
@@ 211-221 (lines=11) @@
208
     *                                                       Throws an exception if the argument given does not match the expected set of
209
     *                                                       values
210
     */
211
    public function setEventNames(array $eventNames)
212
    {
213
        if (Utility::arrayDepth($eventNames) > 1) {
214
            throw new LiftSdkException('Event Names argument is more than 1 level deep.');
215
        }
216
217
        // Set only the array values to the event_names property.
218
        $this['event_names'] = array_values($eventNames);
219
220
        return $this;
221
    }
222
223
    /**
224
     * Gets the 'rule_ids' parameter.