-
Notifications
You must be signed in to change notification settings - Fork 230
Expand file tree
/
Copy pathCredentials.php
More file actions
97 lines (94 loc) · 2.71 KB
/
Credentials.php
File metadata and controls
97 lines (94 loc) · 2.71 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
<?php
/******************************************************************************
*
* Copyright 2023 Paphus Solutions Inc.
*
* Licensed under the Eclipse Public License, Version 1.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.eclipse.org/legal/epl-v10.html
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
******************************************************************************/
/**
* Credential used to establish a connection.
* Requires the url, and an application id.
* You can obtain your application id from your user details page on the hosting website.
*/
class Credentials
{
public String $host = "";
public String $app = "";
public String $url = "";
/**
* Your application's unique identifier.
* You can obtain your application id from your user details page on the hosting website.
*/
public String $applicationId = "";
/**
* Creates a new credentials for the service host url, and the application id.
*/
function Credentials($url, $applicationId)
{
$this->$url = $url;
$this->$applicationId = $applicationId;
}
function getUrl()
{
return $this->url;
}
/**
* Sets the server host name, i.e. www.paphuslivechat.com
*/
function getHost()
{
return $this->host;
}
function getApp()
{
return $this->app;
}
/**
* Sets the hosted service server url, i.e. http://www.paphuslivechat.com
*/
function setUrl($url)
{
return $this->$url = $url;
}
/**
* Sets the server host name, i.e. www.paphuslivechat.com
*/
function setHost($host)
{
return $this->$host = $host;
}
/**
* Sets an app url postfix, this is normally not required, i.e. "".
*/
function setApp($app)
{
return $this->$app = $app;
}
/**
* Returns your application's unique identifier.
*/
function getApplicationId()
{
return $this->applicationId;
}
/**
* Sets your application's unique identifier.
* You can obtain your application id from your user details page on the hosting website.
*/
function setApplicationId($applicationId)
{
$this->applicationId = $applicationId;
}
}
?>