Completed
Pull Request — master (#140)
by Vitaly
04:25
created

File

Size/Duplication

Total Lines 44
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 44
c 0
b 0
f 0

6 Methods

Rating   Name   Duplication   Size   Complexity  
getSize() 0 1 ?
getFilename() 0 1 ?
getPathname() 0 1 ?
getMTime() 0 1 ?
isWritable() 0 1 ?
unlink() 0 1 ?
1
<?php
2
3
namespace phpbu\App\Backup;
4
5
interface File
6
{
7
    /**
8
     * Return the filesize.
9
     *
10
     * @return integer
11
     */
12
    public function getSize(): int;
13
14
    /**
15
     * Return the filename.
16
     *
17
     * @return string
18
     */
19
    public function getFilename(): string;
20
21
    /**
22
     * Return the full path and filename.
23
     *
24
     * @return string
25
     */
26
    public function getPathname(): string;
27
28
    /**
29
     * Return last modified date as unix timestamp.
30
     *
31
     * @return integer
32
     */
33
    public function getMTime(): int;
34
35
    /**
36
     * Return whether the file is writable or not.
37
     *
38
     * @return boolean
39
     */
40
    public function isWritable(): bool;
41
42
    /**
43
     * Deletes the file.
44
     *
45
     * @throws \phpbu\App\Exception
46
     */
47
    public function unlink();
48
}