Passed
Push — master ( 0f08ac...de3478 )
by Roeland
18:05 queued 13s
created

VerifyMountPointEvent   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 48
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 12
c 1
b 0
f 0
dl 0
loc 48
rs 10
wmc 5

5 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 1
A getShare() 0 2 1
A setParent() 0 2 1
A getParent() 0 2 1
A getView() 0 2 1
1
<?php
2
declare(strict_types=1);
3
/**
4
 * @copyright Copyright (c) 2020, Joas Schilling <[email protected]>
5
 *
6
 * @author Joas Schilling <[email protected]>
7
 *
8
 * @license GNU AGPL version 3 or any later version
9
 *
10
 * This program is free software: you can redistribute it and/or modify
11
 * it under the terms of the GNU Affero General Public License as
12
 * published by the Free Software Foundation, either version 3 of the
13
 * License, or (at your option) any later version.
14
 *
15
 * This program is distributed in the hope that it will be useful,
16
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18
 * GNU Affero General Public License for more details.
19
 *
20
 * You should have received a copy of the GNU Affero General Public License
21
 * along with this program. If not, see <http://www.gnu.org/licenses/>.
22
 *
23
 */
24
25
namespace OCP\Share\Events;
26
27
use OC\Files\View;
28
use OCP\EventDispatcher\Event;
29
use OCP\Share\IShare;
30
31
/**
32
 * @since 19.0.0
33
 */
34
class VerifyMountPointEvent extends Event {
35
36
	/** @var IShare */
37
	private $share;
38
	/** @var View */
39
	private $view;
40
	/** @var string */
41
	private $parent;
42
43
	/**
44
	 * @since 19.0.0
45
	 */
46
	public function __construct(IShare $share,
47
								View $view,
48
								string $parent) {
49
		parent::__construct();
50
51
		$this->share = $share;
52
		$this->view = $view;
53
		$this->parent = $parent;
54
	}
55
56
	/**
57
	 * @since 19.0.0
58
	 */
59
	public function getShare(): IShare {
60
		return $this->share;
61
	}
62
63
	/**
64
	 * @since 19.0.0
65
	 */
66
	public function getView(): View {
67
		return $this->view;
68
	}
69
70
	/**
71
	 * @since 19.0.0
72
	 */
73
	public function getParent(): string {
74
		return $this->parent;
75
	}
76
77
	/**
78
	 * @since 19.0.0
79
	 */
80
	public function setParent(string $parent): void {
81
		$this->parent = $parent;
82
	}
83
}
84