FOSSology
4.4.0
Open Source License Compliance by Open Source Software
Info.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
18
class
Info
19
{
24
private
$code
;
29
private
$message
;
34
private
$type
;
41
public
function
__construct
(
$code
,
$message
,
$type
)
42
{
43
$this->code =
$code
;
44
$this->message =
$message
;
45
$this->type =
$type
;
46
}
47
49
54
public
function
getJSON
()
55
{
56
return
json_encode($this->
getArray
());
57
}
58
63
public
function
getArray
()
64
{
65
return
[
66
'code'
=>
$this->code
,
67
'message'
=>
$this->message
,
68
'type'
=>
$this->type
69
];
70
}
71
75
public
function
getCode
()
76
{
77
return
$this->code
;
78
}
79
83
public
function
getMessage
()
84
{
85
return
$this->message
;
86
}
87
91
public
function
getType
()
92
{
93
return
$this->type
;
94
}
95
}
Fossology\UI\Api\Models\Info
Info model to contain general error and return values.
Definition:
Info.php:19
Fossology\UI\Api\Models\Info\$message
$message
Definition:
Info.php:29
Fossology\UI\Api\Models\Info\getCode
getCode()
Definition:
Info.php:75
Fossology\UI\Api\Models\Info\getJSON
getJSON()
Definition:
Info.php:54
Fossology\UI\Api\Models\Info\$code
$code
Definition:
Info.php:24
Fossology\UI\Api\Models\Info\getArray
getArray()
Definition:
Info.php:63
Fossology\UI\Api\Models\Info\$type
$type
Definition:
Info.php:34
Fossology\UI\Api\Models\Info\getType
getType()
Definition:
Info.php:91
Fossology\UI\Api\Models\Info\__construct
__construct($code, $message, $type)
Definition:
Info.php:41
Fossology\UI\Api\Models\Info\getMessage
getMessage()
Definition:
Info.php:83
src
www
ui
api
Models
Info.php
Generated on Mon Nov 18 2024 07:37:14 for FOSSology by
1.9.1