Completed
Push — master ( dfef82...1a995f )
by Andrii
02:58
created

CopyHandler   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 2
c 1
b 0
f 1
lcom 0
cbo 2
dl 0
loc 19
ccs 0
cts 9
cp 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A renderPath() 0 5 1
A parsePath() 0 4 1
1
<?php
2
3
/*
4
 * Task runner, code generator and build tool for easier continuos integration
5
 *
6
 * @link      https://github.com/hiqdev/hidev
7
 * @package   hidev
8
 * @license   BSD-3-Clause
9
 * @copyright Copyright (c) 2015-2016, HiQDev (http://hiqdev.com/)
10
 */
11
12
namespace hidev\handlers;
13
14
use Yii;
15
16
/**
17
 * Handler for copying.
18
 */
19
class CopyHandler extends BaseHandler
20
{
21
    /**
22
     * {@inheritdoc}
23
     */
24
    public function renderPath($path, $data)
25
    {
26
        copy($data->getCopy(), $path);
27
        Yii::warning('Copied file: ' . $path);
28
    }
29
30
    /**
31
     * {@inheritdoc}
32
     */
33
    public function parsePath($path, $minimal = null)
34
    {
35
        return null;
36
    }
37
}
38