7
0
mirror of https://github.com/pelican-dev/panel.git synced 2025-06-15 08:11:09 +02:00
pelican-panel-mirror/app/Contracts/Repository/AllocationRepositoryInterface.php
2021-01-23 12:33:34 -08:00

20 lines
546 B
PHP

<?php
namespace Pterodactyl\Contracts\Repository;
interface AllocationRepositoryInterface extends RepositoryInterface
{
/**
* Return all of the allocations that exist for a node that are not currently
* allocated.
*/
public function getUnassignedAllocationIds(int $node): array;
/**
* Return a single allocation from those meeting the requirements.
*
* @return \Pterodactyl\Models\Allocation|null
*/
public function getRandomAllocation(array $nodes, array $ports, bool $dedicated = false);
}