Total Complexity | 6 |
Total Lines | 85 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
13 | class OfflinePushElem extends Parameter |
||
14 | { |
||
15 | protected $properties = [ |
||
16 | 'PushFlag', |
||
17 | 'Title', |
||
18 | 'Desc', |
||
19 | 'Ext', |
||
20 | 'AndroidInfo', |
||
21 | 'ApnsInfo' |
||
22 | ]; |
||
23 | |||
24 | /** |
||
25 | * |
||
26 | * @param int $value 0 or 1 |
||
27 | * |
||
28 | * @return $this |
||
29 | */ |
||
30 | 1 | public function setPushFlag(int $value) |
|
31 | { |
||
32 | 1 | $this->setAttribute('PushFlag', $value); |
|
33 | 1 | return $this; |
|
34 | } |
||
35 | |||
36 | |||
37 | /** |
||
38 | * |
||
39 | * @param string $value |
||
40 | * |
||
41 | * @return $this |
||
42 | */ |
||
43 | 1 | public function setTitle(string $value) |
|
44 | { |
||
45 | 1 | $this->setAttribute('Title', $value); |
|
46 | 1 | return $this; |
|
47 | } |
||
48 | |||
49 | /** |
||
50 | * |
||
51 | * @param string $value |
||
52 | * |
||
53 | * @return $this |
||
54 | */ |
||
55 | 1 | public function setDesc(string $value) |
|
56 | { |
||
57 | 1 | $this->setAttribute('Desc', $value); |
|
58 | 1 | return $this; |
|
59 | } |
||
60 | |||
61 | /** |
||
62 | * |
||
63 | * @param string $value |
||
64 | * |
||
65 | * @return $this |
||
66 | */ |
||
67 | 1 | public function setExt(string $value) |
|
68 | { |
||
69 | 1 | $this->setAttribute('Ext', $value); |
|
70 | 1 | return $this; |
|
71 | } |
||
72 | |||
73 | /** |
||
74 | * |
||
75 | * @param AndroidInfo $androidInfo |
||
76 | * |
||
77 | * @return $this |
||
78 | * @throws \EasyIM\Kernel\Exceptions\InvalidArgumentException |
||
79 | */ |
||
80 | 1 | public function setAndroidInfo(AndroidInfo $androidInfo) |
|
84 | } |
||
85 | |||
86 | |||
87 | /** |
||
88 | * |
||
89 | * @param ApnsInfo $apnsInfo |
||
90 | * |
||
91 | * @return $this |
||
92 | * @throws \EasyIM\Kernel\Exceptions\InvalidArgumentException |
||
93 | */ |
||
94 | 1 | public function setApnsInfo(ApnsInfo $apnsInfo) |
|
98 | } |
||
99 | } |
||
100 |