DoubleCoordinateCommandOption   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 6
c 1
b 0
f 0
dl 0
loc 29
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getCoordinate2() 0 3 1
1
<?php
2
3
namespace Jackal\ImageMerge\Command\Options;
4
5
use Jackal\ImageMerge\ValueObject\Coordinate;
6
7
/**
8
 * Class DoubleCoordinateCommandOption
9
 * @package Jackal\ImageMerge\Command\Options
10
 */
11
class DoubleCoordinateCommandOption extends SingleCoordinateCommandOption
12
{
13
    /**
14
     * @var integer
15
     */
16
    protected $x2;
17
18
    /**
19
     * @var integer
20
     */
21
    protected $y2;
22
23
    /**
24
     * DoubleCoordinateCommandOption constructor.
25
     * @param Coordinate $coord1
26
     * @param Coordinate $coord2
27
     */
28
    public function __construct(Coordinate $coord1, Coordinate $coord2)
29
    {
30
        parent::__construct($coord1);
31
        $this->add('coord2', $coord2);
32
    }
33
34
    /**
35
     * @return mixed
36
     */
37
    public function getCoordinate2()
38
    {
39
        return $this->get('coord2');
40
    }
41
}
42