Completed
Push — bootstrap4 ( dc7ca1...d74498 )
by Simon
06:19
created

ApiPageBase   A

Complexity

Total Complexity 3

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 3
lcom 0
cbo 1

3 Methods

Rating   Name   Duplication   Size   Complexity  
A execute() 0 4 1
A setRoute() 0 4 1
A getRouteName() 0 4 1
1
<?php
2
/******************************************************************************
3
 * Wikipedia Account Creation Assistance tool                                 *
4
 *                                                                            *
5
 * All code in this file is released into the public domain by the ACC        *
6
 * Development Team. Please see team.json for a list of contributors.         *
7
 ******************************************************************************/
8
9
namespace Waca\Tasks;
10
11
use Waca\API\IApiAction;
12
13
abstract class ApiPageBase extends TaskBase implements IRoutedTask, IApiAction
14
{
15
    final public function execute()
16
    {
17
        $this->main();
18
    }
19
20
    /**
21
     * @param string $routeName
22
     */
23
    public function setRoute($routeName)
24
    {
25
        // no-op
26
    }
27
28
    /**
29
     * @return string
30
     */
31
    public function getRouteName()
32
    {
33
        return 'main';
34
    }
35
}
36