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 © 2023 Text Control GmbH |
13
|
|
|
*/ |
14
|
|
|
|
15
|
|
|
namespace TextControl\ReportingCloud\Stdlib; |
16
|
|
|
|
17
|
|
|
class Path |
18
|
|
|
{ |
19
|
|
|
/** |
20
|
|
|
* Return the root path of PHP SDK for ReportingCloud Web API |
21
|
|
|
*/ |
22
|
86 |
|
public static function root(): string |
23
|
|
|
{ |
24
|
86 |
|
return dirname(__FILE__, 3); |
25
|
|
|
} |
26
|
|
|
|
27
|
|
|
/** |
28
|
|
|
* Return the binary path of PHP SDK for ReportingCloud Web API |
29
|
|
|
*/ |
30
|
2 |
|
public static function bin(): string |
31
|
|
|
{ |
32
|
2 |
|
return sprintf('%s/bin', self::root()); |
33
|
|
|
} |
34
|
|
|
|
35
|
|
|
/** |
36
|
|
|
* Return the data path of PHP SDK for ReportingCloud Web API |
37
|
|
|
*/ |
38
|
22 |
|
public static function data(): string |
39
|
|
|
{ |
40
|
22 |
|
return sprintf('%s/data', self::root()); |
41
|
|
|
} |
42
|
|
|
|
43
|
|
|
/** |
44
|
|
|
* Return the demo path of PHP SDK for ReportingCloud Web API |
45
|
|
|
*/ |
46
|
2 |
|
public static function demo(): string |
47
|
|
|
{ |
48
|
2 |
|
return sprintf('%s/demo', self::root()); |
49
|
|
|
} |
50
|
|
|
|
51
|
|
|
/** |
52
|
|
|
* Return the output path of PHP SDK for ReportingCloud Web API |
53
|
|
|
*/ |
54
|
2 |
|
public static function output(): string |
55
|
|
|
{ |
56
|
2 |
|
return sprintf('%s/output', self::root()); |
57
|
|
|
} |
58
|
|
|
|
59
|
|
|
/** |
60
|
|
|
* Return the resources path of PHP SDK for ReportingCloud Web API |
61
|
|
|
*/ |
62
|
66 |
|
public static function resource(): string |
63
|
|
|
{ |
64
|
66 |
|
return sprintf('%s/resource', self::root()); |
65
|
|
|
} |
66
|
|
|
|
67
|
|
|
/** |
68
|
|
|
* Return the rest path of PHP SDK for ReportingCloud Web API |
69
|
|
|
*/ |
70
|
2 |
|
public static function test(): string |
71
|
|
|
{ |
72
|
2 |
|
return sprintf('%s/test', self::root()); |
73
|
|
|
} |
74
|
|
|
} |
75
|
|
|
|