コード例 #1
0
ファイル: FileServer.php プロジェクト: sweetcode/Nitrapi-PHP
 /**
  * Creates a new directory
  *
  * @param $path
  * @param $name
  * @return bool
  */
 public function createDirectory($path, $name)
 {
     $url = "/services/" . $this->service->getId() . "/gameservers/file_server/mkdir";
     $this->service->getApi()->dataPost($url, array('path' => $path, 'name' => $name));
     return true;
 }
コード例 #2
0
 public static function factory(Gameserver &$service, &$id)
 {
     $data = $service->getApi()->dataGet("services/" . $service->getId() . "/gameservers/mariadbs/" . $id);
     return new MariaDB($service, $data['database']);
 }
コード例 #3
0
 public function resetSettings()
 {
     $this->service->getApi()->dataDelete("services/" . $this->service->getId() . "/gameservers/settings");
     return true;
 }
コード例 #4
0
 public function getInfo()
 {
     $url = "/services/" . $this->service->getId() . "/gameservers/plugin_system/info";
     $infos = $this->service->getApi()->dataGet($url);
     return $infos['plugin_system'];
 }