aboutsummaryrefslogtreecommitdiffstats
path: root/core/Data/LoginFlowV2Credentials.php
blob: 0997b2cbe0630f1cf1066f1ba38c4846e34dd9b4 (plain)
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
<?php

declare(strict_types=1);

/**
 * SPDX-FileCopyrightText: 2019 Nextcloud GmbH and Nextcloud contributors
 * SPDX-License-Identifier: AGPL-3.0-or-later
 */
namespace OC\Core\Data;

class LoginFlowV2Credentials implements \JsonSerializable {
	public function __construct(
		private string $server,
		private string $loginName,
		private string $appPassword,
	) {
	}

	/**
	 * @return string
	 */
	public function getServer(): string {
		return $this->server;
	}

	/**
	 * @return string
	 */
	public function getLoginName(): string {
		return $this->loginName;
	}

	/**
	 * @return string
	 */
	public function getAppPassword(): string {
		return $this->appPassword;
	}

	public function jsonSerialize(): array {
		return [
			'server' => $this->server,
			'loginName' => $this->loginName,
			'appPassword' => $this->appPassword,
		];
	}
}