Completed
Push — master ( ea15e4...6b748c )
by Michał
04:07
created

Process::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
namespace Phppm;
4
5
use Symfony\Component\Console\Output\OutputInterface;
6
7
abstract class Process implements ProcessInterface
8
{
9
    /**
10
     * @var OutputInterface
11
     */
12
    protected $output;
13
14
    /**
15
     * Process constructor.
16
     * @param OutputInterface $output
17
     */
18
    public function __construct(OutputInterface $output)
19
    {
20
        $this->output = $output;
21
    }
22
23
    /**
24
     * @return string
25
     */
26
    protected function getFormattedTime() : string
27
    {
28
        $now = \DateTime::createFromFormat('U.u', microtime(true));
29
        return $now->format("Y-d-m H:i:s.u");
30
    }
31
}
32