FOSSology
4.4.0
Open Source License Compliance by Open Source Software
Job.php
Go to the documentation of this file.
1
<?php
2
/*
3
SPDX-FileCopyrightText: © 2017 Siemens AG
4
5
SPDX-License-Identifier: GPL-2.0-only
6
*/
12
namespace
Fossology\UI\Api\Models;
13
19
class
Job
20
{
25
private
$id
;
30
private
$name
;
35
private
$queueDate
;
40
private
$uploadId
;
45
private
$userId
;
50
private
$groupId
;
55
private
$eta
;
56
65
private
$status
;
66
79
public
function
__construct
(
$id
,
$name
=
""
,
$queueDate
=
""
,
$uploadId
= 0,
80
$userId
= 0,
$groupId
= 0,
$eta
= 0,
$status
=
""
)
81
{
82
$this->
id
= intval(
$id
);
83
$this->name =
$name
;
84
$this->queueDate =
$queueDate
;
85
$this->uploadId = intval(
$uploadId
);
86
$this->userId = intval(
$userId
);
87
$this->groupId = intval(
$groupId
);
88
$this->eta = intval(
$eta
);
89
$this->status =
$status
;
90
}
91
96
public
function
getJSON
()
97
{
98
return
json_encode($this->
getArray
());
99
}
100
105
public
function
getArray
()
106
{
107
return
[
108
'id'
=>
$this->id
,
109
'name'
=>
$this->name
,
110
'queueDate'
=>
$this->queueDate
,
111
'uploadId'
=>
$this->uploadId
,
112
'userId'
=>
$this->userId
,
113
'groupId'
=>
$this->groupId
,
114
'eta'
=>
$this->eta
,
115
'status'
=>
$this->status
116
];
117
}
118
123
public
function
getId
()
124
{
125
return
$this->id
;
126
}
127
132
public
function
getName
()
133
{
134
return
$this->name
;
135
}
136
141
public
function
getQueueDate
()
142
{
143
return
$this->queueDate
;
144
}
145
150
public
function
getUploadId
()
151
{
152
return
$this->uploadId
;
153
}
154
159
public
function
getUserId
()
160
{
161
return
$this->userId
;
162
}
163
168
public
function
getGroupId
()
169
{
170
return
$this->groupId
;
171
}
172
177
public
function
getEta
()
178
{
179
return
$this->eta
;
180
}
181
186
public
function
getStatus
()
187
{
188
return
$this->status
;
189
}
190
195
public
function
setName
(
$name
)
196
{
197
$this->name =
$name
;
198
}
199
204
public
function
setQueueDate
(
$queueDate
)
205
{
206
$this->queueDate =
$queueDate
;
207
}
208
213
public
function
setUploadId
(
$uploadId
)
214
{
215
$this->uploadId =
$uploadId
;
216
}
217
222
public
function
setUserId
(
$userId
)
223
{
224
$this->userId =
$userId
;
225
}
226
231
public
function
setGroupId
(
$groupId
)
232
{
233
$this->groupId =
$groupId
;
234
}
235
240
public
function
setEta
(
$eta
)
241
{
242
$this->eta =
$eta
;
243
}
244
249
public
function
setStatus
(
$status
)
250
{
251
$this->status =
$status
;
252
}
253
}
Fossology\UI\Api\Models\Job
Definition:
Job.php:20
Fossology\UI\Api\Models\Job\getName
getName()
Definition:
Job.php:132
Fossology\UI\Api\Models\Job\getStatus
getStatus()
Definition:
Job.php:186
Fossology\UI\Api\Models\Job\__construct
__construct($id, $name="", $queueDate="", $uploadId=0, $userId=0, $groupId=0, $eta=0, $status="")
Definition:
Job.php:79
Fossology\UI\Api\Models\Job\setUserId
setUserId($userId)
Definition:
Job.php:222
Fossology\UI\Api\Models\Job\getUserId
getUserId()
Definition:
Job.php:159
Fossology\UI\Api\Models\Job\setUploadId
setUploadId($uploadId)
Definition:
Job.php:213
Fossology\UI\Api\Models\Job\getQueueDate
getQueueDate()
Definition:
Job.php:141
Fossology\UI\Api\Models\Job\$uploadId
$uploadId
Definition:
Job.php:40
Fossology\UI\Api\Models\Job\getArray
getArray()
Definition:
Job.php:105
Fossology\UI\Api\Models\Job\$queueDate
$queueDate
Definition:
Job.php:35
Fossology\UI\Api\Models\Job\$id
$id
Definition:
Job.php:25
Fossology\UI\Api\Models\Job\$name
$name
Definition:
Job.php:30
Fossology\UI\Api\Models\Job\setName
setName($name)
Definition:
Job.php:195
Fossology\UI\Api\Models\Job\$status
$status
Definition:
Job.php:65
Fossology\UI\Api\Models\Job\getId
getId()
Definition:
Job.php:123
Fossology\UI\Api\Models\Job\setGroupId
setGroupId($groupId)
Definition:
Job.php:231
Fossology\UI\Api\Models\Job\getJSON
getJSON()
Definition:
Job.php:96
Fossology\UI\Api\Models\Job\$eta
$eta
Definition:
Job.php:55
Fossology\UI\Api\Models\Job\setQueueDate
setQueueDate($queueDate)
Definition:
Job.php:204
Fossology\UI\Api\Models\Job\$userId
$userId
Definition:
Job.php:45
Fossology\UI\Api\Models\Job\setEta
setEta($eta)
Definition:
Job.php:240
Fossology\UI\Api\Models\Job\$groupId
$groupId
Definition:
Job.php:50
Fossology\UI\Api\Models\Job\getUploadId
getUploadId()
Definition:
Job.php:150
Fossology\UI\Api\Models\Job\getEta
getEta()
Definition:
Job.php:177
Fossology\UI\Api\Models\Job\getGroupId
getGroupId()
Definition:
Job.php:168
Fossology\UI\Api\Models\Job\setStatus
setStatus($status)
Definition:
Job.php:249
src
www
ui
api
Models
Job.php
Generated on Thu May 2 2024 13:40:57 for FOSSology by
1.9.1