mirror of
https://github.com/pterodactyl/panel.git
synced 2026-12-01 11:55:51 -05:00
25 lines
789 B
PHP
25 lines
789 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Pterodactyl\Contracts\Databases;
|
|
|
|
use Pterodactyl\Models\DatabaseHost;
|
|
use Throwable;
|
|
|
|
interface UpdatesDatabaseHosts
|
|
{
|
|
/**
|
|
* Update a database host once the Panel has connected to it with the new credentials.
|
|
* The input is validated here, so it can come straight from any caller. It takes the
|
|
* fields a host is created with, required ones included; a blank password keeps the
|
|
* stored one, and a host given no node_id becomes global. Extension field values go under
|
|
* `extensions` as ValidatedExtensionValues.
|
|
*
|
|
* @param array<string, mixed> $input the fields a host is created with
|
|
*
|
|
* @throws Throwable
|
|
*/
|
|
public function update(DatabaseHost $host, array $input): DatabaseHost;
|
|
}
|