VirtualBox

source: vbox/trunk/src/VBox/Main/include/VRDPServerImpl.h@ 30714

Last change on this file since 30714 was 30714, checked in by vboxsync, 14 years ago

Main: remove SupportErrorInfo template magic

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.5 KB
Line 
1/* $Id: VRDPServerImpl.h 30714 2010-07-07 16:20:03Z vboxsync $ */
2
3/** @file
4 *
5 * VirtualBox COM class implementation
6 */
7
8/*
9 * Copyright (C) 2006-2007 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 ____H_VRDPSERVER
21#define ____H_VRDPSERVER
22
23#include "VirtualBoxBase.h"
24
25#include <VBox/VRDPAuth.h>
26
27namespace settings
28{
29 struct VRDPSettings;
30}
31
32class ATL_NO_VTABLE VRDPServer :
33 public VirtualBoxBase,
34 public VirtualBoxSupportTranslation<VRDPServer>,
35 VBOX_SCRIPTABLE_IMPL(IVRDPServer)
36{
37public:
38
39 struct Data
40 {
41 BOOL mEnabled;
42 Bstr mVRDPPorts;
43 Bstr mVRDPAddress;
44 VRDPAuthType_T mAuthType;
45 ULONG mAuthTimeout;
46 BOOL mAllowMultiConnection;
47 BOOL mReuseSingleConnection;
48 BOOL mVideoChannel;
49 ULONG mVideoChannelQuality;
50 };
51
52 VIRTUALBOXBASE_ADD_ERRORINFO_SUPPORT(VRDPServer, IVRDPServer)
53
54 DECLARE_NOT_AGGREGATABLE(VRDPServer)
55
56 DECLARE_PROTECT_FINAL_CONSTRUCT()
57
58 BEGIN_COM_MAP(VRDPServer)
59 COM_INTERFACE_ENTRY (ISupportErrorInfo)
60 COM_INTERFACE_ENTRY (IVRDPServer)
61 COM_INTERFACE_ENTRY2 (IDispatch, IVRDPServer)
62 END_COM_MAP()
63
64 DECLARE_EMPTY_CTOR_DTOR (VRDPServer)
65
66 HRESULT FinalConstruct();
67 void FinalRelease();
68
69 // public initializer/uninitializer for internal purposes only
70 HRESULT init(Machine *aParent);
71 HRESULT init(Machine *aParent, VRDPServer *aThat);
72 HRESULT initCopy (Machine *aParent, VRDPServer *aThat);
73 void uninit();
74
75 // IVRDPServer properties
76 STDMETHOD(COMGETTER(Enabled)) (BOOL *aEnabled);
77 STDMETHOD(COMSETTER(Enabled)) (BOOL aEnable);
78 STDMETHOD(COMGETTER(Ports)) (BSTR *aPorts);
79 STDMETHOD(COMSETTER(Ports)) (IN_BSTR aPorts);
80 STDMETHOD(COMGETTER(NetAddress)) (BSTR *aAddress);
81 STDMETHOD(COMSETTER(NetAddress)) (IN_BSTR aAddress);
82 STDMETHOD(COMGETTER(AuthType)) (VRDPAuthType_T *aType);
83 STDMETHOD(COMSETTER(AuthType)) (VRDPAuthType_T aType);
84 STDMETHOD(COMGETTER(AuthTimeout)) (ULONG *aTimeout);
85 STDMETHOD(COMSETTER(AuthTimeout)) (ULONG aTimeout);
86 STDMETHOD(COMGETTER(AllowMultiConnection)) (BOOL *aAllowMultiConnection);
87 STDMETHOD(COMSETTER(AllowMultiConnection)) (BOOL aAllowMultiConnection);
88 STDMETHOD(COMGETTER(ReuseSingleConnection)) (BOOL *aReuseSingleConnection);
89 STDMETHOD(COMSETTER(ReuseSingleConnection)) (BOOL aReuseSingleConnection);
90 STDMETHOD(COMGETTER(VideoChannel)) (BOOL *aVideoChannel);
91 STDMETHOD(COMSETTER(VideoChannel)) (BOOL aVideoChannel);
92 STDMETHOD(COMGETTER(VideoChannelQuality)) (ULONG *aVideoChannelQuality);
93 STDMETHOD(COMSETTER(VideoChannelQuality)) (ULONG aVideoChannelQuality);
94
95 // IVRDPServer methods
96
97 // public methods only for internal purposes
98
99 HRESULT loadSettings(const settings::VRDPSettings &data);
100 HRESULT saveSettings(settings::VRDPSettings &data);
101
102 void rollback();
103 void commit();
104 void copyFrom (VRDPServer *aThat);
105
106private:
107
108 Machine * const mParent;
109 const ComObjPtr<VRDPServer> mPeer;
110
111 Backupable<Data> mData;
112};
113
114#endif // ____H_VRDPSERVER
115/* vi: set tabstop=4 shiftwidth=4 expandtab: */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette