2017-06-25 20:31:50 +00:00
|
|
|
<?php
|
2017-09-26 02:43:01 +00:00
|
|
|
/**
|
2017-06-25 20:31:50 +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-06-25 20:31:50 +00:00
|
|
|
*/
|
|
|
|
|
2017-08-31 02:11:14 +00:00
|
|
|
namespace Pterodactyl\Contracts\Repository;
|
2017-06-25 20:31:50 +00:00
|
|
|
|
2017-08-31 02:11:14 +00:00
|
|
|
interface SessionRepositoryInterface extends RepositoryInterface
|
2017-06-25 20:31:50 +00:00
|
|
|
{
|
|
|
|
/**
|
2017-08-31 02:11:14 +00:00
|
|
|
* Delete a session for a given user.
|
2017-06-25 20:31:50 +00:00
|
|
|
*
|
2017-08-31 02:11:14 +00:00
|
|
|
* @param int $user
|
|
|
|
* @param int $session
|
|
|
|
* @return null|int
|
2017-06-25 20:31:50 +00:00
|
|
|
*/
|
2017-08-31 02:11:14 +00:00
|
|
|
public function deleteUserSession($user, $session);
|
2017-06-25 20:31:50 +00:00
|
|
|
|
|
|
|
/**
|
2017-08-31 02:11:14 +00:00
|
|
|
* Return all of the active sessions for a user.
|
2017-06-25 20:31:50 +00:00
|
|
|
*
|
2017-08-31 02:11:14 +00:00
|
|
|
* @param int $user
|
|
|
|
* @return \Illuminate\Support\Collection
|
2017-06-25 20:31:50 +00:00
|
|
|
*/
|
2017-08-31 02:11:14 +00:00
|
|
|
public function getUserSessions($user);
|
2017-06-25 20:31:50 +00:00
|
|
|
}
|