Changeset 30760 in vbox
- Timestamp:
- Jul 9, 2010 1:12:04 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 63543
- Location:
- trunk
- Files:
-
- 1 deleted
- 51 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/settings.h
r29873 r30760 841 841 public: 842 842 com::Guid uuid; 843 844 com::Utf8Str strStateFile; 845 com::Guid uuidCurrentSnapshot; 846 843 847 com::Utf8Str strName; 844 848 bool fNameSync; 845 849 com::Utf8Str strDescription; 846 850 com::Utf8Str strOsType; 847 com::Utf8Str strStateFile;848 com::Guid uuidCurrentSnapshot;849 851 com::Utf8Str strSnapshotFolder; 850 852 bool fTeleporterEnabled; -
trunk/src/VBox/Frontends/VBoxBFE/Makefile.kmk
r28800 r30760 24 24 # 25 25 VBOXBFE_MAIN_CPP = MouseImpl.cpp 26 VBOXBFE_MAIN_H = MouseImpl.h ConsoleEvents.h26 VBOXBFE_MAIN_H = MouseImpl.h 27 27 28 28 # -
trunk/src/VBox/Main/ApplianceImpl.cpp
r30716 r30760 20 20 #include <iprt/cpp/utils.h> 21 21 22 #include <VBox/com/array.h>23 24 #include "ApplianceImpl.h"25 22 #include "VFSExplorerImpl.h" 26 23 #include "VirtualBoxImpl.h" … … 29 26 #include "MachineImpl.h" 30 27 28 #include "ApplianceImplPrivate.h" 29 31 30 #include "AutoCaller.h" 32 31 #include "Logging.h" 33 32 34 #include "ApplianceImplPrivate.h" 33 #include "VBox/settings.h" 34 35 #include <VBox/com/array.h> 35 36 36 37 using namespace std; -
trunk/src/VBox/Main/ApplianceImplExport.cpp
r30746 r30760 17 17 */ 18 18 19 #include <iprt/file.h> 19 20 #include <iprt/path.h> 20 21 #include <iprt/dir.h> … … 23 24 #include <iprt/manifest.h> 24 25 25 #include <VBox/version.h> 26 27 #include "ApplianceImpl.h" 26 #include "AudioAdapterImpl.h" 28 27 #include "VirtualBoxImpl.h" 29 30 28 #include "ProgressImpl.h" 31 #include "MachineImpl.h" 29 #include "MachineImplPrivate.h" 30 #include "MediumAttachmentImpl.h" 31 32 #include "ApplianceImplPrivate.h" 32 33 33 34 #include "AutoCaller.h" 34 35 #include "Logging.h" 35 36 36 #include "ApplianceImplPrivate.h" 37 #include <VBox/version.h> 38 #include <VBox/com/array.h> 37 39 38 40 using namespace std; … … 275 277 // <const name="CDROM" value="19" /> 276 278 277 Medi aData::AttachmentList::iterator itA;279 MediumAttachmentsList::iterator itA; 278 280 for (itA = mMediaData->mAttachments.begin(); 279 281 itA != mMediaData->mAttachments.end(); -
trunk/src/VBox/Main/ApplianceImplImport.cpp
r30746 r30760 24 24 #include <iprt/manifest.h> 25 25 26 #include <VBox/com/array.h>27 28 #include "ApplianceImpl.h"29 26 #include "VirtualBoxImpl.h" 30 27 #include "GuestOSTypeImpl.h" … … 32 29 #include "MachineImpl.h" 33 30 31 #include "ApplianceImplPrivate.h" 32 34 33 #include "AutoCaller.h" 35 34 #include "Logging.h" 36 37 #include "ApplianceImplPrivate.h"38 35 39 36 #include <VBox/param.h> 40 37 #include <VBox/version.h> 41 38 #include <VBox/settings.h> 39 40 #include <VBox/com/array.h> 42 41 43 42 using namespace std; -
trunk/src/VBox/Main/ConsoleVRDPServer.cpp
r30714 r30760 16 16 */ 17 17 18 #include "RemoteUSBBackend.h" 18 19 #include "ConsoleVRDPServer.h" 19 20 #include "ConsoleImpl.h" -
trunk/src/VBox/Main/DHCPServerImpl.cpp
r30681 r30760 18 18 */ 19 19 20 #include "DHCPServerRunner.h"21 20 #include "DHCPServerImpl.h" 22 21 #include "AutoCaller.h" -
trunk/src/VBox/Main/HostImpl.cpp
r30743 r30760 140 140 #include <VBox/sup.h> 141 141 142 #include <VBox/com/array.h> 142 143 #include "VBox/com/MultiResult.h" 143 144 -
trunk/src/VBox/Main/HostPower.cpp
r28800 r30760 29 29 30 30 #include <iprt/mem.h> 31 32 #ifdef VBOX_WITH_RESOURCE_USAGE_API 33 #include "Performance.h" 34 #include "PerformanceImpl.h" 35 #endif /* VBOX_WITH_RESOURCE_USAGE_API */ 31 36 32 37 HostPowerService::HostPowerService (VirtualBox *aVirtualBox) -
trunk/src/VBox/Main/MachineImpl.cpp
r30739 r30760 34 34 #include "Logging.h" 35 35 #include "VirtualBoxImpl.h" 36 #include "MachineImpl.h" 37 #include "ProgressImpl.h" 38 #include "ProgressProxyImpl.h" 36 #include "MachineImplPrivate.h" 37 38 #include "VirtualBoxErrorInfoImpl.h" 39 40 #include "AudioAdapterImpl.h" 41 #include "BIOSSettingsImpl.h" 42 #include "GuestImpl.h" 43 #include "GuestOSTypeImpl.h" 44 #include "HostImpl.h" 39 45 #include "MediumAttachmentImpl.h" 40 46 #include "MediumImpl.h" 41 47 #include "MediumLock.h" 48 #include "NetworkAdapterImpl.h" 49 #include "ParallelPortImpl.h" 50 #include "ProgressProxyImpl.h" 42 51 #include "USBControllerImpl.h" 43 #include " HostImpl.h"52 #include "SerialPortImpl.h" 44 53 #include "SharedFolderImpl.h" 45 #include "GuestOSTypeImpl.h"46 #include "VirtualBoxErrorInfoImpl.h"47 #include "GuestImpl.h"48 54 #include "StorageControllerImpl.h" 55 #include "VRDPServerImpl.h" 49 56 50 57 #ifdef VBOX_WITH_USB … … 52 59 #endif 53 60 61 #ifdef VBOX_WITH_RESOURCE_USAGE_API 62 # include "Performance.h" 63 # include "PerformanceImpl.h" 64 #endif /* VBOX_WITH_RESOURCE_USAGE_API */ 65 54 66 #include "AutoCaller.h" 55 67 #include "Performance.h" 56 68 57 69 #include <iprt/asm.h> 70 #include <iprt/file.h> 58 71 #include <iprt/path.h> 59 72 #include <iprt/dir.h> … … 2910 2923 if (aType == DeviceType_HardDisk && mMediaData.isBackedUp()) 2911 2924 { 2912 const Medi aData::AttachmentList &oldAtts = mMediaData.backedUpData()->mAttachments;2925 const MediumAttachmentsList &oldAtts = mMediaData.backedUpData()->mAttachments; 2913 2926 2914 2927 /* check if the medium was attached to the VM before we started … … 2950 2963 if (mMediaData.isBackedUp()) 2951 2964 { 2952 const Medi aData::AttachmentList &oldAtts = mMediaData.backedUpData()->mAttachments;2953 2954 Medi aData::AttachmentList::const_iterator foundIt = oldAtts.end();2965 const MediumAttachmentsList &oldAtts = mMediaData.backedUpData()->mAttachments; 2966 2967 MediumAttachmentsList::const_iterator foundIt = oldAtts.end(); 2955 2968 uint32_t foundLevel = 0; 2956 2969 2957 for (Medi aData::AttachmentList::const_iterator it = oldAtts.begin();2970 for (MediumAttachmentsList::const_iterator it = oldAtts.begin(); 2958 2971 it != oldAtts.end(); 2959 2972 ++it) … … 3025 3038 AutoReadLock snapLock(snap COMMA_LOCKVAL_SRC_POS); 3026 3039 3027 const Medi aData::AttachmentList &snapAtts = snap->getSnapshotMachine()->mMediaData->mAttachments;3028 3029 Medi aData::AttachmentList::const_iterator foundIt = snapAtts.end();3040 const MediumAttachmentsList &snapAtts = snap->getSnapshotMachine()->mMediaData->mAttachments; 3041 3042 MediumAttachmentsList::const_iterator foundIt = snapAtts.end(); 3030 3043 uint32_t foundLevel = 0; 3031 3044 3032 for (Medi aData::AttachmentList::const_iterator it = snapAtts.begin();3045 for (MediumAttachmentsList::const_iterator it = snapAtts.begin(); 3033 3046 it != snapAtts.end(); 3034 3047 ++it) … … 4374 4387 ComSafeArrayOut(IMediumAttachment*, aAttachments)) 4375 4388 { 4376 Medi aData::AttachmentList atts;4389 MediumAttachmentsList atts; 4377 4390 4378 4391 HRESULT rc = getMediumAttachmentsOfController(aName, atts); … … 4540 4553 /* We can remove the controller only if there is no device attached. */ 4541 4554 /* check if the device slot is already busy */ 4542 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();4555 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 4543 4556 it != mMediaData->mAttachments.end(); 4544 4557 ++it) … … 5038 5051 5039 5052 /** 5053 * Returns true if the machine is registered. 5054 * 5055 * @note This method doesn't check this object's readiness. Intended to be 5056 * used by ready Machine children (whose readiness is bound to the parent's 5057 * one) or after doing addCaller() manually. 5058 */ 5059 bool Machine::isRegistered() const 5060 { 5061 return !!mData->mRegistered; 5062 } 5063 5064 /** 5065 * Returns this machine ID. 5066 * 5067 * @note This method doesn't check this object's readiness. Intended to be 5068 * used by ready Machine children (whose readiness is bound to the parent's 5069 * one) or after adding a caller manually. 5070 */ 5071 const Guid& Machine::getId() const 5072 { 5073 return mData->mUuid; 5074 } 5075 5076 /** 5077 * Returns this machine's full settings file path. 5078 * 5079 * @note This method doesn't lock this object or check its readiness. 5080 * Intended to be used only after doing addCaller() manually and locking it 5081 * for reading. 5082 */ 5083 const Utf8Str& Machine::getSettingsFileFull() const 5084 { 5085 return mData->m_strConfigFileFull; 5086 } 5087 5088 /** 5089 * Returns this machine name. 5090 * 5091 * @note This method doesn't lock this object or check its readiness. 5092 * Intended to be used only after doing addCaller() manually and locking it 5093 * for reading. 5094 */ 5095 const Bstr& Machine::getName() const 5096 { 5097 return mUserData->mName; 5098 } 5099 5100 5101 /** 5040 5102 * Adds the given IsModified_* flag to the dirty flags of the machine. 5103 * 5041 5104 * This must be called either during loadSettings or under the machine write lock. 5105 * 5042 5106 * @param fl 5043 5107 */ … … 5709 5773 } 5710 5774 5775 HRESULT Machine::getDirectControl(ComPtr<IInternalSessionControl> &directControl) 5776 { 5777 directControl = mData->mSession.mDirectControl; 5778 5779 if (directControl.isNull()) 5780 return E_ACCESSDENIED; 5781 5782 return S_OK; 5783 } 5784 5711 5785 /** 5712 5786 * Returns @c true if the given machine has an open direct session and returns … … 6360 6434 ) 6361 6435 { 6362 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();6436 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 6363 6437 it != mMediaData->mAttachments.end(); 6364 6438 ++it) … … 7307 7381 7308 7382 HRESULT Machine::getMediumAttachmentsOfController(CBSTR aName, 7309 Medi aData::AttachmentList &atts)7383 MediumAttachmentsList &atts) 7310 7384 { 7311 7385 AutoCaller autoCaller(this); … … 7314 7388 AutoReadLock alock(this COMMA_LOCKVAL_SRC_POS); 7315 7389 7316 for (Medi aData::AttachmentList::iterator it = mMediaData->mAttachments.begin();7390 for (MediumAttachmentsList::iterator it = mMediaData->mAttachments.begin(); 7317 7391 it != mMediaData->mAttachments.end(); 7318 7392 ++it) … … 8070 8144 settings::StorageController &data) 8071 8145 { 8072 Medi aData::AttachmentList atts;8146 MediumAttachmentsList atts; 8073 8147 8074 8148 HRESULT rc = getMediumAttachmentsOfController(Bstr(aStorageController->getName()), atts); … … 8076 8150 8077 8151 data.llAttachedDevices.clear(); 8078 for (Medi aData::AttachmentList::const_iterator it = atts.begin();8152 for (MediumAttachmentsList::const_iterator it = atts.begin(); 8079 8153 it != atts.end(); 8080 8154 ++it) … … 8236 8310 /* lock all attached hard disks early to detect "in use" 8237 8311 * situations before creating actual diffs */ 8238 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();8312 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 8239 8313 it != mMediaData->mAttachments.end(); 8240 8314 ++it) … … 8276 8350 /* remember the current list (note that we don't use backup() since 8277 8351 * mMediaData may be already backed up) */ 8278 Medi aData::AttachmentList atts = mMediaData->mAttachments;8352 MediumAttachmentsList atts = mMediaData->mAttachments; 8279 8353 8280 8354 /* start from scratch */ … … 8283 8357 /* go through remembered attachments and create diffs for normal hard 8284 8358 * disks and attach them */ 8285 for (Medi aData::AttachmentList::const_iterator it = atts.begin();8359 for (MediumAttachmentsList::const_iterator it = atts.begin(); 8286 8360 it != atts.end(); 8287 8361 ++it) … … 8427 8501 HRESULT rc = S_OK; 8428 8502 8429 Medi aData::AttachmentList implicitAtts;8430 8431 const Medi aData::AttachmentList &oldAtts = mMediaData.backedUpData()->mAttachments;8503 MediumAttachmentsList implicitAtts; 8504 8505 const MediumAttachmentsList &oldAtts = mMediaData.backedUpData()->mAttachments; 8432 8506 8433 8507 /* enumerate new attachments */ 8434 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();8508 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 8435 8509 it != mMediaData->mAttachments.end(); 8436 8510 ++it) … … 8485 8559 alock.leave(); 8486 8560 8487 for (Medi aData::AttachmentList::const_iterator it = implicitAtts.begin();8561 for (MediumAttachmentsList::const_iterator it = implicitAtts.begin(); 8488 8562 it != implicitAtts.end(); 8489 8563 ++it) … … 8520 8594 * @return 8521 8595 */ 8522 MediumAttachment* Machine::findAttachment(const Medi aData::AttachmentList &ll,8596 MediumAttachment* Machine::findAttachment(const MediumAttachmentsList &ll, 8523 8597 IN_BSTR aControllerName, 8524 8598 LONG aControllerPort, 8525 8599 LONG aDevice) 8526 8600 { 8527 for (Medi aData::AttachmentList::const_iterator it = ll.begin();8601 for (MediumAttachmentsList::const_iterator it = ll.begin(); 8528 8602 it != ll.end(); 8529 8603 ++it) … … 8548 8622 * @return 8549 8623 */ 8550 MediumAttachment* Machine::findAttachment(const Medi aData::AttachmentList &ll,8624 MediumAttachment* Machine::findAttachment(const MediumAttachmentsList &ll, 8551 8625 ComObjPtr<Medium> pMedium) 8552 8626 { 8553 for (Medi aData::AttachmentList::const_iterator it = ll.begin();8627 for (MediumAttachmentsList::const_iterator it = ll.begin(); 8554 8628 it != ll.end(); 8555 8629 ++it) … … 8575 8649 * @return 8576 8650 */ 8577 MediumAttachment* Machine::findAttachment(const Medi aData::AttachmentList &ll,8651 MediumAttachment* Machine::findAttachment(const MediumAttachmentsList &ll, 8578 8652 Guid &id) 8579 8653 { 8580 for (Medi aData::AttachmentList::const_iterator it = ll.begin();8654 for (MediumAttachmentsList::const_iterator it = ll.begin(); 8581 8655 it != ll.end(); 8582 8656 ++it) … … 8620 8694 return; 8621 8695 8622 Medi aData::AttachmentList &oldAtts = mMediaData.backedUpData()->mAttachments;8696 MediumAttachmentsList &oldAtts = mMediaData.backedUpData()->mAttachments; 8623 8697 bool fMediaNeedsLocking = false; 8624 8698 8625 8699 /* enumerate new attachments */ 8626 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();8700 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 8627 8701 it != mMediaData->mAttachments.end(); 8628 8702 ++it) … … 8680 8754 { 8681 8755 /* was this medium attached before? */ 8682 for (Medi aData::AttachmentList::iterator oldIt = oldAtts.begin();8756 for (MediumAttachmentsList::iterator oldIt = oldAtts.begin(); 8683 8757 oldIt != oldAtts.end(); 8684 8758 ++oldIt) … … 8699 8773 /* enumerate remaining old attachments and de-associate from the 8700 8774 * current machine state */ 8701 for (Medi aData::AttachmentList::const_iterator it = oldAtts.begin();8775 for (MediumAttachmentsList::const_iterator it = oldAtts.begin(); 8702 8776 it != oldAtts.end(); 8703 8777 ++it) … … 8778 8852 8779 8853 /* enumerate new attachments */ 8780 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();8854 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 8781 8855 it != mMediaData->mAttachments.end(); 8782 8856 ++it) … … 10861 10935 10862 10936 /* Collect locking information for all medium objects attached to the VM. */ 10863 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();10937 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 10864 10938 it != mMediaData->mAttachments.end(); 10865 10939 ++it) -
trunk/src/VBox/Main/MediumFormatImpl.cpp
r30681 r30760 23 23 24 24 #include <VBox/VBoxHDD.h> 25 26 #include <VBox/com/array.h> 25 27 26 28 #include <iprt/cpp/utils.h> -
trunk/src/VBox/Main/MediumImpl.cpp
r30739 r30760 17 17 18 18 #include "MediumImpl.h" 19 #include "MediumFormatImpl.h" 19 20 #include "ProgressImpl.h" 20 21 #include "SystemPropertiesImpl.h" 21 22 #include "VirtualBoxImpl.h" 23 #include "MediumLock.h" 22 24 23 25 #include "AutoCaller.h" -
trunk/src/VBox/Main/MouseImpl.cpp
r30681 r30760 21 21 #include "DisplayImpl.h" 22 22 #include "VMMDev.h" 23 #include "ConsoleImpl.h" 23 24 24 25 #include "AutoCaller.h" … … 58 59 uint32_t u32DevCaps; 59 60 }; 60 61 61 62 62 // constructor / destructor -
trunk/src/VBox/Main/NATEngineImpl.cpp
r28864 r30760 27 27 #include <VBox/err.h> 28 28 #include <VBox/settings.h> 29 29 #include "VBox/com/array.h" 30 30 31 31 // constructor / destructor -
trunk/src/VBox/Main/Performance.cpp
r29631 r30760 133 133 ComPtr<IInternalSessionControl> directControl; 134 134 135 ret = mMachine->getDirectControl( &directControl);135 ret = mMachine->getDirectControl(directControl); 136 136 if (ret != S_OK) 137 137 return ret; -
trunk/src/VBox/Main/PerformanceImpl.cpp
r29620 r30760 27 27 #include <VBox/err.h> 28 28 #include <VBox/settings.h> 29 30 #include <VBox/com/array.h> 29 31 30 32 #include <vector> -
trunk/src/VBox/Main/SnapshotImpl.cpp
r30681 r30760 21 21 #include "SnapshotImpl.h" 22 22 23 #include "MachineImpl.h" 23 #include "Global.h" 24 25 #include "AudioAdapterImpl.h" 26 #include "BIOSSettingsImpl.h" 27 #include "MachineImplPrivate.h" 24 28 #include "MediumImpl.h" 29 #include "MediumAttachmentImpl.h" 25 30 #include "MediumFormatImpl.h" 26 #include "Global.h" 31 #include "NetworkAdapterImpl.h" 32 #include "ParallelPortImpl.h" 27 33 #include "ProgressImpl.h" 34 #include "SerialPortImpl.h" 35 #include "StorageControllerImpl.h" 36 #include "VRDPServerImpl.h" 28 37 29 38 // @todo these three includes are required for about one or two lines, try … … 35 44 #include "AutoCaller.h" 36 45 46 #include <iprt/file.h> 37 47 #include <iprt/path.h> 38 48 #include <iprt/cpp/utils.h> … … 40 50 #include <VBox/param.h> 41 51 #include <VBox/err.h> 52 53 #include <VBox/com/array.h> 42 54 43 55 #include <VBox/settings.h> … … 896 908 /* associate hard disks with the snapshot 897 909 * (Machine::uninitDataAndChildObjects() will deassociate at destruction) */ 898 for (Medi aData::AttachmentList::const_iterator it = mMediaData->mAttachments.begin();910 for (MediumAttachmentsList::const_iterator it = mMediaData->mAttachments.begin(); 899 911 it != mMediaData->mAttachments.end(); 900 912 ++it) … … 1595 1607 ULONG ulOpCount = 1; // one for preparations 1596 1608 ULONG ulTotalWeight = 1; // one for preparations 1597 for (Medi aData::AttachmentList::iterator it = pSnapMachine->mMediaData->mAttachments.begin();1609 for (MediumAttachmentsList::iterator it = pSnapMachine->mMediaData->mAttachments.begin(); 1598 1610 it != pSnapMachine->mMediaData->mAttachments.end(); 1599 1611 ++it) … … 1825 1837 std::list< ComObjPtr<MediumAttachment> > llDiffAttachmentsToDelete; 1826 1838 1827 for (Medi aData::AttachmentList::const_iterator it = mMediaData.backedUpData()->mAttachments.begin();1839 for (MediumAttachmentsList::const_iterator it = mMediaData.backedUpData()->mAttachments.begin(); 1828 1840 it != mMediaData.backedUpData()->mAttachments.end(); 1829 1841 ++it) … … 2053 2065 2054 2066 // count normal hard disks and add their sizes to the weight 2055 for (Medi aData::AttachmentList::iterator it = pSnapMachine->mMediaData->mAttachments.begin();2067 for (MediumAttachmentsList::iterator it = pSnapMachine->mMediaData->mAttachments.begin(); 2056 2068 it != pSnapMachine->mMediaData->mAttachments.end(); 2057 2069 ++it) … … 2269 2281 // merge it with its one and only child (the diff image holding the 2270 2282 // changes written after the snapshot was taken). 2271 for (Medi aData::AttachmentList::iterator it = pSnapMachine->mMediaData->mAttachments.begin();2283 for (MediumAttachmentsList::iterator it = pSnapMachine->mMediaData->mAttachments.begin(); 2272 2284 it != pSnapMachine->mMediaData->mAttachments.end(); 2273 2285 ++it) -
trunk/src/VBox/Main/SystemPropertiesImpl.cpp
r30681 r30760 21 21 #include "VirtualBoxImpl.h" 22 22 #include "MachineImpl.h" 23 #include "MediumFormatImpl.h" 24 23 25 #include "AutoCaller.h" 24 26 #include "Logging.h" … … 37 39 #include <VBox/settings.h> 38 40 #include <VBox/VBoxHDD.h> 41 42 #include <VBox/com/array.h> 39 43 40 44 // defines -
trunk/src/VBox/Main/USBControllerImpl.cpp
r30739 r30760 34 34 #include <VBox/err.h> 35 35 #include <VBox/settings.h> 36 #include <VBox/com/array.h> 36 37 37 38 #include <algorithm> -
trunk/src/VBox/Main/VirtualBoxImpl.cpp
r30746 r30760 62 62 #include "SystemPropertiesImpl.h" 63 63 #include "GuestOSTypeImpl.h" 64 #include "DHCPServerRunner.h"65 64 #include "DHCPServerImpl.h" 66 65 #ifdef VBOX_WITH_RESOURCE_USAGE_API 67 # include "PerformanceImpl.h"66 # include "PerformanceImpl.h" 68 67 #endif /* VBOX_WITH_RESOURCE_USAGE_API */ 69 68 #include "EventImpl.h" … … 251 250 typedef std::map<Guid, ComPtr<IProgress> > ProgressMap; 252 251 typedef std::map<Guid, ComObjPtr<Medium> > HardDiskMap; 252 253 typedef std::list< VirtualBoxCallbackRegistration > CallbackList; 253 254 254 255 /** -
trunk/src/VBox/Main/glue/errorprint.cpp
r30681 r30760 25 25 #include <iprt/stream.h> 26 26 #include <iprt/path.h> 27 28 #ifndef DEBUG 29 // string used by ComAssert macro (VirtualBoxBase.h) 30 const char *g_pcszComAssertFailedString 31 = "Assertion failed: [%s] at '%s' (%d) in %s.\nPlease contact the product vendor!"; 32 const char *g_pcszComAssertMsgFailedString 33 = "Assertion failed: [%s] at '%s' (%d) in %s.\n%s\nPlease contact the product vendor!"; 34 #endif 27 35 28 36 namespace com -
trunk/src/VBox/Main/include/ApplianceImpl.h
r30739 r30760 24 24 #include "VirtualBoxBase.h" 25 25 26 /* VBox forward declarations */27 class Progress;28 class VirtualSystemDescription;29 struct VirtualSystemDescriptionEntry;30 31 26 namespace ovf 32 27 { … … 35 30 class OVFReader; 36 31 struct DiskImage; 37 }38 39 namespace xml40 {41 class ElementNode;42 }43 44 namespace settings45 {46 class MachineConfigFile;47 32 } 48 33 -
trunk/src/VBox/Main/include/ApplianceImplPrivate.h
r30008 r30760 19 19 #define ____H_APPLIANCEIMPLPRIVATE 20 20 21 class VirtualSystemDescription; 22 21 #include "ApplianceImpl.h" 23 22 #include "ovfreader.h" 24 23 -
trunk/src/VBox/Main/include/AudioAdapterImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 namespace settings26 {27 struct AudioAdapter;28 }29 24 30 25 class ATL_NO_VTABLE AudioAdapter : -
trunk/src/VBox/Main/include/BIOSSettingsImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 class GuestOSType;26 24 27 25 namespace settings -
trunk/src/VBox/Main/include/ConsoleImpl.h
r30739 r30760 24 24 #include "EventImpl.h" 25 25 26 class Guest;27 class Keyboard;28 class Mouse;29 class Display;30 class MachineDebugger;31 class TeleporterStateSrc;32 class OUSBDevice;33 class RemoteUSBDevice;34 class SharedFolder;35 class RemoteDisplayInfo;36 class AudioSniffer;37 class ConsoleVRDPServer;38 class ConsoleCallbackRegistration; /* See ConsoleImpl.cpp. */39 class VMMDev;40 class Progress;41 42 26 #include <VBox/vrdpapi.h> 43 27 #include <VBox/pdmdrv.h> … … 52 36 struct VUSBIRHCONFIG; 53 37 typedef struct VUSBIRHCONFIG *PVUSBIRHCONFIG; 54 55 #include <list>56 38 57 39 // defines -
trunk/src/VBox/Main/include/ConsoleVRDPServer.h
r30739 r30760 21 21 #define ____H_CONSOLEVRDPSERVER 22 22 23 #include "RemoteUSBBackend.h" 23 class Console; 24 class RemoteUSBBackend; 25 24 26 #include <hgcm/HGCM.h> 25 27 … … 53 55 { 54 56 public: 55 ConsoleVRDPServer 56 ~ConsoleVRDPServer 57 ConsoleVRDPServer(Console *console); 58 ~ConsoleVRDPServer(); 57 59 58 60 int Launch (void); -
trunk/src/VBox/Main/include/DHCPServerImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 #include "DHCPServerRunner.h" 24 26 25 27 #ifdef VBOX_WITH_HOSTNETIF_API -
trunk/src/VBox/Main/include/GuestImpl.h
r30758 r30760 41 41 GUESTSTATTYPE_MAX = 9 42 42 } GUESTSTATTYPE; 43 44 class Console;45 #ifdef VBOX_WITH_GUEST_CONTROL46 class Progress;47 #endif48 43 49 44 class ATL_NO_VTABLE Guest : -
trunk/src/VBox/Main/include/HostImpl.h
r30739 r30760 20 20 21 21 #include "VirtualBoxBase.h" 22 23 class HostUSBDeviceFilter;24 class USBProxyService;25 class SessionMachine;26 class Progress;27 class PerformanceCollector;28 29 namespace settings30 {31 struct Host;32 }33 34 #include <list>35 22 36 23 class ATL_NO_VTABLE Host : -
trunk/src/VBox/Main/include/KeyboardImpl.h
r30739 r30760 20 20 21 21 #include "VirtualBoxBase.h" 22 #include "ConsoleEvents.h"23 22 24 23 #include <VBox/pdmdrv.h> … … 26 25 /** Limit of simultaneously attached devices (just USB and/or PS/2). */ 27 26 enum { KEYBOARD_MAX_DEVICES = 2 }; 28 29 /** Simple keyboard event class. */30 class KeyboardEvent31 {32 public:33 KeyboardEvent() : scan(-1) {}34 KeyboardEvent(int _scan) : scan(_scan) {}35 bool isValid()36 {37 return (scan & ~0x80) && !(scan & ~0xFF);38 }39 int scan;40 };41 // template instantiation42 typedef ConsoleEventBuffer<KeyboardEvent> KeyboardEventBuffer;43 27 44 28 class Console; -
trunk/src/VBox/Main/include/MachineDebuggerImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 class Console;26 24 27 25 class ATL_NO_VTABLE MachineDebugger : -
trunk/src/VBox/Main/include/MachineImpl.h
r30739 r30760 21 21 #include "VirtualBoxBase.h" 22 22 #include "SnapshotImpl.h" 23 #include "VRDPServerImpl.h"24 #include "MediumAttachmentImpl.h"25 #include "MediumLock.h"26 #include "NetworkAdapterImpl.h"27 #include "AudioAdapterImpl.h"28 #include "SerialPortImpl.h"29 #include "ParallelPortImpl.h"30 #include "BIOSSettingsImpl.h"31 #include "StorageControllerImpl.h" // required for MachineImpl.h to compile on Windows32 #include "VBox/settings.h"33 #ifdef VBOX_WITH_RESOURCE_USAGE_API34 #include "Performance.h"35 #include "PerformanceImpl.h"36 #endif /* VBOX_WITH_RESOURCE_USAGE_API */37 23 38 24 // generated header … … 41 27 #include "VBox/com/ErrorInfo.h" 42 28 43 #include <iprt/file.h>44 #include <iprt/thread.h>45 #include <iprt/time.h>46 47 29 #include <list> 48 49 // defines50 ////////////////////////////////////////////////////////////////////////////////51 52 // helper declarations53 ////////////////////////////////////////////////////////////////////////////////54 55 class Progress;56 class ProgressProxy;57 class Keyboard;58 class Mouse;59 class Display;60 class MachineDebugger;61 class USBController;62 class Snapshot;63 class SharedFolder;64 class HostUSBDevice;65 class StorageController;66 67 class SessionMachine;68 69 namespace settings70 {71 class MachineConfigFile;72 struct Snapshot;73 struct Hardware;74 struct Storage;75 struct StorageController;76 struct MachineRegistryEntry;77 }78 30 79 31 // Machine class … … 93 45 }; 94 46 95 /** 96 * Internal machine data. 97 * 98 * Only one instance of this data exists per every machine -- it is shared 99 * by the Machine, SessionMachine and all SnapshotMachine instances 100 * associated with the given machine using the util::Shareable template 101 * through the mData variable. 102 * 103 * @note |const| members are persistent during lifetime so can be 104 * accessed without locking. 105 * 106 * @note There is no need to lock anything inside init() or uninit() 107 * methods, because they are always serialized (see AutoCaller). 108 */ 109 struct Data 110 { 111 /** 112 * Data structure to hold information about sessions opened for the 113 * given machine. 114 */ 115 struct Session 116 { 117 /** Control of the direct session opened by openSession() */ 118 ComPtr<IInternalSessionControl> mDirectControl; 119 120 typedef std::list<ComPtr<IInternalSessionControl> > RemoteControlList; 121 122 /** list of controls of all opened remote sessions */ 123 RemoteControlList mRemoteControls; 124 125 /** openRemoteSession() and OnSessionEnd() progress indicator */ 126 ComObjPtr<ProgressProxy> mProgress; 127 128 /** 129 * PID of the session object that must be passed to openSession() to 130 * finalize the openRemoteSession() request (i.e., PID of the 131 * process created by openRemoteSession()) 132 */ 133 RTPROCESS mPid; 134 135 /** Current session state */ 136 SessionState_T mState; 137 138 /** Session type string (for indirect sessions) */ 139 Bstr mType; 140 141 /** Session machine object */ 142 ComObjPtr<SessionMachine> mMachine; 143 144 /** Medium object lock collection. */ 145 MediumLockListMap mLockedMedia; 146 }; 147 148 Data(); 149 ~Data(); 150 151 const Guid mUuid; 152 BOOL mRegistered; 153 154 /** Flag indicating that the config file is read-only. */ 155 Utf8Str m_strConfigFile; 156 Utf8Str m_strConfigFileFull; 157 158 // machine settings XML file 159 settings::MachineConfigFile *pMachineConfigFile; 160 uint32_t flModifications; 161 162 BOOL mAccessible; 163 com::ErrorInfo mAccessError; 164 165 MachineState_T mMachineState; 166 RTTIMESPEC mLastStateChange; 167 168 /* Note: These are guarded by VirtualBoxBase::stateLockHandle() */ 169 uint32_t mMachineStateDeps; 170 RTSEMEVENTMULTI mMachineStateDepsSem; 171 uint32_t mMachineStateChangePending; 172 173 BOOL mCurrentStateModified; 174 /** Guest properties have been modified and need saving since the 175 * machine was started, or there are transient properties which need 176 * deleting and the machine is being shut down. */ 177 BOOL mGuestPropertiesModified; 178 179 Session mSession; 180 181 ComObjPtr<Snapshot> mFirstSnapshot; 182 ComObjPtr<Snapshot> mCurrentSnapshot; 183 }; 184 185 /** 186 * Saved state data. 187 * 188 * It's actually only the state file path string, but it needs to be 189 * separate from Data, because Machine and SessionMachine instances 190 * share it, while SnapshotMachine does not. 191 * 192 * The data variable is |mSSData|. 193 */ 194 struct SSData 195 { 196 Utf8Str mStateFilePath; 197 }; 198 199 /** 200 * User changeable machine data. 201 * 202 * This data is common for all machine snapshots, i.e. it is shared 203 * by all SnapshotMachine instances associated with the given machine 204 * using the util::Backupable template through the |mUserData| variable. 205 * 206 * SessionMachine instances can alter this data and discard changes. 207 * 208 * @note There is no need to lock anything inside init() or uninit() 209 * methods, because they are always serialized (see AutoCaller). 210 */ 211 struct UserData 212 { 213 UserData(); 214 ~UserData(); 215 216 Bstr mName; 217 BOOL mNameSync; 218 Bstr mDescription; 219 Bstr mOSTypeId; 220 Bstr mSnapshotFolder; 221 Bstr mSnapshotFolderFull; 222 BOOL mTeleporterEnabled; 223 ULONG mTeleporterPort; 224 Bstr mTeleporterAddress; 225 Bstr mTeleporterPassword; 226 BOOL mRTCUseUTC; 227 }; 228 229 /** 230 * Hardware data. 231 * 232 * This data is unique for a machine and for every machine snapshot. 233 * Stored using the util::Backupable template in the |mHWData| variable. 234 * 235 * SessionMachine instances can alter this data and discard changes. 236 */ 237 struct HWData 238 { 239 /** 240 * Data structure to hold information about a guest property. 241 */ 242 struct GuestProperty { 243 /** Property name */ 244 Utf8Str strName; 245 /** Property value */ 246 Utf8Str strValue; 247 /** Property timestamp */ 248 ULONG64 mTimestamp; 249 /** Property flags */ 250 ULONG mFlags; 251 }; 252 253 HWData(); 254 ~HWData(); 255 256 Bstr mHWVersion; 257 Guid mHardwareUUID; /**< If Null, use mData.mUuid. */ 258 ULONG mMemorySize; 259 ULONG mMemoryBalloonSize; 260 BOOL mPageFusionEnabled; 261 ULONG mVRAMSize; 262 ULONG mMonitorCount; 263 BOOL mHWVirtExEnabled; 264 BOOL mHWVirtExExclusive; 265 BOOL mHWVirtExNestedPagingEnabled; 266 BOOL mHWVirtExLargePagesEnabled; 267 BOOL mHWVirtExVPIDEnabled; 268 BOOL mAccelerate2DVideoEnabled; 269 BOOL mPAEEnabled; 270 BOOL mSyntheticCpu; 271 ULONG mCPUCount; 272 BOOL mCPUHotPlugEnabled; 273 BOOL mAccelerate3DEnabled; 274 BOOL mHpetEnabled; 275 276 BOOL mCPUAttached[SchemaDefs::MaxCPUCount]; 277 278 settings::CpuIdLeaf mCpuIdStdLeafs[10]; 279 settings::CpuIdLeaf mCpuIdExtLeafs[10]; 280 281 DeviceType_T mBootOrder[SchemaDefs::MaxBootPosition]; 282 283 typedef std::list< ComObjPtr<SharedFolder> > SharedFolderList; 284 SharedFolderList mSharedFolders; 285 286 ClipboardMode_T mClipboardMode; 287 288 typedef std::list<GuestProperty> GuestPropertyList; 289 GuestPropertyList mGuestProperties; 290 Utf8Str mGuestPropertyNotificationPatterns; 291 292 FirmwareType_T mFirmwareType; 293 KeyboardHidType_T mKeyboardHidType; 294 PointingHidType_T mPointingHidType; 295 296 BOOL mIoCacheEnabled; 297 ULONG mIoCacheSize; 298 ULONG mIoBandwidthMax; 299 }; 300 301 /** 302 * Hard disk and other media data. 303 * 304 * The usage policy is the same as for HWData, but a separate structure 305 * is necessary because hard disk data requires different procedures when 306 * taking or deleting snapshots, etc. 307 * 308 * The data variable is |mMediaData|. 309 */ 310 struct MediaData 311 { 312 MediaData(); 313 ~MediaData(); 314 315 typedef std::list< ComObjPtr<MediumAttachment> > AttachmentList; 316 AttachmentList mAttachments; 317 }; 47 struct Data; // machine data 48 struct SSData; // saved state data 49 struct UserData; // user data 50 struct HWData; // hardware data 51 struct MediaData; // media data 318 52 319 53 VIRTUALBOXBASE_ADD_ERRORINFO_SUPPORT(Machine, IMachine) … … 531 265 // that use it. Note: they should enter Machine lock to keep the returned 532 266 // information valid! 533 bool isRegistered() { return !!mData->mRegistered; }267 bool isRegistered() const; 534 268 535 269 // unsafe inline public methods for internal purposes only (ensure there is … … 545 279 VirtualBox* getVirtualBox() const { return mParent; } 546 280 281 const Guid& getId() const; 282 547 283 /** 548 * Returns this machine ID. 549 * 550 * @note This method doesn't check this object's readiness. Intended to be 551 * used by ready Machine children (whose readiness is bound to the parent's 552 * one) or after adding a caller manually. 284 * Virtual method that returns the snapshot a Machine object is attached 285 * to. This implementation returns Guid::Empty, but the SnapshotMachine 286 * override will return a real snapshot ID. 553 287 */ 554 const Guid& getId() const { return mData->mUuid; } 555 556 /** 557 * Returns the snapshot ID this machine represents or an empty UUID if this 558 * instance is not SnapshotMachine. 559 * 560 * @note This method doesn't check this object's readiness. Intended to be 561 * used by ready Machine children (whose readiness is bound to the parent's 562 * one) or after adding a caller manually. 563 */ 564 inline const Guid& getSnapshotId() const; 565 566 /** 567 * Returns this machine's full settings file path. 568 * 569 * @note This method doesn't lock this object or check its readiness. 570 * Intended to be used only after doing addCaller() manually and locking it 571 * for reading. 572 */ 573 const Utf8Str& getSettingsFileFull() const { return mData->m_strConfigFileFull; } 574 575 /** 576 * Returns this machine name. 577 * 578 * @note This method doesn't lock this object or check its readiness. 579 * Intended to be used only after doing addCaller() manually and locking it 580 * for reading. 581 */ 582 const Bstr& getName() const { return mUserData->mName; } 288 virtual const Guid& getSnapshotId() const 289 { 290 return Guid::Empty; 291 } 292 293 const Utf8Str& getSettingsFileFull() const; 294 295 const Bstr& getName() const; 583 296 584 297 enum … … 624 337 HRESULT openExistingSession(IInternalSessionControl *aControl); 625 338 626 HRESULT getDirectControl(ComPtr<IInternalSessionControl> *directControl) 627 { 628 HRESULT rc; 629 *directControl = mData->mSession.mDirectControl; 630 631 if (!*directControl) 632 rc = E_ACCESSDENIED; 633 else 634 rc = S_OK; 635 636 return rc; 637 } 339 HRESULT getDirectControl(ComPtr<IInternalSessionControl> &directControl); 638 340 639 341 #if defined(RT_OS_WINDOWS) … … 641 343 bool isSessionOpen(ComObjPtr<SessionMachine> &aMachine, 642 344 ComPtr<IInternalSessionControl> *aControl = NULL, 643 HANDLE *aIPCSem = NULL, bool aAllowClosing = false); 345 HANDLE *aIPCSem = NULL, 346 bool aAllowClosing = false); 644 347 bool isSessionSpawning(RTPROCESS *aPID = NULL); 645 348 … … 653 356 bool isSessionOpen(ComObjPtr<SessionMachine> &aMachine, 654 357 ComPtr<IInternalSessionControl> *aControl = NULL, 655 HMTX *aIPCSem = NULL, bool aAllowClosing = false); 358 HMTX *aIPCSem = NULL, 359 bool aAllowClosing = false); 656 360 657 361 bool isSessionSpawning(RTPROCESS *aPID = NULL); … … 728 432 729 433 HRESULT getMediumAttachmentsOfController(CBSTR aName, 730 Medi aData::AttachmentList &aAttachments);434 MediumAttachmentsList &aAttachments); 731 435 732 436 enum … … 760 464 HRESULT deleteImplicitDiffs(bool *pfNeedsSaveSettings); 761 465 762 MediumAttachment* findAttachment(const Medi aData::AttachmentList &ll,466 MediumAttachment* findAttachment(const MediumAttachmentsList &ll, 763 467 IN_BSTR aControllerName, 764 468 LONG aControllerPort, 765 469 LONG aDevice); 766 MediumAttachment* findAttachment(const Medi aData::AttachmentList &ll,470 MediumAttachment* findAttachment(const MediumAttachmentsList &ll, 767 471 ComObjPtr<Medium> pMedium); 768 MediumAttachment* findAttachment(const Medi aData::AttachmentList &ll,472 MediumAttachment* findAttachment(const MediumAttachmentsList &ll, 769 473 Guid &id); 770 474 … … 1102 806 // a caller and a read lock before calling them!) 1103 807 1104 const Guid& getSnapshotId() const { return mSnapshotId; } 808 /** 809 * Override of Machine::getSnapshotId(). Whereas the parent returns an empty Guid, 810 * this returns the snapshot that this machine is attached to. 811 * @return 812 */ 813 virtual const Guid& getSnapshotId() const 814 { 815 return mSnapshotId; 816 } 1105 817 1106 818 private: … … 1111 823 }; 1112 824 1113 // third party methods that depend on SnapshotMachine definiton1114 1115 inline const Guid &Machine::getSnapshotId() const1116 {1117 return (isSnapshotMachine())1118 ? static_cast<const SnapshotMachine*>(this)->getSnapshotId()1119 : Guid::Empty;1120 }1121 1122 1123 825 #endif // ____H_MACHINEIMPL 1124 /* vi: set tabstop=4 shiftwidth=4 expandtab: */ -
trunk/src/VBox/Main/include/MediumFormatImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 #include <VBox/com/array.h>26 27 #include <list>28 24 29 25 struct VDBACKENDINFO; -
trunk/src/VBox/Main/include/MediumImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 #include "MediumLock.h"25 26 class Progress;27 class MediumFormat;28 29 namespace settings30 {31 struct Medium;32 }33 24 34 25 //////////////////////////////////////////////////////////////////////////////// -
trunk/src/VBox/Main/include/MediumLock.h
r28800 r30760 21 21 #define ____H_MEDIUMLOCK 22 22 23 /* interface definitions */24 #include "VBox/com/VirtualBox.h"25 23 #include "VirtualBoxBase.h" 26 24 #include "AutoCaller.h" 27 28 #include <iprt/types.h>29 30 #include <list>31 #include <map>32 33 class Medium;34 class MediumAttachment;35 25 36 26 /** -
trunk/src/VBox/Main/include/MouseImpl.h
r30739 r30760 20 20 21 21 #include "VirtualBoxBase.h" 22 #include "ConsoleEvents.h"23 #include "ConsoleImpl.h"24 22 #include <VBox/pdmdrv.h> 25 23 … … 29 27 typedef struct DRVMAINMOUSE DRVMAINMOUSE, *PDRVMAINMOUSE; 30 28 31 /** Simple mouse event class. */ 32 class MouseEvent 33 { 34 public: 35 MouseEvent() : dx(0), dy(0), dz(0), dw(0), state(-1) {} 36 MouseEvent(int32_t _dx, int32_t _dy, int32_t _dz, int32_t _dw, int32_t _state) : 37 dx(_dx), dy(_dy), dz(_dz), dw(_dw), state(_state) {} 38 bool isValid() 39 { 40 return state != -1; 41 } 42 /* Note: dw is the horizontal scroll wheel */ 43 int32_t dx, dy, dz, dw; 44 int32_t state; 45 }; 46 // template instantiation 47 typedef ConsoleEventBuffer<MouseEvent> MouseEventBuffer; 29 class Console; 48 30 49 31 class ATL_NO_VTABLE Mouse : -
trunk/src/VBox/Main/include/NATEngineImpl.h
r30739 r30760 24 24 #include "VirtualBoxBase.h" 25 25 #include <VBox/settings.h> 26 27 namespace settings28 {29 struct NAT;30 }31 26 32 27 class ATL_NO_VTABLE NATEngine : -
trunk/src/VBox/Main/include/NetworkAdapterImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 #include "NATEngineImpl.h"25 26 class GuestOSType;27 28 namespace settings29 {30 struct NetworkAdapter;31 }32 24 33 25 class ATL_NO_VTABLE NetworkAdapter : -
trunk/src/VBox/Main/include/ParallelPortImpl.h
r30739 r30760 21 21 22 22 #include "VirtualBoxBase.h" 23 24 namespace settings25 {26 struct ParallelPort;27 }28 23 29 24 class ATL_NO_VTABLE ParallelPort : … … 51 46 52 47 // public initializer/uninitializer for internal purposes only 53 HRESULT init 54 HRESULT init 48 HRESULT init(Machine *aParent, ULONG aSlot); 49 HRESULT init(Machine *aParent, ParallelPort *aThat); 55 50 HRESULT initCopy (Machine *parent, ParallelPort *aThat); 56 51 void uninit(); -
trunk/src/VBox/Main/include/PerformanceImpl.h
r30739 r30760 23 23 #include "VirtualBoxBase.h" 24 24 25 #include <VBox/com/com.h> 26 #include <VBox/com/array.h> 27 //#ifdef VBOX_WITH_RESOURCE_USAGE_API 25 // #include <VBox/com/com.h> 26 // #include <VBox/com/array.h> 28 27 #include <iprt/timer.h> 29 //#endif /* VBOX_WITH_RESOURCE_USAGE_API */30 31 #include <list>32 33 namespace pm34 {35 class Metric;36 class BaseMetric;37 class CollectorHAL;38 }39 28 40 29 #undef min … … 43 32 /* Each second we obtain new CPU load stats. */ 44 33 #define VBOX_USAGE_SAMPLER_MIN_INTERVAL 1000 45 46 class HostUSBDevice;47 34 48 35 class ATL_NO_VTABLE PerformanceMetric : -
trunk/src/VBox/Main/include/RemoteUSBBackend.h
r28800 r30760 33 33 //} RDLState; 34 34 35 class Console;36 class ConsoleVRDPServer;37 38 35 DECLCALLBACK(int) USBClientResponseCallback (void *pv, uint32_t u32ClientId, uint8_t code, const void *pvRet, uint32_t cbRet); 39 40 36 41 37 /* How many remote devices can be attached to a remote client. -
trunk/src/VBox/Main/include/SerialPortImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 class GuestOSType;26 27 namespace settings28 {29 struct SerialPort;30 }31 24 32 25 class ATL_NO_VTABLE SerialPort : -
trunk/src/VBox/Main/include/SessionImpl.h
r30739 r30760 20 20 21 21 #include "VirtualBoxBase.h" 22 #include "ConsoleImpl.h"23 22 24 23 #ifdef RT_OS_WINDOWS -
trunk/src/VBox/Main/include/SharedFolderImpl.h
r30739 r30760 21 21 #include "VirtualBoxBase.h" 22 22 #include <VBox/shflsvc.h> 23 24 class Console;25 23 26 24 class ATL_NO_VTABLE SharedFolder : -
trunk/src/VBox/Main/include/SnapshotImpl.h
r30739 r30760 24 24 25 25 #include <iprt/time.h> 26 27 class SnapshotMachine;28 29 namespace settings30 {31 struct Snapshot;32 }33 26 34 27 class ATL_NO_VTABLE Snapshot : -
trunk/src/VBox/Main/include/SystemPropertiesImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 #include "MediumFormatImpl.h"25 26 #include <VBox/com/array.h>27 28 #include <list>29 30 namespace settings31 {32 struct SystemProperties;33 }34 24 35 25 class ATL_NO_VTABLE SystemProperties : -
trunk/src/VBox/Main/include/USBControllerImpl.h
r30739 r30760 22 22 23 23 #include "VirtualBoxBase.h" 24 25 class HostUSBDevice;26 class USBDeviceFilter;27 28 namespace settings29 {30 struct USBController;31 }32 24 33 25 class ATL_NO_VTABLE USBController : -
trunk/src/VBox/Main/include/VirtualBoxBase.h
r30739 r30760 30 30 #include "VBox/com/VirtualBox.h" 31 31 32 // avoid including VBox/settings.h and VBox/xml.h; 33 // only declare the classes 32 // empty-declare a bunch of classes that are commonly used in VirtualBox 33 // headers; this avoids having to include all the headers in every 34 // single implementation .cpp file 35 34 36 namespace xml 35 37 { 36 class File; 38 class ElementNode; 39 class File; 37 40 } 38 41 … … 43 46 class AutoUninitSpan; 44 47 48 class AudioSniffer; 49 class AudioAdapter; 50 class Appliance; 51 class BIOSSettings; 52 class Console; 53 class ConsoleCallbackRegistration; 54 class ConsoleVRDPServer; 55 class DHCPServer; 56 class Display; 57 class Guest; 58 class GuestOSType; 59 class Host; 60 class HostUSBDevice; 61 class HostUSBDeviceFilter; 62 class Keyboard; 63 class Machine; 64 class MachineDebugger; 65 class Medium; 66 class MediumAttachment; 67 class MediumFormat; 68 class MediumLockList; 69 class Mouse; 70 class NetworkAdapter; 71 class NATEngine; 72 class OUSBDevice; 73 class ParallelPort; 74 class PerformanceCollector; 75 class Progress; 76 class ProgressProxy; 77 class RemoteDisplayInfo; 78 class RemoteUSBDevice; 79 class SerialPort; 80 class SessionMachine; 81 class SharedFolder; 82 class Snapshot; 83 class SnapshotMachine; 84 class StorageController; 85 class SystemProperties; 86 class USBController; 87 class USBDeviceFilter; 88 class USBProxyService; 89 class TeleporterStateSrc; 90 class VMMDev; 45 91 class VirtualBox; 46 class Machine; 47 class Medium; 48 class Host; 92 class VirtualSystemDescription; 93 struct VirtualSystemDescriptionEntry; 94 class VRDPServer; 95 49 96 typedef std::list< ComObjPtr<Medium> > MediaList; 97 typedef std::list< ComObjPtr<MediumAttachment> > MediumAttachmentsList; 98 99 namespace settings 100 { 101 struct AudioAdapter; 102 struct Hardware; 103 struct Host; 104 class MainConfigFile; 105 class MachineConfigFile; 106 struct MachineRegistryEntry; 107 struct Medium; 108 struct NAT; 109 struct NetworkAdapter; 110 struct ParallelPort; 111 struct SerialPort; 112 struct Snapshot; 113 struct Storage; 114 struct StorageController; 115 struct SystemProperties; 116 struct USBController; 117 } 118 119 namespace pm 120 { 121 class Metric; 122 class BaseMetric; 123 class CollectorHAL; 124 class CollectorGuestHAL; 125 } 50 126 51 127 //////////////////////////////////////////////////////////////////////////////// … … 139 215 //////////////////////////////////////////////////////////////////////////////// 140 216 217 #ifndef DEBUG 218 // the following two are defined in glue/errorprint.cpp because they are included 219 // in the ComAssert macro below thousands of times in release builds 220 extern const char *g_pcszComAssertFailedString; 221 // "Assertion failed: [%s] at '%s' (%d) in %s.\nPlease contact the product vendor!" 222 extern const char *g_pcszComAssertMsgFailedString; 223 // "Assertion failed: [%s] at '%s' (%d) in %s.\n%s\nPlease contact the product vendor!" 224 #endif 225 141 226 /** 142 227 * Special version of the Assert macro to be used within VirtualBoxBase … … 158 243 if (RT_UNLIKELY(!(expr))) \ 159 244 setError(E_FAIL, \ 160 "Assertion failed: [%s] at '%s' (%d) in %s.\nPlease contact the product vendor!", \245 g_pcszComAssertFailedString, \ 161 246 #expr, __FILE__, __LINE__, __PRETTY_FUNCTION__); \ 162 247 } while (0) … … 179 264 if (RT_UNLIKELY(!(expr))) \ 180 265 setError(E_FAIL, \ 181 "Assertion failed: [%s] at '%s' (%d) in %s.\n%s.\nPlease contact the product vendor!", \182 #expr, __FILE__, __LINE__, __PRETTY_FUNCTION__ ); \266 g_pcszComAssertMsgFailedString, \ 267 #expr, __FILE__, __LINE__, __PRETTY_FUNCTION__, Utf8StrFmt a .c_str()); \ 183 268 } while (0) 184 269 #endif -
trunk/src/VBox/Main/include/VirtualBoxImpl.h
r30739 r30760 33 33 } 34 34 35 class SessionMachine;36 class GuestOSType;37 class SharedFolder;38 class Progress;39 class Host;40 class SystemProperties;41 class DHCPServer;42 class PerformanceCollector;43 class VirtualBoxCallbackRegistration; /* see VirtualBoxImpl.cpp */44 45 35 typedef std::list< ComObjPtr<SessionMachine> > SessionMachinesList; 46 36 … … 50 40 51 41 struct VMClientWatcherData; 52 53 namespace settings54 {55 class MainConfigFile;56 }57 42 58 43 class ATL_NO_VTABLE VirtualBox : … … 68 53 public: 69 54 70 typedef std::list< VirtualBoxCallbackRegistration > CallbackList;71 55 typedef std::list< ComPtr<IInternalSessionControl> > InternalControlList; 72 56 -
trunk/src/VBox/Main/xpcom/server.cpp
r30739 r30760 41 41 #include <iprt/message.h> 42 42 #include <iprt/stream.h> 43 #include <iprt/file.h> 43 44 #include <iprt/path.h> 44 45 #include <iprt/timer.h> … … 60 61 #include <VirtualBox_XPCOM.h> 61 62 #include <VirtualBoxImpl.h> 62 #include <MachineImpl.h> 63 #include <VFSExplorerImpl.h> 64 #include <ApplianceImpl.h> 65 #include <SnapshotImpl.h> 66 #include <MediumImpl.h> 67 #include <MediumFormatImpl.h> 68 #include <ProgressCombinedImpl.h> 69 #include <ProgressProxyImpl.h> 70 #include <VRDPServerImpl.h> 71 #include <SharedFolderImpl.h> 72 #include <HostImpl.h> 73 #include <HostNetworkInterfaceImpl.h> 74 #include <GuestOSTypeImpl.h> 75 #include <NetworkAdapterImpl.h> 76 #include <NATEngineImpl.h> 77 #include <SerialPortImpl.h> 78 #include <ParallelPortImpl.h> 79 #include <USBControllerImpl.h> 63 64 #include "AudioAdapterImpl.h" 65 #include "ApplianceImpl.h" 66 #include "BIOSSettingsImpl.h" 67 #include "GuestOSTypeImpl.h" 68 #include "DHCPServerImpl.h" 69 #include "HostImpl.h" 70 #include "HostNetworkInterfaceImpl.h" 71 #include "MachineImpl.h" 72 #include "MediumImpl.h" 73 #include "MediumAttachmentImpl.h" 74 #include "MediumFormatImpl.h" 75 #include "NATEngineImpl.h" 76 #include "NetworkAdapterImpl.h" 77 #include "ParallelPortImpl.h" 78 #include "ProgressCombinedImpl.h" 79 #include "ProgressProxyImpl.h" 80 #include "VRDPServerImpl.h" 81 #include "SerialPortImpl.h" 82 #include "SharedFolderImpl.h" 83 #include "SnapshotImpl.h" 84 #include "StorageControllerImpl.h" 85 #include "SystemPropertiesImpl.h" 80 86 #include "USBDeviceFilterImpl.h" 81 #include "DHCPServerRunner.h" 82 #include "DHCPServerImpl.h" 87 #include "USBControllerImpl.h" 88 #include "VFSExplorerImpl.h" 89 83 90 #ifdef VBOX_WITH_USB 84 91 # include <HostUSBDeviceImpl.h> 85 92 # include <USBDeviceImpl.h> 86 93 #endif 87 #include <StorageControllerImpl.h> 88 #include <AudioAdapterImpl.h> 89 #include <SystemPropertiesImpl.h> 94 95 #ifdef VBOX_WITH_RESOURCE_USAGE_API 96 # include "Performance.h" 97 # include "PerformanceImpl.h" 98 #endif /* VBOX_WITH_RESOURCE_USAGE_API */ 90 99 91 100 /* implement nsISupports parts of our objects with support for nsIClassInfo */
Note:
See TracChangeset
for help on using the changeset viewer.