aboutsummaryrefslogtreecommitdiff
path: root/tests/Fixtures/MixedVisibilityController.php
blob: 2f5ccff0962b7fb62f8a2745b55922474095ddcf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php

declare(strict_types=1);

namespace BrettParson\MiniRoute\Tests\Fixtures;

use BrettParson\MiniRoute\Attribute\Get;
use BrettParson\MiniRoute\Http\ResponseInterface;

/**
 * One public and one private method carrying route attributes. The private
 * route is invisible to the v0.1.0 loader (see miniroute-uhs.4).
 */
final class MixedVisibilityController
{
    #[Get('/pub')]
    public function pub(): ResponseInterface
    {
        return new TestResponse(200, 'pub');
    }

    #[Get('/secret')]
    private function secret(): ResponseInterface
    {
        return new TestResponse(200, 'secret');
    }
}