helloworld::getAll()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 3
nc 1
nop 1
dl 0
loc 6
rs 9.4285
c 0
b 0
f 0
1
<?php
2
namespace HelloWorld\Endpoints\v1_0;
3
4
use LunixREST\Server\APIRequest\APIRequest;
5
use LunixREST\Server\APIResponse\APIResponseData;
6
use LunixREST\Server\Router\Endpoint\DefaultEndpoint;
7
use LunixREST\Server\Router\Endpoint\Exceptions\EndpointExecutionException;
8
use LunixREST\Server\Router\Endpoint\Exceptions\InvalidRequestException;
9
use LunixREST\Server\Router\Endpoint\Exceptions\UnsupportedMethodException;
10
11
class helloworld extends DefaultEndpoint
12
{
13
14
    /**
15
     * @param APIRequest $request
16
     * @return APIResponseData
17
     * @throws EndpointExecutionException
18
     * @throws UnsupportedMethodException
19
     * @throws InvalidRequestException
20
     */
21
    public function getAll(APIRequest $request): APIResponseData
22
    {
23
        return new APIResponseData([
24
            "helloworld" => "HelloWorld"
25
        ]);
26
    }
27
}
28