Completed
Pull Request — master (#6)
by
unknown
11:57
created

Profile::setEnabled()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
namespace SixtyEightPublishers\Application;
4
5
6
class Profile
7
{
8
	/** @var array  */
9
	private $countries;
10
11
	/** @var array  */
12
	private $languages;
13
14
	/** @var array  */
15
	private $currencies;
16
17
	/** @var array  */
18
	private $domains;
19
20
	/** @var bool  */
21
	private $enabled = TRUE;
22
23
	/**
24
	 * @param array         $countries
25
	 * @param array         $languages
26
	 * @param array         $currencies
27
	 * @param array         $domains
28
	 */
29
	public function __construct(array $countries, array $languages, array $currencies, array $domains)
30
	{
31
		$this->countries = $countries;
32
		$this->languages = $languages;
33
		$this->currencies = $currencies;
34
		$this->domains = $domains;
35
	}
36
37
	/**
38
	 * @param bool $enabled
39
	 *
40
	 * @return void
41
	 */
42
	public function setEnabled($enabled = true)
43
	{
44
		$this->enabled = $enabled;
45
	}
46
47
48
	/**
49
	 * @return array
50
	 */
51
	public function getCountries()
52
	{
53
		return $this->countries;
54
	}
55
56
	/**
57
	 * @return array
58
	 */
59
	public function getLanguages()
60
	{
61
		return $this->languages;
62
	}
63
64
	/**
65
	 * @return array
66
	 */
67
	public function getCurrencies()
68
	{
69
		return $this->currencies;
70
	}
71
72
	/**
73
	 * @return array
74
	 */
75
	public function getDomains()
76
	{
77
		return $this->domains;
78
	}
79
80
	/**
81
	 * @return bool
82
	 */
83
	public function isEnabled()
84
	{
85
		return $this->enabled;
86
	}
87
88
}