TrackManiaControl/core/Callbacks/Structures/ManiaPlanet/StartServerStructure.php

41 lines
954 B
PHP
Raw Permalink Normal View History

<?php
namespace ManiaControl\Callbacks\Structures\ManiaPlanet;
use ManiaControl\Callbacks\Structures\Common\BaseStructure;
use ManiaControl\ManiaControl;
2017-03-24 16:49:54 +01:00
/**
* Structure Class for the Default Start Server Callback
*
2017-04-07 23:26:35 +02:00
* @api
2017-03-24 16:49:54 +01:00
* @author ManiaControl Team <mail@maniacontrol.com>
2020-01-22 10:39:35 +01:00
* @copyright 2014-2020 ManiaControl Team
2017-03-24 16:49:54 +01:00
* @license http://www.gnu.org/licenses/ GNU General Public License, Version 3
*/
2017-03-23 20:55:20 +01:00
class StartServerStructure extends BaseStructure {
private $restarted;
2017-03-24 16:49:54 +01:00
2017-04-07 23:26:35 +02:00
/**
* StartServerStructure constructor.
*
* @param \ManiaControl\ManiaControl $maniaControl
* @param $data
*/
public function __construct(ManiaControl $maniaControl, $data) {
2017-03-23 21:01:44 +01:00
parent::__construct($maniaControl, $data);
2017-03-24 16:49:54 +01:00
$this->restarted = $this->getPlainJsonObject()->restarted;
}
2017-03-24 16:49:54 +01:00
/**
* Flag if the Server got Restarted
*
2017-04-07 23:26:35 +02:00
* @api
2017-03-24 16:49:54 +01:00
* @return mixed
*/
public function getRestarted() {
return $this->restarted;
}
}