Begining with the new VS structure
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
//
|
||||
// Created by WolverinDEV on 03/03/2020.
|
||||
//
|
||||
|
||||
#include <Error.h>
|
||||
#include "DefaultServer.h"
|
||||
|
||||
using namespace ts::server::vserver;
|
||||
|
||||
VirtualServerStartResult DefaultServer::start_server_virtual_(ts::rwshared_lock<ts::rw_mutex> &lock, std::string &error) {
|
||||
if(!lock.auto_lock_exclusive()) {
|
||||
error = "failed to lock server state";
|
||||
return VirtualServerStartResult::CUSTOM;
|
||||
}
|
||||
|
||||
if(auto result = DefaultServer::start_server_virtual_(lock, error); result != VirtualServerStartResult::SUCCESS)
|
||||
return result;
|
||||
|
||||
//TODO: Load anything
|
||||
|
||||
this->status_ = VirtualServerStatus::VIRTUAL;
|
||||
return VirtualServerStartResult::SUCCESS;
|
||||
}
|
||||
|
||||
VirtualServerStartResult DefaultServer::start_server_(ts::rwshared_lock<ts::rw_mutex> &lock, std::string &string) {
|
||||
return VirtualServerStartResult::SERVER_IS_DEFAULT;
|
||||
}
|
||||
|
||||
void DefaultServer::stop_server_(ts::rwshared_lock<ts::rw_mutex> &lock) {
|
||||
VirtualServerBase::stop_server_(lock);
|
||||
|
||||
/* TODO: Save server states? Because we can't really shut down. */
|
||||
}
|
||||
Reference in New Issue
Block a user