SystemPropertiesImpl.cpp revision 26d2a42f095ded346df2e41cc4837cb426b4753a
c936b605260fac01308e3f63b869f401321c52b3vboxsync * VirtualBox COM class implementation
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Copyright (C) 2006-2008 Sun Microsystems, Inc.
c936b605260fac01308e3f63b869f401321c52b3vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
c936b605260fac01308e3f63b869f401321c52b3vboxsync * available from http://www.virtualbox.org. This file is free software;
c936b605260fac01308e3f63b869f401321c52b3vboxsync * you can redistribute it and/or modify it under the terms of the GNU
c936b605260fac01308e3f63b869f401321c52b3vboxsync * General Public License (GPL) as published by the Free Software
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
c936b605260fac01308e3f63b869f401321c52b3vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
c936b605260fac01308e3f63b869f401321c52b3vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Clara, CA 95054 USA or visit http://www.sun.com if you need
c936b605260fac01308e3f63b869f401321c52b3vboxsync * additional information or have any questions.
c936b605260fac01308e3f63b869f401321c52b3vboxsync// generated header
c936b605260fac01308e3f63b869f401321c52b3vboxsync/////////////////////////////////////////////////////////////////////////////
c936b605260fac01308e3f63b869f401321c52b3vboxsync// constructor / destructor
c936b605260fac01308e3f63b869f401321c52b3vboxsync/////////////////////////////////////////////////////////////////////////////
c936b605260fac01308e3f63b869f401321c52b3vboxsync// public methods only for internal purposes
c936b605260fac01308e3f63b869f401321c52b3vboxsync/////////////////////////////////////////////////////////////////////////////
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Initializes the system information object.
c936b605260fac01308e3f63b869f401321c52b3vboxsync * @returns COM result indicator
c936b605260fac01308e3f63b869f401321c52b3vboxsyncHRESULT SystemProperties::init (VirtualBox *aParent)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* Enclose the state transition NotReady->InInit->Ready */
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* Fetch info of all available hd backends. */
c936b605260fac01308e3f63b869f401321c52b3vboxsync /// @todo NEWMEDIA VDBackendInfo needs to be improved to let us enumerate
c936b605260fac01308e3f63b869f401321c52b3vboxsync /// any number of backends
c936b605260fac01308e3f63b869f401321c52b3vboxsync /// @todo We currently leak memory because it's not actually clear what to
c936b605260fac01308e3f63b869f401321c52b3vboxsync /// free in structures returned by VDBackendInfo. Must be fixed ASAP!
c936b605260fac01308e3f63b869f401321c52b3vboxsync int vrc = VDBackendInfo (RT_ELEMENTS (aVDInfo), aVDInfo, &cEntries);
c936b605260fac01308e3f63b869f401321c52b3vboxsync for (unsigned i = 0; i < cEntries; ++ i)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* Confirm a successful initialization */
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Uninitializes the instance and sets the ready flag to FALSE.
c936b605260fac01308e3f63b869f401321c52b3vboxsync * Called either from FinalRelease() or by the parent when it gets destroyed.
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* Enclose the state transition Ready->InUninit->NotReady */
c936b605260fac01308e3f63b869f401321c52b3vboxsync// ISystemProperties properties
c936b605260fac01308e3f63b869f401321c52b3vboxsync/////////////////////////////////////////////////////////////////////////////
c936b605260fac01308e3f63b869f401321c52b3vboxsyncSTDMETHODIMP SystemProperties::COMGETTER(MinGuestRAM)(ULONG *minRAM)
90e8b000bdf708e8465e9c2cd7ecf1339c27c4aavboxsync /* no need to lock, this is const */
c936b605260fac01308e3f63b869f401321c52b3vboxsyncSTDMETHODIMP SystemProperties::COMGETTER(MaxGuestRAM)(ULONG *maxRAM)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* no need to lock, this is const */
c936b605260fac01308e3f63b869f401321c52b3vboxsyncSTDMETHODIMP SystemProperties::COMGETTER(MinGuestVRAM)(ULONG *minVRAM)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* no need to lock, this is const */
c936b605260fac01308e3f63b869f401321c52b3vboxsyncSTDMETHODIMP SystemProperties::COMGETTER(MaxGuestVRAM)(ULONG *maxVRAM)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* no need to lock, this is const */
c936b605260fac01308e3f63b869f401321c52b3vboxsyncSTDMETHODIMP SystemProperties::COMGETTER(MaxGuestMonitors)(ULONG *maxMonitors)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /* no need to lock, this is const */
c936b605260fac01308e3f63b869f401321c52b3vboxsyncSTDMETHODIMP SystemProperties::COMGETTER(MaxVDISize)(ULONG64 *maxVDISize)
c936b605260fac01308e3f63b869f401321c52b3vboxsync /** The BIOS supports currently 32 bit LBA numbers (implementing the full
c936b605260fac01308e3f63b869f401321c52b3vboxsync * 48 bit range is in theory trivial, but the crappy compiler makes things
c936b605260fac01308e3f63b869f401321c52b3vboxsync * more difficult). This translates to almost 2 TBytes (to be on the safe
c936b605260fac01308e3f63b869f401321c52b3vboxsync * side, the reported limit is 1 MiByte less than that, as the total number
c936b605260fac01308e3f63b869f401321c52b3vboxsync * of sectors should fit in 32 bits, too), which should bei enough for
c936b605260fac01308e3f63b869f401321c52b3vboxsync * the moment. The virtual ATA disks support complete LBA48 (although for
c936b605260fac01308e3f63b869f401321c52b3vboxsync * example iSCSI is also currently limited to 32 bit LBA), so the
return S_OK;
if (!count)
return E_POINTER;
return S_OK;
if (!count)
return E_POINTER;
return S_OK;
if (!count)
return E_POINTER;
return S_OK;
if (!aMaxBootPosition)
return E_POINTER;
return S_OK;
if (!aDefaultMachineFolder)
return E_POINTER;
return S_OK;
return rc;
if (!aDefaultHardDiskFolder)
return E_POINTER;
return S_OK;
return rc;
return E_POINTER;
return S_OK;
if (!aDefaultHardDiskFormat)
return E_POINTER;
return S_OK;
return rc;
STDMETHODIMP SystemProperties::COMGETTER(RemoteDisplayAuthLibrary) (BSTR *aRemoteDisplayAuthLibrary)
return E_POINTER;
return S_OK;
STDMETHODIMP SystemProperties::COMSETTER(RemoteDisplayAuthLibrary) (INPTR BSTR aRemoteDisplayAuthLibrary)
return rc;
if (!aWebServiceAuthLibrary)
return E_POINTER;
return S_OK;
return rc;
if (!enabled)
return E_POINTER;
return S_OK;
return rc;
if (!count)
return E_POINTER;
return S_OK;
return rc;
using namespace settings;
return S_OK;
using namespace settings;
return S_OK;
return format;
return S_OK;
return S_OK;
return S_OK;
return S_OK;
return S_OK;