Completed
Pull Request — master (#9)
by Jacob
02:56
created

SecurityPart   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 37.5%

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 3
c 1
b 0
f 1
lcom 1
cbo 1
dl 0
loc 26
ccs 3
cts 8
cp 0.375
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A parseSecurity() 0 3 1
A getSecurity() 0 3 1
A setSecurity() 0 4 1
1
<?php
2
namespace gossi\swagger\parts;
3
4
use phootwork\collection\Map;
5
6
trait SecurityPart {
7
8
	/** @var object */
9
	private $security;
10
11 9
	private function parseSecurity(Map $data) {
12 9
		$this->security = $data->get('security');
13 9
	}
14
15
	/**
16
	 * @return object
17
	 */
18
	public function getSecurity() {
19
		return $this->security;
20
	}
21
22
	/**
23
	 * @param object $security
24
	 * @return $this
25
	 */
26
	public function setSecurity($security) {
27
		$this->security = $security;
28
		return $this;
29
	}
30
31
}
32