1 | /* $Id: VRDEServerImpl.h 93115 2022-01-01 11:31:46Z vboxsync $ */
|
---|
2 |
|
---|
3 | /** @file
|
---|
4 | *
|
---|
5 | * VirtualBox COM class implementation
|
---|
6 | */
|
---|
7 |
|
---|
8 | /*
|
---|
9 | * Copyright (C) 2006-2022 Oracle Corporation
|
---|
10 | *
|
---|
11 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
12 | * available from http://www.virtualbox.org. This file is free software;
|
---|
13 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
14 | * General Public License (GPL) as published by the Free Software
|
---|
15 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
16 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
17 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
18 | */
|
---|
19 |
|
---|
20 | #ifndef MAIN_INCLUDED_VRDEServerImpl_h
|
---|
21 | #define MAIN_INCLUDED_VRDEServerImpl_h
|
---|
22 | #ifndef RT_WITHOUT_PRAGMA_ONCE
|
---|
23 | # pragma once
|
---|
24 | #endif
|
---|
25 |
|
---|
26 | #include "VRDEServerWrap.h"
|
---|
27 |
|
---|
28 | namespace settings
|
---|
29 | {
|
---|
30 | struct VRDESettings;
|
---|
31 | }
|
---|
32 |
|
---|
33 | class ATL_NO_VTABLE VRDEServer :
|
---|
34 | public VRDEServerWrap
|
---|
35 | {
|
---|
36 | public:
|
---|
37 |
|
---|
38 | DECLARE_COMMON_CLASS_METHODS(VRDEServer)
|
---|
39 |
|
---|
40 | HRESULT FinalConstruct();
|
---|
41 | void FinalRelease();
|
---|
42 |
|
---|
43 | // public initializer/uninitializer for internal purposes only
|
---|
44 | HRESULT init(Machine *aParent);
|
---|
45 | HRESULT init(Machine *aParent, VRDEServer *aThat);
|
---|
46 | HRESULT initCopy(Machine *aParent, VRDEServer *aThat);
|
---|
47 | void uninit();
|
---|
48 |
|
---|
49 | // public methods only for internal purposes
|
---|
50 | HRESULT i_loadSettings(const settings::VRDESettings &data);
|
---|
51 | HRESULT i_saveSettings(settings::VRDESettings &data);
|
---|
52 | void i_rollback();
|
---|
53 | void i_commit();
|
---|
54 | void i_copyFrom(VRDEServer *aThat);
|
---|
55 |
|
---|
56 | private:
|
---|
57 |
|
---|
58 | // wrapped IVRDEServer properties
|
---|
59 | HRESULT getEnabled(BOOL *aEnabled);
|
---|
60 | HRESULT setEnabled(BOOL aEnabled);
|
---|
61 | HRESULT getAuthType(AuthType_T *aAuthType);
|
---|
62 | HRESULT setAuthType(AuthType_T aAuthType);
|
---|
63 | HRESULT getAuthTimeout(ULONG *aAuthTimeout);
|
---|
64 | HRESULT setAuthTimeout(ULONG aAuthTimeout);
|
---|
65 | HRESULT getAllowMultiConnection(BOOL *aAllowMultiConnection);
|
---|
66 | HRESULT setAllowMultiConnection(BOOL aAllowMultiConnection);
|
---|
67 | HRESULT getReuseSingleConnection(BOOL *aReuseSingleConnection);
|
---|
68 | HRESULT setReuseSingleConnection(BOOL aReuseSingleConnection);
|
---|
69 | HRESULT getVRDEExtPack(com::Utf8Str &aVRDEExtPack);
|
---|
70 | HRESULT setVRDEExtPack(const com::Utf8Str &aVRDEExtPack);
|
---|
71 | HRESULT getAuthLibrary(com::Utf8Str &aAuthLibrary);
|
---|
72 | HRESULT setAuthLibrary(const com::Utf8Str &aAuthLibrary);
|
---|
73 | HRESULT getVRDEProperties(std::vector<com::Utf8Str> &aVRDEProperties);
|
---|
74 |
|
---|
75 | // wrapped IVRDEServer methods
|
---|
76 | HRESULT setVRDEProperty(const com::Utf8Str &aKey,
|
---|
77 | const com::Utf8Str &aValue);
|
---|
78 | HRESULT getVRDEProperty(const com::Utf8Str &aKey,
|
---|
79 | com::Utf8Str &aValue);
|
---|
80 |
|
---|
81 | Machine * const mParent;
|
---|
82 | const ComObjPtr<VRDEServer> mPeer;
|
---|
83 |
|
---|
84 | Backupable<settings::VRDESettings> mData;
|
---|
85 | };
|
---|
86 |
|
---|
87 | #endif /* !MAIN_INCLUDED_VRDEServerImpl_h */
|
---|
88 | /* vi: set tabstop=4 shiftwidth=4 expandtab: */
|
---|