Passed
Push — master ( 0deb8f...f54565 )
by Goffy
04:13
created

Sanity   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 17
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __set() 0 3 1
A __get() 0 3 1
1
<?php
2
3
namespace XoopsModules\Wggithub\Github;
4
5
6
/**
7
 * Undefined member access check. Stolen from Nette\Object (http://nette.org).
8
 */
9
abstract class Sanity
10
{
11
	/**
12
	 * @throws LogicException
13
	 */
14
	public function & __get($name)
15
	{
16
		throw new LogicException('Cannot read an undeclared property ' . get_class($this) . "::\$$name.");
0 ignored issues
show
Bug introduced by
The type XoopsModules\Wggithub\Github\LogicException was not found. Did you mean LogicException? If so, make sure to prefix the type with \.
Loading history...
17
	}
18
19
20
	/**
21
	 * @throws LogicException
22
	 */
23
	public function __set($name, $value)
24
	{
25
		throw new LogicException('Cannot write to an undeclared property ' . get_class($this) . "::\$$name.");
26
	}
27
28
}
29