# SOME DESCRIPTIVE TITLE. # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the PACKAGE package. # # Translators: msgid "" msgstr "" "Project-Id-Version: ownCloud\n" "Report-Msgid-Bugs-To: http://bugs.owncloud.org/\n" "POT-Creation-Date: 2013-06-26 01:59+0200\n" "PO-Revision-Date: 2013-06-25 23:15+0000\n" "Last-Translator: I Robot \n" "Language-Team: Croatian (http://www.transifex.com/projects/p/owncloud/language/hr/)\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Language: hr\n" "Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" #: ajax/delete.php:42 #, php-format msgid "Couldn't delete %s permanently" msgstr "" #: ajax/undelete.php:42 #, php-format msgid "Couldn't restore %s" msgstr "" #: js/trash.js:7 js/trash.js:97 msgid "perform restore operation" msgstr "" #: js/trash.js:19 js/trash.js:46 js/trash.js:115 js/trash.js:141 msgid "Error" msgstr "Greška" #: js/trash.js:34 msgid "delete file permanently" msgstr "" #: js/trash.js:123 msgid "Delete permanently" msgstr "" #: js/trash.js:176 templates/index.php:17 msgid "Name" msgstr "Ime" #: js/trash.js:177 templates/index.php:27 msgid "Deleted" msgstr "" #: js/trash.js:186 msgid "1 folder" msgstr "" #: js/trash.js:188 msgid "{count} folders" msgstr "" #: js/trash.js:196 msgid "1 file" msgstr "" #: js/trash.js:198 msgid "{count} files" msgstr "" #: templates/index.php:9 msgid "Nothing in here. Your trash bin is empty!" msgstr "" #: templates/index.php:20 templates/index.php:22 msgid "Restore" msgstr "" #: templates/index.php:30 templates/index.php:31 msgid "Delete" msgstr "Obriši" #: templates/part.breadcrumb.php:9 msgid "Deleted Files" msgstr "" ares-parameter-better-distinction Nextcloud server, a safe home for all your data: https://github.com/nextcloud/serverwww-data
aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/Authentication/TwoFactorAuth/EnforcementState.php
blob: b95128c1e0fe28f5458edd0d5a72cebdfd3ddaad (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
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
<?php

declare(strict_types=1);

/**
 * @copyright 2018 Christoph Wurst <christoph@winzerhof-wurst.at>
 *
 * @author Christoph Wurst <christoph@winzerhof-wurst.at>
 *
 * @license GNU AGPL version 3 or any later version
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as
 * published by the Free Software Foundation, either version 3 of the
 * License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program. If not, see <http://www.gnu.org/licenses/>.
 *
 */
namespace OC\Authentication\TwoFactorAuth;

use JsonSerializable;

class EnforcementState implements JsonSerializable {
	/** @var bool */
	private $enforced;

	/** @var array */
	private $enforcedGroups;

	/** @var array */
	private $excludedGroups;

	/**
	 * EnforcementState constructor.
	 *
	 * @param bool $enforced
	 * @param string[] $enforcedGroups
	 * @param string[] $excludedGroups
	 */
	public function __construct(bool $enforced,
								array $enforcedGroups = [],
								array $excludedGroups = []) {
		$this->enforced = $enforced;
		$this->enforcedGroups = $enforcedGroups;
		$this->excludedGroups = $excludedGroups;
	}

	/**
	 * @return bool
	 */
	public function isEnforced(): bool {
		return $this->enforced;
	}

	/**
	 * @return string[]
	 */
	public function getEnforcedGroups(): array {
		return $this->enforcedGroups;
	}

	/**
	 * @return string[]
	 */
	public function getExcludedGroups(): array {
		return $this->excludedGroups;
	}

	public function jsonSerialize(): array {
		return [
			'enforced' => $this->enforced,
			'enforcedGroups' => $this->enforcedGroups,
			'excludedGroups' => $this->excludedGroups,
		];
	}
}