VirtualBox

source: vbox/trunk/src/VBox/Main/include/GuestImpl.h@ 4314

Last change on this file since 4314 was 4314, checked in by vboxsync, 18 years ago

Added memory balloon property to the Guest class

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.5 KB
Line 
1/** @file
2 *
3 * VirtualBox COM class implementation
4 */
5
6/*
7 * Copyright (C) 2006-2007 innotek GmbH
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License as published by the Free Software Foundation,
13 * in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
14 * distribution. VirtualBox OSE is distributed in the hope that it will
15 * be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18#ifndef ____H_GUESTIMPL
19#define ____H_GUESTIMPL
20
21#include "VirtualBoxBase.h"
22
23class Console;
24
25class ATL_NO_VTABLE Guest :
26 public VirtualBoxSupportErrorInfoImpl <Guest, IGuest>,
27 public VirtualBoxSupportTranslation <Guest>,
28 public VirtualBoxBase,
29 public IGuest
30{
31public:
32
33 DECLARE_NOT_AGGREGATABLE(Guest)
34
35 DECLARE_PROTECT_FINAL_CONSTRUCT()
36
37 BEGIN_COM_MAP(Guest)
38 COM_INTERFACE_ENTRY(ISupportErrorInfo)
39 COM_INTERFACE_ENTRY(IGuest)
40 END_COM_MAP()
41
42 NS_DECL_ISUPPORTS
43
44 DECLARE_EMPTY_CTOR_DTOR (Guest)
45
46 HRESULT FinalConstruct();
47 void FinalRelease();
48
49 // public initializer/uninitializer for internal purposes only
50 HRESULT init (Console *aParent);
51 void uninit();
52
53 // IGuest properties
54 STDMETHOD(COMGETTER(OSTypeId)) (BSTR *aOSTypeId);
55 STDMETHOD(COMGETTER(AdditionsActive)) (BOOL *aAdditionsActive);
56 STDMETHOD(COMGETTER(AdditionsVersion)) (BSTR *aAdditionsVersion);
57 STDMETHOD(COMGETTER(SupportsSeamless)) (BOOL *aSupportsSeamless);
58 STDMETHOD(COMGETTER(MemoryBalloonSize)) (ULONG *aMemoryBalloonSize);
59 STDMETHOD(COMSETTER(MemoryBalloonSize)) (ULONG aMemoryBalloonSize);
60
61 // IGuest methods
62 STDMETHOD(SetCredentials)(INPTR BSTR aUserName, INPTR BSTR aPassword,
63 INPTR BSTR aDomain, BOOL aAllowInteractiveLogon);
64
65 // public methods that are not in IDL
66 void setAdditionsVersion (Bstr aVersion);
67
68 void setSupportsSeamless (BOOL aSupportsSeamless);
69
70 // for VirtualBoxSupportErrorInfoImpl
71 static const wchar_t *getComponentName() { return L"Guest"; }
72
73private:
74
75 struct Data
76 {
77 Data() : mAdditionsActive (FALSE), mSupportsSeamless (FALSE) {}
78
79 Bstr mOSTypeId;
80 BOOL mAdditionsActive;
81 Bstr mAdditionsVersion;
82 BOOL mSupportsSeamless;
83 };
84
85 ULONG mMemoryBalloonSize;
86
87 ComObjPtr <Console, ComWeakRef> mParent;
88 Data mData;
89};
90
91#endif // ____H_GUESTIMPL
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