aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public/SystemTag/ISystemTag.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/public/SystemTag/ISystemTag.php')
-rw-r--r--lib/public/SystemTag/ISystemTag.php70
1 files changed, 49 insertions, 21 deletions
diff --git a/lib/public/SystemTag/ISystemTag.php b/lib/public/SystemTag/ISystemTag.php
index 39adb39ec08..4fd93831955 100644
--- a/lib/public/SystemTag/ISystemTag.php
+++ b/lib/public/SystemTag/ISystemTag.php
@@ -1,29 +1,11 @@
<?php
declare(strict_types=1);
-
/**
- * @copyright Copyright (c) 2016, ownCloud, Inc.
- *
- * @author Roeland Jago Douma <roeland@famdouma.nl>
- * @author Vincent Petry <vincent@nextcloud.com>
- *
- * @license AGPL-3.0
- *
- * This code is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Affero General Public License, version 3,
- * as published by the Free Software Foundation.
- *
- * 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, version 3,
- * along with this program. If not, see <http://www.gnu.org/licenses/>
- *
+ * SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-FileCopyrightText: 2016 ownCloud, Inc.
+ * SPDX-License-Identifier: AGPL-3.0-only
*/
-
namespace OCP\SystemTag;
/**
@@ -32,6 +14,27 @@ namespace OCP\SystemTag;
* @since 9.0.0
*/
interface ISystemTag {
+ /**
+ * @since 22.0.0
+ */
+ public const ACCESS_LEVEL_PUBLIC = 0;
+ /**
+ * @since 22.0.0
+ */
+ public const ACCESS_LEVEL_RESTRICTED = 1;
+ /**
+ * @since 22.0.0
+ */
+ public const ACCESS_LEVEL_INVISIBLE = 2;
+
+ /**
+ * @since 22.0.0
+ */
+ public const ACCESS_LEVEL_LOOKUP = [
+ ISystemTag::ACCESS_LEVEL_PUBLIC => 'public',
+ ISystemTag::ACCESS_LEVEL_RESTRICTED => 'restricted',
+ ISystemTag::ACCESS_LEVEL_INVISIBLE => 'invisible',
+ ];
/**
* Returns the tag id
@@ -68,4 +71,29 @@ interface ISystemTag {
* @since 9.0.0
*/
public function isUserAssignable(): bool;
+
+ /**
+ * Returns a term summarizing the access control flags
+ *
+ * @return int the level of access control
+ *
+ * @since 22.0.0
+ */
+ public function getAccessLevel(): int;
+
+ /**
+ * Returns the ETag of the tag
+ * The ETag is a unique identifier for the tag and should change whenever the tag changes
+ * or whenever elements gets added or removed from the tag.
+ *
+ * @since 31.0.0
+ */
+ public function getETag(): ?string;
+
+ /**
+ * Returns the color of the tag
+ *
+ * @since 31.0.0
+ */
+ public function getColor(): ?string;
}