Completed
Push — master ( 4ab4f4...b4fd54 )
by Luo
04:09
created

SignUrl::getMethod()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
ccs 0
cts 3
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Iidestiny\Flysystem\Oss\Plugins;
4
5
6
use League\Flysystem\Plugin\AbstractPlugin;
7
8
class SignUrl extends AbstractPlugin
9
{
10
    /**
11
     * sign url
12
     *
13
     * @return string
14
     */
15
    public function getMethod()
16
    {
17
        return 'signUrl';
18
    }
19
20
    /**
21
     * handle
22
     *
23
     * @param $path
24
     * @param $timeout
25
     *
26
     * @return mixed
27
     */
28
    public function handle($path, $timeout)
29
    {
30
        return $this->filesystem->getAdapter()->signUrl($path, $timeout);
31
    }
32
}