50 lines
1.3 KiB
PHP
50 lines
1.3 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
/**
|
|
* SPDX-FileCopyrightText: Sebastian Krupinski <krupinski01@gmail.com>
|
|
* SPDX-License-Identifier: AGPL-3.0-or-later
|
|
*/
|
|
|
|
namespace KTXF\Resource\Provider;
|
|
|
|
use KTXF\Json\JsonDeserializable;
|
|
|
|
interface ResourceProviderServiceMutateInterface extends ResourceProviderBaseInterface, JsonDeserializable {
|
|
|
|
public const CAPABILITY_SERVICE_FRESH = 'ServiceFresh';
|
|
public const CAPABILITY_SERVICE_CREATE = 'ServiceCreate';
|
|
public const CAPABILITY_SERVICE_UPDATE = 'ServiceUpdate';
|
|
public const CAPABILITY_SERVICE_DESTROY = 'ServiceDestroy';
|
|
|
|
/**
|
|
* construct and new blank service instance
|
|
*
|
|
* @since 2025.05.01
|
|
*/
|
|
public function serviceFresh(string $tenantId, ?string $userId): ResourceServiceMutateInterface;
|
|
|
|
/**
|
|
* create a service configuration for a specific user
|
|
*
|
|
* @since 2025.05.01
|
|
*/
|
|
public function serviceCreate(string $tenantId, ?string $userId, ResourceServiceMutateInterface $service): string;
|
|
|
|
/**
|
|
* modify a service configuration for a specific user
|
|
*
|
|
* @since 2025.05.01
|
|
*/
|
|
public function serviceModify(string $tenantId, ?string $userId, ResourceServiceMutateInterface $service): string;
|
|
|
|
/**
|
|
* delete a service configuration for a specific user
|
|
*
|
|
* @since 2025.05.01
|
|
*/
|
|
public function serviceDestroy(string $tenantId, ?string $userId, ResourceServiceMutateInterface $service): bool;
|
|
|
|
}
|