Completed
Push — development ( 9a019e...1dec28 )
by Alexander
03:32
created

Environment::getName()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
/**
3
 * Class for handling environment staff
4
 *
5
 * @file      Environment.php
6
 *
7
 * PHP version 5.6+
8
 *
9
 * @author    Yancharuk Alexander <alex at itvault dot info>
10
 * @copyright © 2012-2016 Alexander Yancharuk <alex at itvault at info>
11
 * @date      2016-11-05 09:59
12
 * @license   The BSD 3-Clause License
13
 *            <https://tldrlegal.com/license/bsd-3-clause-license-(revised)>
14
 */
15
16
namespace Veles\Application;
17
18
/**
19
 * Class   Environment
20
 *
21
 * @author Yancharuk Alexander <alex at itvault at info>
22
 */
23
class Environment
24
{
25
	/** @var  string */
26
	protected $static_path;
27
	/** @var  string */
28
	protected $name;
29
30
	/**
31
	 * Set path to static files for different environments
32
	 *
33
	 * @param string $static_path
34
	 *
35
	 * @return Environment
36
	 */
37
	public function setStaticPath($static_path)
38
	{
39
		$this->static_path = $static_path;
40
41
		return $this;
42
	}
43
44
	/**
45
	 * Get path to static files for current environment
46
	 *
47
	 * @return string
48
	 */
49
	public function getStaticPath()
50
	{
51
		return $this->static_path;
52
	}
53
54
	/**
55
	 * Set environment name
56
	 *
57
	 * @param string $name
58
	 *
59
	 * @return Environment
60
	 */
61
	public function setName($name)
62
	{
63
		$this->name = $name;
64
65
		return $this;
66
	}
67
68
	/**
69
	 * Get environment name
70
	 *
71
	 * @return mixed
72
	 */
73
	public function getName()
74
	{
75
		return $this->name;
76
	}
77
}
78