Skyscraper 2.0
vmconsole.h
Go to the documentation of this file.
1/*
2 Skyscraper 2.0 - Virtual Manager Console
3 Copyright (C)2004-2025 Ryan Thoryk
4 https://www.skyscrapersim.net
5 https://sourceforge.net/projects/skyscraper/
6 Contact - ryan@skyscrapersim.net
7
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License
10 as published by the Free Software Foundation; either version 2
11 of the License, or (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21*/
22
23#ifndef VMCONSOLE_H
24#define VMCONSOLE_H
25
26namespace Skyscraper {
27
28class GUI;
29
31{
32 std::string textbuffer;
33 std::atomic<bool> ready;
34 std::atomic<bool> threadwait;
35 std::atomic<bool> server_ready;
36};
37
39{
40public:
41 VMConsole(VM *vm);
42 ~VMConsole();
43 void Process(const std::string &text = "", bool echo = true);
44 bool Report(const std::string &text, const std::string &color = "cyan");
45 bool ReportError(const std::string &text);
46
47private:
49 std::string buffer;
50};
51
52//Virtual Manager Console
54{
55public:
56 void operator()(int delay);
57private:
58};
59
60std::string GetColors(const std::string &color);
61
62}
63
64#endif
std::string buffer
Definition vmconsole.h:49
std::string GetColors(const std::string &color)
std::atomic< bool > server_ready
Definition vmconsole.h:35
std::atomic< bool > ready
Definition vmconsole.h:33
std::atomic< bool > threadwait
Definition vmconsole.h:34
#define VMIMPEXP
Definition vm.h:49