2017-07-20 01:49:41 +00:00
|
|
|
<?php
|
2017-09-26 02:43:01 +00:00
|
|
|
/**
|
2017-07-20 01:49:41 +00:00
|
|
|
* Pterodactyl - Panel
|
|
|
|
* Copyright (c) 2015 - 2017 Dane Everitt <dane@daneeveritt.com>.
|
|
|
|
*
|
2017-09-26 02:43:01 +00:00
|
|
|
* This software is licensed under the terms of the MIT license.
|
|
|
|
* https://opensource.org/licenses/MIT
|
2017-07-20 01:49:41 +00:00
|
|
|
*/
|
|
|
|
|
2017-08-19 03:19:06 +00:00
|
|
|
namespace Pterodactyl\Contracts\Repository;
|
2017-07-20 01:49:41 +00:00
|
|
|
|
2017-08-19 03:19:06 +00:00
|
|
|
use Pterodactyl\Contracts\Repository\Attributes\SearchableInterface;
|
2017-07-20 01:49:41 +00:00
|
|
|
|
2017-08-19 03:19:06 +00:00
|
|
|
interface PackRepositoryInterface extends RepositoryInterface, SearchableInterface
|
2017-07-20 01:49:41 +00:00
|
|
|
{
|
2017-08-21 00:23:50 +00:00
|
|
|
/**
|
|
|
|
* Return a paginated listing of packs with their associated option and server count.
|
|
|
|
*
|
|
|
|
* @param int $paginate
|
|
|
|
* @return \Illuminate\Contracts\Pagination\LengthAwarePaginator
|
|
|
|
*/
|
|
|
|
public function paginateWithOptionAndServerCount($paginate = 50);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Return a pack with the associated server models attached to it.
|
|
|
|
*
|
2017-08-22 03:10:48 +00:00
|
|
|
* @param int $id
|
2017-08-21 00:23:50 +00:00
|
|
|
* @return \Illuminate\Database\Eloquent\Collection
|
|
|
|
*
|
|
|
|
* @throws \Illuminate\Database\Eloquent\ModelNotFoundException
|
|
|
|
*/
|
|
|
|
public function getWithServers($id);
|
|
|
|
|
2017-08-19 03:19:06 +00:00
|
|
|
/**
|
|
|
|
* Return all of the file archives for a given pack.
|
|
|
|
*
|
2017-08-22 03:10:48 +00:00
|
|
|
* @param int $id
|
|
|
|
* @param bool $collection
|
2017-08-19 03:19:06 +00:00
|
|
|
* @return object|\Illuminate\Support\Collection
|
2017-08-21 00:23:50 +00:00
|
|
|
*
|
|
|
|
* @throws \Illuminate\Database\Eloquent\ModelNotFoundException
|
2017-08-19 03:19:06 +00:00
|
|
|
*/
|
|
|
|
public function getFileArchives($id, $collection = false);
|
2017-07-20 01:49:41 +00:00
|
|
|
}
|