VirtualBox

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

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

Whitespaces.

  • Property svn:eol-style set to native
File size: 561.5 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="a35a051c-0966-4582-8e9c-7c1b973f6bd2"
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 <method name="composeMachineFilename">
1517 <desc>
1518 Returns the full path of the settings file name that <link to="#createMachine" />
1519 would use. This method gets called by createMachine(), but calling this method
1520 independently might be helpful if one needs to create the machine directory
1521 to place files (such as disk images) there before actually creating the machine.
1522
1523 See the <link to="IMachine::name"/> attribute description for more details about
1524 the machine name.
1525
1526 Every machine has a <i>settings file</i> that is used to store
1527 the machine configuration. This file is stored in a directory called the
1528 <i>machine settings subfolder</i>. Both the settings subfolder and file
1529 will have a name that corresponds to the name of the virtual machine.
1530 You can specify where to create the machine setting subfolder using the
1531 @a baseFolder argument. The base folder can be absolute (full path) or
1532 relative to the <link to="IVirtualBox::homeFolder">VirtualBox home
1533 directory</link>.
1534
1535 If @a baseFolder is a @c null or empty string (which is recommended), the
1536 <link to="ISystemProperties::defaultMachineFolder">default machine
1537 settings folder</link> will be used as a base folder for the created
1538 machine. Otherwise the given base folder will be used. In either case,
1539 the full path to the resulting settings file has the following
1540 structure:
1541 <pre>
1542 &lt;base_folder&gt;/&lt;machine_name&gt;/&lt;machine_name&gt;.xml
1543 </pre>
1544
1545
1546 This method does not access the host disks. In particular, it does not check for
1547 whether a machine of this name already exists.
1548 </desc>
1549 <param name="name" type="wstring" dir="in">
1550 <desc>Suggested machine name.</desc>
1551 </param>
1552 <param name="baseFolder" type="wstring" dir="in">
1553 <desc>Base machine folder (optional).</desc>
1554 </param>
1555 <param name="file" type="wstring" dir="return">
1556 <desc>Fully qualified path where the machine would be created.</desc>
1557 </param>
1558 </method>
1559
1560 <method name="createMachine">
1561 <desc>
1562 Creates a new virtual machine.
1563
1564 The new machine is created unregistered, with the initial configuration
1565 set according to the specified guest OS type. A typical sequence of
1566 actions to create a new virtual machine is as follows:
1567
1568 <ol>
1569 <li>
1570 Call this method to have a new machine created. The returned machine
1571 object will be "mutable" allowing to change any machine property.
1572 </li>
1573
1574 <li>
1575 Configure the machine using the appropriate attributes and methods.
1576 </li>
1577
1578 <li>
1579 Call <link to="IMachine::saveSettings" /> to write the settings
1580 to the machine's XML settings file. The configuration of the newly
1581 created machine will not be saved to disk until this method is
1582 called.
1583 </li>
1584
1585 <li>
1586 Call <link to="#registerMachine" /> to add the machine to the list
1587 of machines known to VirtualBox.
1588 </li>
1589 </ol>
1590
1591 The specified guest OS type identifier must match an ID of one of known
1592 guest OS types listed in the <link to="IVirtualBox::guestOSTypes"/>
1593 array.
1594
1595 This method uses the <link to="#composeMachineFilename" /> method to determine
1596 where to create the machine's directory and settings file. Please refer
1597 to the additional remarks and restrictions there.
1598
1599 If the resulting settings file already exists, this method will fail
1600 with <link to="VBOX_E_FILE_ERROR"/>.
1601
1602 Optionally, you may specify an UUID of to assign to the created machine.
1603 However, this is not recommended and you should normally pass an empty
1604 (@c null) UUID to this method so that a new UUID will be automatically
1605 generated for every created machine. You can use UUID
1606 00000000-0000-0000-0000-000000000000 as @c null value.
1607
1608 <note>
1609 There is no way to change the name of the settings file or
1610 subfolder of the created machine directly.
1611 </note>
1612
1613 <result name="VBOX_E_OBJECT_NOT_FOUND">
1614 @a osTypeId is invalid.
1615 </result>
1616 <result name="VBOX_E_FILE_ERROR">
1617 Resulting settings file name is invalid or the settings file already
1618 exists or could not be created due to an I/O error.
1619 </result>
1620 <result name="E_INVALIDARG">
1621 @a name is empty or @c null.
1622 </result>
1623 </desc>
1624
1625 <param name="name" type="wstring" dir="in">
1626 <desc>Machine name.</desc>
1627 </param>
1628 <param name="osTypeId" type="wstring" dir="in">
1629 <desc>Guest OS Type ID.</desc>
1630 </param>
1631 <param name="baseFolder" type="wstring" dir="in">
1632 <desc>Base machine folder (optional).</desc>
1633 </param>
1634 <param name="id" type="uuid" mod="string" dir="in">
1635 <desc>Machine UUID (optional).</desc>
1636 </param>
1637 <param name="override" type="boolean" dir="in">
1638 <desc>Create the VM even if there are conflicting files.</desc>
1639 </param>
1640 <param name="machine" type="IMachine" dir="return">
1641 <desc>Created machine object.</desc>
1642 </param>
1643 </method>
1644
1645 <method name="openMachine">
1646 <desc>
1647 Opens a virtual machine from the existing settings file.
1648 The opened machine remains unregistered until you call
1649 <link to="#registerMachine"/>.
1650
1651 The specified settings file name can be absolute
1652 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1653 VirtualBox home directory</link>. This file must exist
1654 and must be a valid machine settings file whose contents
1655 will be used to construct the machine object.
1656
1657 <result name="VBOX_E_FILE_ERROR">
1658 Settings file name invalid, not found or sharing violation.
1659 </result>
1660 </desc>
1661 <param name="settingsFile" type="wstring" dir="in">
1662 <desc>
1663 Name of the machine settings file.
1664 </desc>
1665 </param>
1666 <param name="machine" type="IMachine" dir="return">
1667 <desc>Opened machine object.</desc>
1668 </param>
1669 <note>
1670 <link to="IMachine::settingsModified"/> will return
1671 @c false for the created machine, until any of machine settings
1672 are changed.
1673 </note>
1674 </method>
1675
1676 <method name="registerMachine">
1677 <desc>
1678
1679 Registers the machine previously created using
1680 <link to="#createMachine"/> or opened using
1681 <link to="#openMachine"/> within this VirtualBox installation. After
1682 successful method invocation, the
1683 <link to="IMachineRegisteredEvent"/> event is fired.
1684
1685 <note>
1686 This method implicitly calls <link to="IMachine::saveSettings"/>
1687 to save all current machine settings before registering it.
1688 </note>
1689
1690 <result name="VBOX_E_OBJECT_NOT_FOUND">
1691 No matching virtual machine found.
1692 </result>
1693 <result name="VBOX_E_INVALID_OBJECT_STATE">
1694 Virtual machine was not created within this VirtualBox instance.
1695 </result>
1696
1697 </desc>
1698 <param name="machine" type="IMachine" dir="in"/>
1699 </method>
1700
1701 <method name="getMachine">
1702 <desc>
1703 Attempts to find a virtual machine given its UUID.
1704 To look up a machine by name, use <link to="IVirtualBox::findMachine" />
1705 instead.
1706
1707 <result name="VBOX_E_OBJECT_NOT_FOUND">
1708 Could not find registered machine matching @a id.
1709 </result>
1710
1711 </desc>
1712 <param name="id" type="uuid" mod="string" dir="in"/>
1713 <param name="machine" type="IMachine" dir="return"/>
1714 </method>
1715
1716 <method name="findMachine">
1717 <desc>
1718 Attempts to find a virtual machine given its name.
1719 To look up a machine by UUID, use <link to="IVirtualBox::getMachine" />
1720 instead.
1721
1722 <result name="VBOX_E_OBJECT_NOT_FOUND">
1723 Could not find registered machine matching @a name.
1724 </result>
1725
1726 </desc>
1727 <param name="name" type="wstring" dir="in"/>
1728 <param name="machine" type="IMachine" dir="return"/>
1729 </method>
1730
1731 <method name="createAppliance">
1732 <desc>
1733 Creates a new appliance object, which represents an appliance in the Open Virtual Machine
1734 Format (OVF). This can then be used to import an OVF appliance into VirtualBox or to export
1735 machines as an OVF appliance; see the documentation for <link to="IAppliance" /> for details.
1736 </desc>
1737 <param name="appliance" type="IAppliance" dir="return">
1738 <desc>New appliance.</desc>
1739 </param>
1740 </method>
1741
1742 <method name="createHardDisk">
1743 <desc>
1744 Creates a new base medium object that will use the given storage
1745 format and location for medium data.
1746
1747 Note that the actual storage unit is not created by this method. In
1748 order to do it, and before you are able to attach the created medium
1749 to virtual machines, you must call one of the following methods to
1750 allocate a format-specific storage unit at the specified location:
1751 <ul>
1752 <li><link to="IMedium::createBaseStorage"/></li>
1753 <li><link to="IMedium::createDiffStorage"/></li>
1754 </ul>
1755
1756 Some medium attributes, such as <link to="IMedium::id"/>, may
1757 remain uninitialized until the medium storage unit is successfully
1758 created by one of the above methods.
1759
1760 After the storage unit is successfully created, it will be
1761 accessible through the <link to="#findMedium"/> method and can
1762 be found in the <link to="#hardDisks"/> array.
1763
1764 The list of all storage formats supported by this VirtualBox
1765 installation can be obtained using
1766 <link to="ISystemProperties::mediumFormats"/>. If the @a format
1767 attribute is empty or @c null then the default storage format
1768 specified by <link to="ISystemProperties::defaultHardDiskFormat"/> will
1769 be used for creating a storage unit of the medium.
1770
1771 Note that the format of the location string is storage format specific.
1772 See <link to="IMedium::location"/> and IMedium for more details.
1773
1774 <result name="VBOX_E_OBJECT_NOT_FOUND">
1775 @a format identifier is invalid. See
1776 <link to="ISystemProperties::mediumFormats"/>.
1777 </result>
1778 <result name="VBOX_E_FILE_ERROR">
1779 @a location is a not valid file name (for file-based formats only).
1780 </result>
1781 </desc>
1782 <param name="format" type="wstring" dir="in">
1783 <desc>
1784 Identifier of the storage format to use for the new medium.
1785 </desc>
1786 </param>
1787 <param name="location" type="wstring" dir="in">
1788 <desc>
1789 Location of the storage unit for the new medium.
1790 </desc>
1791 </param>
1792 <param name="medium" type="IMedium" dir="return">
1793 <desc>Created medium object.</desc>
1794 </param>
1795 </method>
1796
1797 <method name="openMedium">
1798 <desc>
1799 Opens a medium from an existing storage location.
1800
1801 Once a medium has been opened, it can be passed to other VirtualBox
1802 methods, in particular to <link to="IMachine::attachDevice" />.
1803
1804 Depending on the given device type, the file at the storage location
1805 must be in one of the media formats understood by VirtualBox:
1806
1807 <ul>
1808 <li>With a "HardDisk" device type, the file must be a hard disk image
1809 in one of the formats supported by VirtualBox (see
1810 <link to="ISystemProperties::mediumFormats" />).
1811 After this method succeeds, if the medium is a base medium, it
1812 will be added to the <link to="#hardDisks"/> array attribute. </li>
1813 <li>With a "DVD" device type, the file must be an ISO 9960 CD/DVD image.
1814 After this method succeeds, the medium will be added to the
1815 <link to="#DVDImages"/> array attribute.</li>
1816 <li>With a "Floppy" device type, the file must be an RAW floppy image.
1817 After this method succeeds, the medium will be added to the
1818 <link to="#floppyImages"/> array attribute.</li>
1819 </ul>
1820
1821 After having been opened, the medium can be found by the <link to="#findMedium"/>
1822 method and can be attached to virtual machines. See <link to="IMedium" /> for more details.
1823
1824 The UUID of the newly opened medium will either be retrieved from the
1825 storage location, if the format supports it (e.g. for hard disk images),
1826 or a new UUID will be randomly generated (e.g. for ISO and RAW files).
1827 If for some reason you need to change the medium's UUID, use
1828 <link to="IMedium::setIDs" />.
1829
1830 If a differencing hard disk medium is to be opened by this method, the
1831 operation will succeed only if its parent medium and all ancestors,
1832 if any, are already known to this VirtualBox installation (for example,
1833 were opened by this method before).
1834
1835 This method attempts to guess the storage format of the specified medium
1836 by reading medium data at the specified location.
1837
1838 If @a accessMode is ReadWrite (which it should be for hard disks and floppies),
1839 the image is opened for read/write access and must have according permissions,
1840 as VirtualBox may actually write status information into the disk's metadata
1841 sections.
1842
1843 Note that write access is required for all typical hard disk usage in VirtualBox,
1844 since VirtualBox may need to write metadata such as a UUID into the image.
1845 The only exception is opening a source image temporarily for copying and
1846 cloning (see <link to="IMedium::cloneTo" /> when the image will be closed
1847 again soon.
1848
1849 The format of the location string is storage format specific. See
1850 <link to="IMedium::location"/> and IMedium for more details.
1851
1852 Prior to VirtualBox 3.3, opening a medium added it to a global media
1853 registry in the VirtualBox.xml file, which was shared between
1854 all machines and made transporting machines and their media from one
1855 host to another difficult.
1856
1857 Starting with VirtualBox 3.3, media are only added to a registry when
1858 they are attached to a machine. Machines created with VirtualBox 3.3
1859 or later can have their own media registry. As a result, a medium attached
1860 to such a machine will be remembered in that machine's XML settings file.
1861 Media attached to older machines will continue to be added to the global
1862 registry.
1863
1864 <result name="VBOX_E_FILE_ERROR">
1865 Invalid medium storage file location or could not find the medium
1866 at the specified location.
1867 </result>
1868 <result name="VBOX_E_IPRT_ERROR">
1869 Could not get medium storage format.
1870 </result>
1871 <result name="E_INVALIDARG">
1872 Invalid medium storage format.
1873 </result>
1874 <result name="VBOX_E_INVALID_OBJECT_STATE">
1875 Medium has already been added to a media registry.
1876 </result>
1877 </desc>
1878 <param name="location" type="wstring" dir="in">
1879 <desc>
1880 Location of the storage unit that contains medium data in one of
1881 the supported storage formats.
1882 </desc>
1883 </param>
1884 <param name="deviceType" type="DeviceType" dir="in">
1885 <desc>
1886 Must be one of "HardDisk", "DVD" or "Floppy".
1887 </desc>
1888 </param>
1889 <param name="accessMode" type="AccessMode" dir="in">
1890 <desc>Whether to open the image in read/write or read-only mode. For
1891 a "DVD" device type, this is ignored and read-only mode is always assumed.</desc>
1892 </param>
1893 <param name="medium" type="IMedium" dir="return">
1894 <desc>Opened medium object.</desc>
1895 </param>
1896 </method>
1897
1898 <method name="findMedium">
1899 <desc>
1900 Returns a medium of the given type that uses the given fully qualified
1901 location or UUID to store medium data.
1902
1903 The given medium must be known to this VirtualBox installation, i.e.
1904 it must be previously created by <link to="#createHardDisk"/> or opened
1905 by <link to="#openMedium"/>.
1906
1907 The search is done by comparing the value of the @a location argument to
1908 the <link to="IMedium::location"/> and <link to="IMedium::id" />
1909 attributes of each known medium.
1910
1911 On case sensitive file systems, a case sensitive comparison is performed,
1912 otherwise the case of symbols in the file path is ignored.
1913
1914 <result name="VBOX_E_OBJECT_NOT_FOUND">
1915 No medium object matching @a location found.
1916 </result>
1917 </desc>
1918 <param name="location" type="wstring" dir="in">
1919 <desc>What to search for. This can either be the UUID or the location string of an open medium.</desc>
1920 </param>
1921 <param name="type" type="DeviceType" dir="in">
1922 <desc>Device type (must be HardDisk, DVD or Floppy)</desc>
1923 </param>
1924 <param name="medium" type="IMedium" dir="return">
1925 <desc>Medium object, if found.</desc>
1926 </param>
1927 </method>
1928
1929 <method name="getGuestOSType">
1930 <desc>
1931 Returns an object describing the specified guest OS type.
1932
1933 The requested guest OS type is specified using a string which is a
1934 mnemonic identifier of the guest operating system, such as
1935 <tt>"win31"</tt> or <tt>"ubuntu"</tt>. The guest OS type ID of a
1936 particular virtual machine can be read or set using the
1937 <link to="IMachine::OSTypeId"/> attribute.
1938
1939 The <link to="IVirtualBox::guestOSTypes"/> collection contains all
1940 available guest OS type objects. Each object has an
1941 <link to="IGuestOSType::id"/> attribute which contains an identifier of
1942 the guest OS this object describes.
1943
1944 <result name="E_INVALIDARG">
1945 @a id is not a valid Guest OS type.
1946 </result>
1947
1948 </desc>
1949 <param name="id" type="uuid" mod="string" dir="in">
1950 <desc>Guest OS type ID string.</desc>
1951 </param>
1952 <param name="type" type="IGuestOSType" dir="return">
1953 <desc>Guest OS type object.</desc>
1954 </param>
1955 </method>
1956
1957 <method name="createSharedFolder">
1958 <desc>
1959 Creates a new global shared folder by associating the given logical
1960 name with the given host path, adds it to the collection of shared
1961 folders and starts sharing it. Refer to the description of
1962 <link to="ISharedFolder"/> to read more about logical names.
1963 <note>
1964 In the current implementation, this operation is not
1965 implemented.
1966 </note>
1967 </desc>
1968 <param name="name" type="wstring" dir="in">
1969 <desc>Unique logical name of the shared folder.</desc>
1970 </param>
1971 <param name="hostPath" type="wstring" dir="in">
1972 <desc>Full path to the shared folder in the host file system.</desc>
1973 </param>
1974 <param name="writable" type="boolean" dir="in">
1975 <desc>Whether the share is writable or readonly</desc>
1976 </param>
1977 <param name="automount" type="boolean" dir="in">
1978 <desc>Whether the share gets automatically mounted by the guest
1979 or not.</desc>
1980 </param>
1981 </method>
1982
1983 <method name="removeSharedFolder">
1984 <desc>
1985 Removes the global shared folder with the given name previously
1986 created by <link to="#createSharedFolder"/> from the collection of
1987 shared folders and stops sharing it.
1988 <note>
1989 In the current implementation, this operation is not
1990 implemented.
1991 </note>
1992 </desc>
1993 <param name="name" type="wstring" dir="in">
1994 <desc>Logical name of the shared folder to remove.</desc>
1995 </param>
1996 </method>
1997
1998 <method name="getExtraDataKeys">
1999 <desc>
2000 Returns an array representing the global extra data keys which currently
2001 have values defined.
2002 </desc>
2003 <param name="value" type="wstring" dir="return" safearray="yes">
2004 <desc>Array of extra data keys.</desc>
2005 </param>
2006 </method>
2007
2008 <method name="getExtraData">
2009 <desc>
2010 Returns associated global extra data.
2011
2012 If the requested data @a key does not exist, this function will
2013 succeed and return an empty string in the @a value argument.
2014
2015 <result name="VBOX_E_FILE_ERROR">
2016 Settings file not accessible.
2017 </result>
2018 <result name="VBOX_E_XML_ERROR">
2019 Could not parse the settings file.
2020 </result>
2021
2022 </desc>
2023 <param name="key" type="wstring" dir="in">
2024 <desc>Name of the data key to get.</desc>
2025 </param>
2026 <param name="value" type="wstring" dir="return">
2027 <desc>Value of the requested data key.</desc>
2028 </param>
2029 </method>
2030
2031 <method name="setExtraData">
2032 <desc>
2033 Sets associated global extra data.
2034
2035 If you pass @c null or empty string as a key @a value, the given @a key
2036 will be deleted.
2037
2038 <note>
2039 Before performing the actual data change, this method will ask all
2040 registered event listener using the
2041 <link to="IExtraDataCanChangeEvent"/>
2042 notification for a permission. If one of the listeners refuses the
2043 new value, the change will not be performed.
2044 </note>
2045 <note>
2046 On success, the
2047 <link to="IExtraDataChangedEvent"/> notification
2048 is called to inform all registered listeners about a successful data
2049 change.
2050 </note>
2051
2052 <result name="VBOX_E_FILE_ERROR">
2053 Settings file not accessible.
2054 </result>
2055 <result name="VBOX_E_XML_ERROR">
2056 Could not parse the settings file.
2057 </result>
2058 <result name="E_ACCESSDENIED">
2059 Modification request refused.
2060 </result>
2061
2062 </desc>
2063 <param name="key" type="wstring" dir="in">
2064 <desc>Name of the data key to set.</desc>
2065 </param>
2066 <param name="value" type="wstring" dir="in">
2067 <desc>Value to assign to the key.</desc>
2068 </param>
2069 </method>
2070
2071 <!--method name="createDHCPServerForInterface">
2072 <desc>
2073 Creates a dhcp server settings to be used for the given interface
2074 <result name="E_INVALIDARG">
2075 Host network interface @a name already exists.
2076 </result>
2077 </desc>
2078 <param name="interface" type="IHostNetworkInterface" dir="in">
2079 <desc>Network Interface</desc>
2080 </param>
2081 <param name="server" type="IDHCPServer" dir="out">
2082 <desc>Dhcp server settings</desc>
2083 </param>
2084 </method-->
2085
2086 <method name="createDHCPServer">
2087 <desc>
2088 Creates a dhcp server settings to be used for the given internal network name
2089 <result name="E_INVALIDARG">
2090 Host network interface @a name already exists.
2091 </result>
2092 </desc>
2093 <param name="name" type="wstring" dir="in">
2094 <desc>server name</desc>
2095 </param>
2096 <param name="server" type="IDHCPServer" dir="return">
2097 <desc>Dhcp server settings</desc>
2098 </param>
2099 </method>
2100
2101 <method name="findDHCPServerByNetworkName">
2102 <desc>
2103 Searches a dhcp server settings to be used for the given internal network name
2104 <result name="E_INVALIDARG">
2105 Host network interface @a name already exists.
2106 </result>
2107
2108 </desc>
2109 <param name="name" type="wstring" dir="in">
2110 <desc>server name</desc>
2111 </param>
2112 <param name="server" type="IDHCPServer" dir="return">
2113 <desc>Dhcp server settings</desc>
2114 </param>
2115 </method>
2116
2117 <!--method name="findDHCPServerForInterface">
2118 <desc>
2119 Searches a dhcp server settings to be used for the given interface
2120 <result name="E_INVALIDARG">
2121 Host network interface @a name already exists.
2122 </result>
2123 </desc>
2124 <param name="interface" type="IHostNetworkInterface" dir="in">
2125 <desc>Network Interface</desc>
2126 </param>
2127 <param name="server" type="IDHCPServer" dir="out">
2128 <desc>Dhcp server settings</desc>
2129 </param>
2130 </method-->
2131
2132 <method name="removeDHCPServer">
2133 <desc>
2134 Removes the dhcp server settings
2135 <result name="E_INVALIDARG">
2136 Host network interface @a name already exists.
2137 </result>
2138 </desc>
2139 <param name="server" type="IDHCPServer" dir="in">
2140 <desc>Dhcp server settings to be removed</desc>
2141 </param>
2142 </method>
2143
2144
2145 <method name="checkFirmwarePresent">
2146 <desc>
2147 Check if this VirtualBox installation has a firmware
2148 of the given type available, either system-wide or per-user.
2149 Optionally, this may return a hint where this firmware can be
2150 downloaded from.
2151 </desc>
2152 <param name="firmwareType" type="FirmwareType" dir="in">
2153 <desc>
2154 Type of firmware to check.
2155 </desc>
2156 </param>
2157 <param name="version" type="wstring" dir="in">
2158 <desc>Expected version number, usually empty string (presently ignored).</desc>
2159 </param>
2160
2161 <param name="url" type="wstring" dir="out">
2162 <desc>
2163 Suggested URL to download this firmware from.
2164 </desc>
2165 </param>
2166
2167 <param name="file" type="wstring" dir="out">
2168 <desc>
2169 Filename of firmware, only valid if result == TRUE.
2170 </desc>
2171 </param>
2172
2173 <param name="result" type="boolean" dir="return">
2174 <desc>If firmware of this type and version is available.</desc>
2175 </param>
2176 </method>
2177
2178 </interface>
2179
2180 <!--
2181 // IVFSExplorer
2182 /////////////////////////////////////////////////////////////////////////
2183 -->
2184
2185 <enum
2186 name="VFSType"
2187 uuid="813999ba-b949-48a8-9230-aadc6285e2f2"
2188 >
2189 <desc>
2190 Virtual file systems supported by VFSExplorer.
2191 </desc>
2192
2193 <const name="File" value="1" />
2194 <const name="Cloud" value="2" />
2195 <const name="S3" value="3" />
2196 <const name="WebDav" value="4" />
2197 </enum>
2198
2199 <enum
2200 name="VFSFileType"
2201 uuid="714333cd-44e2-415f-a245-d378fa9b1242"
2202 >
2203 <desc>
2204 File types known by VFSExplorer.
2205 </desc>
2206
2207 <const name="Unknown" value="1" />
2208 <const name="Fifo" value="2" />
2209 <const name="DevChar" value="3" />
2210 <const name="Directory" value="4" />
2211 <const name="DevBlock" value="5" />
2212 <const name="File" value="6" />
2213 <const name="SymLink" value="7" />
2214 <const name="Socket" value="8" />
2215 <const name="WhiteOut" value="9" />
2216 </enum>
2217
2218 <interface
2219 name="IVFSExplorer" extends="$unknown"
2220 uuid="2bb864a1-02a3-4474-a1d4-fb5f23b742e1"
2221 wsmap="managed"
2222 >
2223 <desc>
2224 The VFSExplorer interface unifies access to different file system
2225 types. This includes local file systems as well remote file systems like
2226 S3. For a list of supported types see <link to="VFSType" />.
2227 An instance of this is returned by <link to="IAppliance::createVFSExplorer" />.
2228 </desc>
2229
2230 <attribute name="path" type="wstring" readonly="yes">
2231 <desc>Returns the current path in the virtual file system.</desc>
2232 </attribute>
2233
2234 <attribute name="type" type="VFSType" readonly="yes">
2235 <desc>Returns the file system type which is currently in use.</desc>
2236 </attribute>
2237
2238 <method name="update">
2239 <desc>Updates the internal list of files/directories from the
2240 current directory level. Use <link to="#entryList" /> to get the full list
2241 after a call to this method.</desc>
2242
2243 <param name="aProgress" type="IProgress" dir="return">
2244 <desc>Progress object to track the operation completion.</desc>
2245 </param>
2246 </method>
2247
2248 <method name="cd">
2249 <desc>Change the current directory level.</desc>
2250
2251 <param name="aDir" type="wstring" dir="in">
2252 <desc>The name of the directory to go in.</desc>
2253 </param>
2254
2255 <param name="aProgress" type="IProgress" dir="return">
2256 <desc>Progress object to track the operation completion.</desc>
2257 </param>
2258 </method>
2259
2260 <method name="cdUp">
2261 <desc>Go one directory upwards from the current directory level.</desc>
2262
2263 <param name="aProgress" type="IProgress" dir="return">
2264 <desc>Progress object to track the operation completion.</desc>
2265 </param>
2266 </method>
2267
2268 <method name="entryList">
2269 <desc>Returns a list of files/directories after a call to <link
2270 to="#update" />. The user is responsible for keeping this internal
2271 list up do date.</desc>
2272
2273 <param name="aNames" type="wstring" safearray="yes" dir="out">
2274 <desc>The list of names for the entries.</desc>
2275 </param>
2276
2277 <param name="aTypes" type="unsigned long" safearray="yes" dir="out">
2278 <desc>The list of types for the entries.</desc>
2279 </param>
2280 </method>
2281
2282 <method name="exists">
2283 <desc>Checks if the given file list exists in the current directory
2284 level.</desc>
2285
2286 <param name="aNames" type="wstring" safearray="yes" dir="in">
2287 <desc>The names to check.</desc>
2288 </param>
2289
2290 <param name="aExists" type="wstring" safearray="yes" dir="return">
2291 <desc>The names which exist.</desc>
2292 </param>
2293 </method>
2294
2295 <method name="remove">
2296 <desc>Deletes the given files in the current directory level.</desc>
2297
2298 <param name="aNames" type="wstring" safearray="yes" dir="in">
2299 <desc>The names to remove.</desc>
2300 </param>
2301
2302 <param name="aProgress" type="IProgress" dir="return">
2303 <desc>Progress object to track the operation completion.</desc>
2304 </param>
2305 </method>
2306
2307 </interface>
2308
2309 <!--
2310 // IAppliance
2311 /////////////////////////////////////////////////////////////////////////
2312 -->
2313
2314 <interface
2315 name="IAppliance" extends="$unknown"
2316 uuid="7b148032-4124-4f46-b56a-b48ac1273f5a"
2317 wsmap="managed"
2318 >
2319 <desc>
2320 Represents a platform-independent appliance in OVF format. An instance of this is returned
2321 by <link to="IVirtualBox::createAppliance" />, which can then be used to import and export
2322 virtual machines within an appliance with VirtualBox.
2323
2324 The OVF standard suggests two different physical file formats:
2325
2326 <ol>
2327 <li>If the appliance is distributed as a set of files, there must be at least one XML descriptor
2328 file that conforms to the OVF standard and carries an <tt>.ovf</tt> file extension. If
2329 this descriptor file references other files such as disk images, as OVF appliances typically
2330 do, those additional files must be in the same directory as the descriptor file.</li>
2331
2332 <li>If the appliance is distributed as a single file, it must be in TAR format and have the
2333 <tt>.ova</tt> file extension. This TAR file must then contain at least the OVF descriptor
2334 files and optionally other files.
2335
2336 At this time, VirtualBox does not not yet support the packed (TAR) variant; support will
2337 be added with a later version.</li>
2338 </ol>
2339
2340 <b>Importing</b> an OVF appliance into VirtualBox as instances of
2341 <link to="IMachine" /> involves the following sequence of API calls:
2342
2343 <ol>
2344 <li>Call <link to="IVirtualBox::createAppliance" />. This will create an empty IAppliance object.
2345 </li>
2346
2347 <li>On the new object, call <link to="#read" /> with the full path of the OVF file you
2348 would like to import. So long as this file is syntactically valid, this will succeed
2349 and fill the appliance object with the parsed data from the OVF file.
2350 </li>
2351
2352 <li>Next, call <link to="#interpret" />, which analyzes the OVF data and sets up the
2353 contents of the IAppliance attributes accordingly. These can be inspected by a
2354 VirtualBox front-end such as the GUI, and the suggestions can be displayed to the
2355 user. In particular, the <link to="#virtualSystemDescriptions" /> array contains
2356 instances of <link to="IVirtualSystemDescription" /> which represent the virtual
2357 systems (machines) in the OVF, which in turn describe the virtual hardware prescribed
2358 by the OVF (network and hardware adapters, virtual disk images, memory size and so on).
2359 The GUI can then give the user the option to confirm and/or change these suggestions.
2360 </li>
2361
2362 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
2363 virtual system (machine) to override the suggestions made by the interpret() routine.
2364 </li>
2365
2366 <li>Finally, call <link to="#importMachines" /> to create virtual machines in
2367 VirtualBox as instances of <link to="IMachine" /> that match the information in the
2368 virtual system descriptions. After this call suceeded, the UUIDs of the machines created
2369 can be found in the <link to="#machines" /> array attribute.
2370 </li>
2371 </ol>
2372
2373 <b>Exporting</b> VirtualBox machines into an OVF appliance involves the following steps:
2374
2375 <ol>
2376 <li>As with importing, first call <link to="IVirtualBox::createAppliance" /> to create
2377 an empty IAppliance object.
2378 </li>
2379
2380 <li>For each machine you would like to export, call <link to="IMachine::export" />
2381 with the IAppliance object you just created. Each such call creates one instance of
2382 <link to="IVirtualSystemDescription" /> inside the appliance.
2383 </li>
2384
2385 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
2386 virtual system (machine) to override the suggestions made by the export() routine.
2387 </li>
2388
2389 <li>Finally, call <link to="#write" /> with a path specification to have the OVF
2390 file written.</li>
2391 </ol>
2392
2393 </desc>
2394
2395 <attribute name="path" type="wstring" readonly="yes">
2396 <desc>Path to the main file of the OVF appliance, which is either the <tt>.ovf</tt> or
2397 the <tt>.ova</tt> file passed to <link to="#read" /> (for import) or
2398 <link to="#write" /> (for export).
2399 This attribute is empty until one of these methods has been called.
2400 </desc>
2401 </attribute>
2402
2403 <attribute name="disks" type="wstring" readonly="yes" safearray="yes">
2404 <desc>
2405 Array of virtual disk definitions. One such description exists for each
2406 disk definition in the OVF; each string array item represents one such piece of
2407 disk information, with the information fields separated by tab (\t) characters.
2408
2409 The caller should be prepared for additional fields being appended to
2410 this string in future versions of VirtualBox and therefore check for
2411 the number of tabs in the strings returned.
2412
2413 In the current version, the following eight fields are returned per string
2414 in the array:
2415
2416 <ol>
2417 <li>Disk ID (unique string identifier given to disk)</li>
2418
2419 <li>Capacity (unsigned integer indicating the maximum capacity of the disk)</li>
2420
2421 <li>Populated size (optional unsigned integer indicating the current size of the
2422 disk; can be approximate; -1 if unspecified)</li>
2423
2424 <li>Format (string identifying the disk format, typically
2425 "http://www.vmware.com/specifications/vmdk.html#sparse")</li>
2426
2427 <li>Reference (where to find the disk image, typically a file name; if empty,
2428 then the disk should be created on import)</li>
2429
2430 <li>Image size (optional unsigned integer indicating the size of the image,
2431 which need not necessarily be the same as the values specified above, since
2432 the image may be compressed or sparse; -1 if not specified)</li>
2433
2434 <li>Chunk size (optional unsigned integer if the image is split into chunks;
2435 presently unsupported and always -1)</li>
2436
2437 <li>Compression (optional string equalling "gzip" if the image is gzip-compressed)</li>
2438 </ol>
2439 </desc>
2440 </attribute>
2441
2442 <attribute name="virtualSystemDescriptions" type="IVirtualSystemDescription" readonly="yes" safearray="yes">
2443 <desc> Array of virtual system descriptions. One such description is created
2444 for each virtual system (machine) found in the OVF.
2445 This array is empty until either <link to="#interpret" /> (for import) or <link to="IMachine::export" />
2446 (for export) has been called.
2447 </desc>
2448 </attribute>
2449
2450 <attribute name="machines" type="wstring" readonly="yes" safearray="yes">
2451 <desc>
2452 Contains the UUIDs of the machines created from the information in this appliances. This is only
2453 relevant for the import case, and will only contain data after a call to <link to="#importMachines" />
2454 succeeded.
2455 </desc>
2456 </attribute>
2457
2458 <method name="read">
2459 <desc>
2460 Reads an OVF file into the appliance object.
2461
2462 This method succeeds if the OVF is syntactically valid and, by itself, without errors. The
2463 mere fact that this method returns successfully does not mean that VirtualBox supports all
2464 features requested by the appliance; this can only be examined after a call to <link to="#interpret" />.
2465 </desc>
2466 <param name="file" type="wstring" dir="in">
2467 <desc>
2468 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
2469 on whether the appliance is distributed as a set of files or as a single file, respectively).
2470 </desc>
2471 </param>
2472 <param name="aProgress" type="IProgress" dir="return">
2473 <desc>Progress object to track the operation completion.</desc>
2474 </param>
2475 </method>
2476
2477 <method name="interpret">
2478 <desc>
2479 Interprets the OVF data that was read when the appliance was constructed. After
2480 calling this method, one can inspect the
2481 <link to="#virtualSystemDescriptions" /> array attribute, which will then contain
2482 one <link to="IVirtualSystemDescription" /> for each virtual machine found in
2483 the appliance.
2484
2485 Calling this method is the second step of importing an appliance into VirtualBox;
2486 see <link to="IAppliance" /> for an overview.
2487
2488 After calling this method, one should call <link to="#getWarnings" /> to find out
2489 if problems were encountered during the processing which might later lead to
2490 errors.
2491 </desc>
2492 </method>
2493
2494 <method name="importMachines">
2495 <desc>
2496 Imports the appliance into VirtualBox by creating instances of <link to="IMachine" />
2497 and other interfaces that match the information contained in the appliance as
2498 closely as possible, as represented by the import instructions in the
2499 <link to="#virtualSystemDescriptions" /> array.
2500
2501 Calling this method is the final step of importing an appliance into VirtualBox;
2502 see <link to="IAppliance" /> for an overview.
2503
2504 Since importing the appliance will most probably involve copying and converting
2505 disk images, which can take a long time, this method operates asynchronously and
2506 returns an IProgress object to allow the caller to monitor the progress.
2507
2508 After the import succeeded, the UUIDs of the IMachine instances created can be
2509 retrieved from the <link to="#machines" /> array attribute.
2510 </desc>
2511
2512 <param name="aProgress" type="IProgress" dir="return">
2513 <desc>Progress object to track the operation completion.</desc>
2514 </param>
2515 </method>
2516
2517 <method name="createVFSExplorer">
2518 <desc>Returns a <link to="IVFSExplorer" /> object for the given URI.</desc>
2519
2520 <param name="aUri" type="wstring" dir="in">
2521 <desc>The URI describing the file system to use.</desc>
2522 </param>
2523
2524 <param name="aExplorer" type="IVFSExplorer" dir="return">
2525 <desc></desc>
2526 </param>
2527 </method>
2528
2529 <method name="write">
2530 <desc>
2531 Writes the contents of the appliance exports into a new OVF file.
2532
2533 Calling this method is the final step of exporting an appliance from VirtualBox;
2534 see <link to="IAppliance" /> for an overview.
2535
2536 Since exporting the appliance will most probably involve copying and converting
2537 disk images, which can take a long time, this method operates asynchronously and
2538 returns an IProgress object to allow the caller to monitor the progress.
2539 </desc>
2540 <param name="format" type="wstring" dir="in">
2541 <desc>
2542 Output format, as a string. Currently supported formats are "ovf-0.9" and "ovf-1.0";
2543 future versions of VirtualBox may support additional formats.
2544 </desc>
2545 </param>
2546 <param name="manifest" type="boolean" dir="in">
2547 <desc>
2548 Indicate if the optional manifest file (.mf) should be written. The manifest file
2549 is used for integrity checks prior import.
2550 </desc>
2551 </param>
2552 <param name="path" type="wstring" dir="in">
2553 <desc>
2554 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
2555 on whether the appliance is distributed as a set of files or as a single file, respectively).
2556 </desc>
2557 </param>
2558 <param name="progress" type="IProgress" dir="return">
2559 <desc>Progress object to track the operation completion.</desc>
2560 </param>
2561 </method>
2562
2563 <method name="getWarnings">
2564 <desc>Returns textual warnings which occurred during execution of <link to="#interpret" />.</desc>
2565
2566 <param name="aWarnings" type="wstring" dir="return" safearray="yes">
2567 <desc></desc>
2568 </param>
2569 </method>
2570
2571 </interface>
2572
2573 <enum
2574 name="VirtualSystemDescriptionType"
2575 uuid="c0f8f135-3a1d-417d-afa6-b38b95a91f90"
2576 >
2577 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of
2578 a configuration value.</desc>
2579
2580 <const name="Ignore" value="1" />
2581 <const name="OS" value="2" />
2582 <const name="Name" value="3" />
2583 <const name="Product" value="4" />
2584 <const name="Vendor" value="5" />
2585 <const name="Version" value="6" />
2586 <const name="ProductUrl" value="7" />
2587 <const name="VendorUrl" value="8" />
2588 <const name="Description" value="9" />
2589 <const name="License" value="10" />
2590 <const name="Miscellaneous" value="11" />
2591 <const name="CPU" value="12" />
2592 <const name="Memory" value="13" />
2593 <const name="HardDiskControllerIDE" value="14" />
2594 <const name="HardDiskControllerSATA" value="15" />
2595 <const name="HardDiskControllerSCSI" value="16" />
2596 <const name="HardDiskControllerSAS" value="17" />
2597 <const name="HardDiskImage" value="18" />
2598 <const name="Floppy" value="19" />
2599 <const name="CDROM" value="20" />
2600 <const name="NetworkAdapter" value="21" />
2601 <const name="USBController" value="22" />
2602 <const name="SoundCard" value="23" />
2603
2604 </enum>
2605
2606 <enum
2607 name="VirtualSystemDescriptionValueType"
2608 uuid="56d9403f-3425-4118-9919-36f2a9b8c77c"
2609 >
2610 <desc>Used with <link to="IVirtualSystemDescription::getValuesByType" /> to describe the value
2611 type to fetch.</desc>
2612
2613 <const name="Reference" value="1" />
2614 <const name="Original" value="2" />
2615 <const name="Auto" value="3" />
2616 <const name="ExtraConfig" value="4" />
2617
2618 </enum>
2619
2620 <interface
2621 name="IVirtualSystemDescription" extends="$unknown"
2622 uuid="d7525e6c-531a-4c51-8e04-41235083a3d8"
2623 wsmap="managed"
2624 >
2625
2626 <desc>Represents one virtual system (machine) in an appliance. This interface is used in
2627 the <link to="IAppliance::virtualSystemDescriptions" /> array. After
2628 <link to="IAppliance::interpret" /> has been called, that array contains information
2629 about how the virtual systems described in the OVF should best be imported into
2630 VirtualBox virtual machines. See <link to="IAppliance" /> for the steps required to
2631 import an OVF into VirtualBox.
2632 </desc>
2633
2634 <attribute name="count" type="unsigned long" readonly="yes">
2635 <desc>Return the number of virtual system description entries.</desc>
2636 </attribute>
2637
2638 <method name="getDescription">
2639 <desc>Returns information about the virtual system as arrays of instruction items. In each array, the
2640 items with the same indices correspond and jointly represent an import instruction for VirtualBox.
2641
2642 The list below identifies the value sets that are possible depending on the
2643 <link to="VirtualSystemDescriptionType" /> enum value in the array item in @a aTypes[]. In each case,
2644 the array item with the same index in @a aOvfValues[] will contain the original value as contained
2645 in the OVF file (just for informational purposes), and the corresponding item in @a aVBoxValues[]
2646 will contain a suggested value to be used for VirtualBox. Depending on the description type,
2647 the @a aExtraConfigValues[] array item may also be used.
2648
2649 <ul>
2650 <li>
2651 "OS": the guest operating system type. There must be exactly one such array item on import. The
2652 corresponding item in @a aVBoxValues[] contains the suggested guest operating system for VirtualBox.
2653 This will be one of the values listed in <link to="IVirtualBox::guestOSTypes" />. The corresponding
2654 item in @a aOvfValues[] will contain a numerical value that described the operating system in the OVF.
2655 </li>
2656 <li>
2657 "Name": the name to give to the new virtual machine. There can be at most one such array item;
2658 if none is present on import, then an automatic name will be created from the operating system
2659 type. The correponding item im @a aOvfValues[] will contain the suggested virtual machine name
2660 from the OVF file, and @a aVBoxValues[] will contain a suggestion for a unique VirtualBox
2661 <link to="IMachine" /> name that does not exist yet.
2662 </li>
2663 <li>
2664 "Description": an arbitrary description.
2665 </li>
2666 <li>
2667 "License": the EULA section from the OVF, if present. It is the responsibility of the calling
2668 code to display such a license for agreement; the Main API does not enforce any such policy.
2669 </li>
2670 <li>
2671 Miscellaneous: reserved for future use.
2672 </li>
2673 <li>
2674 "CPU": the number of CPUs. There can be at most one such item, which will presently be ignored.
2675 </li>
2676 <li>
2677 "Memory": the amount of guest RAM, in bytes. There can be at most one such array item; if none
2678 is present on import, then VirtualBox will set a meaningful default based on the operating system
2679 type.
2680 </li>
2681 <li>
2682 "HardDiskControllerIDE": an IDE hard disk controller. There can be at most two such items.
2683 An optional value in @a aOvfValues[] and @a aVBoxValues[] can be "PIIX3" or "PIIX4" to specify
2684 the type of IDE controller; this corresponds to the ResourceSubType element which VirtualBox
2685 writes into the OVF.
2686 The matching item in the @a aRefs[] array will contain an integer that items of the "Harddisk"
2687 type can use to specify which hard disk controller a virtual disk should be connected to.
2688 Note that in OVF, an IDE controller has two channels, corresponding to "master" and "slave"
2689 in traditional terminology, whereas the IDE storage controller that VirtualBox supports in
2690 its virtual machines supports four channels (primary master, primary slave, secondary master,
2691 secondary slave) and thus maps to two IDE controllers in the OVF sense.
2692 </li>
2693 <li>
2694 "HardDiskControllerSATA": an SATA hard disk controller. There can be at most one such item. This
2695 has no value in @a aOvfValues[] or @a aVBoxValues[].
2696 The matching item in the @a aRefs[] array will be used as with IDE controllers (see above).
2697 </li>
2698 <li>
2699 "HardDiskControllerSCSI": a SCSI hard disk controller. There can be at most one such item.
2700 The items in @a aOvfValues[] and @a aVBoxValues[] will either be "LsiLogic", "BusLogic" or
2701 "LsiLogicSas". (Note that in OVF, the LsiLogicSas controller is treated as a SCSI controller
2702 whereas VirtualBox considers it a class of storage controllers of its own; see
2703 <link to="StorageControllerType" />).
2704 The matching item in the @a aRefs[] array will be used as with IDE controllers (see above).
2705 </li>
2706 <li>
2707 "HardDiskImage": a virtual hard disk, most probably as a reference to an image file. There can be an
2708 arbitrary number of these items, one for each virtual disk image that accompanies the OVF.
2709
2710 The array item in @a aOvfValues[] will contain the file specification from the OVF file (without
2711 a path since the image file should be in the same location as the OVF file itself), whereas the
2712 item in @a aVBoxValues[] will contain a qualified path specification to where VirtualBox uses the
2713 hard disk image. This means that on import the image will be copied and converted from the
2714 "ovf" location to the "vbox" location; on export, this will be handled the other way round.
2715
2716 The matching item in the @a aExtraConfigValues[] array must contain a string of the following
2717 format: "controller=&lt;index&gt;;channel=&lt;c&gt;"
2718 In this string, &lt;index&gt; must be an integer specifying the hard disk controller to connect
2719 the image to. That number must be the index of an array item with one of the hard disk controller
2720 types (HardDiskControllerSCSI, HardDiskControllerSATA, HardDiskControllerIDE).
2721 In addition, &lt;c&gt; must specify the channel to use on that controller. For IDE controllers,
2722 this can be 0 or 1 for master or slave, respectively. For compatibility with VirtualBox versions
2723 before 3.2, the values 2 and 3 (for secondary master and secondary slave) are also supported, but
2724 no longer exported. For SATA and SCSI controllers, the channel can range from 0-29.
2725 </li>
2726 <li>
2727 "CDROM": a virtual CD-ROM drive. The matching item in @a aExtraConfigValue[] contains the same
2728 attachment information as with "HardDiskImage" items.
2729 </li>
2730 <li>
2731 "CDROM": a virtual floppy drive. The matching item in @a aExtraConfigValue[] contains the same
2732 attachment information as with "HardDiskImage" items.
2733 </li>
2734 <li>
2735 "NetworkAdapter": a network adapter. The array item in @a aVBoxValues[] will specify the hardware
2736 for the network adapter, whereas the array item in @a aExtraConfigValues[] will have a string
2737 of the "type=&lt;X&gt;" format, where &lt;X&gt; must be either "NAT" or "Bridged".
2738 </li>
2739 <li>
2740 "USBController": a USB controller. There can be at most one such item. If and only if such an
2741 item ispresent, USB support will be enabled for the new virtual machine.
2742 </li>
2743 <li>
2744 "SoundCard": a sound card. There can be at most one such item. If and only if such an item is
2745 present, sound support will be enabled for the new virtual machine. Note that the virtual
2746 machine in VirtualBox will always be presented with the standard VirtualBox soundcard, which
2747 may be different from the virtual soundcard expected by the appliance.
2748 </li>
2749 </ul>
2750
2751 </desc>
2752
2753 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
2754 <desc></desc>
2755 </param>
2756
2757 <param name="aRefs" type="wstring" dir="out" safearray="yes">
2758 <desc></desc>
2759 </param>
2760
2761 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
2762 <desc></desc>
2763 </param>
2764
2765 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
2766 <desc></desc>
2767 </param>
2768
2769 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
2770 <desc></desc>
2771 </param>
2772
2773 </method>
2774
2775 <method name="getDescriptionByType">
2776 <desc>This is the same as <link to="#getDescription" /> except that you can specify which types
2777 should be returned.</desc>
2778
2779 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
2780 <desc></desc>
2781 </param>
2782
2783 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
2784 <desc></desc>
2785 </param>
2786
2787 <param name="aRefs" type="wstring" dir="out" safearray="yes">
2788 <desc></desc>
2789 </param>
2790
2791 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
2792 <desc></desc>
2793 </param>
2794
2795 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
2796 <desc></desc>
2797 </param>
2798
2799 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
2800 <desc></desc>
2801 </param>
2802
2803 </method>
2804
2805 <method name="getValuesByType">
2806 <desc>This is the same as <link to="#getDescriptionByType" /> except that you can specify which
2807 value types should be returned. See <link to="VirtualSystemDescriptionValueType" /> for possible
2808 values.</desc>
2809
2810 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
2811 <desc></desc>
2812 </param>
2813
2814 <param name="aWhich" type="VirtualSystemDescriptionValueType" dir="in">
2815 <desc></desc>
2816 </param>
2817
2818 <param name="aValues" type="wstring" dir="return" safearray="yes">
2819 <desc></desc>
2820 </param>
2821
2822 </method>
2823
2824 <method name="setFinalValues">
2825 <desc>
2826 This method allows the appliance's user to change the configuration for the virtual
2827 system descriptions. For each array item returned from <link to="#getDescription" />,
2828 you must pass in one boolean value and one configuration value.
2829
2830 Each item in the boolean array determines whether the particular configuration item
2831 should be enabled.
2832 You can only disable items of the types HardDiskControllerIDE, HardDiskControllerSATA,
2833 HardDiskControllerSCSI, HardDiskImage, CDROM, Floppy, NetworkAdapter, USBController
2834 and SoundCard.
2835
2836 For the "vbox" and "extra configuration" values, if you pass in the same arrays
2837 as returned in the aVBoxValues and aExtraConfigValues arrays from getDescription(),
2838 the configuration remains unchanged. Please see the documentation for getDescription()
2839 for valid configuration values for the individual array item types. If the
2840 corresponding item in the aEnabled array is @c false, the configuration value is ignored.
2841 </desc>
2842
2843 <param name="aEnabled" type="boolean" dir="in" safearray="yes">
2844 <desc></desc>
2845 </param>
2846
2847 <param name="aVBoxValues" type="wstring" dir="in" safearray="yes">
2848 <desc></desc>
2849 </param>
2850
2851 <param name="aExtraConfigValues" type="wstring" dir="in" safearray="yes">
2852 <desc></desc>
2853 </param>
2854 </method>
2855
2856 <method name="addDescription">
2857 <desc>
2858 This method adds an additional description entry to the stack of already
2859 available descriptions for this virtual system. This is handy for writing
2860 values which aren't directly supported by VirtualBox. One example would
2861 be the License type of <link to="VirtualSystemDescriptionType" />.
2862 </desc>
2863
2864 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
2865 <desc></desc>
2866 </param>
2867
2868 <param name="aVBoxValue" type="wstring" dir="in">
2869 <desc></desc>
2870 </param>
2871
2872 <param name="aExtraConfigValue" type="wstring" dir="in">
2873 <desc></desc>
2874 </param>
2875 </method>
2876 </interface>
2877
2878
2879 <!--
2880 // IMachine
2881 /////////////////////////////////////////////////////////////////////////
2882 -->
2883
2884 <interface
2885 name="IInternalMachineControl" extends="$unknown"
2886 uuid="e2da8b1a-2ad1-490e-b29e-c33a144791b6"
2887 internal="yes"
2888 wsmap="suppress"
2889 >
2890 <method name="setRemoveSavedStateFile">
2891 <desc>
2892 Updates the flag whether the saved state file is removed on a
2893 machine state change from Saved to PoweredOff.
2894 </desc>
2895 <param name="aRemove" type="boolean" dir="in"/>
2896 </method>
2897
2898 <method name="updateState">
2899 <desc>
2900 Updates the VM state.
2901 <note>
2902 This operation will also update the settings file with the correct
2903 information about the saved state file and delete this file from disk
2904 when appropriate.
2905 </note>
2906 </desc>
2907 <param name="state" type="MachineState" dir="in"/>
2908 </method>
2909
2910 <method name="getIPCId">
2911 <param name="id" type="wstring" dir="return"/>
2912 </method>
2913
2914 <method name="beginPowerUp">
2915 <desc>
2916 Tells VBoxSVC that <link to="IConsole::powerUp"/> is under ways and
2917 gives it the progress object that should be part of any pending
2918 <link to="IMachine::launchVMProcess"/> operations. The progress
2919 object may be called back to reflect an early cancelation, so some care
2920 have to be taken with respect to any cancelation callbacks. The console
2921 object will call <link to="IInternalMachineControl::endPowerUp"/>
2922 to signal the completion of the progress object.
2923 </desc>
2924 <param name="aProgress" type="IProgress" dir="in" />
2925 </method>
2926
2927 <method name="endPowerUp">
2928 <desc>
2929 Tells VBoxSVC that <link to="IConsole::powerUp"/> has completed.
2930 This method may query status information from the progress object it
2931 received in <link to="IInternalMachineControl::beginPowerUp"/> and copy
2932 it over to any in-progress <link to="IMachine::launchVMProcess"/>
2933 call in order to complete that progress object.
2934 </desc>
2935 <param name="result" type="long" dir="in"/>
2936 </method>
2937
2938 <method name="runUSBDeviceFilters">
2939 <desc>
2940 Asks the server to run USB devices filters of the associated
2941 machine against the given USB device and tell if there is
2942 a match.
2943 <note>
2944 Intended to be used only for remote USB devices. Local
2945 ones don't require to call this method (this is done
2946 implicitly by the Host and USBProxyService).
2947 </note>
2948 </desc>
2949 <param name="device" type="IUSBDevice" dir="in"/>
2950 <param name="matched" type="boolean" dir="out"/>
2951 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
2952 </method>
2953
2954 <method name="captureUSBDevice">
2955 <desc>
2956 Requests a capture of the given host USB device.
2957 When the request is completed, the VM process will
2958 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
2959 notification.
2960 </desc>
2961 <param name="id" type="uuid" mod="string" dir="in"/>
2962 </method>
2963
2964 <method name="detachUSBDevice">
2965 <desc>
2966 Notification that a VM is going to detach (@a done = @c false) or has
2967 already detached (@a done = @c true) the given USB device.
2968 When the @a done = @c true request is completed, the VM process will
2969 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
2970 notification.
2971 <note>
2972 In the @a done = @c true case, the server must run its own filters
2973 and filters of all VMs but this one on the detached device
2974 as if it were just attached to the host computer.
2975 </note>
2976 </desc>
2977 <param name="id" type="uuid" mod="string" dir="in"/>
2978 <param name="done" type="boolean" dir="in"/>
2979 </method>
2980
2981 <method name="autoCaptureUSBDevices">
2982 <desc>
2983 Requests a capture all matching USB devices attached to the host.
2984 When the request is completed, the VM process will
2985 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
2986 notification per every captured device.
2987 </desc>
2988 </method>
2989
2990 <method name="detachAllUSBDevices">
2991 <desc>
2992 Notification that a VM that is being powered down. The done
2993 parameter indicates whether which stage of the power down
2994 we're at. When @a done = @c false the VM is announcing its
2995 intentions, while when @a done = @c true the VM is reporting
2996 what it has done.
2997 <note>
2998 In the @a done = @c true case, the server must run its own filters
2999 and filters of all VMs but this one on all detach devices as
3000 if they were just attached to the host computer.
3001 </note>
3002 </desc>
3003 <param name="done" type="boolean" dir="in"/>
3004 </method>
3005
3006 <method name="onSessionEnd">
3007 <desc>
3008 Triggered by the given session object when the session is about
3009 to close normally.
3010 </desc>
3011 <param name="session" type="ISession" dir="in">
3012 <desc>Session that is being closed</desc>
3013 </param>
3014 <param name="progress" type="IProgress" dir="return">
3015 <desc>
3016 Used to wait until the corresponding machine is actually
3017 dissociated from the given session on the server.
3018 Returned only when this session is a direct one.
3019 </desc>
3020 </param>
3021 </method>
3022
3023 <method name="beginSavingState">
3024 <desc>
3025 Called by the VM process to inform the server it wants to
3026 save the current state and stop the VM execution.
3027 </desc>
3028 <param name="progress" type="IProgress" dir="in">
3029 <desc>
3030 Progress object created by the VM process to wait until
3031 the state is saved.
3032 </desc>
3033 </param>
3034 <param name="stateFilePath" type="wstring" dir="out">
3035 <desc>
3036 File path the VM process must save the execution state to.
3037 </desc>
3038 </param>
3039 </method>
3040
3041 <method name="endSavingState">
3042 <desc>
3043 Called by the VM process to inform the server that saving
3044 the state previously requested by #beginSavingState is either
3045 successfully finished or there was a failure.
3046
3047 <result name="VBOX_E_FILE_ERROR">
3048 Settings file not accessible.
3049 </result>
3050 <result name="VBOX_E_XML_ERROR">
3051 Could not parse the settings file.
3052 </result>
3053
3054 </desc>
3055
3056 <param name="success" type="boolean" dir="in">
3057 <desc>@c true to indicate success and @c false otherwise.
3058 </desc>
3059 </param>
3060 </method>
3061
3062 <method name="adoptSavedState">
3063 <desc>
3064 Gets called by IConsole::adoptSavedState.
3065 <result name="VBOX_E_FILE_ERROR">
3066 Invalid saved state file path.
3067 </result>
3068 </desc>
3069 <param name="savedStateFile" type="wstring" dir="in">
3070 <desc>Path to the saved state file to adopt.</desc>
3071 </param>
3072 </method>
3073
3074 <method name="beginTakingSnapshot">
3075 <desc>
3076 Called from the VM process to request from the server to perform the
3077 server-side actions of creating a snapshot (creating differencing images
3078 and the snapshot object).
3079
3080 <result name="VBOX_E_FILE_ERROR">
3081 Settings file not accessible.
3082 </result>
3083 <result name="VBOX_E_XML_ERROR">
3084 Could not parse the settings file.
3085 </result>
3086 </desc>
3087 <param name="initiator" type="IConsole" dir="in">
3088 <desc>The console object that initiated this call.</desc>
3089 </param>
3090 <param name="name" type="wstring" dir="in">
3091 <desc>Snapshot name.</desc>
3092 </param>
3093 <param name="description" type="wstring" dir="in">
3094 <desc>Snapshot description.</desc>
3095 </param>
3096 <param name="consoleProgress" type="IProgress" dir="in">
3097 <desc>
3098 Progress object created by the VM process tracking the
3099 snapshot's progress. This has the following sub-operations:
3100 <ul>
3101 <li>setting up (weight 1);</li>
3102 <li>one for each medium attachment that needs a differencing image (weight 1 each);</li>
3103 <li>another one to copy the VM state (if offline with saved state, weight is VM memory size in MB);</li>
3104 <li>another one to save the VM state (if online, weight is VM memory size in MB);</li>
3105 <li>finishing up (weight 1)</li>
3106 </ul>
3107 </desc>
3108 </param>
3109 <param name="fTakingSnapshotOnline" type="boolean" dir="in">
3110 <desc>
3111 Whether this is an online snapshot (i.e. the machine is running).
3112 </desc>
3113 </param>
3114 <param name="stateFilePath" type="wstring" dir="out">
3115 <desc>
3116 File path the VM process must save the execution state to.
3117 </desc>
3118 </param>
3119 </method>
3120
3121 <method name="endTakingSnapshot">
3122 <desc>
3123 Called by the VM process to inform the server that the snapshot
3124 previously requested by #beginTakingSnapshot is either
3125 successfully taken or there was a failure.
3126 </desc>
3127
3128 <param name="success" type="boolean" dir="in">
3129 <desc>@c true to indicate success and @c false otherwise</desc>
3130 </param>
3131 </method>
3132
3133 <method name="deleteSnapshot">
3134 <desc>
3135 Gets called by IConsole::deleteSnapshot.
3136 <result name="VBOX_E_INVALID_OBJECT_STATE">
3137 Snapshot has more than one child snapshot.
3138 </result>
3139 </desc>
3140 <param name="initiator" type="IConsole" dir="in">
3141 <desc>The console object that initiated this call.</desc>
3142 </param>
3143 <param name="id" type="uuid" mod="string" dir="in">
3144 <desc>UUID of the snapshot to delete.</desc>
3145 </param>
3146 <param name="machineState" type="MachineState" dir="out">
3147 <desc>New machine state after this operation is started.</desc>
3148 </param>
3149 <param name="progress" type="IProgress" dir="return">
3150 <desc>Progress object to track the operation completion.</desc>
3151 </param>
3152 </method>
3153
3154 <method name="finishOnlineMergeMedium">
3155 <desc>
3156 Gets called by IConsole::onlineMergeMedium.
3157 </desc>
3158 <param name="mediumAttachment" type="IMediumAttachment" dir="in">
3159 <desc>The medium attachment which needs to be cleaned up.</desc>
3160 </param>
3161 <param name="source" type="IMedium" dir="in">
3162 <desc>Merge source medium.</desc>
3163 </param>
3164 <param name="target" type="IMedium" dir="in">
3165 <desc>Merge target medium.</desc>
3166 </param>
3167 <param name="mergeForward" type="boolean" dir="in">
3168 <desc>Merge direction.</desc>
3169 </param>
3170 <param name="parentForTarget" type="IMedium" dir="in">
3171 <desc>For forward merges: new parent for target medium.</desc>
3172 </param>
3173 <param name="childrenToReparent" type="IMedium" safearray="yes" dir="in">
3174 <desc>For backward merges: list of media which need their parent UUID
3175 updated.</desc>
3176 </param>
3177 </method>
3178
3179 <method name="restoreSnapshot">
3180 <desc>
3181 Gets called by IConsole::RestoreSnapshot.
3182 </desc>
3183 <param name="initiator" type="IConsole" dir="in">
3184 <desc>The console object that initiated this call.</desc>
3185 </param>
3186 <param name="snapshot" type="ISnapshot" dir="in">
3187 <desc>The snapshot to restore the VM state from.</desc>
3188 </param>
3189 <param name="machineState" type="MachineState" dir="out">
3190 <desc>New machine state after this operation is started.</desc>
3191 </param>
3192 <param name="progress" type="IProgress" dir="return">
3193 <desc>Progress object to track the operation completion.</desc>
3194 </param>
3195 </method>
3196
3197 <method name="pullGuestProperties">
3198 <desc>
3199 Get the list of the guest properties matching a set of patterns along
3200 with their values, time stamps and flags and give responsibility for
3201 managing properties to the console.
3202 </desc>
3203 <param name="name" type="wstring" dir="out" safearray="yes">
3204 <desc>
3205 The names of the properties returned.
3206 </desc>
3207 </param>
3208 <param name="value" type="wstring" dir="out" safearray="yes">
3209 <desc>
3210 The values of the properties returned. The array entries match the
3211 corresponding entries in the @a name array.
3212 </desc>
3213 </param>
3214 <param name="timestamp" type="long long" dir="out" safearray="yes">
3215 <desc>
3216 The time stamps of the properties returned. The array entries match
3217 the corresponding entries in the @a name array.
3218 </desc>
3219 </param>
3220 <param name="flags" type="wstring" dir="out" safearray="yes">
3221 <desc>
3222 The flags of the properties returned. The array entries match the
3223 corresponding entries in the @a name array.
3224 </desc>
3225 </param>
3226 </method>
3227
3228 <method name="pushGuestProperty">
3229 <desc>
3230 Update a single guest property in IMachine.
3231 </desc>
3232 <param name="name" type="wstring" dir="in">
3233 <desc>
3234 The name of the property to be updated.
3235 </desc>
3236 </param>
3237 <param name="value" type="wstring" dir="in">
3238 <desc>
3239 The value of the property.
3240 </desc>
3241 </param>
3242 <param name="timestamp" type="long long" dir="in">
3243 <desc>
3244 The timestamp of the property.
3245 </desc>
3246 </param>
3247 <param name="flags" type="wstring" dir="in">
3248 <desc>
3249 The flags of the property.
3250 </desc>
3251 </param>
3252 </method>
3253
3254 <method name="lockMedia">
3255 <desc>
3256 Locks all media attached to the machine for writing and parents of
3257 attached differencing media (if any) for reading. This operation is
3258 atomic so that if it fails no media is actually locked.
3259
3260 This method is intended to be called when the machine is in Starting or
3261 Restoring state. The locked media will be automatically unlocked when
3262 the machine is powered off or crashed.
3263 </desc>
3264 </method>
3265 <method name="unlockMedia">
3266 <desc>
3267 Unlocks all media previously locked using
3268 <link to="IInternalMachineControl::lockMedia"/>.
3269
3270 This method is intended to be used with teleportation so that it is
3271 possible to teleport between processes on the same machine.
3272 </desc>
3273 </method>
3274 </interface>
3275
3276 <interface
3277 name="IBIOSSettings" extends="$unknown"
3278 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
3279 wsmap="managed"
3280 >
3281 <desc>
3282 The IBIOSSettings interface represents BIOS settings of the virtual
3283 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
3284 </desc>
3285 <attribute name="logoFadeIn" type="boolean">
3286 <desc>Fade in flag for BIOS logo animation.</desc>
3287 </attribute>
3288
3289 <attribute name="logoFadeOut" type="boolean">
3290 <desc>Fade out flag for BIOS logo animation.</desc>
3291 </attribute>
3292
3293 <attribute name="logoDisplayTime" type="unsigned long">
3294 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
3295 </attribute>
3296
3297 <attribute name="logoImagePath" type="wstring">
3298 <desc>
3299 Local file system path for external BIOS splash image. Empty string
3300 means the default image is shown on boot.
3301 </desc>
3302 </attribute>
3303
3304 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
3305 <desc>Mode of the BIOS boot device menu.</desc>
3306 </attribute>
3307
3308 <attribute name="ACPIEnabled" type="boolean">
3309 <desc>ACPI support flag.</desc>
3310 </attribute>
3311
3312 <attribute name="IOAPICEnabled" type="boolean">
3313 <desc>
3314 IO APIC support flag. If set, VirtualBox will provide an IO APIC
3315 and support IRQs above 15.
3316 </desc>
3317 </attribute>
3318
3319 <attribute name="timeOffset" type="long long">
3320 <desc>
3321 Offset in milliseconds from the host system time. This allows for
3322 guests running with a different system date/time than the host.
3323 It is equivalent to setting the system date/time in the BIOS except
3324 it is not an absolute value but a relative one. Guest Additions
3325 time synchronization honors this offset.
3326 </desc>
3327 </attribute>
3328
3329 <attribute name="PXEDebugEnabled" type="boolean">
3330 <desc>
3331 PXE debug logging flag. If set, VirtualBox will write extensive
3332 PXE trace information to the release log.
3333 </desc>
3334 </attribute>
3335
3336 </interface>
3337
3338 <enum name="CleanupMode"
3339 uuid="67897c50-7cca-47a9-83f6-ce8fd8eb5441">
3340 <desc>Cleanup mode, used with <link to="IMachine::unregister" />.
3341 </desc>
3342 <const name="UnregisterOnly" value="1">
3343 <desc>Unregister only the machine, but neither delete snapshots nor detach media.</desc>
3344 </const>
3345 <const name="DetachAllReturnNone" value="2">
3346 <desc>Delete all snapshots and detach all media but return none; this will keep all media registered.</desc>
3347 </const>
3348 <const name="DetachAllReturnHardDisksOnly" value="3">
3349 <desc>Delete all snapshots, detach all media and return hard disks for closing, but not removeable media.</desc>
3350 </const>
3351 <const name="Full" value="4">
3352 <desc>Delete all snapshots, detach all media and return all media for closing.</desc>
3353 </const>
3354 </enum>
3355
3356 <interface
3357 name="IMachine" extends="$unknown"
3358 uuid="5c91359b-5bdb-4518-9bd1-5f2c50a3c129"
3359 wsmap="managed"
3360 >
3361 <desc>
3362 The IMachine interface represents a virtual machine, or guest, created
3363 in VirtualBox.
3364
3365 This interface is used in two contexts. First of all, a collection of
3366 objects implementing this interface is stored in the
3367 <link to="IVirtualBox::machines"/> attribute which lists all the virtual
3368 machines that are currently registered with this VirtualBox
3369 installation. Also, once a session has been opened for the given virtual
3370 machine (e.g. the virtual machine is running), the machine object
3371 associated with the open session can be queried from the session object;
3372 see <link to="ISession"/> for details.
3373
3374 The main role of this interface is to expose the settings of the virtual
3375 machine and provide methods to change various aspects of the virtual
3376 machine's configuration. For machine objects stored in the
3377 <link to="IVirtualBox::machines"/> collection, all attributes are
3378 read-only unless explicitly stated otherwise in individual attribute
3379 and method descriptions.
3380
3381 In order to change a machine setting, a session for this machine must be
3382 opened using one of the <link to="IMachine::lockMachine" /> or
3383 <link to="IMachine::launchVMProcess"/> methods. After the
3384 machine has been successfully locked for a session, a mutable machine object
3385 needs to be queried from the session object and then the desired settings
3386 changes can be applied to the returned object using IMachine attributes and
3387 methods. See the <link to="ISession"/> interface description for more
3388 information about sessions.
3389
3390 Note that IMachine does not provide methods to control virtual machine
3391 execution (such as start the machine, or power it down) -- these methods
3392 are grouped in a separate interface called <link to="IConsole" />.
3393
3394 <see>ISession, IConsole</see>
3395 </desc>
3396
3397 <attribute name="parent" type="IVirtualBox" readonly="yes">
3398 <desc>Associated parent object.</desc>
3399 </attribute>
3400
3401 <attribute name="accessible" type="boolean" readonly="yes">
3402 <desc>
3403 Whether this virtual machine is currently accessible or not.
3404
3405 A machine is always deemed accessible unless it is registered <i>and</i>
3406 its settings file cannot be read or parsed (either because the file itself
3407 is unavailable or has invalid XML contents).
3408
3409 Every time this property is read, the accessibility state of
3410 this machine is re-evaluated. If the returned value is @c false,
3411 the <link to="#accessError"/> property may be used to get the
3412 detailed error information describing the reason of
3413 inaccessibility, including XML error messages.
3414
3415 When the machine is inaccessible, only the following properties
3416 can be used on it:
3417 <ul>
3418 <li><link to="#parent"/></li>
3419 <li><link to="#id"/></li>
3420 <li><link to="#settingsFilePath"/></li>
3421 <li><link to="#accessible"/></li>
3422 <li><link to="#accessError"/></li>
3423 </ul>
3424
3425 An attempt to access any other property or method will return
3426 an error.
3427
3428 The only possible action you can perform on an inaccessible
3429 machine is to unregister it using the
3430 <link to="IMachine::unregister"/> call (or, to check
3431 for the accessibility state once more by querying this
3432 property).
3433
3434 <note>
3435 In the current implementation, once this property returns
3436 @c true, the machine will never become inaccessible
3437 later, even if its settings file cannot be successfully
3438 read/written any more (at least, until the VirtualBox
3439 server is restarted). This limitation may be removed in
3440 future releases.
3441 </note>
3442 </desc>
3443 </attribute>
3444
3445 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
3446 <desc>
3447 Error information describing the reason of machine
3448 inaccessibility.
3449
3450 Reading this property is only valid after the last call to
3451 <link to="#accessible"/> returned @c false (i.e. the
3452 machine is currently unaccessible). Otherwise, a @c null
3453 IVirtualBoxErrorInfo object will be returned.
3454 </desc>
3455 </attribute>
3456
3457 <attribute name="name" type="wstring">
3458 <desc>
3459 Name of the virtual machine.
3460
3461 Besides being used for human-readable identification purposes
3462 everywhere in VirtualBox, the virtual machine name is also used
3463 as a name of the machine's settings file and as a name of the
3464 subdirectory this settings file resides in. Thus, every time you
3465 change the value of this property, the settings file will be
3466 renamed once you call <link to="#saveSettings"/> to confirm the
3467 change. The containing subdirectory will be also renamed, but
3468 only if it has exactly the same name as the settings file
3469 itself prior to changing this property (for backward compatibility
3470 with previous API releases). The above implies the following
3471 limitations:
3472 <ul>
3473 <li>The machine name cannot be empty.</li>
3474 <li>The machine name can contain only characters that are valid
3475 file name characters according to the rules of the file
3476 system used to store VirtualBox configuration.</li>
3477 <li>You cannot have two or more machines with the same name
3478 if they use the same subdirectory for storing the machine
3479 settings files.</li>
3480 <li>You cannot change the name of the machine if it is running,
3481 or if any file in the directory containing the settings file
3482 is being used by another running machine or by any other
3483 process in the host operating system at a time when
3484 <link to="#saveSettings"/> is called.
3485 </li>
3486 </ul>
3487 If any of the above limitations are hit, <link to="#saveSettings"/>
3488 will return an appropriate error message explaining the exact
3489 reason and the changes you made to this machine will not be saved.
3490 </desc>
3491 </attribute>
3492
3493 <attribute name="description" type="wstring">
3494 <desc>
3495 Description of the virtual machine.
3496
3497 The description attribute can contain any text and is
3498 typically used to describe the hardware and software
3499 configuration of the virtual machine in detail (i.e. network
3500 settings, versions of the installed software and so on).
3501 </desc>
3502 </attribute>
3503
3504 <attribute name="id" type="uuid" mod="string" readonly="yes">
3505 <desc>UUID of the virtual machine.</desc>
3506 </attribute>
3507
3508 <attribute name="OSTypeId" type="wstring">
3509 <desc>
3510 User-defined identifier of the Guest OS type.
3511 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
3512 an IGuestOSType object representing details about the given
3513 Guest OS type.
3514 <note>
3515 This value may differ from the value returned by
3516 <link to="IGuest::OSTypeId"/> if Guest Additions are
3517 installed to the guest OS.
3518 </note>
3519 </desc>
3520 </attribute>
3521
3522 <attribute name="HardwareVersion" type="wstring">
3523 <desc>Hardware version identifier. Internal use only for now.</desc>
3524 </attribute>
3525
3526 <attribute name="hardwareUUID" type="uuid" mod="string">
3527 <desc>
3528 The UUID presented to the guest via memory tables, hardware and guest
3529 properties. For most VMs this is the same as the @a id, but for VMs
3530 which have been cloned or teleported it may be the same as the source
3531 VM. This latter is because the guest shouldn't notice that it was
3532 cloned or teleported.
3533 </desc>
3534 </attribute>
3535
3536 <attribute name="CPUCount" type="unsigned long">
3537 <desc>Number of virtual CPUs in the VM.</desc>
3538 </attribute>
3539
3540 <attribute name="CPUHotPlugEnabled" type="boolean">
3541 <desc>
3542 This setting determines whether VirtualBox allows CPU
3543 hotplugging for this machine.</desc>
3544 </attribute>
3545
3546 <attribute name="CPUExecutionCap" type="unsigned long">
3547 <desc>
3548 Means to limit the number of CPU cycles a guest can use. The unit
3549 is percentage of host CPU cycles per second. The valid range
3550 is 1 - 100. 100 (the default) implies no limit.
3551 </desc>
3552 </attribute>
3553
3554 <attribute name="memorySize" type="unsigned long">
3555 <desc>System memory size in megabytes.</desc>
3556 </attribute>
3557
3558 <attribute name="memoryBalloonSize" type="unsigned long">
3559 <desc>Memory balloon size in megabytes.</desc>
3560 </attribute>
3561
3562 <attribute name="PageFusionEnabled" type="boolean">
3563 <desc>
3564 This setting determines whether VirtualBox allows page
3565 fusion for this machine (64 bits host only).
3566 </desc>
3567 </attribute>
3568
3569 <attribute name="VRAMSize" type="unsigned long">
3570 <desc>Video memory size in megabytes.</desc>
3571 </attribute>
3572
3573 <attribute name="accelerate3DEnabled" type="boolean" default="false">
3574 <desc>
3575 This setting determines whether VirtualBox allows this machine to make
3576 use of the 3D graphics support available on the host.</desc>
3577 </attribute>
3578
3579 <attribute name="accelerate2DVideoEnabled" type="boolean" default="false">
3580 <desc>
3581 This setting determines whether VirtualBox allows this machine to make
3582 use of the 2D video acceleration support available on the host.</desc>
3583 </attribute>
3584
3585 <attribute name="monitorCount" type="unsigned long">
3586 <desc>
3587 Number of virtual monitors.
3588 <note>
3589 Only effective on Windows XP and later guests with
3590 Guest Additions installed.
3591 </note>
3592 </desc>
3593 </attribute>
3594
3595 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
3596 <desc>Object containing all BIOS settings.</desc>
3597 </attribute>
3598
3599 <attribute name="firmwareType" type="FirmwareType">
3600 <desc>Type of firmware (such as legacy BIOS or EFI), used for initial
3601 bootstrap in this VM.</desc>
3602 </attribute>
3603
3604 <attribute name="pointingHidType" type="PointingHidType">
3605 <desc>Type of pointing HID (such as mouse or tablet) used in this VM.
3606 The default is typically "PS2Mouse" but can vary depending on the
3607 requirements of the guest operating system.</desc>
3608 </attribute>
3609
3610 <attribute name="keyboardHidType" type="KeyboardHidType">
3611 <desc>Type of keyboard HID used in this VM.
3612 The default is typically "PS2Keyboard" but can vary depending on the
3613 requirements of the guest operating system.</desc>
3614 </attribute>
3615
3616 <attribute name="hpetEnabled" type="boolean">
3617 <desc>This attribute controls if High Precision Event Timer (HPET) is
3618 enabled in this VM. Use this property if you want to provide guests
3619 with additional time source, or if guest requires HPET to function correctly.
3620 Default is false.</desc>
3621 </attribute>
3622
3623 <attribute name="chipsetType" type="ChipsetType">
3624 <desc>Chipset type used in this VM.</desc>
3625 </attribute>
3626
3627 <attribute name="snapshotFolder" type="wstring">
3628 <desc>
3629 Full path to the directory used to store snapshot data
3630 (differencing media and saved state files) of this machine.
3631
3632 The initial value of this property is
3633 <tt>&lt;</tt><link to="#settingsFilePath">
3634 path_to_settings_file</link><tt>&gt;/&lt;</tt>
3635 <link to="#id">machine_uuid</link>
3636 <tt>&gt;</tt>.
3637
3638 Currently, it is an error to try to change this property on
3639 a machine that has snapshots (because this would require to
3640 move possibly large files to a different location).
3641 A separate method will be available for this purpose later.
3642
3643 <note>
3644 Setting this property to @c null or to an empty string will restore
3645 the initial value.
3646 </note>
3647 <note>
3648 When setting this property, the specified path can be
3649 absolute (full path) or relative to the directory where the
3650 <link to="#settingsFilePath">machine settings file</link>
3651 is located. When reading this property, a full path is
3652 always returned.
3653 </note>
3654 <note>
3655 The specified path may not exist, it will be created
3656 when necessary.
3657 </note>
3658 </desc>
3659 </attribute>
3660
3661 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
3662 <desc>VRDP server object.</desc>
3663 </attribute>
3664
3665 <attribute name="mediumAttachments" type="IMediumAttachment" readonly="yes" safearray="yes">
3666 <desc>Array of media attached to this machine.</desc>
3667 </attribute>
3668
3669 <attribute name="USBController" type="IUSBController" readonly="yes">
3670 <desc>
3671 Associated USB controller object.
3672
3673 <note>
3674 If USB functionality is not available in the given edition of
3675 VirtualBox, this method will set the result code to @c E_NOTIMPL.
3676 </note>
3677 </desc>
3678 </attribute>
3679
3680 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
3681 <desc>Associated audio adapter, always present.</desc>
3682 </attribute>
3683
3684 <attribute name="storageControllers" type="IStorageController" readonly="yes" safearray="yes">
3685 <desc>Array of storage controllers attached to this machine.</desc>
3686 </attribute>
3687
3688 <attribute name="settingsFilePath" type="wstring" readonly="yes">
3689 <desc>
3690 Full name of the file containing machine settings data.
3691 </desc>
3692 </attribute>
3693
3694 <attribute name="settingsModified" type="boolean" readonly="yes">
3695 <desc>
3696 Whether the settings of this machine have been modified
3697 (but neither yet saved nor discarded).
3698 <note>
3699 Reading this property is only valid on instances returned
3700 by <link to="ISession::machine"/> and on new machines
3701 created by <link to="IVirtualBox::createMachine"/> or opened
3702 by <link to="IVirtualBox::openMachine"/> but not
3703 yet registered, or on unregistered machines after calling
3704 <link to="IMachine::unregister"/>. For all other
3705 cases, the settings can never be modified.
3706 </note>
3707 <note>
3708 For newly created unregistered machines, the value of this
3709 property is always @c true until <link to="#saveSettings"/>
3710 is called (no matter if any machine settings have been
3711 changed after the creation or not). For opened machines
3712 the value is set to @c false (and then follows to normal rules).
3713 </note>
3714 </desc>
3715 </attribute>
3716
3717 <attribute name="sessionState" type="SessionState" readonly="yes">
3718 <desc>Current session state for this machine.</desc>
3719 </attribute>
3720
3721 <attribute name="sessionType" type="wstring" readonly="yes">
3722 <desc>
3723 Type of the session. If <link to="#sessionState"/> is
3724 Spawning or Locked, this attribute contains the
3725 same value as passed to the
3726 <link to="IMachine::launchVMProcess"/> method in the
3727 @a type parameter. If the session was used with
3728 <link to="IMachine::lockMachine" />, or if
3729 <link to="#sessionState"/> is SessionClosed, the value of this
3730 attribute is an empty string.
3731 </desc>
3732 </attribute>
3733
3734 <attribute name="sessionPid" type="unsigned long" readonly="yes">
3735 <desc>
3736 Identifier of the session process. This attribute contains the
3737 platform-dependent identifier of the process whose session was
3738 used with <link to="IMachine::lockMachine" /> call. The returned
3739 value is only valid if <link to="#sessionState"/> is Locked or
3740 Unlocking by the time this property is read.
3741 </desc>
3742 </attribute>
3743
3744 <attribute name="state" type="MachineState" readonly="yes">
3745 <desc>Current execution state of this machine.</desc>
3746 </attribute>
3747
3748 <attribute name="lastStateChange" type="long long" readonly="yes">
3749 <desc>
3750 Time stamp of the last execution state change,
3751 in milliseconds since 1970-01-01 UTC.
3752 </desc>
3753 </attribute>
3754
3755 <attribute name="stateFilePath" type="wstring" readonly="yes">
3756 <desc>
3757 Full path to the file that stores the execution state of
3758 the machine when it is in the <link to="MachineState_Saved"/> state.
3759 <note>
3760 When the machine is not in the Saved state, this attribute is
3761 an empty string.
3762 </note>
3763 </desc>
3764 </attribute>
3765
3766 <attribute name="logFolder" type="wstring" readonly="yes">
3767 <desc>
3768 Full path to the folder that stores a set of rotated log files
3769 recorded during machine execution. The most recent log file is
3770 named <tt>VBox.log</tt>, the previous log file is
3771 named <tt>VBox.log.1</tt> and so on (up to <tt>VBox.log.3</tt>
3772 in the current version).
3773 </desc>
3774 </attribute>
3775
3776 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
3777 <desc>
3778 Current snapshot of this machine. This is @c null if the machine
3779 currently has no snapshots. If it is not @c null, then it was
3780 set by one of <link to="IConsole::takeSnapshot" />,
3781 <link to="IConsole::deleteSnapshot" />
3782 or <link to="IConsole::restoreSnapshot" />, depending on which
3783 was called last. See <link to="ISnapshot"/> for details.
3784 </desc>
3785 </attribute>
3786
3787 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
3788 <desc>
3789 Number of snapshots taken on this machine. Zero means the
3790 machine doesn't have any snapshots.
3791 </desc>
3792 </attribute>
3793
3794 <attribute name="currentStateModified" type="boolean" readonly="yes">
3795 <desc>
3796 Returns @c true if the current state of the machine is not
3797 identical to the state stored in the current snapshot.
3798
3799 The current state is identical to the current snapshot only
3800 directly after one of the following calls are made:
3801
3802 <ul>
3803 <li><link to="IConsole::restoreSnapshot"/>
3804 </li>
3805 <li><link to="IConsole::takeSnapshot"/> (issued on a
3806 "powered off" or "saved" machine, for which
3807 <link to="#settingsModified"/> returns @c false)
3808 </li>
3809 <li><link to="IMachine::setCurrentSnapshot"/>
3810 </li>
3811 </ul>
3812
3813 The current state remains identical until one of the following
3814 happens:
3815 <ul>
3816 <li>settings of the machine are changed</li>
3817 <li>the saved state is deleted</li>
3818 <li>the current snapshot is deleted</li>
3819 <li>an attempt to execute the machine is made</li>
3820 </ul>
3821
3822 <note>
3823 For machines that don't have snapshots, this property is
3824 always @c false.
3825 </note>
3826 </desc>
3827 </attribute>
3828
3829 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
3830 <desc>
3831 Collection of shared folders for this machine (permanent shared
3832 folders). These folders are shared automatically at machine startup
3833 and available only to the guest OS installed within this machine.
3834
3835 New shared folders are added to the collection using
3836 <link to="#createSharedFolder"/>. Existing shared folders can be
3837 removed using <link to="#removeSharedFolder"/>.
3838 </desc>
3839 </attribute>
3840
3841 <attribute name="clipboardMode" type="ClipboardMode">
3842 <desc>
3843 Synchronization mode between the host OS clipboard
3844 and the guest OS clipboard.
3845 </desc>
3846 </attribute>
3847
3848 <attribute name="guestPropertyNotificationPatterns" type="wstring">
3849 <desc>
3850 A comma-separated list of simple glob patterns. Changes to guest
3851 properties whose name matches one of the patterns will generate an
3852 <link to="IGuestPropertyChangedEvent"/> signal.
3853 </desc>
3854 </attribute>
3855
3856 <attribute name="teleporterEnabled" type="boolean">
3857 <desc>
3858 When set to @a true, the virtual machine becomes a target teleporter
3859 the next time it is powered on. This can only set to @a true when the
3860 VM is in the @a PoweredOff or @a Aborted state.
3861
3862 <!-- This property is automatically set to @a false when the VM is powered
3863 on. (bird: This doesn't work yet ) -->
3864 </desc>
3865 </attribute>
3866
3867 <attribute name="teleporterPort" type="unsigned long">
3868 <desc>
3869 The TCP port the target teleporter will listen for incoming
3870 teleportations on.
3871
3872 0 means the port is automatically selected upon power on. The actual
3873 value can be read from this property while the machine is waiting for
3874 incoming teleportations.
3875 </desc>
3876 </attribute>
3877
3878 <attribute name="teleporterAddress" type="wstring">
3879 <desc>
3880 The address the target teleporter will listen on. If set to an empty
3881 string, it will listen on all addresses.
3882 </desc>
3883 </attribute>
3884
3885 <attribute name="teleporterPassword" type="wstring">
3886 <desc>
3887 The password to check for on the target teleporter. This is just a
3888 very basic measure to prevent simple hacks and operators accidentally
3889 beaming a virtual machine to the wrong place.
3890 </desc>
3891 </attribute>
3892
3893 <attribute name="faultToleranceState" type="FaultToleranceState">
3894 <desc>
3895 Fault tolerance state; disabled, source or target.
3896 This property can be changed at any time. If you change it for a running
3897 VM, then the fault tolerance address and port must be set beforehand.
3898 </desc>
3899 </attribute>
3900
3901 <attribute name="faultTolerancePort" type="unsigned long">
3902 <desc>
3903 The TCP port the fault tolerance source or target will use for
3904 communication.
3905 </desc>
3906 </attribute>
3907
3908 <attribute name="faultToleranceAddress" type="wstring">
3909 <desc>
3910 The address the fault tolerance source or target.
3911 </desc>
3912 </attribute>
3913
3914 <attribute name="faultTolerancePassword" type="wstring">
3915 <desc>
3916 The password to check for on the standby VM. This is just a
3917 very basic measure to prevent simple hacks and operators accidentally
3918 choosing the wrong standby VM.
3919 </desc>
3920 </attribute>
3921
3922 <attribute name="faultToleranceSyncInterval" type="unsigned long">
3923 <desc>
3924 The interval in ms used for syncing the state between source and target.
3925 </desc>
3926 </attribute>
3927
3928 <attribute name="RTCUseUTC" type="boolean">
3929 <desc>
3930 When set to @a true, the RTC device of the virtual machine will run
3931 in UTC time, otherwise in local time. Especially Unix guests prefer
3932 the time in UTC.
3933 </desc>
3934 </attribute>
3935
3936 <attribute name="ioCacheEnabled" type="boolean">
3937 <desc>
3938 When set to @a true, the builtin I/O cache of the virtual machine
3939 will be enabled.
3940 </desc>
3941 </attribute>
3942
3943 <attribute name="ioCacheSize" type="unsigned long">
3944 <desc>
3945 Maximum size of the I/O cache in MB.
3946 </desc>
3947 </attribute>
3948
3949 <method name="lockMachine">
3950 <desc>
3951 Locks the machine for the given session to enable the caller
3952 to make changes to the machine or start the VM or control
3953 VM execution.
3954
3955 There are two ways to lock a machine for such uses:
3956
3957 <ul>
3958 <li>If you want to make changes to the machine settings,
3959 you must obtain an exclusive write lock on the machine
3960 by setting @a lockType to @c Write.
3961
3962 This will only succeed if no other process has locked
3963 the machine to prevent conflicting changes. Only after
3964 an exclusive write lock has been obtained using this method, one
3965 can change all VM settings or execute the VM in the process
3966 space of the session object. (Note that the latter is only of
3967 interest if you actually want to write a new front-end for
3968 virtual machines; but this API gets called internally by
3969 the existing front-ends such as VBoxHeadless and the VirtualBox
3970 GUI to acquire a write lock on the machine that they are running.)
3971
3972 On success, write-locking the machine for a session creates
3973 a second copy of the IMachine object. It is this second object
3974 upon which changes can be made; in VirtualBox terminology, the
3975 second copy is "mutable". It is only this second, mutable machine
3976 object upon which you can call methods that change the
3977 machine state. After having called this method, you can
3978 obtain this second, mutable machine object using the
3979 <link to="ISession::machine" /> attribute.
3980 </li>
3981 <li>If you only want to check the machine state or control
3982 machine execution without actually changing machine
3983 settings (e.g. to get access to VM statistics or take
3984 a snapshot or save the machine state), then set the
3985 @a lockType argument to @c Shared.
3986
3987 If no other session has obtained a lock, you will obtain an
3988 exclusive write lock as described above. However, if another
3989 session has already obtained such a lock, then a link to that
3990 existing session will be established which allows you
3991 to control that existing session.
3992
3993 To find out which type of lock was obtained, you can
3994 inspect <link to="ISession::type" />, which will have been
3995 set to either @c WriteLock or @c Shared.
3996 </li>
3997 </ul>
3998
3999 In either case, you can get access to the <link to="IConsole" />
4000 object which controls VM execution.
4001
4002 Also in all of the above cases, one must always call
4003 <link to="ISession::unlockMachine" /> to release the lock on the machine, or
4004 the machine's state will eventually be set to "Aborted".
4005
4006 To change settings on a machine, the following sequence is typically
4007 performed:
4008
4009 <ol>
4010 <li>Call this method to obtain an exclusive write lock for the current session.</li>
4011
4012 <li>Obtain a mutable IMachine object from <link to="ISession::machine" />.</li>
4013
4014 <li>Change the settings of the machine by invoking IMachine methods.</li>
4015
4016 <li>Call <link to="IMachine::saveSettings" />.</li>
4017
4018 <li>Release the write lock by calling <link to="ISession::unlockMachine"/>.</li>
4019 </ol>
4020
4021 <result name="E_UNEXPECTED">
4022 Virtual machine not registered.
4023 </result>
4024 <result name="E_ACCESSDENIED">
4025 Process not started by OpenRemoteSession.
4026 </result>
4027 <result name="VBOX_E_INVALID_OBJECT_STATE">
4028 Session already open or being opened.
4029 </result>
4030 <result name="VBOX_E_VM_ERROR">
4031 Failed to assign machine to session.
4032 </result>
4033 </desc>
4034 <param name="session" type="ISession" dir="in">
4035 <desc>
4036 Session object for which the machine will be locked.
4037 </desc>
4038 </param>
4039 <param name="lockType" type="LockType" dir="in">
4040 <desc>
4041 If set to @c Write, then attempt to acquire an exclusive write lock or fail.
4042 If set to @c Shared, then either acquire an exclusive write lock or establish
4043 a link to an existing session.
4044 </desc>
4045 </param>
4046 </method>
4047
4048 <method name="launchVMProcess">
4049 <desc>
4050 Spawns a new process that will execute the virtual machine and obtains a shared
4051 lock on the machine for the calling session.
4052
4053 If launching the VM succeeds, the new VM process will create its own session
4054 and write-lock the machine for it, preventing conflicting changes from other
4055 processes. If the machine is already locked (because it is already running or
4056 because another session has a write lock), launching the VM process will therefore
4057 fail. Reversely, future attempts to obtain a write lock will also fail while the
4058 machine is running.
4059
4060 The caller's session object remains separate from the session opened by the new
4061 VM process. It receives its own <link to="IConsole" /> object which can be used
4062 to control machine execution, but it cannot be used to change all VM settings
4063 which would be available after a <link to="#lockMachine" /> call.
4064
4065 The caller must eventually release the session's shared lock by calling
4066 <link to="ISession::unlockMachine" /> on the local session object once this call
4067 has returned. However, the session's state (see <link to="ISession::state" />)
4068 will not return to "Unlocked" until the remote session has also unlocked
4069 the machine (i.e. the machine has stopped running).
4070
4071 Lauching a VM process can take some time (a new VM is started in a new process,
4072 for which memory and other resources need to be set up). Because of this,
4073 an <link to="IProgress" /> object is returned to allow the caller to wait
4074 for this asynchronous operation to be completed. Until then, the caller's
4075 session object remains in the "Unlocked" state, and its <link to="ISession::machine" />
4076 and <link to="ISession::console" /> attributes cannot be accessed.
4077 It is recommended to use <link to="IProgress::waitForCompletion" /> or
4078 similar calls to wait for completion. Completion is signalled when the VM
4079 is powered on. If launching the VM fails, error messages can be queried
4080 via the progress object, if available.
4081
4082 The progress object will have at least 2 sub-operations. The first
4083 operation covers the period up to the new VM process calls powerUp.
4084 The subsequent operations mirror the <link to="IConsole::powerUp"/>
4085 progress object. Because <link to="IConsole::powerUp"/> may require
4086 some extra sub-operations, the <link to="IProgress::operationCount"/>
4087 may change at the completion of operation.
4088
4089 For details on the teleportation progress operation, see
4090 <link to="IConsole::powerUp"/>.
4091
4092 The @a environment argument is a string containing definitions of
4093 environment variables in the following format:
4094 @code
4095 NAME[=VALUE]\n
4096 NAME[=VALUE]\n
4097 ...
4098 @endcode
4099 where <tt>\\n</tt> is the new line character. These environment
4100 variables will be appended to the environment of the VirtualBox server
4101 process. If an environment variable exists both in the server process
4102 and in this list, the value from this list takes precedence over the
4103 server's variable. If the value of the environment variable is
4104 omitted, this variable will be removed from the resulting environment.
4105 If the environment string is @c null or empty, the server environment
4106 is inherited by the started process as is.
4107
4108 <result name="E_UNEXPECTED">
4109 Virtual machine not registered.
4110 </result>
4111 <result name="E_INVALIDARG">
4112 Invalid session type @a type.
4113 </result>
4114 <result name="VBOX_E_OBJECT_NOT_FOUND">
4115 No machine matching @a machineId found.
4116 </result>
4117 <result name="VBOX_E_INVALID_OBJECT_STATE">
4118 Session already open or being opened.
4119 </result>
4120 <result name="VBOX_E_IPRT_ERROR">
4121 Launching process for machine failed.
4122 </result>
4123 <result name="VBOX_E_VM_ERROR">
4124 Failed to assign machine to session.
4125 </result>
4126 </desc>
4127 <param name="session" type="ISession" dir="in">
4128 <desc>
4129 Client session object to which the VM process will be connected (this
4130 must be in "Unlocked" state).
4131 </desc>
4132 </param>
4133 <param name="type" type="wstring" dir="in">
4134 <desc>
4135 Front-end to use for the new VM process. The following are currently supported:
4136 <ul>
4137 <li><tt>"gui"</tt>: VirtualBox Qt GUI front-end</li>
4138 <li><tt>"vrdp"</tt>: VBoxHeadless (VRDP Server) front-end</li>
4139 <li><tt>"sdl"</tt>: VirtualBox SDL front-end</li>
4140 </ul>
4141 </desc>
4142 </param>
4143 <param name="environment" type="wstring" dir="in">
4144 <desc>
4145 Environment to pass to the VM process.
4146 </desc>
4147 </param>
4148 <param name="progress" type="IProgress" dir="return">
4149 <desc>Progress object to track the operation completion.</desc>
4150 </param>
4151 </method>
4152
4153 <method name="setBootOrder">
4154 <desc>
4155 Puts the given device to the specified position in
4156 the boot order.
4157
4158 To indicate that no device is associated with the given position,
4159 <link to="DeviceType_Null"/> should be used.
4160
4161 @todo setHardDiskBootOrder(), setNetworkBootOrder()
4162
4163 <result name="E_INVALIDARG">
4164 Boot @a position out of range.
4165 </result>
4166 <result name="E_NOTIMPL">
4167 Booting from USB @a device currently not supported.
4168 </result>
4169
4170 </desc>
4171 <param name="position" type="unsigned long" dir="in">
4172 <desc>
4173 Position in the boot order (@c 1 to the total number of
4174 devices the machine can boot from, as returned by
4175 <link to="ISystemProperties::maxBootPosition"/>).
4176 </desc>
4177 </param>
4178 <param name="device" type="DeviceType" dir="in">
4179 <desc>
4180 The type of the device used to boot at the given position.
4181 </desc>
4182 </param>
4183 </method>
4184
4185 <method name="getBootOrder" const="yes">
4186 <desc>
4187 Returns the device type that occupies the specified
4188 position in the boot order.
4189
4190 @todo [remove?]
4191 If the machine can have more than one device of the returned type
4192 (such as hard disks), then a separate method should be used to
4193 retrieve the individual device that occupies the given position.
4194
4195 If here are no devices at the given position, then
4196 <link to="DeviceType_Null"/> is returned.
4197
4198 @todo getHardDiskBootOrder(), getNetworkBootOrder()
4199
4200 <result name="E_INVALIDARG">
4201 Boot @a position out of range.
4202 </result>
4203
4204 </desc>
4205 <param name="position" type="unsigned long" dir="in">
4206 <desc>
4207 Position in the boot order (@c 1 to the total number of
4208 devices the machine can boot from, as returned by
4209 <link to="ISystemProperties::maxBootPosition"/>).
4210 </desc>
4211 </param>
4212 <param name="device" type="DeviceType" dir="return">
4213 <desc>
4214 Device at the given position.
4215 </desc>
4216 </param>
4217 </method>
4218
4219 <method name="attachDevice">
4220 <desc>
4221 Attaches a device and optionally mounts a medium to the given storage
4222 controller (<link to="IStorageController" />, identified by @a name),
4223 at the indicated port and device.
4224
4225 This method is intended for managing storage devices in general while a
4226 machine is powered off. It can be used to attach and detach fixed
4227 and removeable media. The following kind of media can be attached
4228 to a machine:
4229
4230 <ul>
4231 <li>For fixed and removable media, you can pass in a medium that was
4232 previously opened using <link to="IVirtualBox::openMedium" />.
4233 </li>
4234
4235 <li>Only for storage devices supporting removable media (such as
4236 DVDs and floppies), you can also specify a null pointer to
4237 indicate an empty drive or one of the medium objects listed
4238 in the <link to="IHost::DVDDrives" /> and <link to="IHost::floppyDrives"/>
4239 arrays to indicate a host drive.
4240 For removeable devices, you can also use <link to="IMachine::mountMedium"/>
4241 to change the media while the machine is running.
4242 </li>
4243 </ul>
4244
4245 In a VM's default configuration of virtual machines, the secondary
4246 master of the IDE controller is used for a CD/DVD drive.
4247
4248 After calling this returns successfully, a new instance of
4249 <link to="IMediumAttachment"/> will appear in the machine's list of medium
4250 attachments (see <link to="IMachine::mediumAttachments"/>).
4251
4252 See <link to="IMedium"/> and <link to="IMediumAttachment"/> for more
4253 information about attaching media.
4254
4255 The specified device slot must not have a device attached to it,
4256 or this method will fail.
4257
4258 <note>
4259 You cannot attach a device to a newly created machine until
4260 this machine's settings are saved to disk using
4261 <link to="#saveSettings"/>.
4262 </note>
4263 <note>
4264 If the medium is being attached indirectly, a new differencing medium
4265 will implicitly be created for it and attached instead. If the
4266 changes made to the machine settings (including this indirect
4267 attachment) are later cancelled using <link to="#discardSettings"/>,
4268 this implicitly created differencing medium will implicitly
4269 be deleted.
4270 </note>
4271
4272 <result name="E_INVALIDARG">
4273 SATA device, SATA port, IDE port or IDE slot out of range, or
4274 file or UUID not found.
4275 </result>
4276 <result name="VBOX_E_INVALID_OBJECT_STATE">
4277 Machine must be registered before media can be attached.
4278 </result>
4279 <result name="VBOX_E_INVALID_VM_STATE">
4280 Invalid machine state.
4281 </result>
4282 <result name="VBOX_E_OBJECT_IN_USE">
4283 A medium is already attached to this or another virtual machine.
4284 </result>
4285
4286 </desc>
4287 <param name="name" type="wstring" dir="in">
4288 <desc>Name of the storage controller to attach the device to.</desc>
4289 </param>
4290 <param name="controllerPort" type="long" dir="in">
4291 <desc>Port to attach the device to. For an IDE controller, 0 specifies
4292 the primary controller and 1 specifies the secondary controller.
4293 For a SCSI controller, this must range from 0 to 15; for a SATA controller,
4294 from 0 to 29; for an SAS controller, from 0 to 7.</desc>
4295 </param>
4296 <param name="device" type="long" dir="in">
4297 <desc>Device slot in the given port to attach the device to. This is only
4298 relevant for IDE controllers, for which 0 specifies the master device and
4299 1 specifies the slave device. For all other controller types, this must
4300 be 0.</desc>
4301 </param>
4302 <param name="type" type="DeviceType" dir="in">
4303 <desc>Device type of the attached device. For media opened by
4304 <link to="IVirtualBox::openMedium" />, this must match the device type
4305 specified there.</desc>
4306 </param>
4307 <param name="medium" type="IMedium" dir="in">
4308 <desc>Medium to mount or NULL for an empty drive.</desc>
4309 </param>
4310 </method>
4311
4312 <method name="detachDevice">
4313 <desc>
4314 Detaches the device attached to a device slot of the specified bus.
4315
4316 Detaching the device from the virtual machine is deferred. This means
4317 that the medium remains associated with the machine when this method
4318 returns and gets actually de-associated only after a successful
4319 <link to="#saveSettings"/> call. See <link to="IMedium"/>
4320 for more detailed information about attaching media.
4321
4322 <note>
4323 You cannot detach a device from a running machine.
4324 </note>
4325 <note>
4326 Detaching differencing media implicitly created by <link
4327 to="#attachDevice"/> for the indirect attachment using this
4328 method will <b>not</b> implicitly delete them. The
4329 <link to="IMedium::deleteStorage"/> operation should be
4330 explicitly performed by the caller after the medium is successfully
4331 detached and the settings are saved with
4332 <link to="#saveSettings"/>, if it is the desired action.
4333 </note>
4334
4335 <result name="VBOX_E_INVALID_VM_STATE">
4336 Attempt to detach medium from a running virtual machine.
4337 </result>
4338 <result name="VBOX_E_OBJECT_NOT_FOUND">
4339 No medium attached to given slot/bus.
4340 </result>
4341 <result name="VBOX_E_NOT_SUPPORTED">
4342 Medium format does not support storage deletion.
4343 </result>
4344
4345 </desc>
4346 <param name="name" type="wstring" dir="in">
4347 <desc>Name of the storage controller to detach the medium from.</desc>
4348 </param>
4349 <param name="controllerPort" type="long" dir="in">
4350 <desc>Port number to detach the medium from.</desc>
4351 </param>
4352 <param name="device" type="long" dir="in">
4353 <desc>Device slot number to detach the medium from.</desc>
4354 </param>
4355 </method>
4356
4357 <method name="passthroughDevice">
4358 <desc>
4359 Sets the passthrough mode of an existing DVD device. Changing the
4360 setting while the VM is running is forbidden. The setting is only used
4361 if at VM start the device is configured as a host DVD drive, in all
4362 other cases it is ignored. The device must already exist; see
4363 <link to="IMachine::attachDevice"/> for how to attach a new device.
4364
4365 The @a controllerPort and @a device parameters specify the device slot and
4366 have have the same meaning as with <link to="IMachine::attachDevice" />.
4367
4368 <result name="E_INVALIDARG">
4369 SATA device, SATA port, IDE port or IDE slot out of range.
4370 </result>
4371 <result name="VBOX_E_INVALID_OBJECT_STATE">
4372 Attempt to modify an unregistered virtual machine.
4373 </result>
4374 <result name="VBOX_E_INVALID_VM_STATE">
4375 Invalid machine state.
4376 </result>
4377
4378 </desc>
4379 <param name="name" type="wstring" dir="in">
4380 <desc>Name of the storage controller.</desc>
4381 </param>
4382 <param name="controllerPort" type="long" dir="in">
4383 <desc>Storage controller port.</desc>
4384 </param>
4385 <param name="device" type="long" dir="in">
4386 <desc>Device slot in the given port.</desc>
4387 </param>
4388 <param name="passthrough" type="boolean" dir="in">
4389 <desc>New value for the passthrough setting.</desc>
4390 </param>
4391 </method>
4392
4393 <method name="mountMedium">
4394 <desc>
4395 Mounts a medium (<link to="IMedium" />, identified
4396 by the given UUID @a id) to the given storage controller
4397 (<link to="IStorageController" />, identified by @a name),
4398 at the indicated port and device. The device must already exist;
4399 see <link to="IMachine::attachDevice"/> for how to attach a new device.
4400
4401 This method is intended only for managing removable media, where the
4402 device is fixed but media is changeable at runtime (such as DVDs
4403 and floppies). It cannot be used for fixed media such as hard disks.
4404
4405 The @a controllerPort and @a device parameters specify the device slot and
4406 have have the same meaning as with <link to="IMachine::attachDevice" />.
4407
4408 The specified device slot can have a medium mounted, which will be
4409 unmounted first. Specifying a zero UUID (or an empty string) for
4410 @a medium does just an unmount.
4411
4412 See <link to="IMedium"/> for more detailed information about
4413 attaching media.
4414
4415 <result name="E_INVALIDARG">
4416 SATA device, SATA port, IDE port or IDE slot out of range.
4417 </result>
4418 <result name="VBOX_E_INVALID_OBJECT_STATE">
4419 Attempt to attach medium to an unregistered virtual machine.
4420 </result>
4421 <result name="VBOX_E_INVALID_VM_STATE">
4422 Invalid machine state.
4423 </result>
4424 <result name="VBOX_E_OBJECT_IN_USE">
4425 Medium already attached to this or another virtual machine.
4426 </result>
4427
4428 </desc>
4429 <param name="name" type="wstring" dir="in">
4430 <desc>Name of the storage controller to attach the medium to.</desc>
4431 </param>
4432 <param name="controllerPort" type="long" dir="in">
4433 <desc>Port to attach the medium to.</desc>
4434 </param>
4435 <param name="device" type="long" dir="in">
4436 <desc>Device slot in the given port to attach the medium to.</desc>
4437 </param>
4438 <param name="medium" type="IMedium" dir="in">
4439 <desc>Medium to mount or NULL for an empty drive.</desc>
4440 </param>
4441 <param name="force" type="boolean" dir="in">
4442 <desc>Allows to force unmount/mount of a medium which is locked by
4443 the device slot in the given port to attach the medium to.</desc>
4444 </param>
4445 </method>
4446
4447 <method name="getMedium" const="yes">
4448 <desc>
4449 Returns the virtual medium attached to a device slot of the specified
4450 bus.
4451
4452 Note that if the medium was indirectly attached by
4453 <link to="#mountMedium"/> to the given device slot then this
4454 method will return not the same object as passed to the
4455 <link to="#mountMedium"/> call. See <link to="IMedium"/> for
4456 more detailed information about mounting a medium.
4457
4458 <result name="VBOX_E_OBJECT_NOT_FOUND">
4459 No medium attached to given slot/bus.
4460 </result>
4461
4462 </desc>
4463 <param name="name" type="wstring" dir="in">
4464 <desc>Name of the storage controller the medium is attached to.</desc>
4465 </param>
4466 <param name="controllerPort" type="long" dir="in">
4467 <desc>Port to query.</desc>
4468 </param>
4469 <param name="device" type="long" dir="in">
4470 <desc>Device slot in the given port to query.</desc>
4471 </param>
4472 <param name="medium" type="IMedium" dir="return">
4473 <desc>Attached medium object.</desc>
4474 </param>
4475 </method>
4476
4477 <method name="getMediumAttachmentsOfController" const="yes">
4478 <desc>
4479 Returns an array of medium attachments which are attached to the
4480 the controller with the given name.
4481
4482 <result name="VBOX_E_OBJECT_NOT_FOUND">
4483 A storage controller with given name doesn't exist.
4484 </result>
4485 </desc>
4486 <param name="name" type="wstring" dir="in"/>
4487 <param name="mediumAttachments" type="IMediumAttachment" safearray="yes" dir="return"/>
4488 </method>
4489
4490 <method name="getMediumAttachment" const="yes">
4491 <desc>
4492 Returns a medium attachment which corresponds to the controller with
4493 the given name, on the given port and device slot.
4494
4495 <result name="VBOX_E_OBJECT_NOT_FOUND">
4496 No attachment exists for the given controller/port/device combination.
4497 </result>
4498 </desc>
4499 <param name="name" type="wstring" dir="in"/>
4500 <param name="controllerPort" type="long" dir="in"/>
4501 <param name="device" type="long" dir="in"/>
4502 <param name="attachment" type="IMediumAttachment" dir="return"/>
4503 </method>
4504
4505 <method name="getNetworkAdapter" const="yes">
4506 <desc>
4507 Returns the network adapter associated with the given slot.
4508 Slots are numbered sequentially, starting with zero. The total
4509 number of adapters per machine is defined by the
4510 <link to="ISystemProperties::networkAdapterCount"/> property,
4511 so the maximum slot number is one less than that property's value.
4512
4513 <result name="E_INVALIDARG">
4514 Invalid @a slot number.
4515 </result>
4516
4517 </desc>
4518 <param name="slot" type="unsigned long" dir="in"/>
4519 <param name="adapter" type="INetworkAdapter" dir="return"/>
4520 </method>
4521
4522 <method name="addStorageController">
4523 <desc>
4524 Adds a new storage controller (SCSI, SAS or SATA controller) to the
4525 machine and returns it as an instance of
4526 <link to="IStorageController" />.
4527
4528 @a name identifies the controller for subsequent calls such as
4529 <link to="#getStorageControllerByName" />,
4530 <link to="#getStorageControllerByInstance" />,
4531 <link to="#removeStorageController" />,
4532 <link to="#attachDevice" /> or <link to="#mountMedium" />.
4533
4534 After the controller has been added, you can set its exact
4535 type by setting the <link to="IStorageController::controllerType" />.
4536
4537 <result name="VBOX_E_OBJECT_IN_USE">
4538 A storage controller with given name exists already.
4539 </result>
4540 <result name="E_INVALIDARG">
4541 Invalid @a controllerType.
4542 </result>
4543 </desc>
4544 <param name="name" type="wstring" dir="in"/>
4545 <param name="connectionType" type="StorageBus" dir="in"/>
4546 <param name="controller" type="IStorageController" dir="return"/>
4547 </method>
4548
4549 <method name="getStorageControllerByName" const="yes">
4550 <desc>
4551 Returns a storage controller with the given name.
4552
4553 <result name="VBOX_E_OBJECT_NOT_FOUND">
4554 A storage controller with given name doesn't exist.
4555 </result>
4556 </desc>
4557 <param name="name" type="wstring" dir="in"/>
4558 <param name="storageController" type="IStorageController" dir="return"/>
4559 </method>
4560
4561 <method name="getStorageControllerByInstance" const="yes">
4562 <desc>
4563 Returns a storage controller with the given instance number.
4564
4565 <result name="VBOX_E_OBJECT_NOT_FOUND">
4566 A storage controller with given instance number doesn't exist.
4567 </result>
4568 </desc>
4569 <param name="instance" type="unsigned long" dir="in"/>
4570 <param name="storageController" type="IStorageController" dir="return"/>
4571 </method>
4572
4573 <method name="removeStorageController">
4574 <desc>
4575 Removes a storage controller from the machine.
4576
4577 <result name="VBOX_E_OBJECT_NOT_FOUND">
4578 A storage controller with given name doesn't exist.
4579 </result>
4580 </desc>
4581 <param name="name" type="wstring" dir="in"/>
4582 </method>
4583
4584 <method name="getSerialPort" const="yes">
4585 <desc>
4586 Returns the serial port associated with the given slot.
4587 Slots are numbered sequentially, starting with zero. The total
4588 number of serial ports per machine is defined by the
4589 <link to="ISystemProperties::serialPortCount"/> property,
4590 so the maximum slot number is one less than that property's value.
4591
4592 <result name="E_INVALIDARG">
4593 Invalid @a slot number.
4594 </result>
4595
4596 </desc>
4597 <param name="slot" type="unsigned long" dir="in"/>
4598 <param name="port" type="ISerialPort" dir="return"/>
4599 </method>
4600
4601 <method name="getParallelPort" const="yes">
4602 <desc>
4603 Returns the parallel port associated with the given slot.
4604 Slots are numbered sequentially, starting with zero. The total
4605 number of parallel ports per machine is defined by the
4606 <link to="ISystemProperties::parallelPortCount"/> property,
4607 so the maximum slot number is one less than that property's value.
4608
4609 <result name="E_INVALIDARG">
4610 Invalid @a slot number.
4611 </result>
4612
4613 </desc>
4614 <param name="slot" type="unsigned long" dir="in"/>
4615 <param name="port" type="IParallelPort" dir="return"/>
4616 </method>
4617
4618 <method name="getExtraDataKeys">
4619 <desc>
4620 Returns an array representing the machine-specific extra data keys
4621 which currently have values defined.
4622 </desc>
4623 <param name="value" type="wstring" dir="return" safearray="yes">
4624 <desc>Array of extra data keys.</desc>
4625 </param>
4626 </method>
4627
4628 <method name="getExtraData">
4629 <desc>
4630 Returns associated machine-specific extra data.
4631
4632 If the requested data @a key does not exist, this function will
4633 succeed and return an empty string in the @a value argument.
4634
4635 <result name="VBOX_E_FILE_ERROR">
4636 Settings file not accessible.
4637 </result>
4638 <result name="VBOX_E_XML_ERROR">
4639 Could not parse the settings file.
4640 </result>
4641
4642 </desc>
4643 <param name="key" type="wstring" dir="in">
4644 <desc>Name of the data key to get.</desc>
4645 </param>
4646 <param name="value" type="wstring" dir="return">
4647 <desc>Value of the requested data key.</desc>
4648 </param>
4649 </method>
4650
4651 <method name="setExtraData">
4652 <desc>
4653 Sets associated machine-specific extra data.
4654
4655 If you pass @c null or an empty string as a key @a value, the given
4656 @a key will be deleted.
4657
4658 <note>
4659 Before performing the actual data change, this method will ask all
4660 registered listeners using the
4661 <link to="IExtraDataCanChangeEvent"/>
4662 notification for a permission. If one of the listeners refuses the
4663 new value, the change will not be performed.
4664 </note>
4665 <note>
4666 On success, the
4667 <link to="IExtraDataChangedEvent"/> notification
4668 is called to inform all registered listeners about a successful data
4669 change.
4670 </note>
4671 <note>
4672 This method can be called outside the machine session and therefore
4673 it's a caller's responsibility to handle possible race conditions
4674 when several clients change the same key at the same time.
4675 </note>
4676
4677 <result name="VBOX_E_FILE_ERROR">
4678 Settings file not accessible.
4679 </result>
4680 <result name="VBOX_E_XML_ERROR">
4681 Could not parse the settings file.
4682 </result>
4683
4684 </desc>
4685 <param name="key" type="wstring" dir="in">
4686 <desc>Name of the data key to set.</desc>
4687 </param>
4688 <param name="value" type="wstring" dir="in">
4689 <desc>Value to assign to the key.</desc>
4690 </param>
4691 </method>
4692
4693 <method name="getCPUProperty" const="yes">
4694 <desc>
4695 Returns the virtual CPU boolean value of the specified property.
4696
4697 <result name="E_INVALIDARG">
4698 Invalid property.
4699 </result>
4700
4701 </desc>
4702 <param name="property" type="CPUPropertyType" dir="in">
4703 <desc>
4704 Property type to query.
4705 </desc>
4706 </param>
4707 <param name="value" type="boolean" dir="return">
4708 <desc>
4709 Property value.
4710 </desc>
4711 </param>
4712 </method>
4713
4714 <method name="setCPUProperty">
4715 <desc>
4716 Sets the virtual CPU boolean value of the specified property.
4717
4718 <result name="E_INVALIDARG">
4719 Invalid property.
4720 </result>
4721
4722 </desc>
4723 <param name="property" type="CPUPropertyType" dir="in">
4724 <desc>
4725 Property type to query.
4726 </desc>
4727 </param>
4728 <param name="value" type="boolean" dir="in">
4729 <desc>
4730 Property value.
4731 </desc>
4732 </param>
4733 </method>
4734
4735 <method name="getCPUIDLeaf" const="yes">
4736 <desc>
4737 Returns the virtual CPU cpuid information for the specified leaf.
4738
4739 Currently supported index values for cpuid:
4740 Standard CPUID leafs: 0 - 0xA
4741 Extended CPUID leafs: 0x80000000 - 0x8000000A
4742
4743 See the Intel and AMD programmer's manuals for detailed information
4744 about the cpuid instruction and its leafs.
4745 <result name="E_INVALIDARG">
4746 Invalid id.
4747 </result>
4748
4749 </desc>
4750 <param name="id" type="unsigned long" dir="in">
4751 <desc>
4752 CPUID leaf index.
4753 </desc>
4754 </param>
4755 <param name="valEax" type="unsigned long" dir="out">
4756 <desc>
4757 CPUID leaf value for register eax.
4758 </desc>
4759 </param>
4760 <param name="valEbx" type="unsigned long" dir="out">
4761 <desc>
4762 CPUID leaf value for register ebx.
4763 </desc>
4764 </param>
4765 <param name="valEcx" type="unsigned long" dir="out">
4766 <desc>
4767 CPUID leaf value for register ecx.
4768 </desc>
4769 </param>
4770 <param name="valEdx" type="unsigned long" dir="out">
4771 <desc>
4772 CPUID leaf value for register edx.
4773 </desc>
4774 </param>
4775 </method>
4776
4777 <method name="setCPUIDLeaf">
4778 <desc>
4779 Sets the virtual CPU cpuid information for the specified leaf. Note that these values
4780 are not passed unmodified. VirtualBox clears features that it doesn't support.
4781
4782 Currently supported index values for cpuid:
4783 Standard CPUID leafs: 0 - 0xA
4784 Extended CPUID leafs: 0x80000000 - 0x8000000A
4785
4786 See the Intel and AMD programmer's manuals for detailed information
4787 about the cpuid instruction and its leafs.
4788
4789 Do not use this method unless you know exactly what you're doing. Misuse can lead to
4790 random crashes inside VMs.
4791 <result name="E_INVALIDARG">
4792 Invalid id.
4793 </result>
4794
4795 </desc>
4796 <param name="id" type="unsigned long" dir="in">
4797 <desc>
4798 CPUID leaf index.
4799 </desc>
4800 </param>
4801 <param name="valEax" type="unsigned long" dir="in">
4802 <desc>
4803 CPUID leaf value for register eax.
4804 </desc>
4805 </param>
4806 <param name="valEbx" type="unsigned long" dir="in">
4807 <desc>
4808 CPUID leaf value for register ebx.
4809 </desc>
4810 </param>
4811 <param name="valEcx" type="unsigned long" dir="in">
4812 <desc>
4813 CPUID leaf value for register ecx.
4814 </desc>
4815 </param>
4816 <param name="valEdx" type="unsigned long" dir="in">
4817 <desc>
4818 CPUID leaf value for register edx.
4819 </desc>
4820 </param>
4821 </method>
4822
4823 <method name="removeCPUIDLeaf">
4824 <desc>
4825 Removes the virtual CPU cpuid leaf for the specified index
4826
4827 <result name="E_INVALIDARG">
4828 Invalid id.
4829 </result>
4830
4831 </desc>
4832 <param name="id" type="unsigned long" dir="in">
4833 <desc>
4834 CPUID leaf index.
4835 </desc>
4836 </param>
4837 </method>
4838
4839 <method name="removeAllCPUIDLeaves">
4840 <desc>
4841 Removes all the virtual CPU cpuid leaves
4842 </desc>
4843 </method>
4844
4845 <method name="getHWVirtExProperty" const="yes">
4846 <desc>
4847 Returns the value of the specified hardware virtualization boolean property.
4848
4849 <result name="E_INVALIDARG">
4850 Invalid property.
4851 </result>
4852
4853 </desc>
4854 <param name="property" type="HWVirtExPropertyType" dir="in">
4855 <desc>
4856 Property type to query.
4857 </desc>
4858 </param>
4859 <param name="value" type="boolean" dir="return">
4860 <desc>
4861 Property value.
4862 </desc>
4863 </param>
4864 </method>
4865
4866 <method name="setHWVirtExProperty">
4867 <desc>
4868 Sets a new value for the specified hardware virtualization boolean property.
4869
4870 <result name="E_INVALIDARG">
4871 Invalid property.
4872 </result>
4873
4874 </desc>
4875 <param name="property" type="HWVirtExPropertyType" dir="in">
4876 <desc>
4877 Property type to set.
4878 </desc>
4879 </param>
4880 <param name="value" type="boolean" dir="in">
4881 <desc>
4882 New property value.
4883 </desc>
4884 </param>
4885 </method>
4886
4887 <method name="saveSettings">
4888 <desc>
4889 Saves any changes to machine settings made since the session
4890 has been opened or a new machine has been created, or since the
4891 last call to <link to="#saveSettings"/> or <link to="#discardSettings"/>.
4892 For registered machines, new settings become visible to all
4893 other VirtualBox clients after successful invocation of this
4894 method.
4895 <note>
4896 The method sends <link to="IMachineDataChangedEvent"/>
4897 notification event after the configuration has been successfully
4898 saved (only for registered machines).
4899 </note>
4900 <note>
4901 Calling this method is only valid on instances returned
4902 by <link to="ISession::machine"/> and on new machines
4903 created by <link to="IVirtualBox::createMachine"/> but not
4904 yet registered, or on unregistered machines after calling
4905 <link to="IMachine::unregister"/>.
4906 </note>
4907
4908 <result name="VBOX_E_FILE_ERROR">
4909 Settings file not accessible.
4910 </result>
4911 <result name="VBOX_E_XML_ERROR">
4912 Could not parse the settings file.
4913 </result>
4914 <result name="E_ACCESSDENIED">
4915 Modification request refused.
4916 </result>
4917
4918 </desc>
4919 </method>
4920
4921 <method name="discardSettings">
4922 <desc>
4923 Discards any changes to the machine settings made since the session
4924 has been opened or since the last call to <link to="#saveSettings"/>
4925 or <link to="#discardSettings"/>.
4926 <note>
4927 Calling this method is only valid on instances returned
4928 by <link to="ISession::machine"/> and on new machines
4929 created by <link to="IVirtualBox::createMachine"/> or
4930 opened by <link to="IVirtualBox::openMachine"/> but not
4931 yet registered, or on unregistered machines after calling
4932 <link to="IMachine::unregister"/>.
4933 </note>
4934
4935 <result name="VBOX_E_INVALID_VM_STATE">
4936 Virtual machine is not mutable.
4937 </result>
4938
4939 </desc>
4940 </method>
4941
4942 <method name="unregister">
4943 <desc>
4944 Unregisters the machine, which must have been previously registered using
4945 <link to="IVirtualBox::registerMachine"/>, and optionally do additional
4946 cleanup before the machine is unregistered.
4947
4948 This method does not delete any files. It only changes the machine configuration and
4949 the list of registered machines in the VirtualBox object. To delete the files which
4950 belonged to the machine, including the XML file of the machine itself, call
4951 <link to="#delete"/>, optionally with the array of IMedium objects which was returned
4952 from this method.
4953
4954 How thoroughly this method cleans up the machine configuration before unregistering
4955 the machine depends on the @a cleanupMode argument.
4956
4957 <ul>
4958 <li>With "UnregisterOnly", the machine will only be unregistered, but no additional
4959 cleanup will be performed. The call will fail if the machine is in "Saved" state
4960 or has any snapshots or any media attached (see <link to="IMediumAttachment" />.
4961 It is the responsibility of the caller to delete all such configuration in this mode.
4962 In this mode, the API behaves like the former @c IVirtualBox::unregisterMachine() API
4963 which it replaces.</li>
4964 <li>With "DetachAllReturnNone", the call will succeed even if the machine is in "Saved"
4965 state or if it has snapshots or media attached. All media attached to the current machine
4966 state or in snapshots will be detached. No medium objects will be returned; all of the
4967 machine's media will remain open.</li>
4968 <li>With "DetachAllReturnHardDisksOnly", the call will behave like with "DetachAllReturnNone",
4969 except that all the hard disk medium objects which were detached from the machine will
4970 be returned as an array. This allows for quickly passing them to the <link to="#delete" />
4971 API for closing and deletion.</li>
4972 <li>With "Full", the call will behave like with "DetachAllReturnHardDisksOnly", except
4973 that all media will be returned in the array, including removeable media like DVDs and
4974 floppies. This might be useful if the user wants to inspect in detail which media were
4975 attached to the machine. Be careful when passing the media array to <link to="#delete" />
4976 in that case because users will typically want to preserve ISO and RAW image files.</li>
4977 </ul>
4978
4979 This API does not verify whether the media files returned in the array are still
4980 attached to other machines (i.e. shared between several machines). If such a shared
4981 image is passed to <link to="#delete" /> however, closing the image will fail there
4982 and the image will be silently skipped.
4983
4984 A typical implementation will use "DetachAllReturnHardDisksOnly" and then pass the
4985 resulting IMedia array to <link to="#delete"/>. This way, the machine is completely
4986 deleted with all its saved states and hard disk images, but images for removeable
4987 drives (such as ISO and RAW files) will remain on disk.
4988
4989 The call will fail if the machine is currently locked (see <link to="ISession" />).
4990 It implicitly calls <link to="#saveSettings"/> to save all current machine settings
4991 before unregistering it.
4992
4993 After successful method invocation, the <link to="IMachineRegisteredEvent"/> event
4994 is fired.
4995
4996 <note>
4997 If the given machine is inaccessible (see <link to="#accessible"/>), it
4998 will be unregistered and fully uninitialized right afterwards. As a result,
4999 the returned machine object will be unusable and an attempt to call
5000 <b>any</b> method will return the "Object not ready" error.
5001 </note>
5002
5003 <result name="VBOX_E_INVALID_OBJECT_STATE">
5004 Machine is currently locked for a session.
5005 </result>
5006 </desc>
5007
5008 <param name="cleanupMode" type="CleanupMode" dir="in">
5009 <desc>How to clean up after the machine has been unregistered.</desc>
5010 </param>
5011 <param name="aMedia" type="IMedium" safearray="yes" dir="return">
5012 <desc>List of media detached from the machine, depending on the @a cleanupMode parameter.</desc>
5013 </param>
5014 </method>
5015
5016 <method name="delete">
5017 <desc>
5018 Deletes the files associated with this machine from disk. If medium objects are passed
5019 in with the @a aMedia argument, they are closed and, if closing was succesful, their
5020 storage files are deleted as well. For convenience, this array of media files can be
5021 the same as the one returned from a previous <link to="#unregister" /> call.
5022
5023 This method must only be called on machines which are either write-locked (i.e. on instances
5024 returned by <link to="ISession::machine"/>) or on unregistered machines (i.e. not yet
5025 registered machines created by <link to="IVirtualBox::createMachine"/> or opened by
5026 <link to="IVirtualBox::openMachine"/>, or after having called <link to="#unregister"/>).
5027
5028 The following files will be deleted by this method:
5029 <ul>
5030 <li>If <link to="#unregister" /> had been previously called with a @a cleanupMode
5031 argument other than "UnregisterOnly", this will delete all saved state files that
5032 the machine had in use; possibly one if the machine was in "Saved" state and one
5033 for each online snapshot that the machine had.</li>
5034 <li>On each medium object passed in the @a aMedia array, this will call
5035 <link to="IMedium::close" />. If that succeeds, this will attempt to delete the
5036 medium's storage on disk. Since the close() call will fail if the medium is still
5037 in use, e.g. because it is still attached to a second machine; in that case the
5038 storage will not be deleted.</li>
5039 <li>Finally, the machine's own XML file will be deleted.</li>
5040 </ul>
5041
5042 Since deleting large disk image files can be a time-consuming I/O operation, this
5043 method operates asynchronously and returns an IProgress object to allow the caller
5044 to monitor the progress. There will be one sub-operation for each file that is
5045 being deleted (saved state or medium storage file).
5046
5047 <note>
5048 <link to="#settingsModified"/> will return @c true after this
5049 method successfully returns.
5050 </note>
5051
5052 <result name="VBOX_E_INVALID_VM_STATE">
5053 Machine is registered but not write-locked.
5054 </result>
5055 <result name="VBOX_E_IPRT_ERROR">
5056 Could not delete the settings file.
5057 </result>
5058 </desc>
5059 <param name="aMedia" type="IMedium" safearray="yes" dir="in">
5060 <desc>List of media to be closed and whose storage files will be deleted.</desc>
5061 </param>
5062 <param name="aProgress" type="IProgress" dir="return">
5063 <desc>Progress object to track the operation completion.</desc>
5064 </param>
5065 </method>
5066
5067 <method name="export">
5068 <desc>Exports the machine to an OVF appliance. See <link to="IAppliance" /> for the
5069 steps required to export VirtualBox machines to OVF.
5070 </desc>
5071
5072 <param name="aAppliance" type="IAppliance" dir="in">
5073 <desc>Appliance to export this machine to.</desc>
5074 </param>
5075 <param name="aDescription" type="IVirtualSystemDescription" dir="return">
5076 <desc>VirtualSystemDescription object which is created for this machine.</desc>
5077 </param>
5078 </method >
5079
5080 <method name="getSnapshot">
5081 <desc>
5082 Returns a snapshot of this machine with the given UUID.
5083 A @c null UUID can be used to obtain the first snapshot
5084 taken on this machine. This is useful if you want to traverse
5085 the whole tree of snapshots starting from the root.
5086
5087 <result name="VBOX_E_OBJECT_NOT_FOUND">
5088 Virtual machine has no snapshots or snapshot not found.
5089 </result>
5090
5091 </desc>
5092 <param name="id" type="uuid" mod="string" dir="in">
5093 <desc>UUID of the snapshot to get</desc>
5094 </param>
5095 <param name="snapshot" type="ISnapshot" dir="return">
5096 <desc>Snapshot object with the given UUID.</desc>
5097 </param>
5098 </method>
5099
5100 <method name="findSnapshot">
5101 <desc>
5102 Returns a snapshot of this machine with the given name.
5103
5104 <result name="VBOX_E_OBJECT_NOT_FOUND">
5105 Virtual machine has no snapshots or snapshot not found.
5106 </result>
5107
5108 </desc>
5109 <param name="name" type="wstring" dir="in">
5110 <desc>Name of the snapshot to find</desc>
5111 </param>
5112 <param name="snapshot" type="ISnapshot" dir="return">
5113 <desc>Snapshot object with the given name.</desc>
5114 </param>
5115 </method>
5116
5117 <method name="setCurrentSnapshot">
5118 <desc>
5119 Sets the current snapshot of this machine.
5120 <note>
5121 In the current implementation, this operation is not
5122 implemented.
5123 </note>
5124 </desc>
5125 <param name="id" type="uuid" mod="string" dir="in">
5126 <desc>UUID of the snapshot to set as the current snapshot.</desc>
5127 </param>
5128 </method>
5129
5130 <method name="createSharedFolder">
5131 <desc>
5132 Creates a new permanent shared folder by associating the given logical
5133 name with the given host path, adds it to the collection of shared
5134 folders and starts sharing it. Refer to the description of
5135 <link to="ISharedFolder"/> to read more about logical names.
5136
5137 <result name="VBOX_E_OBJECT_IN_USE">
5138 Shared folder already exists.
5139 </result>
5140 <result name="VBOX_E_FILE_ERROR">
5141 Shared folder @a hostPath not accessible.
5142 </result>
5143
5144 </desc>
5145 <param name="name" type="wstring" dir="in">
5146 <desc>Unique logical name of the shared folder.</desc>
5147 </param>
5148 <param name="hostPath" type="wstring" dir="in">
5149 <desc>Full path to the shared folder in the host file system.</desc>
5150 </param>
5151 <param name="writable" type="boolean" dir="in">
5152 <desc>Whether the share is writable or readonly.</desc>
5153 </param>
5154 <param name="automount" type="boolean" dir="in">
5155 <desc>Whether the share gets automatically mounted by the guest
5156 or not.</desc>
5157 </param>
5158 </method>
5159
5160 <method name="removeSharedFolder">
5161 <desc>
5162 Removes the permanent shared folder with the given name previously
5163 created by <link to="#createSharedFolder"/> from the collection of
5164 shared folders and stops sharing it.
5165
5166 <result name="VBOX_E_INVALID_VM_STATE">
5167 Virtual machine is not mutable.
5168 </result>
5169 <result name="VBOX_E_OBJECT_NOT_FOUND">
5170 Shared folder @a name does not exist.
5171 </result>
5172
5173 </desc>
5174 <param name="name" type="wstring" dir="in">
5175 <desc>Logical name of the shared folder to remove.</desc>
5176 </param>
5177 </method>
5178
5179 <method name="canShowConsoleWindow">
5180 <desc>
5181 Returns @c true if the VM console process can activate the
5182 console window and bring it to foreground on the desktop of
5183 the host PC.
5184 <note>
5185 This method will fail if a session for this machine is not
5186 currently open.
5187 </note>
5188
5189 <result name="VBOX_E_INVALID_VM_STATE">
5190 Machine session is not open.
5191 </result>
5192
5193 </desc>
5194 <param name="canShow" type="boolean" dir="return">
5195 <desc>
5196 @c true if the console window can be shown and @c false otherwise.
5197 </desc>
5198 </param>
5199 </method>
5200
5201 <method name="showConsoleWindow">
5202 <desc>
5203 Activates the console window and brings it to foreground on
5204 the desktop of the host PC. Many modern window managers on
5205 many platforms implement some sort of focus stealing
5206 prevention logic, so that it may be impossible to activate
5207 a window without the help of the currently active
5208 application. In this case, this method will return a non-zero
5209 identifier that represents the top-level window of the VM
5210 console process. The caller, if it represents a currently
5211 active process, is responsible to use this identifier (in a
5212 platform-dependent manner) to perform actual window
5213 activation.
5214 <note>
5215 This method will fail if a session for this machine is not
5216 currently open.
5217 </note>
5218
5219 <result name="VBOX_E_INVALID_VM_STATE">
5220 Machine session is not open.
5221 </result>
5222
5223 </desc>
5224 <param name="winId" type="long long" dir="return">
5225 <desc>
5226 Platform-dependent identifier of the top-level VM console
5227 window, or zero if this method has performed all actions
5228 necessary to implement the <i>show window</i> semantics for
5229 the given platform and/or VirtualBox front-end.
5230 </desc>
5231 </param>
5232 </method>
5233
5234 <method name="getGuestProperty" const="yes">
5235 <desc>
5236 Reads an entry from the machine's guest property store.
5237
5238 <result name="VBOX_E_INVALID_VM_STATE">
5239 Machine session is not open.
5240 </result>
5241
5242 </desc>
5243 <param name="name" type="wstring" dir="in">
5244 <desc>
5245 The name of the property to read.
5246 </desc>
5247 </param>
5248 <param name="value" type="wstring" dir="out">
5249 <desc>
5250 The value of the property. If the property does not exist then this
5251 will be empty.
5252 </desc>
5253 </param>
5254 <param name="timestamp" type="long long" dir="out">
5255 <desc>
5256 The time at which the property was last modified, as seen by the
5257 server process.
5258 </desc>
5259 </param>
5260 <param name="flags" type="wstring" dir="out">
5261 <desc>
5262 Additional property parameters, passed as a comma-separated list of
5263 "name=value" type entries.
5264 </desc>
5265 </param>
5266 </method>
5267
5268 <method name="getGuestPropertyValue" const="yes">
5269 <desc>
5270 Reads a value from the machine's guest property store.
5271
5272 <result name="VBOX_E_INVALID_VM_STATE">
5273 Machine session is not open.
5274 </result>
5275
5276 </desc>
5277 <param name="property" type="wstring" dir="in">
5278 <desc>
5279 The name of the property to read.
5280 </desc>
5281 </param>
5282 <param name="value" type="wstring" dir="return">
5283 <desc>
5284 The value of the property. If the property does not exist then this
5285 will be empty.
5286 </desc>
5287 </param>
5288 </method>
5289
5290 <method name="getGuestPropertyTimestamp" const="yes">
5291 <desc>
5292 Reads a property timestamp from the machine's guest property store.
5293
5294 <result name="VBOX_E_INVALID_VM_STATE">
5295 Machine session is not open.
5296 </result>
5297
5298 </desc>
5299 <param name="property" type="wstring" dir="in">
5300 <desc>
5301 The name of the property to read.
5302 </desc>
5303 </param>
5304 <param name="value" type="long long" dir="return">
5305 <desc>
5306 The timestamp. If the property does not exist then this will be
5307 empty.
5308 </desc>
5309 </param>
5310 </method>
5311
5312 <method name="setGuestProperty">
5313 <desc>
5314 Sets, changes or deletes an entry in the machine's guest property
5315 store.
5316
5317 <result name="E_ACCESSDENIED">
5318 Property cannot be changed.
5319 </result>
5320 <result name="E_INVALIDARG">
5321 Invalid @a flags.
5322 </result>
5323 <result name="VBOX_E_INVALID_VM_STATE">
5324 Virtual machine is not mutable or session not open.
5325 </result>
5326 <result name="VBOX_E_INVALID_OBJECT_STATE">
5327 Cannot set transient property when machine not running.
5328 </result>
5329
5330 </desc>
5331 <param name="property" type="wstring" dir="in">
5332 <desc>
5333 The name of the property to set, change or delete.
5334 </desc>
5335 </param>
5336 <param name="value" type="wstring" dir="in">
5337 <desc>
5338 The new value of the property to set, change or delete. If the
5339 property does not yet exist and value is non-empty, it will be
5340 created. If the value is @c null or empty, the property will be
5341 deleted if it exists.
5342 </desc>
5343 </param>
5344 <param name="flags" type="wstring" dir="in">
5345 <desc>
5346 Additional property parameters, passed as a comma-separated list of
5347 "name=value" type entries.
5348 </desc>
5349 </param>
5350 </method>
5351
5352 <method name="setGuestPropertyValue">
5353 <desc>
5354 Sets, changes or deletes a value in the machine's guest property
5355 store. The flags field will be left unchanged or created empty for a
5356 new property.
5357
5358 <result name="E_ACCESSDENIED">
5359 Property cannot be changed.
5360 </result>
5361 <result name="VBOX_E_INVALID_VM_STATE">
5362 Virtual machine is not mutable or session not open.
5363 </result>
5364 <result name="VBOX_E_INVALID_OBJECT_STATE">
5365 Cannot set transient property when machine not running.
5366 </result>
5367 </desc>
5368
5369 <param name="property" type="wstring" dir="in">
5370 <desc>
5371 The name of the property to set, change or delete.
5372 </desc>
5373 </param>
5374 <param name="value" type="wstring" dir="in">
5375 <desc>
5376 The new value of the property to set, change or delete. If the
5377 property does not yet exist and value is non-empty, it will be
5378 created. If the value is @c null or empty, the property will be
5379 deleted if it exists.
5380 </desc>
5381 </param>
5382 </method>
5383
5384 <method name="enumerateGuestProperties">
5385 <desc>
5386 Return a list of the guest properties matching a set of patterns along
5387 with their values, time stamps and flags.
5388 </desc>
5389 <param name="patterns" type="wstring" dir="in">
5390 <desc>
5391 The patterns to match the properties against, separated by '|'
5392 characters. If this is empty or @c null, all properties will match.
5393 </desc>
5394 </param>
5395 <param name="name" type="wstring" dir="out" safearray="yes">
5396 <desc>
5397 The names of the properties returned.
5398 </desc>
5399 </param>
5400 <param name="value" type="wstring" dir="out" safearray="yes">
5401 <desc>
5402 The values of the properties returned. The array entries match the
5403 corresponding entries in the @a name array.
5404 </desc>
5405 </param>
5406 <param name="timestamp" type="long long" dir="out" safearray="yes">
5407 <desc>
5408 The time stamps of the properties returned. The array entries match
5409 the corresponding entries in the @a name array.
5410 </desc>
5411 </param>
5412 <param name="flags" type="wstring" dir="out" safearray="yes">
5413 <desc>
5414 The flags of the properties returned. The array entries match the
5415 corresponding entries in the @a name array.
5416 </desc>
5417 </param>
5418 </method>
5419
5420 <method name="querySavedGuestSize">
5421 <desc>
5422 Returns the guest dimensions from the saved state.
5423 </desc>
5424 <param name="screenId" type="unsigned long" dir="in">
5425 <desc>
5426 Saved guest screen to query info from.
5427 </desc>
5428 </param>
5429 <param name="width" type="unsigned long" dir="out">
5430 <desc>
5431 Guest width at the time of the saved state was taken.
5432 </desc>
5433 </param>
5434 <param name="height" type="unsigned long" dir="out">
5435 <desc>
5436 Guest height at the time of the saved state was taken.
5437 </desc>
5438 </param>
5439 </method>
5440
5441 <method name="querySavedThumbnailSize">
5442 <desc>
5443 Returns size in bytes and dimensions in pixels of a saved thumbnail bitmap from saved state.
5444 </desc>
5445 <param name="screenId" type="unsigned long" dir="in">
5446 <desc>
5447 Saved guest screen to query info from.
5448 </desc>
5449 </param>
5450 <param name="size" type="unsigned long" dir="out">
5451 <desc>
5452 Size of buffer required to store the bitmap.
5453 </desc>
5454 </param>
5455 <param name="width" type="unsigned long" dir="out">
5456 <desc>
5457 Bitmap width.
5458 </desc>
5459 </param>
5460 <param name="height" type="unsigned long" dir="out">
5461 <desc>
5462 Bitmap height.
5463 </desc>
5464 </param>
5465 </method>
5466
5467 <method name="readSavedThumbnailToArray">
5468 <desc>
5469 Thumbnail is retrieved to an array of bytes in uncompressed 32-bit BGRA or RGBA format.
5470 </desc>
5471 <param name="screenId" type="unsigned long" dir="in">
5472 <desc>
5473 Saved guest screen to read from.
5474 </desc>
5475 </param>
5476 <param name="BGR" type="boolean" dir="in">
5477 <desc>
5478 How to order bytes in the pixel. A pixel consists of 4 bytes. If this parameter is true, then
5479 bytes order is: B, G, R, 0xFF. If this parameter is false, then bytes order is: R, G, B, 0xFF.
5480 </desc>
5481 </param>
5482 <param name="width" type="unsigned long" dir="out">
5483 <desc>
5484 Bitmap width.
5485 </desc>
5486 </param>
5487 <param name="height" type="unsigned long" dir="out">
5488 <desc>
5489 Bitmap height.
5490 </desc>
5491 </param>
5492 <param name="data" type="octet" safearray="yes" dir="return">
5493 <desc>
5494 Array with resulting bitmap data.
5495 </desc>
5496 </param>
5497 </method>
5498
5499 <method name="readSavedThumbnailPNGToArray">
5500 <desc>
5501 Thumbnail in PNG format is retrieved to an array of bytes.
5502 </desc>
5503 <param name="screenId" type="unsigned long" dir="in">
5504 <desc>
5505 Saved guest screen to read from.
5506 </desc>
5507 </param>
5508 <param name="width" type="unsigned long" dir="out">
5509 <desc>
5510 Image width.
5511 </desc>
5512 </param>
5513 <param name="height" type="unsigned long" dir="out">
5514 <desc>
5515 Image height.
5516 </desc>
5517 </param>
5518 <param name="data" type="octet" dir="return" safearray="yes">
5519 <desc>
5520 Array with resulting PNG data.
5521 </desc>
5522 </param>
5523 </method>
5524
5525 <method name="querySavedScreenshotPNGSize">
5526 <desc>
5527 Returns size in bytes and dimensions of a saved PNG image of screenshot from saved state.
5528 </desc>
5529 <param name="screenId" type="unsigned long" dir="in">
5530 <desc>
5531 Saved guest screen to query info from.
5532 </desc>
5533 </param>
5534 <param name="size" type="unsigned long" dir="out">
5535 <desc>
5536 Size of buffer required to store the PNG binary data.
5537 </desc>
5538 </param>
5539 <param name="width" type="unsigned long" dir="out">
5540 <desc>
5541 Image width.
5542 </desc>
5543 </param>
5544 <param name="height" type="unsigned long" dir="out">
5545 <desc>
5546 Image height.
5547 </desc>
5548 </param>
5549 </method>
5550
5551 <method name="readSavedScreenshotPNGToArray">
5552 <desc>
5553 Screenshot in PNG format is retrieved to an array of bytes.
5554 </desc>
5555 <param name="screenId" type="unsigned long" dir="in">
5556 <desc>
5557 Saved guest screen to read from.
5558 </desc>
5559 </param>
5560 <param name="width" type="unsigned long" dir="out">
5561 <desc>
5562 Image width.
5563 </desc>
5564 </param>
5565 <param name="height" type="unsigned long" dir="out">
5566 <desc>
5567 Image height.
5568 </desc>
5569 </param>
5570 <param name="data" type="octet" dir="return" safearray="yes">
5571 <desc>
5572 Array with resulting PNG data.
5573 </desc>
5574 </param>
5575 </method>
5576
5577 <method name="hotPlugCPU">
5578 <desc>
5579 Plugs a CPU into the machine.
5580 </desc>
5581 <param name="cpu" type="unsigned long" dir="in">
5582 <desc>
5583 The CPU id to insert.
5584 </desc>
5585 </param>
5586 </method>
5587
5588 <method name="hotUnplugCPU">
5589 <desc>
5590 Removes a CPU from the machine.
5591 </desc>
5592 <param name="cpu" type="unsigned long" dir="in">
5593 <desc>
5594 The CPU id to remove.
5595 </desc>
5596 </param>
5597 </method>
5598
5599 <method name="getCPUStatus">
5600 <desc>
5601 Returns the current status of the given CPU.
5602 </desc>
5603 <param name="cpu" type="unsigned long" dir="in">
5604 <desc>
5605 The CPU id to check for.
5606 </desc>
5607 </param>
5608 <param name="attached" type="boolean" dir="return">
5609 <desc>
5610 Status of the CPU.
5611 </desc>
5612 </param>
5613 </method>
5614
5615 <method name="queryLogFilename">
5616 <desc>
5617 Queries for the VM log file name of an given index. Returns an empty
5618 string if a log file with that index doesn't exists.
5619 </desc>
5620 <param name="idx" type="unsigned long" dir="in">
5621 <desc>
5622 Which log file name to query. 0=current log file.
5623 </desc>
5624 </param>
5625 <param name="filename" type="wstring" dir="return">
5626 <desc>
5627 On return the full path to the log file or an empty string on error.
5628 </desc>
5629 </param>
5630 </method>
5631
5632 <method name="readLog">
5633 <desc>
5634 Reads the VM log file. The chunk size is limited, so even if you
5635 ask for a big piece there might be less data returned.
5636 </desc>
5637 <param name="idx" type="unsigned long" dir="in">
5638 <desc>
5639 Which log file to read. 0=current log file.
5640 </desc>
5641 </param>
5642 <param name="offset" type="long long" dir="in">
5643 <desc>
5644 Offset in the log file.
5645 </desc>
5646 </param>
5647 <param name="size" type="long long" dir="in">
5648 <desc>
5649 Chunk size to read in the log file.
5650 </desc>
5651 </param>
5652 <param name="data" type="octet" dir="return" safearray="yes">
5653 <desc>
5654 Data read from the log file. A data size of 0 means end of file
5655 if the requested chunk size was not 0. This is the unprocessed
5656 file data, i.e. the line ending style depends on the platform of
5657 the system the server is running on.
5658 </desc>
5659 </param>
5660 </method>
5661 </interface>
5662
5663 <!--
5664 // IConsole
5665 /////////////////////////////////////////////////////////////////////////
5666 -->
5667
5668 <interface
5669 name="IRemoteDisplayInfo" extends="$unknown"
5670 uuid="b3741084-806f-4c3b-8c42-ebad1a81e45a"
5671 wsmap="struct"
5672 >
5673 <desc>
5674 Contains information about the remote display (VRDP) capabilities and status.
5675 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
5676 </desc>
5677
5678 <attribute name="active" type="boolean" readonly="yes">
5679 <desc>
5680 Whether the remote display connection is active.
5681 </desc>
5682 </attribute>
5683
5684 <attribute name="port" type="long" readonly="yes">
5685 <desc>
5686 VRDP server port number. If this property is equal to <tt>0</tt>, then
5687 the VRDP server failed to start, usually because there are no free TCP
5688 ports to bind to. If this property is equal to <tt>-1</tt>, then the VRDP
5689 server has not yet been started.
5690 </desc>
5691 </attribute>
5692
5693 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
5694 <desc>
5695 How many times a client connected.
5696 </desc>
5697 </attribute>
5698
5699 <attribute name="beginTime" type="long long" readonly="yes">
5700 <desc>
5701 When the last connection was established, in milliseconds since 1970-01-01 UTC.
5702 </desc>
5703 </attribute>
5704
5705 <attribute name="endTime" type="long long" readonly="yes">
5706 <desc>
5707 When the last connection was terminated or the current time, if
5708 connection is still active, in milliseconds since 1970-01-01 UTC.
5709 </desc>
5710 </attribute>
5711
5712 <attribute name="bytesSent" type="long long" readonly="yes">
5713 <desc>
5714 How many bytes were sent in last or current, if still active, connection.
5715 </desc>
5716 </attribute>
5717
5718 <attribute name="bytesSentTotal" type="long long" readonly="yes">
5719 <desc>
5720 How many bytes were sent in all connections.
5721 </desc>
5722 </attribute>
5723
5724 <attribute name="bytesReceived" type="long long" readonly="yes">
5725 <desc>
5726 How many bytes were received in last or current, if still active, connection.
5727 </desc>
5728 </attribute>
5729
5730 <attribute name="bytesReceivedTotal" type="long long" readonly="yes">
5731 <desc>
5732 How many bytes were received in all connections.
5733 </desc>
5734 </attribute>
5735
5736 <attribute name="user" type="wstring" readonly="yes">
5737 <desc>
5738 Login user name supplied by the client.
5739 </desc>
5740 </attribute>
5741
5742 <attribute name="domain" type="wstring" readonly="yes">
5743 <desc>
5744 Login domain name supplied by the client.
5745 </desc>
5746 </attribute>
5747
5748 <attribute name="clientName" type="wstring" readonly="yes">
5749 <desc>
5750 The client name supplied by the client.
5751 </desc>
5752 </attribute>
5753
5754 <attribute name="clientIP" type="wstring" readonly="yes">
5755 <desc>
5756 The IP address of the client.
5757 </desc>
5758 </attribute>
5759
5760 <attribute name="clientVersion" type="unsigned long" readonly="yes">
5761 <desc>
5762 The client software version number.
5763 </desc>
5764 </attribute>
5765
5766 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
5767 <desc>
5768 Public key exchange method used when connection was established.
5769 Values: 0 - RDP4 public key exchange scheme.
5770 1 - X509 certificates were sent to client.
5771 </desc>
5772 </attribute>
5773
5774 </interface>
5775
5776 <interface
5777 name="IConsole" extends="$unknown"
5778 uuid="03cb7897-ea17-4e6c-81ae-4bd90be2fde2"
5779 wsmap="managed"
5780 >
5781 <desc>
5782 The IConsole interface represents an interface to control virtual
5783 machine execution.
5784
5785 A console object gets created when a machine has been locked for a
5786 particular session (client process) using <link to="IMachine::lockMachine" />
5787 or <link to="IMachine::launchVMProcess"/>. The console object can
5788 then be found in the session's <link to="ISession::console" /> attribute.
5789
5790 Methods of the IConsole interface allow the caller to query the current
5791 virtual machine execution state, pause the machine or power it down, save
5792 the machine state or take a snapshot, attach and detach removable media
5793 and so on.
5794
5795 <see>ISession</see>
5796 </desc>
5797
5798 <attribute name="machine" type="IMachine" readonly="yes">
5799 <desc>
5800 Machine object this console is sessioned with.
5801 <note>
5802 This is a convenience property, it has the same value as
5803 <link to="ISession::machine"/> of the corresponding session
5804 object.
5805 </note>
5806 </desc>
5807 </attribute>
5808
5809 <attribute name="state" type="MachineState" readonly="yes">
5810 <desc>
5811 Current execution state of the machine.
5812 <note>
5813 This property always returns the same value as the corresponding
5814 property of the IMachine object this console is sessioned with.
5815 For the process that owns (executes) the VM, this is the
5816 preferable way of querying the VM state, because no IPC
5817 calls are made.
5818 </note>
5819 </desc>
5820 </attribute>
5821
5822 <attribute name="guest" type="IGuest" readonly="yes">
5823 <desc>Guest object.</desc>
5824 </attribute>
5825
5826 <attribute name="keyboard" type="IKeyboard" readonly="yes">
5827 <desc>
5828 Virtual keyboard object.
5829 <note>
5830 If the machine is not running, any attempt to use
5831 the returned object will result in an error.
5832 </note>
5833 </desc>
5834 </attribute>
5835
5836 <attribute name="mouse" type="IMouse" readonly="yes">
5837 <desc>
5838 Virtual mouse object.
5839 <note>
5840 If the machine is not running, any attempt to use
5841 the returned object will result in an error.
5842 </note>
5843 </desc>
5844 </attribute>
5845
5846 <attribute name="display" type="IDisplay" readonly="yes">
5847 <desc>Virtual display object.
5848 <note>
5849 If the machine is not running, any attempt to use
5850 the returned object will result in an error.
5851 </note>
5852 </desc>
5853 </attribute>
5854
5855 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
5856 <desc>Debugging interface.</desc>
5857 </attribute>
5858
5859 <attribute name="USBDevices" type="IUSBDevice" readonly="yes" safearray="yes">
5860 <desc>
5861 Collection of USB devices currently attached to the virtual
5862 USB controller.
5863 <note>
5864 The collection is empty if the machine is not running.
5865 </note>
5866 </desc>
5867 </attribute>
5868
5869 <attribute name="remoteUSBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
5870 <desc>
5871 List of USB devices currently attached to the remote VRDP client.
5872 Once a new device is physically attached to the remote host computer,
5873 it appears in this list and remains there until detached.
5874 </desc>
5875 </attribute>
5876
5877 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
5878 <desc>
5879 Collection of shared folders for the current session. These folders
5880 are called transient shared folders because they are available to the
5881 guest OS running inside the associated virtual machine only for the
5882 duration of the session (as opposed to
5883 <link to="IMachine::sharedFolders"/> which represent permanent shared
5884 folders). When the session is closed (e.g. the machine is powered down),
5885 these folders are automatically discarded.
5886
5887 New shared folders are added to the collection using
5888 <link to="#createSharedFolder"/>. Existing shared folders can be
5889 removed using <link to="#removeSharedFolder"/>.
5890 </desc>
5891 </attribute>
5892
5893 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
5894 <desc>
5895 Interface that provides information on Remote Display (VRDP) connection.
5896 </desc>
5897 </attribute>
5898
5899 <attribute name="eventSource" type="IEventSource" readonly="yes">
5900 <desc>
5901 Event source for console events.
5902 </desc>
5903 </attribute>
5904
5905 <method name="powerUp">
5906 <desc>
5907 Starts the virtual machine execution using the current machine
5908 state (that is, its current execution state, current settings and
5909 current storage devices).
5910
5911 <note>
5912 This method is only useful for front-ends that want to actually
5913 execute virtual machines in their own process (like the VirtualBox
5914 or VBoxSDL front-ends). Unless you are intending to write such a
5915 front-end, do not call this method. If you simply want to
5916 start virtual machine execution using one of the existing front-ends
5917 (for example the VirtualBox GUI or headless server), use
5918 <link to="IMachine::launchVMProcess"/> instead; these
5919 front-ends will power up the machine automatically for you.
5920 </note>
5921
5922 If the machine is powered off or aborted, the execution will
5923 start from the beginning (as if the real hardware were just
5924 powered on).
5925
5926 If the machine is in the <link to="MachineState_Saved"/> state,
5927 it will continue its execution the point where the state has
5928 been saved.
5929
5930 If the machine <link to="IMachine::teleporterEnabled"/> property is
5931 enabled on the machine being powered up, the machine will wait for an
5932 incoming teleportation in the <link to="MachineState_TeleportingIn"/>
5933 state. The returned progress object will have at least three
5934 operations where the last three are defined as: (1) powering up and
5935 starting TCP server, (2) waiting for incoming teleportations, and
5936 (3) perform teleportation. These operations will be reflected as the
5937 last three operations of the progress objected returned by
5938 <link to="IMachine::launchVMProcess"/> as well.
5939
5940 <see>#saveState</see>
5941
5942 <result name="VBOX_E_INVALID_VM_STATE">
5943 Virtual machine already running.
5944 </result>
5945 <result name="VBOX_E_HOST_ERROR">
5946 Host interface does not exist or name not set.
5947 </result>
5948 <result name="VBOX_E_FILE_ERROR">
5949 Invalid saved state file.
5950 </result>
5951 </desc>
5952 <param name="progress" type="IProgress" dir="return">
5953 <desc>Progress object to track the operation completion.</desc>
5954 </param>
5955 </method>
5956
5957 <method name="powerUpPaused">
5958 <desc>
5959 Identical to powerUp except that the VM will enter the
5960 <link to="MachineState_Paused"/> state, instead of
5961 <link to="MachineState_Running"/>.
5962
5963 <see>#powerUp</see>
5964 <result name="VBOX_E_INVALID_VM_STATE">
5965 Virtual machine already running.
5966 </result>
5967 <result name="VBOX_E_HOST_ERROR">
5968 Host interface does not exist or name not set.
5969 </result>
5970 <result name="VBOX_E_FILE_ERROR">
5971 Invalid saved state file.
5972 </result>
5973 </desc>
5974 <param name="progress" type="IProgress" dir="return">
5975 <desc>Progress object to track the operation completion.</desc>
5976 </param>
5977 </method>
5978
5979 <method name="powerDown">
5980 <desc>
5981 Initiates the power down procedure to stop the virtual machine
5982 execution.
5983
5984 The completion of the power down procedure is tracked using the returned
5985 IProgress object. After the operation is complete, the machine will go
5986 to the PoweredOff state.
5987 <result name="VBOX_E_INVALID_VM_STATE">
5988 Virtual machine must be Running, Paused or Stuck to be powered down.
5989 </result>
5990 </desc>
5991 <param name="progress" type="IProgress" dir="return">
5992 <desc>Progress object to track the operation completion.</desc>
5993 </param>
5994 </method>
5995
5996 <method name="reset">
5997 <desc>Resets the virtual machine.
5998 <result name="VBOX_E_INVALID_VM_STATE">
5999 Virtual machine not in Running state.
6000 </result>
6001 <result name="VBOX_E_VM_ERROR">
6002 Virtual machine error in reset operation.
6003 </result>
6004 </desc>
6005 </method>
6006
6007 <method name="pause">
6008 <desc>Pauses the virtual machine execution.
6009 <result name="VBOX_E_INVALID_VM_STATE">
6010 Virtual machine not in Running state.
6011 </result>
6012 <result name="VBOX_E_VM_ERROR">
6013 Virtual machine error in suspend operation.
6014 </result>
6015 </desc>
6016 </method>
6017
6018 <method name="resume">
6019 <desc>Resumes the virtual machine execution.
6020 <result name="VBOX_E_INVALID_VM_STATE">
6021 Virtual machine not in Paused state.
6022 </result>
6023 <result name="VBOX_E_VM_ERROR">
6024 Virtual machine error in resume operation.
6025 </result>
6026 </desc>
6027 </method>
6028
6029 <method name="powerButton">
6030 <desc>Sends the ACPI power button event to the guest.
6031 <result name="VBOX_E_INVALID_VM_STATE">
6032 Virtual machine not in Running state.
6033 </result>
6034 <result name="VBOX_E_PDM_ERROR">
6035 Controlled power off failed.
6036 </result>
6037 </desc>
6038 </method>
6039
6040 <method name="sleepButton">
6041 <desc>Sends the ACPI sleep button event to the guest.
6042 <result name="VBOX_E_INVALID_VM_STATE">
6043 Virtual machine not in Running state.
6044 </result>
6045 <result name="VBOX_E_PDM_ERROR">
6046 Sending sleep button event failed.
6047 </result>
6048 </desc>
6049 </method>
6050
6051 <method name="getPowerButtonHandled">
6052 <desc>Checks if the last power button event was handled by guest.
6053 <result name="VBOX_E_PDM_ERROR">
6054 Checking if the event was handled by the guest OS failed.
6055 </result>
6056 </desc>
6057 <param name="handled" type="boolean" dir="return"/>
6058 </method>
6059
6060 <method name="getGuestEnteredACPIMode">
6061 <desc>Checks if the guest entered the ACPI mode G0 (working) or
6062 G1 (sleeping). If this method returns @c false, the guest will
6063 most likely not respond to external ACPI events.
6064 <result name="VBOX_E_INVALID_VM_STATE">
6065 Virtual machine not in Running state.
6066 </result>
6067 </desc>
6068 <param name="entered" type="boolean" dir="return"/>
6069 </method>
6070
6071 <method name="saveState">
6072 <desc>
6073 Saves the current execution state of a running virtual machine
6074 and stops its execution.
6075
6076 After this operation completes, the machine will go to the
6077 Saved state. Next time it is powered up, this state will
6078 be restored and the machine will continue its execution from
6079 the place where it was saved.
6080
6081 This operation differs from taking a snapshot to the effect
6082 that it doesn't create new differencing media. Also, once
6083 the machine is powered up from the state saved using this method,
6084 the saved state is deleted, so it will be impossible to return
6085 to this state later.
6086
6087 <note>
6088 On success, this method implicitly calls
6089 <link to="IMachine::saveSettings"/> to save all current machine
6090 settings (including runtime changes to the DVD medium, etc.).
6091 Together with the impossibility to change any VM settings when it is
6092 in the Saved state, this guarantees adequate hardware
6093 configuration of the machine when it is restored from the saved
6094 state file.
6095 </note>
6096
6097 <note>
6098 The machine must be in the Running or Paused state, otherwise
6099 the operation will fail.
6100 </note>
6101 <result name="VBOX_E_INVALID_VM_STATE">
6102 Virtual machine state neither Running nor Paused.
6103 </result>
6104 <result name="VBOX_E_FILE_ERROR">
6105 Failed to create directory for saved state file.
6106 </result>
6107
6108 <see><link to="#takeSnapshot"/></see>
6109 </desc>
6110 <param name="progress" type="IProgress" dir="return">
6111 <desc>Progress object to track the operation completion.</desc>
6112 </param>
6113 </method>
6114
6115 <method name="adoptSavedState">
6116 <desc>
6117 Associates the given saved state file to the virtual machine.
6118
6119 On success, the machine will go to the Saved state. Next time it is
6120 powered up, it will be restored from the adopted saved state and
6121 continue execution from the place where the saved state file was
6122 created.
6123
6124 The specified saved state file path may be absolute or relative to the
6125 folder the VM normally saves the state to (usually,
6126 <link to="IMachine::snapshotFolder"/>).
6127
6128 <note>
6129 It's a caller's responsibility to make sure the given saved state
6130 file is compatible with the settings of this virtual machine that
6131 represent its virtual hardware (memory size, storage disk configuration
6132 etc.). If there is a mismatch, the behavior of the virtual machine
6133 is undefined.
6134 </note>
6135 <result name="VBOX_E_INVALID_VM_STATE">
6136 Virtual machine state neither PoweredOff nor Aborted.
6137 </result>
6138 </desc>
6139 <param name="savedStateFile" type="wstring" dir="in">
6140 <desc>Path to the saved state file to adopt.</desc>
6141 </param>
6142 </method>
6143
6144 <method name="discardSavedState">
6145 <desc>
6146 Forcibly resets the machine to "Powered Off" state if it is
6147 currently in the "Saved" state (previously created by <link to="#saveState"/>).
6148 Next time the machine is powered up, a clean boot will occur.
6149 <note>
6150 This operation is equivalent to resetting or powering off
6151 the machine without doing a proper shutdown of the guest
6152 operating system; as with resetting a running phyiscal
6153 computer, it can can lead to data loss.
6154 </note>
6155 If @a fRemoveFile is @c true, the file in the machine directory
6156 into which the machine state was saved is also deleted. If
6157 this is @c false, then the state can be recovered and later
6158 re-inserted into a machine using <link to="#adoptSavedState" />.
6159 The location of the file can be found in the
6160 <link to="IMachine::stateFilePath" /> attribute.
6161 <result name="VBOX_E_INVALID_VM_STATE">
6162 Virtual machine not in state Saved.
6163 </result>
6164 </desc>
6165 <param name="fRemoveFile" type="boolean" dir="in" >
6166 <desc>Whether to also remove the saved state file.</desc>
6167 </param>
6168 </method>
6169
6170 <method name="getDeviceActivity">
6171 <desc>
6172 Gets the current activity type of a given device or device group.
6173 <result name="E_INVALIDARG">
6174 Invalid device type.
6175 </result>
6176 </desc>
6177 <param name="type" type="DeviceType" dir="in"/>
6178 <param name="activity" type="DeviceActivity" dir="return"/>
6179 </method>
6180
6181 <method name="attachUSBDevice">
6182 <desc>
6183 Attaches a host USB device with the given UUID to the
6184 USB controller of the virtual machine.
6185
6186 The device needs to be in one of the following states:
6187 <link to="USBDeviceState_Busy"/>,
6188 <link to="USBDeviceState_Available"/> or
6189 <link to="USBDeviceState_Held"/>,
6190 otherwise an error is immediately returned.
6191
6192 When the device state is
6193 <link to="USBDeviceState_Busy">Busy</link>, an error may also
6194 be returned if the host computer refuses to release it for some reason.
6195
6196 <see>IUSBController::deviceFilters, USBDeviceState</see>
6197 <result name="VBOX_E_INVALID_VM_STATE">
6198 Virtual machine state neither Running nor Paused.
6199 </result>
6200 <result name="VBOX_E_PDM_ERROR">
6201 Virtual machine does not have a USB controller.
6202 </result>
6203 </desc>
6204 <param name="id" type="uuid" mod="string" dir="in">
6205 <desc>UUID of the host USB device to attach.</desc>
6206 </param>
6207 </method>
6208
6209 <method name="detachUSBDevice">
6210 <desc>
6211 Detaches an USB device with the given UUID from the USB controller
6212 of the virtual machine.
6213
6214 After this method succeeds, the VirtualBox server re-initiates
6215 all USB filters as if the device were just physically attached
6216 to the host, but filters of this machine are ignored to avoid
6217 a possible automatic re-attachment.
6218
6219 <see>IUSBController::deviceFilters, USBDeviceState</see>
6220
6221 <result name="VBOX_E_PDM_ERROR">
6222 Virtual machine does not have a USB controller.
6223 </result>
6224 <result name="E_INVALIDARG">
6225 USB device not attached to this virtual machine.
6226 </result>
6227 </desc>
6228 <param name="id" type="uuid" mod="string" dir="in">
6229 <desc>UUID of the USB device to detach.</desc>
6230 </param>
6231 <param name="device" type="IUSBDevice" dir="return">
6232 <desc>Detached USB device.</desc>
6233 </param>
6234 </method>
6235
6236 <method name="findUSBDeviceByAddress">
6237 <desc>
6238 Searches for a USB device with the given host address.
6239
6240 <result name="VBOX_E_OBJECT_NOT_FOUND">
6241 Given @c name does not correspond to any USB device.
6242 </result>
6243
6244 <see>IUSBDevice::address</see>
6245 </desc>
6246 <param name="name" type="wstring" dir="in">
6247 <desc>
6248 Address of the USB device (as assigned by the host) to
6249 search for.
6250 </desc>
6251 </param>
6252 <param name="device" type="IUSBDevice" dir="return">
6253 <desc>Found USB device object.</desc>
6254 </param>
6255 </method>
6256
6257 <method name="findUSBDeviceById">
6258 <desc>
6259 Searches for a USB device with the given UUID.
6260
6261 <result name="VBOX_E_OBJECT_NOT_FOUND">
6262 Given @c id does not correspond to any USB device.
6263 </result>
6264
6265 <see>IUSBDevice::id</see>
6266 </desc>
6267 <param name="id" type="uuid" mod="string" dir="in">
6268 <desc>UUID of the USB device to search for.</desc>
6269 </param>
6270 <param name="device" type="IUSBDevice" dir="return">
6271 <desc>Found USB device object.</desc>
6272 </param>
6273 </method>
6274
6275 <method name="createSharedFolder">
6276 <desc>
6277 Creates a transient new shared folder by associating the given logical
6278 name with the given host path, adds it to the collection of shared
6279 folders and starts sharing it. Refer to the description of
6280 <link to="ISharedFolder"/> to read more about logical names.
6281
6282 <result name="VBOX_E_INVALID_VM_STATE">
6283 Virtual machine in Saved state or currently changing state.
6284 </result>
6285 <result name="VBOX_E_FILE_ERROR">
6286 Shared folder already exists or not accessible.
6287 </result>
6288 </desc>
6289 <param name="name" type="wstring" dir="in">
6290 <desc>Unique logical name of the shared folder.</desc>
6291 </param>
6292 <param name="hostPath" type="wstring" dir="in">
6293 <desc>Full path to the shared folder in the host file system.</desc>
6294 </param>
6295 <param name="writable" type="boolean" dir="in">
6296 <desc>Whether the share is writable or readonly</desc>
6297 </param>
6298 <param name="automount" type="boolean" dir="in">
6299 <desc>Whether the share gets automatically mounted by the guest
6300 or not.</desc>
6301 </param>
6302 </method>
6303
6304 <method name="removeSharedFolder">
6305 <desc>
6306 Removes a transient shared folder with the given name previously
6307 created by <link to="#createSharedFolder"/> from the collection of
6308 shared folders and stops sharing it.
6309 <result name="VBOX_E_INVALID_VM_STATE">
6310 Virtual machine in Saved state or currently changing state.
6311 </result>
6312 <result name="VBOX_E_FILE_ERROR">
6313 Shared folder does not exists.
6314 </result>
6315 </desc>
6316 <param name="name" type="wstring" dir="in">
6317 <desc>Logical name of the shared folder to remove.</desc>
6318 </param>
6319 </method>
6320
6321 <method name="takeSnapshot">
6322 <desc>
6323 Saves the current execution state
6324 and all settings of the machine and creates differencing images
6325 for all normal (non-independent) media.
6326 See <link to="ISnapshot" /> for an introduction to snapshots.
6327
6328 This method can be called for a PoweredOff, Saved (see
6329 <link to="#saveState"/>), Running or
6330 Paused virtual machine. When the machine is PoweredOff, an
6331 offline snapshot is created. When the machine is Running a live
6332 snapshot is created, and an online snapshot is is created when Paused.
6333
6334 The taken snapshot is always based on the
6335 <link to="IMachine::currentSnapshot">current snapshot</link>
6336 of the associated virtual machine and becomes a new current snapshot.
6337
6338 <note>
6339 This method implicitly calls <link to="IMachine::saveSettings"/> to
6340 save all current machine settings before taking an offline snapshot.
6341 </note>
6342
6343 <result name="VBOX_E_INVALID_VM_STATE">
6344 Virtual machine currently changing state.
6345 </result>
6346 </desc>
6347 <param name="name" type="wstring" dir="in">
6348 <desc>Short name for the snapshot.</desc>
6349 </param>
6350 <param name="description" type="wstring" dir="in">
6351 <desc>Optional description of the snapshot.</desc>
6352 </param>
6353 <param name="progress" type="IProgress" dir="return">
6354 <desc>Progress object to track the operation completion.</desc>
6355 </param>
6356 </method>
6357
6358 <method name="deleteSnapshot">
6359 <desc>
6360 Starts deleting the specified snapshot asynchronously.
6361 See <link to="ISnapshot" /> for an introduction to snapshots.
6362
6363 The execution state and settings of the associated machine stored in
6364 the snapshot will be deleted. The contents of all differencing media of
6365 this snapshot will be merged with the contents of their dependent child
6366 media to keep the medium chain valid (in other words, all changes
6367 represented by media being deleted will be propagated to their child
6368 medium). After that, this snapshot's differencing medium will be
6369 deleted. The parent of this snapshot will become a new parent for all
6370 its child snapshots.
6371
6372 If the deleted snapshot is the current one, its parent snapshot will
6373 become a new current snapshot. The current machine state is not directly
6374 affected in this case, except that currently attached differencing
6375 media based on media of the deleted snapshot will be also merged as
6376 described above.
6377
6378 If the deleted snapshot is the first or current snapshot, then the
6379 respective IMachine attributes will be adjusted. Deleting the current
6380 snapshot will also implicitly call <link to="IMachine::saveSettings"/>
6381 to make all current machine settings permanent.
6382
6383 Deleting a snapshot has the following preconditions:
6384
6385 <ul>
6386 <li>Child media of all normal media of the deleted snapshot
6387 must be accessible (see <link to="IMedium::state"/>) for this
6388 operation to succeed. In particular, this means that all virtual
6389 machines, whose media are directly or indirectly based on the
6390 media of deleted snapshot, must be powered off.</li>
6391
6392 <li>You cannot delete the snapshot if a medium attached to it has
6393 more than once child medium (differencing images) because otherwise
6394 merging would be impossible. This might be the case if there is
6395 more than one child snapshot or differencing images were created
6396 for other reason (e.g. implicitly because of multiple machine
6397 attachments).</li>
6398 </ul>
6399
6400
6401 The virtual machine's <link to="IMachine::state">state</link> is
6402 changed to "DeletingSnapshot", "DeletingSnapshotOnline" or
6403 "DeletingSnapshotPaused" while this operation is in progress.
6404
6405 <note>
6406 Merging medium contents can be very time and disk space
6407 consuming, if these media are big in size and have many
6408 children. However, if the snapshot being deleted is the last
6409 (head) snapshot on the branch, the operation will be rather
6410 quick.
6411 </note>
6412 <result name="VBOX_E_INVALID_VM_STATE">
6413 The running virtual machine prevents deleting this snapshot. This
6414 happens only in very specific situations, usually snapshots can be
6415 deleted without trouble while a VM is running. The error message
6416 text explains the reason for the failure.
6417 </result>
6418 </desc>
6419 <param name="id" type="uuid" mod="string" dir="in">
6420 <desc>UUID of the snapshot to delete.</desc>
6421 </param>
6422 <param name="progress" type="IProgress" dir="return">
6423 <desc>Progress object to track the operation completion.</desc>
6424 </param>
6425 </method>
6426
6427 <method name="restoreSnapshot">
6428 <desc>
6429 Starts resetting the machine's current state to the state contained
6430 in the given snapshot, asynchronously. All current settings of the
6431 machine will be reset and changes stored in differencing media
6432 will be lost.
6433 See <link to="ISnapshot" /> for an introduction to snapshots.
6434
6435 After this operation is successfully completed, new empty differencing
6436 media are created for all normal media of the machine.
6437
6438 If the given snapshot is an online snapshot, the machine will go to
6439 the <link to="MachineState_Saved"> saved state</link>, so that the
6440 next time it is powered on, the execution state will be restored
6441 from the state of the snapshot.
6442
6443 <note>
6444 The machine must not be running, otherwise the operation will fail.
6445 </note>
6446
6447 <note>
6448 If the machine state is <link to="MachineState_Saved">Saved</link>
6449 prior to this operation, the saved state file will be implicitly
6450 deleted (as if <link to="IConsole::discardSavedState"/> were
6451 called).
6452 </note>
6453
6454 <result name="VBOX_E_INVALID_VM_STATE">
6455 Virtual machine is running.
6456 </result>
6457 </desc>
6458 <param name="snapshot" type="ISnapshot" dir="in">
6459 <desc>The snapshot to restore the VM state from.</desc>
6460 </param>
6461 <param name="progress" type="IProgress" dir="return">
6462 <desc>Progress object to track the operation completion.</desc>
6463 </param>
6464 </method>
6465
6466 <method name="teleport">
6467 <desc>
6468 Teleport the VM to a different host machine or process.
6469
6470 TODO explain the details.
6471
6472 <result name="VBOX_E_INVALID_VM_STATE">
6473 Virtual machine not running or paused.
6474 </result>
6475 </desc>
6476 <param name="hostname" type="wstring" dir="in">
6477 <desc>The name or IP of the host to teleport to.</desc>
6478 </param>
6479 <param name="tcpport" type="unsigned long" dir="in">
6480 <desc>The TCP port to connect to (1..65535).</desc>
6481 </param>
6482 <param name="password" type="wstring" dir="in">
6483 <desc>The password.</desc>
6484 </param>
6485 <param name="maxDowntime" type="unsigned long" dir="in">
6486 <desc>
6487 The maximum allowed downtime given as milliseconds. 0 is not a valid
6488 value. Recommended value: 250 ms.
6489
6490 The higher the value is, the greater the chance for a successful
6491 teleportation. A small value may easily result in the teleportation
6492 process taking hours and eventually fail.
6493
6494 <note>
6495 The current implementation treats this a guideline, not as an
6496 absolute rule.
6497 </note>
6498 </desc>
6499 </param>
6500 <param name="progress" type="IProgress" dir="return">
6501 <desc>Progress object to track the operation completion.</desc>
6502 </param>
6503 </method>
6504
6505 </interface>
6506
6507 <!--
6508 // IHost
6509 /////////////////////////////////////////////////////////////////////////
6510 -->
6511
6512 <enum
6513 name="HostNetworkInterfaceMediumType"
6514 uuid="1aa54aaf-2497-45a2-bfb1-8eb225e93d5b"
6515 >
6516 <desc>
6517 Type of encapsulation. Ethernet encapsulation includes both wired and
6518 wireless Ethernet connections.
6519 <see>IHostNetworkInterface</see>
6520 </desc>
6521
6522 <const name="Unknown" value="0">
6523 <desc>
6524 The type of interface cannot be determined.
6525 </desc>
6526 </const>
6527 <const name="Ethernet" value="1">
6528 <desc>
6529 Ethernet frame encapsulation.
6530 </desc>
6531 </const>
6532 <const name="PPP" value="2">
6533 <desc>
6534 Point-to-point protocol encapsulation.
6535 </desc>
6536 </const>
6537 <const name="SLIP" value="3">
6538 <desc>
6539 Serial line IP encapsulation.
6540 </desc>
6541 </const>
6542 </enum>
6543
6544 <enum
6545 name="HostNetworkInterfaceStatus"
6546 uuid="CC474A69-2710-434B-8D99-C38E5D5A6F41"
6547 >
6548 <desc>
6549 Current status of the interface.
6550 <see>IHostNetworkInterface</see>
6551 </desc>
6552
6553 <const name="Unknown" value="0">
6554 <desc>
6555 The state of interface cannot be determined.
6556 </desc>
6557 </const>
6558 <const name="Up" value="1">
6559 <desc>
6560 The interface is fully operational.
6561 </desc>
6562 </const>
6563 <const name="Down" value="2">
6564 <desc>
6565 The interface is not functioning.
6566 </desc>
6567 </const>
6568 </enum>
6569
6570 <enum
6571 name="HostNetworkInterfaceType"
6572 uuid="67431b00-9946-48a2-bc02-b25c5919f4f3"
6573 >
6574 <desc>
6575 Network interface type.
6576 </desc>
6577 <const name="Bridged" value="1"/>
6578 <const name="HostOnly" value="2"/>
6579 </enum>
6580
6581 <interface
6582 name="IHostNetworkInterface" extends="$unknown"
6583 uuid="ce6fae58-7642-4102-b5db-c9005c2320a8"
6584 wsmap="managed"
6585 >
6586 <desc>
6587 Represents one of host's network interfaces. IP V6 address and network
6588 mask are strings of 32 hexdecimal digits grouped by four. Groups are
6589 separated by colons.
6590 For example, fe80:0000:0000:0000:021e:c2ff:fed2:b030.
6591 </desc>
6592 <attribute name="name" type="wstring" readonly="yes">
6593 <desc>Returns the host network interface name.</desc>
6594 </attribute>
6595
6596 <attribute name="id" type="uuid" mod="string" readonly="yes">
6597 <desc>Returns the interface UUID.</desc>
6598 </attribute>
6599
6600 <attribute name="networkName" type="wstring" readonly="yes">
6601 <desc>Returns the name of a virtual network the interface gets attached to.</desc>
6602 </attribute>
6603
6604 <attribute name="dhcpEnabled" type="boolean" readonly="yes">
6605 <desc>Specifies whether the DHCP is enabled for the interface.</desc>
6606 </attribute>
6607
6608 <attribute name="IPAddress" type="wstring" readonly="yes">
6609 <desc>Returns the IP V4 address of the interface.</desc>
6610 </attribute>
6611
6612 <attribute name="networkMask" type="wstring" readonly="yes">
6613 <desc>Returns the network mask of the interface.</desc>
6614 </attribute>
6615
6616 <attribute name="IPV6Supported" type="boolean" readonly="yes">
6617 <desc>Specifies whether the IP V6 is supported/enabled for the interface.</desc>
6618 </attribute>
6619
6620 <attribute name="IPV6Address" type="wstring" readonly="yes">
6621 <desc>Returns the IP V6 address of the interface.</desc>
6622 </attribute>
6623
6624 <attribute name="IPV6NetworkMaskPrefixLength" type="unsigned long" readonly="yes">
6625 <desc>Returns the length IP V6 network mask prefix of the interface.</desc>
6626 </attribute>
6627
6628 <attribute name="hardwareAddress" type="wstring" readonly="yes">
6629 <desc>Returns the hardware address. For Ethernet it is MAC address.</desc>
6630 </attribute>
6631
6632 <attribute name="mediumType" type="HostNetworkInterfaceMediumType" readonly="yes">
6633 <desc>Type of protocol encapsulation used.</desc>
6634 </attribute>
6635
6636 <attribute name="status" type="HostNetworkInterfaceStatus" readonly="yes">
6637 <desc>Status of the interface.</desc>
6638 </attribute>
6639
6640 <attribute name="interfaceType" type="HostNetworkInterfaceType" readonly="yes">
6641 <desc>specifies the host interface type.</desc>
6642 </attribute>
6643
6644 <method name="enableStaticIpConfig">
6645 <desc>sets and enables the static IP V4 configuration for the given interface.</desc>
6646 <param name="IPAddress" type="wstring" dir="in">
6647 <desc>
6648 IP address.
6649 </desc>
6650 </param>
6651 <param name="networkMask" type="wstring" dir="in">
6652 <desc>
6653 network mask.
6654 </desc>
6655 </param>
6656 </method>
6657
6658 <method name="enableStaticIpConfigV6">
6659 <desc>sets and enables the static IP V6 configuration for the given interface.</desc>
6660 <param name="IPV6Address" type="wstring" dir="in">
6661 <desc>
6662 IP address.
6663 </desc>
6664 </param>
6665 <param name="IPV6NetworkMaskPrefixLength" type="unsigned long" dir="in">
6666 <desc>
6667 network mask.
6668 </desc>
6669 </param>
6670 </method>
6671
6672 <method name="enableDynamicIpConfig">
6673 <desc>enables the dynamic IP configuration.</desc>
6674 </method>
6675
6676 <method name="dhcpRediscover">
6677 <desc>refreshes the IP configuration for dhcp-enabled interface.</desc>
6678 </method>
6679
6680 </interface>
6681
6682 <interface
6683 name="IHost" extends="$unknown"
6684 uuid="35b004f4-7806-4009-bfa8-d1308adba7e5"
6685 wsmap="managed"
6686 >
6687 <desc>
6688 The IHost interface represents the physical machine that this VirtualBox
6689 installation runs on.
6690
6691 An object implementing this interface is returned by the
6692 <link to="IVirtualBox::host" /> attribute. This interface contains
6693 read-only information about the host's physical hardware (such as what
6694 processors and disks are available, what the host operating system is,
6695 and so on) and also allows for manipulating some of the host's hardware,
6696 such as global USB device filters and host interface networking.
6697
6698 </desc>
6699 <attribute name="DVDDrives" type="IMedium" readonly="yes" safearray="yes">
6700 <desc>List of DVD drives available on the host.</desc>
6701 </attribute>
6702
6703 <attribute name="floppyDrives" type="IMedium" readonly="yes" safearray="yes">
6704 <desc>List of floppy drives available on the host.</desc>
6705 </attribute>
6706
6707 <attribute name="USBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
6708 <desc>
6709 List of USB devices currently attached to the host.
6710 Once a new device is physically attached to the host computer,
6711 it appears in this list and remains there until detached.
6712
6713 <note>
6714 If USB functionality is not available in the given edition of
6715 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6716 </note>
6717 </desc>
6718 </attribute>
6719
6720 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilter" readonly="yes" safearray="yes">
6721 <desc>
6722 List of USB device filters in action.
6723 When a new device is physically attached to the host computer,
6724 filters from this list are applied to it (in order they are stored
6725 in the list). The first matched filter will determine the
6726 <link to="IHostUSBDeviceFilter::action">action</link>
6727 performed on the device.
6728
6729 Unless the device is ignored by these filters, filters of all
6730 currently running virtual machines
6731 (<link to="IUSBController::deviceFilters"/>) are applied to it.
6732
6733 <note>
6734 If USB functionality is not available in the given edition of
6735 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6736 </note>
6737
6738 <see>IHostUSBDeviceFilter, USBDeviceState</see>
6739 </desc>
6740 </attribute>
6741
6742 <attribute name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" readonly="yes">
6743 <desc>List of host network interfaces currently defined on the host.</desc>
6744 </attribute>
6745
6746 <attribute name="processorCount" type="unsigned long" readonly="yes">
6747 <desc>Number of (logical) CPUs installed in the host system.</desc>
6748 </attribute>
6749
6750 <attribute name="processorOnlineCount" type="unsigned long" readonly="yes">
6751 <desc>Number of (logical) CPUs online in the host system.</desc>
6752 </attribute>
6753
6754 <attribute name="processorCoreCount" type="unsigned long" readonly="yes">
6755 <desc>Number of physical processor cores installed in the host system.</desc>
6756 </attribute>
6757
6758 <method name="getProcessorSpeed">
6759 <desc>Query the (approximate) maximum speed of a specified host CPU in
6760 Megahertz.
6761 </desc>
6762 <param name="cpuId" type="unsigned long" dir="in">
6763 <desc>
6764 Identifier of the CPU.
6765 </desc>
6766 </param>
6767 <param name="speed" type="unsigned long" dir="return">
6768 <desc>
6769 Speed value. 0 is returned if value is not known or @a cpuId is
6770 invalid.
6771 </desc>
6772 </param>
6773 </method>
6774
6775 <method name="getProcessorFeature">
6776 <desc>Query whether a CPU feature is supported or not.</desc>
6777 <param name="feature" type="ProcessorFeature" dir="in">
6778 <desc>
6779 CPU Feature identifier.
6780 </desc>
6781 </param>
6782 <param name="supported" type="boolean" dir="return">
6783 <desc>
6784 Feature is supported or not.
6785 </desc>
6786 </param>
6787 </method>
6788
6789 <method name="getProcessorDescription">
6790 <desc>Query the model string of a specified host CPU.
6791 </desc>
6792 <param name="cpuId" type="unsigned long" dir="in">
6793 <desc>
6794 Identifier of the CPU.
6795 <note>
6796 The current implementation might not necessarily return the
6797 description for this exact CPU.
6798 </note>
6799 </desc>
6800 </param>
6801 <param name="description" type="wstring" dir="return">
6802 <desc>
6803 Model string. An empty string is returned if value is not known or
6804 @a cpuId is invalid.
6805 </desc>
6806 </param>
6807 </method>
6808
6809 <method name="getProcessorCPUIDLeaf">
6810 <desc>
6811 Returns the CPU cpuid information for the specified leaf.
6812 </desc>
6813 <param name="cpuId" type="unsigned long" dir="in">
6814 <desc>
6815 Identifier of the CPU. The CPU most be online.
6816 <note>
6817 The current implementation might not necessarily return the
6818 description for this exact CPU.
6819 </note>
6820 </desc>
6821 </param>
6822 <param name="leaf" type="unsigned long" dir="in">
6823 <desc>
6824 CPUID leaf index (eax).
6825 </desc>
6826 </param>
6827 <param name="subLeaf" type="unsigned long" dir="in">
6828 <desc>
6829 CPUID leaf sub index (ecx). This currently only applies to cache
6830 information on Intel CPUs. Use 0 if retriving values for
6831 <link to="IMachine::setCPUIDLeaf"/>.
6832 </desc>
6833 </param>
6834 <param name="valEax" type="unsigned long" dir="out">
6835 <desc>
6836 CPUID leaf value for register eax.
6837 </desc>
6838 </param>
6839 <param name="valEbx" type="unsigned long" dir="out">
6840 <desc>
6841 CPUID leaf value for register ebx.
6842 </desc>
6843 </param>
6844 <param name="valEcx" type="unsigned long" dir="out">
6845 <desc>
6846 CPUID leaf value for register ecx.
6847 </desc>
6848 </param>
6849 <param name="valEdx" type="unsigned long" dir="out">
6850 <desc>
6851 CPUID leaf value for register edx.
6852 </desc>
6853 </param>
6854 </method>
6855
6856 <attribute name="memorySize" type="unsigned long" readonly="yes">
6857 <desc>Amount of system memory in megabytes installed in the host system.</desc>
6858 </attribute>
6859
6860 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
6861 <desc>Available system memory in the host system.</desc>
6862 </attribute>
6863
6864 <attribute name="operatingSystem" type="wstring" readonly="yes">
6865 <desc>Name of the host system's operating system.</desc>
6866 </attribute>
6867
6868 <attribute name="OSVersion" type="wstring" readonly="yes">
6869 <desc>Host operating system's version string.</desc>
6870 </attribute>
6871
6872 <attribute name="UTCTime" type="long long" readonly="yes">
6873 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
6874 </attribute>
6875
6876 <attribute name="Acceleration3DAvailable" type="boolean" readonly="yes">
6877 <desc>Returns @c true when the host supports 3D hardware acceleration.</desc>
6878 </attribute>
6879
6880 <method name="createHostOnlyNetworkInterface">
6881 <desc>
6882 Creates a new adapter for Host Only Networking.
6883 <result name="E_INVALIDARG">
6884 Host network interface @a name already exists.
6885 </result>
6886 </desc>
6887 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
6888 <desc>
6889 Created host interface object.
6890 </desc>
6891 </param>
6892 <param name="progress" type="IProgress" dir="return">
6893 <desc>
6894 Progress object to track the operation completion.
6895 </desc>
6896 </param>
6897 </method>
6898
6899 <method name="removeHostOnlyNetworkInterface">
6900 <desc>
6901 Removes the given Host Only Networking interface.
6902 <result name="VBOX_E_OBJECT_NOT_FOUND">
6903 No host network interface matching @a id found.
6904 </result>
6905 </desc>
6906 <param name="id" type="uuid" mod="string" dir="in">
6907 <desc>
6908 Adapter GUID.
6909 </desc>
6910 </param>
6911 <param name="progress" type="IProgress" dir="return">
6912 <desc>
6913 Progress object to track the operation completion.
6914 </desc>
6915 </param>
6916 </method>
6917
6918 <method name="createUSBDeviceFilter">
6919 <desc>
6920 Creates a new USB device filter. All attributes except
6921 the filter name are set to empty (any match),
6922 <i>active</i> is @c false (the filter is not active).
6923
6924 The created filter can be added to the list of filters using
6925 <link to="#insertUSBDeviceFilter"/>.
6926
6927 <see>#USBDeviceFilters</see>
6928 </desc>
6929 <param name="name" type="wstring" dir="in">
6930 <desc>
6931 Filter name. See <link to="IUSBDeviceFilter::name"/> for more information.
6932 </desc>
6933 </param>
6934 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
6935 <desc>Created filter object.</desc>
6936 </param>
6937 </method>
6938
6939 <method name="insertUSBDeviceFilter">
6940 <desc>
6941 Inserts the given USB device to the specified position
6942 in the list of filters.
6943
6944 Positions are numbered starting from @c 0. If the specified
6945 position is equal to or greater than the number of elements in
6946 the list, the filter is added at the end of the collection.
6947
6948 <note>
6949 Duplicates are not allowed, so an attempt to insert a
6950 filter already in the list is an error.
6951 </note>
6952 <note>
6953 If USB functionality is not available in the given edition of
6954 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6955 </note>
6956
6957 <see>#USBDeviceFilters</see>
6958
6959 <result name="VBOX_E_INVALID_OBJECT_STATE">
6960 USB device filter is not created within this VirtualBox instance.
6961 </result>
6962 <result name="E_INVALIDARG">
6963 USB device filter already in list.
6964 </result>
6965
6966 </desc>
6967 <param name="position" type="unsigned long" dir="in">
6968 <desc>Position to insert the filter to.</desc>
6969 </param>
6970 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
6971 <desc>USB device filter to insert.</desc>
6972 </param>
6973 </method>
6974
6975 <method name="removeUSBDeviceFilter">
6976 <desc>
6977 Removes a USB device filter from the specified position in the
6978 list of filters.
6979
6980 Positions are numbered starting from @c 0. Specifying a
6981 position equal to or greater than the number of elements in
6982 the list will produce an error.
6983
6984 <note>
6985 If USB functionality is not available in the given edition of
6986 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6987 </note>
6988
6989 <see>#USBDeviceFilters</see>
6990
6991 <result name="E_INVALIDARG">
6992 USB device filter list empty or invalid @a position.
6993 </result>
6994
6995 </desc>
6996 <param name="position" type="unsigned long" dir="in">
6997 <desc>Position to remove the filter from.</desc>
6998 </param>
6999 </method>
7000
7001 <method name="findHostDVDDrive">
7002 <desc>
7003 Searches for a host DVD drive with the given @c name.
7004
7005 <result name="VBOX_E_OBJECT_NOT_FOUND">
7006 Given @c name does not correspond to any host drive.
7007 </result>
7008
7009 </desc>
7010 <param name="name" type="wstring" dir="in">
7011 <desc>Name of the host drive to search for</desc>
7012 </param>
7013 <param name="drive" type="IMedium" dir="return">
7014 <desc>Found host drive object</desc>
7015 </param>
7016 </method>
7017
7018 <method name="findHostFloppyDrive">
7019 <desc>
7020 Searches for a host floppy drive with the given @c name.
7021
7022 <result name="VBOX_E_OBJECT_NOT_FOUND">
7023 Given @c name does not correspond to any host floppy drive.
7024 </result>
7025
7026 </desc>
7027 <param name="name" type="wstring" dir="in">
7028 <desc>Name of the host floppy drive to search for</desc>
7029 </param>
7030 <param name="drive" type="IMedium" dir="return">
7031 <desc>Found host floppy drive object</desc>
7032 </param>
7033 </method>
7034
7035 <method name="findHostNetworkInterfaceByName">
7036 <desc>
7037 Searches through all host network interfaces for an interface with
7038 the given @c name.
7039 <note>
7040 The method returns an error if the given @c name does not
7041 correspond to any host network interface.
7042 </note>
7043 </desc>
7044 <param name="name" type="wstring" dir="in">
7045 <desc>Name of the host network interface to search for.</desc>
7046 </param>
7047 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7048 <desc>Found host network interface object.</desc>
7049 </param>
7050 </method>
7051 <method name="findHostNetworkInterfaceById">
7052 <desc>
7053 Searches through all host network interfaces for an interface with
7054 the given GUID.
7055 <note>
7056 The method returns an error if the given GUID does not
7057 correspond to any host network interface.
7058 </note>
7059 </desc>
7060 <param name="id" type="uuid" mod="string" dir="in">
7061 <desc>GUID of the host network interface to search for.</desc>
7062 </param>
7063 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7064 <desc>Found host network interface object.</desc>
7065 </param>
7066 </method>
7067 <method name="findHostNetworkInterfacesOfType">
7068 <desc>
7069 Searches through all host network interfaces and returns a list of interfaces of the specified type
7070 </desc>
7071 <param name="type" type="HostNetworkInterfaceType" dir="in">
7072 <desc>type of the host network interfaces to search for.</desc>
7073 </param>
7074 <param name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" dir="return">
7075 <desc>Found host network interface objects.</desc>
7076 </param>
7077 </method>
7078
7079 <method name="findUSBDeviceById">
7080 <desc>
7081 Searches for a USB device with the given UUID.
7082
7083 <result name="VBOX_E_OBJECT_NOT_FOUND">
7084 Given @c id does not correspond to any USB device.
7085 </result>
7086
7087 <see>IHostUSBDevice::id</see>
7088 </desc>
7089 <param name="id" type="uuid" mod="string" dir="in">
7090 <desc>UUID of the USB device to search for.</desc>
7091 </param>
7092 <param name="device" type="IHostUSBDevice" dir="return">
7093 <desc>Found USB device object.</desc>
7094 </param>
7095 </method>
7096
7097 <method name="findUSBDeviceByAddress">
7098 <desc>
7099 Searches for a USB device with the given host address.
7100
7101 <result name="VBOX_E_OBJECT_NOT_FOUND">
7102 Given @c name does not correspond to any USB device.
7103 </result>
7104
7105 <see>IHostUSBDevice::address</see>
7106 </desc>
7107 <param name="name" type="wstring" dir="in">
7108 <desc>
7109 Address of the USB device (as assigned by the host) to
7110 search for.
7111 </desc>
7112 </param>
7113 <param name="device" type="IHostUSBDevice" dir="return">
7114 <desc>Found USB device object.</desc>
7115 </param>
7116 </method>
7117
7118 </interface>
7119
7120 <!--
7121 // ISystemProperties
7122 /////////////////////////////////////////////////////////////////////////
7123 -->
7124
7125 <interface
7126 name="ISystemProperties"
7127 extends="$unknown"
7128 uuid="f8fff1f1-eeb4-4483-a2a4-b4186fab5a1e"
7129 wsmap="managed"
7130 >
7131 <desc>
7132 The ISystemProperties interface represents global properties of the given
7133 VirtualBox installation.
7134
7135 These properties define limits and default values for various attributes
7136 and parameters. Most of the properties are read-only, but some can be
7137 changed by a user.
7138 </desc>
7139
7140 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
7141 <desc>Minimum guest system memory in Megabytes.</desc>
7142 </attribute>
7143
7144 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
7145 <desc>Maximum guest system memory in Megabytes.</desc>
7146 </attribute>
7147
7148 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
7149 <desc>Minimum guest video memory in Megabytes.</desc>
7150 </attribute>
7151
7152 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
7153 <desc>Maximum guest video memory in Megabytes.</desc>
7154 </attribute>
7155
7156 <attribute name="minGuestCPUCount" type="unsigned long" readonly="yes">
7157 <desc>Minimum CPU count.</desc>
7158 </attribute>
7159
7160 <attribute name="maxGuestCPUCount" type="unsigned long" readonly="yes">
7161 <desc>Maximum CPU count.</desc>
7162 </attribute>
7163
7164 <attribute name="maxGuestMonitors" type="unsigned long" readonly="yes">
7165 <desc>Maximum of monitors which could be connected.</desc>
7166 </attribute>
7167
7168 <attribute name="infoVDSize" type="long long" readonly="yes">
7169 <desc>Maximum size of a virtual disk image in bytes. Informational value,
7170 does not reflect the limits of any virtual disk image format.</desc>
7171 </attribute>
7172
7173 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
7174 <desc>
7175 Number of network adapters associated with every
7176 <link to="IMachine"/> instance.
7177 </desc>
7178 </attribute>
7179
7180 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
7181 <desc>
7182 Number of serial ports associated with every
7183 <link to="IMachine"/> instance.
7184 </desc>
7185 </attribute>
7186
7187 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
7188 <desc>
7189 Number of parallel ports associated with every
7190 <link to="IMachine"/> instance.
7191 </desc>
7192 </attribute>
7193
7194 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
7195 <desc>
7196 Maximum device position in the boot order. This value corresponds
7197 to the total number of devices a machine can boot from, to make it
7198 possible to include all possible devices to the boot list.
7199 <see><link to="IMachine::setBootOrder"/></see>
7200 </desc>
7201 </attribute>
7202
7203 <attribute name="defaultMachineFolder" type="wstring">
7204 <desc>
7205 Full path to the default directory used to create new or open
7206 existing machines when a settings file name contains no
7207 path.
7208
7209 The initial value of this property is
7210 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
7211 VirtualBox_home</link><tt>&gt;/Machines</tt>.
7212
7213 <note>
7214 Setting this property to @c null or an empty string will restore the
7215 initial value.
7216 </note>
7217 <note>
7218 When settings this property, the specified path can be
7219 absolute (full path) or relative
7220 to the <link to="IVirtualBox::homeFolder">
7221 VirtualBox home directory</link>.
7222 When reading this property, a full path is
7223 always returned.
7224 </note>
7225 <note>
7226 The specified path may not exist, it will be created
7227 when necessary.
7228 </note>
7229
7230 <see>
7231 <link to="IVirtualBox::createMachine"/>,
7232 <link to="IVirtualBox::openMachine"/>
7233 </see>
7234 </desc>
7235 </attribute>
7236
7237 <attribute name="mediumFormats" type="IMediumFormat" safearray="yes" readonly="yes">
7238 <desc>
7239 List of all medium storage formats supported by this VirtualBox
7240 installation.
7241
7242 Keep in mind that the medium format identifier
7243 (<link to="IMediumFormat::id"/>) used in other API calls like
7244 <link to="IVirtualBox::createHardDisk"/> to refer to a particular
7245 medium format is a case-insensitive string. This means that, for
7246 example, all of the following strings:
7247 <pre>
7248 "VDI"
7249 "vdi"
7250 "VdI"</pre>
7251 refer to the same medium format.
7252
7253 Note that the virtual medium framework is backend-based, therefore
7254 the list of supported formats depends on what backends are currently
7255 installed.
7256
7257 <see>
7258 <link to="IMediumFormat"/>,
7259 </see>
7260 </desc>
7261 </attribute>
7262
7263 <attribute name="defaultHardDiskFormat" type="wstring">
7264 <desc>
7265 Identifier of the default medium format used by VirtualBox.
7266
7267 The medium format set by this attribute is used by VirtualBox
7268 when the medium format was not specified explicitly. One example is
7269 <link to="IVirtualBox::createHardDisk"/> with the empty
7270 format argument. A more complex example is implicit creation of
7271 differencing media when taking a snapshot of a virtual machine:
7272 this operation will try to use a format of the parent medium first
7273 and if this format does not support differencing media the default
7274 format specified by this argument will be used.
7275
7276 The list of supported medium formats may be obtained by the
7277 <link to="#mediumFormats"/> call. Note that the default medium
7278 format must have a capability to create differencing media;
7279 otherwise operations that create media implicitly may fail
7280 unexpectedly.
7281
7282 The initial value of this property is <tt>"VDI"</tt> in the current
7283 version of the VirtualBox product, but may change in the future.
7284
7285 <note>
7286 Setting this property to @c null or empty string will restore the
7287 initial value.
7288 </note>
7289
7290 <see>
7291 <link to="#mediumFormats"/>,
7292 <link to="IMediumFormat::id"/>,
7293 <link to="IVirtualBox::createHardDisk"/>
7294 </see>
7295 </desc>
7296 </attribute>
7297
7298 <attribute name="freeDiskSpaceWarning" type="long long">
7299 <desc>Issue a warning if the free disk space is below (or in some disk
7300 intensive operation is expected to go below) the given size in
7301 bytes.</desc>
7302 </attribute>
7303
7304 <attribute name="freeDiskSpacePercentWarning" type="unsigned long">
7305 <desc>Issue a warning if the free disk space is below (or in some disk
7306 intensive operation is expected to go below) the given percentage.</desc>
7307 </attribute>
7308
7309 <attribute name="freeDiskSpaceError" type="long long">
7310 <desc>Issue an error if the free disk space is below (or in some disk
7311 intensive operation is expected to go below) the given size in
7312 bytes.</desc>
7313 </attribute>
7314
7315 <attribute name="freeDiskSpacePercentError" type="unsigned long">
7316 <desc>Issue an error if the free disk space is below (or in some disk
7317 intensive operation is expected to go below) the given percentage.</desc>
7318 </attribute>
7319
7320 <attribute name="remoteDisplayAuthLibrary" type="wstring">
7321 <desc>
7322 Library that provides authentication for VRDP clients. The library
7323 is used if a virtual machine's authentication type is set to "external"
7324 in the VM RemoteDisplay configuration.
7325
7326 The system library extension (".DLL" or ".so") must be omitted.
7327 A full path can be specified; if not, then the library must reside on the
7328 system's default library path.
7329
7330 The default value of this property is <tt>"VRDPAuth"</tt>. There is a library
7331 of that name in one of the default VirtualBox library directories.
7332
7333 For details about VirtualBox authentication libraries and how to implement
7334 them, please refer to the VirtualBox manual.
7335
7336 <note>
7337 Setting this property to @c null or empty string will restore the
7338 initial value.
7339 </note>
7340 </desc>
7341 </attribute>
7342
7343 <attribute name="webServiceAuthLibrary" type="wstring">
7344 <desc>
7345 Library that provides authentication for webservice clients. The library
7346 is used if a virtual machine's authentication type is set to "external"
7347 in the VM RemoteDisplay configuration and will be called from
7348 within the <link to="IWebsessionManager::logon" /> implementation.
7349
7350 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
7351 there is no per-VM setting for this, as the webservice is a global
7352 resource (if it is running). Only for this setting (for the webservice),
7353 setting this value to a literal <tt>"null"</tt> string disables authentication,
7354 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
7355 no matter what user name and password are supplied.
7356
7357 The initial value of this property is <tt>"VRDPAuth"</tt>,
7358 meaning that the webservice will use the same authentication
7359 library that is used by default for VBoxVRDP (again, see
7360 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
7361 The format and calling convention of authentication libraries
7362 is the same for the webservice as it is for VBoxVRDP.
7363
7364 <note>
7365 Setting this property to @c null or empty string will restore the
7366 initial value.
7367 </note>
7368 </desc>
7369 </attribute>
7370
7371 <attribute name="LogHistoryCount" type="unsigned long">
7372 <desc>
7373 This value specifies how many old release log files are kept.
7374 </desc>
7375 </attribute>
7376
7377 <attribute name="defaultAudioDriver" type="AudioDriverType" readonly="yes">
7378 <desc>This value hold the default audio driver for the current
7379 system.</desc>
7380 </attribute>
7381
7382 <method name="getMaxDevicesPerPortForStorageBus">
7383 <desc>Returns the maximum number of devices which can be attached to a port
7384 for the given storage bus.</desc>
7385
7386 <param name="bus" type="StorageBus" dir="in">
7387 <desc>The storage bus type to get the value for.</desc>
7388 </param>
7389
7390 <param name="maxDevicesPerPort" type="unsigned long" dir="return">
7391 <desc>The maximum number of devices which can eb attached to the port for the given
7392 storage bus.</desc>
7393 </param>
7394 </method>
7395
7396 <method name="getMinPortCountForStorageBus">
7397 <desc>Returns the minimum number of ports the given storage bus supports.</desc>
7398
7399 <param name="bus" type="StorageBus" dir="in">
7400 <desc>The storage bus type to get the value for.</desc>
7401 </param>
7402
7403 <param name="minPortCount" type="unsigned long" dir="return">
7404 <desc>The minimum number of ports for the given storage bus.</desc>
7405 </param>
7406 </method>
7407
7408 <method name="getMaxPortCountForStorageBus">
7409 <desc>Returns the maximum number of ports the given storage bus supports.</desc>
7410
7411 <param name="bus" type="StorageBus" dir="in">
7412 <desc>The storage bus type to get the value for.</desc>
7413 </param>
7414
7415 <param name="maxPortCount" type="unsigned long" dir="return">
7416 <desc>The maximum number of ports for the given storage bus.</desc>
7417 </param>
7418 </method>
7419
7420 <method name="getMaxInstancesOfStorageBus">
7421 <desc>Returns the maximum number of storage bus instances which
7422 can be configured for each VM. This corresponds to the number of
7423 storage controllers one can have.</desc>
7424
7425 <param name="bus" type="StorageBus" dir="in">
7426 <desc>The storage bus type to get the value for.</desc>
7427 </param>
7428
7429 <param name="maxInstances" type="unsigned long" dir="return">
7430 <desc>The maximum number of instances for the given storage bus.</desc>
7431 </param>
7432 </method>
7433
7434 <method name="getDeviceTypesForStorageBus">
7435 <desc>Returns list of all the supported device types
7436 (<link to="DeviceType"/>) for the given type of storage
7437 bus.</desc>
7438
7439 <param name="bus" type="StorageBus" dir="in">
7440 <desc>The storage bus type to get the value for.</desc>
7441 </param>
7442
7443 <param name="deviceTypes" type="DeviceType" safearray="yes" dir="return">
7444 <desc>The list of all supported device types for the given storage bus.</desc>
7445 </param>
7446 </method>
7447
7448 <method name="getDefaultIoCacheSettingForStorageController">
7449 <desc>Returns the default I/O cache setting for the
7450 given storage controller</desc>
7451
7452 <param name="controllerType" type="StorageControllerType" dir="in">
7453 <desc>The storage controller to the setting for.</desc>
7454 </param>
7455
7456 <param name="enabled" type="boolean" dir="return">
7457 <desc>Returned flag indicating the default value</desc>
7458 </param>
7459 </method>
7460 </interface>
7461
7462 <!--
7463 // IGuest
7464 /////////////////////////////////////////////////////////////////////////
7465 -->
7466
7467 <interface
7468 name="IGuestOSType" extends="$unknown"
7469 uuid="432c1546-1354-4abf-bf08-878a32a373f5"
7470 wsmap="struct"
7471 >
7472 <desc>
7473 </desc>
7474
7475 <attribute name="familyId" type="wstring" readonly="yes">
7476 <desc>Guest OS family identifier string.</desc>
7477 </attribute>
7478
7479 <attribute name="familyDescription" type="wstring" readonly="yes">
7480 <desc>Human readable description of the guest OS family.</desc>
7481 </attribute>
7482
7483 <attribute name="id" type="wstring" readonly="yes">
7484 <desc>Guest OS identifier string.</desc>
7485 </attribute>
7486
7487 <attribute name="description" type="wstring" readonly="yes">
7488 <desc>Human readable description of the guest OS.</desc>
7489 </attribute>
7490
7491 <attribute name="is64Bit" type="boolean" readonly="yes">
7492 <desc>Returns @c true if the given OS is 64-bit</desc>
7493 </attribute>
7494
7495 <attribute name="recommendedIOAPIC" type="boolean" readonly="yes">
7496 <desc>Returns @c true if IO APIC recommended for this OS type.</desc>
7497 </attribute>
7498
7499 <attribute name="recommendedVirtEx" type="boolean" readonly="yes">
7500 <desc>Returns @c true if VT-x or AMD-V recommended for this OS type.</desc>
7501 </attribute>
7502
7503 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
7504 <desc>Recommended RAM size in Megabytes.</desc>
7505 </attribute>
7506
7507 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
7508 <desc>Recommended video RAM size in Megabytes.</desc>
7509 </attribute>
7510
7511 <attribute name="recommendedHDD" type="long long" readonly="yes">
7512 <desc>Recommended hard disk size in bytes.</desc>
7513 </attribute>
7514
7515 <attribute name="adapterType" type="NetworkAdapterType" readonly="yes">
7516 <desc>Returns recommended network adapter for this OS type.</desc>
7517 </attribute>
7518
7519 <attribute name="recommendedPae" type="boolean" readonly="yes">
7520 <desc>Returns @c true if using PAE is recommended for this OS type.</desc>
7521 </attribute>
7522
7523 <attribute name="recommendedDvdStorageController" type="StorageControllerType" readonly="yes">
7524 <desc>Recommended storage controller type for DVD/CD drives.</desc>
7525 </attribute>
7526
7527 <attribute name="recommendedDvdStorageBus" type="StorageBus" readonly="yes">
7528 <desc>Recommended storage bus type for DVD/CD drives.</desc>
7529 </attribute>
7530
7531 <attribute name="recommendedHdStorageController" type="StorageControllerType" readonly="yes">
7532 <desc>Recommended storage controller type for HD drives.</desc>
7533 </attribute>
7534
7535 <attribute name="recommendedHdStorageBus" type="StorageBus" readonly="yes">
7536 <desc>Recommended storage bus type for HD drives.</desc>
7537 </attribute>
7538
7539 <attribute name="recommendedFirmware" type="FirmwareType" readonly="yes">
7540 <desc>Recommended firmware type.</desc>
7541 </attribute>
7542
7543 <attribute name="recommendedUsbHid" type="boolean" readonly="yes">
7544 <desc>Returns @c true if using USB Human Interface Devices, such as keyboard and mouse recommended.</desc>
7545 </attribute>
7546
7547 <attribute name="recommendedHpet" type="boolean" readonly="yes">
7548 <desc>Returns @c true if using HPET is recommended for this OS type.</desc>
7549 </attribute>
7550
7551 <attribute name="recommendedUsbTablet" type="boolean" readonly="yes">
7552 <desc>Returns @c true if using a USB Tablet is recommended.</desc>
7553 </attribute>
7554
7555 <attribute name="recommendedRtcUseUtc" type="boolean" readonly="yes">
7556 <desc>Returns @c true if the RTC of this VM should be set to UTC</desc>
7557 </attribute>
7558
7559 <attribute name="recommendedChipset" type="ChipsetType" readonly="yes">
7560 <desc>Recommended chipset type.</desc>
7561 </attribute>
7562
7563 </interface>
7564
7565 <enum
7566 name="AdditionsRunLevelType"
7567 uuid="a25417ee-a9dd-4f5b-b0dc-377860087754"
7568 >
7569 <desc>
7570 Guest Additions run level type.
7571 </desc>
7572
7573 <const name="None" value="0">
7574 <desc>Guest Additions are not loaded.</desc>
7575 </const>
7576 <const name="System" value="1">
7577 <desc>Guest drivers are loaded.</desc>
7578 </const>
7579 <const name="Userland" value="2">
7580 <desc>Common components (such as application services) are loaded.</desc>
7581 </const>
7582 <const name="Desktop" value="3">
7583 <desc>Per-user desktop components are loaded.</desc>
7584 </const>
7585 </enum>
7586
7587 <enum
7588 name="ExecuteProcessFlag"
7589 uuid="9a24c17d-bd46-4207-b247-517fdd6d6b8f"
7590 >
7591 <desc>
7592 Guest process execution flags.
7593 </desc>
7594
7595 <const name="None" value="0">
7596 <desc>No flag set.</desc>
7597 </const>
7598
7599 <const name="IgnoreOrphanedProcesses" value="2">
7600 <desc>Do not report an error when executed processes are still alive when VBoxService or the guest OS is shutting down.</desc>
7601 </const>
7602 </enum>
7603
7604 <enum
7605 name="ProcessInputFlag"
7606 uuid="5d38c1dd-2604-4ddf-92e5-0c0cdd3bdbd5"
7607 >
7608 <desc>
7609 Guest process input flags.
7610 </desc>
7611
7612 <const name="None" value="0">
7613 <desc>No flag set.</desc>
7614 </const>
7615 <const name="EOF" value="1">
7616 <desc>End of file (input) reached.</desc>
7617 </const>
7618 </enum>
7619
7620 <enum
7621 name="CopyFileFlag"
7622 uuid="23f79fdf-738a-493d-b80b-42d607c9b916"
7623 >
7624 <desc>
7625 Host/Guest copy flags.
7626 </desc>
7627
7628 <const name="None" value="0">
7629 <desc>No flag set.</desc>
7630 </const>
7631
7632 <const name="Recursive" value="1">
7633 <desc>Copy directories recursively.</desc>
7634 </const>
7635
7636 <const name="Update" value="2">
7637 <desc>Copy only when the source file is newer than the destination file or when the destination file is missing.</desc>
7638 </const>
7639
7640 <const name="FollowLinks" value="4">
7641 <desc>Follow symbolic links.</desc>
7642 </const>
7643 </enum>
7644
7645 <interface
7646 name="IGuest" extends="$unknown"
7647 uuid="9a2d971f-62cb-4e84-b91a-c5adc2b7c6b8"
7648 wsmap="managed"
7649 >
7650 <desc>
7651 The IGuest interface represents information about the operating system
7652 running inside the virtual machine. Used in
7653 <link to="IConsole::guest"/>.
7654
7655 IGuest provides information about the guest operating system, whether
7656 Guest Additions are installed and other OS-specific virtual machine
7657 properties.
7658 </desc>
7659
7660 <attribute name="OSTypeId" type="wstring" readonly="yes">
7661 <desc>
7662 Identifier of the Guest OS type as reported by the Guest
7663 Additions.
7664 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
7665 an IGuestOSType object representing details about the given
7666 Guest OS type.
7667 <note>
7668 If Guest Additions are not installed, this value will be
7669 the same as <link to="IMachine::OSTypeId"/>.
7670 </note>
7671 </desc>
7672 </attribute>
7673
7674 <attribute name="additionsRunLevel" type="AdditionsRunLevelType" readonly="yes">
7675 <desc>
7676 Current run level of the Guest Additions.
7677 </desc>
7678 </attribute>
7679
7680 <attribute name="additionsVersion" type="wstring" readonly="yes">
7681 <desc>
7682 Version of the Guest Additions including the revision (3 decimal numbers
7683 separated by dots + revision number) installed on the guest or empty
7684 when the Additions are not installed.
7685 </desc>
7686 </attribute>
7687
7688 <attribute name="supportsSeamless" type="boolean" readonly="yes">
7689 <desc>
7690 Flag whether seamless guest display rendering (seamless desktop
7691 integration) is supported.
7692 </desc>
7693 </attribute>
7694
7695 <attribute name="supportsGraphics" type="boolean" readonly="yes">
7696 <desc>
7697 Flag whether the guest is in graphics mode. If it is not, then
7698 seamless rendering will not work, resize hints are not immediately
7699 acted on and guest display resizes are probably not initiated by
7700 the guest additions.
7701 </desc>
7702 </attribute>
7703
7704 <attribute name="memoryBalloonSize" type="unsigned long">
7705 <desc>Guest system memory balloon size in megabytes (transient property).</desc>
7706 </attribute>
7707
7708 <attribute name="statisticsUpdateInterval" type="unsigned long">
7709 <desc>Interval to update guest statistics in seconds.</desc>
7710 </attribute>
7711
7712 <method name="internalGetStatistics">
7713 <desc>
7714 Internal method; do not use as it might change at any time
7715 </desc>
7716 <param name="cpuUser" type="unsigned long" dir="out">
7717 <desc>Percentage of processor time spent in user mode as seen by the guest</desc>
7718 </param>
7719 <param name="cpuKernel" type="unsigned long" dir="out">
7720 <desc>Percentage of processor time spent in kernel mode as seen by the guest</desc>
7721 </param>
7722 <param name="cpuIdle" type="unsigned long" dir="out">
7723 <desc>Percentage of processor time spent idling as seen by the guest</desc>
7724 </param>
7725 <param name="memTotal" type="unsigned long" dir="out">
7726 <desc>Total amount of physical guest RAM</desc>
7727 </param>
7728 <param name="memFree" type="unsigned long" dir="out">
7729 <desc>Free amount of physical guest RAM</desc>
7730 </param>
7731 <param name="memBalloon" type="unsigned long" dir="out">
7732 <desc>Amount of ballooned physical guest RAM</desc>
7733 </param>
7734 <param name="memShared" type="unsigned long" dir="out">
7735 <desc>Amount of shared physical guest RAM</desc>
7736 </param>
7737 <param name="memCache" type="unsigned long" dir="out">
7738 <desc>Total amount of guest (disk) cache memory</desc>
7739 </param>
7740 <param name="pagedTotal" type="unsigned long" dir="out">
7741 <desc>Total amount of space in the page file</desc>
7742 </param>
7743 <param name="memAllocTotal" type="unsigned long" dir="out">
7744 <desc>Total amount of memory allocated by the hypervisor</desc>
7745 </param>
7746 <param name="memFreeTotal" type="unsigned long" dir="out">
7747 <desc>Total amount of free memory available in the hypervisor</desc>
7748 </param>
7749 <param name="memBalloonTotal" type="unsigned long" dir="out">
7750 <desc>Total amount of memory ballooned by the hypervisor</desc>
7751 </param>
7752 <param name="memSharedTotal" type="unsigned long" dir="out">
7753 <desc>Total amount of shared memory in the hypervisor</desc>
7754 </param>
7755 </method>
7756
7757 <method name="getAdditionsStatus">
7758 <desc>
7759 Retrieve the current status of a certain Guest Additions run level.
7760
7761 <result name="VBOX_E_NOT_SUPPORTED">
7762 Wrong status level specified.
7763 </result>
7764
7765 </desc>
7766 <param name="level" type="AdditionsRunLevelType" dir="in">
7767 <desc>Status level to check</desc>
7768 </param>
7769 <param name="active" type="boolean" dir="return">
7770 <desc>Flag whether the status level has been reached or not</desc>
7771 </param>
7772 </method>
7773
7774 <method name="setCredentials">
7775 <desc>
7776 Store login credentials that can be queried by guest operating
7777 systems with Additions installed. The credentials are transient
7778 to the session and the guest may also choose to erase them. Note
7779 that the caller cannot determine whether the guest operating system
7780 has queried or made use of the credentials.
7781
7782 <result name="VBOX_E_VM_ERROR">
7783 VMM device is not available.
7784 </result>
7785
7786 </desc>
7787 <param name="userName" type="wstring" dir="in">
7788 <desc>User name string, can be empty</desc>
7789 </param>
7790 <param name="password" type="wstring" dir="in">
7791 <desc>Password string, can be empty</desc>
7792 </param>
7793 <param name="domain" type="wstring" dir="in">
7794 <desc>Domain name (guest logon scheme specific), can be empty</desc>
7795 </param>
7796 <param name="allowInteractiveLogon" type="boolean" dir="in">
7797 <desc>
7798 Flag whether the guest should alternatively allow the user to
7799 interactively specify different credentials. This flag might
7800 not be supported by all versions of the Additions.
7801 </desc>
7802 </param>
7803 </method>
7804
7805 <method name="executeProcess">
7806 <desc>
7807 Executes an existing program inside the guest VM.
7808
7809 <result name="VBOX_E_IPRT_ERROR">
7810 Could not execute process.
7811 </result>
7812
7813 </desc>
7814 <param name="execName" type="wstring" dir="in">
7815 <desc>
7816 Full path name of the command to execute on the guest; the
7817 commands has to exists in the guest VM in order to be executed.
7818 </desc>
7819 </param>
7820 <param name="flags" type="unsigned long" dir="in">
7821 <desc>
7822 Execution flags - currently not supported and therefore
7823 has to be set to 0.
7824 </desc>
7825 </param>
7826 <param name="arguments" type="wstring" safearray="yes" dir="in">
7827 <desc>
7828 Array of arguments passed to the execution command.
7829 </desc>
7830 </param>
7831 <param name="environment" type="wstring" safearray="yes" dir="in">
7832 <desc>
7833 Environment variables that can be set while the command is being
7834 executed, in form of "NAME=VALUE"; one pair per entry. To unset a
7835 variable just set its name ("NAME") without a value.
7836 </desc>
7837 </param>
7838 <param name="userName" type="wstring" dir="in">
7839 <desc>
7840 User name under which the command will be executed; has to exist
7841 and have the appropriate rights to execute programs in the VM.
7842 </desc>
7843 </param>
7844 <param name="password" type="wstring" dir="in">
7845 <desc>
7846 Password of the user account specified.
7847 </desc>
7848 </param>
7849 <param name="timeoutMS" type="unsigned long" dir="in">
7850 <desc>
7851 The maximum timeout value (in msec) to wait for finished program
7852 execution. Pass 0 for an infinite timeout.
7853 </desc>
7854 </param>
7855 <param name="pid" type="unsigned long" dir="out">
7856 <desc>
7857 The PID (process ID) of the started command for later reference.
7858 </desc>
7859 </param>
7860 <param name="progress" type="IProgress" dir="return">
7861 <desc>Progress object to track the operation completion.</desc>
7862 </param>
7863 </method>
7864
7865 <method name="getProcessOutput">
7866 <desc>
7867 Retrieves output of a formerly started process.
7868
7869 <result name="VBOX_E_IPRT_ERROR">
7870 Could not retrieve output.
7871 </result>
7872
7873 </desc>
7874 <param name="pid" type="unsigned long" dir="in">
7875 <desc>
7876 Process id returned by earlier executeProcess() call.
7877 </desc>
7878 </param>
7879 <param name="flags" type="unsigned long" dir="in">
7880 <desc>
7881 Flags describing which output to retrieve.
7882 </desc>
7883 </param>
7884 <param name="timeoutMS" type="unsigned long" dir="in">
7885 <desc>
7886 The maximum timeout value (in msec) to wait for output
7887 data. Pass 0 for an infinite timeout.
7888 </desc>
7889 </param>
7890 <param name="size" type="long long" dir="in">
7891 <desc>
7892 Size in bytes to read in the buffer.
7893 </desc>
7894 </param>
7895 <param name="data" type="octet" dir="return" safearray="yes">
7896 <desc>
7897 Buffer for retrieving the actual output. A data size of 0 means end of file
7898 if the requested size was not 0. This is the unprocessed
7899 output data, i.e. the line ending style depends on the platform of
7900 the system the server is running on.
7901 </desc>
7902 </param>
7903 </method>
7904
7905 <method name="getProcessStatus">
7906 <desc>
7907 Retrieves status, exit code and the exit reason of a formerly started process.
7908
7909 <result name="VBOX_E_IPRT_ERROR">
7910 Process with specified PID was not found.
7911 </result>
7912
7913 </desc>
7914 <param name="pid" type="unsigned long" dir="in">
7915 <desc>
7916 Process id returned by earlier executeProcess() call.
7917 </desc>
7918 </param>
7919 <param name="exitcode" type="unsigned long" dir="out">
7920 <desc>
7921 The exit code (if available).
7922 </desc>
7923 </param>
7924 <param name="flags" type="unsigned long" dir="out">
7925 <desc>
7926 Additional flags of process status (not used at the moment).
7927 </desc>
7928 </param>
7929 <param name="reason" type="unsigned long" dir="return">
7930 <desc>
7931 The current process status.
7932 </desc>
7933 </param>
7934 </method>
7935
7936 <method name="copyToGuest">
7937 <desc>
7938 Copies files/directories from host to the guest.
7939
7940 <result name="VBOX_E_IPRT_ERROR">
7941 Error while copying.
7942 </result>
7943
7944 </desc>
7945 <param name="source" type="wstring" dir="in">
7946 <desc>
7947 Foo.
7948 </desc>
7949 </param>
7950 <param name="dest" type="wstring" dir="in">
7951 <desc>
7952 Bar.
7953 </desc>
7954 </param>
7955 <param name="flags" type="unsigned long" dir="in">
7956 <desc>
7957 Copy flags.
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="setProcessInput">
7966 <desc>
7967 Sends input into a formerly started process.
7968
7969 <result name="VBOX_E_IPRT_ERROR">
7970 Could not send input.
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 Not used, must be set to zero.
7982 </desc>
7983 </param>
7984 <param name="data" type="octet" dir="in" safearray="yes">
7985 <desc>
7986 Buffer of input data to send to the started process to.
7987 </desc>
7988 </param>
7989 <param name="written" type="unsigned long" dir="return">
7990 <desc>
7991 Number of bytes written.
7992 </desc>
7993 </param>
7994 </method>
7995
7996 </interface>
7997
7998
7999 <!--
8000 // IProgress
8001 /////////////////////////////////////////////////////////////////////////
8002 -->
8003
8004 <interface
8005 name="IProgress" extends="$unknown"
8006 uuid="A163C98F-8635-4AA8-B770-A9941737F3EF"
8007 wsmap="managed"
8008 >
8009 <desc>
8010 The IProgress interface is used to track and control
8011 asynchronous tasks within VirtualBox.
8012
8013 An instance of this is returned every time VirtualBox starts
8014 an asynchronous task (in other words, a separate thread) which
8015 continues to run after a method call returns. For example,
8016 <link to="IConsole::saveState" />, which saves the state of
8017 a running virtual machine, can take a long time to complete.
8018 To be able to display a progress bar, a user interface such as
8019 the VirtualBox graphical user interface can use the IProgress
8020 object returned by that method.
8021
8022 Note that IProgress is a "read-only" interface in the sense
8023 that only the VirtualBox internals behind the Main API can
8024 create and manipulate progress objects, whereas client code
8025 can only use the IProgress object to monitor a task's
8026 progress and, if <link to="#cancelable" /> is @c true,
8027 cancel the task by calling <link to="#cancel" />.
8028
8029 A task represented by IProgress consists of either one or
8030 several sub-operations that run sequentially, one by one (see
8031 <link to="#operation" /> and <link to="#operationCount" />).
8032 Every operation is identified by a number (starting from 0)
8033 and has a separate description.
8034
8035 You can find the individual percentage of completion of the current
8036 operation in <link to="#operationPercent" /> and the
8037 percentage of completion of the task as a whole
8038 in <link to="#percent" />.
8039
8040 Similarly, you can wait for the completion of a particular
8041 operation via <link to="#waitForOperationCompletion" /> or
8042 for the completion of the whole task via
8043 <link to="#waitForCompletion" />.
8044 </desc>
8045
8046 <attribute name="id" type="uuid" mod="string" readonly="yes">
8047 <desc>ID of the task.</desc>
8048 </attribute>
8049
8050 <attribute name="description" type="wstring" readonly="yes">
8051 <desc>Description of the task.</desc>
8052 </attribute>
8053
8054 <attribute name="initiator" type="$unknown" readonly="yes">
8055 <desc>Initiator of the task.</desc>
8056 </attribute>
8057
8058 <attribute name="cancelable" type="boolean" readonly="yes">
8059 <desc>Whether the task can be interrupted.</desc>
8060 </attribute>
8061
8062 <attribute name="percent" type="unsigned long" readonly="yes">
8063 <desc>
8064 Current progress value of the task as a whole, in percent.
8065 This value depends on how many operations are already complete.
8066 Returns 100 if <link to="#completed" /> is @c true.
8067 </desc>
8068 </attribute>
8069
8070 <attribute name="timeRemaining" type="long" readonly="yes">
8071 <desc>
8072 Estimated remaining time until the task completes, in
8073 seconds. Returns 0 once the task has completed; returns -1
8074 if the remaining time cannot be computed, in particular if
8075 the current progress is 0.
8076
8077 Even if a value is returned, the estimate will be unreliable
8078 for low progress values. It will become more reliable as the
8079 task progresses; it is not recommended to display an ETA
8080 before at least 20% of a task have completed.
8081 </desc>
8082 </attribute>
8083
8084 <attribute name="completed" type="boolean" readonly="yes">
8085 <desc>Whether the task has been completed.</desc>
8086 </attribute>
8087
8088 <attribute name="canceled" type="boolean" readonly="yes">
8089 <desc>Whether the task has been canceled.</desc>
8090 </attribute>
8091
8092 <attribute name="resultCode" type="long" readonly="yes">
8093 <desc>
8094 Result code of the progress task.
8095 Valid only if <link to="#completed"/> is @c true.
8096 </desc>
8097 </attribute>
8098
8099 <attribute name="errorInfo" type="IVirtualBoxErrorInfo" readonly="yes">
8100 <desc>
8101 Extended information about the unsuccessful result of the
8102 progress operation. May be @c null if no extended information
8103 is available.
8104 Valid only if <link to="#completed"/> is @c true and
8105 <link to="#resultCode"/> indicates a failure.
8106 </desc>
8107 </attribute>
8108
8109 <attribute name="operationCount" type="unsigned long" readonly="yes">
8110 <desc>
8111 Number of sub-operations this task is divided into.
8112 Every task consists of at least one suboperation.
8113 </desc>
8114 </attribute>
8115
8116 <attribute name="operation" type="unsigned long" readonly="yes">
8117 <desc>Number of the sub-operation being currently executed.</desc>
8118 </attribute>
8119
8120 <attribute name="operationDescription" type="wstring" readonly="yes">
8121 <desc>
8122 Description of the sub-operation being currently executed.
8123 </desc>
8124 </attribute>
8125
8126 <attribute name="operationPercent" type="unsigned long" readonly="yes">
8127 <desc>Progress value of the current sub-operation only, in percent.</desc>
8128 </attribute>
8129
8130 <attribute name="operationWeight" type="unsigned long" readonly="yes">
8131 <desc>Weight value of the current sub-operation only.</desc>
8132 </attribute>
8133
8134 <attribute name="timeout" type="unsigned long">
8135 <desc>
8136 When non-zero, this specifies the number of milliseconds after which
8137 the operation will automatically be canceled. This can only be set on
8138 cancelable objects.
8139 </desc>
8140 </attribute>
8141
8142 <method name="setCurrentOperationProgress">
8143 <desc>Internal method, not to be called externally.</desc>
8144 <param name="percent" type="unsigned long" dir="in" />
8145 </method>
8146 <method name="setNextOperation">
8147 <desc>Internal method, not to be called externally.</desc>
8148 <param name="nextOperationDescription" type="wstring" dir="in" />
8149 <param name="nextOperationsWeight" type="unsigned long" dir="in" />
8150 </method>
8151
8152 <method name="waitForCompletion">
8153 <desc>
8154 Waits until the task is done (including all sub-operations)
8155 with a given timeout in milliseconds; specify -1 for an indefinite wait.
8156
8157 Note that the VirtualBox/XPCOM/COM/native event queues of the calling
8158 thread are not processed while waiting. Neglecting event queues may
8159 have dire consequences (degrade performance, resource hogs,
8160 deadlocks, etc.), this is specially so for the main thread on
8161 platforms using XPCOM. Callers are adviced wait for short periods
8162 and service their event queues between calls, or to create a worker
8163 thread to do the waiting.
8164
8165 <result name="VBOX_E_IPRT_ERROR">
8166 Failed to wait for task completion.
8167 </result>
8168 </desc>
8169
8170 <param name="timeout" type="long" dir="in">
8171 <desc>
8172 Maximum time in milliseconds to wait or -1 to wait indefinitely.
8173 </desc>
8174 </param>
8175 </method>
8176
8177 <method name="waitForOperationCompletion">
8178 <desc>
8179 Waits until the given operation is done with a given timeout in
8180 milliseconds; specify -1 for an indefinite wait.
8181
8182 See <link to="#waitForCompletion"> for event queue considerations.</link>
8183
8184 <result name="VBOX_E_IPRT_ERROR">
8185 Failed to wait for operation completion.
8186 </result>
8187
8188 </desc>
8189 <param name="operation" type="unsigned long" dir="in">
8190 <desc>
8191 Number of the operation to wait for.
8192 Must be less than <link to="#operationCount"/>.
8193 </desc>
8194 </param>
8195 <param name="timeout" type="long" dir="in">
8196 <desc>
8197 Maximum time in milliseconds to wait or -1 to wait indefinitely.
8198 </desc>
8199 </param>
8200 </method>
8201
8202 <method name="cancel">
8203 <desc>
8204 Cancels the task.
8205 <note>
8206 If <link to="#cancelable"/> is @c false, then this method will fail.
8207 </note>
8208
8209 <result name="VBOX_E_INVALID_OBJECT_STATE">
8210 Operation cannot be canceled.
8211 </result>
8212
8213 </desc>
8214 </method>
8215
8216 </interface>
8217
8218 <!--
8219 // ISnapshot
8220 /////////////////////////////////////////////////////////////////////////
8221 -->
8222
8223 <interface
8224 name="ISnapshot" extends="$unknown"
8225 uuid="1a2d0551-58a4-4107-857e-ef414fc42ffc"
8226 wsmap="managed"
8227 >
8228 <desc>
8229 The ISnapshot interface represents a snapshot of the virtual
8230 machine.
8231
8232 Together with the differencing media that are created
8233 when a snapshot is taken, a machine can be brought back to
8234 the exact state it was in when the snapshot was taken.
8235
8236 The ISnapshot interface has no methods, only attributes; snapshots
8237 are controlled through methods of the <link to="IConsole" /> interface
8238 which also manage the media associated with the snapshot.
8239 The following operations exist:
8240
8241 <ul>
8242 <li><link to="IConsole::takeSnapshot"/> creates a new snapshot
8243 by creating new, empty differencing images for the machine's
8244 media and saving the VM settings and (if the VM is running)
8245 the current VM state in the snapshot.
8246
8247 The differencing images will then receive all data written to
8248 the machine's media, while their parent (base) images
8249 remain unmodified after the snapshot has been taken (see
8250 <link to="IMedium" /> for details about differencing images).
8251 This simplifies restoring a machine to the state of a snapshot:
8252 only the differencing images need to be deleted.
8253
8254 The current machine state is not changed by taking a snapshot.
8255 If the machine is running, it will resume execution after the
8256 snapshot has been taken. After calling this,
8257 <link to="IMachine::currentSnapshot" /> is set to the snapshot
8258 just created.
8259 </li>
8260
8261 <li><link to="IConsole::restoreSnapshot"/> resets a machine to
8262 the state of a previous snapshot by deleting the differencing
8263 image of each of the machine's media and setting the machine's
8264 settings and state to the state that was saved in the snapshot (if any).
8265
8266 This destroys the machine's current state. After calling this,
8267 <link to="IMachine::currentSnapshot" /> is set to the snapshot that was
8268 restored.
8269 </li>
8270
8271 <li><link to="IConsole::deleteSnapshot"/> deletes a snapshot
8272 without affecting the current machine state.
8273
8274 This does not change the current machine state, but instead frees the
8275 resources allocated when the snapshot was taken: the settings and machine
8276 state file are deleted (if any), and the snapshot's differencing image for
8277 each of the machine's media gets merged with its parent image.
8278
8279 Neither the current machine state nor other snapshots are affected
8280 by this operation, except that parent media will be modified
8281 to contain the disk data associated with the snapshot being deleted.
8282
8283 When deleting the current snapshot, the <link to="IMachine::currentSnapshot" />
8284 attribute is set to the current snapshot's parent or NULL if it
8285 has no parent. Otherwise the attribute is unchanged.
8286 </li>
8287 </ul>
8288
8289 Each snapshot contains the settings of the virtual machine (hardware
8290 configuration etc.). In addition, if the machine was running when the
8291 snapshot was taken (<link to="IMachine::state"/> is <link to="MachineState_Running"/>),
8292 the current VM state is saved in the snapshot (similarly to what happens
8293 when a VM's state is saved). The snapshot is then said to
8294 be <i>online</i> because when restoring it, the VM will be running.
8295
8296 If the machine is saved (<link to="MachineState_Saved"/>), the snapshot
8297 receives a copy of the execution state file (<link to="IMachine::stateFilePath"/>).
8298
8299 Otherwise, if the machine was not running (<link to="MachineState_PoweredOff"/>
8300 or <link to="MachineState_Aborted"/>), the snapshot is <i>offline</i>;
8301 it then contains a so-called "zero execution state", representing a
8302 machine that is powered off.
8303 </desc>
8304
8305 <attribute name="id" type="uuid" mod="string" readonly="yes">
8306 <desc>UUID of the snapshot.</desc>
8307 </attribute>
8308
8309 <attribute name="name" type="wstring">
8310 <desc>Short name of the snapshot.</desc>
8311 </attribute>
8312
8313 <attribute name="description" type="wstring">
8314 <desc>Optional description of the snapshot.</desc>
8315 </attribute>
8316
8317 <attribute name="timeStamp" type="long long" readonly="yes">
8318 <desc>
8319 Time stamp of the snapshot, in milliseconds since 1970-01-01 UTC.
8320 </desc>
8321 </attribute>
8322
8323 <attribute name="online" type="boolean" readonly="yes">
8324 <desc>
8325 @c true if this snapshot is an online snapshot and @c false otherwise.
8326
8327 When this attribute is @c true, the
8328 <link to="IMachine::stateFilePath"/> attribute of the
8329 <link to="#machine"/> object associated with this snapshot
8330 will point to the saved state file. Otherwise, it will be
8331 an empty string.
8332 </desc>
8333 </attribute>
8334
8335 <attribute name="machine" type="IMachine" readonly="yes">
8336 <desc>
8337 Virtual machine this snapshot is taken on. This object
8338 stores all settings the machine had when taking this snapshot.
8339 <note>
8340 The returned machine object is immutable, i.e. no
8341 any settings can be changed.
8342 </note>
8343 </desc>
8344 </attribute>
8345
8346 <attribute name="parent" type="ISnapshot" readonly="yes">
8347 <desc>
8348 Parent snapshot (a snapshot this one is based on), or
8349 @c null if the snapshot has no parent (i.e. is the first snapshot).
8350 </desc>
8351 </attribute>
8352
8353 <attribute name="children" type="ISnapshot" readonly="yes" safearray="yes">
8354 <desc>
8355 Child snapshots (all snapshots having this one as a parent).
8356 </desc>
8357 </attribute>
8358
8359 </interface>
8360
8361
8362 <!--
8363 // IMedium
8364 /////////////////////////////////////////////////////////////////////////
8365 -->
8366
8367 <enum
8368 name="MediumState"
8369 uuid="ef41e980-e012-43cd-9dea-479d4ef14d13"
8370 >
8371 <desc>
8372 Virtual medium state.
8373 <see>IMedium</see>
8374 </desc>
8375
8376 <const name="NotCreated" value="0">
8377 <desc>
8378 Associated medium storage does not exist (either was not created yet or
8379 was deleted).
8380 </desc>
8381 </const>
8382 <const name="Created" value="1">
8383 <desc>
8384 Associated storage exists and accessible; this gets set if the
8385 accessibility check performed by <link to="IMedium::refreshState" />
8386 was successful.
8387 </desc>
8388 </const>
8389 <const name="LockedRead" value="2">
8390 <desc>
8391 Medium is locked for reading (see <link to="IMedium::lockRead"/>),
8392 no data modification is possible.
8393 </desc>
8394 </const>
8395 <const name="LockedWrite" value="3">
8396 <desc>
8397 Medium is locked for writing (see <link to="IMedium::lockWrite"/>),
8398 no concurrent data reading or modification is possible.
8399 </desc>
8400 </const>
8401 <const name="Inaccessible" value="4">
8402 <desc>
8403 Medium accessiblity check (see <link to="IMedium::refreshState" />) has
8404 not yet been performed, or else, associated medium storage is not
8405 accessible. In the first case, <link to="IMedium::lastAccessError"/>
8406 is empty, in the second case, it describes the error that occured.
8407 </desc>
8408 </const>
8409 <const name="Creating" value="5">
8410 <desc>
8411 Associated medium storage is being created.
8412 </desc>
8413 </const>
8414 <const name="Deleting" value="6">
8415 <desc>
8416 Associated medium storage is being deleted.
8417 </desc>
8418 </const>
8419 </enum>
8420
8421 <enum
8422 name="MediumType"
8423 uuid="46bf1fd4-ad86-4ded-8c49-28bd2d148e5a"
8424 >
8425 <desc>
8426 Virtual medium type.
8427 <see>IMedium</see>
8428 </desc>
8429
8430 <const name="Normal" value="0">
8431 <desc>
8432 Normal medium (attached directly or indirectly, preserved
8433 when taking snapshots).
8434 </desc>
8435 </const>
8436 <const name="Immutable" value="1">
8437 <desc>
8438 Immutable medium (attached indirectly, changes are wiped out
8439 the next time the virtual machine is started).
8440 </desc>
8441 </const>
8442 <const name="Writethrough" value="2">
8443 <desc>
8444 Write through medium (attached directly, ignored when
8445 taking snapshots).
8446 </desc>
8447 </const>
8448 <const name="Shareable" value="3">
8449 <desc>
8450 Allow using this medium concurrently by several machines.
8451 <note>Present since VirtualBox 3.2.0, and accepted since 3.2.8.</note>
8452 </desc>
8453 </const>
8454 </enum>
8455
8456 <enum
8457 name="MediumVariant"
8458 uuid="584ea502-143b-4ab0-ad14-d1028fdf0316"
8459 >
8460 <desc>
8461 Virtual medium image variant. More than one flag may be set.
8462 <see>IMedium</see>
8463 </desc>
8464
8465 <const name="Standard" value="0">
8466 <desc>
8467 No particular variant requested, results in using the backend default.
8468 </desc>
8469 </const>
8470 <const name="VmdkSplit2G" value="0x01">
8471 <desc>
8472 VMDK image split in chunks of less than 2GByte.
8473 </desc>
8474 </const>
8475 <const name="VmdkStreamOptimized" value="0x04">
8476 <desc>
8477 VMDK streamOptimized image. Special import/export format which is
8478 read-only/append-only.
8479 </desc>
8480 </const>
8481 <const name="VmdkESX" value="0x08">
8482 <desc>
8483 VMDK format variant used on ESX products.
8484 </desc>
8485 </const>
8486 <const name="Fixed" value="0x10000">
8487 <desc>
8488 Fixed image. Only allowed for base images.
8489 </desc>
8490 </const>
8491 <const name="Diff" value="0x20000">
8492 <desc>
8493 Differencing image. Only allowed for child images.
8494 </desc>
8495 </const>
8496 </enum>
8497
8498 <interface
8499 name="IMediumAttachment" extends="$unknown"
8500 uuid="c29452cc-ca72-404b-9261-cfc514f1e412"
8501 wsmap="struct"
8502 >
8503 <desc>
8504 The IMediumAttachment interface links storage media to virtual machines.
8505 For each medium (<link to="IMedium"/>) which has been attached to a
8506 storage controller (<link to="IStorageController"/>) of a machine
8507 (<link to="IMachine"/>) via the <link to="IMachine::attachDevice" />
8508 method, one instance of IMediumAttachment is added to the machine's
8509 <link to="IMachine::mediumAttachments"/> array attribute.
8510
8511 Each medium attachment specifies the storage controller as well as a
8512 port and device number and the IMedium instance representing a virtual
8513 hard disk or floppy or DVD image.
8514
8515 For removeable media (DVDs or floppies), there are two additional
8516 options. For one, the IMedium instance can be @c null to represent
8517 an empty drive with no media inserted (see <link to="IMachine::mountMedium" />);
8518 secondly, the medium can be one of the pseudo-media for host drives
8519 listed in <link to="IHost::DVDDrives"/> or <link to="IHost::floppyDrives"/>.
8520 </desc>
8521
8522 <attribute name="medium" type="IMedium" readonly="yes">
8523 <desc>Medium object associated with this attachment; it
8524 can be @c null for removable devices.</desc>
8525 </attribute>
8526
8527 <attribute name="controller" type="wstring" readonly="yes">
8528 <desc>Name of the storage controller of this attachment; this
8529 refers to one of the controllers in <link to="IMachine::storageControllers" />
8530 by name.</desc>
8531 </attribute>
8532
8533 <attribute name="port" type="long" readonly="yes">
8534 <desc>Port number of this attachment.
8535 See <link to="IMachine::attachDevice" /> for the meaning of this value for the different controller types.
8536 </desc>
8537 </attribute>
8538
8539 <attribute name="device" type="long" readonly="yes">
8540 <desc>Device slot number of this attachment.
8541 See <link to="IMachine::attachDevice" /> for the meaning of this value for the different controller types.
8542 </desc>
8543 </attribute>
8544
8545 <attribute name="type" type="DeviceType" readonly="yes">
8546 <desc>Device type of this attachment.</desc>
8547 </attribute>
8548
8549 <attribute name="passthrough" type="boolean" readonly="yes">
8550 <desc>Pass I/O requests through to a device on the host.</desc>
8551 </attribute>
8552
8553 <attribute name="bandwidthLimit" type="unsigned long">
8554 <desc>
8555 Maximum throughput allowed for this medium attachment, in units of 1 mbps.
8556 A zero value means uncapped/unlimited.
8557 </desc>
8558 </attribute>
8559
8560 </interface>
8561
8562 <interface
8563 name="IMedium" extends="$unknown"
8564 uuid="bfcf5b8c-5155-4f24-9414-9457054b16db"
8565 wsmap="managed"
8566 >
8567 <desc>
8568 The IMedium interface represents virtual storage for a machine's
8569 hard disks, CD/DVD or floppy drives. It will typically represent
8570 a disk image on the host, for example a VDI or VMDK file representing
8571 a virtual hard disk, or an ISO or RAW file representing virtual
8572 removable media, but can also point to a network location (e.g.
8573 for iSCSI targets).
8574
8575 Instances of IMedium are connected to virtual machines by way of
8576 medium attachments (see <link to="IMediumAttachment" />), which link
8577 the storage medium to a particular device slot of a storage controller
8578 of the virtual machine.
8579 In the VirtualBox API, virtual storage is therefore always represented
8580 by the following chain of object links:
8581
8582 <ul>
8583 <li><link to="IMachine::storageControllers"/> contains an array of
8584 storage controllers (IDE, SATA, SCSI, SAS or a floppy controller;
8585 these are instances of <link to="IStorageController"/>).</li>
8586 <li><link to="IMachine::mediumAttachments"/> contains an array of
8587 medium attachments (instances of <link to="IMediumAttachment"/>),
8588 each containing a storage controller from the above array, a
8589 port/device specification, and an instance of IMedium representing
8590 the medium storage (image file).
8591
8592 For removable media, the storage medium is optional; a medium
8593 attachment with no medium represents a CD/DVD or floppy drive
8594 with no medium inserted. By contrast, hard disk attachments
8595 will always have an IMedium object attached.</li>
8596 <li>Each IMedium in turn points to a storage unit (such as a file
8597 on the host computer or a network resource) that holds actual
8598 data. This location is represented by the <link to="#location"/>
8599 attribute.</li>
8600 </ul>
8601
8602 Existing media are opened using <link to="IVirtualBox::openMedium"/>;
8603 new hard disk media can be created with the VirtualBox API using the
8604 <link to="IVirtualBox::createHardDisk"/> method.
8605
8606 CD/DVD and floppy images (ISO and RAW files) are usually created outside
8607 VirtualBox, e.g. by storing a copy of the real medium of the corresponding
8608 type in a regular file.
8609
8610 Only for CD/DVDs and floppies, an IMedium instance can also represent a host
8611 drive; in that case the <link to="#id" /> attribute contains the UUID of
8612 one of the drives in <link to="IHost::DVDDrives" /> or <link to="IHost::floppyDrives" />.
8613
8614 <h3>Known media</h3>
8615
8616 When an existing medium is opened for the first time, it is automatically
8617 remembered by the given VirtualBox installation or, in other words, becomes
8618 a <i>known medium</i>. Known media are stored in the media
8619 registry transparently maintained by VirtualBox and stored in settings
8620 files so that this registry is preserved when VirtualBox is not running.
8621
8622 Newly created virtual media are remembered only when the associated
8623 storage unit is actually created.
8624
8625 All known media can be enumerated using
8626 <link to="IVirtualBox::hardDisks"/>,
8627 <link to="IVirtualBox::DVDImages"/> and
8628 <link to="IVirtualBox::floppyImages"/> attributes. Individual media can be
8629 quickly found using the <link to="IVirtualBox::findMedium"/> method.
8630
8631 Only known media can be attached to virtual machines.
8632
8633 Removing known media from the media registry is performed when the given
8634 medium is closed using the <link to="#close"/> method or when its
8635 associated storage unit is deleted.
8636
8637 <h3>Accessibility checks</h3>
8638
8639 VirtualBox defers media accessibility checks until the <link to="#refreshState" />
8640 method is called explicitly on a medium. This is done to make the VirtualBox object
8641 ready for serving requests as fast as possible and let the end-user
8642 application decide if it needs to check media accessibility right away or not.
8643
8644 As a result, when VirtualBox starts up (e.g. the VirtualBox
8645 object gets created for the first time), all known media are in the
8646 "Inaccessible" state, but the value of the <link to="#lastAccessError"/>
8647 attribute is an empty string because no actual accessibility check has
8648 been made yet.
8649
8650 After calling <link to="#refreshState" />, a medium is considered
8651 <i>accessible</i> if its storage unit can be read. In that case, the
8652 <link to="#state"/> attribute has a value of "Created". If the storage
8653 unit cannot be read (for example, because it is located on a disconnected
8654 network resource, or was accidentally deleted outside VirtualBox),
8655 the medium is considered <i>inaccessible</i>, which is indicated by the
8656 "Inaccessible" state. The exact reason why the medium is inaccessible can be
8657 obtained by reading the <link to="#lastAccessError"/> attribute.
8658
8659 <h3>Medium types</h3>
8660
8661 There are four types of medium behavior (see <link to="MediumType" />):
8662 "normal", "immutable", "writethrough" and "shareable", represented by the
8663 <link to="#type"/> attribute. The type of the medium defines how the
8664 medium is attached to a virtual machine and what happens when a
8665 <link to="ISnapshot">snapshot</link> of the virtual machine with the
8666 attached medium is taken. At the moment DVD and floppy media are always
8667 of type "writethrough".
8668
8669 All media can be also divided in two groups: <i>base</i> media and
8670 <i>differencing</i> media. A base medium contains all sectors of the
8671 medium data in its own storage and therefore can be used independently.
8672 In contrast, a differencing mediun is a "delta" to some other medium and
8673 contains only those sectors which differ from that other medium, which is
8674 then called a <i>parent</i>. The differencing medium is said to be
8675 <i>linked to</i> that parent. The parent may be itself a differencing
8676 medium, thus forming a chain of linked media. The last element in that
8677 chain must always be a base medium. Note that several differencing
8678 media may be linked to the same parent medium.
8679
8680 Differencing media can be distinguished from base media by querying the
8681 <link to="#parent"/> attribute: base media do not have parents they would
8682 depend on, so the value of this attribute is always @c null for them.
8683 Using this attribute, it is possible to walk up the medium tree (from the
8684 child medium to its parent). It is also possible to walk down the tree
8685 using the <link to="#children"/> attribute.
8686
8687 Note that the type of all differencing media is "normal"; all other
8688 values are meaningless for them. Base media may be of any type.
8689
8690 <h3>Creating hard disks</h3>
8691
8692 New base hard disks are created using
8693 <link to="IVirtualBox::createHardDisk"/>. Existing hard disks are
8694 opened using <link to="IVirtualBox::openMedium"/>. Differencing hard
8695 disks are usually implicitly created by VirtualBox when needed but may
8696 also be created explicitly using <link to="#createDiffStorage"/>.
8697
8698 After the hard disk is successfully created (including the storage unit)
8699 or opened, it becomes a known hard disk (remembered in the internal media
8700 registry). Known hard disks can be attached to a virtual machine, accessed
8701 through <link to="IVirtualBox::findMedium"/> or enumerated using the
8702 <link to="IVirtualBox::hardDisks"/> array (only for base hard disks).
8703
8704 The following methods, besides <link to="IMedium::close"/>,
8705 automatically remove the hard disk from the media registry:
8706 <ul>
8707 <li><link to="#deleteStorage"/></li>
8708 <li><link to="#mergeTo"/></li>
8709 </ul>
8710
8711 If the storage unit of the hard disk is a regular file in the host's
8712 file system then the rules stated in the description of the
8713 <link to="IMedium::location"/> attribute apply when setting its value.
8714
8715 <h4>Automatic composition of the file name part</h4>
8716
8717 Another extension to the <link to="IMedium::location"/> attribute is that
8718 there is a possibility to cause VirtualBox to compose a unique value for
8719 the file name part of the location using the UUID of the hard disk. This
8720 applies only to hard disks in <link to="MediumState_NotCreated"/> state,
8721 e.g. before the storage unit is created, and works as follows. You set the
8722 value of the <link to="IMedium::location"/> attribute to a location
8723 specification which only contains the path specification but not the file
8724 name part and ends with either a forward slash or a backslash character.
8725 In response, VirtualBox will generate a new UUID for the hard disk and
8726 compose the file name using the following pattern:
8727 <pre>
8728 &lt;path&gt;/{&lt;uuid&gt;}.&lt;ext&gt;
8729 </pre>
8730 where <tt>&lt;path&gt;</tt> is the supplied path specification,
8731 <tt>&lt;uuid&gt;</tt> is the newly generated UUID and <tt>&lt;ext&gt;</tt>
8732 is the default extension for the storage format of this hard disk. After
8733 that, you may call any of the methods that create a new hard disk storage
8734 unit and they will use the generated UUID and file name.
8735
8736 <h3>Attaching Hard Disks</h3>
8737
8738 Hard disks are attached to virtual machines using the
8739 <link to="IMachine::attachDevice"/> method and detached using the
8740 <link to="IMachine::detachDevice"/> method. Depending on their
8741 <link to="#type"/>, hard disks are attached either
8742 <i>directly</i> or <i>indirectly</i>.
8743
8744 When a hard disk is being attached directly, it is associated with the
8745 virtual machine and used for hard disk operations when the machine is
8746 running. When a hard disk is being attached indirectly, a new differencing
8747 hard disk linked to it is implicitly created and this differencing hard
8748 disk is associated with the machine and used for hard disk operations.
8749 This also means that if <link to="IMachine::attachDevice"/> performs
8750 a direct attachment then the same hard disk will be returned in response
8751 to the subsequent <link to="IMachine::getMedium"/> call; however if
8752 an indirect attachment is performed then
8753 <link to="IMachine::getMedium"/> will return the implicitly created
8754 differencing hard disk, not the original one passed to <link
8755 to="IMachine::attachDevice"/>. In detail:
8756
8757 <ul>
8758 <li><b>Normal base</b> hard disks that do not have children (i.e.
8759 differencing hard disks linked to them) and that are not already
8760 attached to virtual machines in snapshots are attached <b>directly</b>.
8761 Otherwise, they are attached <b>indirectly</b> because having
8762 dependent children or being part of the snapshot makes it impossible
8763 to modify hard disk contents without breaking the integrity of the
8764 dependent party. The <link to="#readOnly"/> attribute allows to
8765 quickly determine the kind of the attachment for the given hard
8766 disk. Note that if a normal base hard disk is to be indirectly
8767 attached to a virtual machine with snapshots then a special
8768 procedure called <i>smart attachment</i> is performed (see below).</li>
8769 <li><b>Normal differencing</b> hard disks are like normal base hard disks:
8770 they are attached <b>directly</b> if they do not have children and are
8771 not attached to virtual machines in snapshots, and <b>indirectly</b>
8772 otherwise. Note that the smart attachment procedure is never performed
8773 for differencing hard disks.</li>
8774 <li><b>Immutable</b> hard disks are always attached <b>indirectly</b> because
8775 they are designed to be non-writable. If an immutable hard disk is
8776 attached to a virtual machine with snapshots then a special
8777 procedure called smart attachment is performed (see below).</li>
8778 <li><b>Writethrough</b> hard disks are always attached <b>directly</b>,
8779 also as designed. This also means that writethrough hard disks cannot
8780 have other hard disks linked to them at all.</li>
8781 <li><b>Shareable</b> hard disks are always attached <b>directly</b>,
8782 also as designed. This also means that shareable hard disks cannot
8783 have other hard disks linked to them at all. They behave almost
8784 like writethrough hard disks, except that shareable hard disks can
8785 be attached to several virtual machines which are running, allowing
8786 concurrent accesses. You need special cluster software running in
8787 the virtual machines to make use of such disks.</li>
8788 </ul>
8789
8790 Note that the same hard disk, regardless of its type, may be attached to
8791 more than one virtual machine at a time. In this case, the machine that is
8792 started first gains exclusive access to the hard disk and attempts to
8793 start other machines having this hard disk attached will fail until the
8794 first machine is powered down.
8795
8796 Detaching hard disks is performed in a <i>deferred</i> fashion. This means
8797 that the given hard disk remains associated with the given machine after a
8798 successful <link to="IMachine::detachDevice"/> call until
8799 <link to="IMachine::saveSettings"/> is called to save all changes to
8800 machine settings to disk. This deferring is necessary to guarantee that
8801 the hard disk configuration may be restored at any time by a call to
8802 <link to="IMachine::discardSettings"/> before the settings
8803 are saved (committed).
8804
8805 Note that if <link to="IMachine::discardSettings"/> is called after
8806 indirectly attaching some hard disks to the machine but before a call to
8807 <link to="IMachine::saveSettings"/> is made, it will implicitly delete
8808 all differencing hard disks implicitly created by
8809 <link to="IMachine::attachDevice"/> for these indirect attachments.
8810 Such implicitly created hard disks will also be immediately deleted when
8811 detached explicitly using the <link to="IMachine::detachDevice"/>
8812 call if it is made before <link to="IMachine::saveSettings"/>. This
8813 implicit deletion is safe because newly created differencing hard
8814 disks do not contain any user data.
8815
8816 However, keep in mind that detaching differencing hard disks that were
8817 implicitly created by <link to="IMachine::attachDevice"/>
8818 before the last <link to="IMachine::saveSettings"/> call will
8819 <b>not</b> implicitly delete them as they may already contain some data
8820 (for example, as a result of virtual machine execution). If these hard
8821 disks are no more necessary, the caller can always delete them explicitly
8822 using <link to="#deleteStorage"/> after they are actually de-associated
8823 from this machine by the <link to="IMachine::saveSettings"/> call.
8824
8825 <h3>Smart Attachment</h3>
8826
8827 When normal base or immutable hard disks are indirectly attached to a
8828 virtual machine then some additional steps are performed to make sure the
8829 virtual machine will have the most recent "view" of the hard disk being
8830 attached. These steps include walking through the machine's snapshots
8831 starting from the current one and going through ancestors up to the first
8832 snapshot. Hard disks attached to the virtual machine in all
8833 of the encountered snapshots are checked whether they are descendants of
8834 the given normal base or immutable hard disk. The first found child (which
8835 is the differencing hard disk) will be used instead of the normal base or
8836 immutable hard disk as a parent for creating a new differencing hard disk
8837 that will be actually attached to the machine. And only if no descendants
8838 are found or if the virtual machine does not have any snapshots then the
8839 normal base or immutable hard disk will be used itself as a parent for
8840 this differencing hard disk.
8841
8842 It is easier to explain what smart attachment does using the
8843 following example:
8844 <pre>
8845BEFORE attaching B.vdi: AFTER attaching B.vdi:
8846
8847Snapshot 1 (B.vdi) Snapshot 1 (B.vdi)
8848 Snapshot 2 (D1->B.vdi) Snapshot 2 (D1->B.vdi)
8849 Snapshot 3 (D2->D1.vdi) Snapshot 3 (D2->D1.vdi)
8850 Snapshot 4 (none) Snapshot 4 (none)
8851 CurState (none) CurState (D3->D2.vdi)
8852
8853 NOT
8854 ...
8855 CurState (D3->B.vdi)
8856 </pre>
8857 The first column is the virtual machine configuration before the base hard
8858 disk <tt>B.vdi</tt> is attached, the second column shows the machine after
8859 this hard disk is attached. Constructs like <tt>D1->B.vdi</tt> and similar
8860 mean that the hard disk that is actually attached to the machine is a
8861 differencing hard disk, <tt>D1.vdi</tt>, which is linked to (based on)
8862 another hard disk, <tt>B.vdi</tt>.
8863
8864 As we can see from the example, the hard disk <tt>B.vdi</tt> was detached
8865 from the machine before taking Snapshot 4. Later, after Snapshot 4 was
8866 taken, the user decides to attach <tt>B.vdi</tt> again. <tt>B.vdi</tt> has
8867 dependent child hard disks (<tt>D1.vdi</tt>, <tt>D2.vdi</tt>), therefore
8868 it cannot be attached directly and needs an indirect attachment (i.e.
8869 implicit creation of a new differencing hard disk). Due to the smart
8870 attachment procedure, the new differencing hard disk
8871 (<tt>D3.vdi</tt>) will be based on <tt>D2.vdi</tt>, not on
8872 <tt>B.vdi</tt> itself, since <tt>D2.vdi</tt> is the most recent view of
8873 <tt>B.vdi</tt> existing for this snapshot branch of the given virtual
8874 machine.
8875
8876 Note that if there is more than one descendant hard disk of the given base
8877 hard disk found in a snapshot, and there is an exact device, channel and
8878 bus match, then this exact match will be used. Otherwise, the youngest
8879 descendant will be picked up.
8880
8881 There is one more important aspect of the smart attachment procedure which
8882 is not related to snapshots at all. Before walking through the snapshots
8883 as described above, the backup copy of the current list of hard disk
8884 attachment is searched for descendants. This backup copy is created when
8885 the hard disk configuration is changed for the first time after the last
8886 <link to="IMachine::saveSettings"/> call and used by
8887 <link to="IMachine::discardSettings"/> to undo the recent hard disk
8888 changes. When such a descendant is found in this backup copy, it will be
8889 simply re-attached back, without creating a new differencing hard disk for
8890 it. This optimization is necessary to make it possible to re-attach the
8891 base or immutable hard disk to a different bus, channel or device slot
8892 without losing the contents of the differencing hard disk actually
8893 attached to the machine in place of it.
8894 </desc>
8895
8896 <attribute name="id" type="uuid" mod="string" readonly="yes">
8897 <desc>
8898 UUID of the medium. For a newly created medium, this value is a randomly
8899 generated UUID.
8900
8901 <note>
8902 For media in one of MediumState_NotCreated, MediumState_Creating or
8903 MediumState_Deleting states, the value of this property is undefined
8904 and will most likely be an empty UUID.
8905 </note>
8906 </desc>
8907 </attribute>
8908
8909 <attribute name="description" type="wstring">
8910 <desc>
8911 Optional description of the medium. For a newly created medium the value
8912 of this attribute is an empty string.
8913
8914 Medium types that don't support this attribute will return E_NOTIMPL in
8915 attempt to get or set this attribute's value.
8916
8917 <note>
8918 For some storage types, reading this attribute may return an outdated
8919 (last known) value when <link to="#state"/> is <link
8920 to="MediumState_Inaccessible"/> or <link
8921 to="MediumState_LockedWrite"/> because the value of this attribute is
8922 stored within the storage unit itself. Also note that changing the
8923 attribute value is not possible in such case, as well as when the
8924 medium is the <link to="MediumState_LockedRead"/> state.
8925 </note>
8926 </desc>
8927 </attribute>
8928
8929 <attribute name="state" type="MediumState" readonly="yes">
8930 <desc>
8931 Returns the current medium state, which is the last state set by
8932 the accessibility check performed by <link to="#refreshState"/>.
8933 If that method has not yet been called on the medium, the state
8934 is "Inaccessible"; as opposed to truly inaccessible media, the
8935 value of <link to="#lastAccessError"/> will be an empty string in
8936 that case.
8937
8938 <note>As of version 3.1, this no longer performs an accessibility check
8939 automatically; call <link to="#refreshState"/> for that.
8940 </note>
8941 </desc>
8942 </attribute>
8943
8944 <attribute name="variant" type="MediumVariant" readonly="yes">
8945 <desc>
8946 Returns the storage format variant information for this medium.
8947 Before <link to="#refreshState"/> is called this method returns
8948 an undefined value.
8949 </desc>
8950 </attribute>
8951
8952 <attribute name="location" type="wstring">
8953 <desc>
8954 Location of the storage unit holding medium data.
8955
8956 The format of the location string is medium type specific. For medium
8957 types using regular files in a host's file system, the location
8958 string is the full file name.
8959
8960 Some medium types may support changing the storage unit location by
8961 simply changing the value of this property. If this operation is not
8962 supported, the implementation will return E_NOTIMPL in attempt to set
8963 this attribute's value.
8964
8965 When setting a value of the location attribute which is a regular file
8966 in the host's file system, the given file name may be either relative to
8967 the <link to="IVirtualBox::homeFolder">VirtualBox home folder</link> or
8968 absolute. Note that if the given location specification does not contain
8969 the file extension part then a proper default extension will be
8970 automatically appended by the implementation depending on the medium type.
8971 </desc>
8972 </attribute>
8973
8974 <attribute name="name" type="wstring" readonly="yes">
8975 <desc>
8976 Name of the storage unit holding medium data.
8977
8978 The returned string is a short version of the <link to="#location"/>
8979 attribute that is suitable for representing the medium in situations
8980 where the full location specification is too long (such as lists
8981 and comboboxes in GUI frontends). This string is also used by frontends
8982 to sort the media list alphabetically when needed.
8983
8984 For example, for locations that are regular files in the host's file
8985 system, the value of this attribute is just the file name (+ extension),
8986 without the path specification.
8987
8988 Note that as opposed to the <link to="#location"/> attribute, the name
8989 attribute will not necessary be unique for a list of media of the
8990 given type and format.
8991 </desc>
8992 </attribute>
8993
8994 <attribute name="deviceType" type="DeviceType" readonly="yes">
8995 <desc>Kind of device (DVD/Floppy/HardDisk) which is applicable to this
8996 medium.</desc>
8997 </attribute>
8998
8999 <attribute name="hostDrive" type="boolean" readonly="yes">
9000 <desc>True if this corresponds to a drive on the host.</desc>
9001 </attribute>
9002
9003 <attribute name="size" type="long long" readonly="yes">
9004 <desc>
9005 Physical size of the storage unit used to hold medium data (in bytes).
9006
9007 <note>
9008 For media whose <link to="#state"/> is <link
9009 to="MediumState_Inaccessible"/>, the value of this property is the
9010 last known size. For <link to="MediumState_NotCreated"/> media,
9011 the returned value is zero.
9012 </note>
9013 </desc>
9014 </attribute>
9015
9016 <attribute name="format" type="wstring" readonly="yes">
9017 <desc>
9018 Storage format of this medium.
9019
9020 The value of this attribute is a string that specifies a backend used
9021 to store medium data. The storage format is defined when you create a
9022 new medium or automatically detected when you open an existing medium,
9023 and cannot be changed later.
9024
9025 The list of all storage formats supported by this VirtualBox
9026 installation can be obtained using
9027 <link to="ISystemProperties::mediumFormats"/>.
9028 </desc>
9029 </attribute>
9030
9031 <attribute name="mediumFormat" type="IMediumFormat" readonly="yes">
9032 <desc>
9033 Storage medium format object corresponding to this medium.
9034
9035 The value of this attribute is a reference to the medium format object
9036 that specifies the backend properties used to store medium data. The
9037 storage format is defined when you create a new medium or automatically
9038 detected when you open an existing medium, and cannot be changed later.
9039
9040 <note>@c null is returned if there is no associated medium format
9041 object. This can e.g. happen for medium objects representing host
9042 drives and other special medium objects.</note>
9043 </desc>
9044 </attribute>
9045
9046 <attribute name="type" type="MediumType">
9047 <desc>
9048 Type (role) of this medium.
9049
9050 The following constraints apply when changing the value of this
9051 attribute:
9052 <ul>
9053 <li>If a medium is attached to a virtual machine (either in the
9054 current state or in one of the snapshots), its type cannot be
9055 changed.
9056 </li>
9057 <li>As long as the medium has children, its type cannot be set
9058 to <link to="MediumType_Writethrough"/>.
9059 </li>
9060 <li>The type of all differencing media is
9061 <link to="MediumType_Normal"/> and cannot be changed.
9062 </li>
9063 </ul>
9064
9065 The type of a newly created or opened medium is set to
9066 <link to="MediumType_Normal"/>, except for DVD and floppy media,
9067 which have a type of <link to="MediumType_Writethrough"/>.
9068 </desc>
9069 </attribute>
9070
9071 <attribute name="parent" type="IMedium" readonly="yes">
9072 <desc>
9073 Parent of this medium (the medium this medium is directly based
9074 on).
9075
9076 Only differencing media have parents. For base (non-differencing)
9077 media, @c null is returned.
9078 </desc>
9079 </attribute>
9080
9081 <attribute name="children" type="IMedium" safearray="yes" readonly="yes">
9082 <desc>
9083 Children of this medium (all differencing media directly based
9084 on this medium). A @c null array is returned if this medium
9085 does not have any children.
9086 </desc>
9087 </attribute>
9088
9089 <attribute name="base" type="IMedium" readonly="yes">
9090 <desc>
9091 Base medium of this medium.
9092
9093 If this is a differencing medium, its base medium is the medium
9094 the given medium branch starts from. For all other types of media, this
9095 property returns the medium object itself (i.e. the same object this
9096 property is read on).
9097 </desc>
9098 </attribute>
9099
9100 <attribute name="readOnly" type="boolean" readonly="yes">
9101 <desc>
9102 Returns @c true if this medium is read-only and @c false otherwise.
9103
9104 A medium is considered to be read-only when its contents cannot be
9105 modified without breaking the integrity of other parties that depend on
9106 this medium such as its child media or snapshots of virtual machines
9107 where this medium is attached to these machines. If there are no
9108 children and no such snapshots then there is no dependency and the
9109 medium is not read-only.
9110
9111 The value of this attribute can be used to determine the kind of the
9112 attachment that will take place when attaching this medium to a
9113 virtual machine. If the value is @c false then the medium will
9114 be attached directly. If the value is @c true then the medium
9115 will be attached indirectly by creating a new differencing child
9116 medium for that. See the interface description for more information.
9117
9118 Note that all <link to="MediumType_Immutable">Immutable</link> media
9119 are always read-only while all
9120 <link to="MediumType_Writethrough">Writethrough</link> media are
9121 always not.
9122
9123 <note>
9124 The read-only condition represented by this attribute is related to
9125 the medium type and usage, not to the current
9126 <link to="IMedium::state">medium state</link> and not to the read-only
9127 state of the storage unit.
9128 </note>
9129 </desc>
9130 </attribute>
9131
9132 <attribute name="logicalSize" type="long long" readonly="yes">
9133 <desc>
9134 Logical size of this medium (in bytes), as reported to the
9135 guest OS running inside the virtual machine this medium is
9136 attached to. The logical size is defined when the medium is created
9137 and cannot be changed later.
9138
9139 <note>
9140 Reading this property on a differencing medium will return the size
9141 of its <link to="#base"/> medium.
9142 </note>
9143 <note>
9144 For media whose state is <link to="#state"/> is <link
9145 to="MediumState_Inaccessible"/>, the value of this property is the
9146 last known logical size. For <link to="MediumState_NotCreated"/>
9147 media, the returned value is zero.
9148 </note>
9149 </desc>
9150 </attribute>
9151
9152 <attribute name="autoReset" type="boolean">
9153 <desc>
9154 Whether this differencing medium will be automatically reset each
9155 time a virtual machine it is attached to is powered up. This
9156 attribute is automatically set to @c true for the last
9157 differencing image of an "immutable" medium (see
9158 <link to="MediumType" />).
9159
9160 See <link to="#reset"/> for more information about resetting
9161 differencing media.
9162
9163 <note>
9164 Reading this property on a base (non-differencing) medium will
9165 always @c false. Changing the value of this property in this
9166 case is not supported.
9167 </note>
9168
9169 <result name="VBOX_E_NOT_SUPPORTED">
9170 This is not a differencing medium (when changing the attribute
9171 value).
9172 </result>
9173 </desc>
9174 </attribute>
9175
9176 <attribute name="lastAccessError" type="wstring" readonly="yes">
9177 <desc>
9178 Text message that represents the result of the last accessibility
9179 check performed by <link to="#refreshState"/>.
9180
9181 An empty string is returned if the last accessibility check
9182 was successful or has not yet been called. As a result, if
9183 <link to="#state" /> is "Inaccessible" and this attribute is empty,
9184 then <link to="#refreshState"/> has yet to be called; this is the
9185 default value of media after VirtualBox initialization.
9186 A non-empty string indicates a failure and should normally describe
9187 a reason of the failure (for example, a file read error).
9188 </desc>
9189 </attribute>
9190
9191 <attribute name="machineIds" type="uuid" mod="string" safearray="yes" readonly="yes">
9192 <desc>
9193 Array of UUIDs of all machines this medium is attached to.
9194
9195 A @c null array is returned if this medium is not attached to any
9196 machine or to any machine's snapshot.
9197
9198 <note>
9199 The returned array will include a machine even if this medium is not
9200 attached to that machine in the current state but attached to it in
9201 one of the machine's snapshots. See <link to="#getSnapshotIds"/> for
9202 details.
9203 </note>
9204 </desc>
9205 </attribute>
9206
9207 <method name="setIDs">
9208 <desc>
9209 Changes the UUID and parent UUID for a hard disk medium.
9210 </desc>
9211 <param name="setImageId" type="boolean" dir="in">
9212 <desc>
9213 Select whether a new image UUID is set or not.
9214 </desc>
9215 </param>
9216 <param name="imageId" type="uuid" mod="string" dir="in">
9217 <desc>
9218 New UUID for the image. If an empty string is passed, then a new
9219 UUID is automatically created, provided that @a setImageId is @c true.
9220 Specifying a zero UUID is not allowed.
9221 </desc>
9222 </param>
9223 <param name="setParentId" type="boolean" dir="in">
9224 <desc>
9225 Select whether a new parent UUID is set or not.
9226 </desc>
9227 </param>
9228 <param name="parentId" type="uuid" mod="string" dir="in">
9229 <desc>
9230 New parent UUID for the image. If an empty string is passed, then a
9231 new UUID is automatically created, provided @a setParentId is
9232 @c true. A zero UUID is valid.
9233 </desc>
9234 </param>
9235 <result name="E_INVALIDARG">
9236 Invalid parameter combination.
9237 </result>
9238 <result name="VBOX_E_NOT_SUPPORTED">
9239 Medium is not a hard disk medium.
9240 </result>
9241 </method>
9242
9243 <method name="refreshState">
9244 <desc>
9245 If the current medium state (see <link to="MediumState"/>) is one of
9246 "Created", "Inaccessible" or "LockedRead", then this performs an
9247 accessibility check on the medium and sets the value of the <link to="#state"/>
9248 attribute accordingly; that value is also returned for convenience.
9249
9250 For all other state values, this does not perform a refresh but returns
9251 the state only.
9252
9253 The refresh, if performed, may take a long time (several seconds or even
9254 minutes, depending on the storage unit location and format) because it performs an
9255 accessibility check of the storage unit. This check may cause a significant
9256 delay if the storage unit of the given medium is, for example, a file located
9257 on a network share which is not currently accessible due to connectivity
9258 problems. In that case, the call will not return until a timeout
9259 interval defined by the host OS for this operation expires. For this reason,
9260 it is recommended to never read this attribute on the main UI thread to avoid
9261 making the UI unresponsive.
9262
9263 If the last known state of the medium is "Created" and the accessibility
9264 check fails, then the state would be set to "Inaccessible", and
9265 <link to="#lastAccessError"/> may be used to get more details about the
9266 failure. If the state of the medium is "LockedRead", then it remains the
9267 same, and a non-empty value of <link to="#lastAccessError"/> will
9268 indicate a failed accessibility check in this case.
9269
9270 Note that not all medium states are applicable to all medium types.
9271 </desc>
9272 <param name="state" type="MediumState" dir="return">
9273 <desc>
9274 New medium state.
9275 </desc>
9276 </param>
9277 </method>
9278
9279 <method name="getSnapshotIds">
9280 <desc>
9281 Returns an array of UUIDs of all snapshots of the given machine where
9282 this medium is attached to.
9283
9284 If the medium is attached to the machine in the current state, then the
9285 first element in the array will always be the ID of the queried machine
9286 (i.e. the value equal to the @c machineId argument), followed by
9287 snapshot IDs (if any).
9288
9289 If the medium is not attached to the machine in the current state, then
9290 the array will contain only snapshot IDs.
9291
9292 The returned array may be @c null if this medium is not attached
9293 to the given machine at all, neither in the current state nor in one of
9294 the snapshots.
9295 </desc>
9296 <param name="machineId" type="uuid" mod="string" dir="in">
9297 <desc>
9298 UUID of the machine to query.
9299 </desc>
9300 </param>
9301 <param name="snapshotIds" type="uuid" mod="string" safearray="yes" dir="return">
9302 <desc>
9303 Array of snapshot UUIDs of the given machine using this medium.
9304 </desc>
9305 </param>
9306 </method>
9307
9308 <method name="lockRead">
9309 <desc>
9310 Locks this medium for reading.
9311
9312 A read lock is shared: many clients can simultaneously lock the
9313 same medium for reading unless it is already locked for writing (see
9314 <link to="#lockWrite"/>) in which case an error is returned.
9315
9316 When the medium is locked for reading, it cannot be modified
9317 from within VirtualBox. This means that any method that changes
9318 the properties of this medium or contents of the storage unit
9319 will return an error (unless explicitly stated otherwise). That
9320 includes an attempt to start a virtual machine that wants to
9321 write to the the medium.
9322
9323 When the virtual machine is started up, it locks for reading all
9324 media it uses in read-only mode. If some medium cannot be locked
9325 for reading, the startup procedure will fail.
9326 A medium is typically locked for reading while it is used by a running
9327 virtual machine but has a depending differencing image that receives
9328 the actual write operations. This way one base medium can have
9329 multiple child differencing images which can be written to
9330 simultaneously. Read-only media such as DVD and floppy images are
9331 also locked for reading only (so they can be in use by multiple
9332 machines simultaneously).
9333
9334 A medium is also locked for reading when it is the source of a
9335 write operation such as <link to="#cloneTo"/> or <link to="#mergeTo"/>.
9336
9337 The medium locked for reading must be unlocked using the <link
9338 to="#unlockRead"/> method. Calls to <link to="#lockRead"/>
9339 can be nested and must be followed by the same number of paired
9340 <link to="#unlockRead"/> calls.
9341
9342 This method sets the medium state (see <link to="#state"/>) to
9343 "LockedRead" on success. The medium's previous state must be
9344 one of "Created", "Inaccessible" or "LockedRead".
9345
9346 Locking an inaccessible medium is not an error; this method performs
9347 a logical lock that prevents modifications of this medium through
9348 the VirtualBox API, not a physical file-system lock of the underlying
9349 storage unit.
9350
9351 This method returns the current state of the medium
9352 <i>before</i> the operation.
9353
9354 <result name="VBOX_E_INVALID_OBJECT_STATE">
9355 Invalid medium state (e.g. not created, locked, inaccessible,
9356 creating, deleting).
9357 </result>
9358
9359 </desc>
9360 <param name="state" type="MediumState" dir="return">
9361 <desc>
9362 State of the medium after the operation.
9363 </desc>
9364 </param>
9365 </method>
9366
9367 <method name="unlockRead">
9368 <desc>
9369 Cancels the read lock previously set by <link to="#lockRead"/>.
9370
9371 For both success and failure, this method returns the current state
9372 of the medium <i>after</i> the operation.
9373
9374 See <link to="#lockRead"/> for more details.
9375
9376 <result name="VBOX_E_INVALID_OBJECT_STATE">
9377 Medium not locked for reading.
9378 </result>
9379
9380 </desc>
9381 <param name="state" type="MediumState" dir="return">
9382 <desc>
9383 State of the medium after the operation.
9384 </desc>
9385 </param>
9386 </method>
9387
9388 <method name="lockWrite">
9389 <desc>
9390 Locks this medium for writing.
9391
9392 A write lock, as opposed to <link to="#lockRead"/>, is
9393 exclusive: there may be only one client holding a write lock,
9394 and there may be no read locks while the write lock is held.
9395 As a result, read-locking fails if a write lock is held, and
9396 write-locking fails if either a read or another write lock is held.
9397
9398 When a medium is locked for writing, it cannot be modified
9399 from within VirtualBox, and it is not guaranteed that the values
9400 of its properties are up-to-date. Any method that changes the
9401 properties of this medium or contents of the storage unit will
9402 return an error (unless explicitly stated otherwise).
9403
9404 When a virtual machine is started up, it locks for writing all
9405 media it uses to write data to. If any medium could not be locked
9406 for writing, the startup procedure will fail. If a medium has
9407 differencing images, then while the machine is running, only
9408 the last ("leaf") differencing image is locked for writing,
9409 whereas its parents are locked for reading only.
9410
9411 A medium is also locked for writing when it is the target of a
9412 write operation such as <link to="#cloneTo"/> or <link to="#mergeTo"/>.
9413
9414 The medium locked for writing must be unlocked using the <link
9415 to="#unlockWrite"/> method. Write locks <i>cannot</i> be nested.
9416
9417 This method sets the medium state (see <link to="#state"/>) to
9418 "LockedWrite" on success. The medium's previous state must be
9419 either "Created" or "Inaccessible".
9420
9421 Locking an inaccessible medium is not an error; this method performs
9422 a logical lock that prevents modifications of this medium through
9423 the VirtualBox API, not a physical file-system lock of the underlying
9424 storage unit.
9425
9426 For both, success and failure, this method returns the current
9427 state of the medium <i>before</i> the operation.
9428
9429 <result name="VBOX_E_INVALID_OBJECT_STATE">
9430 Invalid medium state (e.g. not created, locked, inaccessible,
9431 creating, deleting).
9432 </result>
9433
9434 </desc>
9435 <param name="state" type="MediumState" dir="return">
9436 <desc>
9437 State of the medium after the operation.
9438 </desc>
9439 </param>
9440 </method>
9441
9442 <method name="unlockWrite">
9443 <desc>
9444 Cancels the write lock previously set by <link to="#lockWrite"/>.
9445
9446 For both success and failure, this method returns the current
9447 state of the medium <i>after</i> the operation.
9448
9449 See <link to="#lockWrite"/> for more details.
9450
9451 <result name="VBOX_E_INVALID_OBJECT_STATE">
9452 Medium not locked for writing.
9453 </result>
9454
9455 </desc>
9456 <param name="state" type="MediumState" dir="return">
9457 <desc>
9458 State of the medium after the operation.
9459 </desc>
9460 </param>
9461 </method>
9462
9463 <method name="close">
9464 <desc>
9465 Closes this medium.
9466
9467 The medium must not be attached to any known virtual machine
9468 and must not have any known child media, otherwise the
9469 operation will fail.
9470
9471 When the medium is successfully closed, it is removed from
9472 the list of registered media, but its storage unit is not
9473 deleted. In particular, this means that this medium can
9474 later be opened again using the <link to="IVirtualBox::openMedium"/>
9475 call.
9476
9477 Note that after this method successfully returns, the given medium
9478 object becomes uninitialized. This means that any attempt
9479 to call any of its methods or attributes will fail with the
9480 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error.
9481
9482 <result name="VBOX_E_INVALID_OBJECT_STATE">
9483 Invalid medium state (other than not created, created or
9484 inaccessible).
9485 </result>
9486 <result name="VBOX_E_OBJECT_IN_USE">
9487 Medium attached to virtual machine.
9488 </result>
9489 <result name="VBOX_E_FILE_ERROR">
9490 Settings file not accessible.
9491 </result>
9492 <result name="VBOX_E_XML_ERROR">
9493 Could not parse the settings file.
9494 </result>
9495
9496 </desc>
9497 </method>
9498
9499 <!-- storage methods -->
9500
9501 <method name="getProperty">
9502 <desc>
9503 Returns the value of the custom medium property with the given name.
9504
9505 The list of all properties supported by the given medium format can
9506 be obtained with <link to="IMediumFormat::describeProperties"/>.
9507
9508 Note that if this method returns an empty string in @a value, the
9509 requested property is supported but currently not assigned any value.
9510
9511 <result name="VBOX_E_OBJECT_NOT_FOUND">
9512 Requested property does not exist (not supported by the format).
9513 </result>
9514 <result name="E_INVALIDARG">@a name is @c null or empty.</result>
9515 </desc>
9516 <param name="name" type="wstring" dir="in">
9517 <desc>Name of the property to get.</desc>
9518 </param>
9519 <param name="value" type="wstring" dir="return">
9520 <desc>Current property value.</desc>
9521 </param>
9522 </method>
9523
9524 <method name="setProperty">
9525 <desc>
9526 Sets the value of the custom medium property with the given name.
9527
9528 The list of all properties supported by the given medium format can
9529 be obtained with <link to="IMediumFormat::describeProperties"/>.
9530
9531 Note that setting the property value to @c null or an empty string is
9532 equivalent to deleting the existing value. A default value (if it is
9533 defined for this property) will be used by the format backend in this
9534 case.
9535
9536 <result name="VBOX_E_OBJECT_NOT_FOUND">
9537 Requested property does not exist (not supported by the format).
9538 </result>
9539 <result name="E_INVALIDARG">@a name is @c null or empty.</result>
9540 </desc>
9541 <param name="name" type="wstring" dir="in">
9542 <desc>Name of the property to set.</desc>
9543 </param>
9544 <param name="value" type="wstring" dir="in">
9545 <desc>Property value to set.</desc>
9546 </param>
9547 </method>
9548
9549 <method name="getProperties">
9550 <desc>
9551 Returns values for a group of properties in one call.
9552
9553 The names of the properties to get are specified using the @a names
9554 argument which is a list of comma-separated property names or
9555 an empty string if all properties are to be returned. Note that currently
9556 the value of this argument is ignored and the method always returns all
9557 existing properties.
9558
9559 The list of all properties supported by the given medium format can
9560 be obtained with <link to="IMediumFormat::describeProperties"/>.
9561
9562 The method returns two arrays, the array of property names corresponding
9563 to the @a names argument and the current values of these properties.
9564 Both arrays have the same number of elements with each elemend at the
9565 given index in the first array corresponds to an element at the same
9566 index in the second array.
9567
9568 Note that for properties that do not have assigned values,
9569 an empty string is returned at the appropriate index in the
9570 @a returnValues array.
9571
9572 </desc>
9573 <param name="names" type="wstring" dir="in">
9574 <desc>
9575 Names of properties to get.
9576 </desc>
9577 </param>
9578 <param name="returnNames" type="wstring" safearray="yes" dir="out">
9579 <desc>Names of returned properties.</desc>
9580 </param>
9581 <param name="returnValues" type="wstring" safearray="yes" dir="return">
9582 <desc>Values of returned properties.</desc>
9583 </param>
9584 </method>
9585
9586 <method name="setProperties">
9587 <desc>
9588 Sets values for a group of properties in one call.
9589
9590 The names of the properties to set are passed in the @a names
9591 array along with the new values for them in the @a values array. Both
9592 arrays have the same number of elements with each elemend at the given
9593 index in the first array corresponding to an element at the same index
9594 in the second array.
9595
9596 If there is at least one property name in @a names that is not valid,
9597 the method will fail before changing the values of any other properties
9598 from the @a names array.
9599
9600 Using this method over <link to="#setProperty"/> is preferred if you
9601 need to set several properties at once since it will result into less
9602 IPC calls.
9603
9604 The list of all properties supported by the given medium format can
9605 be obtained with <link to="IMediumFormat::describeProperties"/>.
9606
9607 Note that setting the property value to @c null or an empty string is
9608 equivalent to deleting the existing value. A default value (if it is
9609 defined for this property) will be used by the format backend in this
9610 case.
9611 </desc>
9612 <param name="names" type="wstring" safearray="yes" dir="in">
9613 <desc>Names of properties to set.</desc>
9614 </param>
9615 <param name="values" type="wstring" safearray="yes" dir="in">
9616 <desc>Values of properties to set.</desc>
9617 </param>
9618 </method>
9619
9620 <!-- storage methods -->
9621
9622 <method name="createBaseStorage">
9623 <desc>
9624 Starts creating a hard disk storage unit (fixed/dynamic, according
9625 to the variant flags) in in the background. The previous storage unit
9626 created for this object, if any, must first be deleted using
9627 <link to="#deleteStorage"/>, otherwise the operation will fail.
9628
9629 Before the operation starts, the medium is placed in
9630 <link to="MediumState_Creating"/> state. If the create operation
9631 fails, the medium will be placed back in <link to="MediumState_NotCreated"/>
9632 state.
9633
9634 After the returned progress object reports that the operation has
9635 successfully completed, the medium state will be set to <link
9636 to="MediumState_Created"/>, the medium will be remembered by this
9637 VirtualBox installation and may be attached to virtual machines.
9638
9639 <result name="VBOX_E_NOT_SUPPORTED">
9640 The variant of storage creation operation is not supported. See <link
9641 to="IMediumFormat::capabilities"/>.
9642 </result>
9643 </desc>
9644 <param name="logicalSize" type="long long" dir="in">
9645 <desc>Maximum logical size of the medium in bytes.</desc>
9646 </param>
9647 <param name="variant" type="MediumVariant" dir="in">
9648 <desc>Exact image variant which should be created.</desc>
9649 </param>
9650 <param name="progress" type="IProgress" dir="return">
9651 <desc>Progress object to track the operation completion.</desc>
9652 </param>
9653 </method>
9654
9655 <method name="deleteStorage">
9656 <desc>
9657 Starts deleting the storage unit of this medium.
9658
9659 The medium must not be attached to any known virtual machine and must
9660 not have any known child media, otherwise the operation will fail.
9661 It will also fail if there is no storage unit to delete or if deletion
9662 is already in progress, or if the medium is being in use (locked for
9663 read or for write) or inaccessible. Therefore, the only valid state for
9664 this operation to succeed is <link to="MediumState_Created"/>.
9665
9666 Before the operation starts, the medium is placed in
9667 <link to="MediumState_Deleting"/> state and gets removed from the list
9668 of remembered hard disks (media registry). If the delete operation
9669 fails, the medium will be remembered again and placed back to
9670 <link to="MediumState_Created"/> state.
9671
9672 After the returned progress object reports that the operation is
9673 complete, the medium state will be set to
9674 <link to="MediumState_NotCreated"/> and you will be able to use one of
9675 the storage creation methods to create it again.
9676
9677 <see>#close()</see>
9678
9679 <result name="VBOX_E_OBJECT_IN_USE">
9680 Medium is attached to a virtual machine.
9681 </result>
9682 <result name="VBOX_E_NOT_SUPPORTED">
9683 Storage deletion is not allowed because neither of storage creation
9684 operations are supported. See
9685 <link to="IMediumFormat::capabilities"/>.
9686 </result>
9687
9688 <note>
9689 If the deletion operation fails, it is not guaranteed that the storage
9690 unit still exists. You may check the <link to="IMedium::state"/> value
9691 to answer this question.
9692 </note>
9693 </desc>
9694 <param name="progress" type="IProgress" dir="return">
9695 <desc>Progress object to track the operation completion.</desc>
9696 </param>
9697 </method>
9698
9699 <!-- diff methods -->
9700
9701 <method name="createDiffStorage">
9702 <desc>
9703 Starts creating an empty differencing storage unit based on this
9704 medium in the format and at the location defined by the @a target
9705 argument.
9706
9707 The target medium must be in <link to="MediumState_NotCreated"/>
9708 state (i.e. must not have an existing storage unit). Upon successful
9709 completion, this operation will set the type of the target medium to
9710 <link to="MediumType_Normal"/> and create a storage unit necessary to
9711 represent the differencing medium data in the given format (according
9712 to the storage format of the target object).
9713
9714 After the returned progress object reports that the operation is
9715 successfully complete, the target medium gets remembered by this
9716 VirtualBox installation and may be attached to virtual machines.
9717
9718 <note>
9719 The medium will be set to <link to="MediumState_LockedRead"/>
9720 state for the duration of this operation.
9721 </note>
9722 <result name="VBOX_E_OBJECT_IN_USE">
9723 Medium not in @c NotCreated state.
9724 </result>
9725 </desc>
9726 <param name="target" type="IMedium" dir="in">
9727 <desc>Target medium.</desc>
9728 </param>
9729 <param name="variant" type="MediumVariant" dir="in">
9730 <desc>Exact image variant which should be created.</desc>
9731 </param>
9732 <param name="progress" type="IProgress" dir="return">
9733 <desc>Progress object to track the operation completion.</desc>
9734 </param>
9735 </method>
9736
9737 <method name="mergeTo">
9738 <desc>
9739 Starts merging the contents of this medium and all intermediate
9740 differencing media in the chain to the given target medium.
9741
9742 The target medium must be either a descendant of this medium or
9743 its ancestor (otherwise this method will immediately return a failure).
9744 It follows that there are two logical directions of the merge operation:
9745 from ancestor to descendant (<i>forward merge</i>) and from descendant to
9746 ancestor (<i>backward merge</i>). Let us consider the following medium
9747 chain:
9748
9749 <pre>Base &lt;- Diff_1 &lt;- Diff_2</pre>
9750
9751 Here, calling this method on the <tt>Base</tt> medium object with
9752 <tt>Diff_2</tt> as an argument will be a forward merge; calling it on
9753 <tt>Diff_2</tt> with <tt>Base</tt> as an argument will be a backward
9754 merge. Note that in both cases the contents of the resulting medium
9755 will be the same, the only difference is the medium object that takes
9756 the result of the merge operation. In case of the forward merge in the
9757 above example, the result will be written to <tt>Diff_2</tt>; in case of
9758 the backward merge, the result will be written to <tt>Base</tt>. In
9759 other words, the result of the operation is always stored in the target
9760 medium.
9761
9762 Upon successful operation completion, the storage units of all media in
9763 the chain between this (source) medium and the target medium, including
9764 the source medium itself, will be automatically deleted and the
9765 relevant medium objects (including this medium) will become
9766 uninitialized. This means that any attempt to call any of
9767 their methods or attributes will fail with the
9768 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error. Applied to the above
9769 example, the forward merge of <tt>Base</tt> to <tt>Diff_2</tt> will
9770 delete and uninitialize both <tt>Base</tt> and <tt>Diff_1</tt> media.
9771 Note that <tt>Diff_2</tt> in this case will become a base medium
9772 itself since it will no longer be based on any other medium.
9773
9774 Considering the above, all of the following conditions must be met in
9775 order for the merge operation to succeed:
9776 <ul>
9777 <li>
9778 Neither this (source) medium nor any intermediate
9779 differencing medium in the chain between it and the target
9780 medium is attached to any virtual machine.
9781 </li>
9782 <li>
9783 Neither the source medium nor the target medium is an
9784 <link to="MediumType_Immutable"/> medium.
9785 </li>
9786 <li>
9787 The part of the medium tree from the source medium to the
9788 target medium is a linear chain, i.e. all medium in this
9789 chain have exactly one child which is the next medium in this
9790 chain. The only exception from this rule is the target medium in
9791 the forward merge operation; it is allowed to have any number of
9792 child media because the merge operation will not change its
9793 logical contents (as it is seen by the guest OS or by children).
9794 </li>
9795 <li>
9796 None of the involved media are in
9797 <link to="MediumState_LockedRead"/> or
9798 <link to="MediumState_LockedWrite"/> state.
9799 </li>
9800 </ul>
9801
9802 <note>
9803 This (source) medium and all intermediates will be placed to <link
9804 to="MediumState_Deleting"/> state and the target medium will be
9805 placed to <link to="MediumState_LockedWrite"/> state and for the
9806 duration of this operation.
9807 </note>
9808 </desc>
9809 <param name="target" type="IMedium" dir="in">
9810 <desc>Target medium.</desc>
9811 </param>
9812 <param name="progress" type="IProgress" dir="return">
9813 <desc>Progress object to track the operation completion.</desc>
9814 </param>
9815 </method>
9816
9817 <!-- clone method -->
9818
9819 <method name="cloneTo">
9820 <desc>
9821 Starts creating a clone of this medium in the format and at the
9822 location defined by the @a target argument.
9823
9824 The target medium must be either in <link to="MediumState_NotCreated"/>
9825 state (i.e. must not have an existing storage unit) or in
9826 <link to="MediumState_Created"/> state (i.e. created and not locked, and
9827 big enough to hold the data or else the copy will be partial). Upon
9828 successful completion, the cloned medium will contain exactly the
9829 same sector data as the medium being cloned, except that in the
9830 first case a new UUID for the clone will be randomly generated, and in
9831 the second case the UUID will remain unchanged.
9832
9833 The @a parent argument defines which medium will be the parent
9834 of the clone. Passing a @c null reference indicates that the clone will
9835 be a base image, i.e. completely independent. It is possible to specify
9836 an arbitrary medium for this parameter, including the parent of the
9837 medium which is being cloned. Even cloning to a child of the source
9838 medium is possible. Note that when cloning to an existing image, the
9839 @a parent irgument is ignored.
9840
9841 After the returned progress object reports that the operation is
9842 successfully complete, the target medium gets remembered by this
9843 VirtualBox installation and may be attached to virtual machines.
9844
9845 <note>
9846 This medium will be placed to <link to="MediumState_LockedRead"/>
9847 state for the duration of this operation.
9848 </note>
9849 <result name="E_NOTIMPL">
9850 The specified cloning variant is not supported at the moment.
9851 </result>
9852 </desc>
9853 <param name="target" type="IMedium" dir="in">
9854 <desc>Target medium.</desc>
9855 </param>
9856 <param name="variant" type="MediumVariant" dir="in">
9857 <desc>Exact image variant which should be created.</desc>
9858 </param>
9859 <param name="parent" type="IMedium" dir="in">
9860 <desc>Parent of the cloned medium.</desc>
9861 </param>
9862 <param name="progress" type="IProgress" dir="return">
9863 <desc>Progress object to track the operation completion.</desc>
9864 </param>
9865 </method>
9866
9867 <!-- other methods -->
9868
9869 <method name="compact">
9870 <desc>
9871 Starts compacting of this medium. This means that the medium is
9872 transformed into a possibly more compact storage representation.
9873 This potentially creates temporary images, which can require a
9874 substantial amount of additional disk space.
9875
9876 This medium will be placed to <link to="MediumState_LockedWrite"/>
9877 state and all its parent media (if any) will be placed to
9878 <link to="MediumState_LockedRead"/> state for the duration of this
9879 operation.
9880
9881 Please note that the results can be either returned straight away,
9882 or later as the result of the background operation via the object
9883 returned via the @a progress parameter.
9884
9885 <result name="VBOX_E_NOT_SUPPORTED">
9886 Medium format does not support compacting (but potentially
9887 needs it).
9888 </result>
9889 </desc>
9890 <param name="progress" type="IProgress" dir="return">
9891 <desc>Progress object to track the operation completion.</desc>
9892 </param>
9893 </method>
9894
9895 <method name="resize">
9896 <desc>
9897 Starts resizing this medium. This means that the nominal size of the
9898 medium is set to the new value. Both increasing and decreasing the
9899 size is possible, and there are no safety checks, since VirtualBox
9900 does not make any assumptions about the medium contents.
9901
9902 Resizing usually needs additional disk space, and possibly also
9903 some temporary disk space. Note that resize does not create a full
9904 temporary copy of the medium, so the additional disk space requirement
9905 is usually much lower than using the clone operation.
9906
9907 This medium will be placed to <link to="MediumState_LockedWrite"/>
9908 state for the duration of this operation.
9909
9910 Please note that the results can be either returned straight away,
9911 or later as the result of the background operation via the object
9912 returned via the @a progress parameter.
9913
9914 <result name="VBOX_E_NOT_SUPPORTED">
9915 Medium format does not support resizing.
9916 </result>
9917 </desc>
9918 <param name="logicalSize" type="long long" dir="in">
9919 <desc>New nominal capacity of the medium in bytes.</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 <method name="reset">
9927 <desc>
9928 Starts erasing the contents of this differencing medium.
9929
9930 This operation will reset the differencing medium to its initial
9931 state when it does not contain any sector data and any read operation is
9932 redirected to its parent medium. This automatically gets called
9933 during VM power-up for every medium whose <link to="#autoReset" />
9934 attribute is @c true.
9935
9936 The medium will be write-locked for the duration of this operation (see
9937 <link to="#lockWrite" />).
9938
9939 <result name="VBOX_E_NOT_SUPPORTED">
9940 This is not a differencing medium.
9941 </result>
9942 <result name="VBOX_E_INVALID_OBJECT_STATE">
9943 Medium is not in <link to="MediumState_Created"/> or
9944 <link to="MediumState_Inaccessible"/> state.
9945 </result>
9946 </desc>
9947 <param name="progress" type="IProgress" dir="return">
9948 <desc>Progress object to track the operation completion.</desc>
9949 </param>
9950 </method>
9951
9952 </interface>
9953
9954
9955 <!--
9956 // IMediumFormat
9957 /////////////////////////////////////////////////////////////////////////
9958 -->
9959
9960 <enum
9961 name="DataType"
9962 uuid="d90ea51e-a3f1-4a01-beb1-c1723c0d3ba7"
9963 >
9964 <const name="Int32" value="0"/>
9965 <const name="Int8" value="1"/>
9966 <const name="String" value="2"/>
9967 </enum>
9968
9969 <enum
9970 name="DataFlags"
9971 uuid="86884dcf-1d6b-4f1b-b4bf-f5aa44959d60"
9972 >
9973 <const name="None" value="0x00"/>
9974 <const name="Mandatory" value="0x01"/>
9975 <const name="Expert" value="0x02"/>
9976 <const name="Array" value="0x04"/>
9977 <const name="FlagMask" value="0x07"/>
9978 </enum>
9979
9980 <enum
9981 name="MediumFormatCapabilities"
9982 uuid="7342ba79-7ce0-4d94-8f86-5ed5a185d9bd"
9983 >
9984 <desc>
9985 Medium format capability flags.
9986 </desc>
9987
9988 <const name="Uuid" value="0x01">
9989 <desc>
9990 Supports UUIDs as expected by VirtualBox code.
9991 </desc>
9992 </const>
9993
9994 <const name="CreateFixed" value="0x02">
9995 <desc>
9996 Supports creating fixed size images, allocating all space instantly.
9997 </desc>
9998 </const>
9999
10000 <const name="CreateDynamic" value="0x04">
10001 <desc>
10002 Supports creating dynamically growing images, allocating space on
10003 demand.
10004 </desc>
10005 </const>
10006
10007 <const name="CreateSplit2G" value="0x08">
10008 <desc>
10009 Supports creating images split in chunks of a bit less than 2 GBytes.
10010 </desc>
10011 </const>
10012
10013 <const name="Differencing" value="0x10">
10014 <desc>
10015 Supports being used as a format for differencing media (see <link
10016 to="IMedium::createDiffStorage"/>).
10017 </desc>
10018 </const>
10019
10020 <const name="Asynchronous" value="0x20">
10021 <desc>
10022 Supports asynchronous I/O operations for at least some configurations.
10023 </desc>
10024 </const>
10025
10026 <const name="File" value="0x40">
10027 <desc>
10028 The format backend operates on files (the <link to="IMedium::location"/>
10029 attribute of the medium specifies a file used to store medium
10030 data; for a list of supported file extensions see
10031 <link to="IMediumFormat::fileExtensions"/>).
10032 </desc>
10033 </const>
10034
10035 <const name="Properties" value="0x80">
10036 <desc>
10037 The format backend uses the property interface to configure the storage
10038 location and properties (the <link to="IMediumFormat::describeProperties"/>
10039 method is used to get access to properties supported by the given medium format).
10040 </desc>
10041 </const>
10042
10043 <const name="TcpNetworking" value="0x100">
10044 <desc>
10045 The format backend uses the TCP networking interface for network access.
10046 </desc>
10047 </const>
10048
10049 <const name="VFS" value="0x200">
10050 <desc>
10051 The format backend supports virtual filesystem functionality.
10052 </desc>
10053 </const>
10054
10055 <const name="CapabilityMask" value="0x3FF"/>
10056 </enum>
10057
10058 <interface
10059 name="IMediumFormat" extends="$unknown"
10060 uuid="89f52554-d469-4799-9fad-1705e86a08b1"
10061 wsmap="managed"
10062 >
10063 <desc>
10064 The IMediumFormat interface represents a medium format.
10065
10066 Each medium format has an associated backend which is used to handle
10067 media stored in this format. This interface provides information
10068 about the properties of the associated backend.
10069
10070 Each medium format is identified by a string represented by the
10071 <link to="#id"/> attribute. This string is used in calls like
10072 <link to="IVirtualBox::createHardDisk"/> to specify the desired
10073 format.
10074
10075 The list of all supported medium formats can be obtained using
10076 <link to="ISystemProperties::mediumFormats"/>.
10077
10078 <see>IMedium</see>
10079 </desc>
10080
10081 <attribute name="id" type="wstring" readonly="yes">
10082 <desc>
10083 Identifier of this format.
10084
10085 The format identifier is a non-@c null non-empty ASCII string. Note that
10086 this string is case-insensitive. This means that, for example, all of
10087 the following strings:
10088 <pre>
10089 "VDI"
10090 "vdi"
10091 "VdI"</pre>
10092 refer to the same medium format.
10093
10094 This string is used in methods of other interfaces where it is necessary
10095 to specify a medium format, such as
10096 <link to="IVirtualBox::createHardDisk"/>.
10097 </desc>
10098 </attribute>
10099
10100 <attribute name="name" type="wstring" readonly="yes">
10101 <desc>
10102 Human readable description of this format.
10103
10104 Mainly for use in file open dialogs.
10105 </desc>
10106 </attribute>
10107
10108 <attribute name="fileExtensions" type="wstring" safearray="yes" readonly="yes">
10109 <desc>
10110 Array of strings containing the supported file extensions.
10111
10112 The first extension in the array is the extension preferred by the
10113 backend. It is recommended to use this extension when specifying a
10114 location of the storage unit for a new medium.
10115
10116 Note that some backends do not work on files, so this array may be
10117 empty.
10118
10119 <see>IMediumFormat::capabilities</see>
10120 </desc>
10121 </attribute>
10122
10123 <attribute name="capabilities" type="unsigned long" readonly="yes">
10124 <desc>
10125 Capabilities of the format as a set of bit flags.
10126
10127 For the meaning of individual capability flags see
10128 <link to="MediumFormatCapabilities"/>.
10129 </desc>
10130 </attribute>
10131
10132 <method name="describeProperties">
10133 <desc>
10134 Returns several arrays describing the properties supported by this
10135 format.
10136
10137 An element with the given index in each array describes one
10138 property. Thus, the number of elements in each returned array is the
10139 same and corresponds to the number of supported properties.
10140
10141 The returned arrays are filled in only if the
10142 <link to="MediumFormatCapabilities_Properties"/> flag is set.
10143 All arguments must be non-@c null.
10144
10145 <see>DataType</see>
10146 <see>DataFlags</see>
10147 </desc>
10148
10149 <param name="names" type="wstring" safearray="yes" dir="out">
10150 <desc>Array of property names.</desc>
10151 </param>
10152 <param name="description" type="wstring" safearray="yes" dir="out">
10153 <desc>Array of property descriptions.</desc>
10154 </param>
10155 <param name="types" type="DataType" safearray="yes" dir="out">
10156 <desc>Array of property types.</desc>
10157 </param>
10158 <param name="flags" type="unsigned long" safearray="yes" dir="out">
10159 <desc>Array of property flags.</desc>
10160 </param>
10161 <param name="defaults" type="wstring" safearray="yes" dir="out">
10162 <desc>Array of default property values.</desc>
10163 </param>
10164 </method>
10165
10166 </interface>
10167
10168
10169 <!--
10170 // IKeyboard
10171 /////////////////////////////////////////////////////////////////////////
10172 -->
10173
10174 <interface
10175 name="IKeyboard" extends="$unknown"
10176 uuid="f6916ec5-a881-4237-898f-7de58cf88672"
10177 wsmap="managed"
10178 >
10179 <desc>
10180 The IKeyboard interface represents the virtual machine's keyboard. Used
10181 in <link to="IConsole::keyboard"/>.
10182
10183 Use this interface to send keystrokes or the Ctrl-Alt-Del sequence
10184 to the virtual machine.
10185
10186 </desc>
10187 <method name="putScancode">
10188 <desc>Sends a scancode to the keyboard.
10189
10190 <result name="VBOX_E_IPRT_ERROR">
10191 Could not send scan code to virtual keyboard.
10192 </result>
10193
10194 </desc>
10195 <param name="scancode" type="long" dir="in"/>
10196 </method>
10197
10198 <method name="putScancodes">
10199 <desc>Sends an array of scancodes to the keyboard.
10200
10201 <result name="VBOX_E_IPRT_ERROR">
10202 Could not send all scan codes to virtual keyboard.
10203 </result>
10204
10205 </desc>
10206 <param name="scancodes" type="long" dir="in" safearray="yes"/>
10207 <param name="codesStored" type="unsigned long" dir="return"/>
10208 </method>
10209
10210 <method name="putCAD">
10211 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard. This
10212 function is nothing special, it is just a convenience function
10213 calling <link to="IKeyboard::putScancodes"/> with the proper scancodes.
10214
10215 <result name="VBOX_E_IPRT_ERROR">
10216 Could not send all scan codes to virtual keyboard.
10217 </result>
10218
10219 </desc>
10220 </method>
10221
10222 <attribute name="eventSource" type="IEventSource" readonly="yes">
10223 <desc>
10224 Event source for keyboard events.
10225 </desc>
10226 </attribute>
10227
10228 </interface>
10229
10230
10231 <!--
10232 // IMouse
10233 /////////////////////////////////////////////////////////////////////////
10234 -->
10235
10236 <enum
10237 name="MouseButtonState"
10238 uuid="9ee094b8-b28a-4d56-a166-973cb588d7f8"
10239 >
10240 <desc>
10241 Mouse button state.
10242 </desc>
10243
10244 <const name="LeftButton" value="0x01"/>
10245 <const name="RightButton" value="0x02"/>
10246 <const name="MiddleButton" value="0x04"/>
10247 <const name="WheelUp" value="0x08"/>
10248 <const name="WheelDown" value="0x10"/>
10249 <const name="XButton1" value="0x20"/>
10250 <const name="XButton2" value="0x40"/>
10251 <const name="MouseStateMask" value="0x7F"/>
10252 </enum>
10253
10254 <interface
10255 name="IMouse" extends="$unknown"
10256 uuid="05044a52-7811-4f00-ae3a-0ab7ff707b10"
10257 wsmap="managed"
10258 >
10259 <desc>
10260 The IMouse interface represents the virtual machine's mouse. Used in
10261 <link to="IConsole::mouse"/>.
10262
10263 Through this interface, the virtual machine's virtual mouse can be
10264 controlled.
10265 </desc>
10266
10267 <attribute name="absoluteSupported" type="boolean" readonly="yes">
10268 <desc>
10269 Whether the guest OS supports absolute mouse pointer positioning
10270 or not.
10271 <note>
10272 You can use the <link to="IMouseCapabilityChangedEvent"/>
10273 event to be instantly informed about changes of this attribute
10274 during virtual machine execution.
10275 </note>
10276 <see><link to="#putMouseEventAbsolute"/></see>
10277 </desc>
10278 </attribute>
10279
10280 <attribute name="relativeSupported" type="boolean" readonly="yes">
10281 <desc>
10282 Whether the guest OS supports relative mouse pointer positioning
10283 or not.
10284 <note>
10285 You can use the <link to="IMouseCapabilityChangedEvent"/>
10286 event to be instantly informed about changes of this attribute
10287 during virtual machine execution.
10288 </note>
10289 <see><link to="#putMouseEvent"/></see>
10290 </desc>
10291 </attribute>
10292
10293 <attribute name="needsHostCursor" type="boolean" readonly="yes">
10294 <desc>
10295 Whether the guest OS can currently switch to drawing it's own mouse
10296 cursor on demand.
10297 <note>
10298 You can use the <link to="IMouseCapabilityChangedEvent"/>
10299 event to be instantly informed about changes of this attribute
10300 during virtual machine execution.
10301 </note>
10302 <see><link to="#putMouseEvent"/></see>
10303 </desc>
10304 </attribute>
10305
10306 <method name="putMouseEvent">
10307 <desc>
10308 Initiates a mouse event using relative pointer movements
10309 along x and y axis.
10310
10311 <result name="E_ACCESSDENIED">
10312 Console not powered up.
10313 </result>
10314 <result name="VBOX_E_IPRT_ERROR">
10315 Could not send mouse event to virtual mouse.
10316 </result>
10317
10318 </desc>
10319
10320 <param name="dx" type="long" dir="in">
10321 <desc>
10322 Amount of pixels the mouse should move to the right.
10323 Negative values move the mouse to the left.
10324 </desc>
10325 </param>
10326 <param name="dy" type="long" dir="in">
10327 <desc>
10328 Amount of pixels the mouse should move downwards.
10329 Negative values move the mouse upwards.
10330 </desc>
10331 </param>
10332 <param name="dz" type="long" dir="in">
10333 <desc>
10334 Amount of mouse wheel moves.
10335 Positive values describe clockwise wheel rotations,
10336 negative values describe counterclockwise rotations.
10337 </desc>
10338 </param>
10339 <param name="dw" type="long" dir="in">
10340 <desc>
10341 Amount of horizontal mouse wheel moves.
10342 Positive values describe a movement to the left,
10343 negative values describe a movement to the right.
10344 </desc>
10345 </param>
10346 <param name="buttonState" type="long" dir="in">
10347 <desc>
10348 The current state of mouse buttons. Every bit represents
10349 a mouse button as follows:
10350 <table>
10351 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10352 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10353 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10354 </table>
10355 A value of <tt>1</tt> means the corresponding button is pressed.
10356 otherwise it is released.
10357 </desc>
10358 </param>
10359 </method>
10360
10361 <method name="putMouseEventAbsolute">
10362 <desc>
10363 Positions the mouse pointer using absolute x and y coordinates.
10364 These coordinates are expressed in pixels and
10365 start from <tt>[1,1]</tt> which corresponds to the top left
10366 corner of the virtual display.
10367
10368 <result name="E_ACCESSDENIED">
10369 Console not powered up.
10370 </result>
10371 <result name="VBOX_E_IPRT_ERROR">
10372 Could not send mouse event to virtual mouse.
10373 </result>
10374
10375 <note>
10376 This method will have effect only if absolute mouse
10377 positioning is supported by the guest OS.
10378 </note>
10379
10380 <see><link to="#absoluteSupported"/></see>
10381 </desc>
10382
10383 <param name="x" type="long" dir="in">
10384 <desc>
10385 X coordinate of the pointer in pixels, starting from @c 1.
10386 </desc>
10387 </param>
10388 <param name="y" type="long" dir="in">
10389 <desc>
10390 Y coordinate of the pointer in pixels, starting from @c 1.
10391 </desc>
10392 </param>
10393 <param name="dz" type="long" dir="in">
10394 <desc>
10395 Amount of mouse wheel moves.
10396 Positive values describe clockwise wheel rotations,
10397 negative values describe counterclockwise rotations.
10398 </desc>
10399 </param>
10400 <param name="dw" type="long" dir="in">
10401 <desc>
10402 Amount of horizontal mouse wheel moves.
10403 Positive values describe a movement to the left,
10404 negative values describe a movement to the right.
10405 </desc>
10406 </param>
10407 <param name="buttonState" type="long" dir="in">
10408 <desc>
10409 The current state of mouse buttons. Every bit represents
10410 a mouse button as follows:
10411 <table>
10412 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10413 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10414 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10415 </table>
10416 A value of @c 1 means the corresponding button is pressed.
10417 otherwise it is released.
10418 </desc>
10419 </param>
10420 </method>
10421
10422 <attribute name="eventSource" type="IEventSource" readonly="yes">
10423 <desc>
10424 Event source for mouse events.
10425 </desc>
10426 </attribute>
10427
10428 </interface>
10429
10430 <!--
10431 // IDisplay
10432 /////////////////////////////////////////////////////////////////////////
10433 -->
10434
10435 <enum
10436 name="FramebufferPixelFormat"
10437 uuid="7acfd5ed-29e3-45e3-8136-73c9224f3d2d"
10438 >
10439 <desc>
10440 Format of the video memory buffer. Constants represented by this enum can
10441 be used to test for particular values of <link
10442 to="IFramebuffer::pixelFormat"/>. See also <link
10443 to="IFramebuffer::requestResize"/>.
10444
10445 See also www.fourcc.org for more information about FOURCC pixel formats.
10446 </desc>
10447
10448 <const name="Opaque" value="0">
10449 <desc>
10450 Unknown buffer format (the user may not assume any particular format of
10451 the buffer).
10452 </desc>
10453 </const>
10454 <const name="FOURCC_RGB" value="0x32424752">
10455 <desc>
10456 Basic RGB format (<link to="IFramebuffer::bitsPerPixel"/> determines the
10457 bit layout).
10458 </desc>
10459 </const>
10460 </enum>
10461
10462 <interface
10463 name="IFramebuffer" extends="$unknown"
10464 uuid="b7ed347a-5765-40a0-ae1c-f543eb4ddeaf"
10465 wsmap="suppress"
10466 >
10467 <attribute name="address" type="octet" mod="ptr" readonly="yes">
10468 <desc>Address of the start byte of the frame buffer.</desc>
10469 </attribute>
10470
10471 <attribute name="width" type="unsigned long" readonly="yes">
10472 <desc>Frame buffer width, in pixels.</desc>
10473 </attribute>
10474
10475 <attribute name="height" type="unsigned long" readonly="yes">
10476 <desc>Frame buffer height, in pixels.</desc>
10477 </attribute>
10478
10479 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10480 <desc>
10481 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
10482 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, valid values
10483 are: 8, 15, 16, 24 and 32.
10484 </desc>
10485 </attribute>
10486
10487 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
10488 <desc>
10489 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
10490 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, the
10491 size of the scan line must be aligned to 32 bits.
10492 </desc>
10493 </attribute>
10494
10495 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
10496 <desc>
10497 Frame buffer pixel format. It's either one of the values defined by <link
10498 to="FramebufferPixelFormat"/> or a raw FOURCC code.
10499 <note>
10500 This attribute must never return <link
10501 to="FramebufferPixelFormat_Opaque"/> -- the format of the buffer
10502 <link to="#address"/> points to must be always known.
10503 </note>
10504 </desc>
10505 </attribute>
10506
10507 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
10508 <desc>
10509 Defines whether this frame buffer uses the virtual video card's memory
10510 buffer (guest VRAM) directly or not. See <link
10511 to="IFramebuffer::requestResize"/> for more information.
10512 </desc>
10513 </attribute>
10514
10515 <attribute name="heightReduction" type="unsigned long" readonly="yes">
10516 <desc>
10517 Hint from the frame buffer about how much of the standard
10518 screen height it wants to use for itself. This information is
10519 exposed to the guest through the VESA BIOS and VMMDev interface
10520 so that it can use it for determining its video mode table. It
10521 is not guaranteed that the guest respects the value.
10522 </desc>
10523 </attribute>
10524
10525 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
10526 <desc>
10527 An alpha-blended overlay which is superposed over the frame buffer.
10528 The initial purpose is to allow the display of icons providing
10529 information about the VM state, including disk activity, in front
10530 ends which do not have other means of doing that. The overlay is
10531 designed to controlled exclusively by IDisplay. It has no locking
10532 of its own, and any changes made to it are not guaranteed to be
10533 visible until the affected portion of IFramebuffer is updated. The
10534 overlay can be created lazily the first time it is requested. This
10535 attribute can also return @c null to signal that the overlay is not
10536 implemented.
10537 </desc>
10538 </attribute>
10539
10540 <attribute name="winId" type="long long" readonly="yes">
10541 <desc>
10542 Platform-dependent identifier of the window where context of this
10543 frame buffer is drawn, or zero if there's no such window.
10544 </desc>
10545 </attribute>
10546
10547 <method name="lock">
10548 <desc>
10549 Locks the frame buffer.
10550 Gets called by the IDisplay object where this frame buffer is
10551 bound to.
10552 </desc>
10553 </method>
10554
10555 <method name="unlock">
10556 <desc>
10557 Unlocks the frame buffer.
10558 Gets called by the IDisplay object where this frame buffer is
10559 bound to.
10560 </desc>
10561 </method>
10562
10563 <method name="notifyUpdate">
10564 <desc>
10565 Informs about an update.
10566 Gets called by the display object where this buffer is
10567 registered.
10568 </desc>
10569 <param name="x" type="unsigned long" dir="in"/>
10570 <param name="y" type="unsigned long" dir="in"/>
10571 <param name="width" type="unsigned long" dir="in"/>
10572 <param name="height" type="unsigned long" dir="in"/>
10573 </method>
10574
10575 <method name="requestResize">
10576 <desc>
10577 Requests a size and pixel format change.
10578
10579 There are two modes of working with the video buffer of the virtual
10580 machine. The <i>indirect</i> mode implies that the IFramebuffer
10581 implementation allocates a memory buffer for the requested display mode
10582 and provides it to the virtual machine. In <i>direct</i> mode, the
10583 IFramebuffer implementation uses the memory buffer allocated and owned
10584 by the virtual machine. This buffer represents the video memory of the
10585 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
10586 usually faster because the implementation gets a raw pointer to the
10587 guest VRAM buffer which it can directly use for visualizing the contents
10588 of the virtual display, as opposed to the indirect mode where the
10589 contents of guest VRAM are copied to the memory buffer provided by
10590 the implementation every time a display update occurs.
10591
10592 It is important to note that the direct mode is really fast only when
10593 the implementation uses the given guest VRAM buffer directly, for
10594 example, by blitting it to the window representing the virtual machine's
10595 display, which saves at least one copy operation comparing to the
10596 indirect mode. However, using the guest VRAM buffer directly is not
10597 always possible: the format and the color depth of this buffer may be
10598 not supported by the target window, or it may be unknown (opaque) as in
10599 case of text or non-linear multi-plane VGA video modes. In this case,
10600 the indirect mode (that is always available) should be used as a
10601 fallback: when the guest VRAM contents are copied to the
10602 implementation-provided memory buffer, color and format conversion is
10603 done automatically by the underlying code.
10604
10605 The @a pixelFormat parameter defines whether the direct mode is
10606 available or not. If @a pixelFormat is <link
10607 to="FramebufferPixelFormat_Opaque"/> then direct access to the guest
10608 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and
10609 @a bytesPerLine parameters must be ignored and the implementation must use
10610 the indirect mode (where it provides its own buffer in one of the
10611 supported formats). In all other cases, @a pixelFormat together with
10612 @a bitsPerPixel and @a bytesPerLine define the format of the video memory
10613 buffer pointed to by the @a VRAM parameter and the implementation is
10614 free to choose which mode to use. To indicate that this frame buffer uses
10615 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
10616 attribute must return @c true and <link to="#address"/> must
10617 return exactly the same address that is passed in the @a VRAM parameter
10618 of this method; otherwise it is assumed that the indirect strategy is
10619 chosen.
10620
10621 The @a width and @a height parameters represent the size of the
10622 requested display mode in both modes. In case of indirect mode, the
10623 provided memory buffer should be big enough to store data of the given
10624 display mode. In case of direct mode, it is guaranteed that the given
10625 @a VRAM buffer contains enough space to represent the display mode of the
10626 given size. Note that this frame buffer's <link to="#width"/> and <link
10627 to="#height"/> attributes must return exactly the same values as
10628 passed to this method after the resize is completed (see below).
10629
10630 The @a finished output parameter determines if the implementation has
10631 finished resizing the frame buffer or not. If, for some reason, the
10632 resize cannot be finished immediately during this call, @a finished
10633 must be set to @c false, and the implementation must call
10634 <link to="IDisplay::resizeCompleted"/> after it has returned from
10635 this method as soon as possible. If @a finished is @c false, the
10636 machine will not call any frame buffer methods until
10637 <link to="IDisplay::resizeCompleted"/> is called.
10638
10639 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
10640 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
10641 this frame buffer must return exactly the same values as specified in the
10642 parameters of this method, after the resize is completed. If the
10643 indirect mode is chosen, these attributes must return values describing
10644 the format of the implementation's own memory buffer <link
10645 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
10646 value must always correlate with <link to="#pixelFormat"/>. Note that
10647 the <link to="#pixelFormat"/> attribute must never return <link
10648 to="FramebufferPixelFormat_Opaque"/> regardless of the selected mode.
10649
10650 <note>
10651 This method is called by the IDisplay object under the
10652 <link to="#lock"/> provided by this IFramebuffer
10653 implementation. If this method returns @c false in @a finished, then
10654 this lock is not released until
10655 <link to="IDisplay::resizeCompleted"/> is called.
10656 </note>
10657 </desc>
10658 <param name="screenId" type="unsigned long" dir="in">
10659 <desc>
10660 Logical screen number. Must be used in the corresponding call to
10661 <link to="IDisplay::resizeCompleted"/> if this call is made.
10662 </desc>
10663 </param>
10664 <param name="pixelFormat" type="unsigned long" dir="in">
10665 <desc>
10666 Pixel format of the memory buffer pointed to by @a VRAM.
10667 See also <link to="FramebufferPixelFormat"/>.
10668 </desc>
10669 </param>
10670 <param name="VRAM" type="octet" mod="ptr" dir="in">
10671 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
10672 </param>
10673 <param name="bitsPerPixel" type="unsigned long" dir="in">
10674 <desc>Color depth, bits per pixel.</desc>
10675 </param>
10676 <param name="bytesPerLine" type="unsigned long" dir="in">
10677 <desc>Size of one scan line, in bytes.</desc>
10678 </param>
10679 <param name="width" type="unsigned long" dir="in">
10680 <desc>Width of the guest display, in pixels.</desc>
10681 </param>
10682 <param name="height" type="unsigned long" dir="in">
10683 <desc>Height of the guest display, in pixels.</desc>
10684 </param>
10685 <param name="finished" type="boolean" dir="return">
10686 <desc>
10687 Can the VM start using the new frame buffer immediately
10688 after this method returns or it should wait for
10689 <link to="IDisplay::resizeCompleted"/>.
10690 </desc>
10691 </param>
10692 </method>
10693
10694 <method name="videoModeSupported">
10695 <desc>
10696 Returns whether the frame buffer implementation is willing to
10697 support a given video mode. In case it is not able to render
10698 the video mode (or for some reason not willing), it should
10699 return @c false. Usually this method is called when the guest
10700 asks the VMM device whether a given video mode is supported
10701 so the information returned is directly exposed to the guest.
10702 It is important that this method returns very quickly.
10703 </desc>
10704 <param name="width" type="unsigned long" dir="in"/>
10705 <param name="height" type="unsigned long" dir="in"/>
10706 <param name="bpp" type="unsigned long" dir="in"/>
10707 <param name="supported" type="boolean" dir="return"/>
10708 </method>
10709
10710 <method name="getVisibleRegion">
10711 <desc>
10712 Returns the visible region of this frame buffer.
10713
10714 If the @a rectangles parameter is @c null then the value of the
10715 @a count parameter is ignored and the number of elements necessary to
10716 describe the current visible region is returned in @a countCopied.
10717
10718 If @a rectangles is not @c null but @a count is less
10719 than the required number of elements to store region data, the method
10720 will report a failure. If @a count is equal or greater than the
10721 required number of elements, then the actual number of elements copied
10722 to the provided array will be returned in @a countCopied.
10723
10724 <note>
10725 The address of the provided array must be in the process space of
10726 this IFramebuffer object.
10727 </note>
10728 <note>
10729 Method not yet implemented.
10730 </note>
10731 </desc>
10732 <param name="rectangles" type="octet" mod="ptr" dir="in">
10733 <desc>Pointer to the @c RTRECT array to receive region data.</desc>
10734 </param>
10735 <param name="count" type="unsigned long" dir="in">
10736 <desc>Number of @c RTRECT elements in the @a rectangles array.</desc>
10737 </param>
10738 <param name="countCopied" type="unsigned long" dir="return">
10739 <desc>Number of elements copied to the @a rectangles array.</desc>
10740 </param>
10741 </method>
10742
10743 <method name="setVisibleRegion">
10744 <desc>
10745 Suggests a new visible region to this frame buffer. This region
10746 represents the area of the VM display which is a union of regions of
10747 all top-level windows of the guest operating system running inside the
10748 VM (if the Guest Additions for this system support this
10749 functionality). This information may be used by the frontends to
10750 implement the seamless desktop integration feature.
10751
10752 <note>
10753 The address of the provided array must be in the process space of
10754 this IFramebuffer object.
10755 </note>
10756 <note>
10757 The IFramebuffer implementation must make a copy of the provided
10758 array of rectangles.
10759 </note>
10760 <note>
10761 Method not yet implemented.
10762 </note>
10763 </desc>
10764 <param name="rectangles" type="octet" mod="ptr" dir="in">
10765 <desc>Pointer to the @c RTRECT array.</desc>
10766 </param>
10767 <param name="count" type="unsigned long" dir="in">
10768 <desc>Number of @c RTRECT elements in the @a rectangles array.</desc>
10769 </param>
10770 </method>
10771
10772 <method name="processVHWACommand">
10773 <desc>
10774 Posts a Video HW Acceleration Command to the frame buffer for processing.
10775 The commands used for 2D video acceleration (DDraw surface creation/destroying, blitting, scaling, color covnersion, overlaying, etc.)
10776 are posted from quest to the host to be processed by the host hardware.
10777
10778 <note>
10779 The address of the provided command must be in the process space of
10780 this IFramebuffer object.
10781 </note>
10782 </desc>
10783
10784 <param name="command" type="octet" mod="ptr" dir="in">
10785 <desc>Pointer to VBOXVHWACMD containing the command to execute.</desc>
10786 </param>
10787 </method>
10788
10789 </interface>
10790
10791 <interface
10792 name="IFramebufferOverlay" extends="IFramebuffer"
10793 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
10794 wsmap="suppress"
10795 >
10796 <desc>
10797 The IFramebufferOverlay interface represents an alpha blended overlay
10798 for displaying status icons above an IFramebuffer. It is always created
10799 not visible, so that it must be explicitly shown. It only covers a
10800 portion of the IFramebuffer, determined by its width, height and
10801 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
10802 that order) format, and may be written to directly. Do re-read the
10803 width though, after setting it, as it may be adjusted (increased) to
10804 make it more suitable for the front end.
10805 </desc>
10806 <attribute name="x" type="unsigned long" readonly="yes">
10807 <desc>X position of the overlay, relative to the frame buffer.</desc>
10808 </attribute>
10809
10810 <attribute name="y" type="unsigned long" readonly="yes">
10811 <desc>Y position of the overlay, relative to the frame buffer.</desc>
10812 </attribute>
10813
10814 <attribute name="visible" type="boolean" readonly="no">
10815 <desc>
10816 Whether the overlay is currently visible.
10817 </desc>
10818 </attribute>
10819
10820 <attribute name="alpha" type="unsigned long" readonly="no">
10821 <desc>
10822 The global alpha value for the overlay. This may or may not be
10823 supported by a given front end.
10824 </desc>
10825 </attribute>
10826
10827 <method name="move">
10828 <desc>
10829 Changes the overlay's position relative to the IFramebuffer.
10830 </desc>
10831 <param name="x" type="unsigned long" dir="in"/>
10832 <param name="y" type="unsigned long" dir="in"/>
10833 </method>
10834
10835 </interface>
10836
10837 <interface
10838 name="IDisplay" extends="$unknown"
10839 uuid="09EED313-CD56-4D06-BD56-FAC0F716B5DD"
10840 wsmap="managed"
10841 >
10842 <desc>
10843 The IDisplay interface represents the virtual machine's display.
10844
10845 The object implementing this interface is contained in each
10846 <link to="IConsole::display"/> attribute and represents the visual
10847 output of the virtual machine.
10848
10849 The virtual display supports pluggable output targets represented by the
10850 IFramebuffer interface. Examples of the output target are a window on
10851 the host computer or an RDP session's display on a remote computer.
10852 </desc>
10853 <method name="getScreenResolution">
10854 <desc>Queries display width, height and color depth for given screen.</desc>
10855 <param name="screenId" type="unsigned long" dir="in"/>
10856 <param name="width" type="unsigned long" dir="out"/>
10857 <param name="height" type="unsigned long" dir="out"/>
10858 <param name="bitsPerPixel" type="unsigned long" dir="out"/>
10859 </method>
10860
10861 <method name="setFramebuffer">
10862 <desc>
10863 Sets the framebuffer for given screen.
10864 </desc>
10865 <param name="screenId" type="unsigned long" dir="in"/>
10866 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10867 </method>
10868
10869 <method name="getFramebuffer">
10870 <desc>
10871 Queries the framebuffer for given screen.
10872 </desc>
10873 <param name="screenId" type="unsigned long" dir="in"/>
10874 <param name="framebuffer" type="IFramebuffer" dir="out"/>
10875 <param name="xOrigin" type="long" dir="out"/>
10876 <param name="yOrigin" type="long" dir="out"/>
10877 </method>
10878
10879 <method name="setVideoModeHint">
10880 <desc>
10881 Asks VirtualBox to request the given video mode from
10882 the guest. This is just a hint and it cannot be guaranteed
10883 that the requested resolution will be used. Guest Additions
10884 are required for the request to be seen by guests. The caller
10885 should issue the request and wait for a resolution change and
10886 after a timeout retry.
10887
10888 Specifying @c 0 for either @a width, @a height or @a bitsPerPixel
10889 parameters means that the corresponding values should be taken from the
10890 current video mode (i.e. left unchanged).
10891
10892 If the guest OS supports multi-monitor configuration then the @a display
10893 parameter specifies the number of the guest display to send the hint to:
10894 @c 0 is the primary display, @c 1 is the first secondary and
10895 so on. If the multi-monitor configuration is not supported, @a display
10896 must be @c 0.
10897
10898 <result name="E_INVALIDARG">
10899 The @a display is not associated with any monitor.
10900 </result>
10901
10902 </desc>
10903 <param name="width" type="unsigned long" dir="in"/>
10904 <param name="height" type="unsigned long" dir="in"/>
10905 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
10906 <param name="display" type="unsigned long" dir="in"/>
10907 </method>
10908
10909 <method name="setSeamlessMode">
10910 <desc>
10911 Enables or disables seamless guest display rendering (seamless desktop
10912 integration) mode.
10913 <note>
10914 Calling this method has no effect if <link
10915 to="IGuest::supportsSeamless"/> returns @c false.
10916 </note>
10917 </desc>
10918 <param name="enabled" type="boolean" dir="in"/>
10919 </method>
10920
10921 <method name="takeScreenShot">
10922 <desc>
10923 Takes a screen shot of the requested size and copies it to the
10924 32-bpp buffer allocated by the caller and pointed to by @a address.
10925 A pixel consists of 4 bytes in order: B, G, R, 0.
10926
10927 <note>This API can be used only by the COM/XPCOM C++ API as it
10928 requires pointer support. Use <link to="#takeScreenShotToArray" />
10929 with other language bindings.
10930 </note>
10931
10932 <result name="E_NOTIMPL">
10933 Feature not implemented.
10934 </result>
10935 <result name="VBOX_E_IPRT_ERROR">
10936 Could not take a screenshot.
10937 </result>
10938
10939 </desc>
10940 <param name="screenId" type="unsigned long" dir="in"/>
10941 <param name="address" type="octet" mod="ptr" dir="in"/>
10942 <param name="width" type="unsigned long" dir="in"/>
10943 <param name="height" type="unsigned long" dir="in"/>
10944 </method>
10945
10946 <method name="takeScreenShotToArray">
10947 <desc>
10948 Takes a guest screen shot of the requested size and returns it as
10949 an array of bytes in uncompressed 32-bit RGBA format.
10950 A pixel consists of 4 bytes in order: R, G, B, 0xFF.
10951
10952 This API is slow, but could be the only option to get guest screenshot
10953 for scriptable languages not allowed to manipulate with addresses
10954 directly.
10955
10956 <result name="E_NOTIMPL">
10957 Feature not implemented.
10958 </result>
10959 <result name="VBOX_E_IPRT_ERROR">
10960 Could not take a screenshot.
10961 </result>
10962 </desc>
10963 <param name="screenId" type="unsigned long" dir="in">
10964 <desc>
10965 Monitor to take screenshot from.
10966 </desc>
10967 </param>
10968 <param name="width" type="unsigned long" dir="in">
10969 <desc>
10970 Desired image width.
10971 </desc>
10972 </param>
10973 <param name="height" type="unsigned long" dir="in">
10974 <desc>
10975 Desired image height.
10976 </desc>
10977 </param>
10978 <param name="screenData" type="octet" dir="return" safearray="yes">
10979 <desc>
10980 Array with resulting screen data.
10981 </desc>
10982 </param>
10983 </method>
10984
10985 <method name="takeScreenShotPNGToArray">
10986 <desc>
10987 Takes a guest screen shot of the requested size and returns it as
10988 PNG image in array.
10989
10990 <result name="E_NOTIMPL">
10991 Feature not implemented.
10992 </result>
10993 <result name="VBOX_E_IPRT_ERROR">
10994 Could not take a screenshot.
10995 </result>
10996 </desc>
10997 <param name="screenId" type="unsigned long" dir="in">
10998 <desc>
10999 Monitor to take the screenshot from.
11000 </desc>
11001 </param>
11002 <param name="width" type="unsigned long" dir="in">
11003 <desc>
11004 Desired image width.
11005 </desc>
11006 </param>
11007 <param name="height" type="unsigned long" dir="in">
11008 <desc>
11009 Desired image height.
11010 </desc>
11011 </param>
11012 <param name="screenData" type="octet" dir="return" safearray="yes">
11013 <desc>
11014 Array with resulting screen data.
11015 </desc>
11016 </param>
11017 </method>
11018
11019 <method name="drawToScreen">
11020 <desc>
11021 Draws a 32-bpp image of the specified size from the given buffer
11022 to the given point on the VM display.
11023
11024 <result name="E_NOTIMPL">
11025 Feature not implemented.
11026 </result>
11027 <result name="VBOX_E_IPRT_ERROR">
11028 Could not draw to screen.
11029 </result>
11030
11031 </desc>
11032 <param name="screenId" type="unsigned long" dir="in">
11033 <desc>
11034 Monitor to take the screenshot from.
11035 </desc>
11036 </param>
11037 <param name="address" type="octet" mod="ptr" dir="in">
11038 <desc>
11039 Address to store the screenshot to
11040 </desc>
11041 </param>
11042 <param name="x" type="unsigned long" dir="in">
11043 <desc>
11044 Relative to the screen top left corner.
11045 </desc>
11046 </param>
11047 <param name="y" type="unsigned long" dir="in">
11048 <desc>
11049 Relative to the screen top left corner.
11050 </desc>
11051 </param>
11052 <param name="width" type="unsigned long" dir="in">
11053 <desc>
11054 Desired image width.
11055 </desc>
11056 </param>
11057 <param name="height" type="unsigned long" dir="in">
11058 <desc>
11059 Desired image height.
11060 </desc>
11061 </param>
11062 </method>
11063
11064 <method name="invalidateAndUpdate">
11065 <desc>
11066 Does a full invalidation of the VM display and instructs the VM
11067 to update it.
11068
11069 <result name="VBOX_E_IPRT_ERROR">
11070 Could not invalidate and update screen.
11071 </result>
11072
11073 </desc>
11074 </method>
11075
11076 <method name="resizeCompleted">
11077 <desc>
11078 Signals that a framebuffer has completed the resize operation.
11079
11080 <result name="VBOX_E_NOT_SUPPORTED">
11081 Operation only valid for external frame buffers.
11082 </result>
11083
11084 </desc>
11085 <param name="screenId" type="unsigned long" dir="in"/>
11086 </method>
11087
11088 <method name="completeVHWACommand">
11089 <desc>
11090 Signals that the Video HW Acceleration command has completed.
11091 </desc>
11092
11093 <param name="command" type="octet" mod="ptr" dir="in">
11094 <desc>Pointer to VBOXVHWACMD containing the completed command.</desc>
11095 </param>
11096 </method>
11097
11098 </interface>
11099
11100 <!--
11101 // INetworkAdapter
11102 /////////////////////////////////////////////////////////////////////////
11103 -->
11104
11105 <enum
11106 name="NetworkAttachmentType"
11107 uuid="44bce1ee-99f7-4e8e-89fc-80597fd9eeaf"
11108 >
11109 <desc>
11110 Network attachment type.
11111 </desc>
11112
11113 <const name="Null" value="0">
11114 <desc>Null value, also means "not attached".</desc>
11115 </const>
11116 <const name="NAT" value="1"/>
11117 <const name="Bridged" value="2"/>
11118 <const name="Internal" value="3"/>
11119 <const name="HostOnly" value="4"/>
11120 <const name="VDE" value="5"/>
11121 </enum>
11122
11123 <enum
11124 name="NetworkAdapterType"
11125 uuid="3c2281e4-d952-4e87-8c7d-24379cb6a81c"
11126 >
11127 <desc>
11128 Network adapter type.
11129 </desc>
11130
11131 <const name="Null" value="0">
11132 <desc>Null value (never used by the API).</desc>
11133 </const>
11134 <const name="Am79C970A" value="1">
11135 <desc>AMD PCNet-PCI II network card (Am79C970A).</desc>
11136 </const>
11137 <const name="Am79C973" value="2">
11138 <desc>AMD PCNet-FAST III network card (Am79C973).</desc>
11139 </const>
11140 <const name="I82540EM" value="3">
11141 <desc>Intel PRO/1000 MT Desktop network card (82540EM).</desc>
11142 </const>
11143 <const name="I82543GC" value="4">
11144 <desc>Intel PRO/1000 T Server network card (82543GC).</desc>
11145 </const>
11146 <const name="I82545EM" value="5">
11147 <desc>Intel PRO/1000 MT Server network card (82545EM).</desc>
11148 </const>
11149 <const name="Virtio" value="6">
11150 <desc>Virtio network device.</desc>
11151 </const>
11152 </enum>
11153
11154 <interface
11155 name="INetworkAdapter" extends="$unknown"
11156 uuid="9bf58a46-c3f7-4f31-80fa-dde9a5dc0b7b"
11157 wsmap="managed"
11158 >
11159 <desc>
11160 Represents a virtual network adapter that is attached to a virtual machine.
11161 Each virtual machine has a fixed number of network adapter slots with one
11162 instance of this attached to each of them. Call
11163 <link to="IMachine::getNetworkAdapter" /> to get the network adapter that
11164 is attached to a given slot in a given machine.
11165
11166 Each network adapter can be in one of five attachment modes, which are
11167 represented by the <link to="NetworkAttachmentType" /> enumeration;
11168 see the <link to="#attachmentType" /> attribute.
11169 </desc>
11170
11171 <attribute name="adapterType" type="NetworkAdapterType">
11172 <desc>
11173 Type of the virtual network adapter. Depending on this value,
11174 VirtualBox will provide a different virtual network hardware
11175 to the guest.
11176 </desc>
11177 </attribute>
11178
11179 <attribute name="slot" type="unsigned long" readonly="yes">
11180 <desc>
11181 Slot number this adapter is plugged into. Corresponds to
11182 the value you pass to <link to="IMachine::getNetworkAdapter"/>
11183 to obtain this instance.
11184 </desc>
11185 </attribute>
11186
11187 <attribute name="enabled" type="boolean">
11188 <desc>
11189 Flag whether the network adapter is present in the
11190 guest system. If disabled, the virtual guest hardware will
11191 not contain this network adapter. Can only be changed when
11192 the VM is not running.
11193 </desc>
11194 </attribute>
11195
11196 <attribute name="MACAddress" type="wstring">
11197 <desc>
11198 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
11199 it to @c null or an empty string, VirtualBox will generate a unique MAC address.
11200 </desc>
11201 </attribute>
11202
11203 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
11204
11205 <attribute name="hostInterface" type="wstring">
11206 <desc>
11207 Name of the host network interface the VM is attached to.
11208 </desc>
11209 </attribute>
11210
11211 <attribute name="internalNetwork" type="wstring">
11212 <desc>
11213 Name of the internal network the VM is attached to.
11214 </desc>
11215 </attribute>
11216
11217 <attribute name="NATNetwork" type="wstring">
11218 <desc>
11219 Name of the NAT network the VM is attached to.
11220 </desc>
11221 </attribute>
11222
11223 <attribute name="VDENetwork" type="wstring">
11224 <desc>
11225 Name of the VDE switch the VM is attached to.
11226 </desc>
11227 </attribute>
11228
11229 <attribute name="cableConnected" type="boolean">
11230 <desc>
11231 Flag whether the adapter reports the cable as connected or not.
11232 It can be used to report offline situations to a VM.
11233 </desc>
11234 </attribute>
11235
11236 <attribute name="lineSpeed" type="unsigned long">
11237 <desc>
11238 Line speed reported by custom drivers, in units of 1 kbps.
11239 </desc>
11240 </attribute>
11241
11242 <attribute name="traceEnabled" type="boolean">
11243 <desc>
11244 Flag whether network traffic from/to the network card should be traced.
11245 Can only be toggled when the VM is turned off.
11246 </desc>
11247 </attribute>
11248
11249 <attribute name="traceFile" type="wstring">
11250 <desc>
11251 Filename where a network trace will be stored. If not set, VBox-pid.pcap
11252 will be used.
11253 </desc>
11254 </attribute>
11255
11256 <attribute name="natDriver" type="INATEngine" readonly="yes">
11257 <desc>
11258 Points to the NAT engine which handles the network address translation
11259 for this interface. This is active only when the interface actually uses
11260 NAT (see <link to="#attachToNAT" />).
11261 </desc>
11262 </attribute>
11263
11264 <attribute name="bootPriority" type="unsigned long">
11265 <desc>
11266 Network boot priority of the adapter. Priority 1 is highest. If not set,
11267 the priority is considered to be at the lowest possible setting.
11268 </desc>
11269 </attribute>
11270
11271 <attribute name="bandwidthLimit" type="unsigned long">
11272 <desc>
11273 Maximum throughput allowed for this network adapter, in units of 1 mbps.
11274 A zero value means uncapped/unlimited.
11275 </desc>
11276 </attribute>
11277
11278 <method name="attachToNAT">
11279 <desc>
11280 Attach the network adapter to the Network Address Translation (NAT) interface.
11281 </desc>
11282 </method>
11283
11284 <method name="attachToBridgedInterface">
11285 <desc>
11286 Attach the network adapter to a bridged host interface.
11287 </desc>
11288 </method>
11289
11290 <method name="attachToInternalNetwork">
11291 <desc>
11292 Attach the network adapter to an internal network.
11293 </desc>
11294 </method>
11295
11296 <method name="attachToHostOnlyInterface">
11297 <desc>
11298 Attach the network adapter to the host-only network.
11299 </desc>
11300 </method>
11301
11302 <method name="attachToVDE">
11303 <desc>
11304 Attach the network adapter to a VDE network.
11305 </desc>
11306 </method>
11307
11308 <method name="detach">
11309 <desc>
11310 Detach the network adapter
11311 </desc>
11312 </method>
11313 </interface>
11314
11315
11316 <!--
11317 // ISerialPort
11318 /////////////////////////////////////////////////////////////////////////
11319 -->
11320
11321 <enum
11322 name="PortMode"
11323 uuid="533b5fe3-0185-4197-86a7-17e37dd39d76"
11324 >
11325 <desc>
11326 The PortMode enumeration represents possible communication modes for
11327 the virtual serial port device.
11328 </desc>
11329
11330 <const name="Disconnected" value="0">
11331 <desc>Virtual device is not attached to any real host device.</desc>
11332 </const>
11333 <const name="HostPipe" value="1">
11334 <desc>Virtual device is attached to a host pipe.</desc>
11335 </const>
11336 <const name="HostDevice" value="2">
11337 <desc>Virtual device is attached to a host device.</desc>
11338 </const>
11339 <const name="RawFile" value="3">
11340 <desc>Virtual device is attached to a raw file.</desc>
11341 </const>
11342 </enum>
11343
11344 <interface
11345 name="ISerialPort" extends="$unknown"
11346 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
11347 wsmap="managed"
11348 >
11349
11350 <desc>
11351 The ISerialPort interface represents the virtual serial port device.
11352
11353 The virtual serial port device acts like an ordinary serial port
11354 inside the virtual machine. This device communicates to the real
11355 serial port hardware in one of two modes: host pipe or host device.
11356
11357 In host pipe mode, the #path attribute specifies the path to the pipe on
11358 the host computer that represents a serial port. The #server attribute
11359 determines if this pipe is created by the virtual machine process at
11360 machine startup or it must already exist before starting machine
11361 execution.
11362
11363 In host device mode, the #path attribute specifies the name of the
11364 serial port device on the host computer.
11365
11366 There is also a third communication mode: the disconnected mode. In this
11367 mode, the guest OS running inside the virtual machine will be able to
11368 detect the serial port, but all port write operations will be discarded
11369 and all port read operations will return no data.
11370
11371 <see>IMachine::getSerialPort</see>
11372 </desc>
11373
11374 <attribute name="slot" type="unsigned long" readonly="yes">
11375 <desc>
11376 Slot number this serial port is plugged into. Corresponds to
11377 the value you pass to <link to="IMachine::getSerialPort"/>
11378 to obtain this instance.
11379 </desc>
11380 </attribute>
11381
11382 <attribute name="enabled" type="boolean">
11383 <desc>
11384 Flag whether the serial port is enabled. If disabled,
11385 the serial port will not be reported to the guest OS.
11386 </desc>
11387 </attribute>
11388
11389 <attribute name="IOBase" type="unsigned long">
11390 <desc>Base I/O address of the serial port.</desc>
11391 </attribute>
11392
11393 <attribute name="IRQ" type="unsigned long">
11394 <desc>IRQ number of the serial port.</desc>
11395 </attribute>
11396
11397 <attribute name="hostMode" type="PortMode">
11398 <desc>
11399 How is this port connected to the host.
11400 <note>
11401 Changing this attribute may fail if the conditions for
11402 <link to="#path"/> are not met.
11403 </note>
11404 </desc>
11405 </attribute>
11406
11407 <attribute name="server" type="boolean">
11408 <desc>
11409 Flag whether this serial port acts as a server (creates a new pipe on
11410 the host) or as a client (uses the existing pipe). This attribute is
11411 used only when <link to="#hostMode"/> is PortMode_HostPipe.
11412 </desc>
11413 </attribute>
11414
11415 <attribute name="path" type="wstring">
11416 <desc>
11417 Path to the serial port's pipe on the host when <link to="ISerialPort::hostMode"/> is
11418 PortMode_HostPipe, or the host serial device name when
11419 <link to="ISerialPort::hostMode"/> is PortMode_HostDevice. For both
11420 cases, setting a @c null or empty string as the attribute's value
11421 is an error. Otherwise, the value of this property is ignored.
11422 </desc>
11423 </attribute>
11424
11425 </interface>
11426
11427 <!--
11428 // IParallelPort
11429 /////////////////////////////////////////////////////////////////////////
11430 -->
11431
11432 <interface
11433 name="IParallelPort" extends="$unknown"
11434 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
11435 wsmap="managed"
11436 >
11437
11438 <desc>
11439 The IParallelPort interface represents the virtual parallel port device.
11440
11441 The virtual parallel port device acts like an ordinary parallel port
11442 inside the virtual machine. This device communicates to the real
11443 parallel port hardware using the name of the parallel device on the host
11444 computer specified in the #path attribute.
11445
11446 Each virtual parallel port device is assigned a base I/O address and an
11447 IRQ number that will be reported to the guest operating system and used
11448 to operate the given parallel port from within the virtual machine.
11449
11450 <see>IMachine::getParallelPort</see>
11451 </desc>
11452
11453 <attribute name="slot" type="unsigned long" readonly="yes">
11454 <desc>
11455 Slot number this parallel port is plugged into. Corresponds to
11456 the value you pass to <link to="IMachine::getParallelPort"/>
11457 to obtain this instance.
11458 </desc>
11459 </attribute>
11460
11461 <attribute name="enabled" type="boolean">
11462 <desc>
11463 Flag whether the parallel port is enabled. If disabled,
11464 the parallel port will not be reported to the guest OS.
11465 </desc>
11466 </attribute>
11467
11468 <attribute name="IOBase" type="unsigned long">
11469 <desc>Base I/O address of the parallel port.</desc>
11470 </attribute>
11471
11472 <attribute name="IRQ" type="unsigned long">
11473 <desc>IRQ number of the parallel port.</desc>
11474 </attribute>
11475
11476 <attribute name="path" type="wstring">
11477 <desc>
11478 Host parallel device name. If this parallel port is enabled, setting a
11479 @c null or an empty string as this attribute's value will result into
11480 an error.
11481 </desc>
11482 </attribute>
11483
11484 </interface>
11485
11486
11487 <!--
11488 // IMachineDebugger
11489 /////////////////////////////////////////////////////////////////////////
11490 -->
11491
11492 <interface
11493 name="IMachineDebugger" extends="$unknown"
11494 uuid="b0b2a2dd-0627-4502-91c2-ddc5e77609e0"
11495 wsmap="suppress"
11496 >
11497 <method name="resetStats">
11498 <desc>
11499 Reset VM statistics.
11500 </desc>
11501 <param name="pattern" type="wstring" dir="in">
11502 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11503 </param>
11504 </method>
11505
11506 <method name="dumpStats">
11507 <desc>
11508 Dumps VM statistics.
11509 </desc>
11510 <param name="pattern" type="wstring" dir="in">
11511 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11512 </param>
11513 </method>
11514
11515 <method name="getStats">
11516 <desc>
11517 Get the VM statistics in a XMLish format.
11518 </desc>
11519 <param name="pattern" type="wstring" dir="in">
11520 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11521 </param>
11522 <param name="withDescriptions" type="boolean" dir="in">
11523 <desc>Whether to include the descriptions.</desc>
11524 </param>
11525 <param name="stats" type="wstring" dir="out">
11526 <desc>The XML document containing the statistics.</desc>
11527 </param>
11528 </method>
11529
11530 <method name="injectNMI">
11531 <desc>
11532 Inject an NMI into a running VT-x/AMD-V VM.
11533 </desc>
11534 </method>
11535
11536 <attribute name="singlestep" type="boolean">
11537 <desc>Switch for enabling singlestepping.</desc>
11538 </attribute>
11539
11540 <attribute name="recompileUser" type="boolean">
11541 <desc>Switch for forcing code recompilation for user mode code.</desc>
11542 </attribute>
11543
11544 <attribute name="recompileSupervisor" type="boolean">
11545 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
11546 </attribute>
11547
11548 <attribute name="PATMEnabled" type="boolean">
11549 <desc>Switch for enabling and disabling the PATM component.</desc>
11550 </attribute>
11551
11552 <attribute name="CSAMEnabled" type="boolean">
11553 <desc>Switch for enabling and disabling the CSAM component.</desc>
11554 </attribute>
11555
11556 <attribute name="logEnabled" type="boolean">
11557 <desc>Switch for enabling and disabling logging.</desc>
11558 </attribute>
11559
11560 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
11561 <desc>
11562 Flag indicating whether the VM is currently making use of CPU hardware
11563 virtualization extensions.
11564 </desc>
11565 </attribute>
11566
11567 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" readonly="yes">
11568 <desc>
11569 Flag indicating whether the VM is currently making use of the nested paging
11570 CPU hardware virtualization extension.
11571 </desc>
11572 </attribute>
11573
11574 <attribute name="HWVirtExVPIDEnabled" type="boolean" readonly="yes">
11575 <desc>
11576 Flag indicating whether the VM is currently making use of the VPID
11577 VT-x extension.
11578 </desc>
11579 </attribute>
11580
11581 <attribute name="PAEEnabled" type="boolean" readonly="yes">
11582 <desc>
11583 Flag indicating whether the VM is currently making use of the Physical
11584 Address Extension CPU feature.
11585 </desc>
11586 </attribute>
11587
11588 <attribute name="virtualTimeRate" type="unsigned long">
11589 <desc>
11590 The rate at which the virtual time runs expressed as a percentage.
11591 The accepted range is 2% to 20000%.
11592 </desc>
11593 </attribute>
11594
11595 <!-- @todo method for setting log flags, groups and destination! -->
11596
11597 <attribute name="VM" type="long long" readonly="yes">
11598 <desc>
11599 Gets the VM handle. This is only for internal use while
11600 we carve the details of this interface.
11601 </desc>
11602 </attribute>
11603
11604 </interface>
11605
11606 <!--
11607 // IUSBController
11608 /////////////////////////////////////////////////////////////////////////
11609 -->
11610
11611 <interface
11612 name="IUSBController" extends="$unknown"
11613 uuid="6fdcccc5-abd3-4fec-9387-2ad3914fc4a8"
11614 wsmap="managed"
11615 >
11616 <attribute name="enabled" type="boolean">
11617 <desc>
11618 Flag whether the USB controller is present in the
11619 guest system. If disabled, the virtual guest hardware will
11620 not contain any USB controller. Can only be changed when
11621 the VM is powered off.
11622 </desc>
11623 </attribute>
11624
11625 <attribute name="enabledEhci" type="boolean">
11626 <desc>
11627 Flag whether the USB EHCI controller is present in the
11628 guest system. If disabled, the virtual guest hardware will
11629 not contain a USB EHCI controller. Can only be changed when
11630 the VM is powered off.
11631 </desc>
11632 </attribute>
11633
11634 <attribute name="proxyAvailable" type="boolean" readonly="yes">
11635 <desc>
11636 Flag whether there is an USB proxy available.
11637 </desc>
11638 </attribute>
11639
11640 <attribute name="USBStandard" type="unsigned short" readonly="yes">
11641 <desc>
11642 USB standard version which the controller implements.
11643 This is a BCD which means that the major version is in the
11644 high byte and minor version is in the low byte.
11645 </desc>
11646 </attribute>
11647
11648 <attribute name="deviceFilters" type="IUSBDeviceFilter" readonly="yes" safearray="yes">
11649 <desc>
11650 List of USB device filters associated with the machine.
11651
11652 If the machine is currently running, these filters are activated
11653 every time a new (supported) USB device is attached to the host
11654 computer that was not ignored by global filters
11655 (<link to="IHost::USBDeviceFilters"/>).
11656
11657 These filters are also activated when the machine is powered up.
11658 They are run against a list of all currently available USB
11659 devices (in states
11660 <link to="USBDeviceState_Available"/>,
11661 <link to="USBDeviceState_Busy"/>,
11662 <link to="USBDeviceState_Held"/>) that were not previously
11663 ignored by global filters.
11664
11665 If at least one filter matches the USB device in question, this
11666 device is automatically captured (attached to) the virtual USB
11667 controller of this machine.
11668
11669 <see>IUSBDeviceFilter, ::IUSBController</see>
11670 </desc>
11671 </attribute>
11672
11673 <method name="createDeviceFilter">
11674 <desc>
11675 Creates a new USB device filter. All attributes except
11676 the filter name are set to empty (any match),
11677 <i>active</i> is @c false (the filter is not active).
11678
11679 The created filter can then be added to the list of filters using
11680 <link to="#insertDeviceFilter"/>.
11681
11682 <result name="VBOX_E_INVALID_VM_STATE">
11683 The virtual machine is not mutable.
11684 </result>
11685
11686 <see>#deviceFilters</see>
11687 </desc>
11688 <param name="name" type="wstring" dir="in">
11689 <desc>
11690 Filter name. See <link to="IUSBDeviceFilter::name"/>
11691 for more info.
11692 </desc>
11693 </param>
11694 <param name="filter" type="IUSBDeviceFilter" dir="return">
11695 <desc>Created filter object.</desc>
11696 </param>
11697 </method>
11698
11699 <method name="insertDeviceFilter">
11700 <desc>
11701 Inserts the given USB device to the specified position
11702 in the list of filters.
11703
11704 Positions are numbered starting from <tt>0</tt>. If the specified
11705 position is equal to or greater than the number of elements in
11706 the list, the filter is added to the end of the collection.
11707
11708 <note>
11709 Duplicates are not allowed, so an attempt to insert a
11710 filter that is already in the collection, will return an
11711 error.
11712 </note>
11713
11714 <result name="VBOX_E_INVALID_VM_STATE">
11715 Virtual machine is not mutable.
11716 </result>
11717 <result name="E_INVALIDARG">
11718 USB device filter not created within this VirtualBox instance.
11719 </result>
11720 <result name="VBOX_E_INVALID_OBJECT_STATE">
11721 USB device filter already in list.
11722 </result>
11723
11724 <see>#deviceFilters</see>
11725 </desc>
11726 <param name="position" type="unsigned long" dir="in">
11727 <desc>Position to insert the filter to.</desc>
11728 </param>
11729 <param name="filter" type="IUSBDeviceFilter" dir="in">
11730 <desc>USB device filter to insert.</desc>
11731 </param>
11732 </method>
11733
11734 <method name="removeDeviceFilter">
11735 <desc>
11736 Removes a USB device filter from the specified position in the
11737 list of filters.
11738
11739 Positions are numbered starting from <tt>0</tt>. Specifying a
11740 position equal to or greater than the number of elements in
11741 the list will produce an error.
11742
11743 <see>#deviceFilters</see>
11744
11745 <result name="VBOX_E_INVALID_VM_STATE">
11746 Virtual machine is not mutable.
11747 </result>
11748 <result name="E_INVALIDARG">
11749 USB device filter list empty or invalid @a position.
11750 </result>
11751
11752 </desc>
11753 <param name="position" type="unsigned long" dir="in">
11754 <desc>Position to remove the filter from.</desc>
11755 </param>
11756 <param name="filter" type="IUSBDeviceFilter" dir="return">
11757 <desc>Removed USB device filter.</desc>
11758 </param>
11759 </method>
11760
11761 </interface>
11762
11763
11764 <!--
11765 // IUSBDevice
11766 /////////////////////////////////////////////////////////////////////////
11767 -->
11768
11769 <interface
11770 name="IUSBDevice" extends="$unknown"
11771 uuid="f8967b0b-4483-400f-92b5-8b675d98a85b"
11772 wsmap="managed"
11773 >
11774 <desc>
11775 The IUSBDevice interface represents a virtual USB device attached to the
11776 virtual machine.
11777
11778 A collection of objects implementing this interface is stored in the
11779 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
11780 attached to a running virtual machine's USB controller.
11781 </desc>
11782
11783 <attribute name="id" type="uuid" mod="string" readonly="yes">
11784 <desc>
11785 Unique USB device ID. This ID is built from #vendorId,
11786 #productId, #revision and #serialNumber.
11787 </desc>
11788 </attribute>
11789
11790 <attribute name="vendorId" type="unsigned short" readonly="yes">
11791 <desc>Vendor ID.</desc>
11792 </attribute>
11793
11794 <attribute name="productId" type="unsigned short" readonly="yes">
11795 <desc>Product ID.</desc>
11796 </attribute>
11797
11798 <attribute name="revision" type="unsigned short" readonly="yes">
11799 <desc>
11800 Product revision number. This is a packed BCD represented as
11801 unsigned short. The high byte is the integer part and the low
11802 byte is the decimal.
11803 </desc>
11804 </attribute>
11805
11806 <attribute name="manufacturer" type="wstring" readonly="yes">
11807 <desc>Manufacturer string.</desc>
11808 </attribute>
11809
11810 <attribute name="product" type="wstring" readonly="yes">
11811 <desc>Product string.</desc>
11812 </attribute>
11813
11814 <attribute name="serialNumber" type="wstring" readonly="yes">
11815 <desc>Serial number string.</desc>
11816 </attribute>
11817
11818 <attribute name="address" type="wstring" readonly="yes">
11819 <desc>Host specific address of the device.</desc>
11820 </attribute>
11821
11822 <attribute name="port" type="unsigned short" readonly="yes">
11823 <desc>
11824 Host USB port number the device is physically
11825 connected to.
11826 </desc>
11827 </attribute>
11828
11829 <attribute name="version" type="unsigned short" readonly="yes">
11830 <desc>
11831 The major USB version of the device - 1 or 2.
11832 </desc>
11833 </attribute>
11834
11835 <attribute name="portVersion" type="unsigned short" readonly="yes">
11836 <desc>
11837 The major USB version of the host USB port the device is
11838 physically connected to - 1 or 2. For devices not connected to
11839 anything this will have the same value as the version attribute.
11840 </desc>
11841 </attribute>
11842
11843 <attribute name="remote" type="boolean" readonly="yes">
11844 <desc>
11845 Whether the device is physically connected to a remote VRDP
11846 client or to a local host machine.
11847 </desc>
11848 </attribute>
11849
11850 </interface>
11851
11852
11853 <!--
11854 // IUSBDeviceFilter
11855 /////////////////////////////////////////////////////////////////////////
11856 -->
11857
11858 <interface
11859 name="IUSBDeviceFilter" extends="$unknown"
11860 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
11861 wsmap="managed"
11862 >
11863 <desc>
11864 The IUSBDeviceFilter interface represents an USB device filter used
11865 to perform actions on a group of USB devices.
11866
11867 This type of filters is used by running virtual machines to
11868 automatically capture selected USB devices once they are physically
11869 attached to the host computer.
11870
11871 A USB device is matched to the given device filter if and only if all
11872 attributes of the device match the corresponding attributes of the
11873 filter (that is, attributes are joined together using the logical AND
11874 operation). On the other hand, all together, filters in the list of
11875 filters carry the semantics of the logical OR operation. So if it is
11876 desirable to create a match like "this vendor id OR this product id",
11877 one needs to create two filters and specify "any match" (see below)
11878 for unused attributes.
11879
11880 All filter attributes used for matching are strings. Each string
11881 is an expression representing a set of values of the corresponding
11882 device attribute, that will match the given filter. Currently, the
11883 following filtering expressions are supported:
11884
11885 <ul>
11886 <li><i>Interval filters</i>. Used to specify valid intervals for
11887 integer device attributes (Vendor ID, Product ID and Revision).
11888 The format of the string is:
11889
11890 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
11891
11892 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
11893 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
11894 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
11895 is omitted before a dash (<tt>-</tt>), the minimum possible integer
11896 is assumed; if <tt>n</tt> is omitted after a dash, the maximum
11897 possible integer is assumed.
11898 </li>
11899 <li><i>Boolean filters</i>. Used to specify acceptable values for
11900 boolean device attributes. The format of the string is:
11901
11902 <tt>true|false|yes|no|0|1</tt>
11903
11904 </li>
11905 <li><i>Exact match</i>. Used to specify a single value for the given
11906 device attribute. Any string that doesn't start with <tt>int:</tt>
11907 represents the exact match. String device attributes are compared to
11908 this string including case of symbols. Integer attributes are first
11909 converted to a string (see individual filter attributes) and then
11910 compared ignoring case.
11911
11912 </li>
11913 <li><i>Any match</i>. Any value of the corresponding device attribute
11914 will match the given filter. An empty or @c null string is
11915 used to construct this type of filtering expressions.
11916
11917 </li>
11918 </ul>
11919
11920 <note>
11921 On the Windows host platform, interval filters are not currently
11922 available. Also all string filter attributes
11923 (<link to="#manufacturer"/>, <link to="#product"/>,
11924 <link to="#serialNumber"/>) are ignored, so they behave as
11925 <i>any match</i> no matter what string expression is specified.
11926 </note>
11927
11928 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
11929 </desc>
11930
11931 <attribute name="name" type="wstring">
11932 <desc>
11933 Visible name for this filter.
11934 This name is used to visually distinguish one filter from another,
11935 so it can neither be @c null nor an empty string.
11936 </desc>
11937 </attribute>
11938
11939 <attribute name="active" type="boolean">
11940 <desc>Whether this filter active or has been temporarily disabled.</desc>
11941 </attribute>
11942
11943 <attribute name="vendorId" type="wstring">
11944 <desc>
11945 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
11946 The string representation for the <i>exact matching</i>
11947 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11948 (including leading zeroes).
11949 </desc>
11950 </attribute>
11951
11952 <attribute name="productId" type="wstring">
11953 <desc>
11954 <link to="IUSBDevice::productId">Product ID</link> filter.
11955 The string representation for the <i>exact matching</i>
11956 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11957 (including leading zeroes).
11958 </desc>
11959 </attribute>
11960
11961 <attribute name="revision" type="wstring">
11962 <desc>
11963 <link to="IUSBDevice::productId">Product revision number</link>
11964 filter. The string representation for the <i>exact matching</i>
11965 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
11966 of the integer part of the revision, and <tt>F</tt> is the
11967 decimal digit of its fractional part (including leading and
11968 trailing zeros).
11969 Note that for interval filters, it's best to use the hexadecimal
11970 form, because the revision is stored as a 16 bit packed BCD value;
11971 so the expression <tt>int:0x0100-0x0199</tt> will match any
11972 revision from <tt>1.0</tt> to <tt>1.99</tt>.
11973 </desc>
11974 </attribute>
11975
11976 <attribute name="manufacturer" type="wstring">
11977 <desc>
11978 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
11979 </desc>
11980 </attribute>
11981
11982 <attribute name="product" type="wstring">
11983 <desc>
11984 <link to="IUSBDevice::product">Product</link> filter.
11985 </desc>
11986 </attribute>
11987
11988 <attribute name="serialNumber" type="wstring">
11989 <desc>
11990 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
11991 </desc>
11992 </attribute>
11993
11994 <attribute name="port" type="wstring">
11995 <desc>
11996 <link to="IUSBDevice::port">Host USB port</link> filter.
11997 </desc>
11998 </attribute>
11999
12000 <attribute name="remote" type="wstring">
12001 <desc>
12002 <link to="IUSBDevice::remote">Remote state</link> filter.
12003 <note>
12004 This filter makes sense only for machine USB filters,
12005 i.e. it is ignored by IHostUSBDeviceFilter objects.
12006 </note>
12007 </desc>
12008 </attribute>
12009
12010 <attribute name="maskedInterfaces" type="unsigned long">
12011 <desc>
12012 This is an advanced option for hiding one or more USB interfaces
12013 from the guest. The value is a bit mask where the bits that are set
12014 means the corresponding USB interface should be hidden, masked off
12015 if you like.
12016 This feature only works on Linux hosts.
12017 </desc>
12018 </attribute>
12019
12020 </interface>
12021
12022
12023 <!--
12024 // IHostUSBDevice
12025 /////////////////////////////////////////////////////////////////////////
12026 -->
12027
12028 <enum
12029 name="USBDeviceState"
12030 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
12031 >
12032 <desc>
12033 USB device state. This enumeration represents all possible states
12034 of the USB device physically attached to the host computer regarding
12035 its state on the host computer and availability to guest computers
12036 (all currently running virtual machines).
12037
12038 Once a supported USB device is attached to the host, global USB
12039 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
12040 either ignore the device, or put it to USBDeviceState_Held state, or do
12041 nothing. Unless the device is ignored by global filters, filters of all
12042 currently running guests (<link to="IUSBController::deviceFilters"/>) are
12043 activated that can put it to USBDeviceState_Captured state.
12044
12045 If the device was ignored by global filters, or didn't match
12046 any filters at all (including guest ones), it is handled by the host
12047 in a normal way. In this case, the device state is determined by
12048 the host and can be one of USBDeviceState_Unavailable, USBDeviceState_Busy
12049 or USBDeviceState_Available, depending on the current device usage.
12050
12051 Besides auto-capturing based on filters, the device can be manually
12052 captured by guests (<link to="IConsole::attachUSBDevice"/>) if its
12053 state is USBDeviceState_Busy, USBDeviceState_Available or
12054 USBDeviceState_Held.
12055
12056 <note>
12057 Due to differences in USB stack implementations in Linux and Win32,
12058 states USBDeviceState_Busy and USBDeviceState_vailable are applicable
12059 only to the Linux version of the product. This also means that (<link
12060 to="IConsole::attachUSBDevice"/>) can only succeed on Win32 if the
12061 device state is USBDeviceState_Held.
12062 </note>
12063
12064 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
12065 </desc>
12066
12067 <const name="NotSupported" value="0">
12068 <desc>
12069 Not supported by the VirtualBox server, not available to guests.
12070 </desc>
12071 </const>
12072 <const name="Unavailable" value="1">
12073 <desc>
12074 Being used by the host computer exclusively,
12075 not available to guests.
12076 </desc>
12077 </const>
12078 <const name="Busy" value="2">
12079 <desc>
12080 Being used by the host computer, potentially available to guests.
12081 </desc>
12082 </const>
12083 <const name="Available" value="3">
12084 <desc>
12085 Not used by the host computer, available to guests (the host computer
12086 can also start using the device at any time).
12087 </desc>
12088 </const>
12089 <const name="Held" value="4">
12090 <desc>
12091 Held by the VirtualBox server (ignored by the host computer),
12092 available to guests.
12093 </desc>
12094 </const>
12095 <const name="Captured" value="5">
12096 <desc>
12097 Captured by one of the guest computers, not available
12098 to anybody else.
12099 </desc>
12100 </const>
12101 </enum>
12102
12103 <interface
12104 name="IHostUSBDevice" extends="IUSBDevice"
12105 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
12106 wsmap="managed"
12107 >
12108 <desc>
12109 The IHostUSBDevice interface represents a physical USB device attached
12110 to the host computer.
12111
12112 Besides properties inherited from IUSBDevice, this interface adds the
12113 <link to="#state"/> property that holds the current state of the USB
12114 device.
12115
12116 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
12117 </desc>
12118
12119 <attribute name="state" type="USBDeviceState" readonly="yes">
12120 <desc>
12121 Current state of the device.
12122 </desc>
12123 </attribute>
12124
12125 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
12126
12127 </interface>
12128
12129
12130 <!--
12131 // IHostUSBDeviceFilter
12132 /////////////////////////////////////////////////////////////////////////
12133 -->
12134
12135 <enum
12136 name="USBDeviceFilterAction"
12137 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
12138 >
12139 <desc>
12140 Actions for host USB device filters.
12141 <see>IHostUSBDeviceFilter, USBDeviceState</see>
12142 </desc>
12143
12144 <const name="Null" value="0">
12145 <desc>Null value (never used by the API).</desc>
12146 </const>
12147 <const name="Ignore" value="1">
12148 <desc>Ignore the matched USB device.</desc>
12149 </const>
12150 <const name="Hold" value="2">
12151 <desc>Hold the matched USB device.</desc>
12152 </const>
12153 </enum>
12154
12155 <interface
12156 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
12157 uuid="4cc70246-d74a-400f-8222-3900489c0374"
12158 wsmap="managed"
12159 >
12160 <desc>
12161 The IHostUSBDeviceFilter interface represents a global filter for a
12162 physical USB device used by the host computer. Used indirectly in
12163 <link to="IHost::USBDeviceFilters"/>.
12164
12165 Using filters of this type, the host computer determines the initial
12166 state of the USB device after it is physically attached to the
12167 host's USB controller.
12168
12169 <note>
12170 The <link to="IUSBDeviceFilter::remote"/> attribute is ignored by this type of
12171 filters, because it makes sense only for
12172 <link to="IUSBController::deviceFilters">machine USB filters</link>.
12173 </note>
12174
12175 <see>IHost::USBDeviceFilters</see>
12176 </desc>
12177
12178 <attribute name="action" type="USBDeviceFilterAction">
12179 <desc>
12180 Action performed by the host when an attached USB device
12181 matches this filter.
12182 </desc>
12183 </attribute>
12184
12185 </interface>
12186
12187 <!--
12188 // IAudioAdapter
12189 /////////////////////////////////////////////////////////////////////////
12190 -->
12191
12192 <enum
12193 name="AudioDriverType"
12194 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
12195 >
12196 <desc>
12197 Host audio driver type.
12198 </desc>
12199
12200 <const name="Null" value="0">
12201 <desc>Null value, also means "dummy audio driver".</desc>
12202 </const>
12203 <const name="WinMM" value="1">
12204 <desc>Windows multimedia (Windows hosts only).</desc>
12205 </const>
12206 <const name="OSS" value="2">
12207 <desc>Open Sound System (Linux hosts only).</desc>
12208 </const>
12209 <const name="ALSA" value="3">
12210 <desc>Advanced Linux Sound Architecture (Linux hosts only).</desc>
12211 </const>
12212 <const name="DirectSound" value="4">
12213 <desc>DirectSound (Windows hosts only).</desc>
12214 </const>
12215 <const name="CoreAudio" value="5">
12216 <desc>CoreAudio (Mac hosts only).</desc>
12217 </const>
12218 <const name="MMPM" value="6">
12219 <desc>Reserved for historical reasons.</desc>
12220 </const>
12221 <const name="Pulse" value="7">
12222 <desc>PulseAudio (Linux hosts only).</desc>
12223 </const>
12224 <const name="SolAudio" value="8">
12225 <desc>Solaris audio (Solaris hosts only).</desc>
12226 </const>
12227 </enum>
12228
12229 <enum
12230 name="AudioControllerType"
12231 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
12232 >
12233 <desc>
12234 Virtual audio controller type.
12235 </desc>
12236
12237 <const name="AC97" value="0"/>
12238 <const name="SB16" value="1"/>
12239 <const name="HDA" value="2"/>
12240 </enum>
12241
12242 <interface
12243 name="IAudioAdapter" extends="$unknown"
12244 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
12245 wsmap="managed"
12246 >
12247 <desc>
12248 The IAudioAdapter interface represents the virtual audio adapter of
12249 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
12250 </desc>
12251 <attribute name="enabled" type="boolean">
12252 <desc>
12253 Flag whether the audio adapter is present in the
12254 guest system. If disabled, the virtual guest hardware will
12255 not contain any audio adapter. Can only be changed when
12256 the VM is not running.
12257 </desc>
12258 </attribute>
12259 <attribute name="audioController" type="AudioControllerType">
12260 <desc>
12261 The audio hardware we emulate.
12262 </desc>
12263 </attribute>
12264 <attribute name="audioDriver" type="AudioDriverType">
12265 <desc>
12266 Audio driver the adapter is connected to. This setting
12267 can only be changed when the VM is not running.
12268 </desc>
12269 </attribute>
12270 </interface>
12271
12272 <!--
12273 // IVRDPServer
12274 /////////////////////////////////////////////////////////////////////////
12275 -->
12276
12277 <enum
12278 name="VRDPAuthType"
12279 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
12280 >
12281 <desc>
12282 VRDP authentication type.
12283 </desc>
12284
12285 <const name="Null" value="0">
12286 <desc>Null value, also means "no authentication".</desc>
12287 </const>
12288 <const name="External" value="1"/>
12289 <const name="Guest" value="2"/>
12290 </enum>
12291
12292 <interface
12293 name="IVRDPServer" extends="$unknown"
12294 uuid="7aeeb530-0b08-41fe-835d-9be9ec1dbe5c"
12295 wsmap="managed"
12296 >
12297 <attribute name="enabled" type="boolean">
12298 <desc>VRDP server status.</desc>
12299 </attribute>
12300
12301 <attribute name="ports" type="wstring">
12302 <desc>
12303 VRDP server port numbers. The server will try to bind to one of free ports from the list.
12304 <note>
12305 This is a string of comma separated TCP port numbers or port number ranges.
12306 Example <tt>5000,5010-5012,5015</tt>
12307 </note>
12308 </desc>
12309 </attribute>
12310
12311 <attribute name="netAddress" type="wstring">
12312 <desc>VRDP server address.</desc>
12313 </attribute>
12314
12315 <attribute name="authType" type="VRDPAuthType">
12316 <desc>VRDP authentication method.</desc>
12317 </attribute>
12318
12319 <attribute name="authTimeout" type="unsigned long">
12320 <desc>Timeout for guest authentication. Milliseconds.</desc>
12321 </attribute>
12322
12323 <attribute name="allowMultiConnection" type="boolean">
12324 <desc>
12325 Flag whether multiple simultaneous connections to the VM are permitted.
12326 Note that this will be replaced by a more powerful mechanism in the future.
12327 </desc>
12328 </attribute>
12329
12330 <attribute name="reuseSingleConnection" type="boolean">
12331 <desc>
12332 Flag whether the existing connection must be dropped and a new connection
12333 must be established by the VRDP server, when a new client connects in single
12334 connection mode.
12335 </desc>
12336 </attribute>
12337
12338 <attribute name="videoChannel" type="boolean">
12339 <desc>
12340 Flag whether RDP video channel is supported.
12341 </desc>
12342 </attribute>
12343
12344 <attribute name="videoChannelQuality" type="unsigned long">
12345 <desc>
12346 Image quality in percents.
12347 </desc>
12348 </attribute>
12349
12350 </interface>
12351
12352
12353 <!--
12354 // ISharedFolder
12355 /////////////////////////////////////////////////////////////////////////
12356 -->
12357
12358 <interface
12359 name="ISharedFolder" extends="$unknown"
12360 uuid="8388da11-b559-4574-a5b7-2bd7acd5cef8"
12361 wsmap="struct"
12362 >
12363 <desc>
12364 The ISharedFolder interface represents a folder in the host computer's
12365 file system accessible from the guest OS running inside a virtual
12366 machine using an associated logical name.
12367
12368 There are three types of shared folders:
12369 <ul>
12370 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
12371 folders available to all virtual machines.</li>
12372 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
12373 VM-specific shared folders available to the given virtual machine at
12374 startup.</li>
12375 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
12376 VM-specific shared folders created in the session context (for
12377 example, when the virtual machine is running) and automatically
12378 discarded when the session is closed (the VM is powered off).</li>
12379 </ul>
12380
12381 Logical names of shared folders must be unique within the given scope
12382 (global, permanent or transient). However, they do not need to be unique
12383 across scopes. In this case, the definition of the shared folder in a
12384 more specific scope takes precedence over definitions in all other
12385 scopes. The order of precedence is (more specific to more general):
12386 <ol>
12387 <li>Transient definitions</li>
12388 <li>Permanent definitions</li>
12389 <li>Global definitions</li>
12390 </ol>
12391
12392 For example, if MyMachine has a shared folder named
12393 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then creating a
12394 transient shared folder named <tt>C_DRIVE</tt> (that points
12395 to <tt>C:\\\\WINDOWS</tt>) will change the definition
12396 of <tt>C_DRIVE</tt> in the guest OS so
12397 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
12398 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
12399 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
12400 the previous (permanent) definition of <tt>C_DRIVE</tt> that points
12401 to <tt>C:\\</tt> if it still exists.
12402
12403 Note that permanent and transient shared folders of different machines
12404 are in different name spaces, so they don't overlap and don't need to
12405 have unique logical names.
12406
12407 <note>
12408 Global shared folders are not implemented in the current version of the
12409 product.
12410 </note>
12411 </desc>
12412
12413 <attribute name="name" type="wstring" readonly="yes">
12414 <desc>Logical name of the shared folder.</desc>
12415 </attribute>
12416
12417 <attribute name="hostPath" type="wstring" readonly="yes">
12418 <desc>Full path to the shared folder in the host file system.</desc>
12419 </attribute>
12420
12421 <attribute name="accessible" type="boolean" readonly="yes">
12422 <desc>
12423 Whether the folder defined by the host path is currently
12424 accessible or not.
12425 For example, the folder can be unaccessible if it is placed
12426 on the network share that is not available by the time
12427 this property is read.
12428 </desc>
12429 </attribute>
12430
12431 <attribute name="writable" type="boolean" readonly="yes">
12432 <desc>
12433 Whether the folder defined by the host path is writable or
12434 not.
12435 </desc>
12436 </attribute>
12437
12438 <attribute name="autoMount" type="boolean" readonly="yes">
12439 <desc>
12440 Whether the folder gets automatically mounted by the guest or not.
12441 </desc>
12442 </attribute>
12443
12444 <attribute name="lastAccessError" type="wstring" readonly="yes">
12445 <desc>
12446 Text message that represents the result of the last accessibility
12447 check.
12448
12449 Accessibility checks are performed each time the <link to="#accessible"/>
12450 attribute is read. An empty string is returned if the last
12451 accessibility check was successful. A non-empty string indicates a
12452 failure and should normally describe a reason of the failure (for
12453 example, a file read error).
12454 </desc>
12455 </attribute>
12456
12457 </interface>
12458
12459 <!--
12460 // ISession
12461 /////////////////////////////////////////////////////////////////////////
12462 -->
12463
12464 <interface
12465 name="IInternalSessionControl" extends="$unknown"
12466 uuid="0431ef9e-2c2e-42af-87d7-c8f52455f28a"
12467 internal="yes"
12468 wsmap="suppress"
12469 >
12470 <method name="getPID">
12471 <desc>PID of the process that has created this Session object.
12472 </desc>
12473 <param name="pid" type="unsigned long" dir="return"/>
12474 </method>
12475
12476 <method name="getRemoteConsole">
12477 <desc>
12478 Returns the console object suitable for remote control.
12479
12480 <result name="VBOX_E_INVALID_VM_STATE">
12481 Session state prevents operation.
12482 </result>
12483 <result name="VBOX_E_INVALID_OBJECT_STATE">
12484 Session type prevents operation.
12485 </result>
12486
12487 </desc>
12488 <param name="console" type="IConsole" dir="return"/>
12489 </method>
12490
12491 <method name="assignMachine">
12492 <desc>
12493 Assigns the machine object associated with this direct-type
12494 session or informs the session that it will be a remote one
12495 (if @a machine == @c null).
12496
12497 <result name="VBOX_E_INVALID_VM_STATE">
12498 Session state prevents operation.
12499 </result>
12500 <result name="VBOX_E_INVALID_OBJECT_STATE">
12501 Session type prevents operation.
12502 </result>
12503
12504 </desc>
12505 <param name="machine" type="IMachine" dir="in"/>
12506 </method>
12507
12508 <method name="assignRemoteMachine">
12509 <desc>
12510 Assigns the machine and the (remote) console object associated with
12511 this remote-type session.
12512
12513 <result name="VBOX_E_INVALID_VM_STATE">
12514 Session state prevents operation.
12515 </result>
12516
12517 </desc>
12518 <param name="machine" type="IMachine" dir="in"/>
12519 <param name="console" type="IConsole" dir="in"/>
12520 </method>
12521
12522 <method name="updateMachineState">
12523 <desc>
12524 Updates the machine state in the VM process.
12525 Must be called only in certain cases
12526 (see the method implementation).
12527
12528 <result name="VBOX_E_INVALID_VM_STATE">
12529 Session state prevents operation.
12530 </result>
12531 <result name="VBOX_E_INVALID_OBJECT_STATE">
12532 Session type prevents operation.
12533 </result>
12534
12535 </desc>
12536 <param name="aMachineState" type="MachineState" dir="in"/>
12537 </method>
12538
12539 <method name="uninitialize">
12540 <desc>
12541 Uninitializes (closes) this session. Used by VirtualBox to close
12542 the corresponding remote session when the direct session dies
12543 or gets closed.
12544
12545 <result name="VBOX_E_INVALID_VM_STATE">
12546 Session state prevents operation.
12547 </result>
12548
12549 </desc>
12550 </method>
12551
12552 <method name="onNetworkAdapterChange">
12553 <desc>
12554 Triggered when settings of a network adapter of the
12555 associated virtual machine have changed.
12556
12557 <result name="VBOX_E_INVALID_VM_STATE">
12558 Session state prevents operation.
12559 </result>
12560 <result name="VBOX_E_INVALID_OBJECT_STATE">
12561 Session type prevents operation.
12562 </result>
12563
12564 </desc>
12565 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
12566 <param name="changeAdapter" type="boolean" dir="in"/>
12567 </method>
12568
12569 <method name="onSerialPortChange">
12570 <desc>
12571 Triggered when settings of a serial port of the
12572 associated virtual machine have changed.
12573
12574 <result name="VBOX_E_INVALID_VM_STATE">
12575 Session state prevents operation.
12576 </result>
12577 <result name="VBOX_E_INVALID_OBJECT_STATE">
12578 Session type prevents operation.
12579 </result>
12580
12581 </desc>
12582 <param name="serialPort" type="ISerialPort" dir="in"/>
12583 </method>
12584
12585 <method name="onParallelPortChange">
12586 <desc>
12587 Triggered when settings of a parallel port of the
12588 associated virtual machine have changed.
12589
12590 <result name="VBOX_E_INVALID_VM_STATE">
12591 Session state prevents operation.
12592 </result>
12593 <result name="VBOX_E_INVALID_OBJECT_STATE">
12594 Session type prevents operation.
12595 </result>
12596
12597 </desc>
12598 <param name="parallelPort" type="IParallelPort" dir="in"/>
12599 </method>
12600
12601 <method name="onStorageControllerChange">
12602 <desc>
12603 Triggered when settings of a storage controller of the
12604 associated virtual machine have changed.
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 </method>
12615
12616 <method name="onMediumChange">
12617 <desc>
12618 Triggered when attached media of the
12619 associated virtual machine have changed.
12620
12621 <result name="VBOX_E_INVALID_VM_STATE">
12622 Session state prevents operation.
12623 </result>
12624 <result name="VBOX_E_INVALID_OBJECT_STATE">
12625 Session type prevents operation.
12626 </result>
12627
12628 </desc>
12629
12630 <param name="mediumAttachment" type="IMediumAttachment" dir="in"/>
12631 <param name="force" type="boolean" dir="in"/>
12632 </method>
12633
12634 <method name="onCPUChange">
12635 <desc>
12636 Notification when a CPU changes.
12637 </desc>
12638 <param name="cpu" type="unsigned long" dir="in">
12639 <desc>The CPU which changed</desc>
12640 </param>
12641 <param name="add" type="boolean" dir="in">
12642 <desc>Flag whether the CPU was added or removed</desc>
12643 </param>
12644 </method>
12645
12646 <method name="onCPUExecutionCapChange">
12647 <desc>
12648 Notification when the CPU execution cap changes.
12649 </desc>
12650 <param name="executionCap" type="unsigned long" dir="in">
12651 <desc>The new CPU execution cap value. (1-100)</desc>
12652 </param>
12653 </method>
12654
12655 <method name="onVRDPServerChange">
12656 <desc>
12657 Triggered when settings of the VRDP server object of the
12658 associated virtual machine have changed.
12659
12660 <result name="VBOX_E_INVALID_VM_STATE">
12661 Session state prevents operation.
12662 </result>
12663 <result name="VBOX_E_INVALID_OBJECT_STATE">
12664 Session type prevents operation.
12665 </result>
12666
12667 </desc>
12668 <param name="restart" type="boolean" dir="in">
12669 <desc>Flag whether the server must be restarted</desc>
12670 </param>
12671 </method>
12672
12673 <method name="onUSBControllerChange">
12674 <desc>
12675 Triggered when settings of the USB controller object of the
12676 associated virtual machine have changed.
12677
12678 <result name="VBOX_E_INVALID_VM_STATE">
12679 Session state prevents operation.
12680 </result>
12681 <result name="VBOX_E_INVALID_OBJECT_STATE">
12682 Session type prevents operation.
12683 </result>
12684
12685 </desc>
12686 </method>
12687
12688 <method name="onSharedFolderChange">
12689 <desc>
12690 Triggered when a permanent (global or machine) shared folder has been
12691 created or removed.
12692 <note>
12693 We don't pass shared folder parameters in this notification because
12694 the order in which parallel notifications are delivered is not defined,
12695 therefore it could happen that these parameters were outdated by the
12696 time of processing this notification.
12697 </note>
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="global" type="boolean" dir="in"/>
12708 </method>
12709
12710 <method name="onUSBDeviceAttach">
12711 <desc>
12712 Triggered when a request to capture a USB device (as a result
12713 of matched USB filters or direct call to
12714 <link to="IConsole::attachUSBDevice"/>) has completed.
12715 A @c null @a error object means success, otherwise it
12716 describes a failure.
12717
12718 <result name="VBOX_E_INVALID_VM_STATE">
12719 Session state prevents operation.
12720 </result>
12721 <result name="VBOX_E_INVALID_OBJECT_STATE">
12722 Session type prevents operation.
12723 </result>
12724
12725 </desc>
12726 <param name="device" type="IUSBDevice" dir="in"/>
12727 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12728 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
12729 </method>
12730
12731 <method name="onUSBDeviceDetach">
12732 <desc>
12733 Triggered when a request to release the USB device (as a result
12734 of machine termination or direct call to
12735 <link to="IConsole::detachUSBDevice"/>) has completed.
12736 A @c null @a error object means success, otherwise it
12737 describes a failure.
12738
12739 <result name="VBOX_E_INVALID_VM_STATE">
12740 Session state prevents operation.
12741 </result>
12742 <result name="VBOX_E_INVALID_OBJECT_STATE">
12743 Session type prevents operation.
12744 </result>
12745
12746 </desc>
12747 <param name="id" type="uuid" mod="string" dir="in"/>
12748 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12749 </method>
12750
12751 <method name="onShowWindow">
12752 <desc>
12753 Called by <link to="IMachine::canShowConsoleWindow"/> and by
12754 <link to="IMachine::showConsoleWindow"/> in order to notify
12755 console listeners
12756 <link to="ICanShowWindowEvent"/>
12757 and <link to="IShowWindowEvent"/>.
12758
12759 <result name="VBOX_E_INVALID_OBJECT_STATE">
12760 Session type prevents operation.
12761 </result>
12762
12763 </desc>
12764 <param name="check" type="boolean" dir="in"/>
12765 <param name="canShow" type="boolean" dir="out"/>
12766 <param name="winId" type="long long" dir="out"/>
12767 </method>
12768
12769 <method name="accessGuestProperty">
12770 <desc>
12771 Called by <link to="IMachine::getGuestProperty"/> and by
12772 <link to="IMachine::setGuestProperty"/> in order to read and
12773 modify guest properties.
12774
12775 <result name="VBOX_E_INVALID_VM_STATE">
12776 Machine session is not open.
12777 </result>
12778 <result name="VBOX_E_INVALID_OBJECT_STATE">
12779 Session type is not direct.
12780 </result>
12781
12782 </desc>
12783 <param name="name" type="wstring" dir="in"/>
12784 <param name="value" type="wstring" dir="in"/>
12785 <param name="flags" type="wstring" dir="in"/>
12786 <param name="isSetter" type="boolean" dir="in"/>
12787 <param name="retValue" type="wstring" dir="out"/>
12788 <param name="retTimestamp" type="long long" dir="out"/>
12789 <param name="retFlags" type="wstring" dir="out"/>
12790 </method>
12791
12792 <method name="enumerateGuestProperties">
12793 <desc>
12794 Return a list of the guest properties matching a set of patterns along
12795 with their values, time stamps and flags.
12796
12797 <result name="VBOX_E_INVALID_VM_STATE">
12798 Machine session is not open.
12799 </result>
12800 <result name="VBOX_E_INVALID_OBJECT_STATE">
12801 Session type is not direct.
12802 </result>
12803
12804 </desc>
12805 <param name="patterns" type="wstring" dir="in">
12806 <desc>
12807 The patterns to match the properties against as a comma-separated
12808 string. If this is empty, all properties currently set will be
12809 returned.
12810 </desc>
12811 </param>
12812 <param name="key" type="wstring" dir="out" safearray="yes">
12813 <desc>
12814 The key names of the properties returned.
12815 </desc>
12816 </param>
12817 <param name="value" type="wstring" dir="out" safearray="yes">
12818 <desc>
12819 The values of the properties returned. The array entries match the
12820 corresponding entries in the @a key array.
12821 </desc>
12822 </param>
12823 <param name="timestamp" type="long long" dir="out" safearray="yes">
12824 <desc>
12825 The time stamps of the properties returned. The array entries match
12826 the corresponding entries in the @a key array.
12827 </desc>
12828 </param>
12829 <param name="flags" type="wstring" dir="out" safearray="yes">
12830 <desc>
12831 The flags of the properties returned. The array entries match the
12832 corresponding entries in the @a key array.
12833 </desc>
12834 </param>
12835 </method>
12836
12837 <method name="onlineMergeMedium">
12838 <desc>
12839 Triggers online merging of a hard disk. Used internally when deleting
12840 a snapshot while a VM referring to the same hard disk chain is running.
12841
12842 <result name="VBOX_E_INVALID_VM_STATE">
12843 Machine session is not open.
12844 </result>
12845 <result name="VBOX_E_INVALID_OBJECT_STATE">
12846 Session type is not direct.
12847 </result>
12848
12849 </desc>
12850 <param name="mediumAttachment" type="IMediumAttachment" dir="in">
12851 <desc>The medium attachment to identify the medium chain.</desc>
12852 </param>
12853 <param name="sourceIdx" type="unsigned long" dir="in">
12854 <desc>The index of the source image in the chain.
12855 Redundant, but drastically reduces IPC.</desc>
12856 </param>
12857 <param name="targetIdx" type="unsigned long" dir="in">
12858 <desc>The index of the target image in the chain.
12859 Redundant, but drastically reduces IPC.</desc>
12860 </param>
12861 <param name="source" type="IMedium" dir="in">
12862 <desc>Merge source medium.</desc>
12863 </param>
12864 <param name="target" type="IMedium" dir="in">
12865 <desc>Merge target medium.</desc>
12866 </param>
12867 <param name="mergeForward" type="boolean" dir="in">
12868 <desc>Merge direction.</desc>
12869 </param>
12870 <param name="parentForTarget" type="IMedium" dir="in">
12871 <desc>For forward merges: new parent for target medium.</desc>
12872 </param>
12873 <param name="childrenToReparent" type="IMedium" safearray="yes" dir="in">
12874 <desc>For backward merges: list of media which need their parent UUID
12875 updated.</desc>
12876 </param>
12877 <param name="progress" type="IProgress" dir="in">
12878 <desc>
12879 Progress object for this operation.
12880 </desc>
12881 </param>
12882 </method>
12883
12884 </interface>
12885
12886 <interface
12887 name="ISession" extends="$unknown"
12888 uuid="12F4DCDB-12B2-4EC1-B7CD-DDD9F6C5BF4D"
12889 wsmap="managed"
12890 >
12891 <desc>
12892 The ISession interface represents a client process and allows for locking
12893 virtual machines (represented by IMachine objects) to prevent conflicting
12894 changes to the machine.
12895
12896 Any caller wishing to manipulate a virtual machine needs to create a session
12897 object first, which lives in its own process space. Such session objects are
12898 then associated with <link to="IMachine" /> objects living in the VirtualBox
12899 server process to coordinate such changes.
12900
12901 There are two typical scenarios in which sessions are used:
12902
12903 <ul>
12904 <li>To alter machine settings or control a running virtual machine, one
12905 needs to lock a machine for a given session (client process) by calling
12906 <link to="IMachine::lockMachine"/>.
12907
12908 Whereas multiple sessions may control a running virtual machine, only
12909 one process can obtain a write lock on the machine to prevent conflicting
12910 changes. A write lock is also needed if a process wants to actually run a
12911 virtual machine in its own context, such as the VirtualBox GUI or
12912 VBoxHeadless front-ends. They must also lock a machine for their own
12913 sessions before they are allowed to power up the virtual machine.
12914
12915 As a result, no machine settings can be altered while another process is
12916 already using it, either because that process is modifying machine settings
12917 or because the machine is running.
12918 </li>
12919 <li>
12920 To start a VM using one of the existing VirtualBox front-ends (e.g. the
12921 VirtualBox GUI or VBoxHeadless), one would use
12922 <link to="IMachine::launchVMProcess"/>, which also takes a session object
12923 as its first parameter. This session then identifies the caller and lets the
12924 caller control the started machine (for example, pause machine execution or
12925 power it down) as well as be notified about machine execution state changes.
12926 </li>
12927 </ul>
12928
12929 How sessions objects are created in a client process depends on whether you use
12930 the Main API via COM or via the webservice:
12931
12932 <ul>
12933 <li>When using the COM API directly, an object of the Session class from the
12934 VirtualBox type library needs to be created. In regular COM C++ client code,
12935 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
12936 This object will then act as a local session object in further calls to open
12937 a session.
12938 </li>
12939
12940 <li>In the webservice, the session manager (IWebsessionManager) instead creates
12941 a session object automatically whenever <link to="IWebsessionManager::logon" />
12942 is called. A managed object reference to that session object can be retrieved by
12943 calling <link to="IWebsessionManager::getSessionObject" />.
12944 </li>
12945 </ul>
12946 </desc>
12947
12948 <attribute name="state" type="SessionState" readonly="yes">
12949 <desc>Current state of this session.</desc>
12950 </attribute>
12951
12952 <attribute name="type" type="SessionType" readonly="yes">
12953 <desc>
12954 Type of this session. The value of this attribute is valid only
12955 if the session currently has a machine locked (i.e. its
12956 <link to="#state" /> is Locked), otherwise an error will be returned.
12957 </desc>
12958 </attribute>
12959
12960 <attribute name="machine" type="IMachine" readonly="yes">
12961 <desc>Machine object associated with this session.</desc>
12962 </attribute>
12963
12964 <attribute name="console" type="IConsole" readonly="yes">
12965 <desc>Console object associated with this session.</desc>
12966 </attribute>
12967
12968 <method name="unlockMachine">
12969 <desc>
12970 Unlocks a machine that was previously locked for the current session.
12971
12972 Calling this method is required every time a machine has been locked
12973 for a particular session using the <link to="IMachine::launchVMProcess" />
12974 or <link to="IMachine::lockMachine" /> calls. Otherwise the state of
12975 the machine will be set to <link to="MachineState_Aborted" /> on the
12976 server, and changes made to the machine settings will be lost.
12977
12978 Generally, it is recommended to unlock all machines explicitly
12979 before terminating the application (regardless of the reason for
12980 the termination).
12981
12982 <note>
12983 Do not expect the session state (<link to="ISession::state" />
12984 to return to "Unlocked" immediately after you invoke this method,
12985 particularly if you have started a new VM process. The session
12986 state will automatically return to "Unlocked" once the VM is no
12987 longer executing, which can of course take a very long time.
12988 </note>
12989
12990 <result name="E_UNEXPECTED">
12991 Session is not locked.
12992 </result>
12993
12994 </desc>
12995 </method>
12996
12997 </interface>
12998
12999 <!--
13000 // IStorageController
13001 /////////////////////////////////////////////////////////////////////////
13002 -->
13003
13004 <enum
13005 name="StorageBus"
13006 uuid="eee67ab3-668d-4ef5-91e0-7025fe4a0d7a"
13007 >
13008 <desc>
13009 The bus type of the storage controller (IDE, SATA, SCSI, SAS or Floppy);
13010 see <link to="IStorageController::bus" />.
13011 </desc>
13012 <const name="Null" value="0">
13013 <desc>@c null value. Never used by the API.</desc>
13014 </const>
13015 <const name="IDE" value="1"/>
13016 <const name="SATA" value="2"/>
13017 <const name="SCSI" value="3"/>
13018 <const name="Floppy" value="4"/>
13019 <const name="SAS" value="5"/>
13020 </enum>
13021
13022 <enum
13023 name="StorageControllerType"
13024 uuid="8a412b8a-f43e-4456-bd37-b474f0879a58"
13025 >
13026 <desc>
13027 The exact variant of storage controller hardware presented
13028 to the guest; see <link to="IStorageController::controllerType" />.
13029 </desc>
13030
13031 <const name="Null" value="0">
13032 <desc>@c null value. Never used by the API.</desc>
13033 </const>
13034 <const name="LsiLogic" value="1">
13035 <desc>A SCSI controller of the LsiLogic variant.</desc>
13036 </const>
13037 <const name="BusLogic" value="2">
13038 <desc>A SCSI controller of the BusLogic variant.</desc>
13039 </const>
13040 <const name="IntelAhci" value="3">
13041 <desc>An Intel AHCI SATA controller; this is the only variant for SATA.</desc>
13042 </const>
13043 <const name="PIIX3" value="4">
13044 <desc>An IDE controller of the PIIX3 variant.</desc>
13045 </const>
13046 <const name="PIIX4" value="5">
13047 <desc>An IDE controller of the PIIX4 variant.</desc>
13048 </const>
13049 <const name="ICH6" value="6">
13050 <desc>An IDE controller of the ICH6 variant.</desc>
13051 </const>
13052 <const name="I82078" value="7">
13053 <desc>A floppy disk controller; this is the only variant for floppy drives.</desc>
13054 </const>
13055 <const name="LsiLogicSas" value="8">
13056 <desc>A variant of the LsiLogic controller using SAS.</desc>
13057 </const>
13058 </enum>
13059
13060 <enum
13061 name="ChipsetType"
13062 uuid="8b4096a8-a7c3-4d3b-bbb1-05a0a51ec394"
13063 >
13064 <desc>
13065 Type of emulated chipset (mostly southbridge).
13066 </desc>
13067
13068 <const name="Null" value="0">
13069 <desc>@c null value. Never used by the API.</desc>
13070 </const>
13071 <const name="PIIX3" value="1">
13072 <desc>A PIIX3 (PCI IDE ISA Xcelerator) chipset.</desc>
13073 </const>
13074 <const name="ICH9" value="2">
13075 <desc>A ICH9 (I/O Controller Hub) chipset.</desc>
13076 </const>
13077 </enum>
13078
13079 <interface
13080 name="IStorageController" extends="$unknown"
13081 uuid="fd93adc0-bbaa-4256-9e6e-00e29f9151c9"
13082 wsmap="managed"
13083 >
13084 <desc>
13085 Represents a storage controller that is attached to a virtual machine
13086 (<link to="IMachine" />). Just as drives (hard disks, DVDs, FDs) are
13087 attached to storage controllers in a real computer, virtual drives
13088 (represented by <link to="IMediumAttachment" />) are attached to virtual
13089 storage controllers, represented by this interface.
13090
13091 As opposed to physical hardware, VirtualBox has a very generic concept
13092 of a storage controller, and for purposes of the Main API, all virtual
13093 storage is attached to virtual machines via instances of this interface.
13094 There are five types of such virtual storage controllers: IDE, SCSI, SATA,
13095 SAS and Floppy (see <link to="#bus" />). Depending on which of these four
13096 is used, certain sub-types may be available and can be selected in
13097 <link to="#controllerType" />.
13098
13099 Depending on these settings, the guest operating system might see
13100 significantly different virtual hardware.
13101 </desc>
13102
13103 <attribute name="name" type="wstring" readonly="yes">
13104 <desc>
13105 Name of the storage controller, as originally specified with
13106 <link to="IMachine::addStorageController" />. This then uniquely
13107 identifies this controller with other method calls such as
13108 <link to="IMachine::attachDevice" /> and <link to="IMachine::mountMedium" />.
13109 </desc>
13110 </attribute>
13111
13112 <attribute name="maxDevicesPerPortCount" type="unsigned long" readonly="yes">
13113 <desc>
13114 Maximum number of devices which can be attached to one port.
13115 </desc>
13116 </attribute>
13117
13118 <attribute name="minPortCount" type="unsigned long" readonly="yes">
13119 <desc>
13120 Minimum number of ports that <link to="IStorageController::portCount"/> can be set to.
13121 </desc>
13122 </attribute>
13123
13124 <attribute name="maxPortCount" type="unsigned long" readonly="yes">
13125 <desc>
13126 Maximum number of ports that <link to="IStorageController::portCount"/> can be set to.
13127 </desc>
13128 </attribute>
13129
13130 <attribute name="instance" type="unsigned long">
13131 <desc>
13132 The instance number of the device in the running VM.
13133 </desc>
13134 </attribute>
13135
13136 <attribute name="portCount" type="unsigned long">
13137 <desc>
13138 The number of currently usable ports on the controller.
13139 The minimum and maximum number of ports for one controller are
13140 stored in <link to="IStorageController::minPortCount"/>
13141 and <link to="IStorageController::maxPortCount"/>.
13142 </desc>
13143 </attribute>
13144
13145 <attribute name="bus" type="StorageBus" readonly="yes">
13146 <desc>
13147 The bus type of the storage controller (IDE, SATA, SCSI, SAS or Floppy).
13148 </desc>
13149 </attribute>
13150
13151 <attribute name="controllerType" type="StorageControllerType">
13152 <desc>
13153 The exact variant of storage controller hardware presented
13154 to the guest.
13155 Depending on this value, VirtualBox will provide a different
13156 virtual storage controller hardware to the guest.
13157 For SATA, SAS and floppy controllers, only one variant is
13158 available, but for IDE and SCSI, there are several.
13159
13160 For SCSI controllers, the default type is LsiLogic.
13161 </desc>
13162 </attribute>
13163
13164 <attribute name="useHostIOCache" type="boolean">
13165 <desc>
13166 If true, the storage controller emulation will use a dedicated I/O thread, enable the host I/O
13167 caches and use synchronous file APIs on the host. This was the only option in the API before
13168 VirtualBox 3.2 and is still the default for IDE controllers.
13169
13170 If false, the host I/O cache will be disabled for image files attached to this storage controller.
13171 Instead, the storage controller emulation will use asynchronous I/O APIs on the host. This makes
13172 it possible to turn off the host I/O caches because the emulation can handle unaligned access to
13173 the file. This should be used on OS X and Linux hosts if a high I/O load is expected or many
13174 virtual machines are running at the same time to prevent I/O cache related hangs.
13175 This option new with the API of VirtualBox 3.2 and is now the default for non-IDE storage controllers.
13176 </desc>
13177 </attribute>
13178
13179 <method name="getIDEEmulationPort">
13180 <desc>
13181 Gets the corresponding port number which is emulated as an IDE device.
13182 Works only with SATA controllers.
13183
13184 <result name="E_INVALIDARG">
13185 The @a devicePosition is not in the range 0 to 3.
13186 </result>
13187 <result name="E_NOTIMPL">
13188 The storage controller type is not SATAIntelAhci.
13189 </result>
13190
13191 </desc>
13192 <param name="devicePosition" type="long" dir="in"/>
13193 <param name="portNumber" type="long" dir="return"/>
13194 </method>
13195
13196 <method name="setIDEEmulationPort">
13197 <desc>
13198 Sets the port number which is emulated as an IDE device.
13199 Works only with SATA controllers.
13200
13201 <result name="E_INVALIDARG">
13202 The @a devicePosition is not in the range 0 to 3 or the
13203 @a portNumber is not in the range 0 to 29.
13204 </result>
13205 <result name="E_NOTIMPL">
13206 The storage controller type is not SATAIntelAhci.
13207 </result>
13208
13209 </desc>
13210 <param name="devicePosition" type="long" dir="in"/>
13211 <param name="portNumber" type="long" dir="in"/>
13212 </method>
13213
13214 </interface>
13215
13216<if target="wsdl">
13217
13218 <!--
13219 // IManagedObjectRef
13220 /////////////////////////////////////////////////////////////////////////
13221 -->
13222
13223 <interface
13224 name="IManagedObjectRef" extends="$unknown"
13225 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
13226 internal="yes"
13227 wsmap="managed"
13228 wscpp="hardcoded"
13229 >
13230 <desc>
13231 Managed object reference.
13232
13233 Only within the webservice, a managed object reference (which is really
13234 an opaque number) allows a webservice client to address an object
13235 that lives in the address space of the webservice server.
13236
13237 Behind each managed object reference, there is a COM object that lives
13238 in the webservice server's address space. The COM object is not freed
13239 until the managed object reference is released, either by an explicit
13240 call to <link to="IManagedObjectRef::release" /> or by logging off from
13241 the webservice (<link to="IWebsessionManager::logoff" />), which releases
13242 all objects created during the webservice session.
13243
13244 Whenever a method call of the VirtualBox API returns a COM object, the
13245 webservice representation of that method will instead return a
13246 managed object reference, which can then be used to invoke methods
13247 on that object.
13248 </desc>
13249
13250 <method name="getInterfaceName">
13251 <desc>
13252 Returns the name of the interface that this managed object represents,
13253 for example, "IMachine", as a string.
13254 </desc>
13255 <param name="return" type="wstring" dir="return"/>
13256 </method>
13257
13258 <method name="release">
13259 <desc>
13260 Releases this managed object reference and frees the resources that
13261 were allocated for it in the webservice server process. After calling
13262 this method, the identifier of the reference can no longer be used.
13263 </desc>
13264 </method>
13265
13266 </interface>
13267
13268 <!--
13269 // IWebsessionManager
13270 /////////////////////////////////////////////////////////////////////////
13271 -->
13272
13273 <interface
13274 name="IWebsessionManager" extends="$unknown"
13275 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
13276 internal="yes"
13277 wsmap="global"
13278 wscpp="hardcoded"
13279 >
13280 <desc>
13281 Websession manager. This provides essential services
13282 to webservice clients.
13283 </desc>
13284 <method name="logon">
13285 <desc>
13286 Logs a new client onto the webservice and returns a managed object reference to
13287 the IVirtualBox instance, which the client can then use as a basis to further
13288 queries, since all calls to the VirtualBox API are based on the IVirtualBox
13289 interface, in one way or the other.
13290 </desc>
13291 <param name="username" type="wstring" dir="in"/>
13292 <param name="password" type="wstring" dir="in"/>
13293 <param name="return" type="IVirtualBox" dir="return"/>
13294 </method>
13295
13296 <method name="getSessionObject">
13297 <desc>
13298 Returns a managed object reference to the internal ISession object that was created
13299 for this web service session when the client logged on.
13300
13301 <see>ISession</see>
13302 </desc>
13303 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13304 <param name="return" type="ISession" dir="return"/>
13305 </method>
13306
13307 <method name="logoff">
13308 <desc>
13309 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
13310 and destroys all resources associated with the session (most importantly, all
13311 managed objects created in the server while the session was active).
13312 </desc>
13313 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13314 </method>
13315
13316 </interface>
13317
13318</if>
13319
13320 <!--
13321 // IPerformanceCollector & friends
13322 /////////////////////////////////////////////////////////////////////////
13323 -->
13324
13325 <interface
13326 name="IPerformanceMetric" extends="$unknown"
13327 uuid="2a1a60ae-9345-4019-ad53-d34ba41cbfe9" wsmap="managed"
13328 >
13329 <desc>
13330 The IPerformanceMetric interface represents parameters of the given
13331 performance metric.
13332 </desc>
13333
13334 <attribute name="metricName" type="wstring" readonly="yes">
13335 <desc>
13336 Name of the metric.
13337 </desc>
13338 </attribute>
13339
13340 <attribute name="object" type="$unknown" readonly="yes">
13341 <desc>
13342 Object this metric belongs to.
13343 </desc>
13344 </attribute>
13345
13346 <attribute name="description" type="wstring" readonly="yes">
13347 <desc>
13348 Textual description of the metric.
13349 </desc>
13350 </attribute>
13351
13352 <attribute name="period" type="unsigned long" readonly="yes">
13353 <desc>
13354 Time interval between samples, measured in seconds.
13355 </desc>
13356 </attribute>
13357
13358 <attribute name="count" type="unsigned long" readonly="yes">
13359 <desc>
13360 Number of recent samples retained by the performance collector for this
13361 metric.
13362
13363 When the collected sample count exceeds this number, older samples
13364 are discarded.
13365 </desc>
13366 </attribute>
13367
13368 <attribute name="unit" type="wstring" readonly="yes">
13369 <desc>
13370 Unit of measurement.
13371 </desc>
13372 </attribute>
13373
13374 <attribute name="minimumValue" type="long" readonly="yes">
13375 <desc>
13376 Minimum possible value of this metric.
13377 </desc>
13378 </attribute>
13379
13380 <attribute name="maximumValue" type="long" readonly="yes">
13381 <desc>
13382 Maximum possible value of this metric.
13383 </desc>
13384 </attribute>
13385 </interface>
13386
13387 <interface
13388 name="IPerformanceCollector" extends="$unknown"
13389 uuid="e22e1acb-ac4a-43bb-a31c-17321659b0c6"
13390 wsmap="managed"
13391 >
13392 <desc>
13393 The IPerformanceCollector interface represents a service that collects
13394 and stores performance metrics data.
13395
13396 Performance metrics are associated with objects of interfaces like IHost
13397 and IMachine. Each object has a distinct set of performance metrics. The
13398 set can be obtained with <link to="IPerformanceCollector::getMetrics"/>.
13399
13400 Metric data is collected at the specified intervals and is retained
13401 internally. The interval and the number of retained samples can be set
13402 with <link to="IPerformanceCollector::setupMetrics" />. Both metric data
13403 and collection settings are not persistent, they are discarded as soon as
13404 VBoxSVC process terminates. Moreover, metric settings and data associated
13405 with a particular VM only exist while VM is running. They disappear as
13406 soon as VM shuts down. It is not possible to set up metrics for machines
13407 that are powered off. One needs to start VM first, then set up metric
13408 collection parameters.
13409
13410 Metrics are organized hierarchically, with each level separated by a
13411 slash (/) character. Generally, the scheme for metric names is like this:
13412
13413 <tt>Category/Metric[/SubMetric][:aggregation]</tt>
13414
13415 "Category/Metric" together form the base metric name. A base metric is
13416 the smallest unit for which a sampling interval and the number of
13417 retained samples can be set. Only base metrics can be enabled and
13418 disabled. All sub-metrics are collected when their base metric is
13419 collected. Collected values for any set of sub-metrics can be queried
13420 with <link to="IPerformanceCollector::queryMetricsData" />.
13421
13422 For example "CPU/Load/User:avg" metric name stands for the "CPU"
13423 category, "Load" metric, "User" submetric, "average" aggregate. An
13424 aggregate function is computed over all retained data. Valid aggregate
13425 functions are:
13426
13427 <ul>
13428 <li>avg -- average</li>
13429 <li>min -- minimum</li>
13430 <li>max -- maximum</li>
13431 </ul>
13432
13433 When setting up metric parameters, querying metric data, enabling or
13434 disabling metrics wildcards can be used in metric names to specify a
13435 subset of metrics. For example, to select all CPU-related metrics
13436 use <tt>CPU/*</tt>, all averages can be queried using <tt>*:avg</tt> and
13437 so on. To query metric values without aggregates <tt>*:</tt> can be used.
13438
13439 The valid names for base metrics are:
13440
13441 <ul>
13442 <li>CPU/Load</li>
13443 <li>CPU/MHz</li>
13444 <li>RAM/Usage</li>
13445 </ul>
13446
13447 The general sequence for collecting and retrieving the metrics is:
13448 <ul>
13449 <li>
13450 Obtain an instance of IPerformanceCollector with
13451 <link to="IVirtualBox::performanceCollector" />
13452 </li>
13453 <li>
13454 Allocate and populate an array with references to objects the metrics
13455 will be collected for. Use references to IHost and IMachine objects.
13456 </li>
13457 <li>
13458 Allocate and populate an array with base metric names the data will
13459 be collected for.
13460 </li>
13461 <li>
13462 Call <link to="IPerformanceCollector::setupMetrics" />. From now on
13463 the metric data will be collected and stored.
13464 </li>
13465 <li>
13466 Wait for the data to get collected.
13467 </li>
13468 <li>
13469 Allocate and populate an array with references to objects the metric
13470 values will be queried for. You can re-use the object array used for
13471 setting base metrics.
13472 </li>
13473 <li>
13474 Allocate and populate an array with metric names the data will be
13475 collected for. Note that metric names differ from base metric names.
13476 </li>
13477 <li>
13478 Call <link to="IPerformanceCollector::queryMetricsData" />. The data
13479 that have been collected so far are returned. Note that the values
13480 are still retained internally and data collection continues.
13481 </li>
13482 </ul>
13483
13484 For an example of usage refer to the following files in VirtualBox SDK:
13485 <ul>
13486 <li>
13487 Java: <tt>bindings/webservice/java/jax-ws/samples/metrictest.java</tt>
13488 </li>
13489 <li>
13490 Python: <tt>bindings/xpcom/python/sample/shellcommon.py</tt>
13491 </li>
13492 </ul>
13493 </desc>
13494
13495 <attribute name="metricNames" type="wstring" readonly="yes" safearray="yes">
13496 <desc>
13497 Array of unique names of metrics.
13498
13499 This array represents all metrics supported by the performance
13500 collector. Individual objects do not necessarily support all of them.
13501 <link to="IPerformanceCollector::getMetrics"/> can be used to get the
13502 list of supported metrics for a particular object.
13503 </desc>
13504 </attribute>
13505
13506 <method name="getMetrics">
13507 <desc>
13508 Returns parameters of specified metrics for a set of objects.
13509 <note>
13510 @c Null metrics array means all metrics. @c Null object array means
13511 all existing objects.
13512 </note>
13513 </desc>
13514 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13515 <desc>
13516 Metric name filter. Currently, only a comma-separated list of metrics
13517 is supported.
13518 </desc>
13519 </param>
13520 <param name="objects" type="$unknown" dir="in" safearray="yes">
13521 <desc>
13522 Set of objects to return metric parameters for.
13523 </desc>
13524 </param>
13525 <param name="metrics" type="IPerformanceMetric" dir="return" safearray="yes">
13526 <desc>
13527 Array of returned metric parameters.
13528 </desc>
13529 </param>
13530 </method>
13531
13532 <method name="setupMetrics">
13533 <desc>
13534 Sets parameters of specified base metrics for a set of objects. Returns
13535 an array of <link to="IPerformanceMetric" /> describing the metrics
13536 have been affected.
13537 <note>
13538 @c Null or empty metric name array means all metrics. @c Null or
13539 empty object array means all existing objects. If metric name array
13540 contains a single element and object array contains many, the single
13541 metric name array element is applied to each object array element to
13542 form metric/object pairs.
13543 </note>
13544 </desc>
13545 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13546 <desc>
13547 Metric name filter. Comma-separated list of metrics with wildcard
13548 support.
13549 </desc>
13550 </param>
13551 <param name="objects" type="$unknown" dir="in" safearray="yes">
13552 <desc>
13553 Set of objects to setup metric parameters for.
13554 </desc>
13555 </param>
13556 <param name="period" type="unsigned long" dir="in">
13557 <desc>
13558 Time interval in seconds between two consecutive samples of
13559 performance data.
13560 </desc>
13561 </param>
13562 <param name="count" type="unsigned long" dir="in">
13563 <desc>
13564 Number of samples to retain in performance data history. Older
13565 samples get discarded.
13566 </desc>
13567 </param>
13568 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13569 <desc>
13570 Array of metrics that have been modified by the call to this method.
13571 </desc>
13572 </param>
13573 </method>
13574
13575 <method name="enableMetrics">
13576 <desc>
13577 Turns on collecting specified base metrics. Returns an array of
13578 <link to="IPerformanceMetric" /> describing the metrics have been
13579 affected.
13580 <note>
13581 @c Null or empty metric name array means all metrics. @c Null or
13582 empty object array means all existing objects. If metric name array
13583 contains a single element and object array contains many, the single
13584 metric name array element is applied to each object array element to
13585 form metric/object pairs.
13586 </note>
13587 </desc>
13588 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13589 <desc>
13590 Metric name filter. Comma-separated list of metrics with wildcard
13591 support.
13592 </desc>
13593 </param>
13594 <param name="objects" type="$unknown" dir="in" safearray="yes">
13595 <desc>
13596 Set of objects to enable metrics for.
13597 </desc>
13598 </param>
13599 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13600 <desc>
13601 Array of metrics that have been modified by the call to this method.
13602 </desc>
13603 </param>
13604 </method>
13605
13606 <method name="disableMetrics">
13607 <desc>
13608 Turns off collecting specified base metrics. Returns an array of
13609 <link to="IPerformanceMetric" /> describing the metrics have been
13610 affected.
13611 <note>
13612 @c Null or empty metric name array means all metrics. @c Null or
13613 empty object array means all existing objects. If metric name array
13614 contains a single element and object array contains many, the single
13615 metric name array element is applied to each object array element to
13616 form metric/object pairs.
13617 </note>
13618 </desc>
13619 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13620 <desc>
13621 Metric name filter. Comma-separated list of metrics with wildcard
13622 support.
13623 </desc>
13624 </param>
13625 <param name="objects" type="$unknown" dir="in" safearray="yes">
13626 <desc>
13627 Set of objects to disable metrics for.
13628 </desc>
13629 </param>
13630 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13631 <desc>
13632 Array of metrics that have been modified by the call to this method.
13633 </desc>
13634 </param>
13635 </method>
13636
13637 <method name="queryMetricsData">
13638 <desc>
13639 Queries collected metrics data for a set of objects.
13640
13641 The data itself and related metric information are returned in seven
13642 parallel and one flattened array of arrays. Elements of
13643 <tt>returnMetricNames, returnObjects, returnUnits, returnScales,
13644 returnSequenceNumbers, returnDataIndices and returnDataLengths</tt> with
13645 the same index describe one set of values corresponding to a single
13646 metric.
13647
13648 The <tt>returnData</tt> parameter is a flattened array of arrays. Each
13649 start and length of a sub-array is indicated by
13650 <tt>returnDataIndices</tt> and <tt>returnDataLengths</tt>. The first
13651 value for metric <tt>metricNames[i]</tt> is at
13652 <tt>returnData[returnIndices[i]]</tt>.
13653
13654 <note>
13655 @c Null or empty metric name array means all metrics. @c Null or
13656 empty object array means all existing objects. If metric name array
13657 contains a single element and object array contains many, the single
13658 metric name array element is applied to each object array element to
13659 form metric/object pairs.
13660 </note>
13661 <note>
13662 Data collection continues behind the scenes after call to @c
13663 queryMetricsData. The return data can be seen as the snapshot of the
13664 current state at the time of @c queryMetricsData call. The internally
13665 kept metric values are not cleared by the call. This makes possible
13666 querying different subsets of metrics or aggregates with subsequent
13667 calls. If periodic querying is needed it is highly suggested to query
13668 the values with @c interval*count period to avoid confusion. This way
13669 a completely new set of data values will be provided by each query.
13670 </note>
13671 </desc>
13672 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13673 <desc>
13674 Metric name filter. Comma-separated list of metrics with wildcard
13675 support.
13676 </desc>
13677 </param>
13678 <param name="objects" type="$unknown" dir="in" safearray="yes">
13679 <desc>
13680 Set of objects to query metrics for.
13681 </desc>
13682 </param>
13683 <param name="returnMetricNames" type="wstring" dir="out" safearray="yes">
13684 <desc>
13685 Names of metrics returned in @c returnData.
13686 </desc>
13687 </param>
13688 <param name="returnObjects" type="$unknown" dir="out" safearray="yes">
13689 <desc>
13690 Objects associated with metrics returned in @c returnData.
13691 </desc>
13692 </param>
13693 <param name="returnUnits" type="wstring" dir="out" safearray="yes">
13694 <desc>
13695 Units of measurement for each returned metric.
13696 </desc>
13697 </param>
13698 <param name="returnScales" type="unsigned long" dir="out" safearray="yes">
13699 <desc>
13700 Divisor that should be applied to return values in order to get
13701 floating point values. For example:
13702 <tt>(double)returnData[returnDataIndices[0]+i] / returnScales[0]</tt>
13703 will retrieve the floating point value of i-th sample of the first
13704 metric.
13705 </desc>
13706 </param>
13707 <param name="returnSequenceNumbers" type="unsigned long" dir="out" safearray="yes">
13708 <desc>
13709 Sequence numbers of the first elements of value sequences of
13710 particular metrics returned in @c returnData. For aggregate metrics
13711 it is the sequence number of the sample the aggregate started
13712 calculation from.
13713 </desc>
13714 </param>
13715 <param name="returnDataIndices" type="unsigned long" dir="out" safearray="yes">
13716 <desc>
13717 Indices of the first elements of value sequences of particular
13718 metrics returned in @c returnData.
13719 </desc>
13720 </param>
13721 <param name="returnDataLengths" type="unsigned long" dir="out" safearray="yes">
13722 <desc>
13723 Lengths of value sequences of particular metrics.
13724 </desc>
13725 </param>
13726 <param name="returnData" type="long" dir="return" safearray="yes">
13727 <desc>
13728 Flattened array of all metric data containing sequences of values for
13729 each metric.
13730 </desc>
13731 </param>
13732 </method>
13733
13734 </interface>
13735 <enum
13736 name="NATAliasMode"
13737 uuid="67772168-50d9-11df-9669-7fb714ee4fa1">
13738 <desc></desc>
13739 <const name="AliasLog" value="0x1">
13740 <desc></desc>
13741 </const>
13742 <const name="AliasProxyOnly" value="0x02">
13743 <desc></desc>
13744 </const>
13745 <const name="AliasUseSamePorts" value="0x04">
13746 <desc></desc>
13747 </const>
13748 </enum>
13749 <enum
13750 name="NATProtocol"
13751 uuid="e90164be-eb03-11de-94af-fff9b1c1b19f"
13752 >
13753 <desc>Protocol definitions used with NAT port-forwarding rules.</desc>
13754 <const name="UDP" value="0">
13755 <desc>Port-forwarding uses UDP protocol.</desc>
13756 </const>
13757 <const name="TCP" value="1">
13758 <desc>Port-forwarding uses TCP protocol.</desc>
13759 </const>
13760 </enum>
13761
13762 <interface
13763 name="INATEngine" extends="$unknown"
13764 uuid="4b286616-eb03-11de-b0fb-1701eca42246"
13765 wsmap="managed"
13766 >
13767 <desc>Interface for managing a NAT engine which is used with a virtual machine. This
13768 allows for changing NAT behavior such as port-forwarding rules. This interface is
13769 used in the <link to="INetworkAdapter::natDriver" /> attribute.</desc>
13770 <attribute name="network" type="wstring">
13771 <desc>The network attribute of the NAT engine (the same value is used with built-in
13772 DHCP server to fill corresponding fields of DHCP leases).</desc>
13773 </attribute>
13774 <attribute name="hostIP" type="wstring">
13775 <desc>IP of host interface to bind all opened sockets to.
13776 <note>Changing this does not change binding of port forwarding.</note>
13777 </desc>
13778 </attribute>
13779 <attribute name="tftpPrefix" type="wstring">
13780 <desc>TFTP prefix attribute which is used with the built-in DHCP server to fill
13781 the corresponding fields of DHCP leases.</desc>
13782 </attribute>
13783 <attribute name="tftpBootFile" type="wstring">
13784 <desc>TFTP boot file attribute which is used with the built-in DHCP server to fill
13785 the corresponding fields of DHCP leases.</desc>
13786 </attribute>
13787 <attribute name="tftpNextServer" type="wstring">
13788 <desc>TFTP server attribute which is used with the built-in DHCP server to fill
13789 the corresponding fields of DHCP leases.
13790 <note>The preferred form is IPv4 addresses.</note>
13791 </desc>
13792 </attribute>
13793 <attribute name="aliasMode" type="unsigned long">
13794 <desc></desc>
13795 </attribute>
13796 <attribute name="dnsPassDomain" type="boolean">
13797 <desc>Whether the DHCP server should pass the DNS domain used by the host.</desc>
13798 </attribute>
13799 <attribute name="dnsProxy" type="boolean">
13800 <desc>Whether the DHCP server (and the DNS traffic by NAT) should pass the address
13801 of the DNS proxy and process traffic using DNS servers registered on the host.</desc>
13802 </attribute>
13803 <attribute name="dnsUseHostResolver" type="boolean">
13804 <desc>Whether the DHCP server (and the DNS traffic by NAT) should pass the address
13805 of the DNS proxy and process traffic using the host resolver mechanism.</desc>
13806 </attribute>
13807 <attribute name="redirects" type="wstring" readonly="yes" safearray="yes">
13808 <desc>Array of NAT port-forwarding rules in string representation, in the following
13809 format: "name,protocol id,host ip,host port,guest ip,guest port".</desc>
13810 </attribute>
13811 <method name="setNetworkSettings">
13812 <desc>Sets network configuration of the NAT engine.</desc>
13813 <param name="mtu" type="unsigned long" dir="in">
13814 <desc>MTU (maximum transmission unit) of the NAT engine in bytes.</desc>
13815 </param>
13816 <param name="sockSnd" type="unsigned long" dir="in">
13817 <desc>Capacity of the socket send buffer in bytes when creating a new socket.</desc>
13818 </param>
13819 <param name="sockRcv" type="unsigned long" dir="in">
13820 <desc>Capacity of the socket receive buffer in bytes when creating a new socket.</desc>
13821 </param>
13822 <param name="TcpWndSnd" type="unsigned long" dir="in">
13823 <desc>Initial size of the NAT engine's sending TCP window in bytes when
13824 establishing a new TCP connection.</desc>
13825 </param>
13826 <param name="TcpWndRcv" type="unsigned long" dir="in">
13827 <desc>Initial size of the NAT engine's receiving TCP window in bytes when
13828 establishing a new TCP connection.</desc>
13829 </param>
13830 </method>
13831 <method name="getNetworkSettings">
13832 <desc>Returns network configuration of NAT engine. See <link to="#setNetworkSettings" />
13833 for parameter descriptions.</desc>
13834 <param name="mtu" type="unsigned long" dir="out" />
13835 <param name="sockSnd" type="unsigned long" dir="out" />
13836 <param name="sockRcv" type="unsigned long" dir="out" />
13837 <param name="TcpWndSnd" type="unsigned long" dir="out" />
13838 <param name="TcpWndRcv" type="unsigned long" dir="out" />
13839 </method>
13840 <method name="addRedirect">
13841 <desc>Adds a new NAT port-forwarding rule.</desc>
13842 <param name="name" type="wstring" dir="in">
13843 <desc>The name of the rule. An empty name is acceptable, in which case the NAT engine
13844 auto-generates one using the other parameters.</desc>
13845 </param>
13846 <param name="proto" type="NATProtocol" dir="in">
13847 <desc>Protocol handled with the rule.</desc>
13848 </param>
13849 <param name="hostIp" type="wstring" dir="in">
13850 <desc>IP of the host interface to which the rule should apply. An empty ip address is
13851 acceptable, in which case the NAT engine binds the handling socket to any interface.</desc>
13852 </param>
13853 <param name="hostPort" type="unsigned short" dir="in">
13854 <desc>The port number to listen on.</desc>
13855 </param>
13856 <param name="guestIp" type="wstring" dir="in">
13857 <desc>The IP address of the guest which the NAT engine will forward matching packets
13858 to. An empty IP address is acceptable, in which case the NAT engine will forward
13859 packets to the first DHCP lease (x.x.x.15).</desc>
13860 </param>
13861 <param name="guestPort" type="unsigned short" dir="in">
13862 <desc>The port number to forward.</desc>
13863 </param>
13864 </method>
13865 <method name="removeRedirect">
13866 <desc>Removes a port-forwarding rule that was previously registered.</desc>
13867 <param name="name" type="wstring" dir="in">
13868 <desc>The name of the rule to delete.</desc>
13869 </param>
13870 </method>
13871 </interface>
13872
13873 <enum
13874 name="VBoxEventType"
13875 uuid="1728bb3b-4843-4f12-af67-f7a1f69f3a52">
13876
13877 <desc>
13878 Type of an event.
13879 See <link to="IEvent" /> for an introduction to VirtualBox event handling.
13880 </desc>
13881
13882 <const name="Invalid" value="0">
13883 <desc>
13884 Invalid event, must be first.
13885 </desc>
13886 </const>
13887
13888 <const name="Any" value="1">
13889 <desc>
13890 Wildcard for all events.
13891 Events of this type are never delivered, and only used in
13892 registerListener() call to simplify registration.
13893 </desc>
13894 </const>
13895
13896 <const name="Vetoable" value="2">
13897 <desc>
13898 Wildcard for all vetoable events. Events of this type are never delivered, and only
13899 used in registerListener() call to simplify registration.
13900 </desc>
13901 </const>
13902
13903 <const name="MachineEvent" value="3">
13904 <desc>
13905 Wildcard for all machine events. Events of this type are never delivered, and only used in
13906 registerListener() call to simplify registration.
13907 </desc>
13908 </const>
13909
13910 <const name="SnapshotEvent" value="4">
13911 <desc>
13912 Wildcard for all snapshot events. Events of this type are never delivered, and only used in
13913 registerListener() call to simplify registration.
13914 </desc>
13915 </const>
13916
13917 <const name="InputEvent" value="5">
13918 <desc>
13919 Wildcard for all input device (keyboard, mouse) events.
13920 Events of this type are never delivered, and only used in
13921 registerListener() call to simplify registration.
13922 </desc>
13923 </const>
13924
13925 <const name="LastWildcard" value="31">
13926 <desc>
13927 Last wildcard.
13928 </desc>
13929 </const>
13930
13931 <const name="OnMachineStateChanged" value="32">
13932 <desc>
13933 See <link to="IMachineStateChangedEvent">IMachineStateChangedEvent</link>.
13934 </desc>
13935 </const>
13936 <const name="OnMachineDataChanged" value="33">
13937 <desc>
13938 See <link to="IMachineDataChangedEvent">IMachineDataChangedEvent</link>.
13939 </desc>
13940 </const>
13941 <const name="OnExtraDataChanged" value="34">
13942 <desc>
13943 See <link to="IExtraDataChangedEvent">IExtraDataChangedEvent</link>.
13944 </desc>
13945 </const>
13946 <const name="OnExtraDataCanChange" value="35">
13947 <desc>
13948 See <link to="IExtraDataCanChangeEvent">IExtraDataCanChangeEvent</link>.
13949 </desc>
13950 </const>
13951 <const name="OnMediumRegistered" value="36">
13952 <desc>
13953 See <link to="IMediumRegisteredEvent">IMediumRegisteredEvent</link>.
13954 </desc>
13955 </const>
13956 <const name="OnMachineRegistered" value="37">
13957 <desc>
13958 See <link to="IMachineRegisteredEvent">IMachineRegisteredEvent</link>.
13959 </desc>
13960 </const>
13961 <const name="OnSessionStateChanged" value="38">
13962 <desc>
13963 See <link to="ISessionStateChangedEvent">ISessionStateChangedEvent</link>.
13964 </desc>
13965 </const>
13966 <const name="OnSnapshotTaken" value="39">
13967 <desc>
13968 See <link to="ISnapshotTakenEvent">ISnapshotTakenEvent</link>.
13969 </desc>
13970 </const>
13971 <const name="OnSnapshotDeleted" value="40">
13972 <desc>
13973 See <link to="ISnapshotDeletedEvent">ISnapshotDeletedEvent</link>.
13974 </desc>
13975 </const>
13976 <const name="OnSnapshotChanged" value="41">
13977 <desc>
13978 See <link to="ISnapshotChangedEvent">ISnapshotChangedEvent</link>.
13979 </desc>
13980 </const>
13981 <const name="OnGuestPropertyChanged" value="42">
13982 <desc>
13983 See <link to="IGuestPropertyChangedEvent">IGuestPropertyChangedEvent</link>.
13984 </desc>
13985 </const>
13986 <!-- Console events -->
13987 <const name="OnMousePointerShapeChanged" value="43">
13988 <desc>
13989 See <link to="IMousePointerShapeChangedEvent">IMousePointerShapeChangedEvent</link>.
13990 </desc>
13991 </const>
13992 <const name="OnMouseCapabilityChanged" value="44">
13993 <desc>
13994 See <link to="IMouseCapabilityChangedEvent">IMouseCapabilityChangedEvent</link>.
13995 </desc>
13996 </const>
13997 <const name="OnKeyboardLedsChanged" value="45">
13998 <desc>
13999 See <link to="IKeyboardLedsChangedEvent">IKeyboardLedsChangedEvent</link>.
14000 </desc>
14001 </const>
14002 <const name="OnStateChanged" value="46">
14003 <desc>
14004 See <link to="IStateChangedEvent">IStateChangedEvent</link>.
14005 </desc>
14006 </const>
14007 <const name="OnAdditionsStateChanged" value="47">
14008 <desc>
14009 See <link to="IAdditionsStateChangedEvent">IAdditionsStateChangedEvent</link>.
14010 </desc>
14011 </const>
14012 <const name="OnNetworkAdapterChanged" value="48">
14013 <desc>
14014 See <link to="INetworkAdapterChangedEvent">INetworkAdapterChangedEvent</link>.
14015 </desc>
14016 </const>
14017 <const name="OnSerialPortChanged" value="49">
14018 <desc>
14019 See <link to="ISerialPortChangedEvent">ISerialPortChangedEvent</link>.
14020 </desc>
14021 </const>
14022 <const name="OnParallelPortChanged" value="50">
14023 <desc>
14024 See <link to="IParallelPortChangedEvent">IParallelPortChangedEvent</link>.
14025 </desc>
14026 </const>
14027 <const name="OnStorageControllerChanged" value="51">
14028 <desc>
14029 See <link to="IStorageControllerChangedEvent">IStorageControllerChangedEvent</link>.
14030 </desc>
14031 </const>
14032 <const name="OnMediumChanged" value="52">
14033 <desc>
14034 See <link to="IMediumChangedEvent">IMediumChangedEvent</link>.
14035 </desc>
14036 </const>
14037 <const name="OnVRDPServerChanged" value="53">
14038 <desc>
14039 See <link to="IVRDPServerChangedEvent">IVRDPServerChangedEvent</link>.
14040 </desc>
14041 </const>
14042 <const name="OnUSBControllerChanged" value="54">
14043 <desc>
14044 See <link to="IUSBControllerChangedEvent">IUSBControllerChangedEvent</link>.
14045 </desc>
14046 </const>
14047 <const name="OnUSBDeviceStateChanged" value="55">
14048 <desc>
14049 See <link to="IUSBDeviceStateChangedEvent">IUSBDeviceStateChangedEvent</link>.
14050 </desc>
14051 </const>
14052 <const name="OnSharedFolderChanged" value="56">
14053 <desc>
14054 See <link to="ISharedFolderChangedEvent">ISharedFolderChangedEvent</link>.
14055 </desc>
14056 </const>
14057 <const name="OnRuntimeError" value="57">
14058 <desc>
14059 See <link to="IRuntimeErrorEvent">IRuntimeErrorEvent</link>.
14060 </desc>
14061 </const>
14062 <const name="OnCanShowWindow" value="58">
14063 <desc>
14064 See <link to="ICanShowWindowEvent">ICanShowWindowEvent</link>.
14065 </desc>
14066 </const>
14067 <const name="OnShowWindow" value="59">
14068 <desc>
14069 See <link to="IShowWindowEvent">IShowWindowEvent</link>.
14070 </desc>
14071 </const>
14072 <const name="OnCPUChanged" value="60">
14073 <desc>
14074 See <link to="ICPUChangedEvent">ICPUChangedEvent</link>.
14075 </desc>
14076 </const>
14077 <const name="OnRemoteDisplayInfoChanged" value="61">
14078 <desc>
14079 See <link to="IRemoteDisplayInfoChangedEvent">IRemoteDisplayInfoChangedEvent</link>.
14080 </desc>
14081 </const>
14082 <const name="OnEventSourceChanged" value="62">
14083 <desc>
14084 See <link to="IEventSourceChangedEvent">IEventSourceChangedEvent</link>.
14085 </desc>
14086 </const>
14087 <const name="OnCPUExecutionCapChanged" value="63">
14088 <desc>
14089 See <link to="ICPUExecutionCapChangedEvent">ICPUExecutionCapChangedEvent</link>.
14090 </desc>
14091 </const>
14092 <const name="OnGuestKeyboardEvent" value="64">
14093 <desc>
14094 See <link to="IGuestKeyboardEvent">IGuestKeyboardEvent</link>.
14095 </desc>
14096 </const>
14097 <const name="OnGuestMouseEvent" value="65">
14098 <desc>
14099 See <link to="IGuestMouseEvent">IGuestMouseEvent</link>.
14100 </desc>
14101 </const>
14102 <!-- Last event marker -->
14103 <const name="Last" value="66">
14104 <desc>
14105 Must be last event, used for iterations and structures relying on numerical event values.
14106 </desc>
14107 </const>
14108
14109 </enum>
14110
14111 <interface
14112 name="IEventSource" extends="$unknown"
14113 uuid="3c670618-f727-4fe9-94d2-8243f489a033"
14114 wsmap="managed"
14115 >
14116 <desc>
14117 Event source. Generally, any object which could generate events can be an event source,
14118 or aggregate one. To simplify using one-way protocols such as webservices running on top of HTTP(S),
14119 an event source can work with listeners in either active or passive mode. In active mode it is up to
14120 the IEventSource implementation to call <link to="IEventListener::handleEvent" />, in passive mode the
14121 event source keeps track of pending events for each listener and returns available events on demand.
14122
14123 See <link to="IEvent" /> for an introduction to VirtualBox event handling.
14124 </desc>
14125
14126 <method name="createListener">
14127 <desc>
14128 Creates a new listener object, useful for passive mode.
14129 </desc>
14130 <param name="listener" type="IEventListener" dir="return"/>
14131 </method>
14132
14133 <method name="registerListener">
14134 <desc>
14135 Register an event listener.
14136
14137 <note>
14138 To avoid system overload, the VirtualBox server process checks if passive event
14139 listeners call <link to="IEventSource::getEvent"/> frequently enough. In the
14140 current implementation, if more than 100 pending events are detected for a passive
14141 event listener, it is forcefully unregistered by the system, and further
14142 <link to="#getEvent" /> calls will return @c VBOX_E_OBJECT_NOT_FOUND.
14143 </note>
14144 </desc>
14145 <param name="listener" type="IEventListener" dir="in">
14146 <desc>Listener to register.</desc>
14147 </param>
14148 <param name="interesting" type="VBoxEventType" dir="in" safearray="yes">
14149 <desc>
14150 Event types listener is interested in. One can use wildcards like -
14151 <link to="VBoxEventType_Any"/> to specify wildcards, matching more
14152 than one event.
14153 </desc>
14154 </param>
14155 <param name="active" type="boolean" dir="in">
14156 <desc>
14157 Which mode this listener is operating in.
14158 In active mode, <link to="IEventListener::handleEvent" /> is called directly.
14159 In passive mode, an internal event queue is created for this this IEventListener.
14160 For each event coming in, it is added to queues for all interested registered passive
14161 listeners. It is then up to the external code to call the listener's
14162 <link to="IEventListener::handleEvent" /> method. When done with an event, the
14163 external code must call <link to="#eventProcessed" />.
14164 </desc>
14165 </param>
14166 </method>
14167
14168 <method name="unregisterListener">
14169 <desc>
14170 Unregister an event listener. If listener is passive, and some waitable events are still
14171 in queue they are marked as processed automatically.
14172 </desc>
14173 <param name="listener" type="IEventListener" dir="in">
14174 <desc>Listener to unregister.</desc>
14175 </param>
14176 </method>
14177
14178 <method name="fireEvent">
14179 <desc>
14180 Fire an event for this source.
14181 </desc>
14182 <param name="event" type="IEvent" dir="in">
14183 <desc>Event to deliver.</desc>
14184 </param>
14185 <param name="timeout" type="long" dir="in">
14186 <desc>
14187 Maximum time to wait for event processing (if event is waitable), in ms;
14188 0 = no wait, -1 = indefinite wait.
14189 </desc>
14190 </param>
14191 <param name="result" type="boolean" dir="return">
14192 <desc>true if an event was delivered to all targets, or is non-waitable.</desc>
14193 </param>
14194 </method>
14195
14196 <method name="getEvent">
14197 <desc>
14198 Get events from this peer's event queue (for passive mode). Calling this method
14199 regularly is required for passive event listeners to avoid system overload;
14200 see <link to="IEventSource::registerListener" /> for details.
14201
14202 <result name="VBOX_E_OBJECT_NOT_FOUND">
14203 Listener is not registered, or autounregistered.
14204 </result>
14205 </desc>
14206 <param name="listener" type="IEventListener" dir="in">
14207 <desc>Which listener to get data for.</desc>
14208 </param>
14209 <param name="timeout" type="long" dir="in">
14210 <desc>
14211 Maximum time to wait for events, in ms;
14212 0 = no wait, -1 = indefinite wait.
14213 </desc>
14214 </param>
14215 <param name="event" type="IEvent" dir="return">
14216 <desc>Event retrieved, or null if none available.</desc>
14217 </param>
14218 </method>
14219
14220 <method name="eventProcessed">
14221 <desc>
14222 Must be called for waitable events after a particular listener finished its
14223 event processing. When all listeners of a particular event have called this
14224 method, the system will then call <link to="IEvent::setProcessed" />.
14225 </desc>
14226 <param name="listener" type="IEventListener" dir="in">
14227 <desc>Which listener processed event.</desc>
14228 </param>
14229 <param name="event" type="IEvent" dir="in">
14230 <desc>Which event.</desc>
14231 </param>
14232 </method>
14233
14234 </interface>
14235
14236 <interface
14237 name="IEventListener" extends="$unknown"
14238 uuid="67099191-32e7-4f6c-85ee-422304c71b90"
14239 wsmap="managed"
14240 >
14241 <desc>
14242 Event listener. An event listener can work in either active or passive mode, depending on the way
14243 it was registered.
14244 See <link to="IEvent" /> for an introduction to VirtualBox event handling.
14245 </desc>
14246
14247 <method name="handleEvent">
14248 <desc>
14249 Handle event callback (called directly by IEventSource in active mode, or could be
14250 called by event processor thread in passive mode).
14251 </desc>
14252 <param name="event" type="IEvent" dir="in">
14253 <desc>Event available.</desc>
14254 </param>
14255 </method>
14256
14257 </interface>
14258
14259 <interface
14260 name="IEvent" extends="$unknown"
14261 uuid="0ca2adba-8f30-401b-a8cd-fe31dbe839c0"
14262 wsmap="managed"
14263 >
14264 <desc>
14265 Abstract parent interface for VirtualBox events. Actual events will typically implement
14266 a more specific interface which derives from this (see below).
14267
14268 <b>Introduction to VirtualBox events</b>
14269
14270 Generally speaking, an event (represented by this interface) signals that something
14271 happened, while an event listener (see <link to="IEventListener" />) represents an
14272 entity that is interested in certain events. In order for this to work with
14273 unidirectional protocols (i.e. web services), the concepts of passive and active
14274 listener are used.
14275
14276 Event consumers can register themselves as listeners, providing an array of
14277 events they are interested in (see <link to="IEventSource::registerListener" />).
14278 When an event triggers, the listener is notified about the event. The exact
14279 mechanism of the notification depends on whether the listener was registered as
14280 an active or passive listener:
14281
14282 <ul>
14283 <li>An active listener is very similar to a callback: it is a function invoked
14284 by the API. As opposed to the callbacks that were used in the API before
14285 VirtualBox 3.3 however, events are now objects with an interface hierarchy.
14286 </li>
14287
14288 <li>Passive listeners are somewhat tricker to implement, but do not require
14289 a client function to be callable, which is not an option with scripting
14290 languages or web service clients. Internally the <link to="IEventSource" />
14291 implementation maintains an event queue for each passive listener, and
14292 newly arrived events are put in this queue. When the listener calls
14293 <link to="IEventSource::getEvent"/>, first element from its internal event
14294 queue is returned. When the client completes processing of an event,
14295 the <link to="IEventSource::eventProcessed" /> function must be called,
14296 acknowledging that the event was processed. It supports implementing
14297 waitable events. On passive listener unregistration, all events from its
14298 queue are auto-acknowledged.
14299 </li>
14300 </ul>
14301
14302 Waitable events are useful in situations where the event generator wants to track
14303 delivery or a party wants to wait until all listeners have completed the event. A
14304 typical example would be a vetoable event (see <link to="IVetoEvent" />) where a
14305 listeners might veto a certain action, and thus the event producer has to make
14306 sure that all listeners have processed the event and not vetoed before taking
14307 the action.
14308
14309 A given event may have both passive and active listeners at the same time.
14310
14311 <b>Using events</b>
14312
14313 Any VirtualBox object capable of producing externally visible events provides an
14314 @c eventSource read-only attribute, which is of the type <link to="IEventSource" />.
14315 This event source object is notified by VirtualBox once something has happened, so
14316 consumers may register event listeners with this event source. To register a listener,
14317 an object implementing the <link to="IEventListener" /> interface must be provided.
14318 For active listeners, such an object is typically created by the consumer, while for
14319 passive listeners <link to="IEventSource::createListener" /> should be used. Please
14320 note that a listener created with @c createListener() must not be used as an active listener.
14321
14322 Once created, the listener must be registered to listen for the desired events
14323 (see <link to="IEventSource::registerListener" />), providing an array of
14324 <link to="VBoxEventType" /> enums. Those elements can either be the individual
14325 event IDs or wildcards matching multiple event IDs.
14326
14327 After registration, the callback's <link to="IEventListener::handleEvent" /> method is
14328 called automatically when the event is triggered, while passive listeners have to call
14329 <link to="IEventSource::getEvent" /> and <link to="IEventSource::eventProcessed" /> in
14330 an event processing loop.
14331
14332 The IEvent interface is an abstract parent interface for all such VirtualBox events
14333 coming in. As a result, the standard use pattern inside <link to="IEventListener::handleEvent" />
14334 or the event processing loop is to check the <link to="#type" /> attribute of the event and
14335 then cast to the appropriate specific interface using @c QueryInterface().
14336 </desc>
14337
14338 <attribute name="type" readonly="yes" type="VBoxEventType">
14339 <desc>
14340 Event type.
14341 </desc>
14342 </attribute>
14343
14344 <attribute name="source" readonly="yes" type="IEventSource">
14345 <desc>
14346 Source of this event.
14347 </desc>
14348 </attribute>
14349
14350 <attribute name="waitable" readonly="yes" type="boolean">
14351 <desc>
14352 If we can wait for this event being processed. If false, waitProcessed() returns immediately,
14353 and setProcessed() doesn't make sense. Non-waitable events are generally better performing,
14354 as no additional overhead associated with waitability imposed.
14355 Waitable events are needed when one need to be able to wait for particular event processed,
14356 for example for vetoable changes, or if event refers to some resource which need to be kept immutable
14357 until all consumers confirmed events.
14358 </desc>
14359 </attribute>
14360
14361 <method name="setProcessed">
14362 <desc>
14363 Internal method called by the system when all listeners of a particular event have called
14364 <link to="IEventSource::eventProcessed" />. This should not be called by client code.
14365 </desc>
14366 </method>
14367
14368 <method name="waitProcessed">
14369 <desc>
14370 Wait until time outs, or this event is processed. Event must be waitable for this operation to have
14371 described semantics, for non-waitable returns true immediately.
14372 </desc>
14373 <param name="timeout" type="long" dir="in">
14374 <desc>
14375 Maximum time to wait for event processeing, in ms;
14376 0 = no wait, -1 = indefinite wait.
14377 </desc>
14378 </param>
14379 <param name="result" type="boolean" dir="return">
14380 <desc>If this event was processed before timeout.</desc>
14381 </param>
14382 </method>
14383 </interface>
14384
14385
14386 <interface
14387 name="IReusableEvent" extends="IEvent"
14388 uuid="69bfb134-80f6-4266-8e20-16371f68fa25"
14389 wsmap="managed"
14390 >
14391 <desc>Base abstract interface for all reusable events.</desc>
14392
14393 <attribute name="generation" readonly="yes" type="unsigned long">
14394 <desc>Current generation of event, incremented on reuse.</desc>
14395 </attribute>
14396
14397 <method name="reuse">
14398 <desc>
14399 Marks an event as reused, increments 'generation', fields shall no
14400 longer be considered valid.
14401 </desc>
14402 </method>
14403 </interface>
14404
14405 <interface
14406 name="IMachineEvent" extends="IEvent"
14407 uuid="92ed7b1a-0d96-40ed-ae46-a564d484325e"
14408 wsmap="managed" id="MachineEvent"
14409 >
14410 <desc>Base abstract interface for all machine events.</desc>
14411
14412 <attribute name="machineId" readonly="yes" type="uuid" mod="string">
14413 <desc>ID of the machine this event relates to.</desc>
14414 </attribute>
14415
14416 </interface>
14417
14418 <interface
14419 name="IMachineStateChangedEvent" extends="IMachineEvent"
14420 uuid="5748F794-48DF-438D-85EB-98FFD70D18C9"
14421 wsmap="managed" autogen="VBoxEvent" id="OnMachineStateChanged"
14422 >
14423 <desc>Machine state change event.</desc>
14424
14425 <attribute name="state" readonly="yes" type="MachineState">
14426 <desc>New execution state.</desc>
14427 </attribute>
14428 </interface>
14429
14430 <interface
14431 name="IMachineDataChangedEvent" extends="IMachineEvent"
14432 uuid="6AA70A6C-0DCA-4810-8C5C-457B278E3D49"
14433 wsmap="managed" autogen="VBoxEvent" id="OnMachineDataChanged"
14434 >
14435 <desc>
14436 Any of the settings of the given machine has changed.
14437 </desc>
14438 </interface>
14439
14440 <interface
14441 name="IMediumRegisteredEvent" extends="IEvent"
14442 uuid="53fac49a-b7f1-4a5a-a4ef-a11dd9c2a458"
14443 wsmap="managed" autogen="VBoxEvent" id="OnMediumRegistered"
14444 >
14445 <desc>
14446 The given medium was registered or unregistered
14447 within this VirtualBox installation.
14448 </desc>
14449
14450 <attribute name="mediumId" readonly="yes" type="uuid" mod="string">
14451 <desc>ID of the medium this event relates to.</desc>
14452 </attribute>
14453
14454 <attribute name="mediumType" readonly="yes" type="DeviceType">
14455 <desc>Type of the medium this event relates to.</desc>
14456 </attribute>
14457
14458 <attribute name="registered" type="boolean" readonly="yes">
14459 <desc>
14460 If @c true, the medium was registered, otherwise it was
14461 unregistered.
14462 </desc>
14463 </attribute>
14464 </interface>
14465
14466 <interface
14467 name="IMachineRegisteredEvent" extends="IMachineEvent"
14468 uuid="c354a762-3ff2-4f2e-8f09-07382ee25088"
14469 wsmap="managed" autogen="VBoxEvent" id="OnMachineRegistered"
14470 >
14471 <desc>
14472 The given machine was registered or unregistered
14473 within this VirtualBox installation.
14474 </desc>
14475
14476 <attribute name="registered" type="boolean" readonly="yes">
14477 <desc>
14478 If @c true, the machine was registered, otherwise it was
14479 unregistered.
14480 </desc>
14481 </attribute>
14482 </interface>
14483
14484 <interface
14485 name="ISessionStateChangedEvent" extends="IMachineEvent"
14486 uuid="714a3eef-799a-4489-86cd-fe8e45b2ff8e"
14487 wsmap="managed" autogen="VBoxEvent" id="OnSessionStateChanged"
14488 >
14489 <desc>
14490 The state of the session for the given machine was changed.
14491 <see>IMachine::sessionState</see>
14492 </desc>
14493
14494 <attribute name="state" type="SessionState" readonly="yes">
14495 <desc>
14496 New session state.
14497 </desc>
14498 </attribute>
14499 </interface>
14500
14501 <interface
14502 name="IGuestPropertyChangedEvent" extends="IMachineEvent"
14503 uuid="3f63597a-26f1-4edb-8dd2-6bddd0912368"
14504 wsmap="managed" autogen="VBoxEvent" id="OnGuestPropertyChanged"
14505 >
14506 <desc>
14507 Notification when a guest property has changed.
14508 </desc>
14509
14510 <attribute name="name" readonly="yes" type="wstring">
14511 <desc>
14512 The name of the property that has changed.
14513 </desc>
14514 </attribute>
14515
14516 <attribute name="value" readonly="yes" type="wstring">
14517 <desc>
14518 The new property value.
14519 </desc>
14520 </attribute>
14521
14522 <attribute name="flags" readonly="yes" type="wstring">
14523 <desc>
14524 The new property flags.
14525 </desc>
14526 </attribute>
14527
14528 </interface>
14529
14530 <interface
14531 name="ISnapshotEvent" extends="IMachineEvent"
14532 uuid="21637b0e-34b8-42d3-acfb-7e96daf77c22"
14533 wsmap="managed" id="SnapshotEvent"
14534 >
14535 <desc>Base interface for all snapshot events.</desc>
14536
14537 <attribute name="snapshotId" readonly="yes" type="uuid" mod="string">
14538 <desc>ID of the snapshot this event relates to.</desc>
14539 </attribute>
14540
14541 </interface>
14542
14543 <interface
14544 name="ISnapshotTakenEvent" extends="ISnapshotEvent"
14545 uuid="d27c0b3d-6038-422c-b45e-6d4a0503d9f1"
14546 wsmap="managed" autogen="VBoxEvent" id="OnSnapshotTaken"
14547 >
14548 <desc>
14549 A new snapshot of the machine has been taken.
14550 <see>ISnapshot</see>
14551 </desc>
14552 </interface>
14553
14554 <interface
14555 name="ISnapshotDeletedEvent" extends="ISnapshotEvent"
14556 uuid="c48f3401-4a9e-43f4-b7a7-54bd285e22f4"
14557 wsmap="managed" autogen="VBoxEvent" id="OnSnapshotDeleted"
14558 >
14559 <desc>
14560 Snapshot of the given machine has been deleted.
14561
14562 <note>
14563 This notification is delivered <b>after</b> the snapshot
14564 object has been uninitialized on the server (so that any
14565 attempt to call its methods will return an error).
14566 </note>
14567
14568 <see>ISnapshot</see>
14569 </desc>
14570 </interface>
14571
14572 <interface
14573 name="ISnapshotChangedEvent" extends="ISnapshotEvent"
14574 uuid="07541941-8079-447a-a33e-47a69c7980db"
14575 wsmap="managed" autogen="VBoxEvent" id="OnSnapshotChanged"
14576 >
14577 <desc>
14578 Snapshot properties (name and/or description) have been changed.
14579 <see>ISnapshot</see>
14580 </desc>
14581 </interface>
14582
14583 <interface
14584 name="IMousePointerShapeChangedEvent" extends="IEvent"
14585 uuid="a6dcf6e8-416b-4181-8c4a-45ec95177aef"
14586 wsmap="managed" autogen="VBoxEvent" id="OnMousePointerShapeChanged"
14587 >
14588 <desc>
14589 Notification when the guest mouse pointer shape has
14590 changed. The new shape data is given.
14591 </desc>
14592
14593 <attribute name="visible" type="boolean" readonly="yes">
14594 <desc>
14595 Flag whether the pointer is visible.
14596 </desc>
14597 </attribute>
14598 <attribute name="alpha" type="boolean" readonly="yes">
14599 <desc>
14600 Flag whether the pointer has an alpha channel.
14601 </desc>
14602 </attribute>
14603 <attribute name="xhot" type="unsigned long" readonly="yes">
14604 <desc>
14605 The pointer hot spot X coordinate.
14606 </desc>
14607 </attribute>
14608 <attribute name="yhot" type="unsigned long" readonly="yes">
14609 <desc>
14610 The pointer hot spot Y coordinate.
14611 </desc>
14612 </attribute>
14613 <attribute name="width" type="unsigned long" readonly="yes">
14614 <desc>
14615 Width of the pointer shape in pixels.
14616 </desc>
14617 </attribute>
14618 <attribute name="height" type="unsigned long" readonly="yes">
14619 <desc>
14620 Height of the pointer shape in pixels.
14621 </desc>
14622 </attribute>
14623 <attribute name="shape" type="octet" safearray="yes" readonly="yes">
14624 <desc>
14625 Shape buffer arrays.
14626
14627 The @a shape buffer contains a 1-bpp (bits per pixel) AND mask
14628 followed by a 32-bpp XOR (color) mask.
14629
14630 For pointers without alpha channel the XOR mask pixels are 32
14631 bit values: (lsb)BGR0(msb). For pointers with alpha channel
14632 the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
14633
14634 An AND mask is used for pointers with alpha channel, so if the
14635 callback does not support alpha, the pointer could be
14636 displayed as a normal color pointer.
14637
14638 The AND mask is a 1-bpp bitmap with byte aligned scanlines. The
14639 size of the AND mask therefore is <tt>cbAnd = (width + 7) / 8 *
14640 height</tt>. The padding bits at the end of each scanline are
14641 undefined.
14642
14643 The XOR mask follows the AND mask on the next 4-byte aligned
14644 offset: <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>.
14645 Bytes in the gap between the AND and the XOR mask are undefined.
14646 The XOR mask scanlines have no gap between them and the size of
14647 the XOR mask is: <tt>cXor = width * 4 * height</tt>.
14648
14649 <note>
14650 If @a shape is 0, only the pointer visibility is changed.
14651 </note>
14652 </desc>
14653 </attribute>
14654 </interface>
14655
14656 <interface
14657 name="IMouseCapabilityChangedEvent" extends="IEvent"
14658 uuid="d633ad48-820c-4207-b46c-6bd3596640d5"
14659 wsmap="managed" autogen="VBoxEvent" id="OnMouseCapabilityChanged"
14660 >
14661 <desc>
14662 Notification when the mouse capabilities reported by the
14663 guest have changed. The new capabilities are passed.
14664 </desc>
14665 <attribute name="supportsAbsolute" type="boolean" readonly="yes">
14666 <desc>
14667 Supports absolute coordinates.
14668 </desc>
14669 </attribute>
14670 <attribute name="supportsRelative" type="boolean" readonly="yes">
14671 <desc>
14672 Supports relative coordinates.
14673 </desc>
14674 </attribute>
14675 <attribute name="needsHostCursor" type="boolean" readonly="yes">
14676 <desc>
14677 If host cursor is needed.
14678 </desc>
14679 </attribute>
14680 </interface>
14681
14682 <interface
14683 name="IKeyboardLedsChangedEvent" extends="IEvent"
14684 uuid="6DDEF35E-4737-457B-99FC-BC52C851A44F"
14685 wsmap="managed" autogen="VBoxEvent" id="OnKeyboardLedsChanged"
14686 >
14687 <desc>
14688 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
14689 to alter the state of the keyboard LEDs.
14690 </desc>
14691 <attribute name="numLock" type="boolean" readonly="yes">
14692 <desc>
14693 NumLock status.
14694 </desc>
14695 </attribute>
14696 <attribute name="capsLock" type="boolean" readonly="yes">
14697 <desc>
14698 CapsLock status.
14699 </desc>
14700 </attribute>
14701 <attribute name="scrollLock" type="boolean" readonly="yes">
14702 <desc>
14703 ScrollLock status.
14704 </desc>
14705 </attribute>
14706 </interface>
14707
14708 <interface
14709 name="IStateChangedEvent" extends="IEvent"
14710 uuid="4376693C-CF37-453B-9289-3B0F521CAF27"
14711 wsmap="managed" autogen="VBoxEvent" id="OnStateChanged"
14712 >
14713 <desc>
14714 Notification when the execution state of the machine has changed.
14715 The new state is given.
14716 </desc>
14717 <attribute name="state" type="MachineState" readonly="yes">
14718 <desc>
14719 New machine state.
14720 </desc>
14721 </attribute>
14722 </interface>
14723
14724 <interface
14725 name="IAdditionsStateChangedEvent" extends="IEvent"
14726 uuid="D70F7915-DA7C-44C8-A7AC-9F173490446A"
14727 wsmap="managed" autogen="VBoxEvent" id="OnAdditionsStateChanged"
14728 >
14729 <desc>
14730 Notification when a Guest Additions property changes.
14731 Interested callees should query IGuest attributes to
14732 find out what has changed.
14733 </desc>
14734 </interface>
14735
14736 <interface
14737 name="INetworkAdapterChangedEvent" extends="IEvent"
14738 uuid="08889892-1EC6-4883-801D-77F56CFD0103"
14739 wsmap="managed" autogen="VBoxEvent" id="OnNetworkAdapterChanged"
14740 >
14741 <desc>
14742 Notification when a property of one of the
14743 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
14744 changes. Interested callees should use INetworkAdapter methods and
14745 attributes to find out what has changed.
14746 </desc>
14747 <attribute name="networkAdapter" type="INetworkAdapter" readonly="yes">
14748 <desc>
14749 Network adapter that is subject to change.
14750 </desc>
14751 </attribute>
14752 </interface>
14753
14754 <interface
14755 name="ISerialPortChangedEvent" extends="IEvent"
14756 uuid="3BA329DC-659C-488B-835C-4ECA7AE71C6C"
14757 wsmap="managed" autogen="VBoxEvent" id="OnSerialPortChanged"
14758 >
14759 <desc>
14760 Notification when a property of one of the
14761 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
14762 Interested callees should use ISerialPort methods and attributes
14763 to find out what has changed.
14764 </desc>
14765 <attribute name="serialPort" type="ISerialPort" readonly="yes">
14766 <desc>
14767 Serial port that is subject to change.
14768 </desc>
14769 </attribute>
14770 </interface>
14771
14772 <interface
14773 name="IParallelPortChangedEvent" extends="IEvent"
14774 uuid="813C99FC-9849-4F47-813E-24A75DC85615"
14775 wsmap="managed" autogen="VBoxEvent" id="OnParallelPortChanged"
14776 >
14777 <desc>
14778 Notification when a property of one of the
14779 virtual <link to="IMachine::getParallelPort">parallel ports</link>
14780 changes. Interested callees should use ISerialPort methods and
14781 attributes to find out what has changed.
14782 </desc>
14783 <attribute name="parallelPort" type="IParallelPort" readonly="yes">
14784 <desc>
14785 Parallel port that is subject to change.
14786 </desc>
14787 </attribute>
14788 </interface>
14789
14790 <interface
14791 name="IStorageControllerChangedEvent" extends="IEvent"
14792 uuid="715212BF-DA59-426E-8230-3831FAA52C56"
14793 wsmap="managed" autogen="VBoxEvent" id="OnStorageControllerChanged"
14794 >
14795 <desc>
14796 Notification when a
14797 <link to="IMachine::mediumAttachments">medium attachment</link>
14798 changes.
14799 </desc>
14800 </interface>
14801
14802 <interface
14803 name="IMediumChangedEvent" extends="IEvent"
14804 uuid="0FE2DA40-5637-472A-9736-72019EABD7DE"
14805 wsmap="managed" autogen="VBoxEvent" id="OnMediumChanged"
14806 >
14807 <desc>
14808 Notification when a
14809 <link to="IMachine::mediumAttachments">medium attachment</link>
14810 changes.
14811 </desc>
14812 <attribute name="mediumAttachment" type="IMediumAttachment" readonly="yes">
14813 <desc>
14814 Medium attachment that is subject to change.
14815 </desc>
14816 </attribute>
14817 </interface>
14818
14819 <interface
14820 name="ICPUChangedEvent" extends="IEvent"
14821 uuid="D0F0BECC-EE17-4D17-A8CC-383B0EB55E9D"
14822 wsmap="managed" autogen="VBoxEvent" id="OnCPUChanged"
14823 >
14824 <desc>
14825 Notification when a CPU changes.
14826 </desc>
14827 <attribute name="cpu" type="unsigned long" readonly="yes">
14828 <desc>
14829 The CPU which changed.
14830 </desc>
14831 </attribute>
14832 <attribute name="add" type="boolean" readonly="yes">
14833 <desc>
14834 Flag whether the CPU was added or removed.
14835 </desc>
14836 </attribute>
14837 </interface>
14838
14839 <interface
14840 name="ICPUExecutionCapChangedEvent" extends="IEvent"
14841 uuid="dfa7e4f5-b4a4-44ce-85a8-127ac5eb59dc"
14842 wsmap="managed" autogen="VBoxEvent" id="OnCPUExecutionCapChanged"
14843 >
14844 <desc>
14845 Notification when the CPU execution cap changes.
14846 </desc>
14847 <attribute name="executionCap" type="unsigned long" readonly="yes">
14848 <desc>
14849 The new CPU execution cap value. (1-100)
14850 </desc>
14851 </attribute>
14852 </interface>
14853
14854 <interface
14855 name="IGuestKeyboardEvent" extends="IEvent"
14856 uuid="88394258-7006-40d4-b339-472ee3801844"
14857 wsmap="managed" autogen="VBoxEvent" id="OnGuestKeyboardEvent"
14858 >
14859 <desc>
14860 Notification when guest keyboard event happens.
14861 </desc>
14862 <attribute name="scancodes" type="long" safearray="yes" readonly="yes">
14863 <desc>
14864 Array of scancodes.
14865 </desc>
14866 </attribute>
14867 </interface>
14868
14869 <interface
14870 name="IGuestMouseEvent" extends="IReusableEvent"
14871 uuid="1f85d35c-c524-40ff-8e98-307000df0992"
14872 wsmap="managed" autogen="VBoxEvent" id="OnGuestMouseEvent"
14873 >
14874 <desc>
14875 Notification when guest mouse event happens.
14876 </desc>
14877
14878 <attribute name="absolute" type="boolean" readonly="yes">
14879 <desc>
14880 If this event is relative or absolute.
14881 </desc>
14882 </attribute>
14883
14884 <attribute name="x" type="long" readonly="yes">
14885 <desc>
14886 New X position, or X delta.
14887 </desc>
14888 </attribute>
14889
14890 <attribute name="y" type="long" readonly="yes">
14891 <desc>
14892 New Y position, or Y delta.
14893 </desc>
14894 </attribute>
14895
14896 <attribute name="z" type="long" readonly="yes">
14897 <desc>
14898 Z delta.
14899 </desc>
14900 </attribute>
14901
14902 <attribute name="w" type="long" readonly="yes">
14903 <desc>
14904 W delta.
14905 </desc>
14906 </attribute>
14907
14908 <attribute name="buttons" type="long" readonly="yes">
14909 <desc>
14910 Button state bitmask.
14911 </desc>
14912 </attribute>
14913
14914 </interface>
14915
14916
14917 <interface
14918 name="IVRDPServerChangedEvent" extends="IEvent"
14919 uuid="726038B6-6279-4A7A-8037-D041693D1915"
14920 wsmap="managed" autogen="VBoxEvent" id="OnVRDPServerChanged"
14921 >
14922 <desc>
14923 Notification when a property of the
14924 <link to="IMachine::VRDPServer">VRDP server</link> changes.
14925 Interested callees should use IVRDPServer methods and attributes to
14926 find out what has changed.
14927 </desc>
14928 </interface>
14929
14930 <interface
14931 name="IRemoteDisplayInfoChangedEvent" extends="IEvent"
14932 uuid="65B556C5-2A99-47D8-B311-FC177F0914CD"
14933 wsmap="managed" autogen="VBoxEvent" id="OnRemoteDisplayInfoChanged"
14934 >
14935 <desc>
14936 Notification when the status of the VRDP server changes. Interested callees
14937 should use <link to="IConsole::remoteDisplayInfo">IRemoteDisplayInfo</link>
14938 attributes to find out what is the current status.
14939 </desc>
14940 </interface>
14941
14942 <interface
14943 name="IUSBControllerChangedEvent" extends="IEvent"
14944 uuid="93BADC0C-61D9-4940-A084-E6BB29AF3D83"
14945 wsmap="managed" autogen="VBoxEvent" id="OnUSBControllerChanged"
14946 >
14947 <desc>
14948 Notification when a property of the virtual
14949 <link to="IMachine::USBController">USB controller</link> changes.
14950 Interested callees should use IUSBController methods and attributes to
14951 find out what has changed.
14952 </desc>
14953 </interface>
14954
14955 <interface
14956 name="IUSBDeviceStateChangedEvent" extends="IEvent"
14957 uuid="806da61b-6679-422a-b629-51b06b0c6d93"
14958 wsmap="managed" autogen="VBoxEvent" id="OnUSBDeviceStateChanged"
14959 >
14960 <desc>
14961 Notification when a USB device is attached to or detached from
14962 the virtual USB controller.
14963
14964 This notification is sent as a result of the indirect
14965 request to attach the device because it matches one of the
14966 machine USB filters, or as a result of the direct request
14967 issued by <link to="IConsole::attachUSBDevice"/> or
14968 <link to="IConsole::detachUSBDevice"/>.
14969
14970 This notification is sent in case of both a succeeded and a
14971 failed request completion. When the request succeeds, the
14972 @a error parameter is @c null, and the given device has been
14973 already added to (when @a attached is @c true) or removed from
14974 (when @a attached is @c false) the collection represented by
14975 <link to="IConsole::USBDevices"/>. On failure, the collection
14976 doesn't change and the @a error parameter represents the error
14977 message describing the failure.
14978 </desc>
14979 <attribute name="device" type="IUSBDevice" readonly="yes">
14980 <desc>
14981 Device that is subject to state change.
14982 </desc>
14983 </attribute>
14984 <attribute name="attached" type="boolean" readonly="yes">
14985 <desc>
14986 @c true if the device was attached and @c false otherwise.
14987 </desc>
14988 </attribute>
14989 <attribute name="error" type="IVirtualBoxErrorInfo" readonly="yes">
14990 <desc>
14991 @c null on success or an error message object on failure.
14992 </desc>
14993 </attribute>
14994 </interface>
14995
14996 <interface
14997 name="ISharedFolderChangedEvent" extends="IEvent"
14998 uuid="B66349B5-3534-4239-B2DE-8E1535D94C0B"
14999 wsmap="managed" autogen="VBoxEvent" id="OnSharedFolderChanged"
15000 >
15001 <desc>
15002 Notification when a shared folder is added or removed.
15003 The @a scope argument defines one of three scopes:
15004 <link to="IVirtualBox::sharedFolders">global shared folders</link>
15005 (<link to="Scope_Global">Global</link>),
15006 <link to="IMachine::sharedFolders">permanent shared folders</link> of
15007 the machine (<link to="Scope_Machine">Machine</link>) or <link
15008 to="IConsole::sharedFolders">transient shared folders</link> of the
15009 machine (<link to="Scope_Session">Session</link>). Interested callees
15010 should use query the corresponding collections to find out what has
15011 changed.
15012 </desc>
15013 <attribute name="scope" type="Scope" readonly="yes">
15014 <desc>
15015 Scope of the notification.
15016 </desc>
15017 </attribute>
15018 </interface>
15019
15020 <interface
15021 name="IRuntimeErrorEvent" extends="IEvent"
15022 uuid="883DD18B-0721-4CDE-867C-1A82ABAF914C"
15023 wsmap="managed" autogen="VBoxEvent" id="OnRuntimeError"
15024 >
15025 <desc>
15026 Notification when an error happens during the virtual
15027 machine execution.
15028
15029 There are three kinds of runtime errors:
15030 <ul>
15031 <li><i>fatal</i></li>
15032 <li><i>non-fatal with retry</i></li>
15033 <li><i>non-fatal warnings</i></li>
15034 </ul>
15035
15036 <b>Fatal</b> errors are indicated by the @a fatal parameter set
15037 to @c true. In case of fatal errors, the virtual machine
15038 execution is always paused before calling this notification, and
15039 the notification handler is supposed either to immediately save
15040 the virtual machine state using <link to="IConsole::saveState"/>
15041 or power it off using <link to="IConsole::powerDown"/>.
15042 Resuming the execution can lead to unpredictable results.
15043
15044 <b>Non-fatal</b> errors and warnings are indicated by the
15045 @a fatal parameter set to @c false. If the virtual machine
15046 is in the Paused state by the time the error notification is
15047 received, it means that the user can <i>try to resume</i> the machine
15048 execution after attempting to solve the problem that caused the
15049 error. In this case, the notification handler is supposed
15050 to show an appropriate message to the user (depending on the
15051 value of the @a id parameter) that offers several actions such
15052 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
15053 wants to retry, the notification handler should continue
15054 the machine execution using the <link to="IConsole::resume"/>
15055 call. If the machine execution is not Paused during this
15056 notification, then it means this notification is a <i>warning</i>
15057 (for example, about a fatal condition that can happen very soon);
15058 no immediate action is required from the user, the machine
15059 continues its normal execution.
15060
15061 Note that in either case the notification handler
15062 <b>must not</b> perform any action directly on a thread
15063 where this notification is called. Everything it is allowed to
15064 do is to post a message to another thread that will then talk
15065 to the user and take the corresponding action.
15066
15067 Currently, the following error identifiers are known:
15068 <ul>
15069 <li><tt>"HostMemoryLow"</tt></li>
15070 <li><tt>"HostAudioNotResponding"</tt></li>
15071 <li><tt>"VDIStorageFull"</tt></li>
15072 <li><tt>"3DSupportIncompatibleAdditions"</tt></li>
15073 </ul>
15074 </desc>
15075 <attribute name="fatal" type="boolean" readonly="yes">
15076 <desc>
15077 Whether the error is fatal or not.
15078 </desc>
15079 </attribute>
15080 <attribute name="id" type="wstring" readonly="yes">
15081 <desc>
15082 Error identifier.
15083 </desc>
15084 </attribute>
15085 <attribute name="message" type="wstring" readonly="yes">
15086 <desc>
15087 Optional error message.
15088 </desc>
15089 </attribute>
15090 </interface>
15091
15092
15093 <interface
15094 name="IEventSourceChangedEvent" extends="IEvent"
15095 uuid="e7932cb8-f6d4-4ab6-9cbf-558eb8959a6a"
15096 waitable="yes"
15097 wsmap="managed" autogen="VBoxEvent" id="OnEventSourceChanged"
15098 >
15099 <desc>
15100 Notification when an event source state changes (listener added or removed).
15101 </desc>
15102
15103 <attribute name="listener" type="IEventListener" readonly="yes">
15104 <desc>
15105 Event listener which has changed.
15106 </desc>
15107 </attribute>
15108
15109 <attribute name="add" type="boolean" readonly="yes">
15110 <desc>
15111 Flag whether listener was added or removed.
15112 </desc>
15113 </attribute>
15114 </interface>
15115
15116 <interface
15117 name="IExtraDataChangedEvent" extends="IEvent"
15118 uuid="024F00CE-6E0B-492A-A8D0-968472A94DC7"
15119 wsmap="managed" autogen="VBoxEvent" id="OnExtraDataChanged"
15120 >
15121 <desc>
15122 Notification when machine specific or global extra data
15123 has changed.
15124 </desc>
15125 <attribute name="machineId" type="uuid" mod="string" readonly="yes">
15126 <desc>
15127 ID of the machine this event relates to.
15128 Null for global extra data changes.
15129 </desc>
15130 </attribute>
15131 <attribute name="key" type="wstring" readonly="yes">
15132 <desc>
15133 Extra data key that has changed.
15134 </desc>
15135 </attribute>
15136 <attribute name="value" type="wstring" readonly="yes">
15137 <desc>
15138 Extra data value for the given key.
15139 </desc>
15140 </attribute>
15141 </interface>
15142
15143 <interface
15144 name="IVetoEvent" extends="IEvent"
15145 uuid="9a1a4130-69fe-472f-ac10-c6fa25d75007"
15146 wsmap="managed"
15147 >
15148 <desc>Base abstract interface for veto events.</desc>
15149
15150 <method name="addVeto">
15151 <desc>
15152 Adds a veto on this event.
15153 </desc>
15154 <param name="reason" type="wstring" dir="in">
15155 <desc>
15156 Reason for veto, could be null or empty string.
15157 </desc>
15158 </param>
15159 </method>
15160
15161 <method name="isVetoed">
15162 <desc>
15163 If this event was vetoed.
15164 </desc>
15165 <param name="result" type="boolean" dir="return">
15166 <desc>
15167 Reason for veto.
15168 </desc>
15169 </param>
15170 </method>
15171
15172 <method name="getVetos">
15173 <desc>
15174 Current veto reason list, if size is 0 - no veto.
15175 </desc>
15176 <param name="result" type="wstring" dir="return" safearray="yes">
15177 <desc>
15178 Array of reasons for veto provided by different event handlers.
15179 </desc>
15180 </param>
15181 </method>
15182
15183 </interface>
15184
15185 <interface
15186 name="IExtraDataCanChangeEvent" extends="IVetoEvent"
15187 uuid="245d88bd-800a-40f8-87a6-170d02249a55"
15188 wsmap="managed" autogen="VBoxEvent" id="OnExtraDataCanChange"
15189 waitable="true"
15190 >
15191 <desc>
15192 Notification when someone tries to change extra data for
15193 either the given machine or (if @c null) global extra data.
15194 This gives the chance to veto against changes.
15195 </desc>
15196 <attribute name="machineId" type="uuid" mod="string" readonly="yes">
15197 <desc>
15198 ID of the machine this event relates to.
15199 Null for global extra data changes.
15200 </desc>
15201 </attribute>
15202 <attribute name="key" type="wstring" readonly="yes">
15203 <desc>
15204 Extra data key that has changed.
15205 </desc>
15206 </attribute>
15207 <attribute name="value" type="wstring" readonly="yes">
15208 <desc>
15209 Extra data value for the given key.
15210 </desc>
15211 </attribute>
15212 </interface>
15213
15214 <interface
15215 name="ICanShowWindowEvent" extends="IVetoEvent"
15216 uuid="adf292b0-92c9-4a77-9d35-e058b39fe0b9"
15217 wsmap="managed" autogen="VBoxEvent" id="OnCanShowWindow"
15218 waitable="true"
15219 >
15220 <desc>
15221 Notification when a call to
15222 <link to="IMachine::canShowConsoleWindow"/> is made by a
15223 front-end to check if a subsequent call to
15224 <link to="IMachine::showConsoleWindow"/> can succeed.
15225
15226 The callee should give an answer appropriate to the current
15227 machine state using event veto. This answer must
15228 remain valid at least until the next
15229 <link to="IConsole::state">machine state</link> change.
15230 </desc>
15231 </interface>
15232
15233 <interface
15234 name="IShowWindowEvent" extends="IEvent"
15235 uuid="B0A0904D-2F05-4D28-855F-488F96BAD2B2"
15236 wsmap="managed" autogen="VBoxEvent" id="OnShowWindow"
15237 waitable="true"
15238 >
15239 <desc>
15240 Notification when a call to
15241 <link to="IMachine::showConsoleWindow"/>
15242 requests the console window to be activated and brought to
15243 foreground on the desktop of the host PC.
15244
15245 This notification should cause the VM console process to
15246 perform the requested action as described above. If it is
15247 impossible to do it at a time of this notification, this
15248 method should return a failure.
15249
15250 Note that many modern window managers on many platforms
15251 implement some sort of focus stealing prevention logic, so
15252 that it may be impossible to activate a window without the
15253 help of the currently active application (which is supposedly
15254 an initiator of this notification). In this case, this method
15255 must return a non-zero identifier that represents the
15256 top-level window of the VM console process. The caller, if it
15257 represents a currently active process, is responsible to use
15258 this identifier (in a platform-dependent manner) to perform
15259 actual window activation.
15260
15261 This method must set @a winId to zero if it has performed all
15262 actions necessary to complete the request and the console
15263 window is now active and in foreground, to indicate that no
15264 further action is required on the caller's side.
15265 </desc>
15266 <attribute name="winId" type="long long">
15267 <desc>
15268 Platform-dependent identifier of the top-level VM console
15269 window, or zero if this method has performed all actions
15270 necessary to implement the <i>show window</i> semantics for
15271 the given platform and/or this VirtualBox front-end.
15272 </desc>
15273 </attribute>
15274 </interface>
15275
15276 <module name="VBoxSVC" context="LocalServer">
15277 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
15278 namespace="virtualbox.org">
15279 <interface name="IVirtualBox" default="yes"/>
15280 </class>
15281 </module>
15282
15283 <module name="VBoxC" context="InprocServer" threadingModel="Free">
15284 <class name="Session" uuid="3C02F46D-C9D2-4F11-A384-53F0CF917214"
15285 namespace="virtualbox.org">
15286 <interface name="ISession" default="yes"/>
15287 </class>
15288
15289 <class name="Console" uuid="577230FF-164F-4CAC-8548-312D8275A4A7"
15290 namespace="virtualbox.org">
15291 <interface name="IConsole" default="yes"/>
15292 </class>
15293 </module>
15294
15295</library>
15296
15297</idl>
15298
15299<!-- vim: set shiftwidth=2 tabstop=2 expandtab: -->
Note: See TracBrowser for help on using the repository browser.

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