Completed
Push — psr2 ( b196d8...ccc4c7 )
by Andreas
03:04
created

Post   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
dl 0
loc 23
rs 10
c 0
b 0
f 0
wmc 2
lcom 0
cbo 1

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A set() 0 5 1
1
<?php
2
3
namespace dokuwiki\Input;
4
5
/**
6
 * Internal class used for $_POST access in dokuwiki\Input\Input class
7
 */
8
class Post extends Input
9
{
10
11
    /** @noinspection PhpMissingParentConstructorInspection
12
     * Initialize the $access array, remove subclass members
13
     */
14
    public function __construct()
15
    {
16
        $this->access = &$_POST;
17
    }
18
19
    /**
20
     * Sets a parameter in $_POST and $_REQUEST
21
     *
22
     * @param string $name Parameter name
23
     * @param mixed $value Value to set
24
     */
25
    public function set($name, $value)
26
    {
27
        parent::set($name, $value);
28
        $_REQUEST[$name] = $value;
29
    }
30
}
31