aboutsummaryrefslogtreecommitdiffstats
path: root/archiva-modules/archiva-scheduler
Commit message (Expand)AuthorAgeFilesLines
* Centralizing openjpa log configMartin Stockhammer2017-05-212-1/+2
* [MRM-1942] Merge branch 'jpa' into masterMartin Stockhammer2017-05-202-2/+41
|\
| * Use JPA as default and only database backendwithout_jdojpaMartin Stockhammer2016-12-301-0/+6
| * Add jpa settings to test spring contextsMartin Stockhammer2016-10-261-2/+35
* | bump version to 3.0.0-SNAPSHOTolivier lamy2017-05-185-5/+5
* | Merge branch 'feature/jetty_9.4'olivier lamy2017-05-182-10/+12
|\ \
| * | jetty.xml ready, do not force encoding in encoding servletolivier lamy2017-05-131-4/+3
| * | migrate all tests to jetty 9.4olivier lamy2017-05-122-6/+9
* | | [maven-release-plugin] prepare for next development iterationMartin Stockhammer2017-05-125-5/+5
* | | [maven-release-plugin] prepare release archiva-2.2.3archiva-2.2.3Martin Stockhammer2017-05-125-5/+5
|/ /
* | Going back to version 2.2.3Martin Stockhammer2017-04-285-5/+5
* | [maven-release-plugin] prepare for next development iterationMartin Stockhammer2017-04-215-5/+5
* | [maven-release-plugin] prepare release archiva-2.2.2archiva-2.2.2Martin Stockhammer2017-04-215-5/+5
|/
* [maven-release-plugin] prepare for next development iterationolivier lamy2016-05-235-5/+5
* [maven-release-plugin] prepare release archiva-2.2.1archiva-2.2.1olivier lamy2016-05-235-5/+5
* more usage of MockRepositorySessionFactoryOlivier Lamy2015-10-013-56/+13
* more usage of MockRepositorySessionFactoryOlivier Lamy2015-10-012-58/+6
* [MRM-1861] Proxy behaviour issue migrating from 1.3.x to 2.xEduardo Souza2015-06-111-0/+1
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2015-02-245-5/+5
* [maven-release-plugin] prepare release archiva-2.2.0archiva-2.2.0Olivier Lamy2015-02-245-5/+5
* [MRM-1867] Adding a find jar by checksum functionality to the REST apiOlivier Lamy2015-01-121-2/+16
* [MRM-1390] Bump version to 2.2.0Carlos Sanchez2014-12-015-5/+5
* Add a AbstractMetadataRepository to remove duplicated codeCarlos Sanchez2014-11-061-267/+2
* MRM-1865 remove isPermanent flag Eric Barboni2014-10-101-6/+0
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-09-015-5/+5
* [maven-release-plugin] prepare release archiva-2.1.1archiva-2.1.1Olivier Lamy2014-09-015-5/+5
* take advantage of generic typeBrett Porter2014-08-011-11/+9
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-07-165-5/+5
* [maven-release-plugin] prepare release archiva-2.1.0archiva-2.1.0Olivier Lamy2014-07-165-5/+5
* more code simplification with 1.7 featuresOlivier Lamy2014-04-171-6/+1
* using more java.nio.fileOlivier Lamy2014-04-172-30/+34
* Revert "[MRM-1828] upgrade to jetty 9.x"Olivier Lamy2014-04-141-7/+6
* [MRM-1828] upgrade to jetty 9.xOlivier Lamy2014-04-141-6/+7
* one move for all remaining override annotationEric Barboni2014-04-1118-0/+118
* more diamondOlivier Lamy2014-04-101-1/+1
* use diamond operatorOlivier Lamy2014-04-104-6/+6
* bump version to 2.1.0-SNAPSHOT because of 1.7 pre requisiteOlivier Lamy2014-04-055-5/+5
* move the factory bean to the apiOlivier Lamy2014-03-283-1/+11
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-03-265-5/+5
* [maven-release-plugin] prepare release archiva-2.0.1Olivier Lamy2014-03-265-5/+5
* use assertj as fest-assert is not maintained anymoreOlivier Lamy2014-03-252-4/+4
* fix javadoc. Generation possible on jdk8 skygo2014-02-252-2/+2
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare release archiva-2.0.0Olivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare release archiva-2.0.0-RC3Olivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare release archiva-2.0.0-RC2Olivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare for next development iterationOlivier Lamy2014-02-085-5/+5
* [maven-release-plugin] prepare release archiva-2.0.0-RC1Olivier Lamy2014-02-085-5/+5
alue='backport/48520/stable30'>backport/48520/stable30 Nextcloud server, a safe home for all your data: https://github.com/nextcloud/serverwww-data
aboutsummaryrefslogtreecommitdiffstats
path: root/apps/user_status/lib/Connector/UserStatusProvider.php
blob: 4bc2645dceb833c42899e7949b64fa54ff92e011 (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
<?php

declare(strict_types=1);

/**
 * @copyright Copyright (c) 2020, Georg Ehrke
 *
 * @author Georg Ehrke <oc.list@georgehrke.com>
 *
 * @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 OCA\UserStatus\Connector;

use OC\UserStatus\ISettableProvider;
use OCA\UserStatus\Service\StatusService;
use OCP\UserStatus\IProvider;

class UserStatusProvider implements IProvider, ISettableProvider {

	/** @var StatusService */
	private $service;

	/**
	 * UserStatusProvider constructor.
	 *
	 * @param StatusService $service
	 */
	public function __construct(StatusService $service) {
		$this->service = $service;
	}

	/**
	 * @inheritDoc
	 */
	public function getUserStatuses(array $userIds): array {
		$statuses = $this->service->findByUserIds($userIds);

		$userStatuses = [];
		foreach ($statuses as $status) {
			$userStatuses[$status->getUserId()] = new UserStatus($status);
		}

		return $userStatuses;
	}

	public function setUserStatus(string $userId, string $messageId, string $status, bool $createBackup): void {
		$this->service->setUserStatus($userId, $status, $messageId, $createBackup);
	}

	public function revertUserStatus(string $userId, string $messageId, string $status): void {
		$this->service->revertUserStatus($userId, $messageId);
	}

	public function revertMultipleUserStatus(array $userIds, string $messageId, string $status): void {
		$this->service->revertMultipleUserStatus($userIds, $messageId);
	}
}