Symbian platform (C++)
SDK native APIs, runtime and tooling
Loading...
Searching...
No Matches
control.h
Go to the documentation of this file.
1// SPDX-License-Identifier: GPL-3.0-or-later
2#ifndef SYMBIAN_EMULATOR_CONTROL_H_
3#define SYMBIAN_EMULATOR_CONTROL_H_
4
5#include <memory>
6
7#include "absl/status/statusor.h"
8
9namespace eka2l1::desktop {
10struct emulator;
11}
12
13namespace symbian::emulator {
14
15// Owns callbacks on EKA2L1's existing Qt and kernel event loops. There are no
16// new worker threads, schedulers, Python callbacks or Python reference holders.
18 public:
20 ControlServer(const ControlServer&) = delete;
22
23 // Empty socket_path disables control. Enabled sockets require an existing
24 // private directory, and only expose emulator capture, pointer and status.
25 static absl::StatusOr<std::unique_ptr<ControlServer>> Start(
26 eka2l1::desktop::emulator* state, const char* socket_path);
27
28 // Called on the Qt loop before stopping EKA2L1's workers/kernel. Detaches
29 // callbacks and saves the final status beside the socket, without overwrites.
30 absl::Status Stop();
31
32 private:
33 struct Impl;
34 explicit ControlServer(std::unique_ptr<Impl> impl);
35 std::unique_ptr<Impl> impl_;
36};
37
38} // namespace symbian::emulator
39#endif // SYMBIAN_EMULATOR_CONTROL_H_
Definition control.h:17
ControlServer(const ControlServer &)=delete
absl::Status Stop()
Definition control.cc:304
ControlServer & operator=(const ControlServer &)=delete
static absl::StatusOr< std::unique_ptr< ControlServer > > Start(eka2l1::desktop::emulator *state, const char *socket_path)
Definition control.cc:308
Definition control.h:9
Definition control.cc:34