VirtualBox

source: vbox/trunk/src/VBox/Main/idl/VirtualBox.xidl@ 33140

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

Main: have Machine::MountMedium() behave like AttachDevice (use IMedium* pointer instead of UUID); add missing saveSettings calls there

  • Property svn:eol-style set to native
File size: 566.1 KB
Line 
1<?xml version="1.0" ?>
2
3<!--
4
5 Copyright (C) 2006-2010 Oracle Corporation
6
7 This file is part of VirtualBox Open Source Edition (OSE), as
8 available from http://www.virtualbox.org. This file is free software;
9 you can redistribute it and/or modify it under the terms of the GNU
10 General Public License (GPL) as published by the Free Software
11 Foundation, in version 2 as it comes in the "COPYING" file of the
12 VirtualBox OSE distribution. VirtualBox OSE is distributed in the
13 hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
14-->
15
16<!--
17 This is the master declaration for VirtualBox's Main API,
18 represented by COM/XPCOM and web service interfaces.
19
20 From this document, the build system generates several files
21 via XSLT that are then used during the build process.
22
23 Below is the list of XSL templates that operate on this file and
24 output files they generate. These XSL templates must be updated
25 whenever the schema of this file changes:
26
27 1. src/VBox/Main/idl/midl.xsl =>
28 out/<platform>/bin/sdk/idl/VirtualBox.idl
29 (MS COM interface definition file for Main API)
30
31 2. src/VBox/Main/idl/xpidl.xsl =>
32 out/<platform>/bin/sdk/idl/VirtualBox_XPCOM.idl
33 (XPCOM interface definition file for Main API)
34
35 3. src/VBox/Main/idl/doxygen.xsl =>
36 out/<platform>/obj/src/VBox/Main/VirtualBox.idl
37 (pseudo-IDL for Doxygen to generate the official Main API
38 documentation)
39
40 4. src/VBox/Main/webservice/*.xsl =>
41 a bunch of WSDL and C++ files
42 (VirtualBox web service sources and SOAP mappers;
43 see src/VBox/Main/webservice/Makefile.kmk for details)
44
45 5. src/VBox/Frontends/VirtualBox/include/COMWrappers.xsl =>
46 out/<platform>/obj/src/VBox/Frontends/VirtualBox/VirtualBox/include/COMWrappers.h
47 (smart Qt-based C++ wrapper classes for COM interfaces
48 of the Main API)
49
50 6. src/VBox/Installer/win32/VirtualBox_TypeLib.xsl =>
51 out/<platform>/obj/src/VBox/Installer/win32/VirtualBox_TypeLib.wxi
52 (Main API TypeLib block for the WiX installer)
53
54 7. src/VBox/Runtime/common/err/errmsgvboxcom.xsl =>
55 out/<platform>/obj/Runtime/errmsgvboxcomdata.h
56 (<result> extraction for the %Rhrc format specifier)
57-->
58
59<idl>
60
61<desc>
62 Welcome to the <b>VirtualBox Main API documentation</b>. This documentation
63 describes the so-called <i>VirtualBox Main API</i> which comprises all public
64 COM interfaces and components provided by the VirtualBox server and by the
65 VirtualBox client library.
66
67 VirtualBox employs a client-server design, meaning that whenever any part of
68 VirtualBox is running -- be it the Qt GUI, the VBoxManage command-line
69 interface or any virtual machine --, a dedicated server process named
70 VBoxSVC runs in the background. This allows multiple processes working with
71 VirtualBox to cooperate without conflicts. These processes communicate to each
72 other using inter-process communication facilities provided by the COM
73 implementation of the host computer.
74
75 On Windows platforms, the VirtualBox Main API uses Microsoft COM, a native COM
76 implementation. On all other platforms, Mozilla XPCOM, an open-source COM
77 implementation, is used.
78
79 All the parts that a typical VirtualBox user interacts with (the Qt GUI,
80 the VBoxManage command-line interface and the VBoxVRDP server) are technically
81 front-ends to the Main API and only use the interfaces that are documented
82 in this Main API documentation. This ensures that, with any given release
83 version of VirtualBox, all capabilities of the product that could be useful
84 to an external client program are always exposed by way of this API.
85
86 The VirtualBox Main API (also called the <i>VirtualBox COM library</i>)
87 contains two public component classes:
88 <tt>%VirtualBox.VirtualBox</tt> and <tt>%VirtualBox.Session</tt>, which
89 implement IVirtualBox and ISession interfaces respectively. These two classes
90 are of supreme importance and will be needed in order for any front-end
91 program to do anything useful. It is recommended to read the documentation of
92 the mentioned interfaces first.
93
94 The <tt>%VirtualBox.VirtualBox</tt> class is a singleton. This means that
95 there can be only one object of this class on the local machine at any given
96 time. This object is a parent of many other objects in the VirtualBox COM
97 library and lives in the VBoxSVC process. In fact, when you create an instance
98 of the <tt>VirtualBox.VirtualBox</tt>, the COM subsystem checks if the VBoxSVC
99 process is already running, starts it if not, and returns you a reference to
100 the <tt>VirtualBox</tt> object created in this process. When the last reference
101 to this object is released, the VBoxSVC process ends (with a 5 second delay to
102 protect from too frequent restarts).
103
104 The <tt>%VirtualBox.Session</tt> class is a regular component. You can create
105 as many <tt>Session</tt> objects as you need but all of them will live in a
106 process which issues the object instantiation call. <tt>Session</tt> objects
107 represent virtual machine sessions which are used to configure virtual
108 machines and control their execution.
109</desc>
110
111<if target="midl">
112 <cpp line="enum {"/>
113 <cpp line=" kTypeLibraryMajorVersion = 1,"/>
114 <cpp line=" kTypeLibraryMinorVersion = 0"/>
115 <cpp line="};"/>
116</if>
117
118<if target="xpidl">
119 <!-- NS_IMPL_THREADSAFE_ISUPPORTSxx_CI macros are placed here, for convenience -->
120 <cpp>
121/* currently, nsISupportsImpl.h lacks the below-like macros */
122
123#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1_CI NS_IMPL_QUERY_INTERFACE1_CI
124#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2_CI NS_IMPL_QUERY_INTERFACE2_CI
125#define NS_IMPL_THREADSAFE_QUERY_INTERFACE3_CI NS_IMPL_QUERY_INTERFACE3_CI
126#define NS_IMPL_THREADSAFE_QUERY_INTERFACE4_CI NS_IMPL_QUERY_INTERFACE4_CI
127
128
129#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_CI
130# define NS_IMPL_THREADSAFE_ISUPPORTS1_CI(_class, _interface) \
131 NS_IMPL_THREADSAFE_ADDREF(_class) \
132 NS_IMPL_THREADSAFE_RELEASE(_class) \
133 NS_IMPL_THREADSAFE_QUERY_INTERFACE1_CI(_class, _interface) \
134 NS_IMPL_CI_INTERFACE_GETTER1(_class, _interface)
135#endif
136
137#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_CI
138# define NS_IMPL_THREADSAFE_ISUPPORTS2_CI(_class, _i1, _i2) \
139 NS_IMPL_THREADSAFE_ADDREF(_class) \
140 NS_IMPL_THREADSAFE_RELEASE(_class) \
141 NS_IMPL_THREADSAFE_QUERY_INTERFACE2_CI(_class, _i1, _i2) \
142 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
143#endif
144
145#ifndef NS_IMPL_THREADSAFE_ISUPPORTS3_CI
146# define NS_IMPL_THREADSAFE_ISUPPORTS3_CI(_class, _i1, _i2, _i3) \
147 NS_IMPL_THREADSAFE_ADDREF(_class) \
148 NS_IMPL_THREADSAFE_RELEASE(_class) \
149 NS_IMPL_THREADSAFE_QUERY_INTERFACE3_CI(_class, _i1, _i2, _i3) \
150 NS_IMPL_CI_INTERFACE_GETTER3(_class, _i1, _i2, _i3)
151#endif
152
153#ifndef NS_IMPL_THREADSAFE_ISUPPORTS4_CI
154# define NS_IMPL_THREADSAFE_ISUPPORTS4_CI(_class, _i1, _i2, _i3, _i4) \
155 NS_IMPL_THREADSAFE_ADDREF(_class) \
156 NS_IMPL_THREADSAFE_RELEASE(_class) \
157 NS_IMPL_THREADSAFE_QUERY_INTERFACE4_CI(_class, _i1, _i2, _i3, _i4) \
158 NS_IMPL_CI_INTERFACE_GETTER4(_class, _i1, _i2, _i3, _i4)
159#endif
160
161#ifndef NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI
162# define NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI(_class, _i1, _ic1) \
163 NS_INTERFACE_MAP_BEGIN(_class) \
164 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
165 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
166 NS_IMPL_QUERY_CLASSINFO(_class) \
167 NS_INTERFACE_MAP_END
168#endif
169
170#ifndef NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI
171# define NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI(_class, _i1, _ic1, \
172 _i2, _ic2) \
173 NS_INTERFACE_MAP_BEGIN(_class) \
174 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
175 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i2, _ic2) \
176 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
177 NS_IMPL_QUERY_CLASSINFO(_class) \
178 NS_INTERFACE_MAP_END
179#endif
180
181#ifndef NS_IMPL_QUERY_INTERFACE3_AMBIGUOUS_CI
182# define NS_IMPL_QUERY_INTERFACE3_AMBIGUOUS_CI(_class, _i1, _ic1, \
183 _i2, _ic2, _i3, _ic3) \
184 NS_INTERFACE_MAP_BEGIN(_class) \
185 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
186 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i2, _ic2) \
187 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i3, _ic3) \
188 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
189 NS_IMPL_QUERY_CLASSINFO(_class) \
190 NS_INTERFACE_MAP_END
191#endif
192
193#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI
194#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI
195#define NS_IMPL_THREADSAFE_QUERY_INTERFACE3_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE3_AMBIGUOUS_CI
196
197#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_AMBIGUOUS_CI
198# define NS_IMPL_THREADSAFE_ISUPPORTS1_AMBIGUOUS_CI(_class, _i1, _ic1) \
199 NS_IMPL_THREADSAFE_ADDREF(_class) \
200 NS_IMPL_THREADSAFE_RELEASE(_class) \
201 NS_IMPL_THREADSAFE_QUERY_INTERFACE1_AMBIGUOUS_CI(_class, _i1, _ic1) \
202 NS_IMPL_CI_INTERFACE_GETTER1(_class, _i1)
203#endif
204
205#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_AMBIGUOUS_CI
206# define NS_IMPL_THREADSAFE_ISUPPORTS2_AMBIGUOUS_CI(_class, _i1, _ic1, \
207 _i2, _ic2) \
208 NS_IMPL_THREADSAFE_ADDREF(_class) \
209 NS_IMPL_THREADSAFE_RELEASE(_class) \
210 NS_IMPL_THREADSAFE_QUERY_INTERFACE2_AMBIGUOUS_CI(_class, _i1, _ic1, \
211 _i2, _ic2) \
212 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
213#endif
214
215#ifndef NS_IMPL_THREADSAFE_ISUPPORTS3_AMBIGUOUS_CI
216# define NS_IMPL_THREADSAFE_ISUPPORTS3_AMBIGUOUS_CI(_class, _i1, _ic1, \
217 _i2, _ic2, _i3, _ic3) \
218 NS_IMPL_THREADSAFE_ADDREF(_class) \
219 NS_IMPL_THREADSAFE_RELEASE(_class) \
220 NS_IMPL_THREADSAFE_QUERY_INTERFACE3_AMBIGUOUS_CI(_class, _i1, _ic1, \
221 _i2, _ic2, _i3, _ic3) \
222 NS_IMPL_CI_INTERFACE_GETTER3(_class, _i1, _i2, _i3)
223#endif
224
225 </cpp>
226</if>
227
228<library
229 name="VirtualBox"
230 uuid="46137EEC-703B-4fe5-AFD4-7C9BBBBA0259"
231 version="1.3"
232 desc="VirtualBox Type Library"
233 appUuid="819B4D85-9CEE-493C-B6FC-64FFE759B3C9"
234 supportsErrorInfo="yes"
235>
236
237
238 <!--
239 // COM result codes for VirtualBox
240 /////////////////////////////////////////////////////////////////////////
241 -->
242
243 <descGroup id="VirtualBox_COM_result_codes" title="VirtualBox COM result codes">
244 <desc>
245 This section describes all VirtualBox-specific COM result codes that may
246 be returned by methods of VirtualBox COM interfaces in addition to
247 standard COM result codes.
248
249 Note that along with the result code, every VirtualBox method returns
250 extended error information through the IVirtualBoxErrorInfo interface on
251 failure. This interface is a preferred way to present the error to the end
252 user because it contains a human readable description of the error. Raw
253 result codes, both standard and described in this section, are intended to
254 be used by programs to analyze the reason of a failure and select an
255 appropriate course of action without involving the end user (for example,
256 retry the operation later or make a different call).
257
258 The standard COM result codes that may originate from our methods include:
259
260 <table>
261 <tr><td>E_INVALIDARG</td>
262 <td>
263 Returned when the value of the method's argument is not within the range
264 of valid values. This should not be confused with situations when the
265 value is within the range but simply doesn't suit the current object
266 state and there is a possibility that it will be accepted later (in such
267 cases VirtualBox-specific codes are returned, for example,
268 <link to="VBOX_E_OBJECT_NOT_FOUND"/>).
269 </td>
270 </tr>
271 <tr><td>E_POINTER</td>
272 <td>
273 Returned if a memory pointer for the output argument is invalid (for
274 example, @c null). Note that when pointers representing input
275 arguments (such as strings) are invalid, E_INVALIDARG is returned.
276 </td>
277 </tr>
278 <tr><td>E_ACCESSDENIED</td>
279 <td>
280 Returned when the called object is not ready. Since the lifetime of a
281 public COM object cannot be fully controlled by the implementation,
282 VirtualBox maintains the readiness state for all objects it creates and
283 returns this code in response to any method call on the object that was
284 deactivated by VirtualBox and is not functioning any more.
285 </td>
286 </tr>
287 <tr><td>E_OUTOFMEMORY</td>
288 <td>
289 Returned when a memory allocation operation fails.
290 </td>
291 </tr>
292 </table>
293 </desc>
294 </descGroup>
295
296 <!--
297 Note that src/VBox/Runtime/common/err/errmsgvboxcom.xsl will ignore
298 everything in <result>/<desc> after (and including) the first dot, so express
299 the matter of the error code in the first sentence and keep it short.
300 -->
301
302 <result name="VBOX_E_OBJECT_NOT_FOUND" value="0x80BB0001">
303 <desc>
304 Object corresponding to the supplied arguments does not exist.
305 </desc>
306 </result>
307
308 <result name="VBOX_E_INVALID_VM_STATE" value="0x80BB0002">
309 <desc>
310 Current virtual machine state prevents the operation.
311 </desc>
312 </result>
313
314 <result name="VBOX_E_VM_ERROR" value="0x80BB0003">
315 <desc>
316 Virtual machine error occurred attempting the operation.
317 </desc>
318 </result>
319
320 <result name="VBOX_E_FILE_ERROR" value="0x80BB0004">
321 <desc>
322 File not accessible or erroneous file contents.
323 </desc>
324 </result>
325
326 <result name="VBOX_E_IPRT_ERROR" value="0x80BB0005">
327 <desc>
328 Runtime subsystem error.
329 </desc>
330 </result>
331
332 <result name="VBOX_E_PDM_ERROR" value="0x80BB0006">
333 <desc>
334 Pluggable Device Manager error.
335 </desc>
336 </result>
337
338 <result name="VBOX_E_INVALID_OBJECT_STATE" value="0x80BB0007">
339 <desc>
340 Current object state prohibits operation.
341 </desc>
342 </result>
343
344 <result name="VBOX_E_HOST_ERROR" value="0x80BB0008">
345 <desc>
346 Host operating system related error.
347 </desc>
348 </result>
349
350 <result name="VBOX_E_NOT_SUPPORTED" value="0x80BB0009">
351 <desc>
352 Requested operation is not supported.
353 </desc>
354 </result>
355
356 <result name="VBOX_E_XML_ERROR" value="0x80BB000A">
357 <desc>
358 Invalid XML found.
359 </desc>
360 </result>
361
362 <result name="VBOX_E_INVALID_SESSION_STATE" value="0x80BB000B">
363 <desc>
364 Current session state prohibits operation.
365 </desc>
366 </result>
367
368 <result name="VBOX_E_OBJECT_IN_USE" value="0x80BB000C">
369 <desc>
370 Object being in use prohibits operation.
371 </desc>
372 </result>
373
374 <!--
375 Note that src/VBox/Runtime/common/err/errmsgvboxcom.xsl will ignore
376 everything in <result>/<desc> after (and including) the first dot, so express
377 the matter of the error code in the first sentence and keep it short.
378 -->
379
380 <descGroup/>
381
382 <!--
383 // all common enums
384 /////////////////////////////////////////////////////////////////////////
385 -->
386
387 <enum name="SettingsVersion"
388 uuid="52bd6f5f-1adb-4493-975d-581a9c4b803f"
389 >
390 <desc>Settings version of VirtualBox settings files. This is written to
391 the "version" attribute of the root "VirtualBox" element in the settings
392 file XML and indicates which VirtualBox version wrote the file.
393 </desc>
394
395 <const name="Null" value="0">
396 <desc>Null value, indicates invalid version.</desc>
397 </const>
398 <const name="v1_0" value="1">
399 <desc>Legacy settings version, not currently supported.</desc>
400 </const>
401 <const name="v1_1" value="2">
402 <desc>Legacy settings version, not currently supported.</desc>
403 </const>
404 <const name="v1_2" value="3">
405 <desc>Legacy settings version, not currently supported.</desc>
406 </const>
407 <const name="v1_3pre" value="4">
408 <desc>Legacy settings version, not currently supported.</desc>
409 </const>
410 <const name="v1_3" value="5">
411 <desc>Settings version "1.3", written by VirtualBox 2.0.12.</desc>
412 <!--
413 Machine XML: Capitalization of Uart, Lpt elements and many attributes changed.
414 -->
415 </const>
416 <const name="v1_4" value="6">
417 <desc>Intermediate settings version, understood by VirtualBox 2.1.x.</desc>
418 <!--
419 VirtualBox.xml: big DiskRegistry -> MediaRegistry revamp, various HardDisk types merged
420 (was VirtualDiskImage, VMDKImage, VHDImage, ISCSIHardDisk, CustomHardDisk, DiffHardDisk)
421 -->
422 </const>
423 <const name="v1_5" value="7">
424 <desc>Intermediate settings version, understood by VirtualBox 2.1.x.</desc>
425 <!-- 2008-09-04: 2.0.0 released
426 2008-11-20: settings version 1.5 introduced
427 2008-12-17: 2.1.0 released
428 Machine changes:
429 guest OS identifiers changed;
430 Machine/Hardware/Display/MonitorCount renamed to monitorCount;
431 Machine/Hardware/Display/Accelerate3D renamed to accelerate3D;
432 Machine/Hardware/CPU/CPUCount/@count changed to CPU/@count
433 -->
434 </const>
435 <const name="v1_6" value="8">
436 <desc>Settings version "1.6", written by VirtualBox 2.1.4 (at least).</desc>
437 <!-- 2008-12-17: 2.1.0 released
438 2008-12-19: settings version 1.6 introduced (is in 2.1 branch)
439 2009-04-08: 2.2.0 released
440 Machine changes: remove all Machine/Hardware/Network/Adapter/HostInterface[@TAPSetup or @TAPTerminate]/ attributes (done)
441 -->
442 </const>
443 <const name="v1_7" value="9">
444 <desc>Settings version "1.7", written by VirtualBox 2.2.x and 3.0.x.</desc>
445 <!-- 2008-12-17: 2.1.0 released
446 2009-03-11: settings version 1.7 introduced (is in 2.2 branch)
447 2009-04-08: 2.2.0 released
448 VirtualBox.xml additions: NetserviceRegistry with DHCPServers (done)
449 Machine changes: HardDiskAttachments is now StorageControllers (done)
450 -->
451 </const>
452 <const name="v1_8" value="10">
453 <desc>Intermediate settings version "1.8", understood by VirtualBox 3.1.x.</desc>
454 <!-- Machine additions: Display/@accelerate2DVideo (done)
455 -->
456 </const>
457 <const name="v1_9" value="11">
458 <desc>Settings version "1.9", written by VirtualBox 3.1.x.</desc>
459 <!-- The big storage controller / DVD / Floppy rework (done)
460 -->
461 </const>
462 <const name="v1_10" value="12">
463 <desc>Settings version "1.10", written by VirtualBox 3.2.x.</desc>
464 <!-- Machine changes: RTC localOrUTC (done)
465 CPU hot-plug support
466 -->
467 </const>
468 <const name="v1_11" value="13">
469 <desc>Settings version "1.11", written by VirtualBox 4.0.x.</desc>
470 <!-- Machine changes: HD Audio controller, per-machine disk registries
471 -->
472 </const>
473 <const name="Future" value="99999">
474 <desc>Settings version greater than "1.11", written by a future VirtualBox version.</desc>
475 </const>
476 </enum>
477
478 <enum
479 name="AccessMode"
480 uuid="1da0007c-ddf7-4be8-bcac-d84a1558785f"
481 >
482 <desc>
483 Access mode for opening files.
484 </desc>
485
486 <const name="ReadOnly" value="1"/>
487 <const name="ReadWrite" value="2"/>
488 </enum>
489
490 <enum
491 name="MachineState"
492 uuid="ec6c6a9e-113d-4ff4-b44f-0b69f21c97fe"
493 >
494 <desc>
495 Virtual machine execution state.
496
497 This enumeration represents possible values of the <link
498 to="IMachine::state"/> attribute.
499
500 Below is the basic virtual machine state diagram. It shows how the state
501 changes during virtual machine execution. The text in square braces shows
502 a method of the IConsole interface that performs the given state
503 transition.
504
505 <pre>
506 +---------[powerDown()] &lt;- Stuck &lt;--[failure]-+
507 V |
508 +-&gt; PoweredOff --+--&gt;[powerUp()]--&gt; Starting --+ | +-----[resume()]-----+
509 | | | | V |
510 | Aborted -----+ +--&gt; Running --[pause()]--&gt; Paused
511 | | ^ | ^ |
512 | Saved -----------[powerUp()]--&gt; Restoring -+ | | | |
513 | ^ | | | |
514 | | +-----------------------------------------+-|-------------------+ +
515 | | | | |
516 | | +-- Saving &lt;--------[takeSnapshot()]&lt;-------+---------------------+
517 | | | |
518 | +-------- Saving &lt;--------[saveState()]&lt;----------+---------------------+
519 | | |
520 +-------------- Stopping -------[powerDown()]&lt;----------+---------------------+
521 </pre>
522
523 Note that states to the right from PoweredOff, Aborted and Saved in the
524 above diagram are called <i>online VM states</i>. These states
525 represent the virtual machine which is being executed in a dedicated
526 process (usually with a GUI window attached to it where you can see the
527 activity of the virtual machine and interact with it). There are two
528 special pseudo-states, FirstOnline and LastOnline, that can be used in
529 relational expressions to detect if the given machine state is online or
530 not:
531
532 <pre>
533 if (machine.GetState() &gt;= MachineState_FirstOnline &amp;&amp;
534 machine.GetState() &lt;= MachineState_LastOnline)
535 {
536 ...the machine is being executed...
537 }
538 </pre>
539
540 When the virtual machine is in one of the online VM states (that is, being
541 executed), only a few machine settings can be modified. Methods working
542 with such settings contain an explicit note about that. An attempt to
543 change any oter setting or perform a modifying operation during this time
544 will result in the <link to="VBOX_E_INVALID_VM_STATE"/> error.
545
546 All online states except Running, Paused and Stuck are transitional: they
547 represent temporary conditions of the virtual machine that will last as
548 long as the operation that initiated such a condition.
549
550 The Stuck state is a special case. It means that execution of the machine
551 has reached the "Guru Meditation" condition. This condition indicates an
552 internal VMM (virtual machine manager) failure which may happen as a
553 result of either an unhandled low-level virtual hardware exception or one
554 of the recompiler exceptions (such as the <i>too-many-traps</i>
555 condition).
556
557 Note also that any online VM state may transit to the Aborted state. This
558 happens if the process that is executing the virtual machine terminates
559 unexpectedly (for example, crashes). Other than that, the Aborted state is
560 equivalent to PoweredOff.
561
562 There are also a few additional state diagrams that do not deal with
563 virtual machine execution and therefore are shown separately. The states
564 shown on these diagrams are called <i>offline VM states</i> (this includes
565 PoweredOff, Aborted and Saved too).
566
567 The first diagram shows what happens when a lengthy setup operation is
568 being executed (such as <link to="IMachine::attachDevice"/>).
569
570 <pre>
571 +----------------------------------(same state as before the call)------+
572 | |
573 +-&gt; PoweredOff --+ |
574 | | |
575 |-&gt; Aborted -----+--&gt;[lengthy VM configuration call] --&gt; SettingUp -----+
576 | |
577 +-&gt; Saved -------+
578 </pre>
579
580 The next two diagrams demonstrate the process of taking a snapshot of a
581 powered off virtual machine, restoring the state to that as of a snapshot
582 or deleting a snapshot, respectively.
583
584 <pre>
585 +----------------------------------(same state as before the call)------+
586 | |
587 +-&gt; PoweredOff --+ |
588 | +--&gt;[takeSnapshot()] -------------------&gt; Saving ------+
589 +-&gt; Aborted -----+
590
591 +-&gt; PoweredOff --+
592 | |
593 | Aborted -----+--&gt;[restoreSnapshot() ]-------&gt; RestoringSnapshot -+
594 | | [deleteSnapshot() ]-------&gt; DeletingSnapshot --+
595 +-&gt; Saved -------+ |
596 | |
597 +---(Saved if restored from an online snapshot, PoweredOff otherwise)---+
598 </pre>
599
600 Note that the Saving state is present in both the offline state group and
601 online state group. Currently, the only way to determine what group is
602 assumed in a particular case is to remember the previous machine state: if
603 it was Running or Paused, then Saving is an online state, otherwise it is
604 an offline state. This inconsistency may be removed in one of the future
605 versions of VirtualBox by adding a new state.
606
607 <note internal="yes">
608 For whoever decides to touch this enum: In order to keep the
609 comparisons involving FirstOnline and LastOnline pseudo-states valid,
610 the numeric values of these states must be correspondingly updated if
611 needed: for any online VM state, the condition
612 <tt>FirstOnline &lt;= state &lt;= LastOnline</tt> must be
613 @c true. The same relates to transient states for which
614 the condition <tt>FirstOnline &lt;= state &lt;= LastOnline</tt> must be
615 @c true.
616 </note>
617 </desc>
618
619 <const name="Null" value="0">
620 <desc>Null value (never used by the API).</desc>
621 </const>
622 <const name="PoweredOff" value="1">
623 <desc>
624 The machine is not running and has no saved execution state; it has
625 either never been started or been shut down successfully.
626 </desc>
627 </const>
628 <const name="Saved" value="2">
629 <desc>
630 The machine is not currently running, but the execution state of the machine
631 has been saved to an external file when it was running, from where
632 it can be resumed.
633 </desc>
634 </const>
635 <const name="Teleported" value="3">
636 <desc>
637 The machine was teleported to a different host (or process) and then
638 powered off. Take care when powering it on again may corrupt resources
639 it shares with the teleportation target (e.g. disk and network).
640 </desc>
641 </const>
642 <const name="Aborted" value="4">
643 <desc>
644 The process running the machine has terminated abnormally. This may
645 indicate a crash of the VM process in host execution context, or
646 the VM process has been terminated externally.
647 </desc>
648 </const>
649 <const name="Running" value="5">
650 <desc>
651 The machine is currently being executed.
652 <note internal="yes">
653 For whoever decides to touch this enum: In order to keep the
654 comparisons in the old source code valid, this state must immediately
655 precede the Paused state.
656 TODO: Lift this spectacularly wonderful restriction.
657 </note>
658 </desc>
659 </const>
660 <const name="Paused" value="6">
661 <desc>
662 Execution of the machine has been paused.
663 <note internal="yes">
664 For whoever decides to touch this enum: In order to keep the
665 comparisons in the old source code valid, this state must immediately
666 follow the Running state.
667 TODO: Lift this spectacularly wonderful restriction.
668 </note>
669 </desc>
670 </const>
671 <const name="Stuck" value="7">
672 <desc>
673 Execution of the machine has reached the "Guru Meditation"
674 condition. This indicates a severe error in the hypervisor itself.
675 <note internal="yes">
676 bird: Why this uncool name? Could we rename it to "GuruMeditation" or
677 "Guru", perhaps? Or are there some other VMM states that are
678 intended to be lumped in here as well?
679 </note>
680 </desc>
681 </const>
682 <const name="Teleporting" value="8">
683 <desc>
684 The machine is about to be teleported to a different host or process.
685 It is possible to pause a machine in this state, but it will go to the
686 @c TeleportingPausedVM state and it will not be
687 possible to resume it again unless the teleportation fails.
688 </desc>
689 </const>
690 <const name="LiveSnapshotting" value="9">
691 <desc>
692 A live snapshot is being taken. The machine is running normally, but
693 some of the runtime configuration options are inaccessible. Also, if
694 paused while in this state it will transition to
695 @c Saving and it will not be resume the
696 execution until the snapshot operation has completed.
697 </desc>
698 </const>
699 <const name="Starting" value="10">
700 <desc>
701 Machine is being started after powering it on from a
702 zero execution state.
703 </desc>
704 </const>
705 <const name="Stopping" value="11">
706 <desc>
707 Machine is being normally stopped powering it off, or after the guest OS
708 has initiated a shutdown sequence.
709 </desc>
710 </const>
711 <const name="Saving" value="12">
712 <desc>
713 Machine is saving its execution state to a file, or an online
714 snapshot of the machine is being taken.
715 </desc>
716 </const>
717 <const name="Restoring" value="13">
718 <desc>
719 Execution state of the machine is being restored from a file
720 after powering it on from the saved execution state.
721 </desc>
722 </const>
723 <const name="TeleportingPausedVM" value="14">
724 <desc>
725 The machine is being teleported to another host or process, but it is
726 not running. This is the paused variant of the
727 @c state.
728 </desc>
729 </const>
730 <const name="TeleportingIn" value="15">
731 <desc>
732 Teleporting the machine state in from another host or process.
733 </desc>
734 </const>
735 <const name="FaultTolerantSyncing" value="16">
736 <desc>
737 The machine is being synced with a fault tolerant VM running elsewhere.
738 </desc>
739 </const>
740 <const name="DeletingSnapshotOnline" value="17">
741 <desc>
742 Like @c DeletingSnapshot, but the merging of media is ongoing in
743 the background while the machine is running.
744 </desc>
745 </const>
746 <const name="DeletingSnapshotPaused" value="18">
747 <desc>
748 Like @c DeletingSnapshotOnline, but the machine was paused when the
749 merging of differencing media was started.
750 </desc>
751 </const>
752 <const name="RestoringSnapshot" value="19">
753 <desc>
754 A machine snapshot is being restored; this typically does not take long.
755 </desc>
756 </const>
757 <const name="DeletingSnapshot" value="20">
758 <desc>
759 A machine snapshot is being deleted; this can take a long time since this
760 may require merging differencing media. This value indicates that the
761 machine is not running while the snapshot is being deleted.
762 </desc>
763 </const>
764 <const name="SettingUp" value="21">
765 <desc>
766 Lengthy setup operation is in progress.
767 </desc>
768 </const>
769
770 <const name="FirstOnline" value="5" wsmap="suppress"> <!-- Running -->
771 <desc>
772 Pseudo-state: first online state (for use in relational expressions).
773 </desc>
774 </const>
775 <const name="LastOnline" value="18" wsmap="suppress"> <!-- DeletingSnapshotPaused -->
776 <desc>
777 Pseudo-state: last online state (for use in relational expressions).
778 </desc>
779 </const>
780
781 <const name="FirstTransient" value="8" wsmap="suppress"> <!-- Teleporting -->
782 <desc>
783 Pseudo-state: first transient state (for use in relational expressions).
784 </desc>
785 </const>
786 <const name="LastTransient" value="21" wsmap="suppress"> <!-- SettingUp -->
787 <desc>
788 Pseudo-state: last transient state (for use in relational expressions).
789 </desc>
790 </const>
791
792 </enum>
793
794 <enum
795 name="SessionState"
796 uuid="cf2700c0-ea4b-47ae-9725-7810114b94d8"
797 >
798 <desc>
799 Session state. This enumeration represents possible values of
800 <link to="IMachine::sessionState"/> and <link to="ISession::state"/>
801 attributes.
802 </desc>
803
804 <const name="Null" value="0">
805 <desc>Null value (never used by the API).</desc>
806 </const>
807 <const name="Unlocked" value="1">
808 <desc>
809 In <link to="IMachine::sessionState"/>, this means that the machine
810 is not locked for any sessions.
811
812 In <link to="ISession::state"/>, this means that no machine is
813 currently locked for this session.
814 </desc>
815 </const>
816 <const name="Locked" value="2">
817 <desc>
818 In <link to="IMachine::sessionState"/>, this means that the machine
819 is currently locked for a session, whose process identifier can
820 then be found in the <link to="IMachine::sessionPid" /> attribute.
821
822 In <link to="ISession::state"/>, this means that a machine is
823 currently locked for this session, and the mutable machine object
824 can be found in the <link to="ISession::machine"/> attribute
825 (see <link to="IMachine::lockMachine" /> for details).
826 </desc>
827 </const>
828 <const name="Spawning" value="3">
829 <desc>
830 A new process is being spawned for the machine as a result of
831 <link to="IMachine::launchVMProcess"/> call. This state also occurs
832 as a short transient state during an <link to="IMachine::lockMachine"/>
833 call.
834 </desc>
835 </const>
836 <const name="Unlocking" value="4">
837 <desc>
838 The session is being unlocked.
839 </desc>
840 </const>
841 </enum>
842
843 <enum
844 name="CPUPropertyType"
845 uuid="24d356a6-2f45-4abd-b977-1cbe9c4701f5"
846 >
847 <desc>
848 Virtual CPU property type. This enumeration represents possible values of the
849 IMachine get- and setCPUProperty methods.
850 </desc>
851 <const name="Null" value="0">
852 <desc>Null value (never used by the API).</desc>
853 </const>
854 <const name="PAE" value="1">
855 <desc>
856 This setting determines whether VirtualBox will expose the Physical Address
857 Extension (PAE) feature of the host CPU to the guest. Note that in case PAE
858 is not available, it will not be reported.
859 </desc>
860 </const>
861 <const name="Synthetic" value="2">
862 <desc>
863 This setting determines whether VirtualBox will expose a synthetic CPU to the guest to allow
864 teleporting between host systems that differ significantly.
865 </desc>
866 </const>
867 </enum>
868
869
870 <enum
871 name="HWVirtExPropertyType"
872 uuid="ce81dfdd-d2b8-4a90-bbea-40ee8b7ffcee"
873 >
874 <desc>
875 Hardware virtualization property type. This enumeration represents possible values
876 for the <link to="IMachine::getHWVirtExProperty"/> and
877 <link to="IMachine::setHWVirtExProperty"/> methods.
878 </desc>
879 <const name="Null" value="0">
880 <desc>Null value (never used by the API).</desc>
881 </const>
882 <const name="Enabled" value="1">
883 <desc>
884 Whether hardware virtualization (VT-x/AMD-V) is enabled at all. If
885 such extensions are not available, they will not be used.
886 </desc>
887 </const>
888 <const name="Exclusive" value="2">
889 <desc>
890 Whether hardware virtualization is used exclusively by VirtualBox. When enabled,
891 VirtualBox assumes it can acquire full and exclusive access to the VT-x or AMD-V
892 feature of the host. To share these with other hypervisors, you must disable this property.
893 </desc>
894 </const>
895 <const name="VPID" value="3">
896 <desc>
897 Whether VT-x VPID is enabled. If this extension is not available, it will not be used.
898 </desc>
899 </const>
900 <const name="NestedPaging" value="4">
901 <desc>
902 Whether Nested Paging is enabled. If this extension is not available, it will not be used.
903 </desc>
904 </const>
905 <const name="LargePages" value="5">
906 <desc>
907 Whether large page allocation is enabled; requires nested paging and a 64 bits host.
908 </desc>
909 </const>
910 <const name="Force" value="6">
911 <desc>
912 Whether the VM should fail to start if hardware virtualization (VT-x/AMD-V) cannot be used. If
913 not set, there will be an automatic fallback to software virtualization.
914 </desc>
915 </const>
916 </enum>
917
918 <enum
919 name="FaultToleranceState"
920 uuid="5124f7ec-6b67-493c-9dee-ee45a44114e1"
921 >
922 <desc>
923 Used with <link to="IMachine::faultToleranceState" />.
924 </desc>
925 <const name="Inactive" value="1">
926 <desc>No fault tolerance enabled.</desc>
927 </const>
928 <const name="Master" value="2">
929 <desc>Fault tolerant master VM.</desc>
930 </const>
931 <const name="Standby" value="3">
932 <desc>Fault tolerant standby VM.</desc>
933 </const>
934 </enum>
935
936 <enum
937 name="LockType"
938 uuid="138b53f8-db4b-47c5-b32b-4ef52f769413"
939 >
940 <desc>
941 Used with <link to="IMachine::lockMachine" />.
942 </desc>
943 <const name="Write" value="2">
944 <desc>Lock the machine for writing.</desc>
945 </const>
946 <const name="Shared" value="1">
947 <desc>Request only a shared read lock for remote-controlling the machine.</desc>
948 </const>
949 </enum>
950
951 <enum
952 name="SessionType"
953 uuid="A13C02CB-0C2C-421E-8317-AC0E8AAA153A"
954 >
955 <desc>
956 Session type. This enumeration represents possible values of the
957 <link to="ISession::type"/> attribute.
958 </desc>
959
960 <const name="Null" value="0">
961 <desc>Null value (never used by the API).</desc>
962 </const>
963 <const name="WriteLock" value="1">
964 <desc>
965 Session has acquired an exclusive write lock on a machine
966 using <link to="IMachine::lockMachine"/>.
967 </desc>
968 </const>
969 <const name="Remote" value="2">
970 <desc>
971 Session has launched a VM process using
972 <link to="IMachine::launchVMProcess"/>
973 </desc>
974 </const>
975 <const name="Shared" value="3">
976 <desc>
977 Session has obtained a link to another session using
978 <link to="IMachine::lockMachine"/>
979 </desc>
980 </const>
981 </enum>
982
983 <enum
984 name="DeviceType"
985 uuid="6d9420f7-0b56-4636-99f9-7346f1b01e57"
986 >
987 <desc>
988 Device type.
989 </desc>
990 <const name="Null" value="0">
991 <desc>
992 Null value, may also mean "no device" (not allowed for
993 <link to="IConsole::getDeviceActivity"/>).
994 </desc>
995 </const>
996 <const name="Floppy" value="1">
997 <desc>Floppy device.</desc>
998 </const>
999 <const name="DVD" value="2">
1000 <desc>CD/DVD-ROM device.</desc>
1001 </const>
1002 <const name="HardDisk" value="3">
1003 <desc>Hard disk device.</desc>
1004 </const>
1005 <const name="Network" value="4">
1006 <desc>Network device.</desc>
1007 </const>
1008 <const name="USB" value="5">
1009 <desc>USB device.</desc>
1010 </const>
1011 <const name="SharedFolder" value="6">
1012 <desc>Shared folder device.</desc>
1013 </const>
1014 </enum>
1015
1016 <enum
1017 name="DeviceActivity"
1018 uuid="6FC8AEAA-130A-4eb5-8954-3F921422D707"
1019 >
1020 <desc>
1021 Device activity for <link to="IConsole::getDeviceActivity"/>.
1022 </desc>
1023
1024 <const name="Null" value="0"/>
1025 <const name="Idle" value="1"/>
1026 <const name="Reading" value="2"/>
1027 <const name="Writing" value="3"/>
1028 </enum>
1029
1030 <enum
1031 name="ClipboardMode"
1032 uuid="33364716-4008-4701-8f14-be0fa3d62950"
1033 >
1034 <desc>
1035 Host-Guest clipboard interchange mode.
1036 </desc>
1037
1038 <const name="Disabled" value="0"/>
1039 <const name="HostToGuest" value="1"/>
1040 <const name="GuestToHost" value="2"/>
1041 <const name="Bidirectional" value="3"/>
1042 </enum>
1043
1044 <enum
1045 name="Scope"
1046 uuid="7c91096e-499e-4eca-9f9b-9001438d7855"
1047 >
1048 <desc>
1049 Scope of the operation.
1050
1051 A generic enumeration used in various methods to define the action or
1052 argument scope.
1053 </desc>
1054
1055 <const name="Global" value="0"/>
1056 <const name="Machine" value="1"/>
1057 <const name="Session" value="2"/>
1058 </enum>
1059
1060 <enum
1061 name="BIOSBootMenuMode"
1062 uuid="ae4fb9f7-29d2-45b4-b2c7-d579603135d5"
1063 >
1064 <desc>
1065 BIOS boot menu mode.
1066 </desc>
1067
1068 <const name="Disabled" value="0"/>
1069 <const name="MenuOnly" value="1"/>
1070 <const name="MessageAndMenu" value="2"/>
1071 </enum>
1072
1073 <enum
1074 name="ProcessorFeature"
1075 uuid="64c38e6b-8bcf-45ad-ac03-9b406287c5bf"
1076 >
1077 <desc>
1078 CPU features.
1079 </desc>
1080
1081 <const name="HWVirtEx" value="0"/>
1082 <const name="PAE" value="1"/>
1083 <const name="LongMode" value="2"/>
1084 <const name="NestedPaging" value="3"/>
1085 </enum>
1086
1087 <enum
1088 name="FirmwareType"
1089 uuid="b903f264-c230-483e-ac74-2b37ce60d371"
1090 >
1091 <desc>
1092 Firmware type.
1093 </desc>
1094 <const name="BIOS" value="1">
1095 <desc>BIOS Firmware.</desc>
1096 </const>
1097 <const name="EFI" value="2">
1098 <desc>EFI Firmware, bitness detetced basing on OS type.</desc>
1099 </const>
1100 <const name="EFI32" value="3">
1101 <desc>Efi firmware, 32-bit.</desc>
1102 </const>
1103 <const name="EFI64" value="4">
1104 <desc>Efi firmware, 64-bit.</desc>
1105 </const>
1106 <const name="EFIDUAL" value="5">
1107 <desc>Efi firmware, combined 32 and 64-bit.</desc>
1108 </const>
1109 </enum>
1110
1111 <enum
1112 name="PointingHidType"
1113 uuid="0d3c17a2-821a-4b2e-ae41-890c6c60aa97"
1114 >
1115 <desc>
1116 Type of pointing device used in a virtual machine.
1117 </desc>
1118 <const name="None" value="1">
1119 <desc>No mouse.</desc>
1120 </const>
1121 <const name="PS2Mouse" value="2">
1122 <desc>PS/2 auxillary device, a.k.a. mouse.</desc>
1123 </const>
1124 <const name="USBMouse" value="3">
1125 <desc>USB mouse (relative pointer).</desc>
1126 </const>
1127 <const name="USBTablet" value="4">
1128 <desc>USB tablet (absolute pointer).</desc>
1129 </const>
1130 <const name="ComboMouse" value="5">
1131 <desc>Combined device, working as PS/2 or USB mouse, depending on guest behavior.
1132 Using of such device can have negative performance implications. </desc>
1133 </const>
1134 </enum>
1135
1136 <enum
1137 name="KeyboardHidType"
1138 uuid="5a5b0996-3a3e-44bb-9019-56979812cbcc"
1139 >
1140 <desc>
1141 Type of keyboard device used in a virtual machine.
1142 </desc>
1143 <const name="None" value="1">
1144 <desc>No keyboard.</desc>
1145 </const>
1146 <const name="PS2Keyboard" value="2">
1147 <desc>PS/2 keyboard.</desc>
1148 </const>
1149 <const name="USBKeyboard" value="3">
1150 <desc>USB keyboard.</desc>
1151 </const>
1152 <const name="ComboKeyboard" value="4">
1153 <desc>Combined device, working as PS/2 or USB keyboard, depending on guest behavior.
1154 Using of such device can have negative performance implications. </desc>
1155 </const>
1156 </enum>
1157
1158 <!--
1159 // IVirtualBoxErrorInfo
1160 /////////////////////////////////////////////////////////////////////////
1161 -->
1162
1163 <interface
1164 name="IVirtualBoxErrorInfo" extends="$errorinfo"
1165 uuid="e053d3c0-f493-491b-a735-3a9f0b1feed4"
1166 supportsErrorInfo="no"
1167 wsmap="managed"
1168 >
1169 <desc>
1170 The IVirtualBoxErrorInfo interface represents extended error information.
1171
1172 Extended error information can be set by VirtualBox components after
1173 unsuccessful or partially successful method invocation. This information
1174 can be retrieved by the calling party as an IVirtualBoxErrorInfo object
1175 and then shown to the client in addition to the plain 32-bit result code.
1176
1177 In MS COM, this interface extends the IErrorInfo interface,
1178 in XPCOM, it extends the nsIException interface. In both cases,
1179 it provides a set of common attributes to retrieve error
1180 information.
1181
1182 Sometimes invocation of some component's method may involve methods of
1183 other components that may also fail (independently of this method's
1184 failure), or a series of non-fatal errors may precede a fatal error that
1185 causes method failure. In cases like that, it may be desirable to preserve
1186 information about all errors happened during method invocation and deliver
1187 it to the caller. The <link to="#next"/> attribute is intended
1188 specifically for this purpose and allows to represent a chain of errors
1189 through a single IVirtualBoxErrorInfo object set after method invocation.
1190
1191 Note that errors are stored to a chain in the reverse order, i.e. the
1192 initial error object you query right after method invocation is the last
1193 error set by the callee, the object it points to in the @a next attribute
1194 is the previous error and so on, up to the first error (which is the last
1195 in the chain).
1196 </desc>
1197
1198 <attribute name="resultCode" type="long" readonly="yes">
1199 <desc>
1200 Result code of the error.
1201 Usually, it will be the same as the result code returned
1202 by the method that provided this error information, but not
1203 always. For example, on Win32, CoCreateInstance() will most
1204 likely return E_NOINTERFACE upon unsuccessful component
1205 instantiation attempt, but not the value the component factory
1206 returned. Value is typed 'long', not 'result',
1207 to make interface usable from scripting languages.
1208 <note>
1209 In MS COM, there is no equivalent.
1210 In XPCOM, it is the same as nsIException::result.
1211 </note>
1212 </desc>
1213 </attribute>
1214
1215 <attribute name="interfaceID" type="uuid" mod="string" readonly="yes">
1216 <desc>
1217 UUID of the interface that defined the error.
1218 <note>
1219 In MS COM, it is the same as IErrorInfo::GetGUID, except for the
1220 data type.
1221 In XPCOM, there is no equivalent.
1222 </note>
1223 </desc>
1224 </attribute>
1225
1226 <attribute name="component" type="wstring" readonly="yes">
1227 <desc>
1228 Name of the component that generated the error.
1229 <note>
1230 In MS COM, it is the same as IErrorInfo::GetSource.
1231 In XPCOM, there is no equivalent.
1232 </note>
1233 </desc>
1234 </attribute>
1235
1236 <attribute name="text" type="wstring" readonly="yes">
1237 <desc>
1238 Text description of the error.
1239 <note>
1240 In MS COM, it is the same as IErrorInfo::GetDescription.
1241 In XPCOM, it is the same as nsIException::message.
1242 </note>
1243 </desc>
1244 </attribute>
1245
1246 <attribute name="next" type="IVirtualBoxErrorInfo" readonly="yes">
1247 <desc>
1248 Next error object if there is any, or @c null otherwise.
1249 <note>
1250 In MS COM, there is no equivalent.
1251 In XPCOM, it is the same as nsIException::inner.
1252 </note>
1253 </desc>
1254 </attribute>
1255
1256 </interface>
1257
1258 <!--
1259 // IVirtualBox
1260 /////////////////////////////////////////////////////////////////////////
1261 -->
1262
1263 <interface
1264 name="IDHCPServer" extends="$unknown"
1265 uuid="6cfe387c-74fb-4ca7-bff6-973bec8af7a3"
1266 wsmap="managed"
1267 >
1268 <desc>
1269 The IDHCPServer interface represents the vbox dhcp server configuration.
1270
1271 To enumerate all the dhcp servers on the host, use the
1272 <link to="IVirtualBox::DHCPServers"/> attribute.
1273 </desc>
1274
1275 <attribute name="enabled" type="boolean">
1276 <desc>
1277 specifies if the dhcp server is enabled
1278 </desc>
1279 </attribute>
1280
1281 <attribute name="IPAddress" type="wstring" readonly="yes">
1282 <desc>
1283 specifies server IP
1284 </desc>
1285 </attribute>
1286
1287 <attribute name="networkMask" type="wstring" readonly="yes">
1288 <desc>
1289 specifies server network mask
1290 </desc>
1291 </attribute>
1292
1293 <attribute name="networkName" type="wstring" readonly="yes">
1294 <desc>
1295 specifies internal network name the server is used for
1296 </desc>
1297 </attribute>
1298
1299 <attribute name="lowerIP" type="wstring" readonly="yes">
1300 <desc>
1301 specifies from IP adrres in server address range
1302 </desc>
1303 </attribute>
1304
1305 <attribute name="upperIP" type="wstring" readonly="yes">
1306 <desc>
1307 specifies to IP adrres in server address range
1308 </desc>
1309 </attribute>
1310
1311 <method name="setConfiguration">
1312 <desc>
1313 configures the server
1314 <result name="E_INVALIDARG">
1315 invalid configuration supplied
1316 </result>
1317 </desc>
1318 <param name="IPAddress" type="wstring" dir="in">
1319 <desc>
1320 server IP address
1321 </desc>
1322 </param>
1323 <param name="networkMask" type="wstring" dir="in">
1324 <desc>
1325 server network mask
1326 </desc>
1327 </param>
1328 <param name="FromIPAddress" type="wstring" dir="in">
1329 <desc>
1330 server From IP address for address range
1331 </desc>
1332 </param>
1333 <param name="ToIPAddress" type="wstring" dir="in">
1334 <desc>
1335 server To IP address for address range
1336 </desc>
1337 </param>
1338 </method>
1339
1340 <method name="start">
1341 <desc>
1342 Starts DHCP server process.
1343 <result name="E_FAIL">
1344 Failed to start the process.
1345 </result>
1346 </desc>
1347 <param name="networkName" type="wstring" dir="in">
1348 <desc>
1349 Name of internal network DHCP server should attach to.
1350 </desc>
1351 </param>
1352 <param name="trunkName" type="wstring" dir="in">
1353 <desc>
1354 Name of internal network trunk.
1355 </desc>
1356 </param>
1357 <param name="trunkType" type="wstring" dir="in">
1358 <desc>
1359 Type of internal network trunk.
1360 </desc>
1361 </param>
1362 </method>
1363
1364 <method name="stop">
1365 <desc>
1366 Stops DHCP server process.
1367 <result name="E_FAIL">
1368 Failed to stop the process.
1369 </result>
1370 </desc>
1371 </method>
1372 </interface>
1373
1374 <interface
1375 name="IVirtualBox" extends="$unknown"
1376 uuid="ec6cc7e7-06a2-4c5d-8993-1e3619c53817"
1377 wsmap="managed"
1378 >
1379 <desc>
1380 The IVirtualBox interface represents the main interface exposed by the
1381 product that provides virtual machine management.
1382
1383 An instance of IVirtualBox is required for the product to do anything
1384 useful. Even though the interface does not expose this, internally,
1385 IVirtualBox is implemented as a singleton and actually lives in the
1386 process of the VirtualBox server (VBoxSVC.exe). This makes sure that
1387 IVirtualBox can track the state of all virtual machines on a particular
1388 host, regardless of which frontend started them.
1389
1390 To enumerate all the virtual machines on the host, use the
1391 <link to="IVirtualBox::machines"/> attribute.
1392 </desc>
1393
1394 <attribute name="version" type="wstring" readonly="yes">
1395 <desc>
1396 A string representing the version number of the product. The
1397 format is 3 integer numbers divided by dots (e.g. 1.0.1). The
1398 last number represents the build number and will frequently change.
1399 </desc>
1400 </attribute>
1401
1402 <attribute name="revision" type="unsigned long" readonly="yes">
1403 <desc>
1404 The internal build revision number of the product.
1405 </desc>
1406 </attribute>
1407
1408 <attribute name="packageType" type="wstring" readonly="yes">
1409 <desc>
1410 A string representing the package type of this product. The
1411 format is OS_ARCH_DIST where OS is either WINDOWS, LINUX,
1412 SOLARIS, DARWIN. ARCH is either 32BITS or 64BITS. DIST
1413 is either GENERIC, UBUNTU_606, UBUNTU_710, or something like
1414 this.
1415 </desc>
1416 </attribute>
1417
1418 <attribute name="homeFolder" type="wstring" readonly="yes">
1419 <desc>
1420 Full path to the directory where the global settings file,
1421 <tt>VirtualBox.xml</tt>, is stored.
1422
1423 In this version of VirtualBox, the value of this property is
1424 always <tt>&lt;user_dir&gt;/.VirtualBox</tt> (where
1425 <tt>&lt;user_dir&gt;</tt> is the path to the user directory,
1426 as determined by the host OS), and cannot be changed.
1427
1428 This path is also used as the base to resolve relative paths in
1429 places where relative paths are allowed (unless otherwise
1430 expressly indicated).
1431 </desc>
1432 </attribute>
1433
1434 <attribute name="settingsFilePath" type="wstring" readonly="yes">
1435 <desc>
1436 Full name of the global settings file.
1437 The value of this property corresponds to the value of
1438 <link to="#homeFolder"/> plus <tt>/VirtualBox.xml</tt>.
1439 </desc>
1440 </attribute>
1441
1442 <attribute name="host" type="IHost" readonly="yes">
1443 <desc>Associated host object.</desc>
1444 </attribute>
1445
1446 <attribute name="systemProperties" type="ISystemProperties" readonly="yes">
1447 <desc>Associated system information object.</desc>
1448 </attribute>
1449
1450 <attribute name="machines" type="IMachine" readonly="yes" safearray="yes">
1451 <desc>
1452 Array of machine objects registered within this VirtualBox instance.
1453 </desc>
1454 </attribute>
1455
1456 <attribute name="hardDisks" type="IMedium" readonly="yes" safearray="yes">
1457 <desc>
1458 Array of medium objects known to this VirtualBox installation.
1459
1460 This array contains only base media. All differencing
1461 media of the given base medium can be enumerated using
1462 <link to="IMedium::children"/>.
1463 </desc>
1464 </attribute>
1465
1466 <attribute name="DVDImages" type="IMedium" readonly="yes" safearray="yes">
1467 <desc>
1468 Array of CD/DVD image objects currently in use by this VirtualBox instance.
1469 </desc>
1470 </attribute>
1471
1472 <attribute name="floppyImages" type="IMedium" readonly="yes" safearray="yes">
1473 <desc>
1474 Array of floppy image objects currently in use by this VirtualBox instance.
1475 </desc>
1476 </attribute>
1477
1478 <attribute name="progressOperations" type="IProgress" readonly="yes" safearray="yes"/>
1479
1480 <attribute name="guestOSTypes" type="IGuestOSType" readonly="yes" safearray="yes"/>
1481
1482 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
1483 <desc>
1484 Collection of global shared folders. Global shared folders are
1485 available to all virtual machines.
1486
1487 New shared folders are added to the collection using
1488 <link to="#createSharedFolder"/>. Existing shared folders can be
1489 removed using <link to="#removeSharedFolder"/>.
1490
1491 <note>
1492 In the current version of the product, global shared folders are not
1493 implemented and therefore this collection is always empty.
1494 </note>
1495 </desc>
1496 </attribute>
1497
1498 <attribute name="performanceCollector" type="IPerformanceCollector" readonly="yes">
1499 <desc>
1500 Associated performance collector object.
1501 </desc>
1502 </attribute>
1503
1504 <attribute name="DHCPServers" type="IDHCPServer" safearray="yes" readonly="yes">
1505 <desc>
1506 dhcp server settings.
1507 </desc>
1508 </attribute>
1509
1510 <attribute name="eventSource" type="IEventSource" readonly="yes">
1511 <desc>
1512 Event source for VirtualBox events.
1513 </desc>
1514 </attribute>
1515
1516
1517 <method name="createMachine">
1518 <desc>
1519 Creates a new virtual machine.
1520
1521 The new machine is created unregistered, with the initial configuration
1522 set according to the specified guest OS type. A typical sequence of
1523 actions to create a new virtual machine is as follows:
1524
1525 <ol>
1526 <li>
1527 Call this method to have a new machine created. The returned machine
1528 object will be "mutable" allowing to change any machine property.
1529 </li>
1530
1531 <li>
1532 Configure the machine using the appropriate attributes and methods.
1533 </li>
1534
1535 <li>
1536 Call <link to="IMachine::saveSettings" /> to write the settings
1537 to the machine's XML settings file. The configuration of the newly
1538 created machine will not be saved to disk until this method is
1539 called.
1540 </li>
1541
1542 <li>
1543 Call <link to="#registerMachine" /> to add the machine to the list
1544 of machines known to VirtualBox.
1545 </li>
1546 </ol>
1547
1548 You should specify valid name for the newly created machine when calling
1549 this method. See the <link to="IMachine::name"/> attribute description
1550 for more details about the machine name.
1551
1552 The specified guest OS type identifier must match an ID of one of known
1553 guest OS types listed in the <link to="IVirtualBox::guestOSTypes"/>
1554 array.
1555
1556 Every machine has a <i>settings file</i> that is used to store
1557 the machine configuration. This file is stored in a directory called the
1558 <i>machine settings subfolder</i>. Both the settings subfolder and file
1559 will have a name that corresponds to the name of the virtual machine.
1560 You can specify where to create the machine setting subfolder using the
1561 @a baseFolder argument. The base folder can be absolute (full path) or
1562 relative to the <link to="IVirtualBox::homeFolder">VirtualBox home
1563 directory</link>.
1564
1565 If @a baseFolder is a @c null or empty string (which is recommended), the
1566 <link to="ISystemProperties::defaultMachineFolder">default machine
1567 settings folder</link> will be used as a base folder for the created
1568 machine. Otherwise the given base folder will be used. In either case,
1569 the full path to the resulting settings file has the following
1570 structure:
1571 <pre>
1572 &lt;base_folder&gt;/&lt;machine_name&gt;/&lt;machine_name&gt;.xml
1573 </pre>
1574
1575 Note that if the resulting settings file already exists, this method
1576 will fail with <link to="VBOX_E_FILE_ERROR"/>.
1577
1578 Optionally, you may specify an UUID of to assign to the created machine.
1579 However, this is not recommended and you should normally pass an empty
1580 (@c null) UUID to this method so that a new UUID will be automatically
1581 generated for every created machine. You can use UUID
1582 00000000-0000-0000-0000-000000000000 as @c null value.
1583
1584 <note>
1585 There is no way to change the name of the settings file or
1586 subfolder of the created machine directly.
1587 </note>
1588
1589 <result name="VBOX_E_OBJECT_NOT_FOUND">
1590 @a osTypeId is invalid.
1591 </result>
1592 <result name="VBOX_E_FILE_ERROR">
1593 Resulting settings file name is invalid or the settings file already
1594 exists or could not be created due to an I/O error.
1595 </result>
1596 <result name="E_INVALIDARG">
1597 @a name is empty or @c null.
1598 </result>
1599 </desc>
1600
1601 <param name="name" type="wstring" dir="in">
1602 <desc>Machine name.</desc>
1603 </param>
1604 <param name="osTypeId" type="wstring" dir="in">
1605 <desc>Guest OS Type ID.</desc>
1606 </param>
1607 <param name="baseFolder" type="wstring" dir="in">
1608 <desc>Base machine folder (optional).</desc>
1609 </param>
1610 <param name="id" type="uuid" mod="string" dir="in">
1611 <desc>Machine UUID (optional).</desc>
1612 </param>
1613 <param name="override" type="boolean" dir="in">
1614 <desc>Create the VM even if there are conflicting files.</desc>
1615 </param>
1616 <param name="machine" type="IMachine" dir="return">
1617 <desc>Created machine object.</desc>
1618 </param>
1619 </method>
1620
1621 <method name="openMachine">
1622 <desc>
1623 Opens a virtual machine from the existing settings file.
1624 The opened machine remains unregistered until you call
1625 <link to="#registerMachine"/>.
1626
1627 The specified settings file name can be absolute
1628 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1629 VirtualBox home directory</link>. This file must exist
1630 and must be a valid machine settings file whose contents
1631 will be used to construct the machine object.
1632
1633 <result name="VBOX_E_FILE_ERROR">
1634 Settings file name invalid, not found or sharing violation.
1635 </result>
1636 </desc>
1637 <param name="settingsFile" type="wstring" dir="in">
1638 <desc>
1639 Name of the machine settings file.
1640 </desc>
1641 </param>
1642 <param name="machine" type="IMachine" dir="return">
1643 <desc>Opened machine object.</desc>
1644 </param>
1645 <note>
1646 <link to="IMachine::settingsModified"/> will return
1647 @c false for the created machine, until any of machine settings
1648 are changed.
1649 </note>
1650 </method>
1651
1652 <method name="registerMachine">
1653 <desc>
1654
1655 Registers the machine previously created using
1656 <link to="#createMachine"/> or opened using
1657 <link to="#openMachine"/> within this VirtualBox installation. After
1658 successful method invocation, the
1659 <link to="IMachineRegisteredEvent"/> event is fired.
1660
1661 <note>
1662 This method implicitly calls <link to="IMachine::saveSettings"/>
1663 to save all current machine settings before registering it.
1664 </note>
1665
1666 <result name="VBOX_E_OBJECT_NOT_FOUND">
1667 No matching virtual machine found.
1668 </result>
1669 <result name="VBOX_E_INVALID_OBJECT_STATE">
1670 Virtual machine was not created within this VirtualBox instance.
1671 </result>
1672
1673 </desc>
1674 <param name="machine" type="IMachine" dir="in"/>
1675 </method>
1676
1677 <method name="getMachine">
1678 <desc>
1679 Attempts to find a virtual machine given its UUID.
1680 To look up a machine by name, use <link to="IVirtualBox::findMachine" />
1681 instead.
1682
1683 <result name="VBOX_E_OBJECT_NOT_FOUND">
1684 Could not find registered machine matching @a id.
1685 </result>
1686
1687 </desc>
1688 <param name="id" type="uuid" mod="string" dir="in"/>
1689 <param name="machine" type="IMachine" dir="return"/>
1690 </method>
1691
1692 <method name="findMachine">
1693 <desc>
1694 Attempts to find a virtual machine given its name.
1695 To look up a machine by UUID, use <link to="IVirtualBox::getMachine" />
1696 instead.
1697
1698 <result name="VBOX_E_OBJECT_NOT_FOUND">
1699 Could not find registered machine matching @a name.
1700 </result>
1701
1702 </desc>
1703 <param name="name" type="wstring" dir="in"/>
1704 <param name="machine" type="IMachine" dir="return"/>
1705 </method>
1706
1707 <method name="createAppliance">
1708 <desc>
1709 Creates a new appliance object, which represents an appliance in the Open Virtual Machine
1710 Format (OVF). This can then be used to import an OVF appliance into VirtualBox or to export
1711 machines as an OVF appliance; see the documentation for <link to="IAppliance" /> for details.
1712 </desc>
1713 <param name="appliance" type="IAppliance" dir="return">
1714 <desc>New appliance.</desc>
1715 </param>
1716 </method>
1717
1718 <method name="createHardDisk">
1719 <desc>
1720 Creates a new base medium object that will use the given storage
1721 format and location for medium data.
1722
1723 Note that the actual storage unit is not created by this method. In
1724 order to do it, and before you are able to attach the created medium
1725 to virtual machines, you must call one of the following methods to
1726 allocate a format-specific storage unit at the specified location:
1727 <ul>
1728 <li><link to="IMedium::createBaseStorage"/></li>
1729 <li><link to="IMedium::createDiffStorage"/></li>
1730 </ul>
1731
1732 Some medium attributes, such as <link to="IMedium::id"/>, may
1733 remain uninitialized until the medium storage unit is successfully
1734 created by one of the above methods.
1735
1736 After the storage unit is successfully created, it will be
1737 accessible through the <link to="#findMedium"/> method and can
1738 be found in the <link to="#hardDisks"/> array.
1739
1740 The list of all storage formats supported by this VirtualBox
1741 installation can be obtained using
1742 <link to="ISystemProperties::mediumFormats"/>. If the @a format
1743 attribute is empty or @c null then the default storage format
1744 specified by <link to="ISystemProperties::defaultHardDiskFormat"/> will
1745 be used for creating a storage unit of the medium.
1746
1747 Note that the format of the location string is storage format specific.
1748 See <link to="IMedium::location"/>, IMedium and
1749 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1750
1751 <result name="VBOX_E_OBJECT_NOT_FOUND">
1752 @a format identifier is invalid. See
1753 <link to="ISystemProperties::mediumFormats"/>.
1754 </result>
1755 <result name="VBOX_E_FILE_ERROR">
1756 @a location is a not valid file name (for file-based formats only).
1757 </result>
1758 </desc>
1759 <param name="format" type="wstring" dir="in">
1760 <desc>
1761 Identifier of the storage format to use for the new medium.
1762 </desc>
1763 </param>
1764 <param name="location" type="wstring" dir="in">
1765 <desc>
1766 Location of the storage unit for the new medium.
1767 </desc>
1768 </param>
1769 <param name="medium" type="IMedium" dir="return">
1770 <desc>Created medium object.</desc>
1771 </param>
1772 </method>
1773
1774 <method name="openMedium">
1775 <desc>
1776 Opens a medium from an existing storage location.
1777
1778 Once a medium has been opened, it can be passed to other VirtualBox
1779 methods, in particular to <link to="IMachine::attachDevice" />.
1780
1781 Depending on the given device type, the file at the storage location
1782 must be in one of the media formats understood by VirtualBox:
1783
1784 <ul>
1785 <li>With a "HardDisk" device type, the file must be a hard disk image
1786 in one of the formats supported by VirtualBox (see
1787 <link to="ISystemProperties::mediumFormats" />).
1788 After this method succeeds, if the medium is a base medium, it
1789 will be added to the <link to="#hardDisks"/> array attribute. </li>
1790 <li>With a "DVD" device type, the file must be an ISO 9960 CD/DVD image.
1791 After this method succeeds, the medium will be added to the
1792 <link to="#DVDImages"/> array attribute.</li>
1793 <li>With a "Floppy" device type, the file must be an RAW floppy image.
1794 After this method succeeds, the medium will be added to the
1795 <link to="#floppyImages"/> array attribute.</li>
1796 </ul>
1797
1798 After having been opened, the medium can be found by the <link to="#findMedium"/>
1799 method and can be attached to virtual machines. See <link to="IMedium" /> for more details.
1800
1801 The UUID of the newly opened medium will either be retrieved from the
1802 storage location, if the format supports it (e.g. for hard disk images),
1803 or a new UUID will be randomly generated (e.g. for ISO and RAW files).
1804 If for some reason you need to change the medium's UUID, use
1805 <link to="IMedium::setIDs" />.
1806
1807 If a differencing hard disk medium is to be opened by this method, the
1808 operation will succeed only if its parent medium and all ancestors,
1809 if any, are already known to this VirtualBox installation (for example,
1810 were opened by this method before).
1811
1812 This method attempts to guess the storage format of the specified medium
1813 by reading medium data at the specified location.
1814
1815 If @a accessMode is ReadWrite (which it should be for hard disks and floppies),
1816 the image is opened for read/write access and must have according permissions,
1817 as VirtualBox may actually write status information into the disk's metadata
1818 sections.
1819
1820 Note that write access is required for all typical hard disk usage in VirtualBox,
1821 since VirtualBox may need to write metadata such as a UUID into the image.
1822 The only exception is opening a source image temporarily for copying and
1823 cloning (see <link to="IMedium::cloneTo" /> when the image will be closed
1824 again soon.
1825
1826 The format of the location string is storage format specific. See
1827 <link to="IMedium::location"/>, IMedium and
1828 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1829
1830 Prior to VirtualBox 3.3, opening a medium added it to a global media
1831 registry in the VirtualBox.xml file, which was shared between
1832 all machines and made transporting machines and their media from one
1833 host to another difficult.
1834
1835 Starting with VirtualBox 3.3, media are only added to a registry when
1836 they are attached to a machine. Machines created with VirtualBox 3.3
1837 or later can have their own media registry. As a result, a medium attached
1838 to such a machine will be remembered in that machine's XML settings file.
1839 Media attached to older machines will continue to be added to the global
1840 registry.
1841
1842 <result name="VBOX_E_FILE_ERROR">
1843 Invalid medium storage file location or could not find the medium
1844 at the specified location.
1845 </result>
1846 <result name="VBOX_E_IPRT_ERROR">
1847 Could not get medium storage format.
1848 </result>
1849 <result name="E_INVALIDARG">
1850 Invalid medium storage format.
1851 </result>
1852 <result name="VBOX_E_INVALID_OBJECT_STATE">
1853 Medium has already been added to a media registry.
1854 </result>
1855 </desc>
1856 <param name="location" type="wstring" dir="in">
1857 <desc>
1858 Location of the storage unit that contains medium data in one of
1859 the supported storage formats.
1860 </desc>
1861 </param>
1862 <param name="deviceType" type="DeviceType" dir="in">
1863 <desc>
1864 Must be one of "HardDisk", "DVD" or "Floppy".
1865 </desc>
1866 </param>
1867 <param name="accessMode" type="AccessMode" dir="in">
1868 <desc>Whether to open the image in read/write or read-only mode. For
1869 a "DVD" device type, this is ignored and read-only mode is always assumed.</desc>
1870 </param>
1871 <param name="medium" type="IMedium" dir="return">
1872 <desc>Opened medium object.</desc>
1873 </param>
1874 </method>
1875
1876 <method name="findMedium">
1877 <desc>
1878 Returns a medium of the given type that uses the given location or
1879 UUID to store medium data.
1880
1881 The given medium must be known to this VirtualBox installation, i.e.
1882 it must be previously created by <link to="#createHardDisk"/> or opened
1883 by <link to="#openMedium"/>.
1884
1885 The search is done by comparing the value of the @a location argument to
1886 the <link to="IMedium::location"/> and <link to="IMedium::id" />
1887 attributes of each known medium.
1888
1889 For locations represented by file names in the host's file system, the
1890 requested location can be a path relative to the
1891 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
1892 only a file name without any path is given, the
1893 <link to="ISystemProperties::defaultHardDiskFolder"> default medium
1894 folder</link> will be prepended to the file name before searching. Note
1895 that on case sensitive file systems, a case sensitive comparison is
1896 performed, otherwise the case of symbols in the file path is ignored.
1897
1898 <result name="VBOX_E_OBJECT_NOT_FOUND">
1899 No medium object matching @a location found.
1900 </result>
1901 </desc>
1902 <param name="location" type="wstring" dir="in">
1903 <desc>What to search for. This can either be the UUID or the location string of an open medium.</desc>
1904 </param>
1905 <param name="type" type="DeviceType" dir="in">
1906 <desc>Device type (must be HardDisk, DVD or Floppy)</desc>
1907 </param>
1908 <param name="medium" type="IMedium" dir="return">
1909 <desc>Medium object, if found.</desc>
1910 </param>
1911 </method>
1912
1913 <method name="getGuestOSType">
1914 <desc>
1915 Returns an object describing the specified guest OS type.
1916
1917 The requested guest OS type is specified using a string which is a
1918 mnemonic identifier of the guest operating system, such as
1919 <tt>"win31"</tt> or <tt>"ubuntu"</tt>. The guest OS type ID of a
1920 particular virtual machine can be read or set using the
1921 <link to="IMachine::OSTypeId"/> attribute.
1922
1923 The <link to="IVirtualBox::guestOSTypes"/> collection contains all
1924 available guest OS type objects. Each object has an
1925 <link to="IGuestOSType::id"/> attribute which contains an identifier of
1926 the guest OS this object describes.
1927
1928 <result name="E_INVALIDARG">
1929 @a id is not a valid Guest OS type.
1930 </result>
1931
1932 </desc>
1933 <param name="id" type="uuid" mod="string" dir="in">
1934 <desc>Guest OS type ID string.</desc>
1935 </param>
1936 <param name="type" type="IGuestOSType" dir="return">
1937 <desc>Guest OS type object.</desc>
1938 </param>
1939 </method>
1940
1941 <method name="createSharedFolder">
1942 <desc>
1943 Creates a new global shared folder by associating the given logical
1944 name with the given host path, adds it to the collection of shared
1945 folders and starts sharing it. Refer to the description of
1946 <link to="ISharedFolder"/> to read more about logical names.
1947 <note>
1948 In the current implementation, this operation is not
1949 implemented.
1950 </note>
1951 </desc>
1952 <param name="name" type="wstring" dir="in">
1953 <desc>Unique logical name of the shared folder.</desc>
1954 </param>
1955 <param name="hostPath" type="wstring" dir="in">
1956 <desc>Full path to the shared folder in the host file system.</desc>
1957 </param>
1958 <param name="writable" type="boolean" dir="in">
1959 <desc>Whether the share is writable or readonly</desc>
1960 </param>
1961 <param name="automount" type="boolean" dir="in">
1962 <desc>Whether the share gets automatically mounted by the guest
1963 or not.</desc>
1964 </param>
1965 </method>
1966
1967 <method name="removeSharedFolder">
1968 <desc>
1969 Removes the global shared folder with the given name previously
1970 created by <link to="#createSharedFolder"/> from the collection of
1971 shared folders and stops sharing it.
1972 <note>
1973 In the current implementation, this operation is not
1974 implemented.
1975 </note>
1976 </desc>
1977 <param name="name" type="wstring" dir="in">
1978 <desc>Logical name of the shared folder to remove.</desc>
1979 </param>
1980 </method>
1981
1982 <method name="getExtraDataKeys">
1983 <desc>
1984 Returns an array representing the global extra data keys which currently
1985 have values defined.
1986 </desc>
1987 <param name="value" type="wstring" dir="return" safearray="yes">
1988 <desc>Array of extra data keys.</desc>
1989 </param>
1990 </method>
1991
1992 <method name="getExtraData">
1993 <desc>
1994 Returns associated global extra data.
1995
1996 If the requested data @a key does not exist, this function will
1997 succeed and return an empty string in the @a value argument.
1998
1999 <result name="VBOX_E_FILE_ERROR">
2000 Settings file not accessible.
2001 </result>
2002 <result name="VBOX_E_XML_ERROR">
2003 Could not parse the settings file.
2004 </result>
2005
2006 </desc>
2007 <param name="key" type="wstring" dir="in">
2008 <desc>Name of the data key to get.</desc>
2009 </param>
2010 <param name="value" type="wstring" dir="return">
2011 <desc>Value of the requested data key.</desc>
2012 </param>
2013 </method>
2014
2015 <method name="setExtraData">
2016 <desc>
2017 Sets associated global extra data.
2018
2019 If you pass @c null or empty string as a key @a value, the given @a key
2020 will be deleted.
2021
2022 <note>
2023 Before performing the actual data change, this method will ask all
2024 registered event listener using the
2025 <link to="IExtraDataCanChangeEvent"/>
2026 notification for a permission. If one of the listeners refuses the
2027 new value, the change will not be performed.
2028 </note>
2029 <note>
2030 On success, the
2031 <link to="IExtraDataChangedEvent"/> notification
2032 is called to inform all registered listeners about a successful data
2033 change.
2034 </note>
2035
2036 <result name="VBOX_E_FILE_ERROR">
2037 Settings file not accessible.
2038 </result>
2039 <result name="VBOX_E_XML_ERROR">
2040 Could not parse the settings file.
2041 </result>
2042 <result name="E_ACCESSDENIED">
2043 Modification request refused.
2044 </result>
2045
2046 </desc>
2047 <param name="key" type="wstring" dir="in">
2048 <desc>Name of the data key to set.</desc>
2049 </param>
2050 <param name="value" type="wstring" dir="in">
2051 <desc>Value to assign to the key.</desc>
2052 </param>
2053 </method>
2054
2055 <method name="waitForPropertyChange">
2056 <desc>
2057 Blocks the caller until any of the properties represented by the
2058 @a what argument changes the value or until the given timeout interval
2059 expires.
2060
2061 The @a what argument is a comma separated list of property masks that
2062 describe properties the caller is interested in. The property mask is
2063 a string in the following format:
2064
2065 <pre>
2066 [[group.]subgroup.]name
2067 </pre>
2068
2069 where @c name is the property name and @c group, @c subgroup are zero
2070 or more property group specifiers. Each element (group or name) in
2071 the property mask may be either a Latin string or an asterisk symbol
2072 (@c "*") which is used to match any string for the given element. A
2073 property mask that doesn't contain asterisk symbols represents a
2074 single fully qualified property name.
2075
2076 Groups in the fully qualified property name go from more generic (the
2077 left-most part) to more specific (the right-most part). The first
2078 element is usually a name of the object the property belongs to. The
2079 second element may be either a property name, or a child object name,
2080 or an index if the preceding element names an object which is one of
2081 many objects of the same type. This way, property names form a
2082 hierarchy of properties. Here are some examples of property names:
2083
2084 <table>
2085 <tr>
2086 <td><tt>VirtualBox.version</tt></td>
2087 <td><link to="IVirtualBox::version"/> property</td>
2088 </tr>
2089 <tr>
2090 <td><tt>Machine.&lt;UUID&gt;.name</tt></td>
2091 <td><link to="IMachine::name"/> property of the machine with the
2092 given UUID</td>
2093 </tr>
2094 </table>
2095
2096 Most property names directly correspond to the properties of objects
2097 (components) provided by the VirtualBox library and may be used to
2098 track changes to these properties. However, there may be
2099 pseudo-property names that don't correspond to any existing object's
2100 property directly, as well as there may be object properties that
2101 don't have a corresponding property name that is understood by this
2102 method, and therefore changes to such properties cannot be
2103 tracked. See individual object's property descriptions to get a
2104 fully qualified property name that can be used with this method (if
2105 any).
2106
2107 There is a special property mask @c "*" (i.e. a string consisting of a
2108 single asterisk symbol) that can be used to match all properties.
2109 Below are more examples of property masks:
2110
2111 <table>
2112 <tr>
2113 <td><tt>VirtualBox.*</tt></td>
2114 <td>Track all properties of the VirtualBox object</td>
2115 </tr>
2116 <tr>
2117 <td><tt>Machine.*.name</tt></td>
2118 <td>Track changes to the <link to="IMachine::name"/> property of
2119 all registered virtual machines</td>
2120 </tr>
2121 </table>
2122
2123 <note>
2124 This function is not implemented in the current version of the
2125 product.
2126 </note>
2127 </desc>
2128 <param name="what" type="wstring" dir="in">
2129 <desc>Comma separated list of property masks.</desc>
2130 </param>
2131 <param name="timeout" type="unsigned long" dir="in">
2132 <desc>
2133 Wait timeout in milliseconds.
2134 Specify -1 for an indefinite wait.
2135 </desc>
2136 </param>
2137 <param name="changed" type="wstring" dir="out">
2138 <desc>
2139 Comma separated list of properties that have been changed and caused
2140 this method to return to the caller.
2141 </desc>
2142 </param>
2143 <param name="values" type="wstring" dir="out">
2144 <desc>Reserved, not currently used.</desc>
2145 </param>
2146 </method>
2147
2148 <!--method name="createDHCPServerForInterface">
2149 <desc>
2150 Creates a dhcp server settings to be used for the given interface
2151 <result name="E_INVALIDARG">
2152 Host network interface @a name already exists.
2153 </result>
2154 </desc>
2155 <param name="interface" type="IHostNetworkInterface" dir="in">
2156 <desc>Network Interface</desc>
2157 </param>
2158 <param name="server" type="IDHCPServer" dir="out">
2159 <desc>Dhcp server settings</desc>
2160 </param>
2161 </method-->
2162
2163 <method name="createDHCPServer">
2164 <desc>
2165 Creates a dhcp server settings to be used for the given internal network name
2166 <result name="E_INVALIDARG">
2167 Host network interface @a name already exists.
2168 </result>
2169 </desc>
2170 <param name="name" type="wstring" dir="in">
2171 <desc>server name</desc>
2172 </param>
2173 <param name="server" type="IDHCPServer" dir="return">
2174 <desc>Dhcp server settings</desc>
2175 </param>
2176 </method>
2177
2178 <method name="findDHCPServerByNetworkName">
2179 <desc>
2180 Searches a dhcp server settings to be used for the given internal network name
2181 <result name="E_INVALIDARG">
2182 Host network interface @a name already exists.
2183 </result>
2184
2185 </desc>
2186 <param name="name" type="wstring" dir="in">
2187 <desc>server name</desc>
2188 </param>
2189 <param name="server" type="IDHCPServer" dir="return">
2190 <desc>Dhcp server settings</desc>
2191 </param>
2192 </method>
2193
2194 <!--method name="findDHCPServerForInterface">
2195 <desc>
2196 Searches a dhcp server settings to be used for the given interface
2197 <result name="E_INVALIDARG">
2198 Host network interface @a name already exists.
2199 </result>
2200 </desc>
2201 <param name="interface" type="IHostNetworkInterface" dir="in">
2202 <desc>Network Interface</desc>
2203 </param>
2204 <param name="server" type="IDHCPServer" dir="out">
2205 <desc>Dhcp server settings</desc>
2206 </param>
2207 </method-->
2208
2209 <method name="removeDHCPServer">
2210 <desc>
2211 Removes the dhcp server settings
2212 <result name="E_INVALIDARG">
2213 Host network interface @a name already exists.
2214 </result>
2215 </desc>
2216 <param name="server" type="IDHCPServer" dir="in">
2217 <desc>Dhcp server settings to be removed</desc>
2218 </param>
2219 </method>
2220
2221
2222 <method name="checkFirmwarePresent">
2223 <desc>
2224 Check if this VirtualBox installation has a firmware
2225 of the given type available, either system-wide or per-user.
2226 Optionally, this may return a hint where this firmware can be
2227 downloaded from.
2228 </desc>
2229 <param name="firmwareType" type="FirmwareType" dir="in">
2230 <desc>
2231 Type of firmware to check.
2232 </desc>
2233 </param>
2234 <param name="version" type="wstring" dir="in">
2235 <desc>Expected version number, usually empty string (presently ignored).</desc>
2236 </param>
2237
2238 <param name="url" type="wstring" dir="out">
2239 <desc>
2240 Suggested URL to download this firmware from.
2241 </desc>
2242 </param>
2243
2244 <param name="file" type="wstring" dir="out">
2245 <desc>
2246 Filename of firmware, only valid if result == TRUE.
2247 </desc>
2248 </param>
2249
2250 <param name="result" type="boolean" dir="return">
2251 <desc>If firmware of this type and version is available.</desc>
2252 </param>
2253 </method>
2254
2255 </interface>
2256
2257 <!--
2258 // IVFSExplorer
2259 /////////////////////////////////////////////////////////////////////////
2260 -->
2261
2262 <enum
2263 name="VFSType"
2264 uuid="813999ba-b949-48a8-9230-aadc6285e2f2"
2265 >
2266 <desc>
2267 Virtual file systems supported by VFSExplorer.
2268 </desc>
2269
2270 <const name="File" value="1" />
2271 <const name="Cloud" value="2" />
2272 <const name="S3" value="3" />
2273 <const name="WebDav" value="4" />
2274 </enum>
2275
2276 <enum
2277 name="VFSFileType"
2278 uuid="714333cd-44e2-415f-a245-d378fa9b1242"
2279 >
2280 <desc>
2281 File types known by VFSExplorer.
2282 </desc>
2283
2284 <const name="Unknown" value="1" />
2285 <const name="Fifo" value="2" />
2286 <const name="DevChar" value="3" />
2287 <const name="Directory" value="4" />
2288 <const name="DevBlock" value="5" />
2289 <const name="File" value="6" />
2290 <const name="SymLink" value="7" />
2291 <const name="Socket" value="8" />
2292 <const name="WhiteOut" value="9" />
2293 </enum>
2294
2295 <interface
2296 name="IVFSExplorer" extends="$unknown"
2297 uuid="2bb864a1-02a3-4474-a1d4-fb5f23b742e1"
2298 wsmap="managed"
2299 >
2300 <desc>
2301 The VFSExplorer interface unifies access to different file system
2302 types. This includes local file systems as well remote file systems like
2303 S3. For a list of supported types see <link to="VFSType" />.
2304 An instance of this is returned by <link to="IAppliance::createVFSExplorer" />.
2305 </desc>
2306
2307 <attribute name="path" type="wstring" readonly="yes">
2308 <desc>Returns the current path in the virtual file system.</desc>
2309 </attribute>
2310
2311 <attribute name="type" type="VFSType" readonly="yes">
2312 <desc>Returns the file system type which is currently in use.</desc>
2313 </attribute>
2314
2315 <method name="update">
2316 <desc>Updates the internal list of files/directories from the
2317 current directory level. Use <link to="#entryList" /> to get the full list
2318 after a call to this method.</desc>
2319
2320 <param name="aProgress" type="IProgress" dir="return">
2321 <desc>Progress object to track the operation completion.</desc>
2322 </param>
2323 </method>
2324
2325 <method name="cd">
2326 <desc>Change the current directory level.</desc>
2327
2328 <param name="aDir" type="wstring" dir="in">
2329 <desc>The name of the directory to go in.</desc>
2330 </param>
2331
2332 <param name="aProgress" type="IProgress" dir="return">
2333 <desc>Progress object to track the operation completion.</desc>
2334 </param>
2335 </method>
2336
2337 <method name="cdUp">
2338 <desc>Go one directory upwards from the current directory level.</desc>
2339
2340 <param name="aProgress" type="IProgress" dir="return">
2341 <desc>Progress object to track the operation completion.</desc>
2342 </param>
2343 </method>
2344
2345 <method name="entryList">
2346 <desc>Returns a list of files/directories after a call to <link
2347 to="#update" />. The user is responsible for keeping this internal
2348 list up do date.</desc>
2349
2350 <param name="aNames" type="wstring" safearray="yes" dir="out">
2351 <desc>The list of names for the entries.</desc>
2352 </param>
2353
2354 <param name="aTypes" type="unsigned long" safearray="yes" dir="out">
2355 <desc>The list of types for the entries.</desc>
2356 </param>
2357 </method>
2358
2359 <method name="exists">
2360 <desc>Checks if the given file list exists in the current directory
2361 level.</desc>
2362
2363 <param name="aNames" type="wstring" safearray="yes" dir="in">
2364 <desc>The names to check.</desc>
2365 </param>
2366
2367 <param name="aExists" type="wstring" safearray="yes" dir="return">
2368 <desc>The names which exist.</desc>
2369 </param>
2370 </method>
2371
2372 <method name="remove">
2373 <desc>Deletes the given files in the current directory level.</desc>
2374
2375 <param name="aNames" type="wstring" safearray="yes" dir="in">
2376 <desc>The names to remove.</desc>
2377 </param>
2378
2379 <param name="aProgress" type="IProgress" dir="return">
2380 <desc>Progress object to track the operation completion.</desc>
2381 </param>
2382 </method>
2383
2384 </interface>
2385
2386 <!--
2387 // IAppliance
2388 /////////////////////////////////////////////////////////////////////////
2389 -->
2390
2391 <interface
2392 name="IAppliance" extends="$unknown"
2393 uuid="7b148032-4124-4f46-b56a-b48ac1273f5a"
2394 wsmap="managed"
2395 >
2396 <desc>
2397 Represents a platform-independent appliance in OVF format. An instance of this is returned
2398 by <link to="IVirtualBox::createAppliance" />, which can then be used to import and export
2399 virtual machines within an appliance with VirtualBox.
2400
2401 The OVF standard suggests two different physical file formats:
2402
2403 <ol>
2404 <li>If the appliance is distributed as a set of files, there must be at least one XML descriptor
2405 file that conforms to the OVF standard and carries an <tt>.ovf</tt> file extension. If
2406 this descriptor file references other files such as disk images, as OVF appliances typically
2407 do, those additional files must be in the same directory as the descriptor file.</li>
2408
2409 <li>If the appliance is distributed as a single file, it must be in TAR format and have the
2410 <tt>.ova</tt> file extension. This TAR file must then contain at least the OVF descriptor
2411 files and optionally other files.
2412
2413 At this time, VirtualBox does not not yet support the packed (TAR) variant; support will
2414 be added with a later version.</li>
2415 </ol>
2416
2417 <b>Importing</b> an OVF appliance into VirtualBox as instances of
2418 <link to="IMachine" /> involves the following sequence of API calls:
2419
2420 <ol>
2421 <li>Call <link to="IVirtualBox::createAppliance" />. This will create an empty IAppliance object.
2422 </li>
2423
2424 <li>On the new object, call <link to="#read" /> with the full path of the OVF file you
2425 would like to import. So long as this file is syntactically valid, this will succeed
2426 and fill the appliance object with the parsed data from the OVF file.
2427 </li>
2428
2429 <li>Next, call <link to="#interpret" />, which analyzes the OVF data and sets up the
2430 contents of the IAppliance attributes accordingly. These can be inspected by a
2431 VirtualBox front-end such as the GUI, and the suggestions can be displayed to the
2432 user. In particular, the <link to="#virtualSystemDescriptions" /> array contains
2433 instances of <link to="IVirtualSystemDescription" /> which represent the virtual
2434 systems (machines) in the OVF, which in turn describe the virtual hardware prescribed
2435 by the OVF (network and hardware adapters, virtual disk images, memory size and so on).
2436 The GUI can then give the user the option to confirm and/or change these suggestions.
2437 </li>
2438
2439 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
2440 virtual system (machine) to override the suggestions made by the interpret() routine.
2441 </li>
2442
2443 <li>Finally, call <link to="#importMachines" /> to create virtual machines in
2444 VirtualBox as instances of <link to="IMachine" /> that match the information in the
2445 virtual system descriptions. After this call suceeded, the UUIDs of the machines created
2446 can be found in the <link to="#machines" /> array attribute.
2447 </li>
2448 </ol>
2449
2450 <b>Exporting</b> VirtualBox machines into an OVF appliance involves the following steps:
2451
2452 <ol>
2453 <li>As with importing, first call <link to="IVirtualBox::createAppliance" /> to create
2454 an empty IAppliance object.
2455 </li>
2456
2457 <li>For each machine you would like to export, call <link to="IMachine::export" />
2458 with the IAppliance object you just created. Each such call creates one instance of
2459 <link to="IVirtualSystemDescription" /> inside the appliance.
2460 </li>
2461
2462 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
2463 virtual system (machine) to override the suggestions made by the export() routine.
2464 </li>
2465
2466 <li>Finally, call <link to="#write" /> with a path specification to have the OVF
2467 file written.</li>
2468 </ol>
2469
2470 </desc>
2471
2472 <attribute name="path" type="wstring" readonly="yes">
2473 <desc>Path to the main file of the OVF appliance, which is either the <tt>.ovf</tt> or
2474 the <tt>.ova</tt> file passed to <link to="#read" /> (for import) or
2475 <link to="#write" /> (for export).
2476 This attribute is empty until one of these methods has been called.
2477 </desc>
2478 </attribute>
2479
2480 <attribute name="disks" type="wstring" readonly="yes" safearray="yes">
2481 <desc>
2482 Array of virtual disk definitions. One such description exists for each
2483 disk definition in the OVF; each string array item represents one such piece of
2484 disk information, with the information fields separated by tab (\t) characters.
2485
2486 The caller should be prepared for additional fields being appended to
2487 this string in future versions of VirtualBox and therefore check for
2488 the number of tabs in the strings returned.
2489
2490 In the current version, the following eight fields are returned per string
2491 in the array:
2492
2493 <ol>
2494 <li>Disk ID (unique string identifier given to disk)</li>
2495
2496 <li>Capacity (unsigned integer indicating the maximum capacity of the disk)</li>
2497
2498 <li>Populated size (optional unsigned integer indicating the current size of the
2499 disk; can be approximate; -1 if unspecified)</li>
2500
2501 <li>Format (string identifying the disk format, typically
2502 "http://www.vmware.com/specifications/vmdk.html#sparse")</li>
2503
2504 <li>Reference (where to find the disk image, typically a file name; if empty,
2505 then the disk should be created on import)</li>
2506
2507 <li>Image size (optional unsigned integer indicating the size of the image,
2508 which need not necessarily be the same as the values specified above, since
2509 the image may be compressed or sparse; -1 if not specified)</li>
2510
2511 <li>Chunk size (optional unsigned integer if the image is split into chunks;
2512 presently unsupported and always -1)</li>
2513
2514 <li>Compression (optional string equalling "gzip" if the image is gzip-compressed)</li>
2515 </ol>
2516 </desc>
2517 </attribute>
2518
2519 <attribute name="virtualSystemDescriptions" type="IVirtualSystemDescription" readonly="yes" safearray="yes">
2520 <desc> Array of virtual system descriptions. One such description is created
2521 for each virtual system (machine) found in the OVF.
2522 This array is empty until either <link to="#interpret" /> (for import) or <link to="IMachine::export" />
2523 (for export) has been called.
2524 </desc>
2525 </attribute>
2526
2527 <attribute name="machines" type="wstring" readonly="yes" safearray="yes">
2528 <desc>
2529 Contains the UUIDs of the machines created from the information in this appliances. This is only
2530 relevant for the import case, and will only contain data after a call to <link to="#importMachines" />
2531 succeeded.
2532 </desc>
2533 </attribute>
2534
2535 <method name="read">
2536 <desc>
2537 Reads an OVF file into the appliance object.
2538
2539 This method succeeds if the OVF is syntactically valid and, by itself, without errors. The
2540 mere fact that this method returns successfully does not mean that VirtualBox supports all
2541 features requested by the appliance; this can only be examined after a call to <link to="#interpret" />.
2542 </desc>
2543 <param name="file" type="wstring" dir="in">
2544 <desc>
2545 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
2546 on whether the appliance is distributed as a set of files or as a single file, respectively).
2547 </desc>
2548 </param>
2549 <param name="aProgress" type="IProgress" dir="return">
2550 <desc>Progress object to track the operation completion.</desc>
2551 </param>
2552 </method>
2553
2554 <method name="interpret">
2555 <desc>
2556 Interprets the OVF data that was read when the appliance was constructed. After
2557 calling this method, one can inspect the
2558 <link to="#virtualSystemDescriptions" /> array attribute, which will then contain
2559 one <link to="IVirtualSystemDescription" /> for each virtual machine found in
2560 the appliance.
2561
2562 Calling this method is the second step of importing an appliance into VirtualBox;
2563 see <link to="IAppliance" /> for an overview.
2564
2565 After calling this method, one should call <link to="#getWarnings" /> to find out
2566 if problems were encountered during the processing which might later lead to
2567 errors.
2568 </desc>
2569 </method>
2570
2571 <method name="importMachines">
2572 <desc>
2573 Imports the appliance into VirtualBox by creating instances of <link to="IMachine" />
2574 and other interfaces that match the information contained in the appliance as
2575 closely as possible, as represented by the import instructions in the
2576 <link to="#virtualSystemDescriptions" /> array.
2577
2578 Calling this method is the final step of importing an appliance into VirtualBox;
2579 see <link to="IAppliance" /> for an overview.
2580
2581 Since importing the appliance will most probably involve copying and converting
2582 disk images, which can take a long time, this method operates asynchronously and
2583 returns an IProgress object to allow the caller to monitor the progress.
2584
2585 After the import succeeded, the UUIDs of the IMachine instances created can be
2586 retrieved from the <link to="#machines" /> array attribute.
2587 </desc>
2588
2589 <param name="aProgress" type="IProgress" dir="return">
2590 <desc>Progress object to track the operation completion.</desc>
2591 </param>
2592 </method>
2593
2594 <method name="createVFSExplorer">
2595 <desc>Returns a <link to="IVFSExplorer" /> object for the given URI.</desc>
2596
2597 <param name="aUri" type="wstring" dir="in">
2598 <desc>The URI describing the file system to use.</desc>
2599 </param>
2600
2601 <param name="aExplorer" type="IVFSExplorer" dir="return">
2602 <desc></desc>
2603 </param>
2604 </method>
2605
2606 <method name="write">
2607 <desc>
2608 Writes the contents of the appliance exports into a new OVF file.
2609
2610 Calling this method is the final step of exporting an appliance from VirtualBox;
2611 see <link to="IAppliance" /> for an overview.
2612
2613 Since exporting the appliance will most probably involve copying and converting
2614 disk images, which can take a long time, this method operates asynchronously and
2615 returns an IProgress object to allow the caller to monitor the progress.
2616 </desc>
2617 <param name="format" type="wstring" dir="in">
2618 <desc>
2619 Output format, as a string. Currently supported formats are "ovf-0.9" and "ovf-1.0";
2620 future versions of VirtualBox may support additional formats.
2621 </desc>
2622 </param>
2623 <param name="manifest" type="boolean" dir="in">
2624 <desc>
2625 Indicate if the optional manifest file (.mf) should be written. The manifest file
2626 is used for integrity checks prior import.
2627 </desc>
2628 </param>
2629 <param name="path" type="wstring" dir="in">
2630 <desc>
2631 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
2632 on whether the appliance is distributed as a set of files or as a single file, respectively).
2633 </desc>
2634 </param>
2635 <param name="progress" type="IProgress" dir="return">
2636 <desc>Progress object to track the operation completion.</desc>
2637 </param>
2638 </method>
2639
2640 <method name="getWarnings">
2641 <desc>Returns textual warnings which occurred during execution of <link to="#interpret" />.</desc>
2642
2643 <param name="aWarnings" type="wstring" dir="return" safearray="yes">
2644 <desc></desc>
2645 </param>
2646 </method>
2647
2648 </interface>
2649
2650 <enum
2651 name="VirtualSystemDescriptionType"
2652 uuid="c0f8f135-3a1d-417d-afa6-b38b95a91f90"
2653 >
2654 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of
2655 a configuration value.</desc>
2656
2657 <const name="Ignore" value="1" />
2658 <const name="OS" value="2" />
2659 <const name="Name" value="3" />
2660 <const name="Product" value="4" />
2661 <const name="Vendor" value="5" />
2662 <const name="Version" value="6" />
2663 <const name="ProductUrl" value="7" />
2664 <const name="VendorUrl" value="8" />
2665 <const name="Description" value="9" />
2666 <const name="License" value="10" />
2667 <const name="Miscellaneous" value="11" />
2668 <const name="CPU" value="12" />
2669 <const name="Memory" value="13" />
2670 <const name="HardDiskControllerIDE" value="14" />
2671 <const name="HardDiskControllerSATA" value="15" />
2672 <const name="HardDiskControllerSCSI" value="16" />
2673 <const name="HardDiskControllerSAS" value="17" />
2674 <const name="HardDiskImage" value="18" />
2675 <const name="Floppy" value="19" />
2676 <const name="CDROM" value="20" />
2677 <const name="NetworkAdapter" value="21" />
2678 <const name="USBController" value="22" />
2679 <const name="SoundCard" value="23" />
2680
2681 </enum>
2682
2683 <enum
2684 name="VirtualSystemDescriptionValueType"
2685 uuid="56d9403f-3425-4118-9919-36f2a9b8c77c"
2686 >
2687 <desc>Used with <link to="IVirtualSystemDescription::getValuesByType" /> to describe the value
2688 type to fetch.</desc>
2689
2690 <const name="Reference" value="1" />
2691 <const name="Original" value="2" />
2692 <const name="Auto" value="3" />
2693 <const name="ExtraConfig" value="4" />
2694
2695 </enum>
2696
2697 <interface
2698 name="IVirtualSystemDescription" extends="$unknown"
2699 uuid="d7525e6c-531a-4c51-8e04-41235083a3d8"
2700 wsmap="managed"
2701 >
2702
2703 <desc>Represents one virtual system (machine) in an appliance. This interface is used in
2704 the <link to="IAppliance::virtualSystemDescriptions" /> array. After
2705 <link to="IAppliance::interpret" /> has been called, that array contains information
2706 about how the virtual systems described in the OVF should best be imported into
2707 VirtualBox virtual machines. See <link to="IAppliance" /> for the steps required to
2708 import an OVF into VirtualBox.
2709 </desc>
2710
2711 <attribute name="count" type="unsigned long" readonly="yes">
2712 <desc>Return the number of virtual system description entries.</desc>
2713 </attribute>
2714
2715 <method name="getDescription">
2716 <desc>Returns information about the virtual system as arrays of instruction items. In each array, the
2717 items with the same indices correspond and jointly represent an import instruction for VirtualBox.
2718
2719 The list below identifies the value sets that are possible depending on the
2720 <link to="VirtualSystemDescriptionType" /> enum value in the array item in @a aTypes[]. In each case,
2721 the array item with the same index in @a aOvfValues[] will contain the original value as contained
2722 in the OVF file (just for informational purposes), and the corresponding item in @a aVBoxValues[]
2723 will contain a suggested value to be used for VirtualBox. Depending on the description type,
2724 the @a aExtraConfigValues[] array item may also be used.
2725
2726 <ul>
2727 <li>
2728 "OS": the guest operating system type. There must be exactly one such array item on import. The
2729 corresponding item in @a aVBoxValues[] contains the suggested guest operating system for VirtualBox.
2730 This will be one of the values listed in <link to="IVirtualBox::guestOSTypes" />. The corresponding
2731 item in @a aOvfValues[] will contain a numerical value that described the operating system in the OVF.
2732 </li>
2733 <li>
2734 "Name": the name to give to the new virtual machine. There can be at most one such array item;
2735 if none is present on import, then an automatic name will be created from the operating system
2736 type. The correponding item im @a aOvfValues[] will contain the suggested virtual machine name
2737 from the OVF file, and @a aVBoxValues[] will contain a suggestion for a unique VirtualBox
2738 <link to="IMachine" /> name that does not exist yet.
2739 </li>
2740 <li>
2741 "Description": an arbitrary description.
2742 </li>
2743 <li>
2744 "License": the EULA section from the OVF, if present. It is the responsibility of the calling
2745 code to display such a license for agreement; the Main API does not enforce any such policy.
2746 </li>
2747 <li>
2748 Miscellaneous: reserved for future use.
2749 </li>
2750 <li>
2751 "CPU": the number of CPUs. There can be at most one such item, which will presently be ignored.
2752 </li>
2753 <li>
2754 "Memory": the amount of guest RAM, in bytes. There can be at most one such array item; if none
2755 is present on import, then VirtualBox will set a meaningful default based on the operating system
2756 type.
2757 </li>
2758 <li>
2759 "HardDiskControllerIDE": an IDE hard disk controller. There can be at most two such items.
2760 An optional value in @a aOvfValues[] and @a aVBoxValues[] can be "PIIX3" or "PIIX4" to specify
2761 the type of IDE controller; this corresponds to the ResourceSubType element which VirtualBox
2762 writes into the OVF.
2763 The matching item in the @a aRefs[] array will contain an integer that items of the "Harddisk"
2764 type can use to specify which hard disk controller a virtual disk should be connected to.
2765 Note that in OVF, an IDE controller has two channels, corresponding to "master" and "slave"
2766 in traditional terminology, whereas the IDE storage controller that VirtualBox supports in
2767 its virtual machines supports four channels (primary master, primary slave, secondary master,
2768 secondary slave) and thus maps to two IDE controllers in the OVF sense.
2769 </li>
2770 <li>
2771 "HardDiskControllerSATA": an SATA hard disk controller. There can be at most one such item. This
2772 has no value in @a aOvfValues[] or @a aVBoxValues[].
2773 The matching item in the @a aRefs[] array will be used as with IDE controllers (see above).
2774 </li>
2775 <li>
2776 "HardDiskControllerSCSI": a SCSI hard disk controller. There can be at most one such item.
2777 The items in @a aOvfValues[] and @a aVBoxValues[] will either be "LsiLogic", "BusLogic" or
2778 "LsiLogicSas". (Note that in OVF, the LsiLogicSas controller is treated as a SCSI controller
2779 whereas VirtualBox considers it a class of storage controllers of its own; see
2780 <link to="StorageControllerType" />).
2781 The matching item in the @a aRefs[] array will be used as with IDE controllers (see above).
2782 </li>
2783 <li>
2784 "HardDiskImage": a virtual hard disk, most probably as a reference to an image file. There can be an
2785 arbitrary number of these items, one for each virtual disk image that accompanies the OVF.
2786
2787 The array item in @a aOvfValues[] will contain the file specification from the OVF file (without
2788 a path since the image file should be in the same location as the OVF file itself), whereas the
2789 item in @a aVBoxValues[] will contain a qualified path specification to where VirtualBox uses the
2790 hard disk image. This means that on import the image will be copied and converted from the
2791 "ovf" location to the "vbox" location; on export, this will be handled the other way round.
2792
2793 The matching item in the @a aExtraConfigValues[] array must contain a string of the following
2794 format: "controller=&lt;index&gt;;channel=&lt;c&gt;"
2795 In this string, &lt;index&gt; must be an integer specifying the hard disk controller to connect
2796 the image to. That number must be the index of an array item with one of the hard disk controller
2797 types (HardDiskControllerSCSI, HardDiskControllerSATA, HardDiskControllerIDE).
2798 In addition, &lt;c&gt; must specify the channel to use on that controller. For IDE controllers,
2799 this can be 0 or 1 for master or slave, respectively. For compatibility with VirtualBox versions
2800 before 3.2, the values 2 and 3 (for secondary master and secondary slave) are also supported, but
2801 no longer exported. For SATA and SCSI controllers, the channel can range from 0-29.
2802 </li>
2803 <li>
2804 "CDROM": a virtual CD-ROM drive. The matching item in @a aExtraConfigValue[] contains the same
2805 attachment information as with "HardDiskImage" items.
2806 </li>
2807 <li>
2808 "CDROM": a virtual floppy drive. The matching item in @a aExtraConfigValue[] contains the same
2809 attachment information as with "HardDiskImage" items.
2810 </li>
2811 <li>
2812 "NetworkAdapter": a network adapter. The array item in @a aVBoxValues[] will specify the hardware
2813 for the network adapter, whereas the array item in @a aExtraConfigValues[] will have a string
2814 of the "type=&lt;X&gt;" format, where &lt;X&gt; must be either "NAT" or "Bridged".
2815 </li>
2816 <li>
2817 "USBController": a USB controller. There can be at most one such item. If and only if such an
2818 item ispresent, USB support will be enabled for the new virtual machine.
2819 </li>
2820 <li>
2821 "SoundCard": a sound card. There can be at most one such item. If and only if such an item is
2822 present, sound support will be enabled for the new virtual machine. Note that the virtual
2823 machine in VirtualBox will always be presented with the standard VirtualBox soundcard, which
2824 may be different from the virtual soundcard expected by the appliance.
2825 </li>
2826 </ul>
2827
2828 </desc>
2829
2830 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
2831 <desc></desc>
2832 </param>
2833
2834 <param name="aRefs" type="wstring" dir="out" safearray="yes">
2835 <desc></desc>
2836 </param>
2837
2838 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
2839 <desc></desc>
2840 </param>
2841
2842 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
2843 <desc></desc>
2844 </param>
2845
2846 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
2847 <desc></desc>
2848 </param>
2849
2850 </method>
2851
2852 <method name="getDescriptionByType">
2853 <desc>This is the same as <link to="#getDescription" /> except that you can specify which types
2854 should be returned.</desc>
2855
2856 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
2857 <desc></desc>
2858 </param>
2859
2860 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
2861 <desc></desc>
2862 </param>
2863
2864 <param name="aRefs" type="wstring" dir="out" safearray="yes">
2865 <desc></desc>
2866 </param>
2867
2868 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
2869 <desc></desc>
2870 </param>
2871
2872 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
2873 <desc></desc>
2874 </param>
2875
2876 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
2877 <desc></desc>
2878 </param>
2879
2880 </method>
2881
2882 <method name="getValuesByType">
2883 <desc>This is the same as <link to="#getDescriptionByType" /> except that you can specify which
2884 value types should be returned. See <link to="VirtualSystemDescriptionValueType" /> for possible
2885 values.</desc>
2886
2887 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
2888 <desc></desc>
2889 </param>
2890
2891 <param name="aWhich" type="VirtualSystemDescriptionValueType" dir="in">
2892 <desc></desc>
2893 </param>
2894
2895 <param name="aValues" type="wstring" dir="return" safearray="yes">
2896 <desc></desc>
2897 </param>
2898
2899 </method>
2900
2901 <method name="setFinalValues">
2902 <desc>
2903 This method allows the appliance's user to change the configuration for the virtual
2904 system descriptions. For each array item returned from <link to="#getDescription" />,
2905 you must pass in one boolean value and one configuration value.
2906
2907 Each item in the boolean array determines whether the particular configuration item
2908 should be enabled.
2909 You can only disable items of the types HardDiskControllerIDE, HardDiskControllerSATA,
2910 HardDiskControllerSCSI, HardDiskImage, CDROM, Floppy, NetworkAdapter, USBController
2911 and SoundCard.
2912
2913 For the "vbox" and "extra configuration" values, if you pass in the same arrays
2914 as returned in the aVBoxValues and aExtraConfigValues arrays from getDescription(),
2915 the configuration remains unchanged. Please see the documentation for getDescription()
2916 for valid configuration values for the individual array item types. If the
2917 corresponding item in the aEnabled array is @c false, the configuration value is ignored.
2918 </desc>
2919
2920 <param name="aEnabled" type="boolean" dir="in" safearray="yes">
2921 <desc></desc>
2922 </param>
2923
2924 <param name="aVBoxValues" type="wstring" dir="in" safearray="yes">
2925 <desc></desc>
2926 </param>
2927
2928 <param name="aExtraConfigValues" type="wstring" dir="in" safearray="yes">
2929 <desc></desc>
2930 </param>
2931 </method>
2932
2933 <method name="addDescription">
2934 <desc>
2935 This method adds an additional description entry to the stack of already
2936 available descriptions for this virtual system. This is handy for writing
2937 values which aren't directly supported by VirtualBox. One example would
2938 be the License type of <link to="VirtualSystemDescriptionType" />.
2939 </desc>
2940
2941 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
2942 <desc></desc>
2943 </param>
2944
2945 <param name="aVBoxValue" type="wstring" dir="in">
2946 <desc></desc>
2947 </param>
2948
2949 <param name="aExtraConfigValue" type="wstring" dir="in">
2950 <desc></desc>
2951 </param>
2952 </method>
2953 </interface>
2954
2955
2956 <!--
2957 // IMachine
2958 /////////////////////////////////////////////////////////////////////////
2959 -->
2960
2961 <interface
2962 name="IInternalMachineControl" extends="$unknown"
2963 uuid="e2da8b1a-2ad1-490e-b29e-c33a144791b6"
2964 internal="yes"
2965 wsmap="suppress"
2966 >
2967 <method name="setRemoveSavedStateFile">
2968 <desc>
2969 Updates the flag whether the saved state file is removed on a
2970 machine state change from Saved to PoweredOff.
2971 </desc>
2972 <param name="aRemove" type="boolean" dir="in"/>
2973 </method>
2974
2975 <method name="updateState">
2976 <desc>
2977 Updates the VM state.
2978 <note>
2979 This operation will also update the settings file with the correct
2980 information about the saved state file and delete this file from disk
2981 when appropriate.
2982 </note>
2983 </desc>
2984 <param name="state" type="MachineState" dir="in"/>
2985 </method>
2986
2987 <method name="getIPCId">
2988 <param name="id" type="wstring" dir="return"/>
2989 </method>
2990
2991 <method name="beginPowerUp">
2992 <desc>
2993 Tells VBoxSVC that <link to="IConsole::powerUp"/> is under ways and
2994 gives it the progress object that should be part of any pending
2995 <link to="IMachine::launchVMProcess"/> operations. The progress
2996 object may be called back to reflect an early cancelation, so some care
2997 have to be taken with respect to any cancelation callbacks. The console
2998 object will call <link to="IInternalMachineControl::endPowerUp"/>
2999 to signal the completion of the progress object.
3000 </desc>
3001 <param name="aProgress" type="IProgress" dir="in" />
3002 </method>
3003
3004 <method name="endPowerUp">
3005 <desc>
3006 Tells VBoxSVC that <link to="IConsole::powerUp"/> has completed.
3007 This method may query status information from the progress object it
3008 received in <link to="IInternalMachineControl::beginPowerUp"/> and copy
3009 it over to any in-progress <link to="IMachine::launchVMProcess"/>
3010 call in order to complete that progress object.
3011 </desc>
3012 <param name="result" type="long" dir="in"/>
3013 </method>
3014
3015 <method name="runUSBDeviceFilters">
3016 <desc>
3017 Asks the server to run USB devices filters of the associated
3018 machine against the given USB device and tell if there is
3019 a match.
3020 <note>
3021 Intended to be used only for remote USB devices. Local
3022 ones don't require to call this method (this is done
3023 implicitly by the Host and USBProxyService).
3024 </note>
3025 </desc>
3026 <param name="device" type="IUSBDevice" dir="in"/>
3027 <param name="matched" type="boolean" dir="out"/>
3028 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
3029 </method>
3030
3031 <method name="captureUSBDevice">
3032 <desc>
3033 Requests a capture of the given host USB device.
3034 When the request is completed, the VM process will
3035 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3036 notification.
3037 </desc>
3038 <param name="id" type="uuid" mod="string" dir="in"/>
3039 </method>
3040
3041 <method name="detachUSBDevice">
3042 <desc>
3043 Notification that a VM is going to detach (@a done = @c false) or has
3044 already detached (@a done = @c true) the given USB device.
3045 When the @a done = @c true request is completed, the VM process will
3046 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
3047 notification.
3048 <note>
3049 In the @a done = @c true case, the server must run its own filters
3050 and filters of all VMs but this one on the detached device
3051 as if it were just attached to the host computer.
3052 </note>
3053 </desc>
3054 <param name="id" type="uuid" mod="string" dir="in"/>
3055 <param name="done" type="boolean" dir="in"/>
3056 </method>
3057
3058 <method name="autoCaptureUSBDevices">
3059 <desc>
3060 Requests a capture all matching USB devices attached to the host.
3061 When the request is completed, the VM process will
3062 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3063 notification per every captured device.
3064 </desc>
3065 </method>
3066
3067 <method name="detachAllUSBDevices">
3068 <desc>
3069 Notification that a VM that is being powered down. The done
3070 parameter indicates whether which stage of the power down
3071 we're at. When @a done = @c false the VM is announcing its
3072 intentions, while when @a done = @c true the VM is reporting
3073 what it has done.
3074 <note>
3075 In the @a done = @c true case, the server must run its own filters
3076 and filters of all VMs but this one on all detach devices as
3077 if they were just attached to the host computer.
3078 </note>
3079 </desc>
3080 <param name="done" type="boolean" dir="in"/>
3081 </method>
3082
3083 <method name="onSessionEnd">
3084 <desc>
3085 Triggered by the given session object when the session is about
3086 to close normally.
3087 </desc>
3088 <param name="session" type="ISession" dir="in">
3089 <desc>Session that is being closed</desc>
3090 </param>
3091 <param name="progress" type="IProgress" dir="return">
3092 <desc>
3093 Used to wait until the corresponding machine is actually
3094 dissociated from the given session on the server.
3095 Returned only when this session is a direct one.
3096 </desc>
3097 </param>
3098 </method>
3099
3100 <method name="beginSavingState">
3101 <desc>
3102 Called by the VM process to inform the server it wants to
3103 save the current state and stop the VM execution.
3104 </desc>
3105 <param name="progress" type="IProgress" dir="in">
3106 <desc>
3107 Progress object created by the VM process to wait until
3108 the state is saved.
3109 </desc>
3110 </param>
3111 <param name="stateFilePath" type="wstring" dir="out">
3112 <desc>
3113 File path the VM process must save the execution state to.
3114 </desc>
3115 </param>
3116 </method>
3117
3118 <method name="endSavingState">
3119 <desc>
3120 Called by the VM process to inform the server that saving
3121 the state previously requested by #beginSavingState is either
3122 successfully finished or there was a failure.
3123
3124 <result name="VBOX_E_FILE_ERROR">
3125 Settings file not accessible.
3126 </result>
3127 <result name="VBOX_E_XML_ERROR">
3128 Could not parse the settings file.
3129 </result>
3130
3131 </desc>
3132
3133 <param name="success" type="boolean" dir="in">
3134 <desc>@c true to indicate success and @c false otherwise.
3135 </desc>
3136 </param>
3137 </method>
3138
3139 <method name="adoptSavedState">
3140 <desc>
3141 Gets called by IConsole::adoptSavedState.
3142 <result name="VBOX_E_FILE_ERROR">
3143 Invalid saved state file path.
3144 </result>
3145 </desc>
3146 <param name="savedStateFile" type="wstring" dir="in">
3147 <desc>Path to the saved state file to adopt.</desc>
3148 </param>
3149 </method>
3150
3151 <method name="beginTakingSnapshot">
3152 <desc>
3153 Called from the VM process to request from the server to perform the
3154 server-side actions of creating a snapshot (creating differencing images
3155 and the snapshot object).
3156
3157 <result name="VBOX_E_FILE_ERROR">
3158 Settings file not accessible.
3159 </result>
3160 <result name="VBOX_E_XML_ERROR">
3161 Could not parse the settings file.
3162 </result>
3163 </desc>
3164 <param name="initiator" type="IConsole" dir="in">
3165 <desc>The console object that initiated this call.</desc>
3166 </param>
3167 <param name="name" type="wstring" dir="in">
3168 <desc>Snapshot name.</desc>
3169 </param>
3170 <param name="description" type="wstring" dir="in">
3171 <desc>Snapshot description.</desc>
3172 </param>
3173 <param name="consoleProgress" type="IProgress" dir="in">
3174 <desc>
3175 Progress object created by the VM process tracking the
3176 snapshot's progress. This has the following sub-operations:
3177 <ul>
3178 <li>setting up (weight 1);</li>
3179 <li>one for each medium attachment that needs a differencing image (weight 1 each);</li>
3180 <li>another one to copy the VM state (if offline with saved state, weight is VM memory size in MB);</li>
3181 <li>another one to save the VM state (if online, weight is VM memory size in MB);</li>
3182 <li>finishing up (weight 1)</li>
3183 </ul>
3184 </desc>
3185 </param>
3186 <param name="fTakingSnapshotOnline" type="boolean" dir="in">
3187 <desc>
3188 Whether this is an online snapshot (i.e. the machine is running).
3189 </desc>
3190 </param>
3191 <param name="stateFilePath" type="wstring" dir="out">
3192 <desc>
3193 File path the VM process must save the execution state to.
3194 </desc>
3195 </param>
3196 </method>
3197
3198 <method name="endTakingSnapshot">
3199 <desc>
3200 Called by the VM process to inform the server that the snapshot
3201 previously requested by #beginTakingSnapshot is either
3202 successfully taken or there was a failure.
3203 </desc>
3204
3205 <param name="success" type="boolean" dir="in">
3206 <desc>@c true to indicate success and @c false otherwise</desc>
3207 </param>
3208 </method>
3209
3210 <method name="deleteSnapshot">
3211 <desc>
3212 Gets called by IConsole::deleteSnapshot.
3213 <result name="VBOX_E_INVALID_OBJECT_STATE">
3214 Snapshot has more than one child snapshot.
3215 </result>
3216 </desc>
3217 <param name="initiator" type="IConsole" dir="in">
3218 <desc>The console object that initiated this call.</desc>
3219 </param>
3220 <param name="id" type="uuid" mod="string" dir="in">
3221 <desc>UUID of the snapshot to delete.</desc>
3222 </param>
3223 <param name="machineState" type="MachineState" dir="out">
3224 <desc>New machine state after this operation is started.</desc>
3225 </param>
3226 <param name="progress" type="IProgress" dir="return">
3227 <desc>Progress object to track the operation completion.</desc>
3228 </param>
3229 </method>
3230
3231 <method name="finishOnlineMergeMedium">
3232 <desc>
3233 Gets called by IConsole::onlineMergeMedium.
3234 </desc>
3235 <param name="mediumAttachment" type="IMediumAttachment" dir="in">
3236 <desc>The medium attachment which needs to be cleaned up.</desc>
3237 </param>
3238 <param name="source" type="IMedium" dir="in">
3239 <desc>Merge source medium.</desc>
3240 </param>
3241 <param name="target" type="IMedium" dir="in">
3242 <desc>Merge target medium.</desc>
3243 </param>
3244 <param name="mergeForward" type="boolean" dir="in">
3245 <desc>Merge direction.</desc>
3246 </param>
3247 <param name="parentForTarget" type="IMedium" dir="in">
3248 <desc>For forward merges: new parent for target medium.</desc>
3249 </param>
3250 <param name="childrenToReparent" type="IMedium" safearray="yes" dir="in">
3251 <desc>For backward merges: list of media which need their parent UUID
3252 updated.</desc>
3253 </param>
3254 </method>
3255
3256 <method name="restoreSnapshot">
3257 <desc>
3258 Gets called by IConsole::RestoreSnapshot.
3259 </desc>
3260 <param name="initiator" type="IConsole" dir="in">
3261 <desc>The console object that initiated this call.</desc>
3262 </param>
3263 <param name="snapshot" type="ISnapshot" dir="in">
3264 <desc>The snapshot to restore the VM state from.</desc>
3265 </param>
3266 <param name="machineState" type="MachineState" dir="out">
3267 <desc>New machine state after this operation is started.</desc>
3268 </param>
3269 <param name="progress" type="IProgress" dir="return">
3270 <desc>Progress object to track the operation completion.</desc>
3271 </param>
3272 </method>
3273
3274 <method name="pullGuestProperties">
3275 <desc>
3276 Get the list of the guest properties matching a set of patterns along
3277 with their values, time stamps and flags and give responsibility for
3278 managing properties to the console.
3279 </desc>
3280 <param name="name" type="wstring" dir="out" safearray="yes">
3281 <desc>
3282 The names of the properties returned.
3283 </desc>
3284 </param>
3285 <param name="value" type="wstring" dir="out" safearray="yes">
3286 <desc>
3287 The values of the properties returned. The array entries match the
3288 corresponding entries in the @a name array.
3289 </desc>
3290 </param>
3291 <param name="timestamp" type="long long" dir="out" safearray="yes">
3292 <desc>
3293 The time stamps of the properties returned. The array entries match
3294 the corresponding entries in the @a name array.
3295 </desc>
3296 </param>
3297 <param name="flags" type="wstring" dir="out" safearray="yes">
3298 <desc>
3299 The flags of the properties returned. The array entries match the
3300 corresponding entries in the @a name array.
3301 </desc>
3302 </param>
3303 </method>
3304
3305 <method name="pushGuestProperty">
3306 <desc>
3307 Update a single guest property in IMachine.
3308 </desc>
3309 <param name="name" type="wstring" dir="in">
3310 <desc>
3311 The name of the property to be updated.
3312 </desc>
3313 </param>
3314 <param name="value" type="wstring" dir="in">
3315 <desc>
3316 The value of the property.
3317 </desc>
3318 </param>
3319 <param name="timestamp" type="long long" dir="in">
3320 <desc>
3321 The timestamp of the property.
3322 </desc>
3323 </param>
3324 <param name="flags" type="wstring" dir="in">
3325 <desc>
3326 The flags of the property.
3327 </desc>
3328 </param>
3329 </method>
3330
3331 <method name="lockMedia">
3332 <desc>
3333 Locks all media attached to the machine for writing and parents of
3334 attached differencing media (if any) for reading. This operation is
3335 atomic so that if it fails no media is actually locked.
3336
3337 This method is intended to be called when the machine is in Starting or
3338 Restoring state. The locked media will be automatically unlocked when
3339 the machine is powered off or crashed.
3340 </desc>
3341 </method>
3342 <method name="unlockMedia">
3343 <desc>
3344 Unlocks all media previously locked using
3345 <link to="IInternalMachineControl::lockMedia"/>.
3346
3347 This method is intended to be used with teleportation so that it is
3348 possible to teleport between processes on the same machine.
3349 </desc>
3350 </method>
3351 </interface>
3352
3353 <interface
3354 name="IBIOSSettings" extends="$unknown"
3355 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
3356 wsmap="managed"
3357 >
3358 <desc>
3359 The IBIOSSettings interface represents BIOS settings of the virtual
3360 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
3361 </desc>
3362 <attribute name="logoFadeIn" type="boolean">
3363 <desc>Fade in flag for BIOS logo animation.</desc>
3364 </attribute>
3365
3366 <attribute name="logoFadeOut" type="boolean">
3367 <desc>Fade out flag for BIOS logo animation.</desc>
3368 </attribute>
3369
3370 <attribute name="logoDisplayTime" type="unsigned long">
3371 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
3372 </attribute>
3373
3374 <attribute name="logoImagePath" type="wstring">
3375 <desc>
3376 Local file system path for external BIOS splash image. Empty string
3377 means the default image is shown on boot.
3378 </desc>
3379 </attribute>
3380
3381 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
3382 <desc>Mode of the BIOS boot device menu.</desc>
3383 </attribute>
3384
3385 <attribute name="ACPIEnabled" type="boolean">
3386 <desc>ACPI support flag.</desc>
3387 </attribute>
3388
3389 <attribute name="IOAPICEnabled" type="boolean">
3390 <desc>
3391 IO APIC support flag. If set, VirtualBox will provide an IO APIC
3392 and support IRQs above 15.
3393 </desc>
3394 </attribute>
3395
3396 <attribute name="timeOffset" type="long long">
3397 <desc>
3398 Offset in milliseconds from the host system time. This allows for
3399 guests running with a different system date/time than the host.
3400 It is equivalent to setting the system date/time in the BIOS except
3401 it is not an absolute value but a relative one. Guest Additions
3402 time synchronization honors this offset.
3403 </desc>
3404 </attribute>
3405
3406 <attribute name="PXEDebugEnabled" type="boolean">
3407 <desc>
3408 PXE debug logging flag. If set, VirtualBox will write extensive
3409 PXE trace information to the release log.
3410 </desc>
3411 </attribute>
3412
3413 </interface>
3414
3415 <enum name="CleanupMode"
3416 uuid="67897c50-7cca-47a9-83f6-ce8fd8eb5441">
3417 <desc>Cleanup mode, used with <link to="IMachine::unregister" />.
3418 </desc>
3419 <const name="UnregisterOnly" value="1">
3420 <desc>Unregister only the machine, but neither delete snapshots nor detach media.</desc>
3421 </const>
3422 <const name="DetachAllReturnNone" value="2">
3423 <desc>Delete all snapshots and detach all media but return none; this will keep all media registered.</desc>
3424 </const>
3425 <const name="DetachAllReturnHardDisksOnly" value="3">
3426 <desc>Delete all snapshots, detach all media and return hard disks for closing, but not removeable media.</desc>
3427 </const>
3428 <const name="Full" value="4">
3429 <desc>Delete all snapshots, detach all media and return all media for closing.</desc>
3430 </const>
3431 </enum>
3432
3433 <interface
3434 name="IMachine" extends="$unknown"
3435 uuid="5c91359b-5bdb-4518-9bd1-5f2c50a3c129"
3436 wsmap="managed"
3437 >
3438 <desc>
3439 The IMachine interface represents a virtual machine, or guest, created
3440 in VirtualBox.
3441
3442 This interface is used in two contexts. First of all, a collection of
3443 objects implementing this interface is stored in the
3444 <link to="IVirtualBox::machines"/> attribute which lists all the virtual
3445 machines that are currently registered with this VirtualBox
3446 installation. Also, once a session has been opened for the given virtual
3447 machine (e.g. the virtual machine is running), the machine object
3448 associated with the open session can be queried from the session object;
3449 see <link to="ISession"/> for details.
3450
3451 The main role of this interface is to expose the settings of the virtual
3452 machine and provide methods to change various aspects of the virtual
3453 machine's configuration. For machine objects stored in the
3454 <link to="IVirtualBox::machines"/> collection, all attributes are
3455 read-only unless explicitly stated otherwise in individual attribute
3456 and method descriptions.
3457
3458 In order to change a machine setting, a session for this machine must be
3459 opened using one of the <link to="IMachine::lockMachine" /> or
3460 <link to="IMachine::launchVMProcess"/> methods. After the
3461 machine has been successfully locked for a session, a mutable machine object
3462 needs to be queried from the session object and then the desired settings
3463 changes can be applied to the returned object using IMachine attributes and
3464 methods. See the <link to="ISession"/> interface description for more
3465 information about sessions.
3466
3467 Note that IMachine does not provide methods to control virtual machine
3468 execution (such as start the machine, or power it down) -- these methods
3469 are grouped in a separate interface called <link to="IConsole" />.
3470
3471 <see>ISession, IConsole</see>
3472 </desc>
3473
3474 <attribute name="parent" type="IVirtualBox" readonly="yes">
3475 <desc>Associated parent object.</desc>
3476 </attribute>
3477
3478 <attribute name="accessible" type="boolean" readonly="yes">
3479 <desc>
3480 Whether this virtual machine is currently accessible or not.
3481
3482 A machine is always deemed accessible unless it is registered <i>and</i>
3483 its settings file cannot be read or parsed (either because the file itself
3484 is unavailable or has invalid XML contents).
3485
3486 Every time this property is read, the accessibility state of
3487 this machine is re-evaluated. If the returned value is @c false,
3488 the <link to="#accessError"/> property may be used to get the
3489 detailed error information describing the reason of
3490 inaccessibility, including XML error messages.
3491
3492 When the machine is inaccessible, only the following properties
3493 can be used on it:
3494 <ul>
3495 <li><link to="#parent"/></li>
3496 <li><link to="#id"/></li>
3497 <li><link to="#settingsFilePath"/></li>
3498 <li><link to="#accessible"/></li>
3499 <li><link to="#accessError"/></li>
3500 </ul>
3501
3502 An attempt to access any other property or method will return
3503 an error.
3504
3505 The only possible action you can perform on an inaccessible
3506 machine is to unregister it using the
3507 <link to="IMachine::unregister"/> call (or, to check
3508 for the accessibility state once more by querying this
3509 property).
3510
3511 <note>
3512 In the current implementation, once this property returns
3513 @c true, the machine will never become inaccessible
3514 later, even if its settings file cannot be successfully
3515 read/written any more (at least, until the VirtualBox
3516 server is restarted). This limitation may be removed in
3517 future releases.
3518 </note>
3519 </desc>
3520 </attribute>
3521
3522 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
3523 <desc>
3524 Error information describing the reason of machine
3525 inaccessibility.
3526
3527 Reading this property is only valid after the last call to
3528 <link to="#accessible"/> returned @c false (i.e. the
3529 machine is currently unaccessible). Otherwise, a @c null
3530 IVirtualBoxErrorInfo object will be returned.
3531 </desc>
3532 </attribute>
3533
3534 <attribute name="name" type="wstring">
3535 <desc>
3536 Name of the virtual machine.
3537
3538 Besides being used for human-readable identification purposes
3539 everywhere in VirtualBox, the virtual machine name is also used
3540 as a name of the machine's settings file and as a name of the
3541 subdirectory this settings file resides in. Thus, every time you
3542 change the value of this property, the settings file will be
3543 renamed once you call <link to="#saveSettings"/> to confirm the
3544 change. The containing subdirectory will be also renamed, but
3545 only if it has exactly the same name as the settings file
3546 itself prior to changing this property (for backward compatibility
3547 with previous API releases). The above implies the following
3548 limitations:
3549 <ul>
3550 <li>The machine name cannot be empty.</li>
3551 <li>The machine name can contain only characters that are valid
3552 file name characters according to the rules of the file
3553 system used to store VirtualBox configuration.</li>
3554 <li>You cannot have two or more machines with the same name
3555 if they use the same subdirectory for storing the machine
3556 settings files.</li>
3557 <li>You cannot change the name of the machine if it is running,
3558 or if any file in the directory containing the settings file
3559 is being used by another running machine or by any other
3560 process in the host operating system at a time when
3561 <link to="#saveSettings"/> is called.
3562 </li>
3563 </ul>
3564 If any of the above limitations are hit, <link to="#saveSettings"/>
3565 will return an appropriate error message explaining the exact
3566 reason and the changes you made to this machine will not be saved.
3567 </desc>
3568 </attribute>
3569
3570 <attribute name="description" type="wstring">
3571 <desc>
3572 Description of the virtual machine.
3573
3574 The description attribute can contain any text and is
3575 typically used to describe the hardware and software
3576 configuration of the virtual machine in detail (i.e. network
3577 settings, versions of the installed software and so on).
3578 </desc>
3579 </attribute>
3580
3581 <attribute name="id" type="uuid" mod="string" readonly="yes">
3582 <desc>UUID of the virtual machine.</desc>
3583 </attribute>
3584
3585 <attribute name="OSTypeId" type="wstring">
3586 <desc>
3587 User-defined identifier of the Guest OS type.
3588 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
3589 an IGuestOSType object representing details about the given
3590 Guest OS type.
3591 <note>
3592 This value may differ from the value returned by
3593 <link to="IGuest::OSTypeId"/> if Guest Additions are
3594 installed to the guest OS.
3595 </note>
3596 </desc>
3597 </attribute>
3598
3599 <attribute name="HardwareVersion" type="wstring">
3600 <desc>Hardware version identifier. Internal use only for now.</desc>
3601 </attribute>
3602
3603 <attribute name="hardwareUUID" type="uuid" mod="string">
3604 <desc>
3605 The UUID presented to the guest via memory tables, hardware and guest
3606 properties. For most VMs this is the same as the @a id, but for VMs
3607 which have been cloned or teleported it may be the same as the source
3608 VM. This latter is because the guest shouldn't notice that it was
3609 cloned or teleported.
3610 </desc>
3611 </attribute>
3612
3613 <attribute name="CPUCount" type="unsigned long">
3614 <desc>Number of virtual CPUs in the VM.</desc>
3615 </attribute>
3616
3617 <attribute name="CPUHotPlugEnabled" type="boolean">
3618 <desc>
3619 This setting determines whether VirtualBox allows CPU
3620 hotplugging for this machine.</desc>
3621 </attribute>
3622
3623 <attribute name="CPUExecutionCap" type="unsigned long">
3624 <desc>
3625 Means to limit the number of CPU cycles a guest can use. The unit
3626 is percentage of host CPU cycles per second. The valid range
3627 is 1 - 100. 100 (the default) implies no limit.
3628 </desc>
3629 </attribute>
3630
3631 <attribute name="memorySize" type="unsigned long">
3632 <desc>System memory size in megabytes.</desc>
3633 </attribute>
3634
3635 <attribute name="memoryBalloonSize" type="unsigned long">
3636 <desc>Memory balloon size in megabytes.</desc>
3637 </attribute>
3638
3639 <attribute name="PageFusionEnabled" type="boolean">
3640 <desc>
3641 This setting determines whether VirtualBox allows page
3642 fusion for this machine (64 bits host only).
3643 </desc>
3644 </attribute>
3645
3646 <attribute name="VRAMSize" type="unsigned long">
3647 <desc>Video memory size in megabytes.</desc>
3648 </attribute>
3649
3650 <attribute name="accelerate3DEnabled" type="boolean" default="false">
3651 <desc>
3652 This setting determines whether VirtualBox allows this machine to make
3653 use of the 3D graphics support available on the host.</desc>
3654 </attribute>
3655
3656 <attribute name="accelerate2DVideoEnabled" type="boolean" default="false">
3657 <desc>
3658 This setting determines whether VirtualBox allows this machine to make
3659 use of the 2D video acceleration support available on the host.</desc>
3660 </attribute>
3661
3662 <attribute name="monitorCount" type="unsigned long">
3663 <desc>
3664 Number of virtual monitors.
3665 <note>
3666 Only effective on Windows XP and later guests with
3667 Guest Additions installed.
3668 </note>
3669 </desc>
3670 </attribute>
3671
3672 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
3673 <desc>Object containing all BIOS settings.</desc>
3674 </attribute>
3675
3676 <attribute name="firmwareType" type="FirmwareType">
3677 <desc>Type of firmware (such as legacy BIOS or EFI), used for initial
3678 bootstrap in this VM.</desc>
3679 </attribute>
3680
3681 <attribute name="pointingHidType" type="PointingHidType">
3682 <desc>Type of pointing HID (such as mouse or tablet) used in this VM.
3683 The default is typically "PS2Mouse" but can vary depending on the
3684 requirements of the guest operating system.</desc>
3685 </attribute>
3686
3687 <attribute name="keyboardHidType" type="KeyboardHidType">
3688 <desc>Type of keyboard HID used in this VM.
3689 The default is typically "PS2Keyboard" but can vary depending on the
3690 requirements of the guest operating system.</desc>
3691 </attribute>
3692
3693 <attribute name="hpetEnabled" type="boolean">
3694 <desc>This attribute controls if High Precision Event Timer (HPET) is
3695 enabled in this VM. Use this property if you want to provide guests
3696 with additional time source, or if guest requires HPET to function correctly.
3697 Default is false.</desc>
3698 </attribute>
3699
3700 <attribute name="chipsetType" type="ChipsetType">
3701 <desc>Chipset type used in this VM.</desc>
3702 </attribute>
3703
3704 <attribute name="snapshotFolder" type="wstring">
3705 <desc>
3706 Full path to the directory used to store snapshot data
3707 (differencing media and saved state files) of this machine.
3708
3709 The initial value of this property is
3710 <tt>&lt;</tt><link to="#settingsFilePath">
3711 path_to_settings_file</link><tt>&gt;/&lt;</tt>
3712 <link to="#id">machine_uuid</link>
3713 <tt>&gt;</tt>.
3714
3715 Currently, it is an error to try to change this property on
3716 a machine that has snapshots (because this would require to
3717 move possibly large files to a different location).
3718 A separate method will be available for this purpose later.
3719
3720 <note>
3721 Setting this property to @c null or to an empty string will restore
3722 the initial value.
3723 </note>
3724 <note>
3725 When setting this property, the specified path can be
3726 absolute (full path) or relative to the directory where the
3727 <link to="#settingsFilePath">machine settings file</link>
3728 is located. When reading this property, a full path is
3729 always returned.
3730 </note>
3731 <note>
3732 The specified path may not exist, it will be created
3733 when necessary.
3734 </note>
3735 </desc>
3736 </attribute>
3737
3738 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
3739 <desc>VRDP server object.</desc>
3740 </attribute>
3741
3742 <attribute name="mediumAttachments" type="IMediumAttachment" readonly="yes" safearray="yes">
3743 <desc>Array of media attached to this machine.</desc>
3744 </attribute>
3745
3746 <attribute name="USBController" type="IUSBController" readonly="yes">
3747 <desc>
3748 Associated USB controller object.
3749
3750 <note>
3751 If USB functionality is not available in the given edition of
3752 VirtualBox, this method will set the result code to @c E_NOTIMPL.
3753 </note>
3754 </desc>
3755 </attribute>
3756
3757 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
3758 <desc>Associated audio adapter, always present.</desc>
3759 </attribute>
3760
3761 <attribute name="storageControllers" type="IStorageController" readonly="yes" safearray="yes">
3762 <desc>Array of storage controllers attached to this machine.</desc>
3763 </attribute>
3764
3765 <attribute name="settingsFilePath" type="wstring" readonly="yes">
3766 <desc>
3767 Full name of the file containing machine settings data.
3768 </desc>
3769 </attribute>
3770
3771 <attribute name="settingsModified" type="boolean" readonly="yes">
3772 <desc>
3773 Whether the settings of this machine have been modified
3774 (but neither yet saved nor discarded).
3775 <note>
3776 Reading this property is only valid on instances returned
3777 by <link to="ISession::machine"/> and on new machines
3778 created by <link to="IVirtualBox::createMachine"/> or opened
3779 by <link to="IVirtualBox::openMachine"/> but not
3780 yet registered, or on unregistered machines after calling
3781 <link to="IMachine::unregister"/>. For all other
3782 cases, the settings can never be modified.
3783 </note>
3784 <note>
3785 For newly created unregistered machines, the value of this
3786 property is always @c true until <link to="#saveSettings"/>
3787 is called (no matter if any machine settings have been
3788 changed after the creation or not). For opened machines
3789 the value is set to @c false (and then follows to normal rules).
3790 </note>
3791 </desc>
3792 </attribute>
3793
3794 <attribute name="sessionState" type="SessionState" readonly="yes">
3795 <desc>Current session state for this machine.</desc>
3796 </attribute>
3797
3798 <attribute name="sessionType" type="wstring" readonly="yes">
3799 <desc>
3800 Type of the session. If <link to="#sessionState"/> is
3801 Spawning or Locked, this attribute contains the
3802 same value as passed to the
3803 <link to="IMachine::launchVMProcess"/> method in the
3804 @a type parameter. If the session was used with
3805 <link to="IMachine::lockMachine" />, or if
3806 <link to="#sessionState"/> is SessionClosed, the value of this
3807 attribute is an empty string.
3808 </desc>
3809 </attribute>
3810
3811 <attribute name="sessionPid" type="unsigned long" readonly="yes">
3812 <desc>
3813 Identifier of the session process. This attribute contains the
3814 platform-dependent identifier of the process whose session was
3815 used with <link to="IMachine::lockMachine" /> call. The returned
3816 value is only valid if <link to="#sessionState"/> is Locked or
3817 Unlocking by the time this property is read.
3818 </desc>
3819 </attribute>
3820
3821 <attribute name="state" type="MachineState" readonly="yes">
3822 <desc>Current execution state of this machine.</desc>
3823 </attribute>
3824
3825 <attribute name="lastStateChange" type="long long" readonly="yes">
3826 <desc>
3827 Time stamp of the last execution state change,
3828 in milliseconds since 1970-01-01 UTC.
3829 </desc>
3830 </attribute>
3831
3832 <attribute name="stateFilePath" type="wstring" readonly="yes">
3833 <desc>
3834 Full path to the file that stores the execution state of
3835 the machine when it is in the <link to="MachineState_Saved"/> state.
3836 <note>
3837 When the machine is not in the Saved state, this attribute is
3838 an empty string.
3839 </note>
3840 </desc>
3841 </attribute>
3842
3843 <attribute name="logFolder" type="wstring" readonly="yes">
3844 <desc>
3845 Full path to the folder that stores a set of rotated log files
3846 recorded during machine execution. The most recent log file is
3847 named <tt>VBox.log</tt>, the previous log file is
3848 named <tt>VBox.log.1</tt> and so on (up to <tt>VBox.log.3</tt>
3849 in the current version).
3850 </desc>
3851 </attribute>
3852
3853 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
3854 <desc>
3855 Current snapshot of this machine. This is @c null if the machine
3856 currently has no snapshots. If it is not @c null, then it was
3857 set by one of <link to="IConsole::takeSnapshot" />,
3858 <link to="IConsole::deleteSnapshot" />
3859 or <link to="IConsole::restoreSnapshot" />, depending on which
3860 was called last. See <link to="ISnapshot"/> for details.
3861 </desc>
3862 </attribute>
3863
3864 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
3865 <desc>
3866 Number of snapshots taken on this machine. Zero means the
3867 machine doesn't have any snapshots.
3868 </desc>
3869 </attribute>
3870
3871 <attribute name="currentStateModified" type="boolean" readonly="yes">
3872 <desc>
3873 Returns @c true if the current state of the machine is not
3874 identical to the state stored in the current snapshot.
3875
3876 The current state is identical to the current snapshot only
3877 directly after one of the following calls are made:
3878
3879 <ul>
3880 <li><link to="IConsole::restoreSnapshot"/>
3881 </li>
3882 <li><link to="IConsole::takeSnapshot"/> (issued on a
3883 "powered off" or "saved" machine, for which
3884 <link to="#settingsModified"/> returns @c false)
3885 </li>
3886 <li><link to="IMachine::setCurrentSnapshot"/>
3887 </li>
3888 </ul>
3889
3890 The current state remains identical until one of the following
3891 happens:
3892 <ul>
3893 <li>settings of the machine are changed</li>
3894 <li>the saved state is deleted</li>
3895 <li>the current snapshot is deleted</li>
3896 <li>an attempt to execute the machine is made</li>
3897 </ul>
3898
3899 <note>
3900 For machines that don't have snapshots, this property is
3901 always @c false.
3902 </note>
3903 </desc>
3904 </attribute>
3905
3906 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
3907 <desc>
3908 Collection of shared folders for this machine (permanent shared
3909 folders). These folders are shared automatically at machine startup
3910 and available only to the guest OS installed within this machine.
3911
3912 New shared folders are added to the collection using
3913 <link to="#createSharedFolder"/>. Existing shared folders can be
3914 removed using <link to="#removeSharedFolder"/>.
3915 </desc>
3916 </attribute>
3917
3918 <attribute name="clipboardMode" type="ClipboardMode">
3919 <desc>
3920 Synchronization mode between the host OS clipboard
3921 and the guest OS clipboard.
3922 </desc>
3923 </attribute>
3924
3925 <attribute name="guestPropertyNotificationPatterns" type="wstring">
3926 <desc>
3927 A comma-separated list of simple glob patterns. Changes to guest
3928 properties whose name matches one of the patterns will generate an
3929 <link to="IGuestPropertyChangedEvent"/> signal.
3930 </desc>
3931 </attribute>
3932
3933 <attribute name="teleporterEnabled" type="boolean">
3934 <desc>
3935 When set to @a true, the virtual machine becomes a target teleporter
3936 the next time it is powered on. This can only set to @a true when the
3937 VM is in the @a PoweredOff or @a Aborted state.
3938
3939 <!-- This property is automatically set to @a false when the VM is powered
3940 on. (bird: This doesn't work yet ) -->
3941 </desc>
3942 </attribute>
3943
3944 <attribute name="teleporterPort" type="unsigned long">
3945 <desc>
3946 The TCP port the target teleporter will listen for incoming
3947 teleportations on.
3948
3949 0 means the port is automatically selected upon power on. The actual
3950 value can be read from this property while the machine is waiting for
3951 incoming teleportations.
3952 </desc>
3953 </attribute>
3954
3955 <attribute name="teleporterAddress" type="wstring">
3956 <desc>
3957 The address the target teleporter will listen on. If set to an empty
3958 string, it will listen on all addresses.
3959 </desc>
3960 </attribute>
3961
3962 <attribute name="teleporterPassword" type="wstring">
3963 <desc>
3964 The password to check for on the target teleporter. This is just a
3965 very basic measure to prevent simple hacks and operators accidentally
3966 beaming a virtual machine to the wrong place.
3967 </desc>
3968 </attribute>
3969
3970 <attribute name="faultToleranceState" type="FaultToleranceState">
3971 <desc>
3972 Fault tolerance state; disabled, source or target.
3973 This property can be changed at any time. If you change it for a running
3974 VM, then the fault tolerance address and port must be set beforehand.
3975 </desc>
3976 </attribute>
3977
3978 <attribute name="faultTolerancePort" type="unsigned long">
3979 <desc>
3980 The TCP port the fault tolerance source or target will use for
3981 communication.
3982 </desc>
3983 </attribute>
3984
3985 <attribute name="faultToleranceAddress" type="wstring">
3986 <desc>
3987 The address the fault tolerance source or target.
3988 </desc>
3989 </attribute>
3990
3991 <attribute name="faultTolerancePassword" type="wstring">
3992 <desc>
3993 The password to check for on the standby VM. This is just a
3994 very basic measure to prevent simple hacks and operators accidentally
3995 choosing the wrong standby VM.
3996 </desc>
3997 </attribute>
3998
3999 <attribute name="faultToleranceSyncInterval" type="unsigned long">
4000 <desc>
4001 The interval in ms used for syncing the state between source and target.
4002 </desc>
4003 </attribute>
4004
4005 <attribute name="RTCUseUTC" type="boolean">
4006 <desc>
4007 When set to @a true, the RTC device of the virtual machine will run
4008 in UTC time, otherwise in local time. Especially Unix guests prefer
4009 the time in UTC.
4010 </desc>
4011 </attribute>
4012
4013 <attribute name="ioCacheEnabled" type="boolean">
4014 <desc>
4015 When set to @a true, the builtin I/O cache of the virtual machine
4016 will be enabled.
4017 </desc>
4018 </attribute>
4019
4020 <attribute name="ioCacheSize" type="unsigned long">
4021 <desc>
4022 Maximum size of the I/O cache in MB.
4023 </desc>
4024 </attribute>
4025
4026 <method name="lockMachine">
4027 <desc>
4028 Locks the machine for the given session to enable the caller
4029 to make changes to the machine or start the VM or control
4030 VM execution.
4031
4032 There are two ways to lock a machine for such uses:
4033
4034 <ul>
4035 <li>If you want to make changes to the machine settings,
4036 you must obtain an exclusive write lock on the machine
4037 by setting @a lockType to @c Write.
4038
4039 This will only succeed if no other process has locked
4040 the machine to prevent conflicting changes. Only after
4041 an exclusive write lock has been obtained using this method, one
4042 can change all VM settings or execute the VM in the process
4043 space of the session object. (Note that the latter is only of
4044 interest if you actually want to write a new front-end for
4045 virtual machines; but this API gets called internally by
4046 the existing front-ends such as VBoxHeadless and the VirtualBox
4047 GUI to acquire a write lock on the machine that they are running.)
4048
4049 On success, write-locking the machine for a session creates
4050 a second copy of the IMachine object. It is this second object
4051 upon which changes can be made; in VirtualBox terminology, the
4052 second copy is "mutable". It is only this second, mutable machine
4053 object upon which you can call methods that change the
4054 machine state. After having called this method, you can
4055 obtain this second, mutable machine object using the
4056 <link to="ISession::machine" /> attribute.
4057 </li>
4058 <li>If you only want to check the machine state or control
4059 machine execution without actually changing machine
4060 settings (e.g. to get access to VM statistics or take
4061 a snapshot or save the machine state), then set the
4062 @a lockType argument to @c Shared.
4063
4064 If no other session has obtained a lock, you will obtain an
4065 exclusive write lock as described above. However, if another
4066 session has already obtained such a lock, then a link to that
4067 existing session will be established which allows you
4068 to control that existing session.
4069
4070 To find out which type of lock was obtained, you can
4071 inspect <link to="ISession::type" />, which will have been
4072 set to either @c WriteLock or @c Shared.
4073 </li>
4074 </ul>
4075
4076 In either case, you can get access to the <link to="IConsole" />
4077 object which controls VM execution.
4078
4079 Also in all of the above cases, one must always call
4080 <link to="ISession::unlockMachine" /> to release the lock on the machine, or
4081 the machine's state will eventually be set to "Aborted".
4082
4083 To change settings on a machine, the following sequence is typically
4084 performed:
4085
4086 <ol>
4087 <li>Call this method to obtain an exclusive write lock for the current session.</li>
4088
4089 <li>Obtain a mutable IMachine object from <link to="ISession::machine" />.</li>
4090
4091 <li>Change the settings of the machine by invoking IMachine methods.</li>
4092
4093 <li>Call <link to="IMachine::saveSettings" />.</li>
4094
4095 <li>Release the write lock by calling <link to="ISession::unlockMachine"/>.</li>
4096 </ol>
4097
4098 <result name="E_UNEXPECTED">
4099 Virtual machine not registered.
4100 </result>
4101 <result name="E_ACCESSDENIED">
4102 Process not started by OpenRemoteSession.
4103 </result>
4104 <result name="VBOX_E_INVALID_OBJECT_STATE">
4105 Session already open or being opened.
4106 </result>
4107 <result name="VBOX_E_VM_ERROR">
4108 Failed to assign machine to session.
4109 </result>
4110 </desc>
4111 <param name="session" type="ISession" dir="in">
4112 <desc>
4113 Session object for which the machine will be locked.
4114 </desc>
4115 </param>
4116 <param name="lockType" type="LockType" dir="in">
4117 <desc>
4118 If set to @c Write, then attempt to acquire an exclusive write lock or fail.
4119 If set to @c Shared, then either acquire an exclusive write lock or establish
4120 a link to an existing session.
4121 </desc>
4122 </param>
4123 </method>
4124
4125 <method name="launchVMProcess">
4126 <desc>
4127 Spawns a new process that will execute the virtual machine and obtains a shared
4128 lock on the machine for the calling session.
4129
4130 If launching the VM succeeds, the new VM process will create its own session
4131 and write-lock the machine for it, preventing conflicting changes from other
4132 processes. If the machine is already locked (because it is already running or
4133 because another session has a write lock), launching the VM process will therefore
4134 fail. Reversely, future attempts to obtain a write lock will also fail while the
4135 machine is running.
4136
4137 The caller's session object remains separate from the session opened by the new
4138 VM process. It receives its own <link to="IConsole" /> object which can be used
4139 to control machine execution, but it cannot be used to change all VM settings
4140 which would be available after a <link to="#lockMachine" /> call.
4141
4142 The caller must eventually release the session's shared lock by calling
4143 <link to="ISession::unlockMachine" /> on the local session object once this call
4144 has returned. However, the session's state (see <link to="ISession::state" />)
4145 will not return to "Unlocked" until the remote session has also unlocked
4146 the machine (i.e. the machine has stopped running).
4147
4148 Lauching a VM process can take some time (a new VM is started in a new process,
4149 for which memory and other resources need to be set up). Because of this,
4150 an <link to="IProgress" /> object is returned to allow the caller to wait
4151 for this asynchronous operation to be completed. Until then, the caller's
4152 session object remains in the "Unlocked" state, and its <link to="ISession::machine" />
4153 and <link to="ISession::console" /> attributes cannot be accessed.
4154 It is recommended to use <link to="IProgress::waitForCompletion" /> or
4155 similar calls to wait for completion. Completion is signalled when the VM
4156 is powered on. If launching the VM fails, error messages can be queried
4157 via the progress object, if available.
4158
4159 The progress object will have at least 2 sub-operations. The first
4160 operation covers the period up to the new VM process calls powerUp.
4161 The subsequent operations mirror the <link to="IConsole::powerUp"/>
4162 progress object. Because <link to="IConsole::powerUp"/> may require
4163 some extra sub-operations, the <link to="IProgress::operationCount"/>
4164 may change at the completion of operation.
4165
4166 For details on the teleportation progress operation, see
4167 <link to="IConsole::powerUp"/>.
4168
4169 The @a environment argument is a string containing definitions of
4170 environment variables in the following format:
4171 @code
4172 NAME[=VALUE]\n
4173 NAME[=VALUE]\n
4174 ...
4175 @endcode
4176 where <tt>\\n</tt> is the new line character. These environment
4177 variables will be appended to the environment of the VirtualBox server
4178 process. If an environment variable exists both in the server process
4179 and in this list, the value from this list takes precedence over the
4180 server's variable. If the value of the environment variable is
4181 omitted, this variable will be removed from the resulting environment.
4182 If the environment string is @c null or empty, the server environment
4183 is inherited by the started process as is.
4184
4185 <result name="E_UNEXPECTED">
4186 Virtual machine not registered.
4187 </result>
4188 <result name="E_INVALIDARG">
4189 Invalid session type @a type.
4190 </result>
4191 <result name="VBOX_E_OBJECT_NOT_FOUND">
4192 No machine matching @a machineId found.
4193 </result>
4194 <result name="VBOX_E_INVALID_OBJECT_STATE">
4195 Session already open or being opened.
4196 </result>
4197 <result name="VBOX_E_IPRT_ERROR">
4198 Launching process for machine failed.
4199 </result>
4200 <result name="VBOX_E_VM_ERROR">
4201 Failed to assign machine to session.
4202 </result>
4203 </desc>
4204 <param name="session" type="ISession" dir="in">
4205 <desc>
4206 Client session object to which the VM process will be connected (this
4207 must be in "Unlocked" state).
4208 </desc>
4209 </param>
4210 <param name="type" type="wstring" dir="in">
4211 <desc>
4212 Front-end to use for the new VM process. The following are currently supported:
4213 <ul>
4214 <li><tt>"gui"</tt>: VirtualBox Qt GUI front-end</li>
4215 <li><tt>"vrdp"</tt>: VBoxHeadless (VRDP Server) front-end</li>
4216 <li><tt>"sdl"</tt>: VirtualBox SDL front-end</li>
4217 </ul>
4218 </desc>
4219 </param>
4220 <param name="environment" type="wstring" dir="in">
4221 <desc>
4222 Environment to pass to the VM process.
4223 </desc>
4224 </param>
4225 <param name="progress" type="IProgress" dir="return">
4226 <desc>Progress object to track the operation completion.</desc>
4227 </param>
4228 </method>
4229
4230 <method name="setBootOrder">
4231 <desc>
4232 Puts the given device to the specified position in
4233 the boot order.
4234
4235 To indicate that no device is associated with the given position,
4236 <link to="DeviceType_Null"/> should be used.
4237
4238 @todo setHardDiskBootOrder(), setNetworkBootOrder()
4239
4240 <result name="E_INVALIDARG">
4241 Boot @a position out of range.
4242 </result>
4243 <result name="E_NOTIMPL">
4244 Booting from USB @a device currently not supported.
4245 </result>
4246
4247 </desc>
4248 <param name="position" type="unsigned long" dir="in">
4249 <desc>
4250 Position in the boot order (@c 1 to the total number of
4251 devices the machine can boot from, as returned by
4252 <link to="ISystemProperties::maxBootPosition"/>).
4253 </desc>
4254 </param>
4255 <param name="device" type="DeviceType" dir="in">
4256 <desc>
4257 The type of the device used to boot at the given position.
4258 </desc>
4259 </param>
4260 </method>
4261
4262 <method name="getBootOrder" const="yes">
4263 <desc>
4264 Returns the device type that occupies the specified
4265 position in the boot order.
4266
4267 @todo [remove?]
4268 If the machine can have more than one device of the returned type
4269 (such as hard disks), then a separate method should be used to
4270 retrieve the individual device that occupies the given position.
4271
4272 If here are no devices at the given position, then
4273 <link to="DeviceType_Null"/> is returned.
4274
4275 @todo getHardDiskBootOrder(), getNetworkBootOrder()
4276
4277 <result name="E_INVALIDARG">
4278 Boot @a position out of range.
4279 </result>
4280
4281 </desc>
4282 <param name="position" type="unsigned long" dir="in">
4283 <desc>
4284 Position in the boot order (@c 1 to the total number of
4285 devices the machine can boot from, as returned by
4286 <link to="ISystemProperties::maxBootPosition"/>).
4287 </desc>
4288 </param>
4289 <param name="device" type="DeviceType" dir="return">
4290 <desc>
4291 Device at the given position.
4292 </desc>
4293 </param>
4294 </method>
4295
4296 <method name="attachDevice">
4297 <desc>
4298 Attaches a device and optionally mounts a medium to the given storage
4299 controller (<link to="IStorageController" />, identified by @a name),
4300 at the indicated port and device.
4301
4302 This method is intended for managing storage devices in general while a
4303 machine is powered off. It can be used to attach and detach fixed
4304 and removeable media. The following kind of media can be attached
4305 to a machine:
4306
4307 <ul>
4308 <li>For fixed and removable media, you can pass in a medium that was
4309 previously opened using <link to="IVirtualBox::openMedium" />.
4310 </li>
4311
4312 <li>Only for storage devices supporting removable media (such as
4313 DVDs and floppies), you can also specify a null pointer to
4314 indicate an empty drive or one of the medium objects listed
4315 in the <link to="IHost::DVDDrives" /> and <link to="IHost::floppyDrives"/>
4316 arrays to indicate a host drive.
4317 For removeable devices, you can also use <link to="IMachine::mountMedium"/>
4318 to change the media while the machine is running.
4319 </li>
4320 </ul>
4321
4322 In a VM's default configuration of virtual machines, the secondary
4323 master of the IDE controller is used for a CD/DVD drive.
4324
4325 After calling this returns successfully, a new instance of
4326 <link to="IMediumAttachment"/> will appear in the machine's list of medium
4327 attachments (see <link to="IMachine::mediumAttachments"/>).
4328
4329 See <link to="IMedium"/> and <link to="IMediumAttachment"/> for more
4330 information about attaching media.
4331
4332 The specified device slot must not have a device attached to it,
4333 or this method will fail.
4334
4335 <note>
4336 You cannot attach a device to a newly created machine until
4337 this machine's settings are saved to disk using
4338 <link to="#saveSettings"/>.
4339 </note>
4340 <note>
4341 If the medium is being attached indirectly, a new differencing medium
4342 will implicitly be created for it and attached instead. If the
4343 changes made to the machine settings (including this indirect
4344 attachment) are later cancelled using <link to="#discardSettings"/>,
4345 this implicitly created differencing medium will implicitly
4346 be deleted.
4347 </note>
4348
4349 <result name="E_INVALIDARG">
4350 SATA device, SATA port, IDE port or IDE slot out of range, or
4351 file or UUID not found.
4352 </result>
4353 <result name="VBOX_E_INVALID_OBJECT_STATE">
4354 Machine must be registered before media can be attached.
4355 </result>
4356 <result name="VBOX_E_INVALID_VM_STATE">
4357 Invalid machine state.
4358 </result>
4359 <result name="VBOX_E_OBJECT_IN_USE">
4360 A medium is already attached to this or another virtual machine.
4361 </result>
4362
4363 </desc>
4364 <param name="name" type="wstring" dir="in">
4365 <desc>Name of the storage controller to attach the device to.</desc>
4366 </param>
4367 <param name="controllerPort" type="long" dir="in">
4368 <desc>Port to attach the device to. For an IDE controller, 0 specifies
4369 the primary controller and 1 specifies the secondary controller.
4370 For a SCSI controller, this must range from 0 to 15; for a SATA controller,
4371 from 0 to 29; for an SAS controller, from 0 to 7.</desc>
4372 </param>
4373 <param name="device" type="long" dir="in">
4374 <desc>Device slot in the given port to attach the device to. This is only
4375 relevant for IDE controllers, for which 0 specifies the master device and
4376 1 specifies the slave device. For all other controller types, this must
4377 be 0.</desc>
4378 </param>
4379 <param name="type" type="DeviceType" dir="in">
4380 <desc>Device type of the attached device. For media opened by
4381 <link to="IVirtualBox::openMedium" />, this must match the device type
4382 specified there.</desc>
4383 </param>
4384 <param name="medium" type="IMedium" dir="in">
4385 <desc>Medium to mount or NULL for an empty drive.</desc>
4386 </param>
4387 </method>
4388
4389 <method name="detachDevice">
4390 <desc>
4391 Detaches the device attached to a device slot of the specified bus.
4392
4393 Detaching the device from the virtual machine is deferred. This means
4394 that the medium remains associated with the machine when this method
4395 returns and gets actually de-associated only after a successful
4396 <link to="#saveSettings"/> call. See <link to="IMedium"/>
4397 for more detailed information about attaching media.
4398
4399 <note>
4400 You cannot detach a device from a running machine.
4401 </note>
4402 <note>
4403 Detaching differencing media implicitly created by <link
4404 to="#attachDevice"/> for the indirect attachment using this
4405 method will <b>not</b> implicitly delete them. The
4406 <link to="IMedium::deleteStorage"/> operation should be
4407 explicitly performed by the caller after the medium is successfully
4408 detached and the settings are saved with
4409 <link to="#saveSettings"/>, if it is the desired action.
4410 </note>
4411
4412 <result name="VBOX_E_INVALID_VM_STATE">
4413 Attempt to detach medium from a running virtual machine.
4414 </result>
4415 <result name="VBOX_E_OBJECT_NOT_FOUND">
4416 No medium attached to given slot/bus.
4417 </result>
4418 <result name="VBOX_E_NOT_SUPPORTED">
4419 Medium format does not support storage deletion.
4420 </result>
4421
4422 </desc>
4423 <param name="name" type="wstring" dir="in">
4424 <desc>Name of the storage controller to detach the medium from.</desc>
4425 </param>
4426 <param name="controllerPort" type="long" dir="in">
4427 <desc>Port number to detach the medium from.</desc>
4428 </param>
4429 <param name="device" type="long" dir="in">
4430 <desc>Device slot number to detach the medium from.</desc>
4431 </param>
4432 </method>
4433
4434 <method name="passthroughDevice">
4435 <desc>
4436 Sets the passthrough mode of an existing DVD device. Changing the
4437 setting while the VM is running is forbidden. The setting is only used
4438 if at VM start the device is configured as a host DVD drive, in all
4439 other cases it is ignored. The device must already exist; see
4440 <link to="IMachine::attachDevice"/> for how to attach a new device.
4441
4442 The @a controllerPort and @a device parameters specify the device slot and
4443 have have the same meaning as with <link to="IMachine::attachDevice" />.
4444
4445 <result name="E_INVALIDARG">
4446 SATA device, SATA port, IDE port or IDE slot out of range.
4447 </result>
4448 <result name="VBOX_E_INVALID_OBJECT_STATE">
4449 Attempt to modify an unregistered virtual machine.
4450 </result>
4451 <result name="VBOX_E_INVALID_VM_STATE">
4452 Invalid machine state.
4453 </result>
4454
4455 </desc>
4456 <param name="name" type="wstring" dir="in">
4457 <desc>Name of the storage controller.</desc>
4458 </param>
4459 <param name="controllerPort" type="long" dir="in">
4460 <desc>Storage controller port.</desc>
4461 </param>
4462 <param name="device" type="long" dir="in">
4463 <desc>Device slot in the given port.</desc>
4464 </param>
4465 <param name="passthrough" type="boolean" dir="in">
4466 <desc>New value for the passthrough setting.</desc>
4467 </param>
4468 </method>
4469
4470 <method name="mountMedium">
4471 <desc>
4472 Mounts a medium (<link to="IMedium" />, identified
4473 by the given UUID @a id) to the given storage controller
4474 (<link to="IStorageController" />, identified by @a name),
4475 at the indicated port and device. The device must already exist;
4476 see <link to="IMachine::attachDevice"/> for how to attach a new device.
4477
4478 This method is intended only for managing removable media, where the
4479 device is fixed but media is changeable at runtime (such as DVDs
4480 and floppies). It cannot be used for fixed media such as hard disks.
4481
4482 The @a controllerPort and @a device parameters specify the device slot and
4483 have have the same meaning as with <link to="IMachine::attachDevice" />.
4484
4485 The specified device slot can have a medium mounted, which will be
4486 unmounted first. Specifying a zero UUID (or an empty string) for
4487 @a medium does just an unmount.
4488
4489 See <link to="IMedium"/> for more detailed information about
4490 attaching media.
4491
4492 <result name="E_INVALIDARG">
4493 SATA device, SATA port, IDE port or IDE slot out of range.
4494 </result>
4495 <result name="VBOX_E_INVALID_OBJECT_STATE">
4496 Attempt to attach medium to an unregistered virtual machine.
4497 </result>
4498 <result name="VBOX_E_INVALID_VM_STATE">
4499 Invalid machine state.
4500 </result>
4501 <result name="VBOX_E_OBJECT_IN_USE">
4502 Medium already attached to this or another virtual machine.
4503 </result>
4504
4505 </desc>
4506 <param name="name" type="wstring" dir="in">
4507 <desc>Name of the storage controller to attach the medium to.</desc>
4508 </param>
4509 <param name="controllerPort" type="long" dir="in">
4510 <desc>Port to attach the medium to.</desc>
4511 </param>
4512 <param name="device" type="long" dir="in">
4513 <desc>Device slot in the given port to attach the medium to.</desc>
4514 </param>
4515 <param name="medium" type="IMedium" dir="in">
4516 <desc>Medium to mount or NULL for an empty drive.</desc>
4517 </param>
4518 <param name="force" type="boolean" dir="in">
4519 <desc>Allows to force unmount/mount of a medium which is locked by
4520 the device slot in the given port to attach the medium to.</desc>
4521 </param>
4522 </method>
4523
4524 <method name="getMedium" const="yes">
4525 <desc>
4526 Returns the virtual medium attached to a device slot of the specified
4527 bus.
4528
4529 Note that if the medium was indirectly attached by
4530 <link to="#mountMedium"/> to the given device slot then this
4531 method will return not the same object as passed to the
4532 <link to="#mountMedium"/> call. See <link to="IMedium"/> for
4533 more detailed information about mounting a medium.
4534
4535 <result name="VBOX_E_OBJECT_NOT_FOUND">
4536 No medium attached to given slot/bus.
4537 </result>
4538
4539 </desc>
4540 <param name="name" type="wstring" dir="in">
4541 <desc>Name of the storage controller the medium is attached to.</desc>
4542 </param>
4543 <param name="controllerPort" type="long" dir="in">
4544 <desc>Port to query.</desc>
4545 </param>
4546 <param name="device" type="long" dir="in">
4547 <desc>Device slot in the given port to query.</desc>
4548 </param>
4549 <param name="medium" type="IMedium" dir="return">
4550 <desc>Attached medium object.</desc>
4551 </param>
4552 </method>
4553
4554 <method name="getMediumAttachmentsOfController" const="yes">
4555 <desc>
4556 Returns an array of medium attachments which are attached to the
4557 the controller with the given name.
4558
4559 <result name="VBOX_E_OBJECT_NOT_FOUND">
4560 A storage controller with given name doesn't exist.
4561 </result>
4562 </desc>
4563 <param name="name" type="wstring" dir="in"/>
4564 <param name="mediumAttachments" type="IMediumAttachment" safearray="yes" dir="return"/>
4565 </method>
4566
4567 <method name="getMediumAttachment" const="yes">
4568 <desc>
4569 Returns a medium attachment which corresponds to the controller with
4570 the given name, on the given port and device slot.
4571
4572 <result name="VBOX_E_OBJECT_NOT_FOUND">
4573 No attachment exists for the given controller/port/device combination.
4574 </result>
4575 </desc>
4576 <param name="name" type="wstring" dir="in"/>
4577 <param name="controllerPort" type="long" dir="in"/>
4578 <param name="device" type="long" dir="in"/>
4579 <param name="attachment" type="IMediumAttachment" dir="return"/>
4580 </method>
4581
4582 <method name="getNetworkAdapter" const="yes">
4583 <desc>
4584 Returns the network adapter associated with the given slot.
4585 Slots are numbered sequentially, starting with zero. The total
4586 number of adapters per machine is defined by the
4587 <link to="ISystemProperties::networkAdapterCount"/> property,
4588 so the maximum slot number is one less than that property's value.
4589
4590 <result name="E_INVALIDARG">
4591 Invalid @a slot number.
4592 </result>
4593
4594 </desc>
4595 <param name="slot" type="unsigned long" dir="in"/>
4596 <param name="adapter" type="INetworkAdapter" dir="return"/>
4597 </method>
4598
4599 <method name="addStorageController">
4600 <desc>
4601 Adds a new storage controller (SCSI, SAS or SATA controller) to the
4602 machine and returns it as an instance of
4603 <link to="IStorageController" />.
4604
4605 @a name identifies the controller for subsequent calls such as
4606 <link to="#getStorageControllerByName" />,
4607 <link to="#getStorageControllerByInstance" />,
4608 <link to="#removeStorageController" />,
4609 <link to="#attachDevice" /> or <link to="#mountMedium" />.
4610
4611 After the controller has been added, you can set its exact
4612 type by setting the <link to="IStorageController::controllerType" />.
4613
4614 <result name="VBOX_E_OBJECT_IN_USE">
4615 A storage controller with given name exists already.
4616 </result>
4617 <result name="E_INVALIDARG">
4618 Invalid @a controllerType.
4619 </result>
4620 </desc>
4621 <param name="name" type="wstring" dir="in"/>
4622 <param name="connectionType" type="StorageBus" dir="in"/>
4623 <param name="controller" type="IStorageController" dir="return"/>
4624 </method>
4625
4626 <method name="getStorageControllerByName" const="yes">
4627 <desc>
4628 Returns a storage controller with the given name.
4629
4630 <result name="VBOX_E_OBJECT_NOT_FOUND">
4631 A storage controller with given name doesn't exist.
4632 </result>
4633 </desc>
4634 <param name="name" type="wstring" dir="in"/>
4635 <param name="storageController" type="IStorageController" dir="return"/>
4636 </method>
4637
4638 <method name="getStorageControllerByInstance" const="yes">
4639 <desc>
4640 Returns a storage controller with the given instance number.
4641
4642 <result name="VBOX_E_OBJECT_NOT_FOUND">
4643 A storage controller with given instance number doesn't exist.
4644 </result>
4645 </desc>
4646 <param name="instance" type="unsigned long" dir="in"/>
4647 <param name="storageController" type="IStorageController" dir="return"/>
4648 </method>
4649
4650 <method name="removeStorageController">
4651 <desc>
4652 Removes a storage controller from the machine.
4653
4654 <result name="VBOX_E_OBJECT_NOT_FOUND">
4655 A storage controller with given name doesn't exist.
4656 </result>
4657 </desc>
4658 <param name="name" type="wstring" dir="in"/>
4659 </method>
4660
4661 <method name="getSerialPort" const="yes">
4662 <desc>
4663 Returns the serial port associated with the given slot.
4664 Slots are numbered sequentially, starting with zero. The total
4665 number of serial ports per machine is defined by the
4666 <link to="ISystemProperties::serialPortCount"/> property,
4667 so the maximum slot number is one less than that property's value.
4668
4669 <result name="E_INVALIDARG">
4670 Invalid @a slot number.
4671 </result>
4672
4673 </desc>
4674 <param name="slot" type="unsigned long" dir="in"/>
4675 <param name="port" type="ISerialPort" dir="return"/>
4676 </method>
4677
4678 <method name="getParallelPort" const="yes">
4679 <desc>
4680 Returns the parallel port associated with the given slot.
4681 Slots are numbered sequentially, starting with zero. The total
4682 number of parallel ports per machine is defined by the
4683 <link to="ISystemProperties::parallelPortCount"/> property,
4684 so the maximum slot number is one less than that property's value.
4685
4686 <result name="E_INVALIDARG">
4687 Invalid @a slot number.
4688 </result>
4689
4690 </desc>
4691 <param name="slot" type="unsigned long" dir="in"/>
4692 <param name="port" type="IParallelPort" dir="return"/>
4693 </method>
4694
4695 <method name="getExtraDataKeys">
4696 <desc>
4697 Returns an array representing the machine-specific extra data keys
4698 which currently have values defined.
4699 </desc>
4700 <param name="value" type="wstring" dir="return" safearray="yes">
4701 <desc>Array of extra data keys.</desc>
4702 </param>
4703 </method>
4704
4705 <method name="getExtraData">
4706 <desc>
4707 Returns associated machine-specific extra data.
4708
4709 If the requested data @a key does not exist, this function will
4710 succeed and return an empty string in the @a value argument.
4711
4712 <result name="VBOX_E_FILE_ERROR">
4713 Settings file not accessible.
4714 </result>
4715 <result name="VBOX_E_XML_ERROR">
4716 Could not parse the settings file.
4717 </result>
4718
4719 </desc>
4720 <param name="key" type="wstring" dir="in">
4721 <desc>Name of the data key to get.</desc>
4722 </param>
4723 <param name="value" type="wstring" dir="return">
4724 <desc>Value of the requested data key.</desc>
4725 </param>
4726 </method>
4727
4728 <method name="setExtraData">
4729 <desc>
4730 Sets associated machine-specific extra data.
4731
4732 If you pass @c null or an empty string as a key @a value, the given
4733 @a key will be deleted.
4734
4735 <note>
4736 Before performing the actual data change, this method will ask all
4737 registered listeners using the
4738 <link to="IExtraDataCanChangeEvent"/>
4739 notification for a permission. If one of the listeners refuses the
4740 new value, the change will not be performed.
4741 </note>
4742 <note>
4743 On success, the
4744 <link to="IExtraDataChangedEvent"/> notification
4745 is called to inform all registered listeners about a successful data
4746 change.
4747 </note>
4748 <note>
4749 This method can be called outside the machine session and therefore
4750 it's a caller's responsibility to handle possible race conditions
4751 when several clients change the same key at the same time.
4752 </note>
4753
4754 <result name="VBOX_E_FILE_ERROR">
4755 Settings file not accessible.
4756 </result>
4757 <result name="VBOX_E_XML_ERROR">
4758 Could not parse the settings file.
4759 </result>
4760
4761 </desc>
4762 <param name="key" type="wstring" dir="in">
4763 <desc>Name of the data key to set.</desc>
4764 </param>
4765 <param name="value" type="wstring" dir="in">
4766 <desc>Value to assign to the key.</desc>
4767 </param>
4768 </method>
4769
4770 <method name="getCPUProperty" const="yes">
4771 <desc>
4772 Returns the virtual CPU boolean value of the specified property.
4773
4774 <result name="E_INVALIDARG">
4775 Invalid property.
4776 </result>
4777
4778 </desc>
4779 <param name="property" type="CPUPropertyType" dir="in">
4780 <desc>
4781 Property type to query.
4782 </desc>
4783 </param>
4784 <param name="value" type="boolean" dir="return">
4785 <desc>
4786 Property value.
4787 </desc>
4788 </param>
4789 </method>
4790
4791 <method name="setCPUProperty">
4792 <desc>
4793 Sets the virtual CPU boolean value of the specified property.
4794
4795 <result name="E_INVALIDARG">
4796 Invalid property.
4797 </result>
4798
4799 </desc>
4800 <param name="property" type="CPUPropertyType" dir="in">
4801 <desc>
4802 Property type to query.
4803 </desc>
4804 </param>
4805 <param name="value" type="boolean" dir="in">
4806 <desc>
4807 Property value.
4808 </desc>
4809 </param>
4810 </method>
4811
4812 <method name="getCPUIDLeaf" const="yes">
4813 <desc>
4814 Returns the virtual CPU cpuid information for the specified leaf.
4815
4816 Currently supported index values for cpuid:
4817 Standard CPUID leafs: 0 - 0xA
4818 Extended CPUID leafs: 0x80000000 - 0x8000000A
4819
4820 See the Intel and AMD programmer's manuals for detailed information
4821 about the cpuid instruction and its leafs.
4822 <result name="E_INVALIDARG">
4823 Invalid id.
4824 </result>
4825
4826 </desc>
4827 <param name="id" type="unsigned long" dir="in">
4828 <desc>
4829 CPUID leaf index.
4830 </desc>
4831 </param>
4832 <param name="valEax" type="unsigned long" dir="out">
4833 <desc>
4834 CPUID leaf value for register eax.
4835 </desc>
4836 </param>
4837 <param name="valEbx" type="unsigned long" dir="out">
4838 <desc>
4839 CPUID leaf value for register ebx.
4840 </desc>
4841 </param>
4842 <param name="valEcx" type="unsigned long" dir="out">
4843 <desc>
4844 CPUID leaf value for register ecx.
4845 </desc>
4846 </param>
4847 <param name="valEdx" type="unsigned long" dir="out">
4848 <desc>
4849 CPUID leaf value for register edx.
4850 </desc>
4851 </param>
4852 </method>
4853
4854 <method name="setCPUIDLeaf">
4855 <desc>
4856 Sets the virtual CPU cpuid information for the specified leaf. Note that these values
4857 are not passed unmodified. VirtualBox clears features that it doesn't support.
4858
4859 Currently supported index values for cpuid:
4860 Standard CPUID leafs: 0 - 0xA
4861 Extended CPUID leafs: 0x80000000 - 0x8000000A
4862
4863 See the Intel and AMD programmer's manuals for detailed information
4864 about the cpuid instruction and its leafs.
4865
4866 Do not use this method unless you know exactly what you're doing. Misuse can lead to
4867 random crashes inside VMs.
4868 <result name="E_INVALIDARG">
4869 Invalid id.
4870 </result>
4871
4872 </desc>
4873 <param name="id" type="unsigned long" dir="in">
4874 <desc>
4875 CPUID leaf index.
4876 </desc>
4877 </param>
4878 <param name="valEax" type="unsigned long" dir="in">
4879 <desc>
4880 CPUID leaf value for register eax.
4881 </desc>
4882 </param>
4883 <param name="valEbx" type="unsigned long" dir="in">
4884 <desc>
4885 CPUID leaf value for register ebx.
4886 </desc>
4887 </param>
4888 <param name="valEcx" type="unsigned long" dir="in">
4889 <desc>
4890 CPUID leaf value for register ecx.
4891 </desc>
4892 </param>
4893 <param name="valEdx" type="unsigned long" dir="in">
4894 <desc>
4895 CPUID leaf value for register edx.
4896 </desc>
4897 </param>
4898 </method>
4899
4900 <method name="removeCPUIDLeaf">
4901 <desc>
4902 Removes the virtual CPU cpuid leaf for the specified index
4903
4904 <result name="E_INVALIDARG">
4905 Invalid id.
4906 </result>
4907
4908 </desc>
4909 <param name="id" type="unsigned long" dir="in">
4910 <desc>
4911 CPUID leaf index.
4912 </desc>
4913 </param>
4914 </method>
4915
4916 <method name="removeAllCPUIDLeaves">
4917 <desc>
4918 Removes all the virtual CPU cpuid leaves
4919 </desc>
4920 </method>
4921
4922 <method name="getHWVirtExProperty" const="yes">
4923 <desc>
4924 Returns the value of the specified hardware virtualization boolean property.
4925
4926 <result name="E_INVALIDARG">
4927 Invalid property.
4928 </result>
4929
4930 </desc>
4931 <param name="property" type="HWVirtExPropertyType" dir="in">
4932 <desc>
4933 Property type to query.
4934 </desc>
4935 </param>
4936 <param name="value" type="boolean" dir="return">
4937 <desc>
4938 Property value.
4939 </desc>
4940 </param>
4941 </method>
4942
4943 <method name="setHWVirtExProperty">
4944 <desc>
4945 Sets a new value for the specified hardware virtualization boolean property.
4946
4947 <result name="E_INVALIDARG">
4948 Invalid property.
4949 </result>
4950
4951 </desc>
4952 <param name="property" type="HWVirtExPropertyType" dir="in">
4953 <desc>
4954 Property type to set.
4955 </desc>
4956 </param>
4957 <param name="value" type="boolean" dir="in">
4958 <desc>
4959 New property value.
4960 </desc>
4961 </param>
4962 </method>
4963
4964 <method name="saveSettings">
4965 <desc>
4966 Saves any changes to machine settings made since the session
4967 has been opened or a new machine has been created, or since the
4968 last call to <link to="#saveSettings"/> or <link to="#discardSettings"/>.
4969 For registered machines, new settings become visible to all
4970 other VirtualBox clients after successful invocation of this
4971 method.
4972 <note>
4973 The method sends <link to="IMachineDataChangedEvent"/>
4974 notification event after the configuration has been successfully
4975 saved (only for registered machines).
4976 </note>
4977 <note>
4978 Calling this method is only valid on instances returned
4979 by <link to="ISession::machine"/> and on new machines
4980 created by <link to="IVirtualBox::createMachine"/> but not
4981 yet registered, or on unregistered machines after calling
4982 <link to="IMachine::unregister"/>.
4983 </note>
4984
4985 <result name="VBOX_E_FILE_ERROR">
4986 Settings file not accessible.
4987 </result>
4988 <result name="VBOX_E_XML_ERROR">
4989 Could not parse the settings file.
4990 </result>
4991 <result name="E_ACCESSDENIED">
4992 Modification request refused.
4993 </result>
4994
4995 </desc>
4996 </method>
4997
4998 <method name="discardSettings">
4999 <desc>
5000 Discards any changes to the machine settings made since the session
5001 has been opened or since the last call to <link to="#saveSettings"/>
5002 or <link to="#discardSettings"/>.
5003 <note>
5004 Calling this method is only valid on instances returned
5005 by <link to="ISession::machine"/> and on new machines
5006 created by <link to="IVirtualBox::createMachine"/> or
5007 opened by <link to="IVirtualBox::openMachine"/> but not
5008 yet registered, or on unregistered machines after calling
5009 <link to="IMachine::unregister"/>.
5010 </note>
5011
5012 <result name="VBOX_E_INVALID_VM_STATE">
5013 Virtual machine is not mutable.
5014 </result>
5015
5016 </desc>
5017 </method>
5018
5019 <method name="unregister">
5020 <desc>
5021 Unregisters the machine, which must have been previously registered using
5022 <link to="IVirtualBox::registerMachine"/>, and optionally do additional
5023 cleanup before the machine is unregistered.
5024
5025 This method does not delete any files. It only changes the machine configuration and
5026 the list of registered machines in the VirtualBox object. To delete the files which
5027 belonged to the machine, including the XML file of the machine itself, call
5028 <link to="#delete"/>, optionally with the array of IMedium objects which was returned
5029 from this method.
5030
5031 How thoroughly this method cleans up the machine configuration before unregistering
5032 the machine depends on the @a cleanupMode argument.
5033
5034 <ul>
5035 <li>With "UnregisterOnly", the machine will only be unregistered, but no additional
5036 cleanup will be performed. The call will fail if the machine is in "Saved" state
5037 or has any snapshots or any media attached (see <link to="IMediumAttachment" />.
5038 It is the responsibility of the caller to delete all such configuration in this mode.
5039 In this mode, the API behaves like the former @c IVirtualBox::unregisterMachine() API
5040 which it replaces.</li>
5041 <li>With "DetachAllReturnNone", the call will succeed even if the machine is in "Saved"
5042 state or if it has snapshots or media attached. All media attached to the current machine
5043 state or in snapshots will be detached. No medium objects will be returned; all of the
5044 machine's media will remain open.</li>
5045 <li>With "DetachAllReturnHardDisksOnly", the call will behave like with "DetachAllReturnNone",
5046 except that all the hard disk medium objects which were detached from the machine will
5047 be returned as an array. This allows for quickly passing them to the <link to="#delete" />
5048 API for closing and deletion.</li>
5049 <li>With "Full", the call will behave like with "DetachAllReturnHardDisksOnly", except
5050 that all media will be returned in the array, including removeable media like DVDs and
5051 floppies. This might be useful if the user wants to inspect in detail which media were
5052 attached to the machine. Be careful when passing the media array to <link to="#delete" />
5053 in that case because users will typically want to preserve ISO and RAW image files.</li>
5054 </ul>
5055
5056 This API does not verify whether the media files returned in the array are still
5057 attached to other machines (i.e. shared between several machines). If such a shared
5058 image is passed to <link to="#delete" /> however, closing the image will fail there
5059 and the image will be silently skipped.
5060
5061 A typical implementation will use "DetachAllReturnHardDisksOnly" and then pass the
5062 resulting IMedia array to <link to="#delete"/>. This way, the machine is completely
5063 deleted with all its saved states and hard disk images, but images for removeable
5064 drives (such as ISO and RAW files) will remain on disk.
5065
5066 The call will fail if the machine is currently locked (see <link to="ISession" />).
5067 It implicitly calls <link to="#saveSettings"/> to save all current machine settings
5068 before unregistering it.
5069
5070 After successful method invocation, the <link to="IMachineRegisteredEvent"/> event
5071 is fired.
5072
5073 <note>
5074 If the given machine is inaccessible (see <link to="#accessible"/>), it
5075 will be unregistered and fully uninitialized right afterwards. As a result,
5076 the returned machine object will be unusable and an attempt to call
5077 <b>any</b> method will return the "Object not ready" error.
5078 </note>
5079
5080 <result name="VBOX_E_INVALID_OBJECT_STATE">
5081 Machine is currently locked for a session.
5082 </result>
5083 </desc>
5084
5085 <param name="cleanupMode" type="CleanupMode" dir="in">
5086 <desc>How to clean up after the machine has been unregistered.</desc>
5087 </param>
5088 <param name="aMedia" type="IMedium" safearray="yes" dir="return">
5089 <desc>List of media detached from the machine, depending on the @a cleanupMode parameter.</desc>
5090 </param>
5091 </method>
5092
5093 <method name="delete">
5094 <desc>
5095 Deletes the files associated with this machine from disk. If medium objects are passed
5096 in with the @a aMedia argument, they are closed and, if closing was succesful, their
5097 storage files are deleted as well. For convenience, this array of media files can be
5098 the same as the one returned from a previous <link to="#unregister" /> call.
5099
5100 This method must only be called on machines which are either write-locked (i.e. on instances
5101 returned by <link to="ISession::machine"/>) or on unregistered machines (i.e. not yet
5102 registered machines created by <link to="IVirtualBox::createMachine"/> or opened by
5103 <link to="IVirtualBox::openMachine"/>, or after having called <link to="#unregister"/>).
5104
5105 The following files will be deleted by this method:
5106 <ul>
5107 <li>If <link to="#unregister" /> had been previously called with a @a cleanupMode
5108 argument other than "UnregisterOnly", this will delete all saved state files that
5109 the machine had in use; possibly one if the machine was in "Saved" state and one
5110 for each online snapshot that the machine had.</li>
5111 <li>On each medium object passed in the @a aMedia array, this will call
5112 <link to="IMedium::close" />. If that succeeds, this will attempt to delete the
5113 medium's storage on disk. Since the close() call will fail if the medium is still
5114 in use, e.g. because it is still attached to a second machine; in that case the
5115 storage will not be deleted.</li>
5116 <li>Finally, the machine's own XML file will be deleted.</li>
5117 </ul>
5118
5119 Since deleting large disk image files can be a time-consuming I/O operation, this
5120 method operates asynchronously and returns an IProgress object to allow the caller
5121 to monitor the progress. There will be one sub-operation for each file that is
5122 being deleted (saved state or medium storage file).
5123
5124 <note>
5125 <link to="#settingsModified"/> will return @c true after this
5126 method successfully returns.
5127 </note>
5128
5129 <result name="VBOX_E_INVALID_VM_STATE">
5130 Machine is registered but not write-locked.
5131 </result>
5132 <result name="VBOX_E_IPRT_ERROR">
5133 Could not delete the settings file.
5134 </result>
5135 </desc>
5136 <param name="aMedia" type="IMedium" safearray="yes" dir="in">
5137 <desc>List of media to be closed and whose storage files will be deleted.</desc>
5138 </param>
5139 <param name="aProgress" type="IProgress" dir="return">
5140 <desc>Progress object to track the operation completion.</desc>
5141 </param>
5142 </method>
5143
5144 <method name="export">
5145 <desc>Exports the machine to an OVF appliance. See <link to="IAppliance" /> for the
5146 steps required to export VirtualBox machines to OVF.
5147 </desc>
5148
5149 <param name="aAppliance" type="IAppliance" dir="in">
5150 <desc>Appliance to export this machine to.</desc>
5151 </param>
5152 <param name="aDescription" type="IVirtualSystemDescription" dir="return">
5153 <desc>VirtualSystemDescription object which is created for this machine.</desc>
5154 </param>
5155 </method >
5156
5157 <method name="getSnapshot">
5158 <desc>
5159 Returns a snapshot of this machine with the given UUID.
5160 A @c null UUID can be used to obtain the first snapshot
5161 taken on this machine. This is useful if you want to traverse
5162 the whole tree of snapshots starting from the root.
5163
5164 <result name="VBOX_E_OBJECT_NOT_FOUND">
5165 Virtual machine has no snapshots or snapshot not found.
5166 </result>
5167
5168 </desc>
5169 <param name="id" type="uuid" mod="string" dir="in">
5170 <desc>UUID of the snapshot to get</desc>
5171 </param>
5172 <param name="snapshot" type="ISnapshot" dir="return">
5173 <desc>Snapshot object with the given UUID.</desc>
5174 </param>
5175 </method>
5176
5177 <method name="findSnapshot">
5178 <desc>
5179 Returns a snapshot of this machine with the given name.
5180
5181 <result name="VBOX_E_OBJECT_NOT_FOUND">
5182 Virtual machine has no snapshots or snapshot not found.
5183 </result>
5184
5185 </desc>
5186 <param name="name" type="wstring" dir="in">
5187 <desc>Name of the snapshot to find</desc>
5188 </param>
5189 <param name="snapshot" type="ISnapshot" dir="return">
5190 <desc>Snapshot object with the given name.</desc>
5191 </param>
5192 </method>
5193
5194 <method name="setCurrentSnapshot">
5195 <desc>
5196 Sets the current snapshot of this machine.
5197 <note>
5198 In the current implementation, this operation is not
5199 implemented.
5200 </note>
5201 </desc>
5202 <param name="id" type="uuid" mod="string" dir="in">
5203 <desc>UUID of the snapshot to set as the current snapshot.</desc>
5204 </param>
5205 </method>
5206
5207 <method name="createSharedFolder">
5208 <desc>
5209 Creates a new permanent shared folder by associating the given logical
5210 name with the given host path, adds it to the collection of shared
5211 folders and starts sharing it. Refer to the description of
5212 <link to="ISharedFolder"/> to read more about logical names.
5213
5214 <result name="VBOX_E_OBJECT_IN_USE">
5215 Shared folder already exists.
5216 </result>
5217 <result name="VBOX_E_FILE_ERROR">
5218 Shared folder @a hostPath not accessible.
5219 </result>
5220
5221 </desc>
5222 <param name="name" type="wstring" dir="in">
5223 <desc>Unique logical name of the shared folder.</desc>
5224 </param>
5225 <param name="hostPath" type="wstring" dir="in">
5226 <desc>Full path to the shared folder in the host file system.</desc>
5227 </param>
5228 <param name="writable" type="boolean" dir="in">
5229 <desc>Whether the share is writable or readonly.</desc>
5230 </param>
5231 <param name="automount" type="boolean" dir="in">
5232 <desc>Whether the share gets automatically mounted by the guest
5233 or not.</desc>
5234 </param>
5235 </method>
5236
5237 <method name="removeSharedFolder">
5238 <desc>
5239 Removes the permanent shared folder with the given name previously
5240 created by <link to="#createSharedFolder"/> from the collection of
5241 shared folders and stops sharing it.
5242
5243 <result name="VBOX_E_INVALID_VM_STATE">
5244 Virtual machine is not mutable.
5245 </result>
5246 <result name="VBOX_E_OBJECT_NOT_FOUND">
5247 Shared folder @a name does not exist.
5248 </result>
5249
5250 </desc>
5251 <param name="name" type="wstring" dir="in">
5252 <desc>Logical name of the shared folder to remove.</desc>
5253 </param>
5254 </method>
5255
5256 <method name="canShowConsoleWindow">
5257 <desc>
5258 Returns @c true if the VM console process can activate the
5259 console window and bring it to foreground on the desktop of
5260 the host PC.
5261 <note>
5262 This method will fail if a session for this machine is not
5263 currently open.
5264 </note>
5265
5266 <result name="VBOX_E_INVALID_VM_STATE">
5267 Machine session is not open.
5268 </result>
5269
5270 </desc>
5271 <param name="canShow" type="boolean" dir="return">
5272 <desc>
5273 @c true if the console window can be shown and @c false otherwise.
5274 </desc>
5275 </param>
5276 </method>
5277
5278 <method name="showConsoleWindow">
5279 <desc>
5280 Activates the console window and brings it to foreground on
5281 the desktop of the host PC. Many modern window managers on
5282 many platforms implement some sort of focus stealing
5283 prevention logic, so that it may be impossible to activate
5284 a window without the help of the currently active
5285 application. In this case, this method will return a non-zero
5286 identifier that represents the top-level window of the VM
5287 console process. The caller, if it represents a currently
5288 active process, is responsible to use this identifier (in a
5289 platform-dependent manner) to perform actual window
5290 activation.
5291 <note>
5292 This method will fail if a session for this machine is not
5293 currently open.
5294 </note>
5295
5296 <result name="VBOX_E_INVALID_VM_STATE">
5297 Machine session is not open.
5298 </result>
5299
5300 </desc>
5301 <param name="winId" type="long long" dir="return">
5302 <desc>
5303 Platform-dependent identifier of the top-level VM console
5304 window, or zero if this method has performed all actions
5305 necessary to implement the <i>show window</i> semantics for
5306 the given platform and/or VirtualBox front-end.
5307 </desc>
5308 </param>
5309 </method>
5310
5311 <method name="getGuestProperty" const="yes">
5312 <desc>
5313 Reads an entry from the machine's guest property store.
5314
5315 <result name="VBOX_E_INVALID_VM_STATE">
5316 Machine session is not open.
5317 </result>
5318
5319 </desc>
5320 <param name="name" type="wstring" dir="in">
5321 <desc>
5322 The name of the property to read.
5323 </desc>
5324 </param>
5325 <param name="value" type="wstring" dir="out">
5326 <desc>
5327 The value of the property. If the property does not exist then this
5328 will be empty.
5329 </desc>
5330 </param>
5331 <param name="timestamp" type="long long" dir="out">
5332 <desc>
5333 The time at which the property was last modified, as seen by the
5334 server process.
5335 </desc>
5336 </param>
5337 <param name="flags" type="wstring" dir="out">
5338 <desc>
5339 Additional property parameters, passed as a comma-separated list of
5340 "name=value" type entries.
5341 </desc>
5342 </param>
5343 </method>
5344
5345 <method name="getGuestPropertyValue" const="yes">
5346 <desc>
5347 Reads a value from the machine's guest property store.
5348
5349 <result name="VBOX_E_INVALID_VM_STATE">
5350 Machine session is not open.
5351 </result>
5352
5353 </desc>
5354 <param name="property" type="wstring" dir="in">
5355 <desc>
5356 The name of the property to read.
5357 </desc>
5358 </param>
5359 <param name="value" type="wstring" dir="return">
5360 <desc>
5361 The value of the property. If the property does not exist then this
5362 will be empty.
5363 </desc>
5364 </param>
5365 </method>
5366
5367 <method name="getGuestPropertyTimestamp" const="yes">
5368 <desc>
5369 Reads a property timestamp from the machine's guest property store.
5370
5371 <result name="VBOX_E_INVALID_VM_STATE">
5372 Machine session is not open.
5373 </result>
5374
5375 </desc>
5376 <param name="property" type="wstring" dir="in">
5377 <desc>
5378 The name of the property to read.
5379 </desc>
5380 </param>
5381 <param name="value" type="long long" dir="return">
5382 <desc>
5383 The timestamp. If the property does not exist then this will be
5384 empty.
5385 </desc>
5386 </param>
5387 </method>
5388
5389 <method name="setGuestProperty">
5390 <desc>
5391 Sets, changes or deletes an entry in the machine's guest property
5392 store.
5393
5394 <result name="E_ACCESSDENIED">
5395 Property cannot be changed.
5396 </result>
5397 <result name="E_INVALIDARG">
5398 Invalid @a flags.
5399 </result>
5400 <result name="VBOX_E_INVALID_VM_STATE">
5401 Virtual machine is not mutable or session not open.
5402 </result>
5403 <result name="VBOX_E_INVALID_OBJECT_STATE">
5404 Cannot set transient property when machine not running.
5405 </result>
5406
5407 </desc>
5408 <param name="property" type="wstring" dir="in">
5409 <desc>
5410 The name of the property to set, change or delete.
5411 </desc>
5412 </param>
5413 <param name="value" type="wstring" dir="in">
5414 <desc>
5415 The new value of the property to set, change or delete. If the
5416 property does not yet exist and value is non-empty, it will be
5417 created. If the value is @c null or empty, the property will be
5418 deleted if it exists.
5419 </desc>
5420 </param>
5421 <param name="flags" type="wstring" dir="in">
5422 <desc>
5423 Additional property parameters, passed as a comma-separated list of
5424 "name=value" type entries.
5425 </desc>
5426 </param>
5427 </method>
5428
5429 <method name="setGuestPropertyValue">
5430 <desc>
5431 Sets, changes or deletes a value in the machine's guest property
5432 store. The flags field will be left unchanged or created empty for a
5433 new property.
5434
5435 <result name="E_ACCESSDENIED">
5436 Property cannot be changed.
5437 </result>
5438 <result name="VBOX_E_INVALID_VM_STATE">
5439 Virtual machine is not mutable or session not open.
5440 </result>
5441 <result name="VBOX_E_INVALID_OBJECT_STATE">
5442 Cannot set transient property when machine not running.
5443 </result>
5444 </desc>
5445
5446 <param name="property" type="wstring" dir="in">
5447 <desc>
5448 The name of the property to set, change or delete.
5449 </desc>
5450 </param>
5451 <param name="value" type="wstring" dir="in">
5452 <desc>
5453 The new value of the property to set, change or delete. If the
5454 property does not yet exist and value is non-empty, it will be
5455 created. If the value is @c null or empty, the property will be
5456 deleted if it exists.
5457 </desc>
5458 </param>
5459 </method>
5460
5461 <method name="enumerateGuestProperties">
5462 <desc>
5463 Return a list of the guest properties matching a set of patterns along
5464 with their values, time stamps and flags.
5465 </desc>
5466 <param name="patterns" type="wstring" dir="in">
5467 <desc>
5468 The patterns to match the properties against, separated by '|'
5469 characters. If this is empty or @c null, all properties will match.
5470 </desc>
5471 </param>
5472 <param name="name" type="wstring" dir="out" safearray="yes">
5473 <desc>
5474 The names of the properties returned.
5475 </desc>
5476 </param>
5477 <param name="value" type="wstring" dir="out" safearray="yes">
5478 <desc>
5479 The values of the properties returned. The array entries match the
5480 corresponding entries in the @a name array.
5481 </desc>
5482 </param>
5483 <param name="timestamp" type="long long" dir="out" safearray="yes">
5484 <desc>
5485 The time stamps of the properties returned. The array entries match
5486 the corresponding entries in the @a name array.
5487 </desc>
5488 </param>
5489 <param name="flags" type="wstring" dir="out" safearray="yes">
5490 <desc>
5491 The flags of the properties returned. The array entries match the
5492 corresponding entries in the @a name array.
5493 </desc>
5494 </param>
5495 </method>
5496
5497 <method name="querySavedGuestSize">
5498 <desc>
5499 Returns the guest dimensions from the saved state.
5500 </desc>
5501 <param name="screenId" type="unsigned long" dir="in">
5502 <desc>
5503 Saved guest screen to query info from.
5504 </desc>
5505 </param>
5506 <param name="width" type="unsigned long" dir="out">
5507 <desc>
5508 Guest width at the time of the saved state was taken.
5509 </desc>
5510 </param>
5511 <param name="height" type="unsigned long" dir="out">
5512 <desc>
5513 Guest height at the time of the saved state was taken.
5514 </desc>
5515 </param>
5516 </method>
5517
5518 <method name="querySavedThumbnailSize">
5519 <desc>
5520 Returns size in bytes and dimensions in pixels of a saved thumbnail bitmap from saved state.
5521 </desc>
5522 <param name="screenId" type="unsigned long" dir="in">
5523 <desc>
5524 Saved guest screen to query info from.
5525 </desc>
5526 </param>
5527 <param name="size" type="unsigned long" dir="out">
5528 <desc>
5529 Size of buffer required to store the bitmap.
5530 </desc>
5531 </param>
5532 <param name="width" type="unsigned long" dir="out">
5533 <desc>
5534 Bitmap width.
5535 </desc>
5536 </param>
5537 <param name="height" type="unsigned long" dir="out">
5538 <desc>
5539 Bitmap height.
5540 </desc>
5541 </param>
5542 </method>
5543
5544 <method name="readSavedThumbnailToArray">
5545 <desc>
5546 Thumbnail is retrieved to an array of bytes in uncompressed 32-bit BGRA or RGBA format.
5547 </desc>
5548 <param name="screenId" type="unsigned long" dir="in">
5549 <desc>
5550 Saved guest screen to read from.
5551 </desc>
5552 </param>
5553 <param name="BGR" type="boolean" dir="in">
5554 <desc>
5555 How to order bytes in the pixel. A pixel consists of 4 bytes. If this parameter is true, then
5556 bytes order is: B, G, R, 0xFF. If this parameter is false, then bytes order is: R, G, B, 0xFF.
5557 </desc>
5558 </param>
5559 <param name="width" type="unsigned long" dir="out">
5560 <desc>
5561 Bitmap width.
5562 </desc>
5563 </param>
5564 <param name="height" type="unsigned long" dir="out">
5565 <desc>
5566 Bitmap height.
5567 </desc>
5568 </param>
5569 <param name="data" type="octet" safearray="yes" dir="return">
5570 <desc>
5571 Array with resulting bitmap data.
5572 </desc>
5573 </param>
5574 </method>
5575
5576 <method name="readSavedThumbnailPNGToArray">
5577 <desc>
5578 Thumbnail in PNG format is retrieved to an array of bytes.
5579 </desc>
5580 <param name="screenId" type="unsigned long" dir="in">
5581 <desc>
5582 Saved guest screen to read from.
5583 </desc>
5584 </param>
5585 <param name="width" type="unsigned long" dir="out">
5586 <desc>
5587 Image width.
5588 </desc>
5589 </param>
5590 <param name="height" type="unsigned long" dir="out">
5591 <desc>
5592 Image height.
5593 </desc>
5594 </param>
5595 <param name="data" type="octet" dir="return" safearray="yes">
5596 <desc>
5597 Array with resulting PNG data.
5598 </desc>
5599 </param>
5600 </method>
5601
5602 <method name="querySavedScreenshotPNGSize">
5603 <desc>
5604 Returns size in bytes and dimensions of a saved PNG image of screenshot from saved state.
5605 </desc>
5606 <param name="screenId" type="unsigned long" dir="in">
5607 <desc>
5608 Saved guest screen to query info from.
5609 </desc>
5610 </param>
5611 <param name="size" type="unsigned long" dir="out">
5612 <desc>
5613 Size of buffer required to store the PNG binary data.
5614 </desc>
5615 </param>
5616 <param name="width" type="unsigned long" dir="out">
5617 <desc>
5618 Image width.
5619 </desc>
5620 </param>
5621 <param name="height" type="unsigned long" dir="out">
5622 <desc>
5623 Image height.
5624 </desc>
5625 </param>
5626 </method>
5627
5628 <method name="readSavedScreenshotPNGToArray">
5629 <desc>
5630 Screenshot in PNG format is retrieved to an array of bytes.
5631 </desc>
5632 <param name="screenId" type="unsigned long" dir="in">
5633 <desc>
5634 Saved guest screen to read from.
5635 </desc>
5636 </param>
5637 <param name="width" type="unsigned long" dir="out">
5638 <desc>
5639 Image width.
5640 </desc>
5641 </param>
5642 <param name="height" type="unsigned long" dir="out">
5643 <desc>
5644 Image height.
5645 </desc>
5646 </param>
5647 <param name="data" type="octet" dir="return" safearray="yes">
5648 <desc>
5649 Array with resulting PNG data.
5650 </desc>
5651 </param>
5652 </method>
5653
5654 <method name="hotPlugCPU">
5655 <desc>
5656 Plugs a CPU into the machine.
5657 </desc>
5658 <param name="cpu" type="unsigned long" dir="in">
5659 <desc>
5660 The CPU id to insert.
5661 </desc>
5662 </param>
5663 </method>
5664
5665 <method name="hotUnplugCPU">
5666 <desc>
5667 Removes a CPU from the machine.
5668 </desc>
5669 <param name="cpu" type="unsigned long" dir="in">
5670 <desc>
5671 The CPU id to remove.
5672 </desc>
5673 </param>
5674 </method>
5675
5676 <method name="getCPUStatus">
5677 <desc>
5678 Returns the current status of the given CPU.
5679 </desc>
5680 <param name="cpu" type="unsigned long" dir="in">
5681 <desc>
5682 The CPU id to check for.
5683 </desc>
5684 </param>
5685 <param name="attached" type="boolean" dir="return">
5686 <desc>
5687 Status of the CPU.
5688 </desc>
5689 </param>
5690 </method>
5691
5692 <method name="queryLogFilename">
5693 <desc>
5694 Queries for the VM log file name of an given index. Returns an empty
5695 string if a log file with that index doesn't exists.
5696 </desc>
5697 <param name="idx" type="unsigned long" dir="in">
5698 <desc>
5699 Which log file name to query. 0=current log file.
5700 </desc>
5701 </param>
5702 <param name="filename" type="wstring" dir="return">
5703 <desc>
5704 On return the full path to the log file or an empty string on error.
5705 </desc>
5706 </param>
5707 </method>
5708
5709 <method name="readLog">
5710 <desc>
5711 Reads the VM log file. The chunk size is limited, so even if you
5712 ask for a big piece there might be less data returned.
5713 </desc>
5714 <param name="idx" type="unsigned long" dir="in">
5715 <desc>
5716 Which log file to read. 0=current log file.
5717 </desc>
5718 </param>
5719 <param name="offset" type="long long" dir="in">
5720 <desc>
5721 Offset in the log file.
5722 </desc>
5723 </param>
5724 <param name="size" type="long long" dir="in">
5725 <desc>
5726 Chunk size to read in the log file.
5727 </desc>
5728 </param>
5729 <param name="data" type="octet" dir="return" safearray="yes">
5730 <desc>
5731 Data read from the log file. A data size of 0 means end of file
5732 if the requested chunk size was not 0. This is the unprocessed
5733 file data, i.e. the line ending style depends on the platform of
5734 the system the server is running on.
5735 </desc>
5736 </param>
5737 </method>
5738 </interface>
5739
5740 <!--
5741 // IConsole
5742 /////////////////////////////////////////////////////////////////////////
5743 -->
5744
5745 <interface
5746 name="IRemoteDisplayInfo" extends="$unknown"
5747 uuid="b3741084-806f-4c3b-8c42-ebad1a81e45a"
5748 wsmap="struct"
5749 >
5750 <desc>
5751 Contains information about the remote display (VRDP) capabilities and status.
5752 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
5753 </desc>
5754
5755 <attribute name="active" type="boolean" readonly="yes">
5756 <desc>
5757 Whether the remote display connection is active.
5758 </desc>
5759 </attribute>
5760
5761 <attribute name="port" type="long" readonly="yes">
5762 <desc>
5763 VRDP server port number. If this property is equal to <tt>0</tt>, then
5764 the VRDP server failed to start, usually because there are no free TCP
5765 ports to bind to. If this property is equal to <tt>-1</tt>, then the VRDP
5766 server has not yet been started.
5767 </desc>
5768 </attribute>
5769
5770 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
5771 <desc>
5772 How many times a client connected.
5773 </desc>
5774 </attribute>
5775
5776 <attribute name="beginTime" type="long long" readonly="yes">
5777 <desc>
5778 When the last connection was established, in milliseconds since 1970-01-01 UTC.
5779 </desc>
5780 </attribute>
5781
5782 <attribute name="endTime" type="long long" readonly="yes">
5783 <desc>
5784 When the last connection was terminated or the current time, if
5785 connection is still active, in milliseconds since 1970-01-01 UTC.
5786 </desc>
5787 </attribute>
5788
5789 <attribute name="bytesSent" type="long long" readonly="yes">
5790 <desc>
5791 How many bytes were sent in last or current, if still active, connection.
5792 </desc>
5793 </attribute>
5794
5795 <attribute name="bytesSentTotal" type="long long" readonly="yes">
5796 <desc>
5797 How many bytes were sent in all connections.
5798 </desc>
5799 </attribute>
5800
5801 <attribute name="bytesReceived" type="long long" readonly="yes">
5802 <desc>
5803 How many bytes were received in last or current, if still active, connection.
5804 </desc>
5805 </attribute>
5806
5807 <attribute name="bytesReceivedTotal" type="long long" readonly="yes">
5808 <desc>
5809 How many bytes were received in all connections.
5810 </desc>
5811 </attribute>
5812
5813 <attribute name="user" type="wstring" readonly="yes">
5814 <desc>
5815 Login user name supplied by the client.
5816 </desc>
5817 </attribute>
5818
5819 <attribute name="domain" type="wstring" readonly="yes">
5820 <desc>
5821 Login domain name supplied by the client.
5822 </desc>
5823 </attribute>
5824
5825 <attribute name="clientName" type="wstring" readonly="yes">
5826 <desc>
5827 The client name supplied by the client.
5828 </desc>
5829 </attribute>
5830
5831 <attribute name="clientIP" type="wstring" readonly="yes">
5832 <desc>
5833 The IP address of the client.
5834 </desc>
5835 </attribute>
5836
5837 <attribute name="clientVersion" type="unsigned long" readonly="yes">
5838 <desc>
5839 The client software version number.
5840 </desc>
5841 </attribute>
5842
5843 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
5844 <desc>
5845 Public key exchange method used when connection was established.
5846 Values: 0 - RDP4 public key exchange scheme.
5847 1 - X509 certificates were sent to client.
5848 </desc>
5849 </attribute>
5850
5851 </interface>
5852
5853 <interface
5854 name="IConsole" extends="$unknown"
5855 uuid="03cb7897-ea17-4e6c-81ae-4bd90be2fde2"
5856 wsmap="managed"
5857 >
5858 <desc>
5859 The IConsole interface represents an interface to control virtual
5860 machine execution.
5861
5862 A console object gets created when a machine has been locked for a
5863 particular session (client process) using <link to="IMachine::lockMachine" />
5864 or <link to="IMachine::launchVMProcess"/>. The console object can
5865 then be found in the session's <link to="ISession::console" /> attribute.
5866
5867 Methods of the IConsole interface allow the caller to query the current
5868 virtual machine execution state, pause the machine or power it down, save
5869 the machine state or take a snapshot, attach and detach removable media
5870 and so on.
5871
5872 <see>ISession</see>
5873 </desc>
5874
5875 <attribute name="machine" type="IMachine" readonly="yes">
5876 <desc>
5877 Machine object this console is sessioned with.
5878 <note>
5879 This is a convenience property, it has the same value as
5880 <link to="ISession::machine"/> of the corresponding session
5881 object.
5882 </note>
5883 </desc>
5884 </attribute>
5885
5886 <attribute name="state" type="MachineState" readonly="yes">
5887 <desc>
5888 Current execution state of the machine.
5889 <note>
5890 This property always returns the same value as the corresponding
5891 property of the IMachine object this console is sessioned with.
5892 For the process that owns (executes) the VM, this is the
5893 preferable way of querying the VM state, because no IPC
5894 calls are made.
5895 </note>
5896 </desc>
5897 </attribute>
5898
5899 <attribute name="guest" type="IGuest" readonly="yes">
5900 <desc>Guest object.</desc>
5901 </attribute>
5902
5903 <attribute name="keyboard" type="IKeyboard" readonly="yes">
5904 <desc>
5905 Virtual keyboard object.
5906 <note>
5907 If the machine is not running, any attempt to use
5908 the returned object will result in an error.
5909 </note>
5910 </desc>
5911 </attribute>
5912
5913 <attribute name="mouse" type="IMouse" readonly="yes">
5914 <desc>
5915 Virtual mouse object.
5916 <note>
5917 If the machine is not running, any attempt to use
5918 the returned object will result in an error.
5919 </note>
5920 </desc>
5921 </attribute>
5922
5923 <attribute name="display" type="IDisplay" readonly="yes">
5924 <desc>Virtual display object.
5925 <note>
5926 If the machine is not running, any attempt to use
5927 the returned object will result in an error.
5928 </note>
5929 </desc>
5930 </attribute>
5931
5932 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
5933 <desc>Debugging interface.</desc>
5934 </attribute>
5935
5936 <attribute name="USBDevices" type="IUSBDevice" readonly="yes" safearray="yes">
5937 <desc>
5938 Collection of USB devices currently attached to the virtual
5939 USB controller.
5940 <note>
5941 The collection is empty if the machine is not running.
5942 </note>
5943 </desc>
5944 </attribute>
5945
5946 <attribute name="remoteUSBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
5947 <desc>
5948 List of USB devices currently attached to the remote VRDP client.
5949 Once a new device is physically attached to the remote host computer,
5950 it appears in this list and remains there until detached.
5951 </desc>
5952 </attribute>
5953
5954 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
5955 <desc>
5956 Collection of shared folders for the current session. These folders
5957 are called transient shared folders because they are available to the
5958 guest OS running inside the associated virtual machine only for the
5959 duration of the session (as opposed to
5960 <link to="IMachine::sharedFolders"/> which represent permanent shared
5961 folders). When the session is closed (e.g. the machine is powered down),
5962 these folders are automatically discarded.
5963
5964 New shared folders are added to the collection using
5965 <link to="#createSharedFolder"/>. Existing shared folders can be
5966 removed using <link to="#removeSharedFolder"/>.
5967 </desc>
5968 </attribute>
5969
5970 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
5971 <desc>
5972 Interface that provides information on Remote Display (VRDP) connection.
5973 </desc>
5974 </attribute>
5975
5976 <attribute name="eventSource" type="IEventSource" readonly="yes">
5977 <desc>
5978 Event source for console events.
5979 </desc>
5980 </attribute>
5981
5982 <method name="powerUp">
5983 <desc>
5984 Starts the virtual machine execution using the current machine
5985 state (that is, its current execution state, current settings and
5986 current storage devices).
5987
5988 <note>
5989 This method is only useful for front-ends that want to actually
5990 execute virtual machines in their own process (like the VirtualBox
5991 or VBoxSDL front-ends). Unless you are intending to write such a
5992 front-end, do not call this method. If you simply want to
5993 start virtual machine execution using one of the existing front-ends
5994 (for example the VirtualBox GUI or headless server), use
5995 <link to="IMachine::launchVMProcess"/> instead; these
5996 front-ends will power up the machine automatically for you.
5997 </note>
5998
5999 If the machine is powered off or aborted, the execution will
6000 start from the beginning (as if the real hardware were just
6001 powered on).
6002
6003 If the machine is in the <link to="MachineState_Saved"/> state,
6004 it will continue its execution the point where the state has
6005 been saved.
6006
6007 If the machine <link to="IMachine::teleporterEnabled"/> property is
6008 enabled on the machine being powered up, the machine will wait for an
6009 incoming teleportation in the <link to="MachineState_TeleportingIn"/>
6010 state. The returned progress object will have at least three
6011 operations where the last three are defined as: (1) powering up and
6012 starting TCP server, (2) waiting for incoming teleportations, and
6013 (3) perform teleportation. These operations will be reflected as the
6014 last three operations of the progress objected returned by
6015 <link to="IMachine::launchVMProcess"/> as well.
6016
6017 <see>#saveState</see>
6018
6019 <result name="VBOX_E_INVALID_VM_STATE">
6020 Virtual machine already running.
6021 </result>
6022 <result name="VBOX_E_HOST_ERROR">
6023 Host interface does not exist or name not set.
6024 </result>
6025 <result name="VBOX_E_FILE_ERROR">
6026 Invalid saved state file.
6027 </result>
6028 </desc>
6029 <param name="progress" type="IProgress" dir="return">
6030 <desc>Progress object to track the operation completion.</desc>
6031 </param>
6032 </method>
6033
6034 <method name="powerUpPaused">
6035 <desc>
6036 Identical to powerUp except that the VM will enter the
6037 <link to="MachineState_Paused"/> state, instead of
6038 <link to="MachineState_Running"/>.
6039
6040 <see>#powerUp</see>
6041 <result name="VBOX_E_INVALID_VM_STATE">
6042 Virtual machine already running.
6043 </result>
6044 <result name="VBOX_E_HOST_ERROR">
6045 Host interface does not exist or name not set.
6046 </result>
6047 <result name="VBOX_E_FILE_ERROR">
6048 Invalid saved state file.
6049 </result>
6050 </desc>
6051 <param name="progress" type="IProgress" dir="return">
6052 <desc>Progress object to track the operation completion.</desc>
6053 </param>
6054 </method>
6055
6056 <method name="powerDown">
6057 <desc>
6058 Initiates the power down procedure to stop the virtual machine
6059 execution.
6060
6061 The completion of the power down procedure is tracked using the returned
6062 IProgress object. After the operation is complete, the machine will go
6063 to the PoweredOff state.
6064 <result name="VBOX_E_INVALID_VM_STATE">
6065 Virtual machine must be Running, Paused or Stuck to be powered down.
6066 </result>
6067 </desc>
6068 <param name="progress" type="IProgress" dir="return">
6069 <desc>Progress object to track the operation completion.</desc>
6070 </param>
6071 </method>
6072
6073 <method name="reset">
6074 <desc>Resets the virtual machine.
6075 <result name="VBOX_E_INVALID_VM_STATE">
6076 Virtual machine not in Running state.
6077 </result>
6078 <result name="VBOX_E_VM_ERROR">
6079 Virtual machine error in reset operation.
6080 </result>
6081 </desc>
6082 </method>
6083
6084 <method name="pause">
6085 <desc>Pauses the virtual machine execution.
6086 <result name="VBOX_E_INVALID_VM_STATE">
6087 Virtual machine not in Running state.
6088 </result>
6089 <result name="VBOX_E_VM_ERROR">
6090 Virtual machine error in suspend operation.
6091 </result>
6092 </desc>
6093 </method>
6094
6095 <method name="resume">
6096 <desc>Resumes the virtual machine execution.
6097 <result name="VBOX_E_INVALID_VM_STATE">
6098 Virtual machine not in Paused state.
6099 </result>
6100 <result name="VBOX_E_VM_ERROR">
6101 Virtual machine error in resume operation.
6102 </result>
6103 </desc>
6104 </method>
6105
6106 <method name="powerButton">
6107 <desc>Sends the ACPI power button event to the guest.
6108 <result name="VBOX_E_INVALID_VM_STATE">
6109 Virtual machine not in Running state.
6110 </result>
6111 <result name="VBOX_E_PDM_ERROR">
6112 Controlled power off failed.
6113 </result>
6114 </desc>
6115 </method>
6116
6117 <method name="sleepButton">
6118 <desc>Sends the ACPI sleep button event to the guest.
6119 <result name="VBOX_E_INVALID_VM_STATE">
6120 Virtual machine not in Running state.
6121 </result>
6122 <result name="VBOX_E_PDM_ERROR">
6123 Sending sleep button event failed.
6124 </result>
6125 </desc>
6126 </method>
6127
6128 <method name="getPowerButtonHandled">
6129 <desc>Checks if the last power button event was handled by guest.
6130 <result name="VBOX_E_PDM_ERROR">
6131 Checking if the event was handled by the guest OS failed.
6132 </result>
6133 </desc>
6134 <param name="handled" type="boolean" dir="return"/>
6135 </method>
6136
6137 <method name="getGuestEnteredACPIMode">
6138 <desc>Checks if the guest entered the ACPI mode G0 (working) or
6139 G1 (sleeping). If this method returns @c false, the guest will
6140 most likely not respond to external ACPI events.
6141 <result name="VBOX_E_INVALID_VM_STATE">
6142 Virtual machine not in Running state.
6143 </result>
6144 </desc>
6145 <param name="entered" type="boolean" dir="return"/>
6146 </method>
6147
6148 <method name="saveState">
6149 <desc>
6150 Saves the current execution state of a running virtual machine
6151 and stops its execution.
6152
6153 After this operation completes, the machine will go to the
6154 Saved state. Next time it is powered up, this state will
6155 be restored and the machine will continue its execution from
6156 the place where it was saved.
6157
6158 This operation differs from taking a snapshot to the effect
6159 that it doesn't create new differencing media. Also, once
6160 the machine is powered up from the state saved using this method,
6161 the saved state is deleted, so it will be impossible to return
6162 to this state later.
6163
6164 <note>
6165 On success, this method implicitly calls
6166 <link to="IMachine::saveSettings"/> to save all current machine
6167 settings (including runtime changes to the DVD medium, etc.).
6168 Together with the impossibility to change any VM settings when it is
6169 in the Saved state, this guarantees adequate hardware
6170 configuration of the machine when it is restored from the saved
6171 state file.
6172 </note>
6173
6174 <note>
6175 The machine must be in the Running or Paused state, otherwise
6176 the operation will fail.
6177 </note>
6178 <result name="VBOX_E_INVALID_VM_STATE">
6179 Virtual machine state neither Running nor Paused.
6180 </result>
6181 <result name="VBOX_E_FILE_ERROR">
6182 Failed to create directory for saved state file.
6183 </result>
6184
6185 <see><link to="#takeSnapshot"/></see>
6186 </desc>
6187 <param name="progress" type="IProgress" dir="return">
6188 <desc>Progress object to track the operation completion.</desc>
6189 </param>
6190 </method>
6191
6192 <method name="adoptSavedState">
6193 <desc>
6194 Associates the given saved state file to the virtual machine.
6195
6196 On success, the machine will go to the Saved state. Next time it is
6197 powered up, it will be restored from the adopted saved state and
6198 continue execution from the place where the saved state file was
6199 created.
6200
6201 The specified saved state file path may be absolute or relative to the
6202 folder the VM normally saves the state to (usually,
6203 <link to="IMachine::snapshotFolder"/>).
6204
6205 <note>
6206 It's a caller's responsibility to make sure the given saved state
6207 file is compatible with the settings of this virtual machine that
6208 represent its virtual hardware (memory size, storage disk configuration
6209 etc.). If there is a mismatch, the behavior of the virtual machine
6210 is undefined.
6211 </note>
6212 <result name="VBOX_E_INVALID_VM_STATE">
6213 Virtual machine state neither PoweredOff nor Aborted.
6214 </result>
6215 </desc>
6216 <param name="savedStateFile" type="wstring" dir="in">
6217 <desc>Path to the saved state file to adopt.</desc>
6218 </param>
6219 </method>
6220
6221 <method name="discardSavedState">
6222 <desc>
6223 Forcibly resets the machine to "Powered Off" state if it is
6224 currently in the "Saved" state (previously created by <link to="#saveState"/>).
6225 Next time the machine is powered up, a clean boot will occur.
6226 <note>
6227 This operation is equivalent to resetting or powering off
6228 the machine without doing a proper shutdown of the guest
6229 operating system; as with resetting a running phyiscal
6230 computer, it can can lead to data loss.
6231 </note>
6232 If @a fRemoveFile is @c true, the file in the machine directory
6233 into which the machine state was saved is also deleted. If
6234 this is @c false, then the state can be recovered and later
6235 re-inserted into a machine using <link to="#adoptSavedState" />.
6236 The location of the file can be found in the
6237 <link to="IMachine::stateFilePath" /> attribute.
6238 <result name="VBOX_E_INVALID_VM_STATE">
6239 Virtual machine not in state Saved.
6240 </result>
6241 </desc>
6242 <param name="fRemoveFile" type="boolean" dir="in" >
6243 <desc>Whether to also remove the saved state file.</desc>
6244 </param>
6245 </method>
6246
6247 <method name="getDeviceActivity">
6248 <desc>
6249 Gets the current activity type of a given device or device group.
6250 <result name="E_INVALIDARG">
6251 Invalid device type.
6252 </result>
6253 </desc>
6254 <param name="type" type="DeviceType" dir="in"/>
6255 <param name="activity" type="DeviceActivity" dir="return"/>
6256 </method>
6257
6258 <method name="attachUSBDevice">
6259 <desc>
6260 Attaches a host USB device with the given UUID to the
6261 USB controller of the virtual machine.
6262
6263 The device needs to be in one of the following states:
6264 <link to="USBDeviceState_Busy"/>,
6265 <link to="USBDeviceState_Available"/> or
6266 <link to="USBDeviceState_Held"/>,
6267 otherwise an error is immediately returned.
6268
6269 When the device state is
6270 <link to="USBDeviceState_Busy">Busy</link>, an error may also
6271 be returned if the host computer refuses to release it for some reason.
6272
6273 <see>IUSBController::deviceFilters, USBDeviceState</see>
6274 <result name="VBOX_E_INVALID_VM_STATE">
6275 Virtual machine state neither Running nor Paused.
6276 </result>
6277 <result name="VBOX_E_PDM_ERROR">
6278 Virtual machine does not have a USB controller.
6279 </result>
6280 </desc>
6281 <param name="id" type="uuid" mod="string" dir="in">
6282 <desc>UUID of the host USB device to attach.</desc>
6283 </param>
6284 </method>
6285
6286 <method name="detachUSBDevice">
6287 <desc>
6288 Detaches an USB device with the given UUID from the USB controller
6289 of the virtual machine.
6290
6291 After this method succeeds, the VirtualBox server re-initiates
6292 all USB filters as if the device were just physically attached
6293 to the host, but filters of this machine are ignored to avoid
6294 a possible automatic re-attachment.
6295
6296 <see>IUSBController::deviceFilters, USBDeviceState</see>
6297
6298 <result name="VBOX_E_PDM_ERROR">
6299 Virtual machine does not have a USB controller.
6300 </result>
6301 <result name="E_INVALIDARG">
6302 USB device not attached to this virtual machine.
6303 </result>
6304 </desc>
6305 <param name="id" type="uuid" mod="string" dir="in">
6306 <desc>UUID of the USB device to detach.</desc>
6307 </param>
6308 <param name="device" type="IUSBDevice" dir="return">
6309 <desc>Detached USB device.</desc>
6310 </param>
6311 </method>
6312
6313 <method name="findUSBDeviceByAddress">
6314 <desc>
6315 Searches for a USB device with the given host address.
6316
6317 <result name="VBOX_E_OBJECT_NOT_FOUND">
6318 Given @c name does not correspond to any USB device.
6319 </result>
6320
6321 <see>IUSBDevice::address</see>
6322 </desc>
6323 <param name="name" type="wstring" dir="in">
6324 <desc>
6325 Address of the USB device (as assigned by the host) to
6326 search for.
6327 </desc>
6328 </param>
6329 <param name="device" type="IUSBDevice" dir="return">
6330 <desc>Found USB device object.</desc>
6331 </param>
6332 </method>
6333
6334 <method name="findUSBDeviceById">
6335 <desc>
6336 Searches for a USB device with the given UUID.
6337
6338 <result name="VBOX_E_OBJECT_NOT_FOUND">
6339 Given @c id does not correspond to any USB device.
6340 </result>
6341
6342 <see>IUSBDevice::id</see>
6343 </desc>
6344 <param name="id" type="uuid" mod="string" dir="in">
6345 <desc>UUID of the USB device to search for.</desc>
6346 </param>
6347 <param name="device" type="IUSBDevice" dir="return">
6348 <desc>Found USB device object.</desc>
6349 </param>
6350 </method>
6351
6352 <method name="createSharedFolder">
6353 <desc>
6354 Creates a transient new shared folder by associating the given logical
6355 name with the given host path, adds it to the collection of shared
6356 folders and starts sharing it. Refer to the description of
6357 <link to="ISharedFolder"/> to read more about logical names.
6358
6359 <result name="VBOX_E_INVALID_VM_STATE">
6360 Virtual machine in Saved state or currently changing state.
6361 </result>
6362 <result name="VBOX_E_FILE_ERROR">
6363 Shared folder already exists or not accessible.
6364 </result>
6365 </desc>
6366 <param name="name" type="wstring" dir="in">
6367 <desc>Unique logical name of the shared folder.</desc>
6368 </param>
6369 <param name="hostPath" type="wstring" dir="in">
6370 <desc>Full path to the shared folder in the host file system.</desc>
6371 </param>
6372 <param name="writable" type="boolean" dir="in">
6373 <desc>Whether the share is writable or readonly</desc>
6374 </param>
6375 <param name="automount" type="boolean" dir="in">
6376 <desc>Whether the share gets automatically mounted by the guest
6377 or not.</desc>
6378 </param>
6379 </method>
6380
6381 <method name="removeSharedFolder">
6382 <desc>
6383 Removes a transient shared folder with the given name previously
6384 created by <link to="#createSharedFolder"/> from the collection of
6385 shared folders and stops sharing it.
6386 <result name="VBOX_E_INVALID_VM_STATE">
6387 Virtual machine in Saved state or currently changing state.
6388 </result>
6389 <result name="VBOX_E_FILE_ERROR">
6390 Shared folder does not exists.
6391 </result>
6392 </desc>
6393 <param name="name" type="wstring" dir="in">
6394 <desc>Logical name of the shared folder to remove.</desc>
6395 </param>
6396 </method>
6397
6398 <method name="takeSnapshot">
6399 <desc>
6400 Saves the current execution state
6401 and all settings of the machine and creates differencing images
6402 for all normal (non-independent) media.
6403 See <link to="ISnapshot" /> for an introduction to snapshots.
6404
6405 This method can be called for a PoweredOff, Saved (see
6406 <link to="#saveState"/>), Running or
6407 Paused virtual machine. When the machine is PoweredOff, an
6408 offline snapshot is created. When the machine is Running a live
6409 snapshot is created, and an online snapshot is is created when Paused.
6410
6411 The taken snapshot is always based on the
6412 <link to="IMachine::currentSnapshot">current snapshot</link>
6413 of the associated virtual machine and becomes a new current snapshot.
6414
6415 <note>
6416 This method implicitly calls <link to="IMachine::saveSettings"/> to
6417 save all current machine settings before taking an offline snapshot.
6418 </note>
6419
6420 <result name="VBOX_E_INVALID_VM_STATE">
6421 Virtual machine currently changing state.
6422 </result>
6423 </desc>
6424 <param name="name" type="wstring" dir="in">
6425 <desc>Short name for the snapshot.</desc>
6426 </param>
6427 <param name="description" type="wstring" dir="in">
6428 <desc>Optional description of the snapshot.</desc>
6429 </param>
6430 <param name="progress" type="IProgress" dir="return">
6431 <desc>Progress object to track the operation completion.</desc>
6432 </param>
6433 </method>
6434
6435 <method name="deleteSnapshot">
6436 <desc>
6437 Starts deleting the specified snapshot asynchronously.
6438 See <link to="ISnapshot" /> for an introduction to snapshots.
6439
6440 The execution state and settings of the associated machine stored in
6441 the snapshot will be deleted. The contents of all differencing media of
6442 this snapshot will be merged with the contents of their dependent child
6443 media to keep the medium chain valid (in other words, all changes
6444 represented by media being deleted will be propagated to their child
6445 medium). After that, this snapshot's differencing medium will be
6446 deleted. The parent of this snapshot will become a new parent for all
6447 its child snapshots.
6448
6449 If the deleted snapshot is the current one, its parent snapshot will
6450 become a new current snapshot. The current machine state is not directly
6451 affected in this case, except that currently attached differencing
6452 media based on media of the deleted snapshot will be also merged as
6453 described above.
6454
6455 If the deleted snapshot is the first or current snapshot, then the
6456 respective IMachine attributes will be adjusted. Deleting the current
6457 snapshot will also implicitly call <link to="IMachine::saveSettings"/>
6458 to make all current machine settings permanent.
6459
6460 Deleting a snapshot has the following preconditions:
6461
6462 <ul>
6463 <li>Child media of all normal media of the deleted snapshot
6464 must be accessible (see <link to="IMedium::state"/>) for this
6465 operation to succeed. In particular, this means that all virtual
6466 machines, whose media are directly or indirectly based on the
6467 media of deleted snapshot, must be powered off.</li>
6468
6469 <li>You cannot delete the snapshot if a medium attached to it has
6470 more than once child medium (differencing images) because otherwise
6471 merging would be impossible. This might be the case if there is
6472 more than one child snapshot or differencing images were created
6473 for other reason (e.g. implicitly because of multiple machine
6474 attachments).</li>
6475 </ul>
6476
6477
6478 The virtual machine's <link to="IMachine::state">state</link> is
6479 changed to "DeletingSnapshot", "DeletingSnapshotOnline" or
6480 "DeletingSnapshotPaused" while this operation is in progress.
6481
6482 <note>
6483 Merging medium contents can be very time and disk space
6484 consuming, if these media are big in size and have many
6485 children. However, if the snapshot being deleted is the last
6486 (head) snapshot on the branch, the operation will be rather
6487 quick.
6488 </note>
6489 <result name="VBOX_E_INVALID_VM_STATE">
6490 The running virtual machine prevents deleting this snapshot. This
6491 happens only in very specific situations, usually snapshots can be
6492 deleted without trouble while a VM is running. The error message
6493 text explains the reason for the failure.
6494 </result>
6495 </desc>
6496 <param name="id" type="uuid" mod="string" dir="in">
6497 <desc>UUID of the snapshot to delete.</desc>
6498 </param>
6499 <param name="progress" type="IProgress" dir="return">
6500 <desc>Progress object to track the operation completion.</desc>
6501 </param>
6502 </method>
6503
6504 <method name="restoreSnapshot">
6505 <desc>
6506 Starts resetting the machine's current state to the state contained
6507 in the given snapshot, asynchronously. All current settings of the
6508 machine will be reset and changes stored in differencing media
6509 will be lost.
6510 See <link to="ISnapshot" /> for an introduction to snapshots.
6511
6512 After this operation is successfully completed, new empty differencing
6513 media are created for all normal media of the machine.
6514
6515 If the given snapshot is an online snapshot, the machine will go to
6516 the <link to="MachineState_Saved"> saved state</link>, so that the
6517 next time it is powered on, the execution state will be restored
6518 from the state of the snapshot.
6519
6520 <note>
6521 The machine must not be running, otherwise the operation will fail.
6522 </note>
6523
6524 <note>
6525 If the machine state is <link to="MachineState_Saved">Saved</link>
6526 prior to this operation, the saved state file will be implicitly
6527 deleted (as if <link to="IConsole::discardSavedState"/> were
6528 called).
6529 </note>
6530
6531 <result name="VBOX_E_INVALID_VM_STATE">
6532 Virtual machine is running.
6533 </result>
6534 </desc>
6535 <param name="snapshot" type="ISnapshot" dir="in">
6536 <desc>The snapshot to restore the VM state from.</desc>
6537 </param>
6538 <param name="progress" type="IProgress" dir="return">
6539 <desc>Progress object to track the operation completion.</desc>
6540 </param>
6541 </method>
6542
6543 <method name="teleport">
6544 <desc>
6545 Teleport the VM to a different host machine or process.
6546
6547 TODO explain the details.
6548
6549 <result name="VBOX_E_INVALID_VM_STATE">
6550 Virtual machine not running or paused.
6551 </result>
6552 </desc>
6553 <param name="hostname" type="wstring" dir="in">
6554 <desc>The name or IP of the host to teleport to.</desc>
6555 </param>
6556 <param name="tcpport" type="unsigned long" dir="in">
6557 <desc>The TCP port to connect to (1..65535).</desc>
6558 </param>
6559 <param name="password" type="wstring" dir="in">
6560 <desc>The password.</desc>
6561 </param>
6562 <param name="maxDowntime" type="unsigned long" dir="in">
6563 <desc>
6564 The maximum allowed downtime given as milliseconds. 0 is not a valid
6565 value. Recommended value: 250 ms.
6566
6567 The higher the value is, the greater the chance for a successful
6568 teleportation. A small value may easily result in the teleportation
6569 process taking hours and eventually fail.
6570
6571 <note>
6572 The current implementation treats this a guideline, not as an
6573 absolute rule.
6574 </note>
6575 </desc>
6576 </param>
6577 <param name="progress" type="IProgress" dir="return">
6578 <desc>Progress object to track the operation completion.</desc>
6579 </param>
6580 </method>
6581
6582 </interface>
6583
6584 <!--
6585 // IHost
6586 /////////////////////////////////////////////////////////////////////////
6587 -->
6588
6589 <enum
6590 name="HostNetworkInterfaceMediumType"
6591 uuid="1aa54aaf-2497-45a2-bfb1-8eb225e93d5b"
6592 >
6593 <desc>
6594 Type of encapsulation. Ethernet encapsulation includes both wired and
6595 wireless Ethernet connections.
6596 <see>IHostNetworkInterface</see>
6597 </desc>
6598
6599 <const name="Unknown" value="0">
6600 <desc>
6601 The type of interface cannot be determined.
6602 </desc>
6603 </const>
6604 <const name="Ethernet" value="1">
6605 <desc>
6606 Ethernet frame encapsulation.
6607 </desc>
6608 </const>
6609 <const name="PPP" value="2">
6610 <desc>
6611 Point-to-point protocol encapsulation.
6612 </desc>
6613 </const>
6614 <const name="SLIP" value="3">
6615 <desc>
6616 Serial line IP encapsulation.
6617 </desc>
6618 </const>
6619 </enum>
6620
6621 <enum
6622 name="HostNetworkInterfaceStatus"
6623 uuid="CC474A69-2710-434B-8D99-C38E5D5A6F41"
6624 >
6625 <desc>
6626 Current status of the interface.
6627 <see>IHostNetworkInterface</see>
6628 </desc>
6629
6630 <const name="Unknown" value="0">
6631 <desc>
6632 The state of interface cannot be determined.
6633 </desc>
6634 </const>
6635 <const name="Up" value="1">
6636 <desc>
6637 The interface is fully operational.
6638 </desc>
6639 </const>
6640 <const name="Down" value="2">
6641 <desc>
6642 The interface is not functioning.
6643 </desc>
6644 </const>
6645 </enum>
6646
6647 <enum
6648 name="HostNetworkInterfaceType"
6649 uuid="67431b00-9946-48a2-bc02-b25c5919f4f3"
6650 >
6651 <desc>
6652 Network interface type.
6653 </desc>
6654 <const name="Bridged" value="1"/>
6655 <const name="HostOnly" value="2"/>
6656 </enum>
6657
6658 <interface
6659 name="IHostNetworkInterface" extends="$unknown"
6660 uuid="ce6fae58-7642-4102-b5db-c9005c2320a8"
6661 wsmap="managed"
6662 >
6663 <desc>
6664 Represents one of host's network interfaces. IP V6 address and network
6665 mask are strings of 32 hexdecimal digits grouped by four. Groups are
6666 separated by colons.
6667 For example, fe80:0000:0000:0000:021e:c2ff:fed2:b030.
6668 </desc>
6669 <attribute name="name" type="wstring" readonly="yes">
6670 <desc>Returns the host network interface name.</desc>
6671 </attribute>
6672
6673 <attribute name="id" type="uuid" mod="string" readonly="yes">
6674 <desc>Returns the interface UUID.</desc>
6675 </attribute>
6676
6677 <attribute name="networkName" type="wstring" readonly="yes">
6678 <desc>Returns the name of a virtual network the interface gets attached to.</desc>
6679 </attribute>
6680
6681 <attribute name="dhcpEnabled" type="boolean" readonly="yes">
6682 <desc>Specifies whether the DHCP is enabled for the interface.</desc>
6683 </attribute>
6684
6685 <attribute name="IPAddress" type="wstring" readonly="yes">
6686 <desc>Returns the IP V4 address of the interface.</desc>
6687 </attribute>
6688
6689 <attribute name="networkMask" type="wstring" readonly="yes">
6690 <desc>Returns the network mask of the interface.</desc>
6691 </attribute>
6692
6693 <attribute name="IPV6Supported" type="boolean" readonly="yes">
6694 <desc>Specifies whether the IP V6 is supported/enabled for the interface.</desc>
6695 </attribute>
6696
6697 <attribute name="IPV6Address" type="wstring" readonly="yes">
6698 <desc>Returns the IP V6 address of the interface.</desc>
6699 </attribute>
6700
6701 <attribute name="IPV6NetworkMaskPrefixLength" type="unsigned long" readonly="yes">
6702 <desc>Returns the length IP V6 network mask prefix of the interface.</desc>
6703 </attribute>
6704
6705 <attribute name="hardwareAddress" type="wstring" readonly="yes">
6706 <desc>Returns the hardware address. For Ethernet it is MAC address.</desc>
6707 </attribute>
6708
6709 <attribute name="mediumType" type="HostNetworkInterfaceMediumType" readonly="yes">
6710 <desc>Type of protocol encapsulation used.</desc>
6711 </attribute>
6712
6713 <attribute name="status" type="HostNetworkInterfaceStatus" readonly="yes">
6714 <desc>Status of the interface.</desc>
6715 </attribute>
6716
6717 <attribute name="interfaceType" type="HostNetworkInterfaceType" readonly="yes">
6718 <desc>specifies the host interface type.</desc>
6719 </attribute>
6720
6721 <method name="enableStaticIpConfig">
6722 <desc>sets and enables the static IP V4 configuration for the given interface.</desc>
6723 <param name="IPAddress" type="wstring" dir="in">
6724 <desc>
6725 IP address.
6726 </desc>
6727 </param>
6728 <param name="networkMask" type="wstring" dir="in">
6729 <desc>
6730 network mask.
6731 </desc>
6732 </param>
6733 </method>
6734
6735 <method name="enableStaticIpConfigV6">
6736 <desc>sets and enables the static IP V6 configuration for the given interface.</desc>
6737 <param name="IPV6Address" type="wstring" dir="in">
6738 <desc>
6739 IP address.
6740 </desc>
6741 </param>
6742 <param name="IPV6NetworkMaskPrefixLength" type="unsigned long" dir="in">
6743 <desc>
6744 network mask.
6745 </desc>
6746 </param>
6747 </method>
6748
6749 <method name="enableDynamicIpConfig">
6750 <desc>enables the dynamic IP configuration.</desc>
6751 </method>
6752
6753 <method name="dhcpRediscover">
6754 <desc>refreshes the IP configuration for dhcp-enabled interface.</desc>
6755 </method>
6756
6757 </interface>
6758
6759 <interface
6760 name="IHost" extends="$unknown"
6761 uuid="35b004f4-7806-4009-bfa8-d1308adba7e5"
6762 wsmap="managed"
6763 >
6764 <desc>
6765 The IHost interface represents the physical machine that this VirtualBox
6766 installation runs on.
6767
6768 An object implementing this interface is returned by the
6769 <link to="IVirtualBox::host" /> attribute. This interface contains
6770 read-only information about the host's physical hardware (such as what
6771 processors and disks are available, what the host operating system is,
6772 and so on) and also allows for manipulating some of the host's hardware,
6773 such as global USB device filters and host interface networking.
6774
6775 </desc>
6776 <attribute name="DVDDrives" type="IMedium" readonly="yes" safearray="yes">
6777 <desc>List of DVD drives available on the host.</desc>
6778 </attribute>
6779
6780 <attribute name="floppyDrives" type="IMedium" readonly="yes" safearray="yes">
6781 <desc>List of floppy drives available on the host.</desc>
6782 </attribute>
6783
6784 <attribute name="USBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
6785 <desc>
6786 List of USB devices currently attached to the host.
6787 Once a new device is physically attached to the host computer,
6788 it appears in this list and remains there until detached.
6789
6790 <note>
6791 If USB functionality is not available in the given edition of
6792 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6793 </note>
6794 </desc>
6795 </attribute>
6796
6797 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilter" readonly="yes" safearray="yes">
6798 <desc>
6799 List of USB device filters in action.
6800 When a new device is physically attached to the host computer,
6801 filters from this list are applied to it (in order they are stored
6802 in the list). The first matched filter will determine the
6803 <link to="IHostUSBDeviceFilter::action">action</link>
6804 performed on the device.
6805
6806 Unless the device is ignored by these filters, filters of all
6807 currently running virtual machines
6808 (<link to="IUSBController::deviceFilters"/>) are applied to it.
6809
6810 <note>
6811 If USB functionality is not available in the given edition of
6812 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6813 </note>
6814
6815 <see>IHostUSBDeviceFilter, USBDeviceState</see>
6816 </desc>
6817 </attribute>
6818
6819 <attribute name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" readonly="yes">
6820 <desc>List of host network interfaces currently defined on the host.</desc>
6821 </attribute>
6822
6823 <attribute name="processorCount" type="unsigned long" readonly="yes">
6824 <desc>Number of (logical) CPUs installed in the host system.</desc>
6825 </attribute>
6826
6827 <attribute name="processorOnlineCount" type="unsigned long" readonly="yes">
6828 <desc>Number of (logical) CPUs online in the host system.</desc>
6829 </attribute>
6830
6831 <attribute name="processorCoreCount" type="unsigned long" readonly="yes">
6832 <desc>Number of physical processor cores installed in the host system.</desc>
6833 </attribute>
6834
6835 <method name="getProcessorSpeed">
6836 <desc>Query the (approximate) maximum speed of a specified host CPU in
6837 Megahertz.
6838 </desc>
6839 <param name="cpuId" type="unsigned long" dir="in">
6840 <desc>
6841 Identifier of the CPU.
6842 </desc>
6843 </param>
6844 <param name="speed" type="unsigned long" dir="return">
6845 <desc>
6846 Speed value. 0 is returned if value is not known or @a cpuId is
6847 invalid.
6848 </desc>
6849 </param>
6850 </method>
6851
6852 <method name="getProcessorFeature">
6853 <desc>Query whether a CPU feature is supported or not.</desc>
6854 <param name="feature" type="ProcessorFeature" dir="in">
6855 <desc>
6856 CPU Feature identifier.
6857 </desc>
6858 </param>
6859 <param name="supported" type="boolean" dir="return">
6860 <desc>
6861 Feature is supported or not.
6862 </desc>
6863 </param>
6864 </method>
6865
6866 <method name="getProcessorDescription">
6867 <desc>Query the model string of a specified host CPU.
6868 </desc>
6869 <param name="cpuId" type="unsigned long" dir="in">
6870 <desc>
6871 Identifier of the CPU.
6872 <note>
6873 The current implementation might not necessarily return the
6874 description for this exact CPU.
6875 </note>
6876 </desc>
6877 </param>
6878 <param name="description" type="wstring" dir="return">
6879 <desc>
6880 Model string. An empty string is returned if value is not known or
6881 @a cpuId is invalid.
6882 </desc>
6883 </param>
6884 </method>
6885
6886 <method name="getProcessorCPUIDLeaf">
6887 <desc>
6888 Returns the CPU cpuid information for the specified leaf.
6889 </desc>
6890 <param name="cpuId" type="unsigned long" dir="in">
6891 <desc>
6892 Identifier of the CPU. The CPU most be online.
6893 <note>
6894 The current implementation might not necessarily return the
6895 description for this exact CPU.
6896 </note>
6897 </desc>
6898 </param>
6899 <param name="leaf" type="unsigned long" dir="in">
6900 <desc>
6901 CPUID leaf index (eax).
6902 </desc>
6903 </param>
6904 <param name="subLeaf" type="unsigned long" dir="in">
6905 <desc>
6906 CPUID leaf sub index (ecx). This currently only applies to cache
6907 information on Intel CPUs. Use 0 if retriving values for
6908 <link to="IMachine::setCPUIDLeaf"/>.
6909 </desc>
6910 </param>
6911 <param name="valEax" type="unsigned long" dir="out">
6912 <desc>
6913 CPUID leaf value for register eax.
6914 </desc>
6915 </param>
6916 <param name="valEbx" type="unsigned long" dir="out">
6917 <desc>
6918 CPUID leaf value for register ebx.
6919 </desc>
6920 </param>
6921 <param name="valEcx" type="unsigned long" dir="out">
6922 <desc>
6923 CPUID leaf value for register ecx.
6924 </desc>
6925 </param>
6926 <param name="valEdx" type="unsigned long" dir="out">
6927 <desc>
6928 CPUID leaf value for register edx.
6929 </desc>
6930 </param>
6931 </method>
6932
6933 <attribute name="memorySize" type="unsigned long" readonly="yes">
6934 <desc>Amount of system memory in megabytes installed in the host system.</desc>
6935 </attribute>
6936
6937 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
6938 <desc>Available system memory in the host system.</desc>
6939 </attribute>
6940
6941 <attribute name="operatingSystem" type="wstring" readonly="yes">
6942 <desc>Name of the host system's operating system.</desc>
6943 </attribute>
6944
6945 <attribute name="OSVersion" type="wstring" readonly="yes">
6946 <desc>Host operating system's version string.</desc>
6947 </attribute>
6948
6949 <attribute name="UTCTime" type="long long" readonly="yes">
6950 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
6951 </attribute>
6952
6953 <attribute name="Acceleration3DAvailable" type="boolean" readonly="yes">
6954 <desc>Returns @c true when the host supports 3D hardware acceleration.</desc>
6955 </attribute>
6956
6957 <method name="createHostOnlyNetworkInterface">
6958 <desc>
6959 Creates a new adapter for Host Only Networking.
6960 <result name="E_INVALIDARG">
6961 Host network interface @a name already exists.
6962 </result>
6963 </desc>
6964 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
6965 <desc>
6966 Created host interface object.
6967 </desc>
6968 </param>
6969 <param name="progress" type="IProgress" dir="return">
6970 <desc>
6971 Progress object to track the operation completion.
6972 </desc>
6973 </param>
6974 </method>
6975
6976 <method name="removeHostOnlyNetworkInterface">
6977 <desc>
6978 Removes the given Host Only Networking interface.
6979 <result name="VBOX_E_OBJECT_NOT_FOUND">
6980 No host network interface matching @a id found.
6981 </result>
6982 </desc>
6983 <param name="id" type="uuid" mod="string" dir="in">
6984 <desc>
6985 Adapter GUID.
6986 </desc>
6987 </param>
6988 <param name="progress" type="IProgress" dir="return">
6989 <desc>
6990 Progress object to track the operation completion.
6991 </desc>
6992 </param>
6993 </method>
6994
6995 <method name="createUSBDeviceFilter">
6996 <desc>
6997 Creates a new USB device filter. All attributes except
6998 the filter name are set to empty (any match),
6999 <i>active</i> is @c false (the filter is not active).
7000
7001 The created filter can be added to the list of filters using
7002 <link to="#insertUSBDeviceFilter"/>.
7003
7004 <see>#USBDeviceFilters</see>
7005 </desc>
7006 <param name="name" type="wstring" dir="in">
7007 <desc>
7008 Filter name. See <link to="IUSBDeviceFilter::name"/> for more information.
7009 </desc>
7010 </param>
7011 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
7012 <desc>Created filter object.</desc>
7013 </param>
7014 </method>
7015
7016 <method name="insertUSBDeviceFilter">
7017 <desc>
7018 Inserts the given USB device to the specified position
7019 in the list of filters.
7020
7021 Positions are numbered starting from @c 0. If the specified
7022 position is equal to or greater than the number of elements in
7023 the list, the filter is added at the end of the collection.
7024
7025 <note>
7026 Duplicates are not allowed, so an attempt to insert a
7027 filter already in the list is an error.
7028 </note>
7029 <note>
7030 If USB functionality is not available in the given edition of
7031 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7032 </note>
7033
7034 <see>#USBDeviceFilters</see>
7035
7036 <result name="VBOX_E_INVALID_OBJECT_STATE">
7037 USB device filter is not created within this VirtualBox instance.
7038 </result>
7039 <result name="E_INVALIDARG">
7040 USB device filter already in list.
7041 </result>
7042
7043 </desc>
7044 <param name="position" type="unsigned long" dir="in">
7045 <desc>Position to insert the filter to.</desc>
7046 </param>
7047 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
7048 <desc>USB device filter to insert.</desc>
7049 </param>
7050 </method>
7051
7052 <method name="removeUSBDeviceFilter">
7053 <desc>
7054 Removes a USB device filter from the specified position in the
7055 list of filters.
7056
7057 Positions are numbered starting from @c 0. Specifying a
7058 position equal to or greater than the number of elements in
7059 the list will produce an error.
7060
7061 <note>
7062 If USB functionality is not available in the given edition of
7063 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7064 </note>
7065
7066 <see>#USBDeviceFilters</see>
7067
7068 <result name="E_INVALIDARG">
7069 USB device filter list empty or invalid @a position.
7070 </result>
7071
7072 </desc>
7073 <param name="position" type="unsigned long" dir="in">
7074 <desc>Position to remove the filter from.</desc>
7075 </param>
7076 </method>
7077
7078 <method name="findHostDVDDrive">
7079 <desc>
7080 Searches for a host DVD drive with the given @c name.
7081
7082 <result name="VBOX_E_OBJECT_NOT_FOUND">
7083 Given @c name does not correspond to any host drive.
7084 </result>
7085
7086 </desc>
7087 <param name="name" type="wstring" dir="in">
7088 <desc>Name of the host drive to search for</desc>
7089 </param>
7090 <param name="drive" type="IMedium" dir="return">
7091 <desc>Found host drive object</desc>
7092 </param>
7093 </method>
7094
7095 <method name="findHostFloppyDrive">
7096 <desc>
7097 Searches for a host floppy drive with the given @c name.
7098
7099 <result name="VBOX_E_OBJECT_NOT_FOUND">
7100 Given @c name does not correspond to any host floppy drive.
7101 </result>
7102
7103 </desc>
7104 <param name="name" type="wstring" dir="in">
7105 <desc>Name of the host floppy drive to search for</desc>
7106 </param>
7107 <param name="drive" type="IMedium" dir="return">
7108 <desc>Found host floppy drive object</desc>
7109 </param>
7110 </method>
7111
7112 <method name="findHostNetworkInterfaceByName">
7113 <desc>
7114 Searches through all host network interfaces for an interface with
7115 the given @c name.
7116 <note>
7117 The method returns an error if the given @c name does not
7118 correspond to any host network interface.
7119 </note>
7120 </desc>
7121 <param name="name" type="wstring" dir="in">
7122 <desc>Name of the host network interface to search for.</desc>
7123 </param>
7124 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7125 <desc>Found host network interface object.</desc>
7126 </param>
7127 </method>
7128 <method name="findHostNetworkInterfaceById">
7129 <desc>
7130 Searches through all host network interfaces for an interface with
7131 the given GUID.
7132 <note>
7133 The method returns an error if the given GUID does not
7134 correspond to any host network interface.
7135 </note>
7136 </desc>
7137 <param name="id" type="uuid" mod="string" dir="in">
7138 <desc>GUID of the host network interface to search for.</desc>
7139 </param>
7140 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7141 <desc>Found host network interface object.</desc>
7142 </param>
7143 </method>
7144 <method name="findHostNetworkInterfacesOfType">
7145 <desc>
7146 Searches through all host network interfaces and returns a list of interfaces of the specified type
7147 </desc>
7148 <param name="type" type="HostNetworkInterfaceType" dir="in">
7149 <desc>type of the host network interfaces to search for.</desc>
7150 </param>
7151 <param name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" dir="return">
7152 <desc>Found host network interface objects.</desc>
7153 </param>
7154 </method>
7155
7156 <method name="findUSBDeviceById">
7157 <desc>
7158 Searches for a USB device with the given UUID.
7159
7160 <result name="VBOX_E_OBJECT_NOT_FOUND">
7161 Given @c id does not correspond to any USB device.
7162 </result>
7163
7164 <see>IHostUSBDevice::id</see>
7165 </desc>
7166 <param name="id" type="uuid" mod="string" dir="in">
7167 <desc>UUID of the USB device to search for.</desc>
7168 </param>
7169 <param name="device" type="IHostUSBDevice" dir="return">
7170 <desc>Found USB device object.</desc>
7171 </param>
7172 </method>
7173
7174 <method name="findUSBDeviceByAddress">
7175 <desc>
7176 Searches for a USB device with the given host address.
7177
7178 <result name="VBOX_E_OBJECT_NOT_FOUND">
7179 Given @c name does not correspond to any USB device.
7180 </result>
7181
7182 <see>IHostUSBDevice::address</see>
7183 </desc>
7184 <param name="name" type="wstring" dir="in">
7185 <desc>
7186 Address of the USB device (as assigned by the host) to
7187 search for.
7188 </desc>
7189 </param>
7190 <param name="device" type="IHostUSBDevice" dir="return">
7191 <desc>Found USB device object.</desc>
7192 </param>
7193 </method>
7194
7195 </interface>
7196
7197 <!--
7198 // ISystemProperties
7199 /////////////////////////////////////////////////////////////////////////
7200 -->
7201
7202 <interface
7203 name="ISystemProperties"
7204 extends="$unknown"
7205 uuid="5e54e767-293c-441b-a5e4-03a1fdbc0dcb"
7206 wsmap="managed"
7207 >
7208 <desc>
7209 The ISystemProperties interface represents global properties of the given
7210 VirtualBox installation.
7211
7212 These properties define limits and default values for various attributes
7213 and parameters. Most of the properties are read-only, but some can be
7214 changed by a user.
7215 </desc>
7216
7217 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
7218 <desc>Minimum guest system memory in Megabytes.</desc>
7219 </attribute>
7220
7221 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
7222 <desc>Maximum guest system memory in Megabytes.</desc>
7223 </attribute>
7224
7225 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
7226 <desc>Minimum guest video memory in Megabytes.</desc>
7227 </attribute>
7228
7229 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
7230 <desc>Maximum guest video memory in Megabytes.</desc>
7231 </attribute>
7232
7233 <attribute name="minGuestCPUCount" type="unsigned long" readonly="yes">
7234 <desc>Minimum CPU count.</desc>
7235 </attribute>
7236
7237 <attribute name="maxGuestCPUCount" type="unsigned long" readonly="yes">
7238 <desc>Maximum CPU count.</desc>
7239 </attribute>
7240
7241 <attribute name="maxGuestMonitors" type="unsigned long" readonly="yes">
7242 <desc>Maximum of monitors which could be connected.</desc>
7243 </attribute>
7244
7245 <attribute name="infoVDSize" type="long long" readonly="yes">
7246 <desc>Maximum size of a virtual disk image in bytes. Informational value,
7247 does not reflect the limits of any virtual disk image format.</desc>
7248 </attribute>
7249
7250 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
7251 <desc>
7252 Number of network adapters associated with every
7253 <link to="IMachine"/> instance.
7254 </desc>
7255 </attribute>
7256
7257 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
7258 <desc>
7259 Number of serial ports associated with every
7260 <link to="IMachine"/> instance.
7261 </desc>
7262 </attribute>
7263
7264 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
7265 <desc>
7266 Number of parallel ports associated with every
7267 <link to="IMachine"/> instance.
7268 </desc>
7269 </attribute>
7270
7271 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
7272 <desc>
7273 Maximum device position in the boot order. This value corresponds
7274 to the total number of devices a machine can boot from, to make it
7275 possible to include all possible devices to the boot list.
7276 <see><link to="IMachine::setBootOrder"/></see>
7277 </desc>
7278 </attribute>
7279
7280 <attribute name="defaultMachineFolder" type="wstring">
7281 <desc>
7282 Full path to the default directory used to create new or open
7283 existing machines when a settings file name contains no
7284 path.
7285
7286 The initial value of this property is
7287 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
7288 VirtualBox_home</link><tt>&gt;/Machines</tt>.
7289
7290 <note>
7291 Setting this property to @c null or an empty string will restore the
7292 initial value.
7293 </note>
7294 <note>
7295 When settings this property, the specified path can be
7296 absolute (full path) or relative
7297 to the <link to="IVirtualBox::homeFolder">
7298 VirtualBox home directory</link>.
7299 When reading this property, a full path is
7300 always returned.
7301 </note>
7302 <note>
7303 The specified path may not exist, it will be created
7304 when necessary.
7305 </note>
7306
7307 <see>
7308 <link to="IVirtualBox::createMachine"/>,
7309 <link to="IVirtualBox::openMachine"/>
7310 </see>
7311 </desc>
7312 </attribute>
7313
7314 <attribute name="defaultHardDiskFolder" type="wstring">
7315 <desc>
7316 Full path to the default directory used to create new or open existing
7317 virtual disks.
7318
7319 This path is used when the storage unit of a hard disk is a regular file
7320 in the host's file system and only a file name that contains no path is
7321 given.
7322
7323 The initial value of this property is
7324 <tt>&lt;</tt>
7325 <link to="IVirtualBox::homeFolder">VirtualBox_home</link>
7326 <tt>&gt;/HardDisks</tt>.
7327
7328 <note>
7329 Setting this property to @c null or empty string will restore the
7330 initial value.
7331 </note>
7332 <note>
7333 When settings this property, the specified path can be relative
7334 to the
7335 <link to="IVirtualBox::homeFolder">VirtualBox home directory</link> or
7336 absolute. When reading this property, a full path is
7337 always returned.
7338 </note>
7339 <note>
7340 The specified path may not exist, it will be created
7341 when necessary.
7342 </note>
7343
7344 <see>
7345 IMedium,
7346 <link to="IVirtualBox::createHardDisk"/>,
7347 <link to="IVirtualBox::openMedium"/>,
7348 <link to="IMedium::location"/>
7349 </see>
7350 </desc>
7351 </attribute>
7352
7353 <attribute name="mediumFormats" type="IMediumFormat" safearray="yes" readonly="yes">
7354 <desc>
7355 List of all medium storage formats supported by this VirtualBox
7356 installation.
7357
7358 Keep in mind that the medium format identifier
7359 (<link to="IMediumFormat::id"/>) used in other API calls like
7360 <link to="IVirtualBox::createHardDisk"/> to refer to a particular
7361 medium format is a case-insensitive string. This means that, for
7362 example, all of the following strings:
7363 <pre>
7364 "VDI"
7365 "vdi"
7366 "VdI"</pre>
7367 refer to the same medium format.
7368
7369 Note that the virtual medium framework is backend-based, therefore
7370 the list of supported formats depends on what backends are currently
7371 installed.
7372
7373 <see>
7374 <link to="IMediumFormat"/>,
7375 </see>
7376 </desc>
7377 </attribute>
7378
7379 <attribute name="defaultHardDiskFormat" type="wstring">
7380 <desc>
7381 Identifier of the default medium format used by VirtualBox.
7382
7383 The medium format set by this attribute is used by VirtualBox
7384 when the medium format was not specified explicitly. One example is
7385 <link to="IVirtualBox::createHardDisk"/> with the empty
7386 format argument. A more complex example is implicit creation of
7387 differencing media when taking a snapshot of a virtual machine:
7388 this operation will try to use a format of the parent medium first
7389 and if this format does not support differencing media the default
7390 format specified by this argument will be used.
7391
7392 The list of supported medium formats may be obtained by the
7393 <link to="#mediumFormats"/> call. Note that the default medium
7394 format must have a capability to create differencing media;
7395 otherwise operations that create media implicitly may fail
7396 unexpectedly.
7397
7398 The initial value of this property is <tt>"VDI"</tt> in the current
7399 version of the VirtualBox product, but may change in the future.
7400
7401 <note>
7402 Setting this property to @c null or empty string will restore the
7403 initial value.
7404 </note>
7405
7406 <see>
7407 <link to="#mediumFormats"/>,
7408 <link to="IMediumFormat::id"/>,
7409 <link to="IVirtualBox::createHardDisk"/>
7410 </see>
7411 </desc>
7412 </attribute>
7413
7414 <attribute name="freeDiskSpaceWarning" type="long long">
7415 <desc>Issue a warning if the free disk space is below (or in some disk
7416 intensive operation is expected to go below) the given size in
7417 bytes.</desc>
7418 </attribute>
7419
7420 <attribute name="freeDiskSpacePercentWarning" type="unsigned long">
7421 <desc>Issue a warning if the free disk space is below (or in some disk
7422 intensive operation is expected to go below) the given percentage.</desc>
7423 </attribute>
7424
7425 <attribute name="freeDiskSpaceError" type="long long">
7426 <desc>Issue an error if the free disk space is below (or in some disk
7427 intensive operation is expected to go below) the given size in
7428 bytes.</desc>
7429 </attribute>
7430
7431 <attribute name="freeDiskSpacePercentError" type="unsigned long">
7432 <desc>Issue an error if the free disk space is below (or in some disk
7433 intensive operation is expected to go below) the given percentage.</desc>
7434 </attribute>
7435
7436 <attribute name="remoteDisplayAuthLibrary" type="wstring">
7437 <desc>
7438 Library that provides authentication for VRDP clients. The library
7439 is used if a virtual machine's authentication type is set to "external"
7440 in the VM RemoteDisplay configuration.
7441
7442 The system library extension (".DLL" or ".so") must be omitted.
7443 A full path can be specified; if not, then the library must reside on the
7444 system's default library path.
7445
7446 The default value of this property is <tt>"VRDPAuth"</tt>. There is a library
7447 of that name in one of the default VirtualBox library directories.
7448
7449 For details about VirtualBox authentication libraries and how to implement
7450 them, please refer to the VirtualBox manual.
7451
7452 <note>
7453 Setting this property to @c null or empty string will restore the
7454 initial value.
7455 </note>
7456 </desc>
7457 </attribute>
7458
7459 <attribute name="webServiceAuthLibrary" type="wstring">
7460 <desc>
7461 Library that provides authentication for webservice clients. The library
7462 is used if a virtual machine's authentication type is set to "external"
7463 in the VM RemoteDisplay configuration and will be called from
7464 within the <link to="IWebsessionManager::logon" /> implementation.
7465
7466 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
7467 there is no per-VM setting for this, as the webservice is a global
7468 resource (if it is running). Only for this setting (for the webservice),
7469 setting this value to a literal <tt>"null"</tt> string disables authentication,
7470 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
7471 no matter what user name and password are supplied.
7472
7473 The initial value of this property is <tt>"VRDPAuth"</tt>,
7474 meaning that the webservice will use the same authentication
7475 library that is used by default for VBoxVRDP (again, see
7476 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
7477 The format and calling convention of authentication libraries
7478 is the same for the webservice as it is for VBoxVRDP.
7479
7480 <note>
7481 Setting this property to @c null or empty string will restore the
7482 initial value.
7483 </note>
7484 </desc>
7485 </attribute>
7486
7487 <attribute name="LogHistoryCount" type="unsigned long">
7488 <desc>
7489 This value specifies how many old release log files are kept.
7490 </desc>
7491 </attribute>
7492
7493 <attribute name="defaultAudioDriver" type="AudioDriverType" readonly="yes">
7494 <desc>This value hold the default audio driver for the current
7495 system.</desc>
7496 </attribute>
7497
7498 <method name="getMaxDevicesPerPortForStorageBus">
7499 <desc>Returns the maximum number of devices which can be attached to a port
7500 for the given storage bus.</desc>
7501
7502 <param name="bus" type="StorageBus" dir="in">
7503 <desc>The storage bus type to get the value for.</desc>
7504 </param>
7505
7506 <param name="maxDevicesPerPort" type="unsigned long" dir="return">
7507 <desc>The maximum number of devices which can eb attached to the port for the given
7508 storage bus.</desc>
7509 </param>
7510 </method>
7511
7512 <method name="getMinPortCountForStorageBus">
7513 <desc>Returns the minimum number of ports the given storage bus supports.</desc>
7514
7515 <param name="bus" type="StorageBus" dir="in">
7516 <desc>The storage bus type to get the value for.</desc>
7517 </param>
7518
7519 <param name="minPortCount" type="unsigned long" dir="return">
7520 <desc>The minimum number of ports for the given storage bus.</desc>
7521 </param>
7522 </method>
7523
7524 <method name="getMaxPortCountForStorageBus">
7525 <desc>Returns the maximum number of ports the given storage bus supports.</desc>
7526
7527 <param name="bus" type="StorageBus" dir="in">
7528 <desc>The storage bus type to get the value for.</desc>
7529 </param>
7530
7531 <param name="maxPortCount" type="unsigned long" dir="return">
7532 <desc>The maximum number of ports for the given storage bus.</desc>
7533 </param>
7534 </method>
7535
7536 <method name="getMaxInstancesOfStorageBus">
7537 <desc>Returns the maximum number of storage bus instances which
7538 can be configured for each VM. This corresponds to the number of
7539 storage controllers one can have.</desc>
7540
7541 <param name="bus" type="StorageBus" dir="in">
7542 <desc>The storage bus type to get the value for.</desc>
7543 </param>
7544
7545 <param name="maxInstances" type="unsigned long" dir="return">
7546 <desc>The maximum number of instances for the given storage bus.</desc>
7547 </param>
7548 </method>
7549
7550 <method name="getDeviceTypesForStorageBus">
7551 <desc>Returns list of all the supported device types
7552 (<link to="DeviceType"/>) for the given type of storage
7553 bus.</desc>
7554
7555 <param name="bus" type="StorageBus" dir="in">
7556 <desc>The storage bus type to get the value for.</desc>
7557 </param>
7558
7559 <param name="deviceTypes" type="DeviceType" safearray="yes" dir="return">
7560 <desc>The list of all supported device types for the given storage bus.</desc>
7561 </param>
7562 </method>
7563
7564 <method name="getDefaultIoCacheSettingForStorageController">
7565 <desc>Returns the default I/O cache setting for the
7566 given storage controller</desc>
7567
7568 <param name="controllerType" type="StorageControllerType" dir="in">
7569 <desc>The storage controller to the setting for.</desc>
7570 </param>
7571
7572 <param name="enabled" type="boolean" dir="return">
7573 <desc>Returned flag indicating the default value</desc>
7574 </param>
7575 </method>
7576 </interface>
7577
7578 <!--
7579 // IGuest
7580 /////////////////////////////////////////////////////////////////////////
7581 -->
7582
7583 <interface
7584 name="IGuestOSType" extends="$unknown"
7585 uuid="432c1546-1354-4abf-bf08-878a32a373f5"
7586 wsmap="struct"
7587 >
7588 <desc>
7589 </desc>
7590
7591 <attribute name="familyId" type="wstring" readonly="yes">
7592 <desc>Guest OS family identifier string.</desc>
7593 </attribute>
7594
7595 <attribute name="familyDescription" type="wstring" readonly="yes">
7596 <desc>Human readable description of the guest OS family.</desc>
7597 </attribute>
7598
7599 <attribute name="id" type="wstring" readonly="yes">
7600 <desc>Guest OS identifier string.</desc>
7601 </attribute>
7602
7603 <attribute name="description" type="wstring" readonly="yes">
7604 <desc>Human readable description of the guest OS.</desc>
7605 </attribute>
7606
7607 <attribute name="is64Bit" type="boolean" readonly="yes">
7608 <desc>Returns @c true if the given OS is 64-bit</desc>
7609 </attribute>
7610
7611 <attribute name="recommendedIOAPIC" type="boolean" readonly="yes">
7612 <desc>Returns @c true if IO APIC recommended for this OS type.</desc>
7613 </attribute>
7614
7615 <attribute name="recommendedVirtEx" type="boolean" readonly="yes">
7616 <desc>Returns @c true if VT-x or AMD-V recommended for this OS type.</desc>
7617 </attribute>
7618
7619 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
7620 <desc>Recommended RAM size in Megabytes.</desc>
7621 </attribute>
7622
7623 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
7624 <desc>Recommended video RAM size in Megabytes.</desc>
7625 </attribute>
7626
7627 <attribute name="recommendedHDD" type="long long" readonly="yes">
7628 <desc>Recommended hard disk size in bytes.</desc>
7629 </attribute>
7630
7631 <attribute name="adapterType" type="NetworkAdapterType" readonly="yes">
7632 <desc>Returns recommended network adapter for this OS type.</desc>
7633 </attribute>
7634
7635 <attribute name="recommendedPae" type="boolean" readonly="yes">
7636 <desc>Returns @c true if using PAE is recommended for this OS type.</desc>
7637 </attribute>
7638
7639 <attribute name="recommendedDvdStorageController" type="StorageControllerType" readonly="yes">
7640 <desc>Recommended storage controller type for DVD/CD drives.</desc>
7641 </attribute>
7642
7643 <attribute name="recommendedDvdStorageBus" type="StorageBus" readonly="yes">
7644 <desc>Recommended storage bus type for DVD/CD drives.</desc>
7645 </attribute>
7646
7647 <attribute name="recommendedHdStorageController" type="StorageControllerType" readonly="yes">
7648 <desc>Recommended storage controller type for HD drives.</desc>
7649 </attribute>
7650
7651 <attribute name="recommendedHdStorageBus" type="StorageBus" readonly="yes">
7652 <desc>Recommended storage bus type for HD drives.</desc>
7653 </attribute>
7654
7655 <attribute name="recommendedFirmware" type="FirmwareType" readonly="yes">
7656 <desc>Recommended firmware type.</desc>
7657 </attribute>
7658
7659 <attribute name="recommendedUsbHid" type="boolean" readonly="yes">
7660 <desc>Returns @c true if using USB Human Interface Devices, such as keyboard and mouse recommended.</desc>
7661 </attribute>
7662
7663 <attribute name="recommendedHpet" type="boolean" readonly="yes">
7664 <desc>Returns @c true if using HPET is recommended for this OS type.</desc>
7665 </attribute>
7666
7667 <attribute name="recommendedUsbTablet" type="boolean" readonly="yes">
7668 <desc>Returns @c true if using a USB Tablet is recommended.</desc>
7669 </attribute>
7670
7671 <attribute name="recommendedRtcUseUtc" type="boolean" readonly="yes">
7672 <desc>Returns @c true if the RTC of this VM should be set to UTC</desc>
7673 </attribute>
7674
7675 <attribute name="recommendedChipset" type="ChipsetType" readonly="yes">
7676 <desc>Recommended chipset type.</desc>
7677 </attribute>
7678
7679 </interface>
7680
7681 <enum
7682 name="AdditionsRunLevelType"
7683 uuid="a25417ee-a9dd-4f5b-b0dc-377860087754"
7684 >
7685 <desc>
7686 Guest Additions run level type.
7687 </desc>
7688
7689 <const name="None" value="0">
7690 <desc>Guest Additions are not loaded.</desc>
7691 </const>
7692 <const name="System" value="1">
7693 <desc>Guest drivers are loaded.</desc>
7694 </const>
7695 <const name="Userland" value="2">
7696 <desc>Common components (such as application services) are loaded.</desc>
7697 </const>
7698 <const name="Desktop" value="3">
7699 <desc>Per-user desktop components are loaded.</desc>
7700 </const>
7701 </enum>
7702
7703 <enum
7704 name="ExecuteProcessFlag"
7705 uuid="9a24c17d-bd46-4207-b247-517fdd6d6b8f"
7706 >
7707 <desc>
7708 Guest process execution flags.
7709 </desc>
7710
7711 <const name="None" value="0">
7712 <desc>No flag set.</desc>
7713 </const>
7714
7715 <const name="IgnoreOrphanedProcesses" value="2">
7716 <desc>Do not report an error when executed processes are still alive when VBoxService or the guest OS is shutting down.</desc>
7717 </const>
7718 </enum>
7719
7720 <enum
7721 name="CopyFileFlag"
7722 uuid="23f79fdf-738a-493d-b80b-42d607c9b916"
7723 >
7724 <desc>
7725 Host/Guest copy flags.
7726 </desc>
7727
7728 <const name="None" value="0">
7729 <desc>No flag set.</desc>
7730 </const>
7731
7732 <const name="Recursive" value="2">
7733 <desc>Copy directories recursively.</desc>
7734 </const>
7735
7736 <const name="Update" value="4">
7737 <desc>Copy only when the source file is newer than the destination file or when the destination file is missing.</desc>
7738 </const>
7739
7740 <const name="FollowLinks" value="8">
7741 <desc>Follow symbolic links.</desc>
7742 </const>
7743 </enum>
7744
7745 <interface
7746 name="IGuest" extends="$unknown"
7747 uuid="c165a809-0882-4c76-9220-746da84b5ecf"
7748 wsmap="managed"
7749 >
7750 <desc>
7751 The IGuest interface represents information about the operating system
7752 running inside the virtual machine. Used in
7753 <link to="IConsole::guest"/>.
7754
7755 IGuest provides information about the guest operating system, whether
7756 Guest Additions are installed and other OS-specific virtual machine
7757 properties.
7758 </desc>
7759
7760 <attribute name="OSTypeId" type="wstring" readonly="yes">
7761 <desc>
7762 Identifier of the Guest OS type as reported by the Guest
7763 Additions.
7764 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
7765 an IGuestOSType object representing details about the given
7766 Guest OS type.
7767 <note>
7768 If Guest Additions are not installed, this value will be
7769 the same as <link to="IMachine::OSTypeId"/>.
7770 </note>
7771 </desc>
7772 </attribute>
7773
7774 <attribute name="additionsRunLevel" type="AdditionsRunLevelType" readonly="yes">
7775 <desc>
7776 Current run level of the Guest Additions.
7777 </desc>
7778 </attribute>
7779
7780 <attribute name="additionsVersion" type="wstring" readonly="yes">
7781 <desc>
7782 Version of the Guest Additions including the revision (3 decimal numbers
7783 separated by dots + revision number) installed on the guest or empty
7784 when the Additions are not installed.
7785 </desc>
7786 </attribute>
7787
7788 <attribute name="supportsSeamless" type="boolean" readonly="yes">
7789 <desc>
7790 Flag whether seamless guest display rendering (seamless desktop
7791 integration) is supported.
7792 </desc>
7793 </attribute>
7794
7795 <attribute name="supportsGraphics" type="boolean" readonly="yes">
7796 <desc>
7797 Flag whether the guest is in graphics mode. If it is not, then
7798 seamless rendering will not work, resize hints are not immediately
7799 acted on and guest display resizes are probably not initiated by
7800 the guest additions.
7801 </desc>
7802 </attribute>
7803
7804 <attribute name="memoryBalloonSize" type="unsigned long">
7805 <desc>Guest system memory balloon size in megabytes (transient property).</desc>
7806 </attribute>
7807
7808 <attribute name="statisticsUpdateInterval" type="unsigned long">
7809 <desc>Interval to update guest statistics in seconds.</desc>
7810 </attribute>
7811
7812 <method name="internalGetStatistics">
7813 <desc>
7814 Internal method; do not use as it might change at any time
7815 </desc>
7816 <param name="cpuUser" type="unsigned long" dir="out">
7817 <desc>Percentage of processor time spent in user mode as seen by the guest</desc>
7818 </param>
7819 <param name="cpuKernel" type="unsigned long" dir="out">
7820 <desc>Percentage of processor time spent in kernel mode as seen by the guest</desc>
7821 </param>
7822 <param name="cpuIdle" type="unsigned long" dir="out">
7823 <desc>Percentage of processor time spent idling as seen by the guest</desc>
7824 </param>
7825 <param name="memTotal" type="unsigned long" dir="out">
7826 <desc>Total amount of physical guest RAM</desc>
7827 </param>
7828 <param name="memFree" type="unsigned long" dir="out">
7829 <desc>Free amount of physical guest RAM</desc>
7830 </param>
7831 <param name="memBalloon" type="unsigned long" dir="out">
7832 <desc>Amount of ballooned physical guest RAM</desc>
7833 </param>
7834 <param name="memShared" type="unsigned long" dir="out">
7835 <desc>Amount of shared physical guest RAM</desc>
7836 </param>
7837 <param name="memCache" type="unsigned long" dir="out">
7838 <desc>Total amount of guest (disk) cache memory</desc>
7839 </param>
7840 <param name="pagedTotal" type="unsigned long" dir="out">
7841 <desc>Total amount of space in the page file</desc>
7842 </param>
7843 <param name="memAllocTotal" type="unsigned long" dir="out">
7844 <desc>Total amount of memory allocated by the hypervisor</desc>
7845 </param>
7846 <param name="memFreeTotal" type="unsigned long" dir="out">
7847 <desc>Total amount of free memory available in the hypervisor</desc>
7848 </param>
7849 <param name="memBalloonTotal" type="unsigned long" dir="out">
7850 <desc>Total amount of memory ballooned by the hypervisor</desc>
7851 </param>
7852 <param name="memSharedTotal" type="unsigned long" dir="out">
7853 <desc>Total amount of shared memory in the hypervisor</desc>
7854 </param>
7855 </method>
7856
7857 <method name="getAdditionsStatus">
7858 <desc>
7859 Retrieve the current status of a certain Guest Additions run level.
7860
7861 <result name="VBOX_E_NOT_SUPPORTED">
7862 Wrong status level specified.
7863 </result>
7864
7865 </desc>
7866 <param name="level" type="AdditionsRunLevelType" dir="in">
7867 <desc>Status level to check</desc>
7868 </param>
7869 <param name="active" type="boolean" dir="return">
7870 <desc>Flag whether the status level has been reached or not</desc>
7871 </param>
7872 </method>
7873
7874 <method name="setCredentials">
7875 <desc>
7876 Store login credentials that can be queried by guest operating
7877 systems with Additions installed. The credentials are transient
7878 to the session and the guest may also choose to erase them. Note
7879 that the caller cannot determine whether the guest operating system
7880 has queried or made use of the credentials.
7881
7882 <result name="VBOX_E_VM_ERROR">
7883 VMM device is not available.
7884 </result>
7885
7886 </desc>
7887 <param name="userName" type="wstring" dir="in">
7888 <desc>User name string, can be empty</desc>
7889 </param>
7890 <param name="password" type="wstring" dir="in">
7891 <desc>Password string, can be empty</desc>
7892 </param>
7893 <param name="domain" type="wstring" dir="in">
7894 <desc>Domain name (guest logon scheme specific), can be empty</desc>
7895 </param>
7896 <param name="allowInteractiveLogon" type="boolean" dir="in">
7897 <desc>
7898 Flag whether the guest should alternatively allow the user to
7899 interactively specify different credentials. This flag might
7900 not be supported by all versions of the Additions.
7901 </desc>
7902 </param>
7903 </method>
7904
7905 <method name="executeProcess">
7906 <desc>
7907 Executes an existing program inside the guest VM.
7908
7909 <result name="VBOX_E_IPRT_ERROR">
7910 Could not execute process.
7911 </result>
7912
7913 </desc>
7914 <param name="execName" type="wstring" dir="in">
7915 <desc>
7916 Full path name of the command to execute on the guest; the
7917 commands has to exists in the guest VM in order to be executed.
7918 </desc>
7919 </param>
7920 <param name="flags" type="unsigned long" dir="in">
7921 <desc>
7922 Execution flags - currently not supported and therefore
7923 has to be set to 0.
7924 </desc>
7925 </param>
7926 <param name="arguments" type="wstring" safearray="yes" dir="in">
7927 <desc>
7928 Array of arguments passed to the execution command.
7929 </desc>
7930 </param>
7931 <param name="environment" type="wstring" safearray="yes" dir="in">
7932 <desc>
7933 Environment variables that can be set while the command is being
7934 executed, in form of "NAME=VALUE"; one pair per entry. To unset a
7935 variable just set its name ("NAME") without a value.
7936 </desc>
7937 </param>
7938 <param name="userName" type="wstring" dir="in">
7939 <desc>
7940 User name under which the command will be executed; has to exist
7941 and have the appropriate rights to execute programs in the VM.
7942 </desc>
7943 </param>
7944 <param name="password" type="wstring" dir="in">
7945 <desc>
7946 Password of the user account specified.
7947 </desc>
7948 </param>
7949 <param name="timeoutMS" type="unsigned long" dir="in">
7950 <desc>
7951 The maximum timeout value (in msec) to wait for finished program
7952 execution. Pass 0 for an infinite timeout.
7953 </desc>
7954 </param>
7955 <param name="pid" type="unsigned long" dir="out">
7956 <desc>
7957 The PID (process ID) of the started command for later reference.
7958 </desc>
7959 </param>
7960 <param name="progress" type="IProgress" dir="return">
7961 <desc>Progress object to track the operation completion.</desc>
7962 </param>
7963 </method>
7964
7965 <method name="getProcessOutput">
7966 <desc>
7967 Retrieves output of a formerly started process.
7968
7969 <result name="VBOX_E_IPRT_ERROR">
7970 Could not retrieve output.
7971 </result>
7972
7973 </desc>
7974 <param name="pid" type="unsigned long" dir="in">
7975 <desc>
7976 Process id returned by earlier executeProcess() call.
7977 </desc>
7978 </param>
7979 <param name="flags" type="unsigned long" dir="in">
7980 <desc>
7981 Flags describing which output to retrieve.
7982 </desc>
7983 </param>
7984 <param name="timeoutMS" type="unsigned long" dir="in">
7985 <desc>
7986 The maximum timeout value (in msec) to wait for output
7987 data. Pass 0 for an infinite timeout.
7988 </desc>
7989 </param>
7990 <param name="size" type="long long" dir="in">
7991 <desc>
7992 Size in bytes to read in the buffer.
7993 </desc>
7994 </param>
7995 <param name="data" type="octet" dir="return" safearray="yes">
7996 <desc>
7997 Buffer for retrieving the actual output. A data size of 0 means end of file
7998 if the requested size was not 0. This is the unprocessed
7999 output data, i.e. the line ending style depends on the platform of
8000 the system the server is running on.
8001 </desc>
8002 </param>
8003 </method>
8004
8005 <method name="getProcessStatus">
8006 <desc>
8007 Retrieves status, exit code and the exit reason of a formerly started process.
8008
8009 <result name="VBOX_E_IPRT_ERROR">
8010 Process with specified PID was not found.
8011 </result>
8012
8013 </desc>
8014 <param name="pid" type="unsigned long" dir="in">
8015 <desc>
8016 Process id returned by earlier executeProcess() call.
8017 </desc>
8018 </param>
8019 <param name="exitcode" type="unsigned long" dir="out">
8020 <desc>
8021 The exit code (if available).
8022 </desc>
8023 </param>
8024 <param name="flags" type="unsigned long" dir="out">
8025 <desc>
8026 Additional flags of process status (not used at the moment).
8027 </desc>
8028 </param>
8029 <param name="reason" type="unsigned long" dir="return">
8030 <desc>
8031 The current process status.
8032 </desc>
8033 </param>
8034 </method>
8035
8036 <method name="copyToGuest">
8037 <desc>
8038 Copies files/directories from host to the guest.
8039
8040 <result name="VBOX_E_IPRT_ERROR">
8041 Error while copying.
8042 </result>
8043
8044 </desc>
8045 <param name="source" type="wstring" dir="in">
8046 <desc>
8047 Foo.
8048 </desc>
8049 </param>
8050 <param name="dest" type="wstring" dir="in">
8051 <desc>
8052 Bar.
8053 </desc>
8054 </param>
8055 <param name="flags" type="unsigned long" dir="in">
8056 <desc>
8057 Copy flags.
8058 </desc>
8059 </param>
8060 <param name="progress" type="IProgress" dir="return">
8061 <desc>Progress object to track the operation completion.</desc>
8062 </param>
8063 </method>
8064
8065 <method name="setProcessInput">
8066 <desc>
8067 Sends input into a formerly started process.
8068
8069 <result name="VBOX_E_IPRT_ERROR">
8070 Could not send input.
8071 </result>
8072
8073 </desc>
8074 <param name="pid" type="unsigned long" dir="in">
8075 <desc>
8076 Process id returned by earlier executeProcess() call.
8077 </desc>
8078 </param>
8079 <param name="flags" type="unsigned long" dir="in">
8080 <desc>
8081 Not used, must be set to zero.
8082 </desc>
8083 </param>
8084 <param name="timeoutMS" type="unsigned long" dir="in">
8085 <desc>
8086 The maximum timeout value (in msec) to wait for handling
8087 the input data. Pass 0 for an infinite timeout.
8088 </desc>
8089 </param>
8090 <param name="data" type="octet" dir="in" safearray="yes">
8091 <desc>
8092 Buffer of input data to send to the started process to.
8093 </desc>
8094 </param>
8095 <param name="written" type="unsigned long" dir="return">
8096 <desc>
8097 Number of bytes written.
8098 </desc>
8099 </param>
8100 </method>
8101
8102 </interface>
8103
8104
8105 <!--
8106 // IProgress
8107 /////////////////////////////////////////////////////////////////////////
8108 -->
8109
8110 <interface
8111 name="IProgress" extends="$unknown"
8112 uuid="A163C98F-8635-4AA8-B770-A9941737F3EF"
8113 wsmap="managed"
8114 >
8115 <desc>
8116 The IProgress interface is used to track and control
8117 asynchronous tasks within VirtualBox.
8118
8119 An instance of this is returned every time VirtualBox starts
8120 an asynchronous task (in other words, a separate thread) which
8121 continues to run after a method call returns. For example,
8122 <link to="IConsole::saveState" />, which saves the state of
8123 a running virtual machine, can take a long time to complete.
8124 To be able to display a progress bar, a user interface such as
8125 the VirtualBox graphical user interface can use the IProgress
8126 object returned by that method.
8127
8128 Note that IProgress is a "read-only" interface in the sense
8129 that only the VirtualBox internals behind the Main API can
8130 create and manipulate progress objects, whereas client code
8131 can only use the IProgress object to monitor a task's
8132 progress and, if <link to="#cancelable" /> is @c true,
8133 cancel the task by calling <link to="#cancel" />.
8134
8135 A task represented by IProgress consists of either one or
8136 several sub-operations that run sequentially, one by one (see
8137 <link to="#operation" /> and <link to="#operationCount" />).
8138 Every operation is identified by a number (starting from 0)
8139 and has a separate description.
8140
8141 You can find the individual percentage of completion of the current
8142 operation in <link to="#operationPercent" /> and the
8143 percentage of completion of the task as a whole
8144 in <link to="#percent" />.
8145
8146 Similarly, you can wait for the completion of a particular
8147 operation via <link to="#waitForOperationCompletion" /> or
8148 for the completion of the whole task via
8149 <link to="#waitForCompletion" />.
8150 </desc>
8151
8152 <attribute name="id" type="uuid" mod="string" readonly="yes">
8153 <desc>ID of the task.</desc>
8154 </attribute>
8155
8156 <attribute name="description" type="wstring" readonly="yes">
8157 <desc>Description of the task.</desc>
8158 </attribute>
8159
8160 <attribute name="initiator" type="$unknown" readonly="yes">
8161 <desc>Initiator of the task.</desc>
8162 </attribute>
8163
8164 <attribute name="cancelable" type="boolean" readonly="yes">
8165 <desc>Whether the task can be interrupted.</desc>
8166 </attribute>
8167
8168 <attribute name="percent" type="unsigned long" readonly="yes">
8169 <desc>
8170 Current progress value of the task as a whole, in percent.
8171 This value depends on how many operations are already complete.
8172 Returns 100 if <link to="#completed" /> is @c true.
8173 </desc>
8174 </attribute>
8175
8176 <attribute name="timeRemaining" type="long" readonly="yes">
8177 <desc>
8178 Estimated remaining time until the task completes, in
8179 seconds. Returns 0 once the task has completed; returns -1
8180 if the remaining time cannot be computed, in particular if
8181 the current progress is 0.
8182
8183 Even if a value is returned, the estimate will be unreliable
8184 for low progress values. It will become more reliable as the
8185 task progresses; it is not recommended to display an ETA
8186 before at least 20% of a task have completed.
8187 </desc>
8188 </attribute>
8189
8190 <attribute name="completed" type="boolean" readonly="yes">
8191 <desc>Whether the task has been completed.</desc>
8192 </attribute>
8193
8194 <attribute name="canceled" type="boolean" readonly="yes">
8195 <desc>Whether the task has been canceled.</desc>
8196 </attribute>
8197
8198 <attribute name="resultCode" type="long" readonly="yes">
8199 <desc>
8200 Result code of the progress task.
8201 Valid only if <link to="#completed"/> is @c true.
8202 </desc>
8203 </attribute>
8204
8205 <attribute name="errorInfo" type="IVirtualBoxErrorInfo" readonly="yes">
8206 <desc>
8207 Extended information about the unsuccessful result of the
8208 progress operation. May be @c null if no extended information
8209 is available.
8210 Valid only if <link to="#completed"/> is @c true and
8211 <link to="#resultCode"/> indicates a failure.
8212 </desc>
8213 </attribute>
8214
8215 <attribute name="operationCount" type="unsigned long" readonly="yes">
8216 <desc>
8217 Number of sub-operations this task is divided into.
8218 Every task consists of at least one suboperation.
8219 </desc>
8220 </attribute>
8221
8222 <attribute name="operation" type="unsigned long" readonly="yes">
8223 <desc>Number of the sub-operation being currently executed.</desc>
8224 </attribute>
8225
8226 <attribute name="operationDescription" type="wstring" readonly="yes">
8227 <desc>
8228 Description of the sub-operation being currently executed.
8229 </desc>
8230 </attribute>
8231
8232 <attribute name="operationPercent" type="unsigned long" readonly="yes">
8233 <desc>Progress value of the current sub-operation only, in percent.</desc>
8234 </attribute>
8235
8236 <attribute name="operationWeight" type="unsigned long" readonly="yes">
8237 <desc>Weight value of the current sub-operation only.</desc>
8238 </attribute>
8239
8240 <attribute name="timeout" type="unsigned long">
8241 <desc>
8242 When non-zero, this specifies the number of milliseconds after which
8243 the operation will automatically be canceled. This can only be set on
8244 cancelable objects.
8245 </desc>
8246 </attribute>
8247
8248 <method name="setCurrentOperationProgress">
8249 <desc>Internal method, not to be called externally.</desc>
8250 <param name="percent" type="unsigned long" dir="in" />
8251 </method>
8252 <method name="setNextOperation">
8253 <desc>Internal method, not to be called externally.</desc>
8254 <param name="nextOperationDescription" type="wstring" dir="in" />
8255 <param name="nextOperationsWeight" type="unsigned long" dir="in" />
8256 </method>
8257
8258 <method name="waitForCompletion">
8259 <desc>
8260 Waits until the task is done (including all sub-operations)
8261 with a given timeout in milliseconds; specify -1 for an indefinite wait.
8262
8263 Note that the VirtualBox/XPCOM/COM/native event queues of the calling
8264 thread are not processed while waiting. Neglecting event queues may
8265 have dire consequences (degrade performance, resource hogs,
8266 deadlocks, etc.), this is specially so for the main thread on
8267 platforms using XPCOM. Callers are adviced wait for short periods
8268 and service their event queues between calls, or to create a worker
8269 thread to do the waiting.
8270
8271 <result name="VBOX_E_IPRT_ERROR">
8272 Failed to wait for task completion.
8273 </result>
8274 </desc>
8275
8276 <param name="timeout" type="long" dir="in">
8277 <desc>
8278 Maximum time in milliseconds to wait or -1 to wait indefinitely.
8279 </desc>
8280 </param>
8281 </method>
8282
8283 <method name="waitForOperationCompletion">
8284 <desc>
8285 Waits until the given operation is done with a given timeout in
8286 milliseconds; specify -1 for an indefinite wait.
8287
8288 See <link to="#waitForCompletion"> for event queue considerations.</link>
8289
8290 <result name="VBOX_E_IPRT_ERROR">
8291 Failed to wait for operation completion.
8292 </result>
8293
8294 </desc>
8295 <param name="operation" type="unsigned long" dir="in">
8296 <desc>
8297 Number of the operation to wait for.
8298 Must be less than <link to="#operationCount"/>.
8299 </desc>
8300 </param>
8301 <param name="timeout" type="long" dir="in">
8302 <desc>
8303 Maximum time in milliseconds to wait or -1 to wait indefinitely.
8304 </desc>
8305 </param>
8306 </method>
8307
8308 <method name="cancel">
8309 <desc>
8310 Cancels the task.
8311 <note>
8312 If <link to="#cancelable"/> is @c false, then this method will fail.
8313 </note>
8314
8315 <result name="VBOX_E_INVALID_OBJECT_STATE">
8316 Operation cannot be canceled.
8317 </result>
8318
8319 </desc>
8320 </method>
8321
8322 </interface>
8323
8324 <!--
8325 // ISnapshot
8326 /////////////////////////////////////////////////////////////////////////
8327 -->
8328
8329 <interface
8330 name="ISnapshot" extends="$unknown"
8331 uuid="1a2d0551-58a4-4107-857e-ef414fc42ffc"
8332 wsmap="managed"
8333 >
8334 <desc>
8335 The ISnapshot interface represents a snapshot of the virtual
8336 machine.
8337
8338 Together with the differencing media that are created
8339 when a snapshot is taken, a machine can be brought back to
8340 the exact state it was in when the snapshot was taken.
8341
8342 The ISnapshot interface has no methods, only attributes; snapshots
8343 are controlled through methods of the <link to="IConsole" /> interface
8344 which also manage the media associated with the snapshot.
8345 The following operations exist:
8346
8347 <ul>
8348 <li><link to="IConsole::takeSnapshot"/> creates a new snapshot
8349 by creating new, empty differencing images for the machine's
8350 media and saving the VM settings and (if the VM is running)
8351 the current VM state in the snapshot.
8352
8353 The differencing images will then receive all data written to
8354 the machine's media, while their parent (base) images
8355 remain unmodified after the snapshot has been taken (see
8356 <link to="IMedium" /> for details about differencing images).
8357 This simplifies restoring a machine to the state of a snapshot:
8358 only the differencing images need to be deleted.
8359
8360 The current machine state is not changed by taking a snapshot.
8361 If the machine is running, it will resume execution after the
8362 snapshot has been taken. After calling this,
8363 <link to="IMachine::currentSnapshot" /> is set to the snapshot
8364 just created.
8365 </li>
8366
8367 <li><link to="IConsole::restoreSnapshot"/> resets a machine to
8368 the state of a previous snapshot by deleting the differencing
8369 image of each of the machine's media and setting the machine's
8370 settings and state to the state that was saved in the snapshot (if any).
8371
8372 This destroys the machine's current state. After calling this,
8373 <link to="IMachine::currentSnapshot" /> is set to the snapshot that was
8374 restored.
8375 </li>
8376
8377 <li><link to="IConsole::deleteSnapshot"/> deletes a snapshot
8378 without affecting the current machine state.
8379
8380 This does not change the current machine state, but instead frees the
8381 resources allocated when the snapshot was taken: the settings and machine
8382 state file are deleted (if any), and the snapshot's differencing image for
8383 each of the machine's media gets merged with its parent image.
8384
8385 Neither the current machine state nor other snapshots are affected
8386 by this operation, except that parent media will be modified
8387 to contain the disk data associated with the snapshot being deleted.
8388
8389 When deleting the current snapshot, the <link to="IMachine::currentSnapshot" />
8390 attribute is set to the current snapshot's parent or NULL if it
8391 has no parent. Otherwise the attribute is unchanged.
8392 </li>
8393 </ul>
8394
8395 Each snapshot contains the settings of the virtual machine (hardware
8396 configuration etc.). In addition, if the machine was running when the
8397 snapshot was taken (<link to="IMachine::state"/> is <link to="MachineState_Running"/>),
8398 the current VM state is saved in the snapshot (similarly to what happens
8399 when a VM's state is saved). The snapshot is then said to
8400 be <i>online</i> because when restoring it, the VM will be running.
8401
8402 If the machine is saved (<link to="MachineState_Saved"/>), the snapshot
8403 receives a copy of the execution state file (<link to="IMachine::stateFilePath"/>).
8404
8405 Otherwise, if the machine was not running (<link to="MachineState_PoweredOff"/>
8406 or <link to="MachineState_Aborted"/>), the snapshot is <i>offline</i>;
8407 it then contains a so-called "zero execution state", representing a
8408 machine that is powered off.
8409 </desc>
8410
8411 <attribute name="id" type="uuid" mod="string" readonly="yes">
8412 <desc>UUID of the snapshot.</desc>
8413 </attribute>
8414
8415 <attribute name="name" type="wstring">
8416 <desc>Short name of the snapshot.</desc>
8417 </attribute>
8418
8419 <attribute name="description" type="wstring">
8420 <desc>Optional description of the snapshot.</desc>
8421 </attribute>
8422
8423 <attribute name="timeStamp" type="long long" readonly="yes">
8424 <desc>
8425 Time stamp of the snapshot, in milliseconds since 1970-01-01 UTC.
8426 </desc>
8427 </attribute>
8428
8429 <attribute name="online" type="boolean" readonly="yes">
8430 <desc>
8431 @c true if this snapshot is an online snapshot and @c false otherwise.
8432
8433 When this attribute is @c true, the
8434 <link to="IMachine::stateFilePath"/> attribute of the
8435 <link to="#machine"/> object associated with this snapshot
8436 will point to the saved state file. Otherwise, it will be
8437 an empty string.
8438 </desc>
8439 </attribute>
8440
8441 <attribute name="machine" type="IMachine" readonly="yes">
8442 <desc>
8443 Virtual machine this snapshot is taken on. This object
8444 stores all settings the machine had when taking this snapshot.
8445 <note>
8446 The returned machine object is immutable, i.e. no
8447 any settings can be changed.
8448 </note>
8449 </desc>
8450 </attribute>
8451
8452 <attribute name="parent" type="ISnapshot" readonly="yes">
8453 <desc>
8454 Parent snapshot (a snapshot this one is based on), or
8455 @c null if the snapshot has no parent (i.e. is the first snapshot).
8456 </desc>
8457 </attribute>
8458
8459 <attribute name="children" type="ISnapshot" readonly="yes" safearray="yes">
8460 <desc>
8461 Child snapshots (all snapshots having this one as a parent).
8462 </desc>
8463 </attribute>
8464
8465 </interface>
8466
8467
8468 <!--
8469 // IMedium
8470 /////////////////////////////////////////////////////////////////////////
8471 -->
8472
8473 <enum
8474 name="MediumState"
8475 uuid="ef41e980-e012-43cd-9dea-479d4ef14d13"
8476 >
8477 <desc>
8478 Virtual medium state.
8479 <see>IMedium</see>
8480 </desc>
8481
8482 <const name="NotCreated" value="0">
8483 <desc>
8484 Associated medium storage does not exist (either was not created yet or
8485 was deleted).
8486 </desc>
8487 </const>
8488 <const name="Created" value="1">
8489 <desc>
8490 Associated storage exists and accessible; this gets set if the
8491 accessibility check performed by <link to="IMedium::refreshState" />
8492 was successful.
8493 </desc>
8494 </const>
8495 <const name="LockedRead" value="2">
8496 <desc>
8497 Medium is locked for reading (see <link to="IMedium::lockRead"/>),
8498 no data modification is possible.
8499 </desc>
8500 </const>
8501 <const name="LockedWrite" value="3">
8502 <desc>
8503 Medium is locked for writing (see <link to="IMedium::lockWrite"/>),
8504 no concurrent data reading or modification is possible.
8505 </desc>
8506 </const>
8507 <const name="Inaccessible" value="4">
8508 <desc>
8509 Medium accessiblity check (see <link to="IMedium::refreshState" />) has
8510 not yet been performed, or else, associated medium storage is not
8511 accessible. In the first case, <link to="IMedium::lastAccessError"/>
8512 is empty, in the second case, it describes the error that occured.
8513 </desc>
8514 </const>
8515 <const name="Creating" value="5">
8516 <desc>
8517 Associated medium storage is being created.
8518 </desc>
8519 </const>
8520 <const name="Deleting" value="6">
8521 <desc>
8522 Associated medium storage is being deleted.
8523 </desc>
8524 </const>
8525 </enum>
8526
8527 <enum
8528 name="MediumType"
8529 uuid="46bf1fd4-ad86-4ded-8c49-28bd2d148e5a"
8530 >
8531 <desc>
8532 Virtual medium type.
8533 <see>IMedium</see>
8534 </desc>
8535
8536 <const name="Normal" value="0">
8537 <desc>
8538 Normal medium (attached directly or indirectly, preserved
8539 when taking snapshots).
8540 </desc>
8541 </const>
8542 <const name="Immutable" value="1">
8543 <desc>
8544 Immutable medium (attached indirectly, changes are wiped out
8545 the next time the virtual machine is started).
8546 </desc>
8547 </const>
8548 <const name="Writethrough" value="2">
8549 <desc>
8550 Write through medium (attached directly, ignored when
8551 taking snapshots).
8552 </desc>
8553 </const>
8554 <const name="Shareable" value="3">
8555 <desc>
8556 Allow using this medium concurrently by several machines.
8557 <note>Present since VirtualBox 3.2.0, and accepted since 3.2.8.</note>
8558 </desc>
8559 </const>
8560 </enum>
8561
8562 <enum
8563 name="MediumVariant"
8564 uuid="584ea502-143b-4ab0-ad14-d1028fdf0316"
8565 >
8566 <desc>
8567 Virtual medium image variant. More than one flag may be set.
8568 <see>IMedium</see>
8569 </desc>
8570
8571 <const name="Standard" value="0">
8572 <desc>
8573 No particular variant requested, results in using the backend default.
8574 </desc>
8575 </const>
8576 <const name="VmdkSplit2G" value="0x01">
8577 <desc>
8578 VMDK image split in chunks of less than 2GByte.
8579 </desc>
8580 </const>
8581 <const name="VmdkStreamOptimized" value="0x04">
8582 <desc>
8583 VMDK streamOptimized image. Special import/export format which is
8584 read-only/append-only.
8585 </desc>
8586 </const>
8587 <const name="VmdkESX" value="0x08">
8588 <desc>
8589 VMDK format variant used on ESX products.
8590 </desc>
8591 </const>
8592 <const name="Fixed" value="0x10000">
8593 <desc>
8594 Fixed image. Only allowed for base images.
8595 </desc>
8596 </const>
8597 <const name="Diff" value="0x20000">
8598 <desc>
8599 Differencing image. Only allowed for child images.
8600 </desc>
8601 </const>
8602 </enum>
8603
8604 <interface
8605 name="IMediumAttachment" extends="$unknown"
8606 uuid="c29452cc-ca72-404b-9261-cfc514f1e412"
8607 wsmap="struct"
8608 >
8609 <desc>
8610 The IMediumAttachment interface links storage media to virtual machines.
8611 For each medium (<link to="IMedium"/>) which has been attached to a
8612 storage controller (<link to="IStorageController"/>) of a machine
8613 (<link to="IMachine"/>) via the <link to="IMachine::attachDevice" />
8614 method, one instance of IMediumAttachment is added to the machine's
8615 <link to="IMachine::mediumAttachments"/> array attribute.
8616
8617 Each medium attachment specifies the storage controller as well as a
8618 port and device number and the IMedium instance representing a virtual
8619 hard disk or floppy or DVD image.
8620
8621 For removeable media (DVDs or floppies), there are two additional
8622 options. For one, the IMedium instance can be @c null to represent
8623 an empty drive with no media inserted (see <link to="IMachine::mountMedium" />);
8624 secondly, the medium can be one of the pseudo-media for host drives
8625 listed in <link to="IHost::DVDDrives"/> or <link to="IHost::floppyDrives"/>.
8626 </desc>
8627
8628 <attribute name="medium" type="IMedium" readonly="yes">
8629 <desc>Medium object associated with this attachment; it
8630 can be @c null for removable devices.</desc>
8631 </attribute>
8632
8633 <attribute name="controller" type="wstring" readonly="yes">
8634 <desc>Name of the storage controller of this attachment; this
8635 refers to one of the controllers in <link to="IMachine::storageControllers" />
8636 by name.</desc>
8637 </attribute>
8638
8639 <attribute name="port" type="long" readonly="yes">
8640 <desc>Port number of this attachment.
8641 See <link to="IMachine::attachDevice" /> for the meaning of this value for the different controller types.
8642 </desc>
8643 </attribute>
8644
8645 <attribute name="device" type="long" readonly="yes">
8646 <desc>Device slot number of this attachment.
8647 See <link to="IMachine::attachDevice" /> for the meaning of this value for the different controller types.
8648 </desc>
8649 </attribute>
8650
8651 <attribute name="type" type="DeviceType" readonly="yes">
8652 <desc>Device type of this attachment.</desc>
8653 </attribute>
8654
8655 <attribute name="passthrough" type="boolean" readonly="yes">
8656 <desc>Pass I/O requests through to a device on the host.</desc>
8657 </attribute>
8658
8659 <attribute name="bandwidthLimit" type="unsigned long">
8660 <desc>
8661 Maximum throughput allowed for this medium attachment, in units of 1 mbps.
8662 A zero value means uncapped/unlimited.
8663 </desc>
8664 </attribute>
8665
8666 </interface>
8667
8668 <interface
8669 name="IMedium" extends="$unknown"
8670 uuid="bfcf5b8c-5155-4f24-9414-9457054b16db"
8671 wsmap="managed"
8672 >
8673 <desc>
8674 The IMedium interface represents virtual storage for a machine's
8675 hard disks, CD/DVD or floppy drives. It will typically represent
8676 a disk image on the host, for example a VDI or VMDK file representing
8677 a virtual hard disk, or an ISO or RAW file representing virtual
8678 removable media, but can also point to a network location (e.g.
8679 for iSCSI targets).
8680
8681 Instances of IMedium are connected to virtual machines by way of
8682 medium attachments (see <link to="IMediumAttachment" />), which link
8683 the storage medium to a particular device slot of a storage controller
8684 of the virtual machine.
8685 In the VirtualBox API, virtual storage is therefore always represented
8686 by the following chain of object links:
8687
8688 <ul>
8689 <li><link to="IMachine::storageControllers"/> contains an array of
8690 storage controllers (IDE, SATA, SCSI, SAS or a floppy controller;
8691 these are instances of <link to="IStorageController"/>).</li>
8692 <li><link to="IMachine::mediumAttachments"/> contains an array of
8693 medium attachments (instances of <link to="IMediumAttachment"/>),
8694 each containing a storage controller from the above array, a
8695 port/device specification, and an instance of IMedium representing
8696 the medium storage (image file).
8697
8698 For removable media, the storage medium is optional; a medium
8699 attachment with no medium represents a CD/DVD or floppy drive
8700 with no medium inserted. By contrast, hard disk attachments
8701 will always have an IMedium object attached.</li>
8702 <li>Each IMedium in turn points to a storage unit (such as a file
8703 on the host computer or a network resource) that holds actual
8704 data. This location is represented by the <link to="#location"/>
8705 attribute.</li>
8706 </ul>
8707
8708 Existing media are opened using <link to="IVirtualBox::openMedium"/>;
8709 new hard disk media can be created with the VirtualBox API using the
8710 <link to="IVirtualBox::createHardDisk"/> method.
8711
8712 CD/DVD and floppy images (ISO and RAW files) are usually created outside
8713 VirtualBox, e.g. by storing a copy of the real medium of the corresponding
8714 type in a regular file.
8715
8716 Only for CD/DVDs and floppies, an IMedium instance can also represent a host
8717 drive; in that case the <link to="#id" /> attribute contains the UUID of
8718 one of the drives in <link to="IHost::DVDDrives" /> or <link to="IHost::floppyDrives" />.
8719
8720 <h3>Known media</h3>
8721
8722 When an existing medium is opened for the first time, it is automatically
8723 remembered by the given VirtualBox installation or, in other words, becomes
8724 a <i>known medium</i>. Known media are stored in the media
8725 registry transparently maintained by VirtualBox and stored in settings
8726 files so that this registry is preserved when VirtualBox is not running.
8727
8728 Newly created virtual media are remembered only when the associated
8729 storage unit is actually created.
8730
8731 All known media can be enumerated using
8732 <link to="IVirtualBox::hardDisks"/>,
8733 <link to="IVirtualBox::DVDImages"/> and
8734 <link to="IVirtualBox::floppyImages"/> attributes. Individual media can be
8735 quickly found using the <link to="IVirtualBox::findMedium"/> method.
8736
8737 Only known media can be attached to virtual machines.
8738
8739 Removing known media from the media registry is performed when the given
8740 medium is closed using the <link to="#close"/> method or when its
8741 associated storage unit is deleted.
8742
8743 <h3>Accessibility checks</h3>
8744
8745 VirtualBox defers media accessibility checks until the <link to="#refreshState" />
8746 method is called explicitly on a medium. This is done to make the VirtualBox object
8747 ready for serving requests as fast as possible and let the end-user
8748 application decide if it needs to check media accessibility right away or not.
8749
8750 As a result, when VirtualBox starts up (e.g. the VirtualBox
8751 object gets created for the first time), all known media are in the
8752 "Inaccessible" state, but the value of the <link to="#lastAccessError"/>
8753 attribute is an empty string because no actual accessibility check has
8754 been made yet.
8755
8756 After calling <link to="#refreshState" />, a medium is considered
8757 <i>accessible</i> if its storage unit can be read. In that case, the
8758 <link to="#state"/> attribute has a value of "Created". If the storage
8759 unit cannot be read (for example, because it is located on a disconnected
8760 network resource, or was accidentally deleted outside VirtualBox),
8761 the medium is considered <i>inaccessible</i>, which is indicated by the
8762 "Inaccessible" state. The exact reason why the medium is inaccessible can be
8763 obtained by reading the <link to="#lastAccessError"/> attribute.
8764
8765 <h3>Medium types</h3>
8766
8767 There are four types of medium behavior (see <link to="MediumType" />):
8768 "normal", "immutable", "writethrough" and "shareable", represented by the
8769 <link to="#type"/> attribute. The type of the medium defines how the
8770 medium is attached to a virtual machine and what happens when a
8771 <link to="ISnapshot">snapshot</link> of the virtual machine with the
8772 attached medium is taken. At the moment DVD and floppy media are always
8773 of type "writethrough".
8774
8775 All media can be also divided in two groups: <i>base</i> media and
8776 <i>differencing</i> media. A base medium contains all sectors of the
8777 medium data in its own storage and therefore can be used independently.
8778 In contrast, a differencing mediun is a "delta" to some other medium and
8779 contains only those sectors which differ from that other medium, which is
8780 then called a <i>parent</i>. The differencing medium is said to be
8781 <i>linked to</i> that parent. The parent may be itself a differencing
8782 medium, thus forming a chain of linked media. The last element in that
8783 chain must always be a base medium. Note that several differencing
8784 media may be linked to the same parent medium.
8785
8786 Differencing media can be distinguished from base media by querying the
8787 <link to="#parent"/> attribute: base media do not have parents they would
8788 depend on, so the value of this attribute is always @c null for them.
8789 Using this attribute, it is possible to walk up the medium tree (from the
8790 child medium to its parent). It is also possible to walk down the tree
8791 using the <link to="#children"/> attribute.
8792
8793 Note that the type of all differencing media is "normal"; all other
8794 values are meaningless for them. Base media may be of any type.
8795
8796 <h3>Creating hard disks</h3>
8797
8798 New base hard disks are created using
8799 <link to="IVirtualBox::createHardDisk"/>. Existing hard disks are
8800 opened using <link to="IVirtualBox::openMedium"/>. Differencing hard
8801 disks are usually implicitly created by VirtualBox when needed but may
8802 also be created explicitly using <link to="#createDiffStorage"/>.
8803
8804 After the hard disk is successfully created (including the storage unit)
8805 or opened, it becomes a known hard disk (remembered in the internal media
8806 registry). Known hard disks can be attached to a virtual machine, accessed
8807 through <link to="IVirtualBox::findMedium"/> or enumerated using the
8808 <link to="IVirtualBox::hardDisks"/> array (only for base hard disks).
8809
8810 The following methods, besides <link to="IMedium::close"/>,
8811 automatically remove the hard disk from the media registry:
8812 <ul>
8813 <li><link to="#deleteStorage"/></li>
8814 <li><link to="#mergeTo"/></li>
8815 </ul>
8816
8817 If the storage unit of the hard disk is a regular file in the host's
8818 file system then the rules stated in the description of the
8819 <link to="IMedium::location"/> attribute apply when setting its value. In
8820 addition, a plain file name without any path may be given, in which case
8821 the <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
8822 folder</link> will be prepended to it.
8823
8824 <h4>Automatic composition of the file name part</h4>
8825
8826 Another extension to the <link to="IMedium::location"/> attribute is that
8827 there is a possibility to cause VirtualBox to compose a unique value for
8828 the file name part of the location using the UUID of the hard disk. This
8829 applies only to hard disks in <link to="MediumState_NotCreated"/> state,
8830 e.g. before the storage unit is created, and works as follows. You set the
8831 value of the <link to="IMedium::location"/> attribute to a location
8832 specification which only contains the path specification but not the file
8833 name part and ends with either a forward slash or a backslash character.
8834 In response, VirtualBox will generate a new UUID for the hard disk and
8835 compose the file name using the following pattern:
8836 <pre>
8837 &lt;path&gt;/{&lt;uuid&gt;}.&lt;ext&gt;
8838 </pre>
8839 where <tt>&lt;path&gt;</tt> is the supplied path specification,
8840 <tt>&lt;uuid&gt;</tt> is the newly generated UUID and <tt>&lt;ext&gt;</tt>
8841 is the default extension for the storage format of this hard disk. After
8842 that, you may call any of the methods that create a new hard disk storage
8843 unit and they will use the generated UUID and file name.
8844
8845 <h3>Attaching Hard Disks</h3>
8846
8847 Hard disks are attached to virtual machines using the
8848 <link to="IMachine::attachDevice"/> method and detached using the
8849 <link to="IMachine::detachDevice"/> method. Depending on their
8850 <link to="#type"/>, hard disks are attached either
8851 <i>directly</i> or <i>indirectly</i>.
8852
8853 When a hard disk is being attached directly, it is associated with the
8854 virtual machine and used for hard disk operations when the machine is
8855 running. When a hard disk is being attached indirectly, a new differencing
8856 hard disk linked to it is implicitly created and this differencing hard
8857 disk is associated with the machine and used for hard disk operations.
8858 This also means that if <link to="IMachine::attachDevice"/> performs
8859 a direct attachment then the same hard disk will be returned in response
8860 to the subsequent <link to="IMachine::getMedium"/> call; however if
8861 an indirect attachment is performed then
8862 <link to="IMachine::getMedium"/> will return the implicitly created
8863 differencing hard disk, not the original one passed to <link
8864 to="IMachine::attachDevice"/>. In detail:
8865
8866 <ul>
8867 <li><b>Normal base</b> hard disks that do not have children (i.e.
8868 differencing hard disks linked to them) and that are not already
8869 attached to virtual machines in snapshots are attached <b>directly</b>.
8870 Otherwise, they are attached <b>indirectly</b> because having
8871 dependent children or being part of the snapshot makes it impossible
8872 to modify hard disk contents without breaking the integrity of the
8873 dependent party. The <link to="#readOnly"/> attribute allows to
8874 quickly determine the kind of the attachment for the given hard
8875 disk. Note that if a normal base hard disk is to be indirectly
8876 attached to a virtual machine with snapshots then a special
8877 procedure called <i>smart attachment</i> is performed (see below).</li>
8878 <li><b>Normal differencing</b> hard disks are like normal base hard disks:
8879 they are attached <b>directly</b> if they do not have children and are
8880 not attached to virtual machines in snapshots, and <b>indirectly</b>
8881 otherwise. Note that the smart attachment procedure is never performed
8882 for differencing hard disks.</li>
8883 <li><b>Immutable</b> hard disks are always attached <b>indirectly</b> because
8884 they are designed to be non-writable. If an immutable hard disk is
8885 attached to a virtual machine with snapshots then a special
8886 procedure called smart attachment is performed (see below).</li>
8887 <li><b>Writethrough</b> hard disks are always attached <b>directly</b>,
8888 also as designed. This also means that writethrough hard disks cannot
8889 have other hard disks linked to them at all.</li>
8890 <li><b>Shareable</b> hard disks are always attached <b>directly</b>,
8891 also as designed. This also means that shareable hard disks cannot
8892 have other hard disks linked to them at all. They behave almost
8893 like writethrough hard disks, except that shareable hard disks can
8894 be attached to several virtual machines which are running, allowing
8895 concurrent accesses. You need special cluster software running in
8896 the virtual machines to make use of such disks.</li>
8897 </ul>
8898
8899 Note that the same hard disk, regardless of its type, may be attached to
8900 more than one virtual machine at a time. In this case, the machine that is
8901 started first gains exclusive access to the hard disk and attempts to
8902 start other machines having this hard disk attached will fail until the
8903 first machine is powered down.
8904
8905 Detaching hard disks is performed in a <i>deferred</i> fashion. This means
8906 that the given hard disk remains associated with the given machine after a
8907 successful <link to="IMachine::detachDevice"/> call until
8908 <link to="IMachine::saveSettings"/> is called to save all changes to
8909 machine settings to disk. This deferring is necessary to guarantee that
8910 the hard disk configuration may be restored at any time by a call to
8911 <link to="IMachine::discardSettings"/> before the settings
8912 are saved (committed).
8913
8914 Note that if <link to="IMachine::discardSettings"/> is called after
8915 indirectly attaching some hard disks to the machine but before a call to
8916 <link to="IMachine::saveSettings"/> is made, it will implicitly delete
8917 all differencing hard disks implicitly created by
8918 <link to="IMachine::attachDevice"/> for these indirect attachments.
8919 Such implicitly created hard disks will also be immediately deleted when
8920 detached explicitly using the <link to="IMachine::detachDevice"/>
8921 call if it is made before <link to="IMachine::saveSettings"/>. This
8922 implicit deletion is safe because newly created differencing hard
8923 disks do not contain any user data.
8924
8925 However, keep in mind that detaching differencing hard disks that were
8926 implicitly created by <link to="IMachine::attachDevice"/>
8927 before the last <link to="IMachine::saveSettings"/> call will
8928 <b>not</b> implicitly delete them as they may already contain some data
8929 (for example, as a result of virtual machine execution). If these hard
8930 disks are no more necessary, the caller can always delete them explicitly
8931 using <link to="#deleteStorage"/> after they are actually de-associated
8932 from this machine by the <link to="IMachine::saveSettings"/> call.
8933
8934 <h3>Smart Attachment</h3>
8935
8936 When normal base or immutable hard disks are indirectly attached to a
8937 virtual machine then some additional steps are performed to make sure the
8938 virtual machine will have the most recent "view" of the hard disk being
8939 attached. These steps include walking through the machine's snapshots
8940 starting from the current one and going through ancestors up to the first
8941 snapshot. Hard disks attached to the virtual machine in all
8942 of the encountered snapshots are checked whether they are descendants of
8943 the given normal base or immutable hard disk. The first found child (which
8944 is the differencing hard disk) will be used instead of the normal base or
8945 immutable hard disk as a parent for creating a new differencing hard disk
8946 that will be actually attached to the machine. And only if no descendants
8947 are found or if the virtual machine does not have any snapshots then the
8948 normal base or immutable hard disk will be used itself as a parent for
8949 this differencing hard disk.
8950
8951 It is easier to explain what smart attachment does using the
8952 following example:
8953 <pre>
8954BEFORE attaching B.vdi: AFTER attaching B.vdi:
8955
8956Snapshot 1 (B.vdi) Snapshot 1 (B.vdi)
8957 Snapshot 2 (D1->B.vdi) Snapshot 2 (D1->B.vdi)
8958 Snapshot 3 (D2->D1.vdi) Snapshot 3 (D2->D1.vdi)
8959 Snapshot 4 (none) Snapshot 4 (none)
8960 CurState (none) CurState (D3->D2.vdi)
8961
8962 NOT
8963 ...
8964 CurState (D3->B.vdi)
8965 </pre>
8966 The first column is the virtual machine configuration before the base hard
8967 disk <tt>B.vdi</tt> is attached, the second column shows the machine after
8968 this hard disk is attached. Constructs like <tt>D1->B.vdi</tt> and similar
8969 mean that the hard disk that is actually attached to the machine is a
8970 differencing hard disk, <tt>D1.vdi</tt>, which is linked to (based on)
8971 another hard disk, <tt>B.vdi</tt>.
8972
8973 As we can see from the example, the hard disk <tt>B.vdi</tt> was detached
8974 from the machine before taking Snapshot 4. Later, after Snapshot 4 was
8975 taken, the user decides to attach <tt>B.vdi</tt> again. <tt>B.vdi</tt> has
8976 dependent child hard disks (<tt>D1.vdi</tt>, <tt>D2.vdi</tt>), therefore
8977 it cannot be attached directly and needs an indirect attachment (i.e.
8978 implicit creation of a new differencing hard disk). Due to the smart
8979 attachment procedure, the new differencing hard disk
8980 (<tt>D3.vdi</tt>) will be based on <tt>D2.vdi</tt>, not on
8981 <tt>B.vdi</tt> itself, since <tt>D2.vdi</tt> is the most recent view of
8982 <tt>B.vdi</tt> existing for this snapshot branch of the given virtual
8983 machine.
8984
8985 Note that if there is more than one descendant hard disk of the given base
8986 hard disk found in a snapshot, and there is an exact device, channel and
8987 bus match, then this exact match will be used. Otherwise, the youngest
8988 descendant will be picked up.
8989
8990 There is one more important aspect of the smart attachment procedure which
8991 is not related to snapshots at all. Before walking through the snapshots
8992 as described above, the backup copy of the current list of hard disk
8993 attachment is searched for descendants. This backup copy is created when
8994 the hard disk configuration is changed for the first time after the last
8995 <link to="IMachine::saveSettings"/> call and used by
8996 <link to="IMachine::discardSettings"/> to undo the recent hard disk
8997 changes. When such a descendant is found in this backup copy, it will be
8998 simply re-attached back, without creating a new differencing hard disk for
8999 it. This optimization is necessary to make it possible to re-attach the
9000 base or immutable hard disk to a different bus, channel or device slot
9001 without losing the contents of the differencing hard disk actually
9002 attached to the machine in place of it.
9003 </desc>
9004
9005 <attribute name="id" type="uuid" mod="string" readonly="yes">
9006 <desc>
9007 UUID of the medium. For a newly created medium, this value is a randomly
9008 generated UUID.
9009
9010 <note>
9011 For media in one of MediumState_NotCreated, MediumState_Creating or
9012 MediumState_Deleting states, the value of this property is undefined
9013 and will most likely be an empty UUID.
9014 </note>
9015 </desc>
9016 </attribute>
9017
9018 <attribute name="description" type="wstring">
9019 <desc>
9020 Optional description of the medium. For a newly created medium the value
9021 of this attribute is an empty string.
9022
9023 Medium types that don't support this attribute will return E_NOTIMPL in
9024 attempt to get or set this attribute's value.
9025
9026 <note>
9027 For some storage types, reading this attribute may return an outdated
9028 (last known) value when <link to="#state"/> is <link
9029 to="MediumState_Inaccessible"/> or <link
9030 to="MediumState_LockedWrite"/> because the value of this attribute is
9031 stored within the storage unit itself. Also note that changing the
9032 attribute value is not possible in such case, as well as when the
9033 medium is the <link to="MediumState_LockedRead"/> state.
9034 </note>
9035 </desc>
9036 </attribute>
9037
9038 <attribute name="state" type="MediumState" readonly="yes">
9039 <desc>
9040 Returns the current medium state, which is the last state set by
9041 the accessibility check performed by <link to="#refreshState"/>.
9042 If that method has not yet been called on the medium, the state
9043 is "Inaccessible"; as opposed to truly inaccessible media, the
9044 value of <link to="#lastAccessError"/> will be an empty string in
9045 that case.
9046
9047 <note>As of version 3.1, this no longer performs an accessibility check
9048 automatically; call <link to="#refreshState"/> for that.
9049 </note>
9050 </desc>
9051 </attribute>
9052
9053 <attribute name="variant" type="MediumVariant" readonly="yes">
9054 <desc>
9055 Returns the storage format variant information for this medium.
9056 Before <link to="#refreshState"/> is called this method returns
9057 an undefined value.
9058 </desc>
9059 </attribute>
9060
9061 <attribute name="location" type="wstring">
9062 <desc>
9063 Location of the storage unit holding medium data.
9064
9065 The format of the location string is medium type specific. For medium
9066 types using regular files in a host's file system, the location
9067 string is the full file name.
9068
9069 Some medium types may support changing the storage unit location by
9070 simply changing the value of this property. If this operation is not
9071 supported, the implementation will return E_NOTIMPL in attempt to set
9072 this attribute's value.
9073
9074 When setting a value of the location attribute which is a regular file
9075 in the host's file system, the given file name may be either relative to
9076 the <link to="IVirtualBox::homeFolder">VirtualBox home folder</link> or
9077 absolute. Note that if the given location specification does not contain
9078 the file extension part then a proper default extension will be
9079 automatically appended by the implementation depending on the medium type.
9080 </desc>
9081 </attribute>
9082
9083 <attribute name="name" type="wstring" readonly="yes">
9084 <desc>
9085 Name of the storage unit holding medium data.
9086
9087 The returned string is a short version of the <link to="#location"/>
9088 attribute that is suitable for representing the medium in situations
9089 where the full location specification is too long (such as lists
9090 and comboboxes in GUI frontends). This string is also used by frontends
9091 to sort the media list alphabetically when needed.
9092
9093 For example, for locations that are regular files in the host's file
9094 system, the value of this attribute is just the file name (+ extension),
9095 without the path specification.
9096
9097 Note that as opposed to the <link to="#location"/> attribute, the name
9098 attribute will not necessary be unique for a list of media of the
9099 given type and format.
9100 </desc>
9101 </attribute>
9102
9103 <attribute name="deviceType" type="DeviceType" readonly="yes">
9104 <desc>Kind of device (DVD/Floppy/HardDisk) which is applicable to this
9105 medium.</desc>
9106 </attribute>
9107
9108 <attribute name="hostDrive" type="boolean" readonly="yes">
9109 <desc>True if this corresponds to a drive on the host.</desc>
9110 </attribute>
9111
9112 <attribute name="size" type="long long" readonly="yes">
9113 <desc>
9114 Physical size of the storage unit used to hold medium data (in bytes).
9115
9116 <note>
9117 For media whose <link to="#state"/> is <link
9118 to="MediumState_Inaccessible"/>, the value of this property is the
9119 last known size. For <link to="MediumState_NotCreated"/> media,
9120 the returned value is zero.
9121 </note>
9122 </desc>
9123 </attribute>
9124
9125 <attribute name="format" type="wstring" readonly="yes">
9126 <desc>
9127 Storage format of this medium.
9128
9129 The value of this attribute is a string that specifies a backend used
9130 to store medium data. The storage format is defined when you create a
9131 new medium or automatically detected when you open an existing medium,
9132 and cannot be changed later.
9133
9134 The list of all storage formats supported by this VirtualBox
9135 installation can be obtained using
9136 <link to="ISystemProperties::mediumFormats"/>.
9137 </desc>
9138 </attribute>
9139
9140 <attribute name="mediumFormat" type="IMediumFormat" readonly="yes">
9141 <desc>
9142 Storage medium format object corresponding to this medium.
9143
9144 The value of this attribute is a reference to the medium format object
9145 that specifies the backend properties used to store medium data. The
9146 storage format is defined when you create a new medium or automatically
9147 detected when you open an existing medium, and cannot be changed later.
9148
9149 <note>@c null is returned if there is no associated medium format
9150 object. This can e.g. happen for medium objects representing host
9151 drives and other special medium objects.</note>
9152 </desc>
9153 </attribute>
9154
9155 <attribute name="type" type="MediumType">
9156 <desc>
9157 Type (role) of this medium.
9158
9159 The following constraints apply when changing the value of this
9160 attribute:
9161 <ul>
9162 <li>If a medium is attached to a virtual machine (either in the
9163 current state or in one of the snapshots), its type cannot be
9164 changed.
9165 </li>
9166 <li>As long as the medium has children, its type cannot be set
9167 to <link to="MediumType_Writethrough"/>.
9168 </li>
9169 <li>The type of all differencing media is
9170 <link to="MediumType_Normal"/> and cannot be changed.
9171 </li>
9172 </ul>
9173
9174 The type of a newly created or opened medium is set to
9175 <link to="MediumType_Normal"/>, except for DVD and floppy media,
9176 which have a type of <link to="MediumType_Writethrough"/>.
9177 </desc>
9178 </attribute>
9179
9180 <attribute name="parent" type="IMedium" readonly="yes">
9181 <desc>
9182 Parent of this medium (the medium this medium is directly based
9183 on).
9184
9185 Only differencing media have parents. For base (non-differencing)
9186 media, @c null is returned.
9187 </desc>
9188 </attribute>
9189
9190 <attribute name="children" type="IMedium" safearray="yes" readonly="yes">
9191 <desc>
9192 Children of this medium (all differencing media directly based
9193 on this medium). A @c null array is returned if this medium
9194 does not have any children.
9195 </desc>
9196 </attribute>
9197
9198 <attribute name="base" type="IMedium" readonly="yes">
9199 <desc>
9200 Base medium of this medium.
9201
9202 If this is a differencing medium, its base medium is the medium
9203 the given medium branch starts from. For all other types of media, this
9204 property returns the medium object itself (i.e. the same object this
9205 property is read on).
9206 </desc>
9207 </attribute>
9208
9209 <attribute name="readOnly" type="boolean" readonly="yes">
9210 <desc>
9211 Returns @c true if this medium is read-only and @c false otherwise.
9212
9213 A medium is considered to be read-only when its contents cannot be
9214 modified without breaking the integrity of other parties that depend on
9215 this medium such as its child media or snapshots of virtual machines
9216 where this medium is attached to these machines. If there are no
9217 children and no such snapshots then there is no dependency and the
9218 medium is not read-only.
9219
9220 The value of this attribute can be used to determine the kind of the
9221 attachment that will take place when attaching this medium to a
9222 virtual machine. If the value is @c false then the medium will
9223 be attached directly. If the value is @c true then the medium
9224 will be attached indirectly by creating a new differencing child
9225 medium for that. See the interface description for more information.
9226
9227 Note that all <link to="MediumType_Immutable">Immutable</link> media
9228 are always read-only while all
9229 <link to="MediumType_Writethrough">Writethrough</link> media are
9230 always not.
9231
9232 <note>
9233 The read-only condition represented by this attribute is related to
9234 the medium type and usage, not to the current
9235 <link to="IMedium::state">medium state</link> and not to the read-only
9236 state of the storage unit.
9237 </note>
9238 </desc>
9239 </attribute>
9240
9241 <attribute name="logicalSize" type="long long" readonly="yes">
9242 <desc>
9243 Logical size of this medium (in bytes), as reported to the
9244 guest OS running inside the virtual machine this medium is
9245 attached to. The logical size is defined when the medium is created
9246 and cannot be changed later.
9247
9248 <note>
9249 Reading this property on a differencing medium will return the size
9250 of its <link to="#base"/> medium.
9251 </note>
9252 <note>
9253 For media whose state is <link to="#state"/> is <link
9254 to="MediumState_Inaccessible"/>, the value of this property is the
9255 last known logical size. For <link to="MediumState_NotCreated"/>
9256 media, the returned value is zero.
9257 </note>
9258 </desc>
9259 </attribute>
9260
9261 <attribute name="autoReset" type="boolean">
9262 <desc>
9263 Whether this differencing medium will be automatically reset each
9264 time a virtual machine it is attached to is powered up. This
9265 attribute is automatically set to @c true for the last
9266 differencing image of an "immutable" medium (see
9267 <link to="MediumType" />).
9268
9269 See <link to="#reset"/> for more information about resetting
9270 differencing media.
9271
9272 <note>
9273 Reading this property on a base (non-differencing) medium will
9274 always @c false. Changing the value of this property in this
9275 case is not supported.
9276 </note>
9277
9278 <result name="VBOX_E_NOT_SUPPORTED">
9279 This is not a differencing medium (when changing the attribute
9280 value).
9281 </result>
9282 </desc>
9283 </attribute>
9284
9285 <attribute name="lastAccessError" type="wstring" readonly="yes">
9286 <desc>
9287 Text message that represents the result of the last accessibility
9288 check performed by <link to="#refreshState"/>.
9289
9290 An empty string is returned if the last accessibility check
9291 was successful or has not yet been called. As a result, if
9292 <link to="#state" /> is "Inaccessible" and this attribute is empty,
9293 then <link to="#refreshState"/> has yet to be called; this is the
9294 default value of media after VirtualBox initialization.
9295 A non-empty string indicates a failure and should normally describe
9296 a reason of the failure (for example, a file read error).
9297 </desc>
9298 </attribute>
9299
9300 <attribute name="machineIds" type="uuid" mod="string" safearray="yes" readonly="yes">
9301 <desc>
9302 Array of UUIDs of all machines this medium is attached to.
9303
9304 A @c null array is returned if this medium is not attached to any
9305 machine or to any machine's snapshot.
9306
9307 <note>
9308 The returned array will include a machine even if this medium is not
9309 attached to that machine in the current state but attached to it in
9310 one of the machine's snapshots. See <link to="#getSnapshotIds"/> for
9311 details.
9312 </note>
9313 </desc>
9314 </attribute>
9315
9316 <method name="setIDs">
9317 <desc>
9318 Changes the UUID and parent UUID for a hard disk medium.
9319 </desc>
9320 <param name="setImageId" type="boolean" dir="in">
9321 <desc>
9322 Select whether a new image UUID is set or not.
9323 </desc>
9324 </param>
9325 <param name="imageId" type="uuid" mod="string" dir="in">
9326 <desc>
9327 New UUID for the image. If an empty string is passed, then a new
9328 UUID is automatically created, provided that @a setImageId is @c true.
9329 Specifying a zero UUID is not allowed.
9330 </desc>
9331 </param>
9332 <param name="setParentId" type="boolean" dir="in">
9333 <desc>
9334 Select whether a new parent UUID is set or not.
9335 </desc>
9336 </param>
9337 <param name="parentId" type="uuid" mod="string" dir="in">
9338 <desc>
9339 New parent UUID for the image. If an empty string is passed, then a
9340 new UUID is automatically created, provided @a setParentId is
9341 @c true. A zero UUID is valid.
9342 </desc>
9343 </param>
9344 <result name="E_INVALIDARG">
9345 Invalid parameter combination.
9346 </result>
9347 <result name="VBOX_E_NOT_SUPPORTED">
9348 Medium is not a hard disk medium.
9349 </result>
9350 </method>
9351
9352 <method name="refreshState">
9353 <desc>
9354 If the current medium state (see <link to="MediumState"/>) is one of
9355 "Created", "Inaccessible" or "LockedRead", then this performs an
9356 accessibility check on the medium and sets the value of the <link to="#state"/>
9357 attribute accordingly; that value is also returned for convenience.
9358
9359 For all other state values, this does not perform a refresh but returns
9360 the state only.
9361
9362 The refresh, if performed, may take a long time (several seconds or even
9363 minutes, depending on the storage unit location and format) because it performs an
9364 accessibility check of the storage unit. This check may cause a significant
9365 delay if the storage unit of the given medium is, for example, a file located
9366 on a network share which is not currently accessible due to connectivity
9367 problems. In that case, the call will not return until a timeout
9368 interval defined by the host OS for this operation expires. For this reason,
9369 it is recommended to never read this attribute on the main UI thread to avoid
9370 making the UI unresponsive.
9371
9372 If the last known state of the medium is "Created" and the accessibility
9373 check fails, then the state would be set to "Inaccessible", and
9374 <link to="#lastAccessError"/> may be used to get more details about the
9375 failure. If the state of the medium is "LockedRead", then it remains the
9376 same, and a non-empty value of <link to="#lastAccessError"/> will
9377 indicate a failed accessibility check in this case.
9378
9379 Note that not all medium states are applicable to all medium types.
9380 </desc>
9381 <param name="state" type="MediumState" dir="return">
9382 <desc>
9383 New medium state.
9384 </desc>
9385 </param>
9386 </method>
9387
9388 <method name="getSnapshotIds">
9389 <desc>
9390 Returns an array of UUIDs of all snapshots of the given machine where
9391 this medium is attached to.
9392
9393 If the medium is attached to the machine in the current state, then the
9394 first element in the array will always be the ID of the queried machine
9395 (i.e. the value equal to the @c machineId argument), followed by
9396 snapshot IDs (if any).
9397
9398 If the medium is not attached to the machine in the current state, then
9399 the array will contain only snapshot IDs.
9400
9401 The returned array may be @c null if this medium is not attached
9402 to the given machine at all, neither in the current state nor in one of
9403 the snapshots.
9404 </desc>
9405 <param name="machineId" type="uuid" mod="string" dir="in">
9406 <desc>
9407 UUID of the machine to query.
9408 </desc>
9409 </param>
9410 <param name="snapshotIds" type="uuid" mod="string" safearray="yes" dir="return">
9411 <desc>
9412 Array of snapshot UUIDs of the given machine using this medium.
9413 </desc>
9414 </param>
9415 </method>
9416
9417 <method name="lockRead">
9418 <desc>
9419 Locks this medium for reading.
9420
9421 A read lock is shared: many clients can simultaneously lock the
9422 same medium for reading unless it is already locked for writing (see
9423 <link to="#lockWrite"/>) in which case an error is returned.
9424
9425 When the medium is locked for reading, it cannot be modified
9426 from within VirtualBox. This means that any method that changes
9427 the properties of this medium or contents of the storage unit
9428 will return an error (unless explicitly stated otherwise). That
9429 includes an attempt to start a virtual machine that wants to
9430 write to the the medium.
9431
9432 When the virtual machine is started up, it locks for reading all
9433 media it uses in read-only mode. If some medium cannot be locked
9434 for reading, the startup procedure will fail.
9435 A medium is typically locked for reading while it is used by a running
9436 virtual machine but has a depending differencing image that receives
9437 the actual write operations. This way one base medium can have
9438 multiple child differencing images which can be written to
9439 simultaneously. Read-only media such as DVD and floppy images are
9440 also locked for reading only (so they can be in use by multiple
9441 machines simultaneously).
9442
9443 A medium is also locked for reading when it is the source of a
9444 write operation such as <link to="#cloneTo"/> or <link to="#mergeTo"/>.
9445
9446 The medium locked for reading must be unlocked using the <link
9447 to="#unlockRead"/> method. Calls to <link to="#lockRead"/>
9448 can be nested and must be followed by the same number of paired
9449 <link to="#unlockRead"/> calls.
9450
9451 This method sets the medium state (see <link to="#state"/>) to
9452 "LockedRead" on success. The medium's previous state must be
9453 one of "Created", "Inaccessible" or "LockedRead".
9454
9455 Locking an inaccessible medium is not an error; this method performs
9456 a logical lock that prevents modifications of this medium through
9457 the VirtualBox API, not a physical file-system lock of the underlying
9458 storage unit.
9459
9460 This method returns the current state of the medium
9461 <i>before</i> the operation.
9462
9463 <result name="VBOX_E_INVALID_OBJECT_STATE">
9464 Invalid medium state (e.g. not created, locked, inaccessible,
9465 creating, deleting).
9466 </result>
9467
9468 </desc>
9469 <param name="state" type="MediumState" dir="return">
9470 <desc>
9471 State of the medium after the operation.
9472 </desc>
9473 </param>
9474 </method>
9475
9476 <method name="unlockRead">
9477 <desc>
9478 Cancels the read lock previously set by <link to="#lockRead"/>.
9479
9480 For both success and failure, this method returns the current state
9481 of the medium <i>after</i> the operation.
9482
9483 See <link to="#lockRead"/> for more details.
9484
9485 <result name="VBOX_E_INVALID_OBJECT_STATE">
9486 Medium not locked for reading.
9487 </result>
9488
9489 </desc>
9490 <param name="state" type="MediumState" dir="return">
9491 <desc>
9492 State of the medium after the operation.
9493 </desc>
9494 </param>
9495 </method>
9496
9497 <method name="lockWrite">
9498 <desc>
9499 Locks this medium for writing.
9500
9501 A write lock, as opposed to <link to="#lockRead"/>, is
9502 exclusive: there may be only one client holding a write lock,
9503 and there may be no read locks while the write lock is held.
9504 As a result, read-locking fails if a write lock is held, and
9505 write-locking fails if either a read or another write lock is held.
9506
9507 When a medium is locked for writing, it cannot be modified
9508 from within VirtualBox, and it is not guaranteed that the values
9509 of its properties are up-to-date. Any method that changes the
9510 properties of this medium or contents of the storage unit will
9511 return an error (unless explicitly stated otherwise).
9512
9513 When a virtual machine is started up, it locks for writing all
9514 media it uses to write data to. If any medium could not be locked
9515 for writing, the startup procedure will fail. If a medium has
9516 differencing images, then while the machine is running, only
9517 the last ("leaf") differencing image is locked for writing,
9518 whereas its parents are locked for reading only.
9519
9520 A medium is also locked for writing when it is the target of a
9521 write operation such as <link to="#cloneTo"/> or <link to="#mergeTo"/>.
9522
9523 The medium locked for writing must be unlocked using the <link
9524 to="#unlockWrite"/> method. Write locks <i>cannot</i> be nested.
9525
9526 This method sets the medium state (see <link to="#state"/>) to
9527 "LockedWrite" on success. The medium's previous state must be
9528 either "Created" or "Inaccessible".
9529
9530 Locking an inaccessible medium is not an error; this method performs
9531 a logical lock that prevents modifications of this medium through
9532 the VirtualBox API, not a physical file-system lock of the underlying
9533 storage unit.
9534
9535 For both, success and failure, this method returns the current
9536 state of the medium <i>before</i> the operation.
9537
9538 <result name="VBOX_E_INVALID_OBJECT_STATE">
9539 Invalid medium state (e.g. not created, locked, inaccessible,
9540 creating, deleting).
9541 </result>
9542
9543 </desc>
9544 <param name="state" type="MediumState" dir="return">
9545 <desc>
9546 State of the medium after the operation.
9547 </desc>
9548 </param>
9549 </method>
9550
9551 <method name="unlockWrite">
9552 <desc>
9553 Cancels the write lock previously set by <link to="#lockWrite"/>.
9554
9555 For both success and failure, this method returns the current
9556 state of the medium <i>after</i> the operation.
9557
9558 See <link to="#lockWrite"/> for more details.
9559
9560 <result name="VBOX_E_INVALID_OBJECT_STATE">
9561 Medium not locked for writing.
9562 </result>
9563
9564 </desc>
9565 <param name="state" type="MediumState" dir="return">
9566 <desc>
9567 State of the medium after the operation.
9568 </desc>
9569 </param>
9570 </method>
9571
9572 <method name="close">
9573 <desc>
9574 Closes this medium.
9575
9576 The medium must not be attached to any known virtual machine
9577 and must not have any known child media, otherwise the
9578 operation will fail.
9579
9580 When the medium is successfully closed, it is removed from
9581 the list of registered media, but its storage unit is not
9582 deleted. In particular, this means that this medium can
9583 later be opened again using the <link to="IVirtualBox::openMedium"/>
9584 call.
9585
9586 Note that after this method successfully returns, the given medium
9587 object becomes uninitialized. This means that any attempt
9588 to call any of its methods or attributes will fail with the
9589 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error.
9590
9591 <result name="VBOX_E_INVALID_OBJECT_STATE">
9592 Invalid medium state (other than not created, created or
9593 inaccessible).
9594 </result>
9595 <result name="VBOX_E_OBJECT_IN_USE">
9596 Medium attached to virtual machine.
9597 </result>
9598 <result name="VBOX_E_FILE_ERROR">
9599 Settings file not accessible.
9600 </result>
9601 <result name="VBOX_E_XML_ERROR">
9602 Could not parse the settings file.
9603 </result>
9604
9605 </desc>
9606 </method>
9607
9608 <!-- storage methods -->
9609
9610 <method name="getProperty">
9611 <desc>
9612 Returns the value of the custom medium property with the given name.
9613
9614 The list of all properties supported by the given medium format can
9615 be obtained with <link to="IMediumFormat::describeProperties"/>.
9616
9617 Note that if this method returns an empty string in @a value, the
9618 requested property is supported but currently not assigned any value.
9619
9620 <result name="VBOX_E_OBJECT_NOT_FOUND">
9621 Requested property does not exist (not supported by the format).
9622 </result>
9623 <result name="E_INVALIDARG">@a name is @c null or empty.</result>
9624 </desc>
9625 <param name="name" type="wstring" dir="in">
9626 <desc>Name of the property to get.</desc>
9627 </param>
9628 <param name="value" type="wstring" dir="return">
9629 <desc>Current property value.</desc>
9630 </param>
9631 </method>
9632
9633 <method name="setProperty">
9634 <desc>
9635 Sets the value of the custom medium property with the given name.
9636
9637 The list of all properties supported by the given medium format can
9638 be obtained with <link to="IMediumFormat::describeProperties"/>.
9639
9640 Note that setting the property value to @c null or an empty string is
9641 equivalent to deleting the existing value. A default value (if it is
9642 defined for this property) will be used by the format backend in this
9643 case.
9644
9645 <result name="VBOX_E_OBJECT_NOT_FOUND">
9646 Requested property does not exist (not supported by the format).
9647 </result>
9648 <result name="E_INVALIDARG">@a name is @c null or empty.</result>
9649 </desc>
9650 <param name="name" type="wstring" dir="in">
9651 <desc>Name of the property to set.</desc>
9652 </param>
9653 <param name="value" type="wstring" dir="in">
9654 <desc>Property value to set.</desc>
9655 </param>
9656 </method>
9657
9658 <method name="getProperties">
9659 <desc>
9660 Returns values for a group of properties in one call.
9661
9662 The names of the properties to get are specified using the @a names
9663 argument which is a list of comma-separated property names or
9664 an empty string if all properties are to be returned. Note that currently
9665 the value of this argument is ignored and the method always returns all
9666 existing properties.
9667
9668 The list of all properties supported by the given medium format can
9669 be obtained with <link to="IMediumFormat::describeProperties"/>.
9670
9671 The method returns two arrays, the array of property names corresponding
9672 to the @a names argument and the current values of these properties.
9673 Both arrays have the same number of elements with each elemend at the
9674 given index in the first array corresponds to an element at the same
9675 index in the second array.
9676
9677 Note that for properties that do not have assigned values,
9678 an empty string is returned at the appropriate index in the
9679 @a returnValues array.
9680
9681 </desc>
9682 <param name="names" type="wstring" dir="in">
9683 <desc>
9684 Names of properties to get.
9685 </desc>
9686 </param>
9687 <param name="returnNames" type="wstring" safearray="yes" dir="out">
9688 <desc>Names of returned properties.</desc>
9689 </param>
9690 <param name="returnValues" type="wstring" safearray="yes" dir="return">
9691 <desc>Values of returned properties.</desc>
9692 </param>
9693 </method>
9694
9695 <method name="setProperties">
9696 <desc>
9697 Sets values for a group of properties in one call.
9698
9699 The names of the properties to set are passed in the @a names
9700 array along with the new values for them in the @a values array. Both
9701 arrays have the same number of elements with each elemend at the given
9702 index in the first array corresponding to an element at the same index
9703 in the second array.
9704
9705 If there is at least one property name in @a names that is not valid,
9706 the method will fail before changing the values of any other properties
9707 from the @a names array.
9708
9709 Using this method over <link to="#setProperty"/> is preferred if you
9710 need to set several properties at once since it will result into less
9711 IPC calls.
9712
9713 The list of all properties supported by the given medium format can
9714 be obtained with <link to="IMediumFormat::describeProperties"/>.
9715
9716 Note that setting the property value to @c null or an empty string is
9717 equivalent to deleting the existing value. A default value (if it is
9718 defined for this property) will be used by the format backend in this
9719 case.
9720 </desc>
9721 <param name="names" type="wstring" safearray="yes" dir="in">
9722 <desc>Names of properties to set.</desc>
9723 </param>
9724 <param name="values" type="wstring" safearray="yes" dir="in">
9725 <desc>Values of properties to set.</desc>
9726 </param>
9727 </method>
9728
9729 <!-- storage methods -->
9730
9731 <method name="createBaseStorage">
9732 <desc>
9733 Starts creating a hard disk storage unit (fixed/dynamic, according
9734 to the variant flags) in in the background. The previous storage unit
9735 created for this object, if any, must first be deleted using
9736 <link to="#deleteStorage"/>, otherwise the operation will fail.
9737
9738 Before the operation starts, the medium is placed in
9739 <link to="MediumState_Creating"/> state. If the create operation
9740 fails, the medium will be placed back in <link to="MediumState_NotCreated"/>
9741 state.
9742
9743 After the returned progress object reports that the operation has
9744 successfully completed, the medium state will be set to <link
9745 to="MediumState_Created"/>, the medium will be remembered by this
9746 VirtualBox installation and may be attached to virtual machines.
9747
9748 <result name="VBOX_E_NOT_SUPPORTED">
9749 The variant of storage creation operation is not supported. See <link
9750 to="IMediumFormat::capabilities"/>.
9751 </result>
9752 </desc>
9753 <param name="logicalSize" type="long long" dir="in">
9754 <desc>Maximum logical size of the medium in bytes.</desc>
9755 </param>
9756 <param name="variant" type="MediumVariant" dir="in">
9757 <desc>Exact image variant which should be created.</desc>
9758 </param>
9759 <param name="progress" type="IProgress" dir="return">
9760 <desc>Progress object to track the operation completion.</desc>
9761 </param>
9762 </method>
9763
9764 <method name="deleteStorage">
9765 <desc>
9766 Starts deleting the storage unit of this medium.
9767
9768 The medium must not be attached to any known virtual machine and must
9769 not have any known child media, otherwise the operation will fail.
9770 It will also fail if there is no storage unit to delete or if deletion
9771 is already in progress, or if the medium is being in use (locked for
9772 read or for write) or inaccessible. Therefore, the only valid state for
9773 this operation to succeed is <link to="MediumState_Created"/>.
9774
9775 Before the operation starts, the medium is placed in
9776 <link to="MediumState_Deleting"/> state and gets removed from the list
9777 of remembered hard disks (media registry). If the delete operation
9778 fails, the medium will be remembered again and placed back to
9779 <link to="MediumState_Created"/> state.
9780
9781 After the returned progress object reports that the operation is
9782 complete, the medium state will be set to
9783 <link to="MediumState_NotCreated"/> and you will be able to use one of
9784 the storage creation methods to create it again.
9785
9786 <see>#close()</see>
9787
9788 <result name="VBOX_E_OBJECT_IN_USE">
9789 Medium is attached to a virtual machine.
9790 </result>
9791 <result name="VBOX_E_NOT_SUPPORTED">
9792 Storage deletion is not allowed because neither of storage creation
9793 operations are supported. See
9794 <link to="IMediumFormat::capabilities"/>.
9795 </result>
9796
9797 <note>
9798 If the deletion operation fails, it is not guaranteed that the storage
9799 unit still exists. You may check the <link to="IMedium::state"/> value
9800 to answer this question.
9801 </note>
9802 </desc>
9803 <param name="progress" type="IProgress" dir="return">
9804 <desc>Progress object to track the operation completion.</desc>
9805 </param>
9806 </method>
9807
9808 <!-- diff methods -->
9809
9810 <method name="createDiffStorage">
9811 <desc>
9812 Starts creating an empty differencing storage unit based on this
9813 medium in the format and at the location defined by the @a target
9814 argument.
9815
9816 The target medium must be in <link to="MediumState_NotCreated"/>
9817 state (i.e. must not have an existing storage unit). Upon successful
9818 completion, this operation will set the type of the target medium to
9819 <link to="MediumType_Normal"/> and create a storage unit necessary to
9820 represent the differencing medium data in the given format (according
9821 to the storage format of the target object).
9822
9823 After the returned progress object reports that the operation is
9824 successfully complete, the target medium gets remembered by this
9825 VirtualBox installation and may be attached to virtual machines.
9826
9827 <note>
9828 The medium will be set to <link to="MediumState_LockedRead"/>
9829 state for the duration of this operation.
9830 </note>
9831 <result name="VBOX_E_OBJECT_IN_USE">
9832 Medium not in @c NotCreated state.
9833 </result>
9834 </desc>
9835 <param name="target" type="IMedium" dir="in">
9836 <desc>Target medium.</desc>
9837 </param>
9838 <param name="variant" type="MediumVariant" dir="in">
9839 <desc>Exact image variant which should be created.</desc>
9840 </param>
9841 <param name="progress" type="IProgress" dir="return">
9842 <desc>Progress object to track the operation completion.</desc>
9843 </param>
9844 </method>
9845
9846 <method name="mergeTo">
9847 <desc>
9848 Starts merging the contents of this medium and all intermediate
9849 differencing media in the chain to the given target medium.
9850
9851 The target medium must be either a descendant of this medium or
9852 its ancestor (otherwise this method will immediately return a failure).
9853 It follows that there are two logical directions of the merge operation:
9854 from ancestor to descendant (<i>forward merge</i>) and from descendant to
9855 ancestor (<i>backward merge</i>). Let us consider the following medium
9856 chain:
9857
9858 <pre>Base &lt;- Diff_1 &lt;- Diff_2</pre>
9859
9860 Here, calling this method on the <tt>Base</tt> medium object with
9861 <tt>Diff_2</tt> as an argument will be a forward merge; calling it on
9862 <tt>Diff_2</tt> with <tt>Base</tt> as an argument will be a backward
9863 merge. Note that in both cases the contents of the resulting medium
9864 will be the same, the only difference is the medium object that takes
9865 the result of the merge operation. In case of the forward merge in the
9866 above example, the result will be written to <tt>Diff_2</tt>; in case of
9867 the backward merge, the result will be written to <tt>Base</tt>. In
9868 other words, the result of the operation is always stored in the target
9869 medium.
9870
9871 Upon successful operation completion, the storage units of all media in
9872 the chain between this (source) medium and the target medium, including
9873 the source medium itself, will be automatically deleted and the
9874 relevant medium objects (including this medium) will become
9875 uninitialized. This means that any attempt to call any of
9876 their methods or attributes will fail with the
9877 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error. Applied to the above
9878 example, the forward merge of <tt>Base</tt> to <tt>Diff_2</tt> will
9879 delete and uninitialize both <tt>Base</tt> and <tt>Diff_1</tt> media.
9880 Note that <tt>Diff_2</tt> in this case will become a base medium
9881 itself since it will no longer be based on any other medium.
9882
9883 Considering the above, all of the following conditions must be met in
9884 order for the merge operation to succeed:
9885 <ul>
9886 <li>
9887 Neither this (source) medium nor any intermediate
9888 differencing medium in the chain between it and the target
9889 medium is attached to any virtual machine.
9890 </li>
9891 <li>
9892 Neither the source medium nor the target medium is an
9893 <link to="MediumType_Immutable"/> medium.
9894 </li>
9895 <li>
9896 The part of the medium tree from the source medium to the
9897 target medium is a linear chain, i.e. all medium in this
9898 chain have exactly one child which is the next medium in this
9899 chain. The only exception from this rule is the target medium in
9900 the forward merge operation; it is allowed to have any number of
9901 child media because the merge operation will not change its
9902 logical contents (as it is seen by the guest OS or by children).
9903 </li>
9904 <li>
9905 None of the involved media are in
9906 <link to="MediumState_LockedRead"/> or
9907 <link to="MediumState_LockedWrite"/> state.
9908 </li>
9909 </ul>
9910
9911 <note>
9912 This (source) medium and all intermediates will be placed to <link
9913 to="MediumState_Deleting"/> state and the target medium will be
9914 placed to <link to="MediumState_LockedWrite"/> state and for the
9915 duration of this operation.
9916 </note>
9917 </desc>
9918 <param name="target" type="IMedium" dir="in">
9919 <desc>Target medium.</desc>
9920 </param>
9921 <param name="progress" type="IProgress" dir="return">
9922 <desc>Progress object to track the operation completion.</desc>
9923 </param>
9924 </method>
9925
9926 <!-- clone method -->
9927
9928 <method name="cloneTo">
9929 <desc>
9930 Starts creating a clone of this medium in the format and at the
9931 location defined by the @a target argument.
9932
9933 The target medium must be either in <link to="MediumState_NotCreated"/>
9934 state (i.e. must not have an existing storage unit) or in
9935 <link to="MediumState_Created"/> state (i.e. created and not locked, and
9936 big enough to hold the data or else the copy will be partial). Upon
9937 successful completion, the cloned medium will contain exactly the
9938 same sector data as the medium being cloned, except that in the
9939 first case a new UUID for the clone will be randomly generated, and in
9940 the second case the UUID will remain unchanged.
9941
9942 The @a parent argument defines which medium will be the parent
9943 of the clone. Passing a @c null reference indicates that the clone will
9944 be a base image, i.e. completely independent. It is possible to specify
9945 an arbitrary medium for this parameter, including the parent of the
9946 medium which is being cloned. Even cloning to a child of the source
9947 medium is possible. Note that when cloning to an existing image, the
9948 @a parent irgument is ignored.
9949
9950 After the returned progress object reports that the operation is
9951 successfully complete, the target medium gets remembered by this
9952 VirtualBox installation and may be attached to virtual machines.
9953
9954 <note>
9955 This medium will be placed to <link to="MediumState_LockedRead"/>
9956 state for the duration of this operation.
9957 </note>
9958 <result name="E_NOTIMPL">
9959 The specified cloning variant is not supported at the moment.
9960 </result>
9961 </desc>
9962 <param name="target" type="IMedium" dir="in">
9963 <desc>Target medium.</desc>
9964 </param>
9965 <param name="variant" type="MediumVariant" dir="in">
9966 <desc>Exact image variant which should be created.</desc>
9967 </param>
9968 <param name="parent" type="IMedium" dir="in">
9969 <desc>Parent of the cloned medium.</desc>
9970 </param>
9971 <param name="progress" type="IProgress" dir="return">
9972 <desc>Progress object to track the operation completion.</desc>
9973 </param>
9974 </method>
9975
9976 <!-- other methods -->
9977
9978 <method name="compact">
9979 <desc>
9980 Starts compacting of this medium. This means that the medium is
9981 transformed into a possibly more compact storage representation.
9982 This potentially creates temporary images, which can require a
9983 substantial amount of additional disk space.
9984
9985 This medium will be placed to <link to="MediumState_LockedWrite"/>
9986 state and all its parent media (if any) will be placed to
9987 <link to="MediumState_LockedRead"/> state for the duration of this
9988 operation.
9989
9990 Please note that the results can be either returned straight away,
9991 or later as the result of the background operation via the object
9992 returned via the @a progress parameter.
9993
9994 <result name="VBOX_E_NOT_SUPPORTED">
9995 Medium format does not support compacting (but potentially
9996 needs it).
9997 </result>
9998 </desc>
9999 <param name="progress" type="IProgress" dir="return">
10000 <desc>Progress object to track the operation completion.</desc>
10001 </param>
10002 </method>
10003
10004 <method name="resize">
10005 <desc>
10006 Starts resizing this medium. This means that the nominal size of the
10007 medium is set to the new value. Both increasing and decreasing the
10008 size is possible, and there are no safety checks, since VirtualBox
10009 does not make any assumptions about the medium contents.
10010
10011 Resizing usually needs additional disk space, and possibly also
10012 some temporary disk space. Note that resize does not create a full
10013 temporary copy of the medium, so the additional disk space requirement
10014 is usually much lower than using the clone operation.
10015
10016 This medium will be placed to <link to="MediumState_LockedWrite"/>
10017 state for the duration of this operation.
10018
10019 Please note that the results can be either returned straight away,
10020 or later as the result of the background operation via the object
10021 returned via the @a progress parameter.
10022
10023 <result name="VBOX_E_NOT_SUPPORTED">
10024 Medium format does not support resizing.
10025 </result>
10026 </desc>
10027 <param name="logicalSize" type="long long" dir="in">
10028 <desc>New nominal capacity of the medium in bytes.</desc>
10029 </param>
10030 <param name="progress" type="IProgress" dir="return">
10031 <desc>Progress object to track the operation completion.</desc>
10032 </param>
10033 </method>
10034
10035 <method name="reset">
10036 <desc>
10037 Starts erasing the contents of this differencing medium.
10038
10039 This operation will reset the differencing medium to its initial
10040 state when it does not contain any sector data and any read operation is
10041 redirected to its parent medium. This automatically gets called
10042 during VM power-up for every medium whose <link to="#autoReset" />
10043 attribute is @c true.
10044
10045 The medium will be write-locked for the duration of this operation (see
10046 <link to="#lockWrite" />).
10047
10048 <result name="VBOX_E_NOT_SUPPORTED">
10049 This is not a differencing medium.
10050 </result>
10051 <result name="VBOX_E_INVALID_OBJECT_STATE">
10052 Medium is not in <link to="MediumState_Created"/> or
10053 <link to="MediumState_Inaccessible"/> state.
10054 </result>
10055 </desc>
10056 <param name="progress" type="IProgress" dir="return">
10057 <desc>Progress object to track the operation completion.</desc>
10058 </param>
10059 </method>
10060
10061 </interface>
10062
10063
10064 <!--
10065 // IMediumFormat
10066 /////////////////////////////////////////////////////////////////////////
10067 -->
10068
10069 <enum
10070 name="DataType"
10071 uuid="d90ea51e-a3f1-4a01-beb1-c1723c0d3ba7"
10072 >
10073 <const name="Int32" value="0"/>
10074 <const name="Int8" value="1"/>
10075 <const name="String" value="2"/>
10076 </enum>
10077
10078 <enum
10079 name="DataFlags"
10080 uuid="86884dcf-1d6b-4f1b-b4bf-f5aa44959d60"
10081 >
10082 <const name="None" value="0x00"/>
10083 <const name="Mandatory" value="0x01"/>
10084 <const name="Expert" value="0x02"/>
10085 <const name="Array" value="0x04"/>
10086 <const name="FlagMask" value="0x07"/>
10087 </enum>
10088
10089 <enum
10090 name="MediumFormatCapabilities"
10091 uuid="7342ba79-7ce0-4d94-8f86-5ed5a185d9bd"
10092 >
10093 <desc>
10094 Medium format capability flags.
10095 </desc>
10096
10097 <const name="Uuid" value="0x01">
10098 <desc>
10099 Supports UUIDs as expected by VirtualBox code.
10100 </desc>
10101 </const>
10102
10103 <const name="CreateFixed" value="0x02">
10104 <desc>
10105 Supports creating fixed size images, allocating all space instantly.
10106 </desc>
10107 </const>
10108
10109 <const name="CreateDynamic" value="0x04">
10110 <desc>
10111 Supports creating dynamically growing images, allocating space on
10112 demand.
10113 </desc>
10114 </const>
10115
10116 <const name="CreateSplit2G" value="0x08">
10117 <desc>
10118 Supports creating images split in chunks of a bit less than 2 GBytes.
10119 </desc>
10120 </const>
10121
10122 <const name="Differencing" value="0x10">
10123 <desc>
10124 Supports being used as a format for differencing media (see <link
10125 to="IMedium::createDiffStorage"/>).
10126 </desc>
10127 </const>
10128
10129 <const name="Asynchronous" value="0x20">
10130 <desc>
10131 Supports asynchronous I/O operations for at least some configurations.
10132 </desc>
10133 </const>
10134
10135 <const name="File" value="0x40">
10136 <desc>
10137 The format backend operates on files (the <link to="IMedium::location"/>
10138 attribute of the medium specifies a file used to store medium
10139 data; for a list of supported file extensions see
10140 <link to="IMediumFormat::fileExtensions"/>).
10141 </desc>
10142 </const>
10143
10144 <const name="Properties" value="0x80">
10145 <desc>
10146 The format backend uses the property interface to configure the storage
10147 location and properties (the <link to="IMediumFormat::describeProperties"/>
10148 method is used to get access to properties supported by the given medium format).
10149 </desc>
10150 </const>
10151
10152 <const name="TcpNetworking" value="0x100">
10153 <desc>
10154 The format backend uses the TCP networking interface for network access.
10155 </desc>
10156 </const>
10157
10158 <const name="VFS" value="0x200">
10159 <desc>
10160 The format backend supports virtual filesystem functionality.
10161 </desc>
10162 </const>
10163
10164 <const name="CapabilityMask" value="0x3FF"/>
10165 </enum>
10166
10167 <interface
10168 name="IMediumFormat" extends="$unknown"
10169 uuid="89f52554-d469-4799-9fad-1705e86a08b1"
10170 wsmap="managed"
10171 >
10172 <desc>
10173 The IMediumFormat interface represents a medium format.
10174
10175 Each medium format has an associated backend which is used to handle
10176 media stored in this format. This interface provides information
10177 about the properties of the associated backend.
10178
10179 Each medium format is identified by a string represented by the
10180 <link to="#id"/> attribute. This string is used in calls like
10181 <link to="IVirtualBox::createHardDisk"/> to specify the desired
10182 format.
10183
10184 The list of all supported medium formats can be obtained using
10185 <link to="ISystemProperties::mediumFormats"/>.
10186
10187 <see>IMedium</see>
10188 </desc>
10189
10190 <attribute name="id" type="wstring" readonly="yes">
10191 <desc>
10192 Identifier of this format.
10193
10194 The format identifier is a non-@c null non-empty ASCII string. Note that
10195 this string is case-insensitive. This means that, for example, all of
10196 the following strings:
10197 <pre>
10198 "VDI"
10199 "vdi"
10200 "VdI"</pre>
10201 refer to the same medium format.
10202
10203 This string is used in methods of other interfaces where it is necessary
10204 to specify a medium format, such as
10205 <link to="IVirtualBox::createHardDisk"/>.
10206 </desc>
10207 </attribute>
10208
10209 <attribute name="name" type="wstring" readonly="yes">
10210 <desc>
10211 Human readable description of this format.
10212
10213 Mainly for use in file open dialogs.
10214 </desc>
10215 </attribute>
10216
10217 <attribute name="fileExtensions" type="wstring" safearray="yes" readonly="yes">
10218 <desc>
10219 Array of strings containing the supported file extensions.
10220
10221 The first extension in the array is the extension preferred by the
10222 backend. It is recommended to use this extension when specifying a
10223 location of the storage unit for a new medium.
10224
10225 Note that some backends do not work on files, so this array may be
10226 empty.
10227
10228 <see>IMediumFormat::capabilities</see>
10229 </desc>
10230 </attribute>
10231
10232 <attribute name="capabilities" type="unsigned long" readonly="yes">
10233 <desc>
10234 Capabilities of the format as a set of bit flags.
10235
10236 For the meaning of individual capability flags see
10237 <link to="MediumFormatCapabilities"/>.
10238 </desc>
10239 </attribute>
10240
10241 <method name="describeProperties">
10242 <desc>
10243 Returns several arrays describing the properties supported by this
10244 format.
10245
10246 An element with the given index in each array describes one
10247 property. Thus, the number of elements in each returned array is the
10248 same and corresponds to the number of supported properties.
10249
10250 The returned arrays are filled in only if the
10251 <link to="MediumFormatCapabilities_Properties"/> flag is set.
10252 All arguments must be non-@c null.
10253
10254 <see>DataType</see>
10255 <see>DataFlags</see>
10256 </desc>
10257
10258 <param name="names" type="wstring" safearray="yes" dir="out">
10259 <desc>Array of property names.</desc>
10260 </param>
10261 <param name="description" type="wstring" safearray="yes" dir="out">
10262 <desc>Array of property descriptions.</desc>
10263 </param>
10264 <param name="types" type="DataType" safearray="yes" dir="out">
10265 <desc>Array of property types.</desc>
10266 </param>
10267 <param name="flags" type="unsigned long" safearray="yes" dir="out">
10268 <desc>Array of property flags.</desc>
10269 </param>
10270 <param name="defaults" type="wstring" safearray="yes" dir="out">
10271 <desc>Array of default property values.</desc>
10272 </param>
10273 </method>
10274
10275 </interface>
10276
10277
10278 <!--
10279 // IKeyboard
10280 /////////////////////////////////////////////////////////////////////////
10281 -->
10282
10283 <interface
10284 name="IKeyboard" extends="$unknown"
10285 uuid="f6916ec5-a881-4237-898f-7de58cf88672"
10286 wsmap="managed"
10287 >
10288 <desc>
10289 The IKeyboard interface represents the virtual machine's keyboard. Used
10290 in <link to="IConsole::keyboard"/>.
10291
10292 Use this interface to send keystrokes or the Ctrl-Alt-Del sequence
10293 to the virtual machine.
10294
10295 </desc>
10296 <method name="putScancode">
10297 <desc>Sends a scancode to the keyboard.
10298
10299 <result name="VBOX_E_IPRT_ERROR">
10300 Could not send scan code to virtual keyboard.
10301 </result>
10302
10303 </desc>
10304 <param name="scancode" type="long" dir="in"/>
10305 </method>
10306
10307 <method name="putScancodes">
10308 <desc>Sends an array of scancodes to the keyboard.
10309
10310 <result name="VBOX_E_IPRT_ERROR">
10311 Could not send all scan codes to virtual keyboard.
10312 </result>
10313
10314 </desc>
10315 <param name="scancodes" type="long" dir="in" safearray="yes"/>
10316 <param name="codesStored" type="unsigned long" dir="return"/>
10317 </method>
10318
10319 <method name="putCAD">
10320 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard. This
10321 function is nothing special, it is just a convenience function
10322 calling <link to="IKeyboard::putScancodes"/> with the proper scancodes.
10323
10324 <result name="VBOX_E_IPRT_ERROR">
10325 Could not send all scan codes to virtual keyboard.
10326 </result>
10327
10328 </desc>
10329 </method>
10330
10331 <attribute name="eventSource" type="IEventSource" readonly="yes">
10332 <desc>
10333 Event source for keyboard events.
10334 </desc>
10335 </attribute>
10336
10337 </interface>
10338
10339
10340 <!--
10341 // IMouse
10342 /////////////////////////////////////////////////////////////////////////
10343 -->
10344
10345 <enum
10346 name="MouseButtonState"
10347 uuid="9ee094b8-b28a-4d56-a166-973cb588d7f8"
10348 >
10349 <desc>
10350 Mouse button state.
10351 </desc>
10352
10353 <const name="LeftButton" value="0x01"/>
10354 <const name="RightButton" value="0x02"/>
10355 <const name="MiddleButton" value="0x04"/>
10356 <const name="WheelUp" value="0x08"/>
10357 <const name="WheelDown" value="0x10"/>
10358 <const name="XButton1" value="0x20"/>
10359 <const name="XButton2" value="0x40"/>
10360 <const name="MouseStateMask" value="0x7F"/>
10361 </enum>
10362
10363 <interface
10364 name="IMouse" extends="$unknown"
10365 uuid="05044a52-7811-4f00-ae3a-0ab7ff707b10"
10366 wsmap="managed"
10367 >
10368 <desc>
10369 The IMouse interface represents the virtual machine's mouse. Used in
10370 <link to="IConsole::mouse"/>.
10371
10372 Through this interface, the virtual machine's virtual mouse can be
10373 controlled.
10374 </desc>
10375
10376 <attribute name="absoluteSupported" type="boolean" readonly="yes">
10377 <desc>
10378 Whether the guest OS supports absolute mouse pointer positioning
10379 or not.
10380 <note>
10381 You can use the <link to="IMouseCapabilityChangedEvent"/>
10382 event to be instantly informed about changes of this attribute
10383 during virtual machine execution.
10384 </note>
10385 <see><link to="#putMouseEventAbsolute"/></see>
10386 </desc>
10387 </attribute>
10388
10389 <attribute name="relativeSupported" type="boolean" readonly="yes">
10390 <desc>
10391 Whether the guest OS supports relative mouse pointer positioning
10392 or not.
10393 <note>
10394 You can use the <link to="IMouseCapabilityChangedEvent"/>
10395 event to be instantly informed about changes of this attribute
10396 during virtual machine execution.
10397 </note>
10398 <see><link to="#putMouseEvent"/></see>
10399 </desc>
10400 </attribute>
10401
10402 <attribute name="needsHostCursor" type="boolean" readonly="yes">
10403 <desc>
10404 Whether the guest OS can currently switch to drawing it's own mouse
10405 cursor on demand.
10406 <note>
10407 You can use the <link to="IMouseCapabilityChangedEvent"/>
10408 event to be instantly informed about changes of this attribute
10409 during virtual machine execution.
10410 </note>
10411 <see><link to="#putMouseEvent"/></see>
10412 </desc>
10413 </attribute>
10414
10415 <method name="putMouseEvent">
10416 <desc>
10417 Initiates a mouse event using relative pointer movements
10418 along x and y axis.
10419
10420 <result name="E_ACCESSDENIED">
10421 Console not powered up.
10422 </result>
10423 <result name="VBOX_E_IPRT_ERROR">
10424 Could not send mouse event to virtual mouse.
10425 </result>
10426
10427 </desc>
10428
10429 <param name="dx" type="long" dir="in">
10430 <desc>
10431 Amount of pixels the mouse should move to the right.
10432 Negative values move the mouse to the left.
10433 </desc>
10434 </param>
10435 <param name="dy" type="long" dir="in">
10436 <desc>
10437 Amount of pixels the mouse should move downwards.
10438 Negative values move the mouse upwards.
10439 </desc>
10440 </param>
10441 <param name="dz" type="long" dir="in">
10442 <desc>
10443 Amount of mouse wheel moves.
10444 Positive values describe clockwise wheel rotations,
10445 negative values describe counterclockwise rotations.
10446 </desc>
10447 </param>
10448 <param name="dw" type="long" dir="in">
10449 <desc>
10450 Amount of horizontal mouse wheel moves.
10451 Positive values describe a movement to the left,
10452 negative values describe a movement to the right.
10453 </desc>
10454 </param>
10455 <param name="buttonState" type="long" dir="in">
10456 <desc>
10457 The current state of mouse buttons. Every bit represents
10458 a mouse button as follows:
10459 <table>
10460 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10461 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10462 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10463 </table>
10464 A value of <tt>1</tt> means the corresponding button is pressed.
10465 otherwise it is released.
10466 </desc>
10467 </param>
10468 </method>
10469
10470 <method name="putMouseEventAbsolute">
10471 <desc>
10472 Positions the mouse pointer using absolute x and y coordinates.
10473 These coordinates are expressed in pixels and
10474 start from <tt>[1,1]</tt> which corresponds to the top left
10475 corner of the virtual display.
10476
10477 <result name="E_ACCESSDENIED">
10478 Console not powered up.
10479 </result>
10480 <result name="VBOX_E_IPRT_ERROR">
10481 Could not send mouse event to virtual mouse.
10482 </result>
10483
10484 <note>
10485 This method will have effect only if absolute mouse
10486 positioning is supported by the guest OS.
10487 </note>
10488
10489 <see><link to="#absoluteSupported"/></see>
10490 </desc>
10491
10492 <param name="x" type="long" dir="in">
10493 <desc>
10494 X coordinate of the pointer in pixels, starting from @c 1.
10495 </desc>
10496 </param>
10497 <param name="y" type="long" dir="in">
10498 <desc>
10499 Y coordinate of the pointer in pixels, starting from @c 1.
10500 </desc>
10501 </param>
10502 <param name="dz" type="long" dir="in">
10503 <desc>
10504 Amount of mouse wheel moves.
10505 Positive values describe clockwise wheel rotations,
10506 negative values describe counterclockwise rotations.
10507 </desc>
10508 </param>
10509 <param name="dw" type="long" dir="in">
10510 <desc>
10511 Amount of horizontal mouse wheel moves.
10512 Positive values describe a movement to the left,
10513 negative values describe a movement to the right.
10514 </desc>
10515 </param>
10516 <param name="buttonState" type="long" dir="in">
10517 <desc>
10518 The current state of mouse buttons. Every bit represents
10519 a mouse button as follows:
10520 <table>
10521 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10522 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10523 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10524 </table>
10525 A value of @c 1 means the corresponding button is pressed.
10526 otherwise it is released.
10527 </desc>
10528 </param>
10529 </method>
10530
10531 <attribute name="eventSource" type="IEventSource" readonly="yes">
10532 <desc>
10533 Event source for mouse events.
10534 </desc>
10535 </attribute>
10536
10537 </interface>
10538
10539 <!--
10540 // IDisplay
10541 /////////////////////////////////////////////////////////////////////////
10542 -->
10543
10544 <enum
10545 name="FramebufferPixelFormat"
10546 uuid="7acfd5ed-29e3-45e3-8136-73c9224f3d2d"
10547 >
10548 <desc>
10549 Format of the video memory buffer. Constants represented by this enum can
10550 be used to test for particular values of <link
10551 to="IFramebuffer::pixelFormat"/>. See also <link
10552 to="IFramebuffer::requestResize"/>.
10553
10554 See also www.fourcc.org for more information about FOURCC pixel formats.
10555 </desc>
10556
10557 <const name="Opaque" value="0">
10558 <desc>
10559 Unknown buffer format (the user may not assume any particular format of
10560 the buffer).
10561 </desc>
10562 </const>
10563 <const name="FOURCC_RGB" value="0x32424752">
10564 <desc>
10565 Basic RGB format (<link to="IFramebuffer::bitsPerPixel"/> determines the
10566 bit layout).
10567 </desc>
10568 </const>
10569 </enum>
10570
10571 <interface
10572 name="IFramebuffer" extends="$unknown"
10573 uuid="b7ed347a-5765-40a0-ae1c-f543eb4ddeaf"
10574 wsmap="suppress"
10575 >
10576 <attribute name="address" type="octet" mod="ptr" readonly="yes">
10577 <desc>Address of the start byte of the frame buffer.</desc>
10578 </attribute>
10579
10580 <attribute name="width" type="unsigned long" readonly="yes">
10581 <desc>Frame buffer width, in pixels.</desc>
10582 </attribute>
10583
10584 <attribute name="height" type="unsigned long" readonly="yes">
10585 <desc>Frame buffer height, in pixels.</desc>
10586 </attribute>
10587
10588 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10589 <desc>
10590 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
10591 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, valid values
10592 are: 8, 15, 16, 24 and 32.
10593 </desc>
10594 </attribute>
10595
10596 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
10597 <desc>
10598 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
10599 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, the
10600 size of the scan line must be aligned to 32 bits.
10601 </desc>
10602 </attribute>
10603
10604 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
10605 <desc>
10606 Frame buffer pixel format. It's either one of the values defined by <link
10607 to="FramebufferPixelFormat"/> or a raw FOURCC code.
10608 <note>
10609 This attribute must never return <link
10610 to="FramebufferPixelFormat_Opaque"/> -- the format of the buffer
10611 <link to="#address"/> points to must be always known.
10612 </note>
10613 </desc>
10614 </attribute>
10615
10616 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
10617 <desc>
10618 Defines whether this frame buffer uses the virtual video card's memory
10619 buffer (guest VRAM) directly or not. See <link
10620 to="IFramebuffer::requestResize"/> for more information.
10621 </desc>
10622 </attribute>
10623
10624 <attribute name="heightReduction" type="unsigned long" readonly="yes">
10625 <desc>
10626 Hint from the frame buffer about how much of the standard
10627 screen height it wants to use for itself. This information is
10628 exposed to the guest through the VESA BIOS and VMMDev interface
10629 so that it can use it for determining its video mode table. It
10630 is not guaranteed that the guest respects the value.
10631 </desc>
10632 </attribute>
10633
10634 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
10635 <desc>
10636 An alpha-blended overlay which is superposed over the frame buffer.
10637 The initial purpose is to allow the display of icons providing
10638 information about the VM state, including disk activity, in front
10639 ends which do not have other means of doing that. The overlay is
10640 designed to controlled exclusively by IDisplay. It has no locking
10641 of its own, and any changes made to it are not guaranteed to be
10642 visible until the affected portion of IFramebuffer is updated. The
10643 overlay can be created lazily the first time it is requested. This
10644 attribute can also return @c null to signal that the overlay is not
10645 implemented.
10646 </desc>
10647 </attribute>
10648
10649 <attribute name="winId" type="long long" readonly="yes">
10650 <desc>
10651 Platform-dependent identifier of the window where context of this
10652 frame buffer is drawn, or zero if there's no such window.
10653 </desc>
10654 </attribute>
10655
10656 <method name="lock">
10657 <desc>
10658 Locks the frame buffer.
10659 Gets called by the IDisplay object where this frame buffer is
10660 bound to.
10661 </desc>
10662 </method>
10663
10664 <method name="unlock">
10665 <desc>
10666 Unlocks the frame buffer.
10667 Gets called by the IDisplay object where this frame buffer is
10668 bound to.
10669 </desc>
10670 </method>
10671
10672 <method name="notifyUpdate">
10673 <desc>
10674 Informs about an update.
10675 Gets called by the display object where this buffer is
10676 registered.
10677 </desc>
10678 <param name="x" type="unsigned long" dir="in"/>
10679 <param name="y" type="unsigned long" dir="in"/>
10680 <param name="width" type="unsigned long" dir="in"/>
10681 <param name="height" type="unsigned long" dir="in"/>
10682 </method>
10683
10684 <method name="requestResize">
10685 <desc>
10686 Requests a size and pixel format change.
10687
10688 There are two modes of working with the video buffer of the virtual
10689 machine. The <i>indirect</i> mode implies that the IFramebuffer
10690 implementation allocates a memory buffer for the requested display mode
10691 and provides it to the virtual machine. In <i>direct</i> mode, the
10692 IFramebuffer implementation uses the memory buffer allocated and owned
10693 by the virtual machine. This buffer represents the video memory of the
10694 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
10695 usually faster because the implementation gets a raw pointer to the
10696 guest VRAM buffer which it can directly use for visualizing the contents
10697 of the virtual display, as opposed to the indirect mode where the
10698 contents of guest VRAM are copied to the memory buffer provided by
10699 the implementation every time a display update occurs.
10700
10701 It is important to note that the direct mode is really fast only when
10702 the implementation uses the given guest VRAM buffer directly, for
10703 example, by blitting it to the window representing the virtual machine's
10704 display, which saves at least one copy operation comparing to the
10705 indirect mode. However, using the guest VRAM buffer directly is not
10706 always possible: the format and the color depth of this buffer may be
10707 not supported by the target window, or it may be unknown (opaque) as in
10708 case of text or non-linear multi-plane VGA video modes. In this case,
10709 the indirect mode (that is always available) should be used as a
10710 fallback: when the guest VRAM contents are copied to the
10711 implementation-provided memory buffer, color and format conversion is
10712 done automatically by the underlying code.
10713
10714 The @a pixelFormat parameter defines whether the direct mode is
10715 available or not. If @a pixelFormat is <link
10716 to="FramebufferPixelFormat_Opaque"/> then direct access to the guest
10717 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and
10718 @a bytesPerLine parameters must be ignored and the implementation must use
10719 the indirect mode (where it provides its own buffer in one of the
10720 supported formats). In all other cases, @a pixelFormat together with
10721 @a bitsPerPixel and @a bytesPerLine define the format of the video memory
10722 buffer pointed to by the @a VRAM parameter and the implementation is
10723 free to choose which mode to use. To indicate that this frame buffer uses
10724 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
10725 attribute must return @c true and <link to="#address"/> must
10726 return exactly the same address that is passed in the @a VRAM parameter
10727 of this method; otherwise it is assumed that the indirect strategy is
10728 chosen.
10729
10730 The @a width and @a height parameters represent the size of the
10731 requested display mode in both modes. In case of indirect mode, the
10732 provided memory buffer should be big enough to store data of the given
10733 display mode. In case of direct mode, it is guaranteed that the given
10734 @a VRAM buffer contains enough space to represent the display mode of the
10735 given size. Note that this frame buffer's <link to="#width"/> and <link
10736 to="#height"/> attributes must return exactly the same values as
10737 passed to this method after the resize is completed (see below).
10738
10739 The @a finished output parameter determines if the implementation has
10740 finished resizing the frame buffer or not. If, for some reason, the
10741 resize cannot be finished immediately during this call, @a finished
10742 must be set to @c false, and the implementation must call
10743 <link to="IDisplay::resizeCompleted"/> after it has returned from
10744 this method as soon as possible. If @a finished is @c false, the
10745 machine will not call any frame buffer methods until
10746 <link to="IDisplay::resizeCompleted"/> is called.
10747
10748 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
10749 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
10750 this frame buffer must return exactly the same values as specified in the
10751 parameters of this method, after the resize is completed. If the
10752 indirect mode is chosen, these attributes must return values describing
10753 the format of the implementation's own memory buffer <link
10754 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
10755 value must always correlate with <link to="#pixelFormat"/>. Note that
10756 the <link to="#pixelFormat"/> attribute must never return <link
10757 to="FramebufferPixelFormat_Opaque"/> regardless of the selected mode.
10758
10759 <note>
10760 This method is called by the IDisplay object under the
10761 <link to="#lock"/> provided by this IFramebuffer
10762 implementation. If this method returns @c false in @a finished, then
10763 this lock is not released until
10764 <link to="IDisplay::resizeCompleted"/> is called.
10765 </note>
10766 </desc>
10767 <param name="screenId" type="unsigned long" dir="in">
10768 <desc>
10769 Logical screen number. Must be used in the corresponding call to
10770 <link to="IDisplay::resizeCompleted"/> if this call is made.
10771 </desc>
10772 </param>
10773 <param name="pixelFormat" type="unsigned long" dir="in">
10774 <desc>
10775 Pixel format of the memory buffer pointed to by @a VRAM.
10776 See also <link to="FramebufferPixelFormat"/>.
10777 </desc>
10778 </param>
10779 <param name="VRAM" type="octet" mod="ptr" dir="in">
10780 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
10781 </param>
10782 <param name="bitsPerPixel" type="unsigned long" dir="in">
10783 <desc>Color depth, bits per pixel.</desc>
10784 </param>
10785 <param name="bytesPerLine" type="unsigned long" dir="in">
10786 <desc>Size of one scan line, in bytes.</desc>
10787 </param>
10788 <param name="width" type="unsigned long" dir="in">
10789 <desc>Width of the guest display, in pixels.</desc>
10790 </param>
10791 <param name="height" type="unsigned long" dir="in">
10792 <desc>Height of the guest display, in pixels.</desc>
10793 </param>
10794 <param name="finished" type="boolean" dir="return">
10795 <desc>
10796 Can the VM start using the new frame buffer immediately
10797 after this method returns or it should wait for
10798 <link to="IDisplay::resizeCompleted"/>.
10799 </desc>
10800 </param>
10801 </method>
10802
10803 <method name="videoModeSupported">
10804 <desc>
10805 Returns whether the frame buffer implementation is willing to
10806 support a given video mode. In case it is not able to render
10807 the video mode (or for some reason not willing), it should
10808 return @c false. Usually this method is called when the guest
10809 asks the VMM device whether a given video mode is supported
10810 so the information returned is directly exposed to the guest.
10811 It is important that this method returns very quickly.
10812 </desc>
10813 <param name="width" type="unsigned long" dir="in"/>
10814 <param name="height" type="unsigned long" dir="in"/>
10815 <param name="bpp" type="unsigned long" dir="in"/>
10816 <param name="supported" type="boolean" dir="return"/>
10817 </method>
10818
10819 <method name="getVisibleRegion">
10820 <desc>
10821 Returns the visible region of this frame buffer.
10822
10823 If the @a rectangles parameter is @c null then the value of the
10824 @a count parameter is ignored and the number of elements necessary to
10825 describe the current visible region is returned in @a countCopied.
10826
10827 If @a rectangles is not @c null but @a count is less
10828 than the required number of elements to store region data, the method
10829 will report a failure. If @a count is equal or greater than the
10830 required number of elements, then the actual number of elements copied
10831 to the provided array will be returned in @a countCopied.
10832
10833 <note>
10834 The address of the provided array must be in the process space of
10835 this IFramebuffer object.
10836 </note>
10837 <note>
10838 Method not yet implemented.
10839 </note>
10840 </desc>
10841 <param name="rectangles" type="octet" mod="ptr" dir="in">
10842 <desc>Pointer to the @c RTRECT array to receive region data.</desc>
10843 </param>
10844 <param name="count" type="unsigned long" dir="in">
10845 <desc>Number of @c RTRECT elements in the @a rectangles array.</desc>
10846 </param>
10847 <param name="countCopied" type="unsigned long" dir="return">
10848 <desc>Number of elements copied to the @a rectangles array.</desc>
10849 </param>
10850 </method>
10851
10852 <method name="setVisibleRegion">
10853 <desc>
10854 Suggests a new visible region to this frame buffer. This region
10855 represents the area of the VM display which is a union of regions of
10856 all top-level windows of the guest operating system running inside the
10857 VM (if the Guest Additions for this system support this
10858 functionality). This information may be used by the frontends to
10859 implement the seamless desktop integration feature.
10860
10861 <note>
10862 The address of the provided array must be in the process space of
10863 this IFramebuffer object.
10864 </note>
10865 <note>
10866 The IFramebuffer implementation must make a copy of the provided
10867 array of rectangles.
10868 </note>
10869 <note>
10870 Method not yet implemented.
10871 </note>
10872 </desc>
10873 <param name="rectangles" type="octet" mod="ptr" dir="in">
10874 <desc>Pointer to the @c RTRECT array.</desc>
10875 </param>
10876 <param name="count" type="unsigned long" dir="in">
10877 <desc>Number of @c RTRECT elements in the @a rectangles array.</desc>
10878 </param>
10879 </method>
10880
10881 <method name="processVHWACommand">
10882 <desc>
10883 Posts a Video HW Acceleration Command to the frame buffer for processing.
10884 The commands used for 2D video acceleration (DDraw surface creation/destroying, blitting, scaling, color covnersion, overlaying, etc.)
10885 are posted from quest to the host to be processed by the host hardware.
10886
10887 <note>
10888 The address of the provided command must be in the process space of
10889 this IFramebuffer object.
10890 </note>
10891 </desc>
10892
10893 <param name="command" type="octet" mod="ptr" dir="in">
10894 <desc>Pointer to VBOXVHWACMD containing the command to execute.</desc>
10895 </param>
10896 </method>
10897
10898 </interface>
10899
10900 <interface
10901 name="IFramebufferOverlay" extends="IFramebuffer"
10902 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
10903 wsmap="suppress"
10904 >
10905 <desc>
10906 The IFramebufferOverlay interface represents an alpha blended overlay
10907 for displaying status icons above an IFramebuffer. It is always created
10908 not visible, so that it must be explicitly shown. It only covers a
10909 portion of the IFramebuffer, determined by its width, height and
10910 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
10911 that order) format, and may be written to directly. Do re-read the
10912 width though, after setting it, as it may be adjusted (increased) to
10913 make it more suitable for the front end.
10914 </desc>
10915 <attribute name="x" type="unsigned long" readonly="yes">
10916 <desc>X position of the overlay, relative to the frame buffer.</desc>
10917 </attribute>
10918
10919 <attribute name="y" type="unsigned long" readonly="yes">
10920 <desc>Y position of the overlay, relative to the frame buffer.</desc>
10921 </attribute>
10922
10923 <attribute name="visible" type="boolean" readonly="no">
10924 <desc>
10925 Whether the overlay is currently visible.
10926 </desc>
10927 </attribute>
10928
10929 <attribute name="alpha" type="unsigned long" readonly="no">
10930 <desc>
10931 The global alpha value for the overlay. This may or may not be
10932 supported by a given front end.
10933 </desc>
10934 </attribute>
10935
10936 <method name="move">
10937 <desc>
10938 Changes the overlay's position relative to the IFramebuffer.
10939 </desc>
10940 <param name="x" type="unsigned long" dir="in"/>
10941 <param name="y" type="unsigned long" dir="in"/>
10942 </method>
10943
10944 </interface>
10945
10946 <interface
10947 name="IDisplay" extends="$unknown"
10948 uuid="09EED313-CD56-4D06-BD56-FAC0F716B5DD"
10949 wsmap="managed"
10950 >
10951 <desc>
10952 The IDisplay interface represents the virtual machine's display.
10953
10954 The object implementing this interface is contained in each
10955 <link to="IConsole::display"/> attribute and represents the visual
10956 output of the virtual machine.
10957
10958 The virtual display supports pluggable output targets represented by the
10959 IFramebuffer interface. Examples of the output target are a window on
10960 the host computer or an RDP session's display on a remote computer.
10961 </desc>
10962 <method name="getScreenResolution">
10963 <desc>Queries display width, height and color depth for given screen.</desc>
10964 <param name="screenId" type="unsigned long" dir="in"/>
10965 <param name="width" type="unsigned long" dir="out"/>
10966 <param name="height" type="unsigned long" dir="out"/>
10967 <param name="bitsPerPixel" type="unsigned long" dir="out"/>
10968 </method>
10969
10970 <method name="setFramebuffer">
10971 <desc>
10972 Sets the framebuffer for given screen.
10973 </desc>
10974 <param name="screenId" type="unsigned long" dir="in"/>
10975 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10976 </method>
10977
10978 <method name="getFramebuffer">
10979 <desc>
10980 Queries the framebuffer for given screen.
10981 </desc>
10982 <param name="screenId" type="unsigned long" dir="in"/>
10983 <param name="framebuffer" type="IFramebuffer" dir="out"/>
10984 <param name="xOrigin" type="long" dir="out"/>
10985 <param name="yOrigin" type="long" dir="out"/>
10986 </method>
10987
10988 <method name="setVideoModeHint">
10989 <desc>
10990 Asks VirtualBox to request the given video mode from
10991 the guest. This is just a hint and it cannot be guaranteed
10992 that the requested resolution will be used. Guest Additions
10993 are required for the request to be seen by guests. The caller
10994 should issue the request and wait for a resolution change and
10995 after a timeout retry.
10996
10997 Specifying @c 0 for either @a width, @a height or @a bitsPerPixel
10998 parameters means that the corresponding values should be taken from the
10999 current video mode (i.e. left unchanged).
11000
11001 If the guest OS supports multi-monitor configuration then the @a display
11002 parameter specifies the number of the guest display to send the hint to:
11003 @c 0 is the primary display, @c 1 is the first secondary and
11004 so on. If the multi-monitor configuration is not supported, @a display
11005 must be @c 0.
11006
11007 <result name="E_INVALIDARG">
11008 The @a display is not associated with any monitor.
11009 </result>
11010
11011 </desc>
11012 <param name="width" type="unsigned long" dir="in"/>
11013 <param name="height" type="unsigned long" dir="in"/>
11014 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
11015 <param name="display" type="unsigned long" dir="in"/>
11016 </method>
11017
11018 <method name="setSeamlessMode">
11019 <desc>
11020 Enables or disables seamless guest display rendering (seamless desktop
11021 integration) mode.
11022 <note>
11023 Calling this method has no effect if <link
11024 to="IGuest::supportsSeamless"/> returns @c false.
11025 </note>
11026 </desc>
11027 <param name="enabled" type="boolean" dir="in"/>
11028 </method>
11029
11030 <method name="takeScreenShot">
11031 <desc>
11032 Takes a screen shot of the requested size and copies it to the
11033 32-bpp buffer allocated by the caller and pointed to by @a address.
11034 A pixel consists of 4 bytes in order: B, G, R, 0.
11035
11036 <note>This API can be used only by the COM/XPCOM C++ API as it
11037 requires pointer support. Use <link to="#takeScreenShotToArray" />
11038 with other language bindings.
11039 </note>
11040
11041 <result name="E_NOTIMPL">
11042 Feature not implemented.
11043 </result>
11044 <result name="VBOX_E_IPRT_ERROR">
11045 Could not take a screenshot.
11046 </result>
11047
11048 </desc>
11049 <param name="screenId" type="unsigned long" dir="in"/>
11050 <param name="address" type="octet" mod="ptr" dir="in"/>
11051 <param name="width" type="unsigned long" dir="in"/>
11052 <param name="height" type="unsigned long" dir="in"/>
11053 </method>
11054
11055 <method name="takeScreenShotToArray">
11056 <desc>
11057 Takes a guest screen shot of the requested size and returns it as
11058 an array of bytes in uncompressed 32-bit RGBA format.
11059 A pixel consists of 4 bytes in order: R, G, B, 0xFF.
11060
11061 This API is slow, but could be the only option to get guest screenshot
11062 for scriptable languages not allowed to manipulate with addresses
11063 directly.
11064
11065 <result name="E_NOTIMPL">
11066 Feature not implemented.
11067 </result>
11068 <result name="VBOX_E_IPRT_ERROR">
11069 Could not take a screenshot.
11070 </result>
11071 </desc>
11072 <param name="screenId" type="unsigned long" dir="in">
11073 <desc>
11074 Monitor to take screenshot from.
11075 </desc>
11076 </param>
11077 <param name="width" type="unsigned long" dir="in">
11078 <desc>
11079 Desired image width.
11080 </desc>
11081 </param>
11082 <param name="height" type="unsigned long" dir="in">
11083 <desc>
11084 Desired image height.
11085 </desc>
11086 </param>
11087 <param name="screenData" type="octet" dir="return" safearray="yes">
11088 <desc>
11089 Array with resulting screen data.
11090 </desc>
11091 </param>
11092 </method>
11093
11094 <method name="takeScreenShotPNGToArray">
11095 <desc>
11096 Takes a guest screen shot of the requested size and returns it as
11097 PNG image in array.
11098
11099 <result name="E_NOTIMPL">
11100 Feature not implemented.
11101 </result>
11102 <result name="VBOX_E_IPRT_ERROR">
11103 Could not take a screenshot.
11104 </result>
11105 </desc>
11106 <param name="screenId" type="unsigned long" dir="in">
11107 <desc>
11108 Monitor to take the screenshot from.
11109 </desc>
11110 </param>
11111 <param name="width" type="unsigned long" dir="in">
11112 <desc>
11113 Desired image width.
11114 </desc>
11115 </param>
11116 <param name="height" type="unsigned long" dir="in">
11117 <desc>
11118 Desired image height.
11119 </desc>
11120 </param>
11121 <param name="screenData" type="octet" dir="return" safearray="yes">
11122 <desc>
11123 Array with resulting screen data.
11124 </desc>
11125 </param>
11126 </method>
11127
11128 <method name="drawToScreen">
11129 <desc>
11130 Draws a 32-bpp image of the specified size from the given buffer
11131 to the given point on the VM display.
11132
11133 <result name="E_NOTIMPL">
11134 Feature not implemented.
11135 </result>
11136 <result name="VBOX_E_IPRT_ERROR">
11137 Could not draw to screen.
11138 </result>
11139
11140 </desc>
11141 <param name="screenId" type="unsigned long" dir="in">
11142 <desc>
11143 Monitor to take the screenshot from.
11144 </desc>
11145 </param>
11146 <param name="address" type="octet" mod="ptr" dir="in">
11147 <desc>
11148 Address to store the screenshot to
11149 </desc>
11150 </param>
11151 <param name="x" type="unsigned long" dir="in">
11152 <desc>
11153 Relative to the screen top left corner.
11154 </desc>
11155 </param>
11156 <param name="y" type="unsigned long" dir="in">
11157 <desc>
11158 Relative to the screen top left corner.
11159 </desc>
11160 </param>
11161 <param name="width" type="unsigned long" dir="in">
11162 <desc>
11163 Desired image width.
11164 </desc>
11165 </param>
11166 <param name="height" type="unsigned long" dir="in">
11167 <desc>
11168 Desired image height.
11169 </desc>
11170 </param>
11171 </method>
11172
11173 <method name="invalidateAndUpdate">
11174 <desc>
11175 Does a full invalidation of the VM display and instructs the VM
11176 to update it.
11177
11178 <result name="VBOX_E_IPRT_ERROR">
11179 Could not invalidate and update screen.
11180 </result>
11181
11182 </desc>
11183 </method>
11184
11185 <method name="resizeCompleted">
11186 <desc>
11187 Signals that a framebuffer has completed the resize operation.
11188
11189 <result name="VBOX_E_NOT_SUPPORTED">
11190 Operation only valid for external frame buffers.
11191 </result>
11192
11193 </desc>
11194 <param name="screenId" type="unsigned long" dir="in"/>
11195 </method>
11196
11197 <method name="completeVHWACommand">
11198 <desc>
11199 Signals that the Video HW Acceleration command has completed.
11200 </desc>
11201
11202 <param name="command" type="octet" mod="ptr" dir="in">
11203 <desc>Pointer to VBOXVHWACMD containing the completed command.</desc>
11204 </param>
11205 </method>
11206
11207 </interface>
11208
11209 <!--
11210 // INetworkAdapter
11211 /////////////////////////////////////////////////////////////////////////
11212 -->
11213
11214 <enum
11215 name="NetworkAttachmentType"
11216 uuid="44bce1ee-99f7-4e8e-89fc-80597fd9eeaf"
11217 >
11218 <desc>
11219 Network attachment type.
11220 </desc>
11221
11222 <const name="Null" value="0">
11223 <desc>Null value, also means "not attached".</desc>
11224 </const>
11225 <const name="NAT" value="1"/>
11226 <const name="Bridged" value="2"/>
11227 <const name="Internal" value="3"/>
11228 <const name="HostOnly" value="4"/>
11229 <const name="VDE" value="5"/>
11230 </enum>
11231
11232 <enum
11233 name="NetworkAdapterType"
11234 uuid="3c2281e4-d952-4e87-8c7d-24379cb6a81c"
11235 >
11236 <desc>
11237 Network adapter type.
11238 </desc>
11239
11240 <const name="Null" value="0">
11241 <desc>Null value (never used by the API).</desc>
11242 </const>
11243 <const name="Am79C970A" value="1">
11244 <desc>AMD PCNet-PCI II network card (Am79C970A).</desc>
11245 </const>
11246 <const name="Am79C973" value="2">
11247 <desc>AMD PCNet-FAST III network card (Am79C973).</desc>
11248 </const>
11249 <const name="I82540EM" value="3">
11250 <desc>Intel PRO/1000 MT Desktop network card (82540EM).</desc>
11251 </const>
11252 <const name="I82543GC" value="4">
11253 <desc>Intel PRO/1000 T Server network card (82543GC).</desc>
11254 </const>
11255 <const name="I82545EM" value="5">
11256 <desc>Intel PRO/1000 MT Server network card (82545EM).</desc>
11257 </const>
11258 <const name="Virtio" value="6">
11259 <desc>Virtio network device.</desc>
11260 </const>
11261 </enum>
11262
11263 <interface
11264 name="INetworkAdapter" extends="$unknown"
11265 uuid="9bf58a46-c3f7-4f31-80fa-dde9a5dc0b7b"
11266 wsmap="managed"
11267 >
11268 <desc>
11269 Represents a virtual network adapter that is attached to a virtual machine.
11270 Each virtual machine has a fixed number of network adapter slots with one
11271 instance of this attached to each of them. Call
11272 <link to="IMachine::getNetworkAdapter" /> to get the network adapter that
11273 is attached to a given slot in a given machine.
11274
11275 Each network adapter can be in one of five attachment modes, which are
11276 represented by the <link to="NetworkAttachmentType" /> enumeration;
11277 see the <link to="#attachmentType" /> attribute.
11278 </desc>
11279
11280 <attribute name="adapterType" type="NetworkAdapterType">
11281 <desc>
11282 Type of the virtual network adapter. Depending on this value,
11283 VirtualBox will provide a different virtual network hardware
11284 to the guest.
11285 </desc>
11286 </attribute>
11287
11288 <attribute name="slot" type="unsigned long" readonly="yes">
11289 <desc>
11290 Slot number this adapter is plugged into. Corresponds to
11291 the value you pass to <link to="IMachine::getNetworkAdapter"/>
11292 to obtain this instance.
11293 </desc>
11294 </attribute>
11295
11296 <attribute name="enabled" type="boolean">
11297 <desc>
11298 Flag whether the network adapter is present in the
11299 guest system. If disabled, the virtual guest hardware will
11300 not contain this network adapter. Can only be changed when
11301 the VM is not running.
11302 </desc>
11303 </attribute>
11304
11305 <attribute name="MACAddress" type="wstring">
11306 <desc>
11307 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
11308 it to @c null or an empty string, VirtualBox will generate a unique MAC address.
11309 </desc>
11310 </attribute>
11311
11312 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
11313
11314 <attribute name="hostInterface" type="wstring">
11315 <desc>
11316 Name of the host network interface the VM is attached to.
11317 </desc>
11318 </attribute>
11319
11320 <attribute name="internalNetwork" type="wstring">
11321 <desc>
11322 Name of the internal network the VM is attached to.
11323 </desc>
11324 </attribute>
11325
11326 <attribute name="NATNetwork" type="wstring">
11327 <desc>
11328 Name of the NAT network the VM is attached to.
11329 </desc>
11330 </attribute>
11331
11332 <attribute name="VDENetwork" type="wstring">
11333 <desc>
11334 Name of the VDE switch the VM is attached to.
11335 </desc>
11336 </attribute>
11337
11338 <attribute name="cableConnected" type="boolean">
11339 <desc>
11340 Flag whether the adapter reports the cable as connected or not.
11341 It can be used to report offline situations to a VM.
11342 </desc>
11343 </attribute>
11344
11345 <attribute name="lineSpeed" type="unsigned long">
11346 <desc>
11347 Line speed reported by custom drivers, in units of 1 kbps.
11348 </desc>
11349 </attribute>
11350
11351 <attribute name="traceEnabled" type="boolean">
11352 <desc>
11353 Flag whether network traffic from/to the network card should be traced.
11354 Can only be toggled when the VM is turned off.
11355 </desc>
11356 </attribute>
11357
11358 <attribute name="traceFile" type="wstring">
11359 <desc>
11360 Filename where a network trace will be stored. If not set, VBox-pid.pcap
11361 will be used.
11362 </desc>
11363 </attribute>
11364
11365 <attribute name="natDriver" type="INATEngine" readonly="yes">
11366 <desc>
11367 Points to the NAT engine which handles the network address translation
11368 for this interface. This is active only when the interface actually uses
11369 NAT (see <link to="#attachToNAT" />).
11370 </desc>
11371 </attribute>
11372
11373 <attribute name="bootPriority" type="unsigned long">
11374 <desc>
11375 Network boot priority of the adapter. Priority 1 is highest. If not set,
11376 the priority is considered to be at the lowest possible setting.
11377 </desc>
11378 </attribute>
11379
11380 <attribute name="bandwidthLimit" type="unsigned long">
11381 <desc>
11382 Maximum throughput allowed for this network adapter, in units of 1 mbps.
11383 A zero value means uncapped/unlimited.
11384 </desc>
11385 </attribute>
11386
11387 <method name="attachToNAT">
11388 <desc>
11389 Attach the network adapter to the Network Address Translation (NAT) interface.
11390 </desc>
11391 </method>
11392
11393 <method name="attachToBridgedInterface">
11394 <desc>
11395 Attach the network adapter to a bridged host interface.
11396 </desc>
11397 </method>
11398
11399 <method name="attachToInternalNetwork">
11400 <desc>
11401 Attach the network adapter to an internal network.
11402 </desc>
11403 </method>
11404
11405 <method name="attachToHostOnlyInterface">
11406 <desc>
11407 Attach the network adapter to the host-only network.
11408 </desc>
11409 </method>
11410
11411 <method name="attachToVDE">
11412 <desc>
11413 Attach the network adapter to a VDE network.
11414 </desc>
11415 </method>
11416
11417 <method name="detach">
11418 <desc>
11419 Detach the network adapter
11420 </desc>
11421 </method>
11422 </interface>
11423
11424
11425 <!--
11426 // ISerialPort
11427 /////////////////////////////////////////////////////////////////////////
11428 -->
11429
11430 <enum
11431 name="PortMode"
11432 uuid="533b5fe3-0185-4197-86a7-17e37dd39d76"
11433 >
11434 <desc>
11435 The PortMode enumeration represents possible communication modes for
11436 the virtual serial port device.
11437 </desc>
11438
11439 <const name="Disconnected" value="0">
11440 <desc>Virtual device is not attached to any real host device.</desc>
11441 </const>
11442 <const name="HostPipe" value="1">
11443 <desc>Virtual device is attached to a host pipe.</desc>
11444 </const>
11445 <const name="HostDevice" value="2">
11446 <desc>Virtual device is attached to a host device.</desc>
11447 </const>
11448 <const name="RawFile" value="3">
11449 <desc>Virtual device is attached to a raw file.</desc>
11450 </const>
11451 </enum>
11452
11453 <interface
11454 name="ISerialPort" extends="$unknown"
11455 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
11456 wsmap="managed"
11457 >
11458
11459 <desc>
11460 The ISerialPort interface represents the virtual serial port device.
11461
11462 The virtual serial port device acts like an ordinary serial port
11463 inside the virtual machine. This device communicates to the real
11464 serial port hardware in one of two modes: host pipe or host device.
11465
11466 In host pipe mode, the #path attribute specifies the path to the pipe on
11467 the host computer that represents a serial port. The #server attribute
11468 determines if this pipe is created by the virtual machine process at
11469 machine startup or it must already exist before starting machine
11470 execution.
11471
11472 In host device mode, the #path attribute specifies the name of the
11473 serial port device on the host computer.
11474
11475 There is also a third communication mode: the disconnected mode. In this
11476 mode, the guest OS running inside the virtual machine will be able to
11477 detect the serial port, but all port write operations will be discarded
11478 and all port read operations will return no data.
11479
11480 <see>IMachine::getSerialPort</see>
11481 </desc>
11482
11483 <attribute name="slot" type="unsigned long" readonly="yes">
11484 <desc>
11485 Slot number this serial port is plugged into. Corresponds to
11486 the value you pass to <link to="IMachine::getSerialPort"/>
11487 to obtain this instance.
11488 </desc>
11489 </attribute>
11490
11491 <attribute name="enabled" type="boolean">
11492 <desc>
11493 Flag whether the serial port is enabled. If disabled,
11494 the serial port will not be reported to the guest OS.
11495 </desc>
11496 </attribute>
11497
11498 <attribute name="IOBase" type="unsigned long">
11499 <desc>Base I/O address of the serial port.</desc>
11500 </attribute>
11501
11502 <attribute name="IRQ" type="unsigned long">
11503 <desc>IRQ number of the serial port.</desc>
11504 </attribute>
11505
11506 <attribute name="hostMode" type="PortMode">
11507 <desc>
11508 How is this port connected to the host.
11509 <note>
11510 Changing this attribute may fail if the conditions for
11511 <link to="#path"/> are not met.
11512 </note>
11513 </desc>
11514 </attribute>
11515
11516 <attribute name="server" type="boolean">
11517 <desc>
11518 Flag whether this serial port acts as a server (creates a new pipe on
11519 the host) or as a client (uses the existing pipe). This attribute is
11520 used only when <link to="#hostMode"/> is PortMode_HostPipe.
11521 </desc>
11522 </attribute>
11523
11524 <attribute name="path" type="wstring">
11525 <desc>
11526 Path to the serial port's pipe on the host when <link to="ISerialPort::hostMode"/> is
11527 PortMode_HostPipe, or the host serial device name when
11528 <link to="ISerialPort::hostMode"/> is PortMode_HostDevice. For both
11529 cases, setting a @c null or empty string as the attribute's value
11530 is an error. Otherwise, the value of this property is ignored.
11531 </desc>
11532 </attribute>
11533
11534 </interface>
11535
11536 <!--
11537 // IParallelPort
11538 /////////////////////////////////////////////////////////////////////////
11539 -->
11540
11541 <interface
11542 name="IParallelPort" extends="$unknown"
11543 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
11544 wsmap="managed"
11545 >
11546
11547 <desc>
11548 The IParallelPort interface represents the virtual parallel port device.
11549
11550 The virtual parallel port device acts like an ordinary parallel port
11551 inside the virtual machine. This device communicates to the real
11552 parallel port hardware using the name of the parallel device on the host
11553 computer specified in the #path attribute.
11554
11555 Each virtual parallel port device is assigned a base I/O address and an
11556 IRQ number that will be reported to the guest operating system and used
11557 to operate the given parallel port from within the virtual machine.
11558
11559 <see>IMachine::getParallelPort</see>
11560 </desc>
11561
11562 <attribute name="slot" type="unsigned long" readonly="yes">
11563 <desc>
11564 Slot number this parallel port is plugged into. Corresponds to
11565 the value you pass to <link to="IMachine::getParallelPort"/>
11566 to obtain this instance.
11567 </desc>
11568 </attribute>
11569
11570 <attribute name="enabled" type="boolean">
11571 <desc>
11572 Flag whether the parallel port is enabled. If disabled,
11573 the parallel port will not be reported to the guest OS.
11574 </desc>
11575 </attribute>
11576
11577 <attribute name="IOBase" type="unsigned long">
11578 <desc>Base I/O address of the parallel port.</desc>
11579 </attribute>
11580
11581 <attribute name="IRQ" type="unsigned long">
11582 <desc>IRQ number of the parallel port.</desc>
11583 </attribute>
11584
11585 <attribute name="path" type="wstring">
11586 <desc>
11587 Host parallel device name. If this parallel port is enabled, setting a
11588 @c null or an empty string as this attribute's value will result into
11589 an error.
11590 </desc>
11591 </attribute>
11592
11593 </interface>
11594
11595
11596 <!--
11597 // IMachineDebugger
11598 /////////////////////////////////////////////////////////////////////////
11599 -->
11600
11601 <interface
11602 name="IMachineDebugger" extends="$unknown"
11603 uuid="b0b2a2dd-0627-4502-91c2-ddc5e77609e0"
11604 wsmap="suppress"
11605 >
11606 <method name="resetStats">
11607 <desc>
11608 Reset VM statistics.
11609 </desc>
11610 <param name="pattern" type="wstring" dir="in">
11611 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11612 </param>
11613 </method>
11614
11615 <method name="dumpStats">
11616 <desc>
11617 Dumps VM statistics.
11618 </desc>
11619 <param name="pattern" type="wstring" dir="in">
11620 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11621 </param>
11622 </method>
11623
11624 <method name="getStats">
11625 <desc>
11626 Get the VM statistics in a XMLish format.
11627 </desc>
11628 <param name="pattern" type="wstring" dir="in">
11629 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11630 </param>
11631 <param name="withDescriptions" type="boolean" dir="in">
11632 <desc>Whether to include the descriptions.</desc>
11633 </param>
11634 <param name="stats" type="wstring" dir="out">
11635 <desc>The XML document containing the statistics.</desc>
11636 </param>
11637 </method>
11638
11639 <method name="injectNMI">
11640 <desc>
11641 Inject an NMI into a running VT-x/AMD-V VM.
11642 </desc>
11643 </method>
11644
11645 <attribute name="singlestep" type="boolean">
11646 <desc>Switch for enabling singlestepping.</desc>
11647 </attribute>
11648
11649 <attribute name="recompileUser" type="boolean">
11650 <desc>Switch for forcing code recompilation for user mode code.</desc>
11651 </attribute>
11652
11653 <attribute name="recompileSupervisor" type="boolean">
11654 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
11655 </attribute>
11656
11657 <attribute name="PATMEnabled" type="boolean">
11658 <desc>Switch for enabling and disabling the PATM component.</desc>
11659 </attribute>
11660
11661 <attribute name="CSAMEnabled" type="boolean">
11662 <desc>Switch for enabling and disabling the CSAM component.</desc>
11663 </attribute>
11664
11665 <attribute name="logEnabled" type="boolean">
11666 <desc>Switch for enabling and disabling logging.</desc>
11667 </attribute>
11668
11669 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
11670 <desc>
11671 Flag indicating whether the VM is currently making use of CPU hardware
11672 virtualization extensions.
11673 </desc>
11674 </attribute>
11675
11676 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" readonly="yes">
11677 <desc>
11678 Flag indicating whether the VM is currently making use of the nested paging
11679 CPU hardware virtualization extension.
11680 </desc>
11681 </attribute>
11682
11683 <attribute name="HWVirtExVPIDEnabled" type="boolean" readonly="yes">
11684 <desc>
11685 Flag indicating whether the VM is currently making use of the VPID
11686 VT-x extension.
11687 </desc>
11688 </attribute>
11689
11690 <attribute name="PAEEnabled" type="boolean" readonly="yes">
11691 <desc>
11692 Flag indicating whether the VM is currently making use of the Physical
11693 Address Extension CPU feature.
11694 </desc>
11695 </attribute>
11696
11697 <attribute name="virtualTimeRate" type="unsigned long">
11698 <desc>
11699 The rate at which the virtual time runs expressed as a percentage.
11700 The accepted range is 2% to 20000%.
11701 </desc>
11702 </attribute>
11703
11704 <!-- @todo method for setting log flags, groups and destination! -->
11705
11706 <attribute name="VM" type="long long" readonly="yes">
11707 <desc>
11708 Gets the VM handle. This is only for internal use while
11709 we carve the details of this interface.
11710 </desc>
11711 </attribute>
11712
11713 </interface>
11714
11715 <!--
11716 // IUSBController
11717 /////////////////////////////////////////////////////////////////////////
11718 -->
11719
11720 <interface
11721 name="IUSBController" extends="$unknown"
11722 uuid="6fdcccc5-abd3-4fec-9387-2ad3914fc4a8"
11723 wsmap="managed"
11724 >
11725 <attribute name="enabled" type="boolean">
11726 <desc>
11727 Flag whether the USB controller is present in the
11728 guest system. If disabled, the virtual guest hardware will
11729 not contain any USB controller. Can only be changed when
11730 the VM is powered off.
11731 </desc>
11732 </attribute>
11733
11734 <attribute name="enabledEhci" type="boolean">
11735 <desc>
11736 Flag whether the USB EHCI controller is present in the
11737 guest system. If disabled, the virtual guest hardware will
11738 not contain a USB EHCI controller. Can only be changed when
11739 the VM is powered off.
11740 </desc>
11741 </attribute>
11742
11743 <attribute name="proxyAvailable" type="boolean" readonly="yes">
11744 <desc>
11745 Flag whether there is an USB proxy available.
11746 </desc>
11747 </attribute>
11748
11749 <attribute name="USBStandard" type="unsigned short" readonly="yes">
11750 <desc>
11751 USB standard version which the controller implements.
11752 This is a BCD which means that the major version is in the
11753 high byte and minor version is in the low byte.
11754 </desc>
11755 </attribute>
11756
11757 <attribute name="deviceFilters" type="IUSBDeviceFilter" readonly="yes" safearray="yes">
11758 <desc>
11759 List of USB device filters associated with the machine.
11760
11761 If the machine is currently running, these filters are activated
11762 every time a new (supported) USB device is attached to the host
11763 computer that was not ignored by global filters
11764 (<link to="IHost::USBDeviceFilters"/>).
11765
11766 These filters are also activated when the machine is powered up.
11767 They are run against a list of all currently available USB
11768 devices (in states
11769 <link to="USBDeviceState_Available"/>,
11770 <link to="USBDeviceState_Busy"/>,
11771 <link to="USBDeviceState_Held"/>) that were not previously
11772 ignored by global filters.
11773
11774 If at least one filter matches the USB device in question, this
11775 device is automatically captured (attached to) the virtual USB
11776 controller of this machine.
11777
11778 <see>IUSBDeviceFilter, ::IUSBController</see>
11779 </desc>
11780 </attribute>
11781
11782 <method name="createDeviceFilter">
11783 <desc>
11784 Creates a new USB device filter. All attributes except
11785 the filter name are set to empty (any match),
11786 <i>active</i> is @c false (the filter is not active).
11787
11788 The created filter can then be added to the list of filters using
11789 <link to="#insertDeviceFilter"/>.
11790
11791 <result name="VBOX_E_INVALID_VM_STATE">
11792 The virtual machine is not mutable.
11793 </result>
11794
11795 <see>#deviceFilters</see>
11796 </desc>
11797 <param name="name" type="wstring" dir="in">
11798 <desc>
11799 Filter name. See <link to="IUSBDeviceFilter::name"/>
11800 for more info.
11801 </desc>
11802 </param>
11803 <param name="filter" type="IUSBDeviceFilter" dir="return">
11804 <desc>Created filter object.</desc>
11805 </param>
11806 </method>
11807
11808 <method name="insertDeviceFilter">
11809 <desc>
11810 Inserts the given USB device to the specified position
11811 in the list of filters.
11812
11813 Positions are numbered starting from <tt>0</tt>. If the specified
11814 position is equal to or greater than the number of elements in
11815 the list, the filter is added to the end of the collection.
11816
11817 <note>
11818 Duplicates are not allowed, so an attempt to insert a
11819 filter that is already in the collection, will return an
11820 error.
11821 </note>
11822
11823 <result name="VBOX_E_INVALID_VM_STATE">
11824 Virtual machine is not mutable.
11825 </result>
11826 <result name="E_INVALIDARG">
11827 USB device filter not created within this VirtualBox instance.
11828 </result>
11829 <result name="VBOX_E_INVALID_OBJECT_STATE">
11830 USB device filter already in list.
11831 </result>
11832
11833 <see>#deviceFilters</see>
11834 </desc>
11835 <param name="position" type="unsigned long" dir="in">
11836 <desc>Position to insert the filter to.</desc>
11837 </param>
11838 <param name="filter" type="IUSBDeviceFilter" dir="in">
11839 <desc>USB device filter to insert.</desc>
11840 </param>
11841 </method>
11842
11843 <method name="removeDeviceFilter">
11844 <desc>
11845 Removes a USB device filter from the specified position in the
11846 list of filters.
11847
11848 Positions are numbered starting from <tt>0</tt>. Specifying a
11849 position equal to or greater than the number of elements in
11850 the list will produce an error.
11851
11852 <see>#deviceFilters</see>
11853
11854 <result name="VBOX_E_INVALID_VM_STATE">
11855 Virtual machine is not mutable.
11856 </result>
11857 <result name="E_INVALIDARG">
11858 USB device filter list empty or invalid @a position.
11859 </result>
11860
11861 </desc>
11862 <param name="position" type="unsigned long" dir="in">
11863 <desc>Position to remove the filter from.</desc>
11864 </param>
11865 <param name="filter" type="IUSBDeviceFilter" dir="return">
11866 <desc>Removed USB device filter.</desc>
11867 </param>
11868 </method>
11869
11870 </interface>
11871
11872
11873 <!--
11874 // IUSBDevice
11875 /////////////////////////////////////////////////////////////////////////
11876 -->
11877
11878 <interface
11879 name="IUSBDevice" extends="$unknown"
11880 uuid="f8967b0b-4483-400f-92b5-8b675d98a85b"
11881 wsmap="managed"
11882 >
11883 <desc>
11884 The IUSBDevice interface represents a virtual USB device attached to the
11885 virtual machine.
11886
11887 A collection of objects implementing this interface is stored in the
11888 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
11889 attached to a running virtual machine's USB controller.
11890 </desc>
11891
11892 <attribute name="id" type="uuid" mod="string" readonly="yes">
11893 <desc>
11894 Unique USB device ID. This ID is built from #vendorId,
11895 #productId, #revision and #serialNumber.
11896 </desc>
11897 </attribute>
11898
11899 <attribute name="vendorId" type="unsigned short" readonly="yes">
11900 <desc>Vendor ID.</desc>
11901 </attribute>
11902
11903 <attribute name="productId" type="unsigned short" readonly="yes">
11904 <desc>Product ID.</desc>
11905 </attribute>
11906
11907 <attribute name="revision" type="unsigned short" readonly="yes">
11908 <desc>
11909 Product revision number. This is a packed BCD represented as
11910 unsigned short. The high byte is the integer part and the low
11911 byte is the decimal.
11912 </desc>
11913 </attribute>
11914
11915 <attribute name="manufacturer" type="wstring" readonly="yes">
11916 <desc>Manufacturer string.</desc>
11917 </attribute>
11918
11919 <attribute name="product" type="wstring" readonly="yes">
11920 <desc>Product string.</desc>
11921 </attribute>
11922
11923 <attribute name="serialNumber" type="wstring" readonly="yes">
11924 <desc>Serial number string.</desc>
11925 </attribute>
11926
11927 <attribute name="address" type="wstring" readonly="yes">
11928 <desc>Host specific address of the device.</desc>
11929 </attribute>
11930
11931 <attribute name="port" type="unsigned short" readonly="yes">
11932 <desc>
11933 Host USB port number the device is physically
11934 connected to.
11935 </desc>
11936 </attribute>
11937
11938 <attribute name="version" type="unsigned short" readonly="yes">
11939 <desc>
11940 The major USB version of the device - 1 or 2.
11941 </desc>
11942 </attribute>
11943
11944 <attribute name="portVersion" type="unsigned short" readonly="yes">
11945 <desc>
11946 The major USB version of the host USB port the device is
11947 physically connected to - 1 or 2. For devices not connected to
11948 anything this will have the same value as the version attribute.
11949 </desc>
11950 </attribute>
11951
11952 <attribute name="remote" type="boolean" readonly="yes">
11953 <desc>
11954 Whether the device is physically connected to a remote VRDP
11955 client or to a local host machine.
11956 </desc>
11957 </attribute>
11958
11959 </interface>
11960
11961
11962 <!--
11963 // IUSBDeviceFilter
11964 /////////////////////////////////////////////////////////////////////////
11965 -->
11966
11967 <interface
11968 name="IUSBDeviceFilter" extends="$unknown"
11969 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
11970 wsmap="managed"
11971 >
11972 <desc>
11973 The IUSBDeviceFilter interface represents an USB device filter used
11974 to perform actions on a group of USB devices.
11975
11976 This type of filters is used by running virtual machines to
11977 automatically capture selected USB devices once they are physically
11978 attached to the host computer.
11979
11980 A USB device is matched to the given device filter if and only if all
11981 attributes of the device match the corresponding attributes of the
11982 filter (that is, attributes are joined together using the logical AND
11983 operation). On the other hand, all together, filters in the list of
11984 filters carry the semantics of the logical OR operation. So if it is
11985 desirable to create a match like "this vendor id OR this product id",
11986 one needs to create two filters and specify "any match" (see below)
11987 for unused attributes.
11988
11989 All filter attributes used for matching are strings. Each string
11990 is an expression representing a set of values of the corresponding
11991 device attribute, that will match the given filter. Currently, the
11992 following filtering expressions are supported:
11993
11994 <ul>
11995 <li><i>Interval filters</i>. Used to specify valid intervals for
11996 integer device attributes (Vendor ID, Product ID and Revision).
11997 The format of the string is:
11998
11999 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
12000
12001 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
12002 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
12003 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
12004 is omitted before a dash (<tt>-</tt>), the minimum possible integer
12005 is assumed; if <tt>n</tt> is omitted after a dash, the maximum
12006 possible integer is assumed.
12007 </li>
12008 <li><i>Boolean filters</i>. Used to specify acceptable values for
12009 boolean device attributes. The format of the string is:
12010
12011 <tt>true|false|yes|no|0|1</tt>
12012
12013 </li>
12014 <li><i>Exact match</i>. Used to specify a single value for the given
12015 device attribute. Any string that doesn't start with <tt>int:</tt>
12016 represents the exact match. String device attributes are compared to
12017 this string including case of symbols. Integer attributes are first
12018 converted to a string (see individual filter attributes) and then
12019 compared ignoring case.
12020
12021 </li>
12022 <li><i>Any match</i>. Any value of the corresponding device attribute
12023 will match the given filter. An empty or @c null string is
12024 used to construct this type of filtering expressions.
12025
12026 </li>
12027 </ul>
12028
12029 <note>
12030 On the Windows host platform, interval filters are not currently
12031 available. Also all string filter attributes
12032 (<link to="#manufacturer"/>, <link to="#product"/>,
12033 <link to="#serialNumber"/>) are ignored, so they behave as
12034 <i>any match</i> no matter what string expression is specified.
12035 </note>
12036
12037 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
12038 </desc>
12039
12040 <attribute name="name" type="wstring">
12041 <desc>
12042 Visible name for this filter.
12043 This name is used to visually distinguish one filter from another,
12044 so it can neither be @c null nor an empty string.
12045 </desc>
12046 </attribute>
12047
12048 <attribute name="active" type="boolean">
12049 <desc>Whether this filter active or has been temporarily disabled.</desc>
12050 </attribute>
12051
12052 <attribute name="vendorId" type="wstring">
12053 <desc>
12054 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
12055 The string representation for the <i>exact matching</i>
12056 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
12057 (including leading zeroes).
12058 </desc>
12059 </attribute>
12060
12061 <attribute name="productId" type="wstring">
12062 <desc>
12063 <link to="IUSBDevice::productId">Product ID</link> filter.
12064 The string representation for the <i>exact matching</i>
12065 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
12066 (including leading zeroes).
12067 </desc>
12068 </attribute>
12069
12070 <attribute name="revision" type="wstring">
12071 <desc>
12072 <link to="IUSBDevice::productId">Product revision number</link>
12073 filter. The string representation for the <i>exact matching</i>
12074 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
12075 of the integer part of the revision, and <tt>F</tt> is the
12076 decimal digit of its fractional part (including leading and
12077 trailing zeros).
12078 Note that for interval filters, it's best to use the hexadecimal
12079 form, because the revision is stored as a 16 bit packed BCD value;
12080 so the expression <tt>int:0x0100-0x0199</tt> will match any
12081 revision from <tt>1.0</tt> to <tt>1.99</tt>.
12082 </desc>
12083 </attribute>
12084
12085 <attribute name="manufacturer" type="wstring">
12086 <desc>
12087 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
12088 </desc>
12089 </attribute>
12090
12091 <attribute name="product" type="wstring">
12092 <desc>
12093 <link to="IUSBDevice::product">Product</link> filter.
12094 </desc>
12095 </attribute>
12096
12097 <attribute name="serialNumber" type="wstring">
12098 <desc>
12099 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
12100 </desc>
12101 </attribute>
12102
12103 <attribute name="port" type="wstring">
12104 <desc>
12105 <link to="IUSBDevice::port">Host USB port</link> filter.
12106 </desc>
12107 </attribute>
12108
12109 <attribute name="remote" type="wstring">
12110 <desc>
12111 <link to="IUSBDevice::remote">Remote state</link> filter.
12112 <note>
12113 This filter makes sense only for machine USB filters,
12114 i.e. it is ignored by IHostUSBDeviceFilter objects.
12115 </note>
12116 </desc>
12117 </attribute>
12118
12119 <attribute name="maskedInterfaces" type="unsigned long">
12120 <desc>
12121 This is an advanced option for hiding one or more USB interfaces
12122 from the guest. The value is a bit mask where the bits that are set
12123 means the corresponding USB interface should be hidden, masked off
12124 if you like.
12125 This feature only works on Linux hosts.
12126 </desc>
12127 </attribute>
12128
12129 </interface>
12130
12131
12132 <!--
12133 // IHostUSBDevice
12134 /////////////////////////////////////////////////////////////////////////
12135 -->
12136
12137 <enum
12138 name="USBDeviceState"
12139 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
12140 >
12141 <desc>
12142 USB device state. This enumeration represents all possible states
12143 of the USB device physically attached to the host computer regarding
12144 its state on the host computer and availability to guest computers
12145 (all currently running virtual machines).
12146
12147 Once a supported USB device is attached to the host, global USB
12148 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
12149 either ignore the device, or put it to USBDeviceState_Held state, or do
12150 nothing. Unless the device is ignored by global filters, filters of all
12151 currently running guests (<link to="IUSBController::deviceFilters"/>) are
12152 activated that can put it to USBDeviceState_Captured state.
12153
12154 If the device was ignored by global filters, or didn't match
12155 any filters at all (including guest ones), it is handled by the host
12156 in a normal way. In this case, the device state is determined by
12157 the host and can be one of USBDeviceState_Unavailable, USBDeviceState_Busy
12158 or USBDeviceState_Available, depending on the current device usage.
12159
12160 Besides auto-capturing based on filters, the device can be manually
12161 captured by guests (<link to="IConsole::attachUSBDevice"/>) if its
12162 state is USBDeviceState_Busy, USBDeviceState_Available or
12163 USBDeviceState_Held.
12164
12165 <note>
12166 Due to differences in USB stack implementations in Linux and Win32,
12167 states USBDeviceState_Busy and USBDeviceState_vailable are applicable
12168 only to the Linux version of the product. This also means that (<link
12169 to="IConsole::attachUSBDevice"/>) can only succeed on Win32 if the
12170 device state is USBDeviceState_Held.
12171 </note>
12172
12173 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
12174 </desc>
12175
12176 <const name="NotSupported" value="0">
12177 <desc>
12178 Not supported by the VirtualBox server, not available to guests.
12179 </desc>
12180 </const>
12181 <const name="Unavailable" value="1">
12182 <desc>
12183 Being used by the host computer exclusively,
12184 not available to guests.
12185 </desc>
12186 </const>
12187 <const name="Busy" value="2">
12188 <desc>
12189 Being used by the host computer, potentially available to guests.
12190 </desc>
12191 </const>
12192 <const name="Available" value="3">
12193 <desc>
12194 Not used by the host computer, available to guests (the host computer
12195 can also start using the device at any time).
12196 </desc>
12197 </const>
12198 <const name="Held" value="4">
12199 <desc>
12200 Held by the VirtualBox server (ignored by the host computer),
12201 available to guests.
12202 </desc>
12203 </const>
12204 <const name="Captured" value="5">
12205 <desc>
12206 Captured by one of the guest computers, not available
12207 to anybody else.
12208 </desc>
12209 </const>
12210 </enum>
12211
12212 <interface
12213 name="IHostUSBDevice" extends="IUSBDevice"
12214 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
12215 wsmap="managed"
12216 >
12217 <desc>
12218 The IHostUSBDevice interface represents a physical USB device attached
12219 to the host computer.
12220
12221 Besides properties inherited from IUSBDevice, this interface adds the
12222 <link to="#state"/> property that holds the current state of the USB
12223 device.
12224
12225 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
12226 </desc>
12227
12228 <attribute name="state" type="USBDeviceState" readonly="yes">
12229 <desc>
12230 Current state of the device.
12231 </desc>
12232 </attribute>
12233
12234 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
12235
12236 </interface>
12237
12238
12239 <!--
12240 // IHostUSBDeviceFilter
12241 /////////////////////////////////////////////////////////////////////////
12242 -->
12243
12244 <enum
12245 name="USBDeviceFilterAction"
12246 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
12247 >
12248 <desc>
12249 Actions for host USB device filters.
12250 <see>IHostUSBDeviceFilter, USBDeviceState</see>
12251 </desc>
12252
12253 <const name="Null" value="0">
12254 <desc>Null value (never used by the API).</desc>
12255 </const>
12256 <const name="Ignore" value="1">
12257 <desc>Ignore the matched USB device.</desc>
12258 </const>
12259 <const name="Hold" value="2">
12260 <desc>Hold the matched USB device.</desc>
12261 </const>
12262 </enum>
12263
12264 <interface
12265 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
12266 uuid="4cc70246-d74a-400f-8222-3900489c0374"
12267 wsmap="managed"
12268 >
12269 <desc>
12270 The IHostUSBDeviceFilter interface represents a global filter for a
12271 physical USB device used by the host computer. Used indirectly in
12272 <link to="IHost::USBDeviceFilters"/>.
12273
12274 Using filters of this type, the host computer determines the initial
12275 state of the USB device after it is physically attached to the
12276 host's USB controller.
12277
12278 <note>
12279 The <link to="IUSBDeviceFilter::remote"/> attribute is ignored by this type of
12280 filters, because it makes sense only for
12281 <link to="IUSBController::deviceFilters">machine USB filters</link>.
12282 </note>
12283
12284 <see>IHost::USBDeviceFilters</see>
12285 </desc>
12286
12287 <attribute name="action" type="USBDeviceFilterAction">
12288 <desc>
12289 Action performed by the host when an attached USB device
12290 matches this filter.
12291 </desc>
12292 </attribute>
12293
12294 </interface>
12295
12296 <!--
12297 // IAudioAdapter
12298 /////////////////////////////////////////////////////////////////////////
12299 -->
12300
12301 <enum
12302 name="AudioDriverType"
12303 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
12304 >
12305 <desc>
12306 Host audio driver type.
12307 </desc>
12308
12309 <const name="Null" value="0">
12310 <desc>Null value, also means "dummy audio driver".</desc>
12311 </const>
12312 <const name="WinMM" value="1">
12313 <desc>Windows multimedia (Windows hosts only).</desc>
12314 </const>
12315 <const name="OSS" value="2">
12316 <desc>Open Sound System (Linux hosts only).</desc>
12317 </const>
12318 <const name="ALSA" value="3">
12319 <desc>Advanced Linux Sound Architecture (Linux hosts only).</desc>
12320 </const>
12321 <const name="DirectSound" value="4">
12322 <desc>DirectSound (Windows hosts only).</desc>
12323 </const>
12324 <const name="CoreAudio" value="5">
12325 <desc>CoreAudio (Mac hosts only).</desc>
12326 </const>
12327 <const name="MMPM" value="6">
12328 <desc>Reserved for historical reasons.</desc>
12329 </const>
12330 <const name="Pulse" value="7">
12331 <desc>PulseAudio (Linux hosts only).</desc>
12332 </const>
12333 <const name="SolAudio" value="8">
12334 <desc>Solaris audio (Solaris hosts only).</desc>
12335 </const>
12336 </enum>
12337
12338 <enum
12339 name="AudioControllerType"
12340 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
12341 >
12342 <desc>
12343 Virtual audio controller type.
12344 </desc>
12345
12346 <const name="AC97" value="0"/>
12347 <const name="SB16" value="1"/>
12348 <const name="HDA" value="2"/>
12349 </enum>
12350
12351 <interface
12352 name="IAudioAdapter" extends="$unknown"
12353 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
12354 wsmap="managed"
12355 >
12356 <desc>
12357 The IAudioAdapter interface represents the virtual audio adapter of
12358 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
12359 </desc>
12360 <attribute name="enabled" type="boolean">
12361 <desc>
12362 Flag whether the audio adapter is present in the
12363 guest system. If disabled, the virtual guest hardware will
12364 not contain any audio adapter. Can only be changed when
12365 the VM is not running.
12366 </desc>
12367 </attribute>
12368 <attribute name="audioController" type="AudioControllerType">
12369 <desc>
12370 The audio hardware we emulate.
12371 </desc>
12372 </attribute>
12373 <attribute name="audioDriver" type="AudioDriverType">
12374 <desc>
12375 Audio driver the adapter is connected to. This setting
12376 can only be changed when the VM is not running.
12377 </desc>
12378 </attribute>
12379 </interface>
12380
12381 <!--
12382 // IVRDPServer
12383 /////////////////////////////////////////////////////////////////////////
12384 -->
12385
12386 <enum
12387 name="VRDPAuthType"
12388 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
12389 >
12390 <desc>
12391 VRDP authentication type.
12392 </desc>
12393
12394 <const name="Null" value="0">
12395 <desc>Null value, also means "no authentication".</desc>
12396 </const>
12397 <const name="External" value="1"/>
12398 <const name="Guest" value="2"/>
12399 </enum>
12400
12401 <interface
12402 name="IVRDPServer" extends="$unknown"
12403 uuid="7aeeb530-0b08-41fe-835d-9be9ec1dbe5c"
12404 wsmap="managed"
12405 >
12406 <attribute name="enabled" type="boolean">
12407 <desc>VRDP server status.</desc>
12408 </attribute>
12409
12410 <attribute name="ports" type="wstring">
12411 <desc>
12412 VRDP server port numbers. The server will try to bind to one of free ports from the list.
12413 <note>
12414 This is a string of comma separated TCP port numbers or port number ranges.
12415 Example <tt>5000,5010-5012,5015</tt>
12416 </note>
12417 </desc>
12418 </attribute>
12419
12420 <attribute name="netAddress" type="wstring">
12421 <desc>VRDP server address.</desc>
12422 </attribute>
12423
12424 <attribute name="authType" type="VRDPAuthType">
12425 <desc>VRDP authentication method.</desc>
12426 </attribute>
12427
12428 <attribute name="authTimeout" type="unsigned long">
12429 <desc>Timeout for guest authentication. Milliseconds.</desc>
12430 </attribute>
12431
12432 <attribute name="allowMultiConnection" type="boolean">
12433 <desc>
12434 Flag whether multiple simultaneous connections to the VM are permitted.
12435 Note that this will be replaced by a more powerful mechanism in the future.
12436 </desc>
12437 </attribute>
12438
12439 <attribute name="reuseSingleConnection" type="boolean">
12440 <desc>
12441 Flag whether the existing connection must be dropped and a new connection
12442 must be established by the VRDP server, when a new client connects in single
12443 connection mode.
12444 </desc>
12445 </attribute>
12446
12447 <attribute name="videoChannel" type="boolean">
12448 <desc>
12449 Flag whether RDP video channel is supported.
12450 </desc>
12451 </attribute>
12452
12453 <attribute name="videoChannelQuality" type="unsigned long">
12454 <desc>
12455 Image quality in percents.
12456 </desc>
12457 </attribute>
12458
12459 </interface>
12460
12461
12462 <!--
12463 // ISharedFolder
12464 /////////////////////////////////////////////////////////////////////////
12465 -->
12466
12467 <interface
12468 name="ISharedFolder" extends="$unknown"
12469 uuid="8388da11-b559-4574-a5b7-2bd7acd5cef8"
12470 wsmap="struct"
12471 >
12472 <desc>
12473 The ISharedFolder interface represents a folder in the host computer's
12474 file system accessible from the guest OS running inside a virtual
12475 machine using an associated logical name.
12476
12477 There are three types of shared folders:
12478 <ul>
12479 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
12480 folders available to all virtual machines.</li>
12481 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
12482 VM-specific shared folders available to the given virtual machine at
12483 startup.</li>
12484 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
12485 VM-specific shared folders created in the session context (for
12486 example, when the virtual machine is running) and automatically
12487 discarded when the session is closed (the VM is powered off).</li>
12488 </ul>
12489
12490 Logical names of shared folders must be unique within the given scope
12491 (global, permanent or transient). However, they do not need to be unique
12492 across scopes. In this case, the definition of the shared folder in a
12493 more specific scope takes precedence over definitions in all other
12494 scopes. The order of precedence is (more specific to more general):
12495 <ol>
12496 <li>Transient definitions</li>
12497 <li>Permanent definitions</li>
12498 <li>Global definitions</li>
12499 </ol>
12500
12501 For example, if MyMachine has a shared folder named
12502 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then creating a
12503 transient shared folder named <tt>C_DRIVE</tt> (that points
12504 to <tt>C:\\\\WINDOWS</tt>) will change the definition
12505 of <tt>C_DRIVE</tt> in the guest OS so
12506 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
12507 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
12508 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
12509 the previous (permanent) definition of <tt>C_DRIVE</tt> that points
12510 to <tt>C:\\</tt> if it still exists.
12511
12512 Note that permanent and transient shared folders of different machines
12513 are in different name spaces, so they don't overlap and don't need to
12514 have unique logical names.
12515
12516 <note>
12517 Global shared folders are not implemented in the current version of the
12518 product.
12519 </note>
12520 </desc>
12521
12522 <attribute name="name" type="wstring" readonly="yes">
12523 <desc>Logical name of the shared folder.</desc>
12524 </attribute>
12525
12526 <attribute name="hostPath" type="wstring" readonly="yes">
12527 <desc>Full path to the shared folder in the host file system.</desc>
12528 </attribute>
12529
12530 <attribute name="accessible" type="boolean" readonly="yes">
12531 <desc>
12532 Whether the folder defined by the host path is currently
12533 accessible or not.
12534 For example, the folder can be unaccessible if it is placed
12535 on the network share that is not available by the time
12536 this property is read.
12537 </desc>
12538 </attribute>
12539
12540 <attribute name="writable" type="boolean" readonly="yes">
12541 <desc>
12542 Whether the folder defined by the host path is writable or
12543 not.
12544 </desc>
12545 </attribute>
12546
12547 <attribute name="autoMount" type="boolean" readonly="yes">
12548 <desc>
12549 Whether the folder gets automatically mounted by the guest or not.
12550 </desc>
12551 </attribute>
12552
12553 <attribute name="lastAccessError" type="wstring" readonly="yes">
12554 <desc>
12555 Text message that represents the result of the last accessibility
12556 check.
12557
12558 Accessibility checks are performed each time the <link to="#accessible"/>
12559 attribute is read. An empty string is returned if the last
12560 accessibility check was successful. A non-empty string indicates a
12561 failure and should normally describe a reason of the failure (for
12562 example, a file read error).
12563 </desc>
12564 </attribute>
12565
12566 </interface>
12567
12568 <!--
12569 // ISession
12570 /////////////////////////////////////////////////////////////////////////
12571 -->
12572
12573 <interface
12574 name="IInternalSessionControl" extends="$unknown"
12575 uuid="0431ef9e-2c2e-42af-87d7-c8f52455f28a"
12576 internal="yes"
12577 wsmap="suppress"
12578 >
12579 <method name="getPID">
12580 <desc>PID of the process that has created this Session object.
12581 </desc>
12582 <param name="pid" type="unsigned long" dir="return"/>
12583 </method>
12584
12585 <method name="getRemoteConsole">
12586 <desc>
12587 Returns the console object suitable for remote control.
12588
12589 <result name="VBOX_E_INVALID_VM_STATE">
12590 Session state prevents operation.
12591 </result>
12592 <result name="VBOX_E_INVALID_OBJECT_STATE">
12593 Session type prevents operation.
12594 </result>
12595
12596 </desc>
12597 <param name="console" type="IConsole" dir="return"/>
12598 </method>
12599
12600 <method name="assignMachine">
12601 <desc>
12602 Assigns the machine object associated with this direct-type
12603 session or informs the session that it will be a remote one
12604 (if @a machine == @c null).
12605
12606 <result name="VBOX_E_INVALID_VM_STATE">
12607 Session state prevents operation.
12608 </result>
12609 <result name="VBOX_E_INVALID_OBJECT_STATE">
12610 Session type prevents operation.
12611 </result>
12612
12613 </desc>
12614 <param name="machine" type="IMachine" dir="in"/>
12615 </method>
12616
12617 <method name="assignRemoteMachine">
12618 <desc>
12619 Assigns the machine and the (remote) console object associated with
12620 this remote-type session.
12621
12622 <result name="VBOX_E_INVALID_VM_STATE">
12623 Session state prevents operation.
12624 </result>
12625
12626 </desc>
12627 <param name="machine" type="IMachine" dir="in"/>
12628 <param name="console" type="IConsole" dir="in"/>
12629 </method>
12630
12631 <method name="updateMachineState">
12632 <desc>
12633 Updates the machine state in the VM process.
12634 Must be called only in certain cases
12635 (see the method implementation).
12636
12637 <result name="VBOX_E_INVALID_VM_STATE">
12638 Session state prevents operation.
12639 </result>
12640 <result name="VBOX_E_INVALID_OBJECT_STATE">
12641 Session type prevents operation.
12642 </result>
12643
12644 </desc>
12645 <param name="aMachineState" type="MachineState" dir="in"/>
12646 </method>
12647
12648 <method name="uninitialize">
12649 <desc>
12650 Uninitializes (closes) this session. Used by VirtualBox to close
12651 the corresponding remote session when the direct session dies
12652 or gets closed.
12653
12654 <result name="VBOX_E_INVALID_VM_STATE">
12655 Session state prevents operation.
12656 </result>
12657
12658 </desc>
12659 </method>
12660
12661 <method name="onNetworkAdapterChange">
12662 <desc>
12663 Triggered when settings of a network adapter of the
12664 associated virtual machine have changed.
12665
12666 <result name="VBOX_E_INVALID_VM_STATE">
12667 Session state prevents operation.
12668 </result>
12669 <result name="VBOX_E_INVALID_OBJECT_STATE">
12670 Session type prevents operation.
12671 </result>
12672
12673 </desc>
12674 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
12675 <param name="changeAdapter" type="boolean" dir="in"/>
12676 </method>
12677
12678 <method name="onSerialPortChange">
12679 <desc>
12680 Triggered when settings of a serial port of the
12681 associated virtual machine have changed.
12682
12683 <result name="VBOX_E_INVALID_VM_STATE">
12684 Session state prevents operation.
12685 </result>
12686 <result name="VBOX_E_INVALID_OBJECT_STATE">
12687 Session type prevents operation.
12688 </result>
12689
12690 </desc>
12691 <param name="serialPort" type="ISerialPort" dir="in"/>
12692 </method>
12693
12694 <method name="onParallelPortChange">
12695 <desc>
12696 Triggered when settings of a parallel port of the
12697 associated virtual machine have changed.
12698
12699 <result name="VBOX_E_INVALID_VM_STATE">
12700 Session state prevents operation.
12701 </result>
12702 <result name="VBOX_E_INVALID_OBJECT_STATE">
12703 Session type prevents operation.
12704 </result>
12705
12706 </desc>
12707 <param name="parallelPort" type="IParallelPort" dir="in"/>
12708 </method>
12709
12710 <method name="onStorageControllerChange">
12711 <desc>
12712 Triggered when settings of a storage controller of the
12713 associated virtual machine have changed.
12714
12715 <result name="VBOX_E_INVALID_VM_STATE">
12716 Session state prevents operation.
12717 </result>
12718 <result name="VBOX_E_INVALID_OBJECT_STATE">
12719 Session type prevents operation.
12720 </result>
12721
12722 </desc>
12723 </method>
12724
12725 <method name="onMediumChange">
12726 <desc>
12727 Triggered when attached media of the
12728 associated virtual machine have changed.
12729
12730 <result name="VBOX_E_INVALID_VM_STATE">
12731 Session state prevents operation.
12732 </result>
12733 <result name="VBOX_E_INVALID_OBJECT_STATE">
12734 Session type prevents operation.
12735 </result>
12736
12737 </desc>
12738
12739 <param name="mediumAttachment" type="IMediumAttachment" dir="in"/>
12740 <param name="force" type="boolean" dir="in"/>
12741 </method>
12742
12743 <method name="onCPUChange">
12744 <desc>
12745 Notification when a CPU changes.
12746 </desc>
12747 <param name="cpu" type="unsigned long" dir="in">
12748 <desc>The CPU which changed</desc>
12749 </param>
12750 <param name="add" type="boolean" dir="in">
12751 <desc>Flag whether the CPU was added or removed</desc>
12752 </param>
12753 </method>
12754
12755 <method name="onCPUExecutionCapChange">
12756 <desc>
12757 Notification when the CPU execution cap changes.
12758 </desc>
12759 <param name="executionCap" type="unsigned long" dir="in">
12760 <desc>The new CPU execution cap value. (1-100)</desc>
12761 </param>
12762 </method>
12763
12764 <method name="onVRDPServerChange">
12765 <desc>
12766 Triggered when settings of the VRDP server object of the
12767 associated virtual machine have changed.
12768
12769 <result name="VBOX_E_INVALID_VM_STATE">
12770 Session state prevents operation.
12771 </result>
12772 <result name="VBOX_E_INVALID_OBJECT_STATE">
12773 Session type prevents operation.
12774 </result>
12775
12776 </desc>
12777 <param name="restart" type="boolean" dir="in">
12778 <desc>Flag whether the server must be restarted</desc>
12779 </param>
12780 </method>
12781
12782 <method name="onUSBControllerChange">
12783 <desc>
12784 Triggered when settings of the USB controller object of the
12785 associated virtual machine have changed.
12786
12787 <result name="VBOX_E_INVALID_VM_STATE">
12788 Session state prevents operation.
12789 </result>
12790 <result name="VBOX_E_INVALID_OBJECT_STATE">
12791 Session type prevents operation.
12792 </result>
12793
12794 </desc>
12795 </method>
12796
12797 <method name="onSharedFolderChange">
12798 <desc>
12799 Triggered when a permanent (global or machine) shared folder has been
12800 created or removed.
12801 <note>
12802 We don't pass shared folder parameters in this notification because
12803 the order in which parallel notifications are delivered is not defined,
12804 therefore it could happen that these parameters were outdated by the
12805 time of processing this notification.
12806 </note>
12807
12808 <result name="VBOX_E_INVALID_VM_STATE">
12809 Session state prevents operation.
12810 </result>
12811 <result name="VBOX_E_INVALID_OBJECT_STATE">
12812 Session type prevents operation.
12813 </result>
12814
12815 </desc>
12816 <param name="global" type="boolean" dir="in"/>
12817 </method>
12818
12819 <method name="onUSBDeviceAttach">
12820 <desc>
12821 Triggered when a request to capture a USB device (as a result
12822 of matched USB filters or direct call to
12823 <link to="IConsole::attachUSBDevice"/>) has completed.
12824 A @c null @a error object means success, otherwise it
12825 describes a failure.
12826
12827 <result name="VBOX_E_INVALID_VM_STATE">
12828 Session state prevents operation.
12829 </result>
12830 <result name="VBOX_E_INVALID_OBJECT_STATE">
12831 Session type prevents operation.
12832 </result>
12833
12834 </desc>
12835 <param name="device" type="IUSBDevice" dir="in"/>
12836 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12837 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
12838 </method>
12839
12840 <method name="onUSBDeviceDetach">
12841 <desc>
12842 Triggered when a request to release the USB device (as a result
12843 of machine termination or direct call to
12844 <link to="IConsole::detachUSBDevice"/>) has completed.
12845 A @c null @a error object means success, otherwise it
12846 describes a failure.
12847
12848 <result name="VBOX_E_INVALID_VM_STATE">
12849 Session state prevents operation.
12850 </result>
12851 <result name="VBOX_E_INVALID_OBJECT_STATE">
12852 Session type prevents operation.
12853 </result>
12854
12855 </desc>
12856 <param name="id" type="uuid" mod="string" dir="in"/>
12857 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12858 </method>
12859
12860 <method name="onShowWindow">
12861 <desc>
12862 Called by <link to="IMachine::canShowConsoleWindow"/> and by
12863 <link to="IMachine::showConsoleWindow"/> in order to notify
12864 console listeners
12865 <link to="ICanShowWindowEvent"/>
12866 and <link to="IShowWindowEvent"/>.
12867
12868 <result name="VBOX_E_INVALID_OBJECT_STATE">
12869 Session type prevents operation.
12870 </result>
12871
12872 </desc>
12873 <param name="check" type="boolean" dir="in"/>
12874 <param name="canShow" type="boolean" dir="out"/>
12875 <param name="winId" type="long long" dir="out"/>
12876 </method>
12877
12878 <method name="accessGuestProperty">
12879 <desc>
12880 Called by <link to="IMachine::getGuestProperty"/> and by
12881 <link to="IMachine::setGuestProperty"/> in order to read and
12882 modify guest properties.
12883
12884 <result name="VBOX_E_INVALID_VM_STATE">
12885 Machine session is not open.
12886 </result>
12887 <result name="VBOX_E_INVALID_OBJECT_STATE">
12888 Session type is not direct.
12889 </result>
12890
12891 </desc>
12892 <param name="name" type="wstring" dir="in"/>
12893 <param name="value" type="wstring" dir="in"/>
12894 <param name="flags" type="wstring" dir="in"/>
12895 <param name="isSetter" type="boolean" dir="in"/>
12896 <param name="retValue" type="wstring" dir="out"/>
12897 <param name="retTimestamp" type="long long" dir="out"/>
12898 <param name="retFlags" type="wstring" dir="out"/>
12899 </method>
12900
12901 <method name="enumerateGuestProperties">
12902 <desc>
12903 Return a list of the guest properties matching a set of patterns along
12904 with their values, time stamps and flags.
12905
12906 <result name="VBOX_E_INVALID_VM_STATE">
12907 Machine session is not open.
12908 </result>
12909 <result name="VBOX_E_INVALID_OBJECT_STATE">
12910 Session type is not direct.
12911 </result>
12912
12913 </desc>
12914 <param name="patterns" type="wstring" dir="in">
12915 <desc>
12916 The patterns to match the properties against as a comma-separated
12917 string. If this is empty, all properties currently set will be
12918 returned.
12919 </desc>
12920 </param>
12921 <param name="key" type="wstring" dir="out" safearray="yes">
12922 <desc>
12923 The key names of the properties returned.
12924 </desc>
12925 </param>
12926 <param name="value" type="wstring" dir="out" safearray="yes">
12927 <desc>
12928 The values of the properties returned. The array entries match the
12929 corresponding entries in the @a key array.
12930 </desc>
12931 </param>
12932 <param name="timestamp" type="long long" dir="out" safearray="yes">
12933 <desc>
12934 The time stamps of the properties returned. The array entries match
12935 the corresponding entries in the @a key array.
12936 </desc>
12937 </param>
12938 <param name="flags" type="wstring" dir="out" safearray="yes">
12939 <desc>
12940 The flags of the properties returned. The array entries match the
12941 corresponding entries in the @a key array.
12942 </desc>
12943 </param>
12944 </method>
12945
12946 <method name="onlineMergeMedium">
12947 <desc>
12948 Triggers online merging of a hard disk. Used internally when deleting
12949 a snapshot while a VM referring to the same hard disk chain is running.
12950
12951 <result name="VBOX_E_INVALID_VM_STATE">
12952 Machine session is not open.
12953 </result>
12954 <result name="VBOX_E_INVALID_OBJECT_STATE">
12955 Session type is not direct.
12956 </result>
12957
12958 </desc>
12959 <param name="mediumAttachment" type="IMediumAttachment" dir="in">
12960 <desc>The medium attachment to identify the medium chain.</desc>
12961 </param>
12962 <param name="sourceIdx" type="unsigned long" dir="in">
12963 <desc>The index of the source image in the chain.
12964 Redundant, but drastically reduces IPC.</desc>
12965 </param>
12966 <param name="targetIdx" type="unsigned long" dir="in">
12967 <desc>The index of the target image in the chain.
12968 Redundant, but drastically reduces IPC.</desc>
12969 </param>
12970 <param name="source" type="IMedium" dir="in">
12971 <desc>Merge source medium.</desc>
12972 </param>
12973 <param name="target" type="IMedium" dir="in">
12974 <desc>Merge target medium.</desc>
12975 </param>
12976 <param name="mergeForward" type="boolean" dir="in">
12977 <desc>Merge direction.</desc>
12978 </param>
12979 <param name="parentForTarget" type="IMedium" dir="in">
12980 <desc>For forward merges: new parent for target medium.</desc>
12981 </param>
12982 <param name="childrenToReparent" type="IMedium" safearray="yes" dir="in">
12983 <desc>For backward merges: list of media which need their parent UUID
12984 updated.</desc>
12985 </param>
12986 <param name="progress" type="IProgress" dir="in">
12987 <desc>
12988 Progress object for this operation.
12989 </desc>
12990 </param>
12991 </method>
12992
12993 </interface>
12994
12995 <interface
12996 name="ISession" extends="$unknown"
12997 uuid="12F4DCDB-12B2-4EC1-B7CD-DDD9F6C5BF4D"
12998 wsmap="managed"
12999 >
13000 <desc>
13001 The ISession interface represents a client process and allows for locking
13002 virtual machines (represented by IMachine objects) to prevent conflicting
13003 changes to the machine.
13004
13005 Any caller wishing to manipulate a virtual machine needs to create a session
13006 object first, which lives in its own process space. Such session objects are
13007 then associated with <link to="IMachine" /> objects living in the VirtualBox
13008 server process to coordinate such changes.
13009
13010 There are two typical scenarios in which sessions are used:
13011
13012 <ul>
13013 <li>To alter machine settings or control a running virtual machine, one
13014 needs to lock a machine for a given session (client process) by calling
13015 <link to="IMachine::lockMachine"/>.
13016
13017 Whereas multiple sessions may control a running virtual machine, only
13018 one process can obtain a write lock on the machine to prevent conflicting
13019 changes. A write lock is also needed if a process wants to actually run a
13020 virtual machine in its own context, such as the VirtualBox GUI or
13021 VBoxHeadless front-ends. They must also lock a machine for their own
13022 sessions before they are allowed to power up the virtual machine.
13023
13024 As a result, no machine settings can be altered while another process is
13025 already using it, either because that process is modifying machine settings
13026 or because the machine is running.
13027 </li>
13028 <li>
13029 To start a VM using one of the existing VirtualBox front-ends (e.g. the
13030 VirtualBox GUI or VBoxHeadless), one would use
13031 <link to="IMachine::launchVMProcess"/>, which also takes a session object
13032 as its first parameter. This session then identifies the caller and lets the
13033 caller control the started machine (for example, pause machine execution or
13034 power it down) as well as be notified about machine execution state changes.
13035 </li>
13036 </ul>
13037
13038 How sessions objects are created in a client process depends on whether you use
13039 the Main API via COM or via the webservice:
13040
13041 <ul>
13042 <li>When using the COM API directly, an object of the Session class from the
13043 VirtualBox type library needs to be created. In regular COM C++ client code,
13044 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
13045 This object will then act as a local session object in further calls to open
13046 a session.
13047 </li>
13048
13049 <li>In the webservice, the session manager (IWebsessionManager) instead creates
13050 a session object automatically whenever <link to="IWebsessionManager::logon" />
13051 is called. A managed object reference to that session object can be retrieved by
13052 calling <link to="IWebsessionManager::getSessionObject" />.
13053 </li>
13054 </ul>
13055 </desc>
13056
13057 <attribute name="state" type="SessionState" readonly="yes">
13058 <desc>Current state of this session.</desc>
13059 </attribute>
13060
13061 <attribute name="type" type="SessionType" readonly="yes">
13062 <desc>
13063 Type of this session. The value of this attribute is valid only
13064 if the session currently has a machine locked (i.e. its
13065 <link to="#state" /> is Locked), otherwise an error will be returned.
13066 </desc>
13067 </attribute>
13068
13069 <attribute name="machine" type="IMachine" readonly="yes">
13070 <desc>Machine object associated with this session.</desc>
13071 </attribute>
13072
13073 <attribute name="console" type="IConsole" readonly="yes">
13074 <desc>Console object associated with this session.</desc>
13075 </attribute>
13076
13077 <method name="unlockMachine">
13078 <desc>
13079 Unlocks a machine that was previously locked for the current session.
13080
13081 Calling this method is required every time a machine has been locked
13082 for a particular session using the <link to="IMachine::launchVMProcess" />
13083 or <link to="IMachine::lockMachine" /> calls. Otherwise the state of
13084 the machine will be set to <link to="MachineState_Aborted" /> on the
13085 server, and changes made to the machine settings will be lost.
13086
13087 Generally, it is recommended to unlock all machines explicitly
13088 before terminating the application (regardless of the reason for
13089 the termination).
13090
13091 <note>
13092 Do not expect the session state (<link to="ISession::state" />
13093 to return to "Unlocked" immediately after you invoke this method,
13094 particularly if you have started a new VM process. The session
13095 state will automatically return to "Unlocked" once the VM is no
13096 longer executing, which can of course take a very long time.
13097 </note>
13098
13099 <result name="E_UNEXPECTED">
13100 Session is not locked.
13101 </result>
13102
13103 </desc>
13104 </method>
13105
13106 </interface>
13107
13108 <!--
13109 // IStorageController
13110 /////////////////////////////////////////////////////////////////////////
13111 -->
13112
13113 <enum
13114 name="StorageBus"
13115 uuid="eee67ab3-668d-4ef5-91e0-7025fe4a0d7a"
13116 >
13117 <desc>
13118 The bus type of the storage controller (IDE, SATA, SCSI, SAS or Floppy);
13119 see <link to="IStorageController::bus" />.
13120 </desc>
13121 <const name="Null" value="0">
13122 <desc>@c null value. Never used by the API.</desc>
13123 </const>
13124 <const name="IDE" value="1"/>
13125 <const name="SATA" value="2"/>
13126 <const name="SCSI" value="3"/>
13127 <const name="Floppy" value="4"/>
13128 <const name="SAS" value="5"/>
13129 </enum>
13130
13131 <enum
13132 name="StorageControllerType"
13133 uuid="8a412b8a-f43e-4456-bd37-b474f0879a58"
13134 >
13135 <desc>
13136 The exact variant of storage controller hardware presented
13137 to the guest; see <link to="IStorageController::controllerType" />.
13138 </desc>
13139
13140 <const name="Null" value="0">
13141 <desc>@c null value. Never used by the API.</desc>
13142 </const>
13143 <const name="LsiLogic" value="1">
13144 <desc>A SCSI controller of the LsiLogic variant.</desc>
13145 </const>
13146 <const name="BusLogic" value="2">
13147 <desc>A SCSI controller of the BusLogic variant.</desc>
13148 </const>
13149 <const name="IntelAhci" value="3">
13150 <desc>An Intel AHCI SATA controller; this is the only variant for SATA.</desc>
13151 </const>
13152 <const name="PIIX3" value="4">
13153 <desc>An IDE controller of the PIIX3 variant.</desc>
13154 </const>
13155 <const name="PIIX4" value="5">
13156 <desc>An IDE controller of the PIIX4 variant.</desc>
13157 </const>
13158 <const name="ICH6" value="6">
13159 <desc>An IDE controller of the ICH6 variant.</desc>
13160 </const>
13161 <const name="I82078" value="7">
13162 <desc>A floppy disk controller; this is the only variant for floppy drives.</desc>
13163 </const>
13164 <const name="LsiLogicSas" value="8">
13165 <desc>A variant of the LsiLogic controller using SAS.</desc>
13166 </const>
13167 </enum>
13168
13169 <enum
13170 name="ChipsetType"
13171 uuid="8b4096a8-a7c3-4d3b-bbb1-05a0a51ec394"
13172 >
13173 <desc>
13174 Type of emulated chipset (mostly southbridge).
13175 </desc>
13176
13177 <const name="Null" value="0">
13178 <desc>@c null value. Never used by the API.</desc>
13179 </const>
13180 <const name="PIIX3" value="1">
13181 <desc>A PIIX3 (PCI IDE ISA Xcelerator) chipset.</desc>
13182 </const>
13183 <const name="ICH9" value="2">
13184 <desc>A ICH9 (I/O Controller Hub) chipset.</desc>
13185 </const>
13186 </enum>
13187
13188 <interface
13189 name="IStorageController" extends="$unknown"
13190 uuid="fd93adc0-bbaa-4256-9e6e-00e29f9151c9"
13191 wsmap="managed"
13192 >
13193 <desc>
13194 Represents a storage controller that is attached to a virtual machine
13195 (<link to="IMachine" />). Just as drives (hard disks, DVDs, FDs) are
13196 attached to storage controllers in a real computer, virtual drives
13197 (represented by <link to="IMediumAttachment" />) are attached to virtual
13198 storage controllers, represented by this interface.
13199
13200 As opposed to physical hardware, VirtualBox has a very generic concept
13201 of a storage controller, and for purposes of the Main API, all virtual
13202 storage is attached to virtual machines via instances of this interface.
13203 There are five types of such virtual storage controllers: IDE, SCSI, SATA,
13204 SAS and Floppy (see <link to="#bus" />). Depending on which of these four
13205 is used, certain sub-types may be available and can be selected in
13206 <link to="#controllerType" />.
13207
13208 Depending on these settings, the guest operating system might see
13209 significantly different virtual hardware.
13210 </desc>
13211
13212 <attribute name="name" type="wstring" readonly="yes">
13213 <desc>
13214 Name of the storage controller, as originally specified with
13215 <link to="IMachine::addStorageController" />. This then uniquely
13216 identifies this controller with other method calls such as
13217 <link to="IMachine::attachDevice" /> and <link to="IMachine::mountMedium" />.
13218 </desc>
13219 </attribute>
13220
13221 <attribute name="maxDevicesPerPortCount" type="unsigned long" readonly="yes">
13222 <desc>
13223 Maximum number of devices which can be attached to one port.
13224 </desc>
13225 </attribute>
13226
13227 <attribute name="minPortCount" type="unsigned long" readonly="yes">
13228 <desc>
13229 Minimum number of ports that <link to="IStorageController::portCount"/> can be set to.
13230 </desc>
13231 </attribute>
13232
13233 <attribute name="maxPortCount" type="unsigned long" readonly="yes">
13234 <desc>
13235 Maximum number of ports that <link to="IStorageController::portCount"/> can be set to.
13236 </desc>
13237 </attribute>
13238
13239 <attribute name="instance" type="unsigned long">
13240 <desc>
13241 The instance number of the device in the running VM.
13242 </desc>
13243 </attribute>
13244
13245 <attribute name="portCount" type="unsigned long">
13246 <desc>
13247 The number of currently usable ports on the controller.
13248 The minimum and maximum number of ports for one controller are
13249 stored in <link to="IStorageController::minPortCount"/>
13250 and <link to="IStorageController::maxPortCount"/>.
13251 </desc>
13252 </attribute>
13253
13254 <attribute name="bus" type="StorageBus" readonly="yes">
13255 <desc>
13256 The bus type of the storage controller (IDE, SATA, SCSI, SAS or Floppy).
13257 </desc>
13258 </attribute>
13259
13260 <attribute name="controllerType" type="StorageControllerType">
13261 <desc>
13262 The exact variant of storage controller hardware presented
13263 to the guest.
13264 Depending on this value, VirtualBox will provide a different
13265 virtual storage controller hardware to the guest.
13266 For SATA, SAS and floppy controllers, only one variant is
13267 available, but for IDE and SCSI, there are several.
13268
13269 For SCSI controllers, the default type is LsiLogic.
13270 </desc>
13271 </attribute>
13272
13273 <attribute name="useHostIOCache" type="boolean">
13274 <desc>
13275 If true, the storage controller emulation will use a dedicated I/O thread, enable the host I/O
13276 caches and use synchronous file APIs on the host. This was the only option in the API before
13277 VirtualBox 3.2 and is still the default for IDE controllers.
13278
13279 If false, the host I/O cache will be disabled for image files attached to this storage controller.
13280 Instead, the storage controller emulation will use asynchronous I/O APIs on the host. This makes
13281 it possible to turn off the host I/O caches because the emulation can handle unaligned access to
13282 the file. This should be used on OS X and Linux hosts if a high I/O load is expected or many
13283 virtual machines are running at the same time to prevent I/O cache related hangs.
13284 This option new with the API of VirtualBox 3.2 and is now the default for non-IDE storage controllers.
13285 </desc>
13286 </attribute>
13287
13288 <method name="getIDEEmulationPort">
13289 <desc>
13290 Gets the corresponding port number which is emulated as an IDE device.
13291 Works only with SATA controllers.
13292
13293 <result name="E_INVALIDARG">
13294 The @a devicePosition is not in the range 0 to 3.
13295 </result>
13296 <result name="E_NOTIMPL">
13297 The storage controller type is not SATAIntelAhci.
13298 </result>
13299
13300 </desc>
13301 <param name="devicePosition" type="long" dir="in"/>
13302 <param name="portNumber" type="long" dir="return"/>
13303 </method>
13304
13305 <method name="setIDEEmulationPort">
13306 <desc>
13307 Sets the port number which is emulated as an IDE device.
13308 Works only with SATA controllers.
13309
13310 <result name="E_INVALIDARG">
13311 The @a devicePosition is not in the range 0 to 3 or the
13312 @a portNumber is not in the range 0 to 29.
13313 </result>
13314 <result name="E_NOTIMPL">
13315 The storage controller type is not SATAIntelAhci.
13316 </result>
13317
13318 </desc>
13319 <param name="devicePosition" type="long" dir="in"/>
13320 <param name="portNumber" type="long" dir="in"/>
13321 </method>
13322
13323 </interface>
13324
13325<if target="wsdl">
13326
13327 <!--
13328 // IManagedObjectRef
13329 /////////////////////////////////////////////////////////////////////////
13330 -->
13331
13332 <interface
13333 name="IManagedObjectRef" extends="$unknown"
13334 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
13335 internal="yes"
13336 wsmap="managed"
13337 wscpp="hardcoded"
13338 >
13339 <desc>
13340 Managed object reference.
13341
13342 Only within the webservice, a managed object reference (which is really
13343 an opaque number) allows a webservice client to address an object
13344 that lives in the address space of the webservice server.
13345
13346 Behind each managed object reference, there is a COM object that lives
13347 in the webservice server's address space. The COM object is not freed
13348 until the managed object reference is released, either by an explicit
13349 call to <link to="IManagedObjectRef::release" /> or by logging off from
13350 the webservice (<link to="IWebsessionManager::logoff" />), which releases
13351 all objects created during the webservice session.
13352
13353 Whenever a method call of the VirtualBox API returns a COM object, the
13354 webservice representation of that method will instead return a
13355 managed object reference, which can then be used to invoke methods
13356 on that object.
13357 </desc>
13358
13359 <method name="getInterfaceName">
13360 <desc>
13361 Returns the name of the interface that this managed object represents,
13362 for example, "IMachine", as a string.
13363 </desc>
13364 <param name="return" type="wstring" dir="return"/>
13365 </method>
13366
13367 <method name="release">
13368 <desc>
13369 Releases this managed object reference and frees the resources that
13370 were allocated for it in the webservice server process. After calling
13371 this method, the identifier of the reference can no longer be used.
13372 </desc>
13373 </method>
13374
13375 </interface>
13376
13377 <!--
13378 // IWebsessionManager
13379 /////////////////////////////////////////////////////////////////////////
13380 -->
13381
13382 <interface
13383 name="IWebsessionManager" extends="$unknown"
13384 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
13385 internal="yes"
13386 wsmap="global"
13387 wscpp="hardcoded"
13388 >
13389 <desc>
13390 Websession manager. This provides essential services
13391 to webservice clients.
13392 </desc>
13393 <method name="logon">
13394 <desc>
13395 Logs a new client onto the webservice and returns a managed object reference to
13396 the IVirtualBox instance, which the client can then use as a basis to further
13397 queries, since all calls to the VirtualBox API are based on the IVirtualBox
13398 interface, in one way or the other.
13399 </desc>
13400 <param name="username" type="wstring" dir="in"/>
13401 <param name="password" type="wstring" dir="in"/>
13402 <param name="return" type="IVirtualBox" dir="return"/>
13403 </method>
13404
13405 <method name="getSessionObject">
13406 <desc>
13407 Returns a managed object reference to the internal ISession object that was created
13408 for this web service session when the client logged on.
13409
13410 <see>ISession</see>
13411 </desc>
13412 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13413 <param name="return" type="ISession" dir="return"/>
13414 </method>
13415
13416 <method name="logoff">
13417 <desc>
13418 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
13419 and destroys all resources associated with the session (most importantly, all
13420 managed objects created in the server while the session was active).
13421 </desc>
13422 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13423 </method>
13424
13425 </interface>
13426
13427</if>
13428
13429 <!--
13430 // IPerformanceCollector & friends
13431 /////////////////////////////////////////////////////////////////////////
13432 -->
13433
13434 <interface
13435 name="IPerformanceMetric" extends="$unknown"
13436 uuid="2a1a60ae-9345-4019-ad53-d34ba41cbfe9" wsmap="managed"
13437 >
13438 <desc>
13439 The IPerformanceMetric interface represents parameters of the given
13440 performance metric.
13441 </desc>
13442
13443 <attribute name="metricName" type="wstring" readonly="yes">
13444 <desc>
13445 Name of the metric.
13446 </desc>
13447 </attribute>
13448
13449 <attribute name="object" type="$unknown" readonly="yes">
13450 <desc>
13451 Object this metric belongs to.
13452 </desc>
13453 </attribute>
13454
13455 <attribute name="description" type="wstring" readonly="yes">
13456 <desc>
13457 Textual description of the metric.
13458 </desc>
13459 </attribute>
13460
13461 <attribute name="period" type="unsigned long" readonly="yes">
13462 <desc>
13463 Time interval between samples, measured in seconds.
13464 </desc>
13465 </attribute>
13466
13467 <attribute name="count" type="unsigned long" readonly="yes">
13468 <desc>
13469 Number of recent samples retained by the performance collector for this
13470 metric.
13471
13472 When the collected sample count exceeds this number, older samples
13473 are discarded.
13474 </desc>
13475 </attribute>
13476
13477 <attribute name="unit" type="wstring" readonly="yes">
13478 <desc>
13479 Unit of measurement.
13480 </desc>
13481 </attribute>
13482
13483 <attribute name="minimumValue" type="long" readonly="yes">
13484 <desc>
13485 Minimum possible value of this metric.
13486 </desc>
13487 </attribute>
13488
13489 <attribute name="maximumValue" type="long" readonly="yes">
13490 <desc>
13491 Maximum possible value of this metric.
13492 </desc>
13493 </attribute>
13494 </interface>
13495
13496 <interface
13497 name="IPerformanceCollector" extends="$unknown"
13498 uuid="e22e1acb-ac4a-43bb-a31c-17321659b0c6"
13499 wsmap="managed"
13500 >
13501 <desc>
13502 The IPerformanceCollector interface represents a service that collects
13503 and stores performance metrics data.
13504
13505 Performance metrics are associated with objects of interfaces like IHost
13506 and IMachine. Each object has a distinct set of performance metrics. The
13507 set can be obtained with <link to="IPerformanceCollector::getMetrics"/>.
13508
13509 Metric data is collected at the specified intervals and is retained
13510 internally. The interval and the number of retained samples can be set
13511 with <link to="IPerformanceCollector::setupMetrics" />. Both metric data
13512 and collection settings are not persistent, they are discarded as soon as
13513 VBoxSVC process terminates. Moreover, metric settings and data associated
13514 with a particular VM only exist while VM is running. They disappear as
13515 soon as VM shuts down. It is not possible to set up metrics for machines
13516 that are powered off. One needs to start VM first, then set up metric
13517 collection parameters.
13518
13519 Metrics are organized hierarchically, with each level separated by a
13520 slash (/) character. Generally, the scheme for metric names is like this:
13521
13522 <tt>Category/Metric[/SubMetric][:aggregation]</tt>
13523
13524 "Category/Metric" together form the base metric name. A base metric is
13525 the smallest unit for which a sampling interval and the number of
13526 retained samples can be set. Only base metrics can be enabled and
13527 disabled. All sub-metrics are collected when their base metric is
13528 collected. Collected values for any set of sub-metrics can be queried
13529 with <link to="IPerformanceCollector::queryMetricsData" />.
13530
13531 For example "CPU/Load/User:avg" metric name stands for the "CPU"
13532 category, "Load" metric, "User" submetric, "average" aggregate. An
13533 aggregate function is computed over all retained data. Valid aggregate
13534 functions are:
13535
13536 <ul>
13537 <li>avg -- average</li>
13538 <li>min -- minimum</li>
13539 <li>max -- maximum</li>
13540 </ul>
13541
13542 When setting up metric parameters, querying metric data, enabling or
13543 disabling metrics wildcards can be used in metric names to specify a
13544 subset of metrics. For example, to select all CPU-related metrics
13545 use <tt>CPU/*</tt>, all averages can be queried using <tt>*:avg</tt> and
13546 so on. To query metric values without aggregates <tt>*:</tt> can be used.
13547
13548 The valid names for base metrics are:
13549
13550 <ul>
13551 <li>CPU/Load</li>
13552 <li>CPU/MHz</li>
13553 <li>RAM/Usage</li>
13554 </ul>
13555
13556 The general sequence for collecting and retrieving the metrics is:
13557 <ul>
13558 <li>
13559 Obtain an instance of IPerformanceCollector with
13560 <link to="IVirtualBox::performanceCollector" />
13561 </li>
13562 <li>
13563 Allocate and populate an array with references to objects the metrics
13564 will be collected for. Use references to IHost and IMachine objects.
13565 </li>
13566 <li>
13567 Allocate and populate an array with base metric names the data will
13568 be collected for.
13569 </li>
13570 <li>
13571 Call <link to="IPerformanceCollector::setupMetrics" />. From now on
13572 the metric data will be collected and stored.
13573 </li>
13574 <li>
13575 Wait for the data to get collected.
13576 </li>
13577 <li>
13578 Allocate and populate an array with references to objects the metric
13579 values will be queried for. You can re-use the object array used for
13580 setting base metrics.
13581 </li>
13582 <li>
13583 Allocate and populate an array with metric names the data will be
13584 collected for. Note that metric names differ from base metric names.
13585 </li>
13586 <li>
13587 Call <link to="IPerformanceCollector::queryMetricsData" />. The data
13588 that have been collected so far are returned. Note that the values
13589 are still retained internally and data collection continues.
13590 </li>
13591 </ul>
13592
13593 For an example of usage refer to the following files in VirtualBox SDK:
13594 <ul>
13595 <li>
13596 Java: <tt>bindings/webservice/java/jax-ws/samples/metrictest.java</tt>
13597 </li>
13598 <li>
13599 Python: <tt>bindings/xpcom/python/sample/shellcommon.py</tt>
13600 </li>
13601 </ul>
13602 </desc>
13603
13604 <attribute name="metricNames" type="wstring" readonly="yes" safearray="yes">
13605 <desc>
13606 Array of unique names of metrics.
13607
13608 This array represents all metrics supported by the performance
13609 collector. Individual objects do not necessarily support all of them.
13610 <link to="IPerformanceCollector::getMetrics"/> can be used to get the
13611 list of supported metrics for a particular object.
13612 </desc>
13613 </attribute>
13614
13615 <method name="getMetrics">
13616 <desc>
13617 Returns parameters of specified metrics for a set of objects.
13618 <note>
13619 @c Null metrics array means all metrics. @c Null object array means
13620 all existing objects.
13621 </note>
13622 </desc>
13623 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13624 <desc>
13625 Metric name filter. Currently, only a comma-separated list of metrics
13626 is supported.
13627 </desc>
13628 </param>
13629 <param name="objects" type="$unknown" dir="in" safearray="yes">
13630 <desc>
13631 Set of objects to return metric parameters for.
13632 </desc>
13633 </param>
13634 <param name="metrics" type="IPerformanceMetric" dir="return" safearray="yes">
13635 <desc>
13636 Array of returned metric parameters.
13637 </desc>
13638 </param>
13639 </method>
13640
13641 <method name="setupMetrics">
13642 <desc>
13643 Sets parameters of specified base metrics for a set of objects. Returns
13644 an array of <link to="IPerformanceMetric" /> describing the metrics
13645 have been affected.
13646 <note>
13647 @c Null or empty metric name array means all metrics. @c Null or
13648 empty object array means all existing objects. If metric name array
13649 contains a single element and object array contains many, the single
13650 metric name array element is applied to each object array element to
13651 form metric/object pairs.
13652 </note>
13653 </desc>
13654 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13655 <desc>
13656 Metric name filter. Comma-separated list of metrics with wildcard
13657 support.
13658 </desc>
13659 </param>
13660 <param name="objects" type="$unknown" dir="in" safearray="yes">
13661 <desc>
13662 Set of objects to setup metric parameters for.
13663 </desc>
13664 </param>
13665 <param name="period" type="unsigned long" dir="in">
13666 <desc>
13667 Time interval in seconds between two consecutive samples of
13668 performance data.
13669 </desc>
13670 </param>
13671 <param name="count" type="unsigned long" dir="in">
13672 <desc>
13673 Number of samples to retain in performance data history. Older
13674 samples get discarded.
13675 </desc>
13676 </param>
13677 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13678 <desc>
13679 Array of metrics that have been modified by the call to this method.
13680 </desc>
13681 </param>
13682 </method>
13683
13684 <method name="enableMetrics">
13685 <desc>
13686 Turns on collecting specified base metrics. Returns an array of
13687 <link to="IPerformanceMetric" /> describing the metrics have been
13688 affected.
13689 <note>
13690 @c Null or empty metric name array means all metrics. @c Null or
13691 empty object array means all existing objects. If metric name array
13692 contains a single element and object array contains many, the single
13693 metric name array element is applied to each object array element to
13694 form metric/object pairs.
13695 </note>
13696 </desc>
13697 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13698 <desc>
13699 Metric name filter. Comma-separated list of metrics with wildcard
13700 support.
13701 </desc>
13702 </param>
13703 <param name="objects" type="$unknown" dir="in" safearray="yes">
13704 <desc>
13705 Set of objects to enable metrics for.
13706 </desc>
13707 </param>
13708 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13709 <desc>
13710 Array of metrics that have been modified by the call to this method.
13711 </desc>
13712 </param>
13713 </method>
13714
13715 <method name="disableMetrics">
13716 <desc>
13717 Turns off collecting specified base metrics. Returns an array of
13718 <link to="IPerformanceMetric" /> describing the metrics have been
13719 affected.
13720 <note>
13721 @c Null or empty metric name array means all metrics. @c Null or
13722 empty object array means all existing objects. If metric name array
13723 contains a single element and object array contains many, the single
13724 metric name array element is applied to each object array element to
13725 form metric/object pairs.
13726 </note>
13727 </desc>
13728 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13729 <desc>
13730 Metric name filter. Comma-separated list of metrics with wildcard
13731 support.
13732 </desc>
13733 </param>
13734 <param name="objects" type="$unknown" dir="in" safearray="yes">
13735 <desc>
13736 Set of objects to disable metrics for.
13737 </desc>
13738 </param>
13739 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13740 <desc>
13741 Array of metrics that have been modified by the call to this method.
13742 </desc>
13743 </param>
13744 </method>
13745
13746 <method name="queryMetricsData">
13747 <desc>
13748 Queries collected metrics data for a set of objects.
13749
13750 The data itself and related metric information are returned in seven
13751 parallel and one flattened array of arrays. Elements of
13752 <tt>returnMetricNames, returnObjects, returnUnits, returnScales,
13753 returnSequenceNumbers, returnDataIndices and returnDataLengths</tt> with
13754 the same index describe one set of values corresponding to a single
13755 metric.
13756
13757 The <tt>returnData</tt> parameter is a flattened array of arrays. Each
13758 start and length of a sub-array is indicated by
13759 <tt>returnDataIndices</tt> and <tt>returnDataLengths</tt>. The first
13760 value for metric <tt>metricNames[i]</tt> is at
13761 <tt>returnData[returnIndices[i]]</tt>.
13762
13763 <note>
13764 @c Null or empty metric name array means all metrics. @c Null or
13765 empty object array means all existing objects. If metric name array
13766 contains a single element and object array contains many, the single
13767 metric name array element is applied to each object array element to
13768 form metric/object pairs.
13769 </note>
13770 <note>
13771 Data collection continues behind the scenes after call to @c
13772 queryMetricsData. The return data can be seen as the snapshot of the
13773 current state at the time of @c queryMetricsData call. The internally
13774 kept metric values are not cleared by the call. This makes possible
13775 querying different subsets of metrics or aggregates with subsequent
13776 calls. If periodic querying is needed it is highly suggested to query
13777 the values with @c interval*count period to avoid confusion. This way
13778 a completely new set of data values will be provided by each query.
13779 </note>
13780 </desc>
13781 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13782 <desc>
13783 Metric name filter. Comma-separated list of metrics with wildcard
13784 support.
13785 </desc>
13786 </param>
13787 <param name="objects" type="$unknown" dir="in" safearray="yes">
13788 <desc>
13789 Set of objects to query metrics for.
13790 </desc>
13791 </param>
13792 <param name="returnMetricNames" type="wstring" dir="out" safearray="yes">
13793 <desc>
13794 Names of metrics returned in @c returnData.
13795 </desc>
13796 </param>
13797 <param name="returnObjects" type="$unknown" dir="out" safearray="yes">
13798 <desc>
13799 Objects associated with metrics returned in @c returnData.
13800 </desc>
13801 </param>
13802 <param name="returnUnits" type="wstring" dir="out" safearray="yes">
13803 <desc>
13804 Units of measurement for each returned metric.
13805 </desc>
13806 </param>
13807 <param name="returnScales" type="unsigned long" dir="out" safearray="yes">
13808 <desc>
13809 Divisor that should be applied to return values in order to get
13810 floating point values. For example:
13811 <tt>(double)returnData[returnDataIndices[0]+i] / returnScales[0]</tt>
13812 will retrieve the floating point value of i-th sample of the first
13813 metric.
13814 </desc>
13815 </param>
13816 <param name="returnSequenceNumbers" type="unsigned long" dir="out" safearray="yes">
13817 <desc>
13818 Sequence numbers of the first elements of value sequences of
13819 particular metrics returned in @c returnData. For aggregate metrics
13820 it is the sequence number of the sample the aggregate started
13821 calculation from.
13822 </desc>
13823 </param>
13824 <param name="returnDataIndices" type="unsigned long" dir="out" safearray="yes">
13825 <desc>
13826 Indices of the first elements of value sequences of particular
13827 metrics returned in @c returnData.
13828 </desc>
13829 </param>
13830 <param name="returnDataLengths" type="unsigned long" dir="out" safearray="yes">
13831 <desc>
13832 Lengths of value sequences of particular metrics.
13833 </desc>
13834 </param>
13835 <param name="returnData" type="long" dir="return" safearray="yes">
13836 <desc>
13837 Flattened array of all metric data containing sequences of values for
13838 each metric.
13839 </desc>
13840 </param>
13841 </method>
13842
13843 </interface>
13844 <enum
13845 name="NATAliasMode"
13846 uuid="67772168-50d9-11df-9669-7fb714ee4fa1">
13847 <desc></desc>
13848 <const name="AliasLog" value="0x1">
13849 <desc></desc>
13850 </const>
13851 <const name="AliasProxyOnly" value="0x02">
13852 <desc></desc>
13853 </const>
13854 <const name="AliasUseSamePorts" value="0x04">
13855 <desc></desc>
13856 </const>
13857 </enum>
13858 <enum
13859 name="NATProtocol"
13860 uuid="e90164be-eb03-11de-94af-fff9b1c1b19f"
13861 >
13862 <desc>Protocol definitions used with NAT port-forwarding rules.</desc>
13863 <const name="UDP" value="0">
13864 <desc>Port-forwarding uses UDP protocol.</desc>
13865 </const>
13866 <const name="TCP" value="1">
13867 <desc>Port-forwarding uses TCP protocol.</desc>
13868 </const>
13869 </enum>
13870
13871 <interface
13872 name="INATEngine" extends="$unknown"
13873 uuid="4b286616-eb03-11de-b0fb-1701eca42246"
13874 wsmap="managed"
13875 >
13876 <desc>Interface for managing a NAT engine which is used with a virtual machine. This
13877 allows for changing NAT behavior such as port-forwarding rules. This interface is
13878 used in the <link to="INetworkAdapter::natDriver" /> attribute.</desc>
13879 <attribute name="network" type="wstring">
13880 <desc>The network attribute of the NAT engine (the same value is used with built-in
13881 DHCP server to fill corresponding fields of DHCP leases).</desc>
13882 </attribute>
13883 <attribute name="hostIP" type="wstring">
13884 <desc>IP of host interface to bind all opened sockets to.
13885 <note>Changing this does not change binding of port forwarding.</note>
13886 </desc>
13887 </attribute>
13888 <attribute name="tftpPrefix" type="wstring">
13889 <desc>TFTP prefix attribute which is used with the built-in DHCP server to fill
13890 the corresponding fields of DHCP leases.</desc>
13891 </attribute>
13892 <attribute name="tftpBootFile" type="wstring">
13893 <desc>TFTP boot file attribute which is used with the built-in DHCP server to fill
13894 the corresponding fields of DHCP leases.</desc>
13895 </attribute>
13896 <attribute name="tftpNextServer" type="wstring">
13897 <desc>TFTP server attribute which is used with the built-in DHCP server to fill
13898 the corresponding fields of DHCP leases.
13899 <note>The preferred form is IPv4 addresses.</note>
13900 </desc>
13901 </attribute>
13902 <attribute name="aliasMode" type="unsigned long">
13903 <desc></desc>
13904 </attribute>
13905 <attribute name="dnsPassDomain" type="boolean">
13906 <desc>Whether the DHCP server should pass the DNS domain used by the host.</desc>
13907 </attribute>
13908 <attribute name="dnsProxy" type="boolean">
13909 <desc>Whether the DHCP server (and the DNS traffic by NAT) should pass the address
13910 of the DNS proxy and process traffic using DNS servers registered on the host.</desc>
13911 </attribute>
13912 <attribute name="dnsUseHostResolver" type="boolean">
13913 <desc>Whether the DHCP server (and the DNS traffic by NAT) should pass the address
13914 of the DNS proxy and process traffic using the host resolver mechanism.</desc>
13915 </attribute>
13916 <attribute name="redirects" type="wstring" readonly="yes" safearray="yes">
13917 <desc>Array of NAT port-forwarding rules in string representation, in the following
13918 format: "name,protocol id,host ip,host port,guest ip,guest port".</desc>
13919 </attribute>
13920 <method name="setNetworkSettings">
13921 <desc>Sets network configuration of the NAT engine.</desc>
13922 <param name="mtu" type="unsigned long" dir="in">
13923 <desc>MTU (maximum transmission unit) of the NAT engine in bytes.</desc>
13924 </param>
13925 <param name="sockSnd" type="unsigned long" dir="in">
13926 <desc>Capacity of the socket send buffer in bytes when creating a new socket.</desc>
13927 </param>
13928 <param name="sockRcv" type="unsigned long" dir="in">
13929 <desc>Capacity of the socket receive buffer in bytes when creating a new socket.</desc>
13930 </param>
13931 <param name="TcpWndSnd" type="unsigned long" dir="in">
13932 <desc>Initial size of the NAT engine's sending TCP window in bytes when
13933 establishing a new TCP connection.</desc>
13934 </param>
13935 <param name="TcpWndRcv" type="unsigned long" dir="in">
13936 <desc>Initial size of the NAT engine's receiving TCP window in bytes when
13937 establishing a new TCP connection.</desc>
13938 </param>
13939 </method>
13940 <method name="getNetworkSettings">
13941 <desc>Returns network configuration of NAT engine. See <link to="#setNetworkSettings" />
13942 for parameter descriptions.</desc>
13943 <param name="mtu" type="unsigned long" dir="out" />
13944 <param name="sockSnd" type="unsigned long" dir="out" />
13945 <param name="sockRcv" type="unsigned long" dir="out" />
13946 <param name="TcpWndSnd" type="unsigned long" dir="out" />
13947 <param name="TcpWndRcv" type="unsigned long" dir="out" />
13948 </method>
13949 <method name="addRedirect">
13950 <desc>Adds a new NAT port-forwarding rule.</desc>
13951 <param name="name" type="wstring" dir="in">
13952 <desc>The name of the rule. An empty name is acceptable, in which case the NAT engine
13953 auto-generates one using the other parameters.</desc>
13954 </param>
13955 <param name="proto" type="NATProtocol" dir="in">
13956 <desc>Protocol handled with the rule.</desc>
13957 </param>
13958 <param name="hostIp" type="wstring" dir="in">
13959 <desc>IP of the host interface to which the rule should apply. An empty ip address is
13960 acceptable, in which case the NAT engine binds the handling socket to any interface.</desc>
13961 </param>
13962 <param name="hostPort" type="unsigned short" dir="in">
13963 <desc>The port number to listen on.</desc>
13964 </param>
13965 <param name="guestIp" type="wstring" dir="in">
13966 <desc>The IP address of the guest which the NAT engine will forward matching packets
13967 to. An empty IP address is acceptable, in which case the NAT engine will forward
13968 packets to the first DHCP lease (x.x.x.15).</desc>
13969 </param>
13970 <param name="guestPort" type="unsigned short" dir="in">
13971 <desc>The port number to forward.</desc>
13972 </param>
13973 </method>
13974 <method name="removeRedirect">
13975 <desc>Removes a port-forwarding rule that was previously registered.</desc>
13976 <param name="name" type="wstring" dir="in">
13977 <desc>The name of the rule to delete.</desc>
13978 </param>
13979 </method>
13980 </interface>
13981
13982 <enum
13983 name="VBoxEventType"
13984 uuid="1728bb3b-4843-4f12-af67-f7a1f69f3a52">
13985
13986 <desc>
13987 Type of an event.
13988 See <link to="IEvent" /> for an introduction to VirtualBox event handling.
13989 </desc>
13990
13991 <const name="Invalid" value="0">
13992 <desc>
13993 Invalid event, must be first.
13994 </desc>
13995 </const>
13996
13997 <const name="Any" value="1">
13998 <desc>
13999 Wildcard for all events.
14000 Events of this type are never delivered, and only used in
14001 registerListener() call to simplify registration.
14002 </desc>
14003 </const>
14004
14005 <const name="Vetoable" value="2">
14006 <desc>
14007 Wildcard for all vetoable events. Events of this type are never delivered, and only
14008 used in registerListener() call to simplify registration.
14009 </desc>
14010 </const>
14011
14012 <const name="MachineEvent" value="3">
14013 <desc>
14014 Wildcard for all machine events. Events of this type are never delivered, and only used in
14015 registerListener() call to simplify registration.
14016 </desc>
14017 </const>
14018
14019 <const name="SnapshotEvent" value="4">
14020 <desc>
14021 Wildcard for all snapshot events. Events of this type are never delivered, and only used in
14022 registerListener() call to simplify registration.
14023 </desc>
14024 </const>
14025
14026 <const name="InputEvent" value="5">
14027 <desc>
14028 Wildcard for all input device (keyboard, mouse) events.
14029 Events of this type are never delivered, and only used in
14030 registerListener() call to simplify registration.
14031 </desc>
14032 </const>
14033
14034 <const name="LastWildcard" value="31">
14035 <desc>
14036 Last wildcard.
14037 </desc>
14038 </const>
14039
14040 <const name="OnMachineStateChanged" value="32">
14041 <desc>
14042 See <link to="IMachineStateChangedEvent">IMachineStateChangedEvent</link>.
14043 </desc>
14044 </const>
14045 <const name="OnMachineDataChanged" value="33">
14046 <desc>
14047 See <link to="IMachineDataChangedEvent">IMachineDataChangedEvent</link>.
14048 </desc>
14049 </const>
14050 <const name="OnExtraDataChanged" value="34">
14051 <desc>
14052 See <link to="IExtraDataChangedEvent">IExtraDataChangedEvent</link>.
14053 </desc>
14054 </const>
14055 <const name="OnExtraDataCanChange" value="35">
14056 <desc>
14057 See <link to="IExtraDataCanChangeEvent">IExtraDataCanChangeEvent</link>.
14058 </desc>
14059 </const>
14060 <const name="OnMediumRegistered" value="36">
14061 <desc>
14062 See <link to="IMediumRegisteredEvent">IMediumRegisteredEvent</link>.
14063 </desc>
14064 </const>
14065 <const name="OnMachineRegistered" value="37">
14066 <desc>
14067 See <link to="IMachineRegisteredEvent">IMachineRegisteredEvent</link>.
14068 </desc>
14069 </const>
14070 <const name="OnSessionStateChanged" value="38">
14071 <desc>
14072 See <link to="ISessionStateChangedEvent">ISessionStateChangedEvent</link>.
14073 </desc>
14074 </const>
14075 <const name="OnSnapshotTaken" value="39">
14076 <desc>
14077 See <link to="ISnapshotTakenEvent">ISnapshotTakenEvent</link>.
14078 </desc>
14079 </const>
14080 <const name="OnSnapshotDeleted" value="40">
14081 <desc>
14082 See <link to="ISnapshotDeletedEvent">ISnapshotDeletedEvent</link>.
14083 </desc>
14084 </const>
14085 <const name="OnSnapshotChanged" value="41">
14086 <desc>
14087 See <link to="ISnapshotChangedEvent">ISnapshotChangedEvent</link>.
14088 </desc>
14089 </const>
14090 <const name="OnGuestPropertyChanged" value="42">
14091 <desc>
14092 See <link to="IGuestPropertyChangedEvent">IGuestPropertyChangedEvent</link>.
14093 </desc>
14094 </const>
14095 <!-- Console events -->
14096 <const name="OnMousePointerShapeChanged" value="43">
14097 <desc>
14098 See <link to="IMousePointerShapeChangedEvent">IMousePointerShapeChangedEvent</link>.
14099 </desc>
14100 </const>
14101 <const name="OnMouseCapabilityChanged" value="44">
14102 <desc>
14103 See <link to="IMouseCapabilityChangedEvent">IMouseCapabilityChangedEvent</link>.
14104 </desc>
14105 </const>
14106 <const name="OnKeyboardLedsChanged" value="45">
14107 <desc>
14108 See <link to="IKeyboardLedsChangedEvent">IKeyboardLedsChangedEvent</link>.
14109 </desc>
14110 </const>
14111 <const name="OnStateChanged" value="46">
14112 <desc>
14113 See <link to="IStateChangedEvent">IStateChangedEvent</link>.
14114 </desc>
14115 </const>
14116 <const name="OnAdditionsStateChanged" value="47">
14117 <desc>
14118 See <link to="IAdditionsStateChangedEvent">IAdditionsStateChangedEvent</link>.
14119 </desc>
14120 </const>
14121 <const name="OnNetworkAdapterChanged" value="48">
14122 <desc>
14123 See <link to="INetworkAdapterChangedEvent">INetworkAdapterChangedEvent</link>.
14124 </desc>
14125 </const>
14126 <const name="OnSerialPortChanged" value="49">
14127 <desc>
14128 See <link to="ISerialPortChangedEvent">ISerialPortChangedEvent</link>.
14129 </desc>
14130 </const>
14131 <const name="OnParallelPortChanged" value="50">
14132 <desc>
14133 See <link to="IParallelPortChangedEvent">IParallelPortChangedEvent</link>.
14134 </desc>
14135 </const>
14136 <const name="OnStorageControllerChanged" value="51">
14137 <desc>
14138 See <link to="IStorageControllerChangedEvent">IStorageControllerChangedEvent</link>.
14139 </desc>
14140 </const>
14141 <const name="OnMediumChanged" value="52">
14142 <desc>
14143 See <link to="IMediumChangedEvent">IMediumChangedEvent</link>.
14144 </desc>
14145 </const>
14146 <const name="OnVRDPServerChanged" value="53">
14147 <desc>
14148 See <link to="IVRDPServerChangedEvent">IVRDPServerChangedEvent</link>.
14149 </desc>
14150 </const>
14151 <const name="OnUSBControllerChanged" value="54">
14152 <desc>
14153 See <link to="IUSBControllerChangedEvent">IUSBControllerChangedEvent</link>.
14154 </desc>
14155 </const>
14156 <const name="OnUSBDeviceStateChanged" value="55">
14157 <desc>
14158 See <link to="IUSBDeviceStateChangedEvent">IUSBDeviceStateChangedEvent</link>.
14159 </desc>
14160 </const>
14161 <const name="OnSharedFolderChanged" value="56">
14162 <desc>
14163 See <link to="ISharedFolderChangedEvent">ISharedFolderChangedEvent</link>.
14164 </desc>
14165 </const>
14166 <const name="OnRuntimeError" value="57">
14167 <desc>
14168 See <link to="IRuntimeErrorEvent">IRuntimeErrorEvent</link>.
14169 </desc>
14170 </const>
14171 <const name="OnCanShowWindow" value="58">
14172 <desc>
14173 See <link to="ICanShowWindowEvent">ICanShowWindowEvent</link>.
14174 </desc>
14175 </const>
14176 <const name="OnShowWindow" value="59">
14177 <desc>
14178 See <link to="IShowWindowEvent">IShowWindowEvent</link>.
14179 </desc>
14180 </const>
14181 <const name="OnCPUChanged" value="60">
14182 <desc>
14183 See <link to="ICPUChangedEvent">ICPUChangedEvent</link>.
14184 </desc>
14185 </const>
14186 <const name="OnRemoteDisplayInfoChanged" value="61">
14187 <desc>
14188 See <link to="IRemoteDisplayInfoChangedEvent">IRemoteDisplayInfoChangedEvent</link>.
14189 </desc>
14190 </const>
14191 <const name="OnEventSourceChanged" value="62">
14192 <desc>
14193 See <link to="IEventSourceChangedEvent">IEventSourceChangedEvent</link>.
14194 </desc>
14195 </const>
14196 <const name="OnCPUExecutionCapChanged" value="63">
14197 <desc>
14198 See <link to="ICPUExecutionCapChangedEvent">ICPUExecutionCapChangedEvent</link>.
14199 </desc>
14200 </const>
14201 <const name="OnGuestKeyboardEvent" value="64">
14202 <desc>
14203 See <link to="IGuestKeyboardEvent">IGuestKeyboardEvent</link>.
14204 </desc>
14205 </const>
14206 <const name="OnGuestMouseEvent" value="65">
14207 <desc>
14208 See <link to="IGuestMouseEvent">IGuestMouseEvent</link>.
14209 </desc>
14210 </const>
14211 <!-- Last event marker -->
14212 <const name="Last" value="66">
14213 <desc>
14214 Must be last event, used for iterations and structures relying on numerical event values.
14215 </desc>
14216 </const>
14217
14218 </enum>
14219
14220 <interface
14221 name="IEventSource" extends="$unknown"
14222 uuid="3c670618-f727-4fe9-94d2-8243f489a033"
14223 wsmap="managed"
14224 >
14225 <desc>
14226 Event source. Generally, any object which could generate events can be an event source,
14227 or aggregate one. To simplify using one-way protocols such as webservices running on top of HTTP(S),
14228 an event source can work with listeners in either active or passive mode. In active mode it is up to
14229 the IEventSource implementation to call <link to="IEventListener::handleEvent" />, in passive mode the
14230 event source keeps track of pending events for each listener and returns available events on demand.
14231
14232 See <link to="IEvent" /> for an introduction to VirtualBox event handling.
14233 </desc>
14234
14235 <method name="createListener">
14236 <desc>
14237 Creates a new listener object, useful for passive mode.
14238 </desc>
14239 <param name="listener" type="IEventListener" dir="return"/>
14240 </method>
14241
14242 <method name="registerListener">
14243 <desc>
14244 Register an event listener.
14245
14246 <note>
14247 To avoid system overload, the VirtualBox server process checks if passive event
14248 listeners call <link to="IEventSource::getEvent"/> frequently enough. In the
14249 current implementation, if more than 100 pending events are detected for a passive
14250 event listener, it is forcefully unregistered by the system, and further
14251 <link to="#getEvent" /> calls will return @c VBOX_E_OBJECT_NOT_FOUND.
14252 </note>
14253 </desc>
14254 <param name="listener" type="IEventListener" dir="in">
14255 <desc>Listener to register.</desc>
14256 </param>
14257 <param name="interesting" type="VBoxEventType" dir="in" safearray="yes">
14258 <desc>
14259 Event types listener is interested in. One can use wildcards like -
14260 <link to="VBoxEventType_Any"/> to specify wildcards, matching more
14261 than one event.
14262 </desc>
14263 </param>
14264 <param name="active" type="boolean" dir="in">
14265 <desc>
14266 Which mode this listener is operating in.
14267 In active mode, <link to="IEventListener::handleEvent" /> is called directly.
14268 In passive mode, an internal event queue is created for this this IEventListener.
14269 For each event coming in, it is added to queues for all interested registered passive
14270 listeners. It is then up to the external code to call the listener's
14271 <link to="IEventListener::handleEvent" /> method. When done with an event, the
14272 external code must call <link to="#eventProcessed" />.
14273 </desc>
14274 </param>
14275 </method>
14276
14277 <method name="unregisterListener">
14278 <desc>
14279 Unregister an event listener. If listener is passive, and some waitable events are still
14280 in queue they are marked as processed automatically.
14281 </desc>
14282 <param name="listener" type="IEventListener" dir="in">
14283 <desc>Listener to unregister.</desc>
14284 </param>
14285 </method>
14286
14287 <method name="fireEvent">
14288 <desc>
14289 Fire an event for this source.
14290 </desc>
14291 <param name="event" type="IEvent" dir="in">
14292 <desc>Event to deliver.</desc>
14293 </param>
14294 <param name="timeout" type="long" dir="in">
14295 <desc>
14296 Maximum time to wait for event processing (if event is waitable), in ms;
14297 0 = no wait, -1 = indefinite wait.
14298 </desc>
14299 </param>
14300 <param name="result" type="boolean" dir="return">
14301 <desc>true if an event was delivered to all targets, or is non-waitable.</desc>
14302 </param>
14303 </method>
14304
14305 <method name="getEvent">
14306 <desc>
14307 Get events from this peer's event queue (for passive mode). Calling this method
14308 regularly is required for passive event listeners to avoid system overload;
14309 see <link to="IEventSource::registerListener" /> for details.
14310
14311 <result name="VBOX_E_OBJECT_NOT_FOUND">
14312 Listener is not registered, or autounregistered.
14313 </result>
14314 </desc>
14315 <param name="listener" type="IEventListener" dir="in">
14316 <desc>Which listener to get data for.</desc>
14317 </param>
14318 <param name="timeout" type="long" dir="in">
14319 <desc>
14320 Maximum time to wait for events, in ms;
14321 0 = no wait, -1 = indefinite wait.
14322 </desc>
14323 </param>
14324 <param name="event" type="IEvent" dir="return">
14325 <desc>Event retrieved, or null if none available.</desc>
14326 </param>
14327 </method>
14328
14329 <method name="eventProcessed">
14330 <desc>
14331 Must be called for waitable events after a particular listener finished its
14332 event processing. When all listeners of a particular event have called this
14333 method, the system will then call <link to="IEvent::setProcessed" />.
14334 </desc>
14335 <param name="listener" type="IEventListener" dir="in">
14336 <desc>Which listener processed event.</desc>
14337 </param>
14338 <param name="event" type="IEvent" dir="in">
14339 <desc>Which event.</desc>
14340 </param>
14341 </method>
14342
14343 </interface>
14344
14345 <interface
14346 name="IEventListener" extends="$unknown"
14347 uuid="67099191-32e7-4f6c-85ee-422304c71b90"
14348 wsmap="managed"
14349 >
14350 <desc>
14351 Event listener. An event listener can work in either active or passive mode, depending on the way
14352 it was registered.
14353 See <link to="IEvent" /> for an introduction to VirtualBox event handling.
14354 </desc>
14355
14356 <method name="handleEvent">
14357 <desc>
14358 Handle event callback (called directly by IEventSource in active mode, or could be
14359 called by event processor thread in passive mode).
14360 </desc>
14361 <param name="event" type="IEvent" dir="in">
14362 <desc>Event available.</desc>
14363 </param>
14364 </method>
14365
14366 </interface>
14367
14368 <interface
14369 name="IEvent" extends="$unknown"
14370 uuid="0ca2adba-8f30-401b-a8cd-fe31dbe839c0"
14371 wsmap="managed"
14372 >
14373 <desc>
14374 Abstract parent interface for VirtualBox events. Actual events will typically implement
14375 a more specific interface which derives from this (see below).
14376
14377 <b>Introduction to VirtualBox events</b>
14378
14379 Generally speaking, an event (represented by this interface) signals that something
14380 happened, while an event listener (see <link to="IEventListener" />) represents an
14381 entity that is interested in certain events. In order for this to work with
14382 unidirectional protocols (i.e. web services), the concepts of passive and active
14383 listener are used.
14384
14385 Event consumers can register themselves as listeners, providing an array of
14386 events they are interested in (see <link to="IEventSource::registerListener" />).
14387 When an event triggers, the listener is notified about the event. The exact
14388 mechanism of the notification depends on whether the listener was registered as
14389 an active or passive listener:
14390
14391 <ul>
14392 <li>An active listener is very similar to a callback: it is a function invoked
14393 by the API. As opposed to the callbacks that were used in the API before
14394 VirtualBox 3.3 however, events are now objects with an interface hierarchy.
14395 </li>
14396
14397 <li>Passive listeners are somewhat tricker to implement, but do not require
14398 a client function to be callable, which is not an option with scripting
14399 languages or web service clients. Internally the <link to="IEventSource" />
14400 implementation maintains an event queue for each passive listener, and
14401 newly arrived events are put in this queue. When the listener calls
14402 <link to="IEventSource::getEvent"/>, first element from its internal event
14403 queue is returned. When the client completes processing of an event,
14404 the <link to="IEventSource::eventProcessed" /> function must be called,
14405 acknowledging that the event was processed. It supports implementing
14406 waitable events. On passive listener unregistration, all events from its
14407 queue are auto-acknowledged.
14408 </li>
14409 </ul>
14410
14411 Waitable events are useful in situations where the event generator wants to track
14412 delivery or a party wants to wait until all listeners have completed the event. A
14413 typical example would be a vetoable event (see <link to="IVetoEvent" />) where a
14414 listeners might veto a certain action, and thus the event producer has to make
14415 sure that all listeners have processed the event and not vetoed before taking
14416 the action.
14417
14418 A given event may have both passive and active listeners at the same time.
14419
14420 <b>Using events</b>
14421
14422 Any VirtualBox object capable of producing externally visible events provides an
14423 @c eventSource read-only attribute, which is of the type <link to="IEventSource" />.
14424 This event source object is notified by VirtualBox once something has happened, so
14425 consumers may register event listeners with this event source. To register a listener,
14426 an object implementing the <link to="IEventListener" /> interface must be provided.
14427 For active listeners, such an object is typically created by the consumer, while for
14428 passive listeners <link to="IEventSource::createListener" /> should be used. Please
14429 note that a listener created with @c createListener() must not be used as an active listener.
14430
14431 Once created, the listener must be registered to listen for the desired events
14432 (see <link to="IEventSource::registerListener" />), providing an array of
14433 <link to="VBoxEventType" /> enums. Those elements can either be the individual
14434 event IDs or wildcards matching multiple event IDs.
14435
14436 After registration, the callback's <link to="IEventListener::handleEvent" /> method is
14437 called automatically when the event is triggered, while passive listeners have to call
14438 <link to="IEventSource::getEvent" /> and <link to="IEventSource::eventProcessed" /> in
14439 an event processing loop.
14440
14441 The IEvent interface is an abstract parent interface for all such VirtualBox events
14442 coming in. As a result, the standard use pattern inside <link to="IEventListener::handleEvent" />
14443 or the event processing loop is to check the <link to="#type" /> attribute of the event and
14444 then cast to the appropriate specific interface using @c QueryInterface().
14445 </desc>
14446
14447 <attribute name="type" readonly="yes" type="VBoxEventType">
14448 <desc>
14449 Event type.
14450 </desc>
14451 </attribute>
14452
14453 <attribute name="source" readonly="yes" type="IEventSource">
14454 <desc>
14455 Source of this event.
14456 </desc>
14457 </attribute>
14458
14459 <attribute name="waitable" readonly="yes" type="boolean">
14460 <desc>
14461 If we can wait for this event being processed. If false, waitProcessed() returns immediately,
14462 and setProcessed() doesn't make sense. Non-waitable events are generally better performing,
14463 as no additional overhead associated with waitability imposed.
14464 Waitable events are needed when one need to be able to wait for particular event processed,
14465 for example for vetoable changes, or if event refers to some resource which need to be kept immutable
14466 until all consumers confirmed events.
14467 </desc>
14468 </attribute>
14469
14470 <method name="setProcessed">
14471 <desc>
14472 Internal method called by the system when all listeners of a particular event have called
14473 <link to="IEventSource::eventProcessed" />. This should not be called by client code.
14474 </desc>
14475 </method>
14476
14477 <method name="waitProcessed">
14478 <desc>
14479 Wait until time outs, or this event is processed. Event must be waitable for this operation to have
14480 described semantics, for non-waitable returns true immediately.
14481 </desc>
14482 <param name="timeout" type="long" dir="in">
14483 <desc>
14484 Maximum time to wait for event processeing, in ms;
14485 0 = no wait, -1 = indefinite wait.
14486 </desc>
14487 </param>
14488 <param name="result" type="boolean" dir="return">
14489 <desc>If this event was processed before timeout.</desc>
14490 </param>
14491 </method>
14492 </interface>
14493
14494
14495 <interface
14496 name="IReusableEvent" extends="IEvent"
14497 uuid="69bfb134-80f6-4266-8e20-16371f68fa25"
14498 wsmap="managed"
14499 >
14500 <desc>Base abstract interface for all reusable events.</desc>
14501
14502 <attribute name="generation" readonly="yes" type="unsigned long">
14503 <desc>Current generation of event, incremented on reuse.</desc>
14504 </attribute>
14505
14506 <method name="reuse">
14507 <desc>
14508 Marks an event as reused, increments 'generation', fields shall no
14509 longer be considered valid.
14510 </desc>
14511 </method>
14512 </interface>
14513
14514 <interface
14515 name="IMachineEvent" extends="IEvent"
14516 uuid="92ed7b1a-0d96-40ed-ae46-a564d484325e"
14517 wsmap="managed" id="MachineEvent"
14518 >
14519 <desc>Base abstract interface for all machine events.</desc>
14520
14521 <attribute name="machineId" readonly="yes" type="uuid" mod="string">
14522 <desc>ID of the machine this event relates to.</desc>
14523 </attribute>
14524
14525 </interface>
14526
14527 <interface
14528 name="IMachineStateChangedEvent" extends="IMachineEvent"
14529 uuid="5748F794-48DF-438D-85EB-98FFD70D18C9"
14530 wsmap="managed" autogen="VBoxEvent" id="OnMachineStateChanged"
14531 >
14532 <desc>Machine state change event.</desc>
14533
14534 <attribute name="state" readonly="yes" type="MachineState">
14535 <desc>New execution state.</desc>
14536 </attribute>
14537 </interface>
14538
14539 <interface
14540 name="IMachineDataChangedEvent" extends="IMachineEvent"
14541 uuid="6AA70A6C-0DCA-4810-8C5C-457B278E3D49"
14542 wsmap="managed" autogen="VBoxEvent" id="OnMachineDataChanged"
14543 >
14544 <desc>
14545 Any of the settings of the given machine has changed.
14546 </desc>
14547 </interface>
14548
14549 <interface
14550 name="IMediumRegisteredEvent" extends="IEvent"
14551 uuid="53fac49a-b7f1-4a5a-a4ef-a11dd9c2a458"
14552 wsmap="managed" autogen="VBoxEvent" id="OnMediumRegistered"
14553 >
14554 <desc>
14555 The given medium was registered or unregistered
14556 within this VirtualBox installation.
14557 </desc>
14558
14559 <attribute name="mediumId" readonly="yes" type="uuid" mod="string">
14560 <desc>ID of the medium this event relates to.</desc>
14561 </attribute>
14562
14563 <attribute name="mediumType" readonly="yes" type="DeviceType">
14564 <desc>Type of the medium this event relates to.</desc>
14565 </attribute>
14566
14567 <attribute name="registered" type="boolean" readonly="yes">
14568 <desc>
14569 If @c true, the medium was registered, otherwise it was
14570 unregistered.
14571 </desc>
14572 </attribute>
14573 </interface>
14574
14575 <interface
14576 name="IMachineRegisteredEvent" extends="IMachineEvent"
14577 uuid="c354a762-3ff2-4f2e-8f09-07382ee25088"
14578 wsmap="managed" autogen="VBoxEvent" id="OnMachineRegistered"
14579 >
14580 <desc>
14581 The given machine was registered or unregistered
14582 within this VirtualBox installation.
14583 </desc>
14584
14585 <attribute name="registered" type="boolean" readonly="yes">
14586 <desc>
14587 If @c true, the machine was registered, otherwise it was
14588 unregistered.
14589 </desc>
14590 </attribute>
14591 </interface>
14592
14593 <interface
14594 name="ISessionStateChangedEvent" extends="IMachineEvent"
14595 uuid="714a3eef-799a-4489-86cd-fe8e45b2ff8e"
14596 wsmap="managed" autogen="VBoxEvent" id="OnSessionStateChanged"
14597 >
14598 <desc>
14599 The state of the session for the given machine was changed.
14600 <see>IMachine::sessionState</see>
14601 </desc>
14602
14603 <attribute name="state" type="SessionState" readonly="yes">
14604 <desc>
14605 New session state.
14606 </desc>
14607 </attribute>
14608 </interface>
14609
14610 <interface
14611 name="IGuestPropertyChangedEvent" extends="IMachineEvent"
14612 uuid="3f63597a-26f1-4edb-8dd2-6bddd0912368"
14613 wsmap="managed" autogen="VBoxEvent" id="OnGuestPropertyChanged"
14614 >
14615 <desc>
14616 Notification when a guest property has changed.
14617 </desc>
14618
14619 <attribute name="name" readonly="yes" type="wstring">
14620 <desc>
14621 The name of the property that has changed.
14622 </desc>
14623 </attribute>
14624
14625 <attribute name="value" readonly="yes" type="wstring">
14626 <desc>
14627 The new property value.
14628 </desc>
14629 </attribute>
14630
14631 <attribute name="flags" readonly="yes" type="wstring">
14632 <desc>
14633 The new property flags.
14634 </desc>
14635 </attribute>
14636
14637 </interface>
14638
14639 <interface
14640 name="ISnapshotEvent" extends="IMachineEvent"
14641 uuid="21637b0e-34b8-42d3-acfb-7e96daf77c22"
14642 wsmap="managed" id="SnapshotEvent"
14643 >
14644 <desc>Base interface for all snapshot events.</desc>
14645
14646 <attribute name="snapshotId" readonly="yes" type="uuid" mod="string">
14647 <desc>ID of the snapshot this event relates to.</desc>
14648 </attribute>
14649
14650 </interface>
14651
14652 <interface
14653 name="ISnapshotTakenEvent" extends="ISnapshotEvent"
14654 uuid="d27c0b3d-6038-422c-b45e-6d4a0503d9f1"
14655 wsmap="managed" autogen="VBoxEvent" id="OnSnapshotTaken"
14656 >
14657 <desc>
14658 A new snapshot of the machine has been taken.
14659 <see>ISnapshot</see>
14660 </desc>
14661 </interface>
14662
14663 <interface
14664 name="ISnapshotDeletedEvent" extends="ISnapshotEvent"
14665 uuid="c48f3401-4a9e-43f4-b7a7-54bd285e22f4"
14666 wsmap="managed" autogen="VBoxEvent" id="OnSnapshotDeleted"
14667 >
14668 <desc>
14669 Snapshot of the given machine has been deleted.
14670
14671 <note>
14672 This notification is delivered <b>after</b> the snapshot
14673 object has been uninitialized on the server (so that any
14674 attempt to call its methods will return an error).
14675 </note>
14676
14677 <see>ISnapshot</see>
14678 </desc>
14679 </interface>
14680
14681 <interface
14682 name="ISnapshotChangedEvent" extends="ISnapshotEvent"
14683 uuid="07541941-8079-447a-a33e-47a69c7980db"
14684 wsmap="managed" autogen="VBoxEvent" id="OnSnapshotChanged"
14685 >
14686 <desc>
14687 Snapshot properties (name and/or description) have been changed.
14688 <see>ISnapshot</see>
14689 </desc>
14690 </interface>
14691
14692 <interface
14693 name="IMousePointerShapeChangedEvent" extends="IEvent"
14694 uuid="a6dcf6e8-416b-4181-8c4a-45ec95177aef"
14695 wsmap="managed" autogen="VBoxEvent" id="OnMousePointerShapeChanged"
14696 >
14697 <desc>
14698 Notification when the guest mouse pointer shape has
14699 changed. The new shape data is given.
14700 </desc>
14701
14702 <attribute name="visible" type="boolean" readonly="yes">
14703 <desc>
14704 Flag whether the pointer is visible.
14705 </desc>
14706 </attribute>
14707 <attribute name="alpha" type="boolean" readonly="yes">
14708 <desc>
14709 Flag whether the pointer has an alpha channel.
14710 </desc>
14711 </attribute>
14712 <attribute name="xhot" type="unsigned long" readonly="yes">
14713 <desc>
14714 The pointer hot spot X coordinate.
14715 </desc>
14716 </attribute>
14717 <attribute name="yhot" type="unsigned long" readonly="yes">
14718 <desc>
14719 The pointer hot spot Y coordinate.
14720 </desc>
14721 </attribute>
14722 <attribute name="width" type="unsigned long" readonly="yes">
14723 <desc>
14724 Width of the pointer shape in pixels.
14725 </desc>
14726 </attribute>
14727 <attribute name="height" type="unsigned long" readonly="yes">
14728 <desc>
14729 Height of the pointer shape in pixels.
14730 </desc>
14731 </attribute>
14732 <attribute name="shape" type="octet" safearray="yes" readonly="yes">
14733 <desc>
14734 Shape buffer arrays.
14735
14736 The @a shape buffer contains a 1-bpp (bits per pixel) AND mask
14737 followed by a 32-bpp XOR (color) mask.
14738
14739 For pointers without alpha channel the XOR mask pixels are 32
14740 bit values: (lsb)BGR0(msb). For pointers with alpha channel
14741 the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
14742
14743 An AND mask is used for pointers with alpha channel, so if the
14744 callback does not support alpha, the pointer could be
14745 displayed as a normal color pointer.
14746
14747 The AND mask is a 1-bpp bitmap with byte aligned scanlines. The
14748 size of the AND mask therefore is <tt>cbAnd = (width + 7) / 8 *
14749 height</tt>. The padding bits at the end of each scanline are
14750 undefined.
14751
14752 The XOR mask follows the AND mask on the next 4-byte aligned
14753 offset: <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>.
14754 Bytes in the gap between the AND and the XOR mask are undefined.
14755 The XOR mask scanlines have no gap between them and the size of
14756 the XOR mask is: <tt>cXor = width * 4 * height</tt>.
14757
14758 <note>
14759 If @a shape is 0, only the pointer visibility is changed.
14760 </note>
14761 </desc>
14762 </attribute>
14763 </interface>
14764
14765 <interface
14766 name="IMouseCapabilityChangedEvent" extends="IEvent"
14767 uuid="d633ad48-820c-4207-b46c-6bd3596640d5"
14768 wsmap="managed" autogen="VBoxEvent" id="OnMouseCapabilityChanged"
14769 >
14770 <desc>
14771 Notification when the mouse capabilities reported by the
14772 guest have changed. The new capabilities are passed.
14773 </desc>
14774 <attribute name="supportsAbsolute" type="boolean" readonly="yes">
14775 <desc>
14776 Supports absolute coordinates.
14777 </desc>
14778 </attribute>
14779 <attribute name="supportsRelative" type="boolean" readonly="yes">
14780 <desc>
14781 Supports relative coordinates.
14782 </desc>
14783 </attribute>
14784 <attribute name="needsHostCursor" type="boolean" readonly="yes">
14785 <desc>
14786 If host cursor is needed.
14787 </desc>
14788 </attribute>
14789 </interface>
14790
14791 <interface
14792 name="IKeyboardLedsChangedEvent" extends="IEvent"
14793 uuid="6DDEF35E-4737-457B-99FC-BC52C851A44F"
14794 wsmap="managed" autogen="VBoxEvent" id="OnKeyboardLedsChanged"
14795 >
14796 <desc>
14797 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
14798 to alter the state of the keyboard LEDs.
14799 </desc>
14800 <attribute name="numLock" type="boolean" readonly="yes">
14801 <desc>
14802 NumLock status.
14803 </desc>
14804 </attribute>
14805 <attribute name="capsLock" type="boolean" readonly="yes">
14806 <desc>
14807 CapsLock status.
14808 </desc>
14809 </attribute>
14810 <attribute name="scrollLock" type="boolean" readonly="yes">
14811 <desc>
14812 ScrollLock status.
14813 </desc>
14814 </attribute>
14815 </interface>
14816
14817 <interface
14818 name="IStateChangedEvent" extends="IEvent"
14819 uuid="4376693C-CF37-453B-9289-3B0F521CAF27"
14820 wsmap="managed" autogen="VBoxEvent" id="OnStateChanged"
14821 >
14822 <desc>
14823 Notification when the execution state of the machine has changed.
14824 The new state is given.
14825 </desc>
14826 <attribute name="state" type="MachineState" readonly="yes">
14827 <desc>
14828 New machine state.
14829 </desc>
14830 </attribute>
14831 </interface>
14832
14833 <interface
14834 name="IAdditionsStateChangedEvent" extends="IEvent"
14835 uuid="D70F7915-DA7C-44C8-A7AC-9F173490446A"
14836 wsmap="managed" autogen="VBoxEvent" id="OnAdditionsStateChanged"
14837 >
14838 <desc>
14839 Notification when a Guest Additions property changes.
14840 Interested callees should query IGuest attributes to
14841 find out what has changed.
14842 </desc>
14843 </interface>
14844
14845 <interface
14846 name="INetworkAdapterChangedEvent" extends="IEvent"
14847 uuid="08889892-1EC6-4883-801D-77F56CFD0103"
14848 wsmap="managed" autogen="VBoxEvent" id="OnNetworkAdapterChanged"
14849 >
14850 <desc>
14851 Notification when a property of one of the
14852 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
14853 changes. Interested callees should use INetworkAdapter methods and
14854 attributes to find out what has changed.
14855 </desc>
14856 <attribute name="networkAdapter" type="INetworkAdapter" readonly="yes">
14857 <desc>
14858 Network adapter that is subject to change.
14859 </desc>
14860 </attribute>
14861 </interface>
14862
14863 <interface
14864 name="ISerialPortChangedEvent" extends="IEvent"
14865 uuid="3BA329DC-659C-488B-835C-4ECA7AE71C6C"
14866 wsmap="managed" autogen="VBoxEvent" id="OnSerialPortChanged"
14867 >
14868 <desc>
14869 Notification when a property of one of the
14870 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
14871 Interested callees should use ISerialPort methods and attributes
14872 to find out what has changed.
14873 </desc>
14874 <attribute name="serialPort" type="ISerialPort" readonly="yes">
14875 <desc>
14876 Serial port that is subject to change.
14877 </desc>
14878 </attribute>
14879 </interface>
14880
14881 <interface
14882 name="IParallelPortChangedEvent" extends="IEvent"
14883 uuid="813C99FC-9849-4F47-813E-24A75DC85615"
14884 wsmap="managed" autogen="VBoxEvent" id="OnParallelPortChanged"
14885 >
14886 <desc>
14887 Notification when a property of one of the
14888 virtual <link to="IMachine::getParallelPort">parallel ports</link>
14889 changes. Interested callees should use ISerialPort methods and
14890 attributes to find out what has changed.
14891 </desc>
14892 <attribute name="parallelPort" type="IParallelPort" readonly="yes">
14893 <desc>
14894 Parallel port that is subject to change.
14895 </desc>
14896 </attribute>
14897 </interface>
14898
14899 <interface
14900 name="IStorageControllerChangedEvent" extends="IEvent"
14901 uuid="715212BF-DA59-426E-8230-3831FAA52C56"
14902 wsmap="managed" autogen="VBoxEvent" id="OnStorageControllerChanged"
14903 >
14904 <desc>
14905 Notification when a
14906 <link to="IMachine::mediumAttachments">medium attachment</link>
14907 changes.
14908 </desc>
14909 </interface>
14910
14911 <interface
14912 name="IMediumChangedEvent" extends="IEvent"
14913 uuid="0FE2DA40-5637-472A-9736-72019EABD7DE"
14914 wsmap="managed" autogen="VBoxEvent" id="OnMediumChanged"
14915 >
14916 <desc>
14917 Notification when a
14918 <link to="IMachine::mediumAttachments">medium attachment</link>
14919 changes.
14920 </desc>
14921 <attribute name="mediumAttachment" type="IMediumAttachment" readonly="yes">
14922 <desc>
14923 Medium attachment that is subject to change.
14924 </desc>
14925 </attribute>
14926 </interface>
14927
14928 <interface
14929 name="ICPUChangedEvent" extends="IEvent"
14930 uuid="D0F0BECC-EE17-4D17-A8CC-383B0EB55E9D"
14931 wsmap="managed" autogen="VBoxEvent" id="OnCPUChanged"
14932 >
14933 <desc>
14934 Notification when a CPU changes.
14935 </desc>
14936 <attribute name="cpu" type="unsigned long" readonly="yes">
14937 <desc>
14938 The CPU which changed.
14939 </desc>
14940 </attribute>
14941 <attribute name="add" type="boolean" readonly="yes">
14942 <desc>
14943 Flag whether the CPU was added or removed.
14944 </desc>
14945 </attribute>
14946 </interface>
14947
14948 <interface
14949 name="ICPUExecutionCapChangedEvent" extends="IEvent"
14950 uuid="dfa7e4f5-b4a4-44ce-85a8-127ac5eb59dc"
14951 wsmap="managed" autogen="VBoxEvent" id="OnCPUExecutionCapChanged"
14952 >
14953 <desc>
14954 Notification when the CPU execution cap changes.
14955 </desc>
14956 <attribute name="executionCap" type="unsigned long" readonly="yes">
14957 <desc>
14958 The new CPU execution cap value. (1-100)
14959 </desc>
14960 </attribute>
14961 </interface>
14962
14963 <interface
14964 name="IGuestKeyboardEvent" extends="IEvent"
14965 uuid="88394258-7006-40d4-b339-472ee3801844"
14966 wsmap="managed" autogen="VBoxEvent" id="OnGuestKeyboardEvent"
14967 >
14968 <desc>
14969 Notification when guest keyboard event happens.
14970 </desc>
14971 <attribute name="scancodes" type="long" safearray="yes" readonly="yes">
14972 <desc>
14973 Array of scancodes.
14974 </desc>
14975 </attribute>
14976 </interface>
14977
14978 <interface
14979 name="IGuestMouseEvent" extends="IReusableEvent"
14980 uuid="1f85d35c-c524-40ff-8e98-307000df0992"
14981 wsmap="managed" autogen="VBoxEvent" id="OnGuestMouseEvent"
14982 >
14983 <desc>
14984 Notification when guest mouse event happens.
14985 </desc>
14986
14987 <attribute name="absolute" type="boolean" readonly="yes">
14988 <desc>
14989 If this event is relative or absolute.
14990 </desc>
14991 </attribute>
14992
14993 <attribute name="x" type="long" readonly="yes">
14994 <desc>
14995 New X position, or X delta.
14996 </desc>
14997 </attribute>
14998
14999 <attribute name="y" type="long" readonly="yes">
15000 <desc>
15001 New Y position, or Y delta.
15002 </desc>
15003 </attribute>
15004
15005 <attribute name="z" type="long" readonly="yes">
15006 <desc>
15007 Z delta.
15008 </desc>
15009 </attribute>
15010
15011 <attribute name="w" type="long" readonly="yes">
15012 <desc>
15013 W delta.
15014 </desc>
15015 </attribute>
15016
15017 <attribute name="buttons" type="long" readonly="yes">
15018 <desc>
15019 Button state bitmask.
15020 </desc>
15021 </attribute>
15022
15023 </interface>
15024
15025
15026 <interface
15027 name="IVRDPServerChangedEvent" extends="IEvent"
15028 uuid="726038B6-6279-4A7A-8037-D041693D1915"
15029 wsmap="managed" autogen="VBoxEvent" id="OnVRDPServerChanged"
15030 >
15031 <desc>
15032 Notification when a property of the
15033 <link to="IMachine::VRDPServer">VRDP server</link> changes.
15034 Interested callees should use IVRDPServer methods and attributes to
15035 find out what has changed.
15036 </desc>
15037 </interface>
15038
15039 <interface
15040 name="IRemoteDisplayInfoChangedEvent" extends="IEvent"
15041 uuid="65B556C5-2A99-47D8-B311-FC177F0914CD"
15042 wsmap="managed" autogen="VBoxEvent" id="OnRemoteDisplayInfoChanged"
15043 >
15044 <desc>
15045 Notification when the status of the VRDP server changes. Interested callees
15046 should use <link to="IConsole::remoteDisplayInfo">IRemoteDisplayInfo</link>
15047 attributes to find out what is the current status.
15048 </desc>
15049 </interface>
15050
15051 <interface
15052 name="IUSBControllerChangedEvent" extends="IEvent"
15053 uuid="93BADC0C-61D9-4940-A084-E6BB29AF3D83"
15054 wsmap="managed" autogen="VBoxEvent" id="OnUSBControllerChanged"
15055 >
15056 <desc>
15057 Notification when a property of the virtual
15058 <link to="IMachine::USBController">USB controller</link> changes.
15059 Interested callees should use IUSBController methods and attributes to
15060 find out what has changed.
15061 </desc>
15062 </interface>
15063
15064 <interface
15065 name="IUSBDeviceStateChangedEvent" extends="IEvent"
15066 uuid="806da61b-6679-422a-b629-51b06b0c6d93"
15067 wsmap="managed" autogen="VBoxEvent" id="OnUSBDeviceStateChanged"
15068 >
15069 <desc>
15070 Notification when a USB device is attached to or detached from
15071 the virtual USB controller.
15072
15073 This notification is sent as a result of the indirect
15074 request to attach the device because it matches one of the
15075 machine USB filters, or as a result of the direct request
15076 issued by <link to="IConsole::attachUSBDevice"/> or
15077 <link to="IConsole::detachUSBDevice"/>.
15078
15079 This notification is sent in case of both a succeeded and a
15080 failed request completion. When the request succeeds, the
15081 @a error parameter is @c null, and the given device has been
15082 already added to (when @a attached is @c true) or removed from
15083 (when @a attached is @c false) the collection represented by
15084 <link to="IConsole::USBDevices"/>. On failure, the collection
15085 doesn't change and the @a error parameter represents the error
15086 message describing the failure.
15087 </desc>
15088 <attribute name="device" type="IUSBDevice" readonly="yes">
15089 <desc>
15090 Device that is subject to state change.
15091 </desc>
15092 </attribute>
15093 <attribute name="attached" type="boolean" readonly="yes">
15094 <desc>
15095 @c true if the device was attached and @c false otherwise.
15096 </desc>
15097 </attribute>
15098 <attribute name="error" type="IVirtualBoxErrorInfo" readonly="yes">
15099 <desc>
15100 @c null on success or an error message object on failure.
15101 </desc>
15102 </attribute>
15103 </interface>
15104
15105 <interface
15106 name="ISharedFolderChangedEvent" extends="IEvent"
15107 uuid="B66349B5-3534-4239-B2DE-8E1535D94C0B"
15108 wsmap="managed" autogen="VBoxEvent" id="OnSharedFolderChanged"
15109 >
15110 <desc>
15111 Notification when a shared folder is added or removed.
15112 The @a scope argument defines one of three scopes:
15113 <link to="IVirtualBox::sharedFolders">global shared folders</link>
15114 (<link to="Scope_Global">Global</link>),
15115 <link to="IMachine::sharedFolders">permanent shared folders</link> of
15116 the machine (<link to="Scope_Machine">Machine</link>) or <link
15117 to="IConsole::sharedFolders">transient shared folders</link> of the
15118 machine (<link to="Scope_Session">Session</link>). Interested callees
15119 should use query the corresponding collections to find out what has
15120 changed.
15121 </desc>
15122 <attribute name="scope" type="Scope" readonly="yes">
15123 <desc>
15124 Scope of the notification.
15125 </desc>
15126 </attribute>
15127 </interface>
15128
15129 <interface
15130 name="IRuntimeErrorEvent" extends="IEvent"
15131 uuid="883DD18B-0721-4CDE-867C-1A82ABAF914C"
15132 wsmap="managed" autogen="VBoxEvent" id="OnRuntimeError"
15133 >
15134 <desc>
15135 Notification when an error happens during the virtual
15136 machine execution.
15137
15138 There are three kinds of runtime errors:
15139 <ul>
15140 <li><i>fatal</i></li>
15141 <li><i>non-fatal with retry</i></li>
15142 <li><i>non-fatal warnings</i></li>
15143 </ul>
15144
15145 <b>Fatal</b> errors are indicated by the @a fatal parameter set
15146 to @c true. In case of fatal errors, the virtual machine
15147 execution is always paused before calling this notification, and
15148 the notification handler is supposed either to immediately save
15149 the virtual machine state using <link to="IConsole::saveState"/>
15150 or power it off using <link to="IConsole::powerDown"/>.
15151 Resuming the execution can lead to unpredictable results.
15152
15153 <b>Non-fatal</b> errors and warnings are indicated by the
15154 @a fatal parameter set to @c false. If the virtual machine
15155 is in the Paused state by the time the error notification is
15156 received, it means that the user can <i>try to resume</i> the machine
15157 execution after attempting to solve the problem that caused the
15158 error. In this case, the notification handler is supposed
15159 to show an appropriate message to the user (depending on the
15160 value of the @a id parameter) that offers several actions such
15161 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
15162 wants to retry, the notification handler should continue
15163 the machine execution using the <link to="IConsole::resume"/>
15164 call. If the machine execution is not Paused during this
15165 notification, then it means this notification is a <i>warning</i>
15166 (for example, about a fatal condition that can happen very soon);
15167 no immediate action is required from the user, the machine
15168 continues its normal execution.
15169
15170 Note that in either case the notification handler
15171 <b>must not</b> perform any action directly on a thread
15172 where this notification is called. Everything it is allowed to
15173 do is to post a message to another thread that will then talk
15174 to the user and take the corresponding action.
15175
15176 Currently, the following error identifiers are known:
15177 <ul>
15178 <li><tt>"HostMemoryLow"</tt></li>
15179 <li><tt>"HostAudioNotResponding"</tt></li>
15180 <li><tt>"VDIStorageFull"</tt></li>
15181 <li><tt>"3DSupportIncompatibleAdditions"</tt></li>
15182 </ul>
15183 </desc>
15184 <attribute name="fatal" type="boolean" readonly="yes">
15185 <desc>
15186 Whether the error is fatal or not.
15187 </desc>
15188 </attribute>
15189 <attribute name="id" type="wstring" readonly="yes">
15190 <desc>
15191 Error identifier.
15192 </desc>
15193 </attribute>
15194 <attribute name="message" type="wstring" readonly="yes">
15195 <desc>
15196 Optional error message.
15197 </desc>
15198 </attribute>
15199 </interface>
15200
15201
15202 <interface
15203 name="IEventSourceChangedEvent" extends="IEvent"
15204 uuid="e7932cb8-f6d4-4ab6-9cbf-558eb8959a6a"
15205 waitable="yes"
15206 wsmap="managed" autogen="VBoxEvent" id="OnEventSourceChanged"
15207 >
15208 <desc>
15209 Notification when an event source state changes (listener added or removed).
15210 </desc>
15211
15212 <attribute name="listener" type="IEventListener" readonly="yes">
15213 <desc>
15214 Event listener which has changed.
15215 </desc>
15216 </attribute>
15217
15218 <attribute name="add" type="boolean" readonly="yes">
15219 <desc>
15220 Flag whether listener was added or removed.
15221 </desc>
15222 </attribute>
15223 </interface>
15224
15225 <interface
15226 name="IExtraDataChangedEvent" extends="IEvent"
15227 uuid="024F00CE-6E0B-492A-A8D0-968472A94DC7"
15228 wsmap="managed" autogen="VBoxEvent" id="OnExtraDataChanged"
15229 >
15230 <desc>
15231 Notification when machine specific or global extra data
15232 has changed.
15233 </desc>
15234 <attribute name="machineId" type="uuid" mod="string" readonly="yes">
15235 <desc>
15236 ID of the machine this event relates to.
15237 Null for global extra data changes.
15238 </desc>
15239 </attribute>
15240 <attribute name="key" type="wstring" readonly="yes">
15241 <desc>
15242 Extra data key that has changed.
15243 </desc>
15244 </attribute>
15245 <attribute name="value" type="wstring" readonly="yes">
15246 <desc>
15247 Extra data value for the given key.
15248 </desc>
15249 </attribute>
15250 </interface>
15251
15252 <interface
15253 name="IVetoEvent" extends="IEvent"
15254 uuid="9a1a4130-69fe-472f-ac10-c6fa25d75007"
15255 wsmap="managed"
15256 >
15257 <desc>Base abstract interface for veto events.</desc>
15258
15259 <method name="addVeto">
15260 <desc>
15261 Adds a veto on this event.
15262 </desc>
15263 <param name="reason" type="wstring" dir="in">
15264 <desc>
15265 Reason for veto, could be null or empty string.
15266 </desc>
15267 </param>
15268 </method>
15269
15270 <method name="isVetoed">
15271 <desc>
15272 If this event was vetoed.
15273 </desc>
15274 <param name="result" type="boolean" dir="return">
15275 <desc>
15276 Reason for veto.
15277 </desc>
15278 </param>
15279 </method>
15280
15281 <method name="getVetos">
15282 <desc>
15283 Current veto reason list, if size is 0 - no veto.
15284 </desc>
15285 <param name="result" type="wstring" dir="return" safearray="yes">
15286 <desc>
15287 Array of reasons for veto provided by different event handlers.
15288 </desc>
15289 </param>
15290 </method>
15291
15292 </interface>
15293
15294 <interface
15295 name="IExtraDataCanChangeEvent" extends="IVetoEvent"
15296 uuid="245d88bd-800a-40f8-87a6-170d02249a55"
15297 wsmap="managed" autogen="VBoxEvent" id="OnExtraDataCanChange"
15298 waitable="true"
15299 >
15300 <desc>
15301 Notification when someone tries to change extra data for
15302 either the given machine or (if @c null) global extra data.
15303 This gives the chance to veto against changes.
15304 </desc>
15305 <attribute name="machineId" type="uuid" mod="string" readonly="yes">
15306 <desc>
15307 ID of the machine this event relates to.
15308 Null for global extra data changes.
15309 </desc>
15310 </attribute>
15311 <attribute name="key" type="wstring" readonly="yes">
15312 <desc>
15313 Extra data key that has changed.
15314 </desc>
15315 </attribute>
15316 <attribute name="value" type="wstring" readonly="yes">
15317 <desc>
15318 Extra data value for the given key.
15319 </desc>
15320 </attribute>
15321 </interface>
15322
15323 <interface
15324 name="ICanShowWindowEvent" extends="IVetoEvent"
15325 uuid="adf292b0-92c9-4a77-9d35-e058b39fe0b9"
15326 wsmap="managed" autogen="VBoxEvent" id="OnCanShowWindow"
15327 waitable="true"
15328 >
15329 <desc>
15330 Notification when a call to
15331 <link to="IMachine::canShowConsoleWindow"/> is made by a
15332 front-end to check if a subsequent call to
15333 <link to="IMachine::showConsoleWindow"/> can succeed.
15334
15335 The callee should give an answer appropriate to the current
15336 machine state using event veto. This answer must
15337 remain valid at least until the next
15338 <link to="IConsole::state">machine state</link> change.
15339 </desc>
15340 </interface>
15341
15342 <interface
15343 name="IShowWindowEvent" extends="IEvent"
15344 uuid="B0A0904D-2F05-4D28-855F-488F96BAD2B2"
15345 wsmap="managed" autogen="VBoxEvent" id="OnShowWindow"
15346 waitable="true"
15347 >
15348 <desc>
15349 Notification when a call to
15350 <link to="IMachine::showConsoleWindow"/>
15351 requests the console window to be activated and brought to
15352 foreground on the desktop of the host PC.
15353
15354 This notification should cause the VM console process to
15355 perform the requested action as described above. If it is
15356 impossible to do it at a time of this notification, this
15357 method should return a failure.
15358
15359 Note that many modern window managers on many platforms
15360 implement some sort of focus stealing prevention logic, so
15361 that it may be impossible to activate a window without the
15362 help of the currently active application (which is supposedly
15363 an initiator of this notification). In this case, this method
15364 must return a non-zero identifier that represents the
15365 top-level window of the VM console process. The caller, if it
15366 represents a currently active process, is responsible to use
15367 this identifier (in a platform-dependent manner) to perform
15368 actual window activation.
15369
15370 This method must set @a winId to zero if it has performed all
15371 actions necessary to complete the request and the console
15372 window is now active and in foreground, to indicate that no
15373 further action is required on the caller's side.
15374 </desc>
15375 <attribute name="winId" type="long long">
15376 <desc>
15377 Platform-dependent identifier of the top-level VM console
15378 window, or zero if this method has performed all actions
15379 necessary to implement the <i>show window</i> semantics for
15380 the given platform and/or this VirtualBox front-end.
15381 </desc>
15382 </attribute>
15383 </interface>
15384
15385 <module name="VBoxSVC" context="LocalServer">
15386 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
15387 namespace="virtualbox.org">
15388 <interface name="IVirtualBox" default="yes"/>
15389 </class>
15390 </module>
15391
15392 <module name="VBoxC" context="InprocServer" threadingModel="Free">
15393 <class name="Session" uuid="3C02F46D-C9D2-4F11-A384-53F0CF917214"
15394 namespace="virtualbox.org">
15395 <interface name="ISession" default="yes"/>
15396 </class>
15397
15398 <class name="Console" uuid="577230FF-164F-4CAC-8548-312D8275A4A7"
15399 namespace="virtualbox.org">
15400 <interface name="IConsole" default="yes"/>
15401 </class>
15402 </module>
15403
15404</library>
15405
15406</idl>
15407
15408<!-- vim: set shiftwidth=2 tabstop=2 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