Package::getUserId()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace JWage\APNS\Safari;
4
5
class Package
6
{
7
    /**
8
     * @var array
9
     */
10
    public static $packageFiles = array(
11
        'icon.iconset/icon_16x16.png',
12
        'icon.iconset/[email protected]',
13
        'icon.iconset/icon_32x32.png',
14
        'icon.iconset/[email protected]',
15
        'icon.iconset/icon_128x128.png',
16
        'icon.iconset/[email protected]',
17
        'website.json'
18
    );
19
20
    /**
21
     * @var string
22
     */
23
    private $packageDir;
24
25
    /**
26
     * @var string
27
     */
28
    private $userId;
29
30
    /**
31
     * @var string
32
     */
33
    private $zipPath;
34
35
    /**
36
     * @param string $packageDir
37
     * @param string $userId
38
     */
39
    public function __construct($packageDir, $userId)
40
    {
41
        $this->packageDir = $packageDir;
42
        $this->userId = $userId;
43
        $this->zipPath = sprintf('%s.zip', $packageDir);
44
    }
45
46
    /**
47
     * Gets path to the zip package directory.
48
     *
49
     * @return string $packageDir
50
     */
51
    public function getPackageDir()
52
    {
53
        return $this->packageDir;
54
    }
55
56
    /**
57
     * Gets the user id this package is for.
58
     *
59
     * @return string $userId
60
     */
61
    public function getUserId()
62
    {
63
        return $this->userId;
64
    }
65
66
    /**
67
     * Gets path to the zip package.
68
     *
69
     * @return string $zipPath
70
     */
71
    public function getZipPath()
72
    {
73
        return $this->zipPath;
74
    }
75
}
76