Path   A
last analyzed

Complexity

Total Complexity 7

Size/Duplication

Total Lines 70
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 7
eloc 8
c 1
b 0
f 0
dl 0
loc 70
ccs 14
cts 14
cp 1
rs 10

7 Methods

Rating   Name   Duplication   Size   Complexity  
A resource() 0 3 1
A bin() 0 3 1
A root() 0 3 1
A output() 0 3 1
A test() 0 3 1
A demo() 0 3 1
A data() 0 3 1
1
<?php
2
declare(strict_types=1);
3
4
/**
5
 * ReportingCloud PHP SDK
6
 *
7
 * PHP SDK for ReportingCloud Web API. Authored and supported by Text Control GmbH.
8
 *
9
 * @link      https://www.reporting.cloud to learn more about ReportingCloud
10
 * @link      https://git.io/Jejj2 for the canonical source repository
11
 * @license   https://git.io/Jejjr
12
 * @copyright © 2022 Text Control GmbH
13
 */
14
15
namespace TxTextControl\ReportingCloud\Stdlib;
16
17
/**
18
 * Class Path
19
 *
20
 * @package TxTextControl\ReportingCloud
21
 * @author  Jonathan Maron (@JonathanMaron)
22
 */
23
class Path
24
{
25
    /**
26
     * Return the root path of PHP SDK for ReportingCloud Web API
27
     *
28
     * @return string
29
     */
30 86
    public static function root(): string
31
    {
32 86
        return dirname(__FILE__, 3);
33
    }
34
35
    /**
36
     * Return the binary path of PHP SDK for ReportingCloud Web API
37
     *
38
     * @return string
39
     */
40 2
    public static function bin(): string
41
    {
42 2
        return sprintf('%s/bin', self::root());
43
    }
44
45
    /**
46
     * Return the data path of PHP SDK for ReportingCloud Web API
47
     *
48
     * @return string
49
     */
50 22
    public static function data(): string
51
    {
52 22
        return sprintf('%s/data', self::root());
53
    }
54
55
    /**
56
     * Return the demo path of PHP SDK for ReportingCloud Web API
57
     *
58
     * @return string
59
     */
60 2
    public static function demo(): string
61
    {
62 2
        return sprintf('%s/demo', self::root());
63
    }
64
65
    /**
66
     * Return the output path of PHP SDK for ReportingCloud Web API
67
     *
68
     * @return string
69
     */
70 2
    public static function output(): string
71
    {
72 2
        return sprintf('%s/output', self::root());
73
    }
74
75
    /**
76
     * Return the resources path of PHP SDK for ReportingCloud Web API
77
     *
78
     * @return string
79
     */
80 66
    public static function resource(): string
81
    {
82 66
        return sprintf('%s/resource', self::root());
83
    }
84
85
    /**
86
     * Return the rest path of PHP SDK for ReportingCloud Web API
87
     *
88
     * @return string
89
     */
90 2
    public static function test(): string
91
    {
92 2
        return sprintf('%s/test', self::root());
93
    }
94
}
95