19 lines
552 B
PHP
19 lines
552 B
PHP
<?php
|
|
|
|
namespace MintyPHP\Repository\Tenant;
|
|
|
|
/** Contract for querying user-tenant membership and per-tenant user counts. */
|
|
interface UserTenantRepositoryInterface
|
|
{
|
|
public function listTenantIdsByUserId(int $userId): array;
|
|
|
|
public function replaceForUser(int $userId, array $tenantIds): bool;
|
|
|
|
public function countUsersByTenantIds(array $tenantIds): array;
|
|
|
|
public function countActiveUsersByTenantIds(array $tenantIds): array;
|
|
|
|
/** @return list<int> */
|
|
public function listActiveUserIdsByTenantId(int $tenantId): array;
|
|
}
|