Code Duplication    Length = 13-13 lines in 3 locations

Manager/Cron.php 3 locations

@@ 276-288 (lines=13) @@
273
     * @return $this
274
     * @throws InvalidArgumentException
275
     */
276
    public function setHour($hour)
277
    {
278
        if (is_numeric($hour) && ($hour < 0 || $hour > 23)) {
279
            throw new InvalidArgumentException(
280
                sprintf('Invalid hour "%d"', $hour),
281
                self::ERROR_HOUR
282
            );
283
        }
284
285
        $this->hour = $hour;
286
287
        return $this;
288
    }
289
290
    /**
291
     * @return string
@@ 304-316 (lines=13) @@
301
     * @return $this
302
     * @throws InvalidArgumentException
303
     */
304
    public function setMinute($minute)
305
    {
306
        if (is_numeric($minute) && ($minute < 0 || $minute > 59)) {
307
            throw new InvalidArgumentException(
308
                sprintf('Invalid minute "%d"', $minute),
309
                self::ERROR_MINUTE
310
            );
311
        }
312
313
        $this->minute = $minute;
314
315
        return $this;
316
    }
317
318
    /**
319
     * @return string
@@ 332-344 (lines=13) @@
329
     * @return $this
330
     * @throws InvalidArgumentException
331
     */
332
    public function setMonth($month)
333
    {
334
        if (is_numeric($month) && ($month < 1 || $month > 12)) {
335
            throw new InvalidArgumentException(
336
                sprintf('Invalid month "%d"', $month),
337
                self::ERROR_MONTH
338
            );
339
        }
340
341
        $this->month = $month;
342
343
        return $this;
344
    }
345
346
    /**
347
     * @return string