VirtualBox

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

Last change on this file since 20889 was 20888, checked in by vboxsync, 16 years ago

webservice: changes to allow for supporting IDisplay and other interfaces: suppress only methods with [ptr] args, not entire interfaces that use them; better error reporting in jax-ws generator; use common table in include file for type conversions; make takeScreenShotSlow() use dir=return instead of dir=out for one output arg

  • Property svn:eol-style set to native
File size: 497.1 KB
Line 
1<?xml version="1.0" ?>
2
3<!--
4 * :tabSize=2:indentSize=2:noTabs=true:
5 * :folding=explicit:collapseFolds=1:
6 *
7 * Master declaration for VirtualBox's Main API, represented
8 * by COM/XPCOM and web service interfaces.
9 *
10 * From this document, the build system generates several files
11 * via XSLT that are then used during the build process.
12 *
13 * Below is the list of XSL templates that operate on this file and
14 * output files they generate. These XSL templates must be updated
15 * whenever the schema of this file changes:
16 *
17 * 1. src/VBox/Main/idl/midl.xsl =>
18 * out/<platform>/bin/sdk/idl/VirtualBox.idl
19 * (MS COM interface definition file for Main API)
20 *
21 * 2. src/VBox/Main/idl/xpidl.xsl =>
22 * out/<platform>/bin/sdk/idl/VirtualBox_XPCOM.idl
23 * (XPCOM interface definition file for Main API)
24 *
25 * 3. src/VBox/Main/idl/doxygen.xsl =>
26 * out/<platform>/obj/src/VBox/Main/VirtualBox.idl
27 * (pseudo-IDL for Doxygen to generate the official Main API
28 * documentation)
29 *
30 * 4. src/VBox/Main/webservice/*.xsl =>
31 * a bunch of WSDL and C++ files
32 * (VirtualBox web service sources and SOAP mappers;
33 * see src/VBox/Main/webservice/Makefile.kmk for details)
34 *
35 * 5. src/VBox/Frontends/VirtualBox/include/COMWrappers.xsl =>
36 * out/<platform>/obj/src/VBox/Frontends/VirtualBox/VirtualBox/include/COMWrappers.h
37 * (smart Qt-based C++ wrapper classes for COM interfaces
38 * of the Main API)
39 *
40 * 6. src/VBox/Installer/win32/VirtualBox_TypeLib.xsl =>
41 * out/<platform>/obj/src/VBox/Installer/win32/VirtualBox_TypeLib.wxi
42 * (Main API TypeLib block for the WiX installer)
43 *
44 * 7. src/VBox/Runtime/common/err/errmsgvboxcom.xsl =>
45 * out/<platform>/obj/Runtime/errmsgvboxcomdata.h
46 * (<result> extraction for the %Rhrc format specifier)
47 *
48 Copyright (C) 2006-2009 Sun Microsystems, Inc.
49
50 This file is part of VirtualBox Open Source Edition (OSE), as
51 available from http://www.virtualbox.org. This file is free software;
52 you can redistribute it and/or modify it under the terms of the GNU
53 General Public License (GPL) as published by the Free Software
54 Foundation, in version 2 as it comes in the "COPYING" file of the
55 VirtualBox OSE distribution. VirtualBox OSE is distributed in the
56 hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
57
58 Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
59 Clara, CA 95054 USA or visit http://www.sun.com if you need
60 additional information or have any questions.
61-->
62
63<idl>
64
65<desc>
66 Welcome to the <b>VirtualBox Main API documentation</b>. This documentation
67 describes the so-called <i>VirtualBox Main API</i> which comprises all public
68 COM interfaces and components provided by the VirtualBox server and by the
69 VirtualBox client library.
70
71 VirtualBox employs a client-server design, meaning that whenever any part of
72 VirtualBox is running -- be it the Qt GUI, the VBoxManage command-line
73 interface or any virtual machine --, a dedicated server process named
74 VBoxSVC runs in the background. This allows multiple processes working with
75 VirtualBox to cooperate without conflicts. These processes communicate to each
76 other using inter-process communication facilities provided by the COM
77 implementation of the host computer.
78
79 On Windows platforms, the VirtualBox Main API uses Microsoft COM, a native COM
80 implementation. On all other platforms, Mozilla XPCOM, an open-source COM
81 implementation, is used.
82
83 All the parts that a typical VirtualBox user interacts with (the Qt GUI,
84 the VBoxManage command-line interface and the VBoxVRDP server) are technically
85 front-ends to the Main API and only use the interfaces that are documented
86 in this Main API documentation. This ensures that, with any given release
87 version of VirtualBox, all capabilities of the product that could be useful
88 to an external client program are always exposed by way of this API.
89
90 The VirtualBox Main API (also called the <i>VirtualBox COM library</i>)
91 contains two public component classes:
92 <tt>%VirtualBox.VirtualBox</tt> and <tt>%VirtualBox.Session</tt>, which
93 implement IVirtualBox and ISession interfaces respectively. These two classes
94 are of supreme importance and will be needed in order for any front-end
95 program to do anything useful. It is recommended to read the documentation of
96 the mentioned interfaces first.
97
98 The <tt>%VirtualBox.VirtualBox</tt> class is a singleton. This means that
99 there can be only one object of this class on the local machine at any given
100 time. This object is a parent of many other objects in the VirtualBox COM
101 library and lives in the VBoxSVC process. In fact, when you create an instance
102 of the <tt>VirtualBox.VirtualBox</tt>, the COM subsystem checks if the VBoxSVC
103 process is already running, starts it if not, and returns you a reference to
104 the <tt>VirtualBox</tt> object created in this process. When the last reference
105 to this object is released, the VBoxSVC process ends (with a 5 second delay to
106 protect from too frequent restarts).
107
108 The <tt>%VirtualBox.Session</tt> class is a regular component. You can create
109 as many <tt>Session</tt> objects as you need but all of them will live in a
110 process which issues the object instantiation call. <tt>Session</tt> objects
111 represent virtual machine sessions which are used to configure virtual
112 machines and control their execution.
113</desc>
114
115<if target="midl">
116 <cpp line="enum {"/>
117 <cpp line=" kTypeLibraryMajorVersion = 1,"/>
118 <cpp line=" kTypeLibraryMinorVersion = 0"/>
119 <cpp line="};"/>
120</if>
121
122<if target="xpidl">
123 <!-- NS_IMPL_THREADSAFE_ISUPPORTSxx_CI macros are placed here, for convenience -->
124 <cpp>
125/* currently, nsISupportsImpl.h lacks the below-like macros */
126
127#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1_CI NS_IMPL_QUERY_INTERFACE1_CI
128#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2_CI NS_IMPL_QUERY_INTERFACE2_CI
129
130#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_CI
131# define NS_IMPL_THREADSAFE_ISUPPORTS1_CI(_class, _interface) \
132 NS_IMPL_THREADSAFE_ADDREF(_class) \
133 NS_IMPL_THREADSAFE_RELEASE(_class) \
134 NS_IMPL_THREADSAFE_QUERY_INTERFACE1_CI(_class, _interface) \
135 NS_IMPL_CI_INTERFACE_GETTER1(_class, _interface)
136#endif
137
138#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_CI
139# define NS_IMPL_THREADSAFE_ISUPPORTS2_CI(_class, _i1, _i2) \
140 NS_IMPL_THREADSAFE_ADDREF(_class) \
141 NS_IMPL_THREADSAFE_RELEASE(_class) \
142 NS_IMPL_THREADSAFE_QUERY_INTERFACE2_CI(_class, _i1, _i2) \
143 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
144#endif
145
146#ifndef NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI
147# define NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI(_class, _i1, _ic1) \
148 NS_INTERFACE_MAP_BEGIN(_class) \
149 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
150 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
151 NS_IMPL_QUERY_CLASSINFO(_class) \
152 NS_INTERFACE_MAP_END
153#endif
154
155#ifndef NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI
156# define NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI(_class, _i1, _ic1, \
157 _i2, _ic2) \
158 NS_INTERFACE_MAP_BEGIN(_class) \
159 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
160 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i2, _ic2) \
161 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
162 NS_IMPL_QUERY_CLASSINFO(_class) \
163 NS_INTERFACE_MAP_END
164#endif
165
166#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI
167#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI
168
169#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_AMBIGUOUS_CI
170# define NS_IMPL_THREADSAFE_ISUPPORTS1_AMBIGUOUS_CI(_class, _i1, _ic1) \
171 NS_IMPL_THREADSAFE_ADDREF(_class) \
172 NS_IMPL_THREADSAFE_RELEASE(_class) \
173 NS_IMPL_THREADSAFE_QUERY_INTERFACE1_AMBIGUOUS_CI(_class, _i1, _ic1) \
174 NS_IMPL_CI_INTERFACE_GETTER1(_class, _i1)
175#endif
176
177#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_AMBIGUOUS_CI
178# define NS_IMPL_THREADSAFE_ISUPPORTS2_AMBIGUOUS_CI(_class, _i1, _ic1, \
179 _i2, _ic2) \
180 NS_IMPL_THREADSAFE_ADDREF(_class) \
181 NS_IMPL_THREADSAFE_RELEASE(_class) \
182 NS_IMPL_THREADSAFE_QUERY_INTERFACE2_AMBIGUOUS_CI(_class, _i1, _ic1, \
183 _i2, _ic2) \
184 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
185#endif
186 </cpp>
187</if>
188
189<library
190 name="VirtualBox"
191 uuid="46137EEC-703B-4fe5-AFD4-7C9BBBBA0259"
192 version="1.3"
193 desc="VirtualBox Type Library"
194 appUuid="819B4D85-9CEE-493C-B6FC-64FFE759B3C9"
195 supportsErrorInfo="yes"
196>
197
198
199 <!--
200 // COM result codes for VirtualBox
201 /////////////////////////////////////////////////////////////////////////
202 -->
203
204 <descGroup id="VirtualBox_COM_result_codes" title="VirtualBox COM result codes">
205 <desc>
206 This section describes all VirtualBox-specific COM result codes that may
207 be returned by methods of VirtualBox COM interfaces in addition to
208 standard COM result codes.
209
210 Note that along with the result code, every VirtualBox method returns
211 extended error information through the IVirtualBoxErrorInfo interface on
212 failure. This interface is a preferred way to present the error to the end
213 user because it contains a human readable description of the error. Raw
214 result codes, both standard and described in this section, are intended to
215 be used by programs to analyze the reason of a failure and select an
216 appropriate course of action without involving the end user (for example,
217 retry the operation later or make a different call).
218
219 The standard COM result codes that may originate from our methods include:
220
221 <table>
222 <tr><td>E_INVALIDARG</td>
223 <td>
224 Returned when the value of the method's argument is not within the range
225 of valid values. This should not be confused with situations when the
226 value is within the range but simply doesn't suit the current object
227 state and there is a possibility that it will be accepted later (in such
228 cases VirtualBox-specific codes are returned, for example,
229 <link to="VBOX_E_OBJECT_NOT_FOUND"/>).
230 </td>
231 </tr>
232 <tr><td>E_POINTER</td>
233 <td>
234 Returned if a memory pointer for the output argument is invalid (for
235 example, <tt>NULL</tt>). Note that when pointers representing input
236 arguments (such as strings) are invalid, E_INVALIDARG is returned.
237 </td>
238 </tr>
239 <tr><td>E_ACCESSDENIED</td>
240 <td>
241 Returned when the called object is not ready. Since the lifetime of a
242 public COM object cannot be fully controlled by the implementation,
243 VirtualBox maintains the readiness state for all objects it creates and
244 returns this code in response to any method call on the object that was
245 deactivated by VirtualBox and is not functioning any more.
246 </td>
247 </tr>
248 <tr><td>E_OUTOFMEMORY</td>
249 <td>
250 Returned when a memory allocation operation fails.
251 </td>
252 </tr>
253 </table>
254 </desc>
255 </descGroup>
256
257 <!--
258 Note that src/VBox/Runtime/common/err/errmsgvboxcom.xsl will ignore
259 everything in <result>/<desc> after (and including) the first dot, so express
260 the matter of the error code in the first sentence and keep it short.
261 -->
262
263 <result name="VBOX_E_OBJECT_NOT_FOUND" value="0x80BB0001">
264 <desc>
265 Object corresponding to the supplied arguments does not exist.
266 </desc>
267 </result>
268
269 <result name="VBOX_E_INVALID_VM_STATE" value="0x80BB0002">
270 <desc>
271 Current virtual machine state prevents the operation.
272 </desc>
273 </result>
274
275 <result name="VBOX_E_VM_ERROR" value="0x80BB0003">
276 <desc>
277 Virtual machine error occurred attempting the operation.
278 </desc>
279 </result>
280
281 <result name="VBOX_E_FILE_ERROR" value="0x80BB0004">
282 <desc>
283 File not accessible or erroneous file contents.
284 </desc>
285 </result>
286
287 <result name="VBOX_E_IPRT_ERROR" value="0x80BB0005">
288 <desc>
289 Runtime subsystem error.
290 </desc>
291 </result>
292
293 <result name="VBOX_E_PDM_ERROR" value="0x80BB0006">
294 <desc>
295 Pluggable Device Manager error.
296 </desc>
297 </result>
298
299 <result name="VBOX_E_INVALID_OBJECT_STATE" value="0x80BB0007">
300 <desc>
301 Current object state prohibits operation.
302 </desc>
303 </result>
304
305 <result name="VBOX_E_HOST_ERROR" value="0x80BB0008">
306 <desc>
307 Host operating system related error.
308 </desc>
309 </result>
310
311 <result name="VBOX_E_NOT_SUPPORTED" value="0x80BB0009">
312 <desc>
313 Requested operation is not supported.
314 </desc>
315 </result>
316
317 <result name="VBOX_E_XML_ERROR" value="0x80BB000A">
318 <desc>
319 Invalid XML found.
320 </desc>
321 </result>
322
323 <result name="VBOX_E_INVALID_SESSION_STATE" value="0x80BB000B">
324 <desc>
325 Current session state prohibits operation.
326 </desc>
327 </result>
328
329 <result name="VBOX_E_OBJECT_IN_USE" value="0x80BB000C">
330 <desc>
331 Object being in use prohibits operation.
332 </desc>
333 </result>
334
335 <!--
336 Note that src/VBox/Runtime/common/err/errmsgvboxcom.xsl will ignore
337 everything in <result>/<desc> after (and including) the first dot, so express
338 the matter of the error code in the first sentence and keep it short.
339 -->
340
341 <descGroup/>
342
343 <!--
344 // all common enums
345 /////////////////////////////////////////////////////////////////////////
346 -->
347
348 <enum
349 name="TSBool"
350 uuid="523ff64d-842a-4b1a-80e7-c311b028cb3a"
351 >
352 <desc>
353 Boolean variable having a third state, default.
354 </desc>
355
356 <const name="False" value="0"/>
357 <const name="True" value="1"/>
358 <const name="Default" value="2"/>
359 </enum>
360
361 <enum
362 name="AccessMode"
363 uuid="1da0007c-ddf7-4be8-bcac-d84a1558785f"
364 >
365 <desc>
366 Access mode for opening files.
367 </desc>
368
369 <const name="ReadOnly" value="1"/>
370 <const name="ReadWrite" value="2"/>
371 </enum>
372
373 <enum
374 name="MachineState"
375 uuid="73bf04d0-7c4f-4684-9abf-d65a9ad74343"
376 >
377 <desc>
378 Virtual machine execution state.
379
380 This enumeration represents possible values of the <link
381 to="IMachine::state"/> attribute.
382
383 Below is the basic virtual machine state diagram. It shows how the state
384 changes during virtual machine execution. The text in square braces shows
385 a method of the IConsole interface that performs the given state
386 transition.
387
388 <pre>
389 +---------[powerDown()] &lt;- Stuck &lt;--[failure]-+
390 V |
391 +-&gt; PoweredOff --+--&gt;[powerUp()]--&gt; Starting --+ | +-----[resume()]-----+
392 | | | | V |
393 | Aborted -----+ +--&gt; Running --[pause()]--&gt; Paused
394 | | ^ | ^ |
395 | Saved -----------[powerUp()]--&gt; Restoring -+ | | | |
396 | ^ | | | |
397 | | +-----------------------------------------+-|-------------------+ +
398 | | | | |
399 | | +-- Saving &lt;--------[takeSnapshot()]&lt;-------+---------------------+
400 | | | |
401 | +-------- Saving &lt;--------[saveState()]&lt;----------+---------------------+
402 | | |
403 +-------------- Stopping -------[powerDown()]&lt;----------+---------------------+
404 </pre>
405
406 Note that states to the right from PoweredOff, Aborted and Saved in the
407 above diagram are called <i>online VM states</i>. These states
408 represent the virtual machine which is being executed in a dedicated
409 process (usually with a GUI window attached to it where you can see the
410 activity of the virtual machine and interact with it). There are two
411 special pseudo-states, FirstOnline and LastOnline, that can be used in
412 relational expressions to detect if the given machine state is online or
413 not:
414
415 <pre>
416 if (machine.GetState() &gt;= MachineState_FirstOnline &amp;&amp;
417 machine.GetState() &lt;= MachineState_LastOnline)
418 {
419 ...the machine is being executed...
420 }
421 </pre>
422
423 When the virtual machine is in one of the online VM states (that is, being
424 executed), only a few machine settings can be modified. Methods working
425 with such settings contain an explicit note about that. An attempt to
426 change any oter setting or perform a modifying operation during this time
427 will result in the <link to="VBOX_E_INVALID_VM_STATE"/> error.
428
429 All online states except Running, Paused and Stuck are transitional: they
430 represent temporary conditions of the virtual machine that will last as
431 long as the operation that initiated such a condition.
432
433 The Stuck state is a special case. It means that execution of the machine
434 has reached the "Guru Meditation" condition. This condition indicates an
435 internal VMM (virtual machine manager) failure which may happen as a
436 result of either an unhandled low-level virtual hardware exception or one
437 of the recompiler exceptions (such as the <i>too-many-traps</i>
438 condition).
439
440 Note also that any online VM state may transit to the Aborted state. This
441 happens if the process that is executing the virtual machine terminates
442 unexpectedly (for example, crashes). Other than that, the Aborted state is
443 equivalent to PoweredOff.
444
445 There are also a few additional state diagrams that do not deal with
446 virtual machine execution and therefore are shown separately. The states
447 shown on these diagrams are called <i>offline VM states</i> (this includes
448 PoweredOff, Aborted and Saved too).
449
450 The first diagram shows what happens when a lengthy setup operation is
451 being executed (such as <link to="IMachine::attachHardDisk"/>).
452
453 <pre>
454 +----------------------------------(same state as before the call)------+
455 | |
456 +-&gt; PoweredOff --+ |
457 | | |
458 |-&gt; Aborted -----+--&gt;[lengthy VM configuration call] --&gt; SettingUp -----+
459 | |
460 +-&gt; Saved -------+
461 </pre>
462
463 The next two diagrams demonstrate the process of taking a snapshot of a
464 powered off virtual machine and performing one of the "discard..."
465 operations, respectively.
466
467 <pre>
468 +----------------------------------(same state as before the call)------+
469 | |
470 +-&gt; PoweredOff --+ |
471 | +--&gt;[takeSnapshot()] -------------------&gt; Saving ------+
472 +-&gt; Aborted -----+
473
474 +-&gt; PoweredOff --+
475 | |
476 | Aborted -----+--&gt;[discardSnapshot() ]-------------&gt; Discarding --+
477 | | [discardCurrentState()] |
478 +-&gt; Saved -------+ [discardCurrentSnapshotAndState()] |
479 | |
480 +---(Saved if restored from an online snapshot, PoweredOff otherwise)---+
481 </pre>
482
483 Note that the Saving state is present in both the offline state group and
484 online state group. Currently, the only way to determine what group is
485 assumed in a particular case is to remember the previous machine state: if
486 it was Running or Paused, then Saving is an online state, otherwise it is
487 an offline state. This inconsistency may be removed in one of the future
488 versions of VirtualBox by adding a new state.
489
490 <note internal="yes">
491 For whoever decides to touch this enum: In order to keep the
492 comparisons involving FirstOnline and LastOnline pseudo-states valid,
493 the numeric values of these states must be correspondingly updated if
494 needed: for any online VM state, the condition
495 <tt>FirstOnline &lt;= state &lt;= LastOnline</tt> must be
496 <tt>true</tt>. The same relates to transient states for which
497 the condition <tt>FirstOnline &lt;= state &lt;= LastOnline</tt> must be
498 <tt>true</tt>.
499 </note>
500 </desc>
501
502 <const name="Null" value="0">
503 <desc>Null value (never used by the API).</desc>
504 </const>
505 <const name="PoweredOff" value="1">
506 <desc>
507 The machine is not running.
508 </desc>
509 </const>
510 <const name="Saved" value="2">
511 <desc>
512 The machine is not currently running, but the execution state of the machine
513 has been saved to an external file when it was running.
514 </desc>
515 </const>
516 <const name="Aborted" value="3">
517 <desc>
518 The process running the machine has terminated abnormally.
519 </desc>
520 </const>
521 <const name="Running" value="4">
522 <desc>
523 The machine is currently being executed.
524 <note internal="yes">
525 For whoever decides to touch this enum: In order to keep the
526 comparisons in the old source code valid, this state must immediately
527 precede the Paused state.
528 </note>
529 </desc>
530 </const>
531 <const name="Paused" value="5">
532 <desc>
533 Execution of the machine has been paused.
534 <note internal="yes">
535 For whoever decides to touch this enum: In order to keep the
536 comparisons in the old source code valid, this state must immediately
537 follow the Running state.
538 </note>
539 </desc>
540 </const>
541 <const name="Stuck" value="6">
542 <desc>
543 Execution of the machine has reached the "Guru Meditation"
544 condition.
545 </desc>
546 </const>
547 <const name="Starting" value="7">
548 <desc>
549 Machine is being started after powering it on from a
550 zero execution state.
551 </desc>
552 </const>
553 <const name="Stopping" value="8">
554 <desc>
555 Machine is being normally stopped powering it off, or after the guest OS
556 has initiated a shutdown sequence.
557 </desc>
558 </const>
559 <const name="Saving" value="9">
560 <desc>
561 Machine is saving its execution state to a file or an online
562 snapshot of the machine is being taken.
563 </desc>
564 </const>
565 <const name="Restoring" value="10">
566 <desc>
567 Execution state of the machine is being restored from a file
568 after powering it on from the saved execution state.
569 </desc>
570 </const>
571 <const name="Discarding" value="11">
572 <desc>
573 Snapshot of the machine is being discarded.
574 </desc>
575 </const>
576 <const name="SettingUp" value="12">
577 <desc>
578 Lengthy setup operation is in progress.
579 </desc>
580 </const>
581
582 <const name="FirstOnline" value="4" wsmap="suppress"> <!-- Running -->
583 <desc>
584 Pseudo-state: first online state (for use in relational expressions).
585 </desc>
586 </const>
587 <const name="LastOnline" value="10" wsmap="suppress"> <!-- Restoring -->
588 <desc>
589 Pseudo-state: last online state (for use in relational expressions).
590 </desc>
591 </const>
592
593 <const name="FirstTransient" value="7" wsmap="suppress"> <!-- Starting -->
594 <desc>
595 Pseudo-state: first transient state (for use in relational expressions).
596 </desc>
597 </const>
598 <const name="LastTransient" value="12" wsmap="suppress"> <!-- SettingUp -->
599 <desc>
600 Pseudo-state: last transient state (for use in relational expressions).
601 </desc>
602 </const>
603
604 </enum>
605
606 <enum
607 name="SessionState"
608 uuid="CF2700C0-EA4B-47ae-9725-7810114B94D8"
609 >
610 <desc>
611 Session state. This enumeration represents possible values of
612 <link to="IMachine::sessionState"/> and <link to="ISession::state"/>
613 attributes. See individual enumerator descriptions for the meaning for
614 every value.
615 </desc>
616
617 <const name="Null" value="0">
618 <desc>Null value (never used by the API).</desc>
619 </const>
620 <const name="Closed" value="1">
621 <desc>
622 The machine has no open sessions (<link to="IMachine::sessionState"/>);
623 the session is closed (<link to="ISession::state"/>)
624 </desc>
625 </const>
626 <const name="Open" value="2">
627 <desc>
628 The machine has an open direct session (<link to="IMachine::sessionState"/>);
629 the session is open (<link to="ISession::state"/>)
630 </desc>
631 </const>
632 <const name="Spawning" value="3">
633 <desc>
634 A new (direct) session is being opened for the machine
635 as a result of <link to="IVirtualBox::openRemoteSession"/>
636 call (<link to="IMachine::sessionState"/>);
637 the session is currently being opened
638 as a result of <link to="IVirtualBox::openRemoteSession"/>
639 call (<link to="ISession::state"/>)
640 </desc>
641 </const>
642 <const name="Closing" value="4">
643 <desc>
644 The direct session is being closed (<link to="IMachine::sessionState"/>);
645 the session is being closed (<link to="ISession::state"/>)
646 </desc>
647 </const>
648 </enum>
649
650 <enum
651 name="SessionType"
652 uuid="A13C02CB-0C2C-421E-8317-AC0E8AAA153A"
653 >
654 <desc>
655 Session type. This enumeration represents possible values of the
656 <link to="ISession::type"/> attribute.
657 </desc>
658
659 <const name="Null" value="0">
660 <desc>Null value (never used by the API).</desc>
661 </const>
662 <const name="Direct" value="1">
663 <desc>
664 Direct session
665 (opened by <link to="IVirtualBox::openSession"/>)
666 </desc>
667 </const>
668 <const name="Remote" value="2">
669 <desc>
670 Remote session
671 (opened by <link to="IVirtualBox::openRemoteSession"/>)
672 </desc>
673 </const>
674 <const name="Existing" value="3">
675 <desc>
676 Existing session
677 (opened by <link to="IVirtualBox::openExistingSession"/>)
678 </desc>
679 </const>
680 </enum>
681
682 <enum
683 name="DeviceType"
684 uuid="6d9420f7-0b56-4636-99f9-7346f1b01e57"
685 >
686 <desc>
687 Device type.
688 </desc>
689 <const name="Null" value="0">
690 <desc>
691 Null value, may also mean "no device" (not allowed for
692 <link to="IConsole::getDeviceActivity"/>).
693 </desc>
694 </const>
695 <const name="Floppy" value="1">
696 <desc>Floppy device.</desc>
697 </const>
698 <const name="DVD" value="2">
699 <desc>CD/DVD-ROM device.</desc>
700 </const>
701 <const name="HardDisk" value="3">
702 <desc>Hard disk device.</desc>
703 </const>
704 <const name="Network" value="4">
705 <desc>Network device.</desc>
706 </const>
707 <const name="USB" value="5">
708 <desc>USB device.</desc>
709 </const>
710 <const name="SharedFolder" value="6">
711 <desc>Shared folder device.</desc>
712 </const>
713 </enum>
714
715 <enum
716 name="DeviceActivity"
717 uuid="6FC8AEAA-130A-4eb5-8954-3F921422D707"
718 >
719 <desc>
720 Device activity for <link to="IConsole::getDeviceActivity"/>.
721 </desc>
722
723 <const name="Null" value="0"/>
724 <const name="Idle" value="1"/>
725 <const name="Reading" value="2"/>
726 <const name="Writing" value="3"/>
727 </enum>
728
729 <enum
730 name="ClipboardMode"
731 uuid="33364716-4008-4701-8f14-be0fa3d62950"
732 >
733 <desc>
734 Host-Guest clipboard interchange mode.
735 </desc>
736
737 <const name="Disabled" value="0"/>
738 <const name="HostToGuest" value="1"/>
739 <const name="GuestToHost" value="2"/>
740 <const name="Bidirectional" value="3"/>
741 </enum>
742
743 <enum
744 name="Scope"
745 uuid="7c91096e-499e-4eca-9f9b-9001438d7855"
746 >
747 <desc>
748 Scope of the operation.
749
750 A generic enumeration used in various methods to define the action or
751 argument scope.
752 </desc>
753
754 <const name="Global" value="0"/>
755 <const name="Machine" value="1"/>
756 <const name="Session" value="2"/>
757 </enum>
758
759 <enum
760 name="GuestStatisticType"
761 uuid="aa7c1d71-aafe-47a8-9608-27d2d337cf55"
762 >
763 <desc>
764 Statistics type for <link to="IGuest::getStatistic"/>.
765 </desc>
766
767 <const name="CPULoad_Idle" value="0">
768 <desc>
769 Idle CPU load (0-100%) for last interval.
770 </desc>
771 </const>
772 <const name="CPULoad_Kernel" value="1">
773 <desc>
774 Kernel CPU load (0-100%) for last interval.
775 </desc>
776 </const>
777 <const name="CPULoad_User" value="2">
778 <desc>
779 User CPU load (0-100%) for last interval.
780 </desc>
781 </const>
782 <const name="Threads" value="3">
783 <desc>
784 Total number of threads in the system.
785 </desc>
786 </const>
787 <const name="Processes" value="4">
788 <desc>
789 Total number of processes in the system.
790 </desc>
791 </const>
792 <const name="Handles" value="5">
793 <desc>
794 Total number of handles in the system.
795 </desc>
796 </const>
797 <const name="MemoryLoad" value="6">
798 <desc>
799 Memory load (0-100%).
800 </desc>
801 </const>
802 <const name="PhysMemTotal" value="7">
803 <desc>
804 Total physical memory in megabytes.
805 </desc>
806 </const>
807 <const name="PhysMemAvailable" value="8">
808 <desc>
809 Free physical memory in megabytes.
810 </desc>
811 </const>
812 <const name="PhysMemBalloon" value="9">
813 <desc>
814 Ballooned physical memory in megabytes.
815 </desc>
816 </const>
817 <const name="MemCommitTotal" value="10">
818 <desc>
819 Total amount of memory in the committed state in megabytes.
820 </desc>
821 </const>
822 <const name="MemKernelTotal" value="11">
823 <desc>
824 Total amount of memory used by the guest OS's kernel in megabytes.
825 </desc>
826 </const>
827 <const name="MemKernelPaged" value="12">
828 <desc>
829 Total amount of paged memory used by the guest OS's kernel in megabytes.
830 </desc>
831 </const>
832 <const name="MemKernelNonpaged" value="13">
833 <desc>
834 Total amount of non-paged memory used by the guest OS's kernel in megabytes.
835 </desc>
836 </const>
837 <const name="MemSystemCache" value="14">
838 <desc>
839 Total amount of memory used by the guest OS's system cache in megabytes.
840 </desc>
841 </const>
842 <const name="PageFileSize" value="15">
843 <desc>
844 Pagefile size in megabytes.
845 </desc>
846 </const>
847 <const name="SampleNumber" value="16">
848 <desc>
849 Statistics sample number
850 </desc>
851 </const>
852 <const name="MaxVal" value="17"/>
853 </enum>
854
855 <enum
856 name="BIOSBootMenuMode"
857 uuid="ae4fb9f7-29d2-45b4-b2c7-d579603135d5"
858 >
859 <desc>
860 BIOS boot menu mode.
861 </desc>
862
863 <const name="Disabled" value="0"/>
864 <const name="MenuOnly" value="1"/>
865 <const name="MessageAndMenu" value="2"/>
866 </enum>
867
868 <enum
869 name="DriveState"
870 uuid="cb7233b7-c519-42a5-8310-1830953cacbc"
871 >
872 <const name="Null" value="0">
873 <desc>Null value (never used by the API).</desc>
874 </const>
875 <const name="NotMounted" value="1"/>
876 <const name="ImageMounted" value="2"/>
877 <const name="HostDriveCaptured" value="3"/>
878 </enum>
879
880 <enum
881 name="ProcessorFeature"
882 uuid="b8353b35-705d-4796-9967-ebfb7ba54af4"
883 >
884 <desc>
885 CPU features.
886 </desc>
887
888 <const name="HWVirtEx" value="0"/>
889 <const name="PAE" value="1"/>
890 <const name="LongMode" value="2"/>
891 </enum>
892
893
894 <!--
895 // IVirtualBoxErrorInfo
896 /////////////////////////////////////////////////////////////////////////
897 -->
898
899 <interface
900 name="IVirtualBoxErrorInfo" extends="$errorinfo"
901 uuid="bcae7fc3-3fd0-4bac-923c-ec1596c7bc83"
902 supportsErrorInfo="no"
903 wsmap="suppress"
904 >
905 <desc>
906 The IVirtualBoxErrorInfo interface represents extended error information.
907
908 Extended error information can be set by VirtualBox components after
909 unsuccessful or partially successful method invocation. This information
910 can be retrieved by the calling party as an IVirtualBoxErrorInfo object
911 and then shown to the client in addition to the plain 32-bit result code.
912
913 In MS COM, this interface extends the IErrorInfo interface,
914 in XPCOM, it extends the nsIException interface. In both cases,
915 it provides a set of common attributes to retrieve error
916 information.
917
918 Sometimes invocation of some component's method may involve methods of
919 other components that may also fail (independently of this method's
920 failure), or a series of non-fatal errors may precede a fatal error that
921 causes method failure. In cases like that, it may be desirable to preserve
922 information about all errors happened during method invocation and deliver
923 it to the caller. The <link to="#next"/> attribute is intended
924 specifically for this purpose and allows to represent a chain of errors
925 through a single IVirtualBoxErrorInfo object set after method invocation.
926
927 Note that errors are stored to a chain in the reverse order, i.e. the
928 initial error object you query right after method invocation is the last
929 error set by the callee, the object it points to in the @a next attribute
930 is the previous error and so on, up to the first error (which is the last
931 in the chain).
932 </desc>
933
934 <attribute name="resultCode" type="long" readonly="yes">
935 <desc>
936 Result code of the error.
937 Usually, it will be the same as the result code returned
938 by the method that provided this error information, but not
939 always. For example, on Win32, CoCreateInstance() will most
940 likely return E_NOINTERFACE upon unsuccessful component
941 instantiation attempt, but not the value the component factory
942 returned. Value is typed 'long', not 'result',
943 to make interface usable from scripting languages.
944 <note>
945 In MS COM, there is no equivalent.
946 In XPCOM, it is the same as nsIException::result.
947 </note>
948 </desc>
949 </attribute>
950
951 <attribute name="interfaceID" type="uuid" readonly="yes">
952 <desc>
953 UUID of the interface that defined the error.
954 <note>
955 In MS COM, it is the same as IErrorInfo::GetGUID.
956 In XPCOM, there is no equivalent.
957 </note>
958 </desc>
959 </attribute>
960
961 <attribute name="component" type="wstring" readonly="yes">
962 <desc>
963 Name of the component that generated the error.
964 <note>
965 In MS COM, it is the same as IErrorInfo::GetSource.
966 In XPCOM, there is no equivalent.
967 </note>
968 </desc>
969 </attribute>
970
971 <attribute name="text" type="wstring" readonly="yes">
972 <desc>
973 Text description of the error.
974 <note>
975 In MS COM, it is the same as IErrorInfo::GetDescription.
976 In XPCOM, it is the same as nsIException::message.
977 </note>
978 </desc>
979 </attribute>
980
981 <attribute name="next" type="IVirtualBoxErrorInfo" readonly="yes">
982 <desc>
983 Next error object if there is any, or @c null otherwise.
984 <note>
985 In MS COM, there is no equivalent.
986 In XPCOM, it is the same as nsIException::inner.
987 </note>
988 </desc>
989 </attribute>
990
991 </interface>
992
993
994 <!--
995 // IVirtualBox
996 /////////////////////////////////////////////////////////////////////////
997 -->
998
999 <interface
1000 name="IVirtualBoxCallback" extends="$unknown"
1001 uuid="2990059f-5bc8-4635-8415-658917cd3186"
1002 wsmap="suppress"
1003 >
1004 <method name="onMachineStateChange">
1005 <desc>
1006 The execution state of the given machine has changed.
1007 <see>IMachine::state</see>
1008 </desc>
1009 <param name="machineId" type="wstring" dir="in">
1010 <desc>ID of the machine this event relates to.</desc>
1011 </param>
1012 <param name="state" type="MachineState" dir="in">
1013 <desc>New execution state.</desc>
1014 </param>
1015 </method>
1016
1017 <method name="onMachineDataChange">
1018 <desc>
1019 Any of the settings of the given machine has changed.
1020 </desc>
1021 <param name="machineId" type="wstring" dir="in">
1022 <desc>ID of the machine this event relates to.</desc>
1023 </param>
1024 </method>
1025
1026 <method name="onExtraDataCanChange">
1027 <desc>
1028 Notification when someone tries to change extra data for
1029 either the given machine or (if null) global extra data.
1030 This gives the chance to veto against changes.
1031 </desc>
1032 <param name="machineId" type="wstring" dir="in">
1033 <desc>
1034 ID of the machine this event relates to
1035 (null ID for global extra data change requests).
1036 </desc>
1037 </param>
1038 <param name="key" type="wstring" dir="in">
1039 <desc>
1040 Extra data key for the attempted write.
1041 </desc>
1042 </param>
1043 <param name="value" type="wstring" dir="in">
1044 <desc>
1045 Extra data value for the given key.
1046 </desc>
1047 </param>
1048 <param name="error" type="wstring" dir="out">
1049 <desc>
1050 Optional error message describing the reason of the
1051 veto (ignored if this notification returns @c true).
1052 </desc>
1053 </param>
1054 <param name="allowChange" type="boolean" dir="return">
1055 <desc>
1056 Flag to indicate whether the callee agrees (@c true)
1057 or vetoes against the change (@c false).
1058 </desc>
1059 </param>
1060 </method>
1061
1062 <method name="onExtraDataChange">
1063 <desc>
1064 Notification when machine specific or global extra data
1065 has changed.
1066 </desc>
1067 <param name="machineId" type="wstring" dir="in">
1068 <desc>
1069 ID of the machine this event relates to.
1070 Null for global extra data changes.
1071 </desc>
1072 </param>
1073 <param name="key" type="wstring" dir="in">
1074 <desc>
1075 Extra data key that has changed.
1076 </desc>
1077 </param>
1078 <param name="value" type="wstring" dir="in">
1079 <desc>
1080 Extra data value for the given key.
1081 </desc>
1082 </param>
1083 </method>
1084
1085 <method name="onMediaRegistered">
1086 <desc>
1087 The given media was registered or unregistered
1088 within this VirtualBox installation.
1089
1090 The @a mediaType parameter describes what type of
1091 media the specified @a mediaId refers to. Possible
1092 values are:
1093
1094 <ul>
1095 <li><link to="DeviceType_HardDisk"/>: the media is a hard disk
1096 that, if registered, can be obtained using the
1097 <link to="IVirtualBox::getHardDisk"/> call.</li>
1098 <li><link to="DeviceType_DVD"/>: the media is a CD/DVD image
1099 that, if registered, can be obtained using the
1100 <link to="IVirtualBox::getDVDImage"/> call.</li>
1101 <li><link to="DeviceType_Floppy"/>: the media is a Floppy image
1102 that, if registered, can be obtained using the
1103 <link to="IVirtualBox::getFloppyImage"/> call.</li>
1104 </ul>
1105
1106 Note that if this is a deregistration notification,
1107 there is no way to access the object representing the
1108 unregistered media. It is supposed that the
1109 application will do required cleanup based on the
1110 @a mediaId value.
1111 </desc>
1112 <param name="mediaId" type="wstring" dir="in">
1113 <desc>ID of the media this event relates to.</desc>
1114 </param>
1115 <param name="mediaType" type="DeviceType" dir="in">
1116 <desc>Type of the media this event relates to.</desc>
1117 </param>
1118 <param name="registered" type="boolean" dir="in">
1119 <desc>
1120 If true, the media was registered, otherwise it was
1121 unregistered.
1122 </desc>
1123 </param>
1124 </method>
1125
1126 <method name="onMachineRegistered">
1127 <desc>
1128 The given machine was registered or unregistered
1129 within this VirtualBox installation.
1130 </desc>
1131 <param name="machineId" type="wstring" dir="in">
1132 <desc>ID of the machine this event relates to.</desc>
1133 </param>
1134 <param name="registered" type="boolean" dir="in">
1135 <desc>
1136 If true, the machine was registered, otherwise it was
1137 unregistered.
1138 </desc>
1139 </param>
1140 </method>
1141
1142 <method name="onSessionStateChange">
1143 <desc>
1144 The state of the session for the given machine was changed.
1145 <see>IMachine::sessionState</see>
1146 </desc>
1147 <param name="machineId" type="wstring" dir="in">
1148 <desc>ID of the machine this event relates to.</desc>
1149 </param>
1150 <param name="state" type="SessionState" dir="in">
1151 <desc>New session state.</desc>
1152 </param>
1153 </method>
1154
1155 <method name="onSnapshotTaken">
1156 <desc>
1157 A new snapshot of the machine has been taken.
1158 <see>ISnapshot</see>
1159 </desc>
1160 <param name="machineId" type="wstring" dir="in">
1161 <desc>ID of the machine this event relates to.</desc>
1162 </param>
1163 <param name="snapshotId" type="wstring" dir="in">
1164 <desc>ID of the new snapshot.</desc>
1165 </param>
1166 </method>
1167
1168 <method name="onSnapshotDiscarded">
1169 <desc>
1170 Snapshot of the given machine has been discarded.
1171
1172 <note>
1173 This notification is delivered <b>after</b> the snapshot
1174 object has been uninitialized on the server (so that any
1175 attempt to call its methods will return an error).
1176 </note>
1177
1178 <see>ISnapshot</see>
1179 </desc>
1180 <param name="machineId" type="wstring" dir="in">
1181 <desc>ID of the machine this event relates to.</desc>
1182 </param>
1183 <param name="snapshotId" type="wstring" dir="in">
1184 <desc>
1185 ID of the discarded snapshot. <tt>null</tt> means the
1186 current machine state has been discarded (restored from
1187 the current snapshot).
1188 </desc>
1189 </param>
1190 </method>
1191
1192 <method name="onSnapshotChange">
1193 <desc>
1194 Snapshot properties (name and/or description) have been changed.
1195 <see>ISnapshot</see>
1196 </desc>
1197 <param name="machineId" type="wstring" dir="in">
1198 <desc>ID of the machine this event relates to.</desc>
1199 </param>
1200 <param name="snapshotId" type="wstring" dir="in">
1201 <desc>ID of the changed snapshot.</desc>
1202 </param>
1203 </method>
1204
1205 <method name="onGuestPropertyChange">
1206 <desc>
1207 Notification when a guest property has changed.
1208 </desc>
1209 <param name="machineId" type="wstring" dir="in">
1210 <desc>
1211 ID of the machine this event relates to.
1212 </desc>
1213 </param>
1214 <param name="name" type="wstring" dir="in">
1215 <desc>
1216 The name of the property that has changed.
1217 </desc>
1218 </param>
1219 <param name="value" type="wstring" dir="in">
1220 <desc>
1221 The new property value.
1222 </desc>
1223 </param>
1224 <param name="flags" type="wstring" dir="in">
1225 <desc>
1226 The new property flags.
1227 </desc>
1228 </param>
1229 </method>
1230
1231 </interface>
1232
1233 <interface
1234 name="IDHCPServer" extends="$unknown"
1235 uuid="6cfe387c-74fb-4ca7-bff6-973bec8af7a3"
1236 wsmap="managed"
1237 >
1238 <desc>
1239 The IDHCPServer interface represents the vbox dhcp server configuration.
1240
1241 To enumerate all the dhcp servers on the host, use the
1242 <link to="IVirtualBox::DHCPServers"/> attribute.
1243 </desc>
1244
1245 <attribute name="enabled" type="boolean">
1246 <desc>
1247 specifies if the dhcp server is enabled
1248 </desc>
1249 </attribute>
1250
1251 <attribute name="IPAddress" type="wstring" readonly="yes">
1252 <desc>
1253 specifies server IP
1254 </desc>
1255 </attribute>
1256
1257 <attribute name="networkMask" type="wstring" readonly="yes">
1258 <desc>
1259 specifies server network mask
1260 </desc>
1261 </attribute>
1262
1263 <attribute name="networkName" type="wstring" readonly="yes">
1264 <desc>
1265 specifies internal network name the server is used for
1266 </desc>
1267 </attribute>
1268
1269 <attribute name="lowerIP" type="wstring" readonly="yes">
1270 <desc>
1271 specifies from IP adrres in server address range
1272 </desc>
1273 </attribute>
1274
1275 <attribute name="upperIP" type="wstring" readonly="yes">
1276 <desc>
1277 specifies to IP adrres in server address range
1278 </desc>
1279 </attribute>
1280
1281 <method name="setConfiguration">
1282 <desc>
1283 configures the server
1284 <result name="E_INVALIDARG">
1285 invalid configuration supplied
1286 </result>
1287 </desc>
1288 <param name="IPAddress" type="wstring" dir="in">
1289 <desc>
1290 server IP address
1291 </desc>
1292 </param>
1293 <param name="networkMask" type="wstring" dir="in">
1294 <desc>
1295 server network mask
1296 </desc>
1297 </param>
1298 <param name="FromIPAddress" type="wstring" dir="in">
1299 <desc>
1300 server From IP address for address range
1301 </desc>
1302 </param>
1303 <param name="ToIPAddress" type="wstring" dir="in">
1304 <desc>
1305 server To IP address for address range
1306 </desc>
1307 </param>
1308 </method>
1309
1310 <method name="start">
1311 <desc>
1312 Starts DHCP server process.
1313 <result name="E_FAIL">
1314 Failed to start the process.
1315 </result>
1316 </desc>
1317 <param name="networkName" type="wstring" dir="in">
1318 <desc>
1319 Name of internal network DHCP server should attach to.
1320 </desc>
1321 </param>
1322 <param name="trunkName" type="wstring" dir="in">
1323 <desc>
1324 Name of internal network trunk.
1325 </desc>
1326 </param>
1327 <param name="trunkType" type="wstring" dir="in">
1328 <desc>
1329 Type of internal network trunk.
1330 </desc>
1331 </param>
1332 </method>
1333
1334 <method name="stop">
1335 <desc>
1336 Stops DHCP server process.
1337 <result name="E_FAIL">
1338 Failed to stop the process.
1339 </result>
1340 </desc>
1341 </method>
1342 </interface>
1343
1344 <interface
1345 name="IVirtualBox" extends="$dispatched"
1346 uuid="54bf05ec-3fa9-4735-b92e-76e7c6c7e2be"
1347 wsmap="managed"
1348 >
1349 <desc>
1350 The IVirtualBox interface represents the main interface exposed by the
1351 product that provides virtual machine management.
1352
1353 An instance of IVirtualBox is required for the product to do anything
1354 useful. Even though the interface does not expose this, internally,
1355 IVirtualBox is implemented as a singleton and actually lives in the
1356 process of the VirtualBox server (VBoxSVC.exe). This makes sure that
1357 IVirtualBox can track the state of all virtual machines on a particular
1358 host, regardless of which frontend started them.
1359
1360 To enumerate all the virtual machines on the host, use the
1361 <link to="IVirtualBox::machines"/> attribute.
1362 </desc>
1363
1364 <attribute name="version" type="wstring" readonly="yes">
1365 <desc>
1366 A string representing the version number of the product. The
1367 format is 3 integer numbers divided by dots (e.g. 1.0.1). The
1368 last number represents the build number and will frequently change.
1369 </desc>
1370 </attribute>
1371
1372 <attribute name="revision" type="unsigned long" readonly="yes">
1373 <desc>
1374 The internal build revision number of the product.
1375 </desc>
1376 </attribute>
1377
1378 <attribute name="packageType" type="wstring" readonly="yes">
1379 <desc>
1380 A string representing the package type of this product. The
1381 format is OS_ARCH_DIST where OS is either WINDOWS, LINUX,
1382 SOLARIS, DARWIN. ARCH is either 32BITS or 64BITS. DIST
1383 is either GENERIC, UBUNTU_606, UBUNTU_710, or something like
1384 this.
1385 </desc>
1386 </attribute>
1387
1388 <attribute name="homeFolder" type="wstring" readonly="yes">
1389 <desc>
1390 Full path to the directory where the global settings file,
1391 <tt>VirtualBox.xml</tt>, is stored.
1392
1393 In this version of VirtualBox, the value of this property is
1394 always <tt>&lt;user_dir&gt;/.VirtualBox</tt> (where
1395 <tt>&lt;user_dir&gt;</tt> is the path to the user directory,
1396 as determined by the host OS), and cannot be changed.
1397
1398 This path is also used as the base to resolve relative paths in
1399 places where relative paths are allowed (unless otherwise
1400 expressly indicated).
1401 </desc>
1402 </attribute>
1403
1404 <attribute name="settingsFilePath" type="wstring" readonly="yes">
1405 <desc>
1406 Full name of the global settings file.
1407 The value of this property corresponds to the value of
1408 <link to="#homeFolder"/> plus <tt>/VirtualBox.xml</tt>.
1409 </desc>
1410 </attribute>
1411
1412 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
1413 <desc>
1414 Current version of the format of the global VirtualBox settings file
1415 (<tt>VirtualBox.xml</tt>).
1416
1417 The version string has the following format:
1418 <pre>
1419 x.y-platform
1420 </pre>
1421 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
1422 versions, and <tt>platform</tt> is the platform identifier.
1423
1424 The current version usually matches the value of the
1425 <link to="#settingsFormatVersion"/> attribute unless the
1426 settings file was created by an older version of VirtualBox and there
1427 was a change of the settings file format since then.
1428
1429 Note that VirtualBox automatically converts settings files from older
1430 versions to the most recent version when reading them (usually at
1431 VirtualBox startup) but it doesn't save the changes back until
1432 you call a method that implicitly saves settings (such as
1433 <link to="#setExtraData"/>) or call <link to="#saveSettings"/>
1434 explicitly. Therefore, if the value of this attribute differs from the
1435 value of <link to="#settingsFormatVersion"/>, then it
1436 means that the settings file was converted but the result of the
1437 conversion is not yet saved to disk.
1438
1439 The above feature may be used by interactive front-ends to inform users
1440 about the settings file format change and offer them to explicitly save
1441 all converted settings files (the global and VM-specific ones),
1442 optionally create backup copies of the old settings files before saving,
1443 etc.
1444
1445 <see>settingsFormatVersion, saveSettingsWithBackup()</see>
1446 </desc>
1447 </attribute>
1448
1449 <attribute name="settingsFormatVersion" type="wstring" readonly="yes">
1450 <desc>
1451 Most recent version of the settings file format.
1452
1453 The version string has the following format:
1454 <pre>
1455 x.y-platform
1456 </pre>
1457 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
1458 versions, and <tt>platform</tt> is the platform identifier.
1459
1460 VirtualBox uses this version of the format when saving settings files
1461 (either as a result of method calls that require to save settings or as
1462 a result of an explicit call to <link to="#saveSettings"/>).
1463
1464 <see>settingsFileVersion</see>
1465 </desc>
1466 </attribute>
1467
1468 <attribute name="host" type="IHost" readonly="yes">
1469 <desc>Associated host object.</desc>
1470 </attribute>
1471
1472 <attribute name="systemProperties" type="ISystemProperties" readonly="yes">
1473 <desc>Associated system information object.</desc>
1474 </attribute>
1475
1476 <attribute name="machines" type="IMachine" readonly="yes" safearray="yes">
1477 <desc>
1478 Array of machine objects registered within this VirtualBox instance.
1479 </desc>
1480 </attribute>
1481
1482 <attribute name="hardDisks" type="IHardDisk" readonly="yes" safearray="yes">
1483 <desc>
1484 Array of hard disk objects known to this VirtualBox installation.
1485
1486 This array contains only base (root) hard disks. All differencing
1487 hard disks of the given base hard disk can be enumerated using
1488 <link to="IHardDisk::children"/>.
1489 </desc>
1490 </attribute>
1491
1492 <attribute name="DVDImages" type="IDVDImage" readonly="yes" safearray="yes">
1493 <desc>
1494 Array of CD/DVD image objects registered with this VirtualBox instance.
1495 </desc>
1496 </attribute>
1497
1498 <attribute name="floppyImages" type="IFloppyImage" readonly="yes" safearray="yes">
1499 <desc>
1500 Array of floppy image objects registered with this VirtualBox instance.
1501 </desc>
1502 </attribute>
1503
1504 <attribute name="progressOperations" type="IProgress" readonly="yes" safearray="yes"/>
1505
1506 <attribute name="guestOSTypes" type="IGuestOSType" readonly="yes" safearray="yes"/>
1507
1508 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
1509 <desc>
1510 Collection of global shared folders. Global shared folders are
1511 available to all virtual machines.
1512
1513 New shared folders are added to the collection using
1514 <link to="#createSharedFolder"/>. Existing shared folders can be
1515 removed using <link to="#removeSharedFolder"/>.
1516
1517 <note>
1518 In the current version of the product, global shared folders are not
1519 implemented and therefore this collection is always empty.
1520 </note>
1521 </desc>
1522 </attribute>
1523
1524 <attribute name="performanceCollector" type="IPerformanceCollector" readonly="yes">
1525 <desc>
1526 Associated performance collector object.
1527 </desc>
1528 </attribute>
1529
1530 <attribute name="DHCPServers" type="IDHCPServer" safearray="yes" readonly="yes">
1531 <desc>
1532 dhcp server settings.
1533 </desc>
1534 </attribute>
1535
1536 <method name="createMachine">
1537 <desc>
1538 Creates a new virtual machine.
1539
1540 The new machine is created unregistered, with the initial configuration
1541 set according to the specified guest OS type. A typical sequence of
1542 actions to create a new virtual machine is as follows:
1543
1544 <ol>
1545 <li>
1546 Call this method to have a new machine created. The returned machine
1547 object will be "mutable" allowing to change any machine property.
1548 </li>
1549
1550 <li>
1551 Configure the machine using the appropriate attributes and methods.
1552 </li>
1553
1554 <li>
1555 Call <link to="IMachine::saveSettings" /> to write the settings
1556 to the machine's XML settings file. The configuration of the newly
1557 created machine will not be saved to disk until this method is
1558 called.
1559 </li>
1560
1561 <li>
1562 Call <link to="#registerMachine" /> to add the machine to the list
1563 of machines known to VirtualBox.
1564 </li>
1565 </ol>
1566
1567 You should specify valid name for the newly created machine when calling
1568 this method. See the <link to="IMachine::name"/> attribute description
1569 for more details about the machine name.
1570
1571 The specified guest OS type identifier must match an ID of one of known
1572 guest OS types listed in the <link to="IVirtualBox::guestOSTypes"/>
1573 array.
1574
1575 Every machine has a <i>settings file</i> that is used to store
1576 the machine configuration. This file is stored in a directory called the
1577 <i>machine settings subfolder</i>. Both the settings subfolder and file
1578 will have a name that corresponds to the name of the virtual machine.
1579 You can specify where to create the machine setting subfolder using the
1580 @a baseFolder argument. The base folder can be absolute (full path) or
1581 relative to the <link to="IVirtualBox::homeFolder">VirtualBox home
1582 directory</link>.
1583
1584 If @a baseFolder is a null or empty string (which is recommended), the
1585 <link to="ISystemProperties::defaultMachineFolder">default machine
1586 settings folder</link> will be used as a base folder for the created
1587 machine. Otherwise the given base folder will be used. In either case,
1588 the full path to the resulting settings file has the following
1589 structure:
1590 <pre>
1591 &lt;base_folder&gt;/&lt;machine_name&gt;/&lt;machine_name&gt;.xml
1592 </pre>
1593
1594 Note that if the resulting settings file already exists, this method
1595 will fail with <link to="VBOX_E_FILE_ERROR"/>.
1596
1597 Optionally, you may specify an UUID of to assign to the created machine.
1598 However, this is not recommended and you should normally pass an empty
1599 (null) UUID to this method so that a new UUID will be automatically
1600 generated for every created machine. You can use UUID
1601 00000000-0000-0000-0000-000000000000 as null value.
1602
1603 <note>
1604 There is no way to change the name of the settings file or
1605 subfolder of the created machine directly.
1606 </note>
1607
1608 <result name="VBOX_E_OBJECT_NOT_FOUND">
1609 @a osTypeId is invalid.
1610 </result>
1611 <result name="VBOX_E_FILE_ERROR">
1612 Resulting settings file name is invalid or the settings file already
1613 exists or could not be created due to an I/O error.
1614 </result>
1615 <result name="E_INVALIDARG">
1616 @a name is empty or null.
1617 </result>
1618 </desc>
1619
1620 <param name="name" type="wstring" dir="in">
1621 <desc>Machine name.</desc>
1622 </param>
1623 <param name="osTypeId" type="wstring" dir="in">
1624 <desc>Guest OS Type ID.</desc>
1625 </param>
1626 <param name="baseFolder" type="wstring" dir="in">
1627 <desc>Base machine folder (optional).</desc>
1628 </param>
1629 <param name="id" type="wstring" dir="in">
1630 <desc>Machine UUID (optional).</desc>
1631 </param>
1632 <param name="machine" type="IMachine" dir="return">
1633 <desc>Created machine object.</desc>
1634 </param>
1635 </method>
1636
1637 <method name="createLegacyMachine">
1638 <desc>
1639 Creates a new virtual machine in "legacy" mode, using the specified
1640 settings file to store machine settings.
1641
1642 As opposed to machines created by <link to="#createMachine"/>,
1643 the settings file of the machine created in "legacy" mode is not
1644 automatically renamed when the machine name is changed -- it will always
1645 remain the same as specified in this method call.
1646
1647 The specified settings file name can be absolute (full path) or relative
1648 to the <link to="IVirtualBox::homeFolder">VirtualBox home
1649 directory</link>. If the file name doesn't contain an extension, the
1650 default extension (.xml) will be appended.
1651
1652 Note that the configuration of the newly created machine is not
1653 saved to disk (and therefore no settings file is created)
1654 until <link to="IMachine::saveSettings"/> is called. If the
1655 specified settings file already exists, this method
1656 will fail with <link to="VBOX_E_FILE_ERROR"/>.
1657
1658 See <link to="#createMachine"/> for more information.
1659
1660 @deprecated This method may be removed later. Use <link
1661 to="IVirtualBox::createMachine"/> instead.
1662
1663 <note>
1664 There is no way to change the name of the settings file
1665 of the machine created in "legacy" mode.
1666 </note>
1667
1668 <result name="VBOX_E_OBJECT_NOT_FOUND">
1669 @a osTypeId is invalid.
1670 </result>
1671 <result name="VBOX_E_FILE_ERROR">
1672 @a settingsFile is invalid or the settings file already exists or
1673 could not be created due to an I/O error.
1674 </result>
1675 <result name="E_INVALIDARG">
1676 @a name or @a settingsFile is empty or null.
1677 </result>
1678 </desc>
1679
1680 <param name="name" type="wstring" dir="in">
1681 <desc>Machine name.</desc>
1682 </param>
1683 <param name="osTypeId" type="wstring" dir="in">
1684 <desc>Machine OS Type ID.</desc>
1685 </param>
1686 <param name="settingsFile" type="wstring" dir="in">
1687 <desc>Name of the machine settings file.</desc>
1688 </param>
1689 <param name="id" type="wstring" dir="in">
1690 <desc>Machine UUID (optional).</desc>
1691 </param>
1692 <param name="machine" type="IMachine" dir="return">
1693 <desc>Created machine object.</desc>
1694 </param>
1695 </method>
1696
1697 <method name="openMachine">
1698 <desc>
1699 Opens a virtual machine from the existing settings file.
1700 The opened machine remains unregistered until you call
1701 <link to="#registerMachine"/>.
1702
1703 The specified settings file name can be absolute
1704 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1705 VirtualBox home directory</link>. This file must exist
1706 and must be a valid machine settings file whose contents
1707 will be used to construct the machine object.
1708
1709 @deprecated Will be removed soon.
1710 <result name="VBOX_E_FILE_ERROR">
1711 Settings file name invalid, not found or sharing violation.
1712 </result>
1713 </desc>
1714 <param name="settingsFile" type="wstring" dir="in">
1715 <desc>
1716 Name of the machine settings file.
1717 </desc>
1718 </param>
1719 <param name="machine" type="IMachine" dir="return">
1720 <desc>Opened machine object.</desc>
1721 </param>
1722 <note>
1723 <link to="IMachine::settingsModified"/> will return
1724 false for the created machine, until any of machine settings
1725 are changed.
1726 </note>
1727 </method>
1728
1729 <method name="registerMachine">
1730 <desc>
1731
1732 Registers the machine previously created using
1733 <link to="#createMachine"/> or opened using
1734 <link to="#openMachine"/> within this VirtualBox installation. After
1735 successful method invocation, the
1736 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1737 to all registered callbacks.
1738
1739 <note>
1740 This method implicitly calls <link to="IMachine::saveSettings"/>
1741 to save all current machine settings before registering it.
1742 </note>
1743
1744 <result name="VBOX_E_OBJECT_NOT_FOUND">
1745 No matching virtual machine found.
1746 </result>
1747 <result name="VBOX_E_INVALID_OBJECT_STATE">
1748 Virtual machine was not created within this VirtualBox instance.
1749 </result>
1750
1751 </desc>
1752 <param name="machine" type="IMachine" dir="in"/>
1753 </method>
1754
1755 <method name="getMachine">
1756 <desc>
1757 Attempts to find a virtual machine given its UUID.
1758 To look up a machine by name, use <link to="IVirtualBox::findMachine" />
1759 instead.
1760
1761 <result name="VBOX_E_OBJECT_NOT_FOUND">
1762 Could not find registered machine matching @a id.
1763 </result>
1764
1765 </desc>
1766 <param name="id" type="wstring" dir="in"/>
1767 <param name="machine" type="IMachine" dir="return"/>
1768 </method>
1769
1770 <method name="findMachine">
1771 <desc>
1772 Attempts to find a virtual machine given its name.
1773 To look up a machine by UUID, use <link to="IVirtualBox::getMachine" />
1774 instead.
1775
1776 <result name="VBOX_E_OBJECT_NOT_FOUND">
1777 Could not find registered machine matching @a name.
1778 </result>
1779
1780 </desc>
1781 <param name="name" type="wstring" dir="in"/>
1782 <param name="machine" type="IMachine" dir="return"/>
1783 </method>
1784
1785 <method name="unregisterMachine">
1786 <desc>
1787
1788 Unregisters the machine previously registered using
1789 <link to="#registerMachine"/>. After successful method invocation, the
1790 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1791 to all registered callbacks.
1792
1793 <note>
1794 The specified machine must not be in the Saved state, have an open
1795 (or a spawning) direct session associated with it, have snapshots or
1796 have hard disks attached.
1797 </note>
1798
1799 <note>
1800 This method implicitly calls <link to="IMachine::saveSettings"/> to
1801 save all current machine settings before unregistering it.
1802 </note>
1803
1804 <note>
1805 If the given machine is inaccessible (see
1806 <link to="IMachine::accessible"/>), it will be unregistered and
1807 fully uninitialized right afterwards. As a result, the returned
1808 machine object will be unusable and an attempt to call
1809 <b>any</b> method will return the "Object not ready" error.
1810 </note>
1811
1812 <result name="VBOX_E_OBJECT_NOT_FOUND">
1813 Could not find registered machine matching @a id.
1814 </result>
1815 <result name="VBOX_E_INVALID_VM_STATE">
1816 Machine is in Saved state.
1817 </result>
1818 <result name="VBOX_E_INVALID_OBJECT_STATE">
1819 Machine has snapshot or open session or hard disk attached.
1820 </result>
1821
1822 </desc>
1823 <param name="id" type="wstring" dir="in">
1824 <desc>UUID of the machine to unregister.</desc>
1825 </param>
1826 <param name="machine" type="IMachine" dir="return">
1827 <desc>Unregistered machine object.</desc>
1828 </param>
1829 </method>
1830
1831 <method name="createAppliance">
1832 <desc>
1833 Creates a new appliance object, which represents an appliance in the Open Virtual Machine
1834 Format (OVF). This can then be used to import an OVF appliance into VirtualBox or to export
1835 machines as an OVF appliance; see the documentation for <link to="IAppliance" /> for details.
1836 </desc>
1837 <param name="appliance" type="IAppliance" dir="return">
1838 <desc>New appliance.</desc>
1839 </param>
1840 </method>
1841
1842 <method name="createHardDisk">
1843 <desc>
1844 Creates a new base hard disk object that will use the given storage
1845 format and location for hard disk data.
1846
1847 Note that the actual storage unit is not created by this method. In
1848 order to do it, and before you are able to attach the created hard disk
1849 to virtual machines, you must call one of the following methods to
1850 allocate a format-specific storage unit at the specified location:
1851 <ul>
1852 <li><link to="IHardDisk::createBaseStorage"/></li>
1853 <li><link to="IHardDisk::createDiffStorage"/></li>
1854 </ul>
1855
1856 Some hard disk attributes, such as <link to="IHardDisk::id"/>, may
1857 remain uninitialized until the hard disk storage unit is successfully
1858 created by one of the above methods.
1859
1860 After the storage unit is successfully created, the hard disk gets
1861 remembered by this VirtualBox installation and will be accessible
1862 through <link to="#getHardDisk"/> and <link to="#findHardDisk"/>
1863 methods. Remembered root (base) hard disks are also returned as part of
1864 the <link to="#hardDisks"/> array. See IHardDisk for more details.
1865
1866 The list of all storage formats supported by this VirtualBox
1867 installation can be obtained using
1868 <link to="ISystemProperties::hardDiskFormats"/>. If the @a format
1869 attribute is empty or <tt>null</tt> then the default storage format
1870 specified by <link to="ISystemProperties::defaultHardDiskFormat"/> will
1871 be used for creating a storage unit of the hard disk.
1872
1873 Note that the format of the location string is storage format specific.
1874 See <link to="IMedium::location"/>, IHardDisk and
1875 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1876
1877 <result name="VBOX_E_OBJECT_NOT_FOUND">
1878 @a format identifier is invalid. See
1879 <link to="ISystemProperties::hardDiskFormats"/>.
1880 </result>
1881 <result name="VBOX_E_FILE_ERROR">
1882 @a location is a not valid file name (for file-based formats only).
1883 </result>
1884 <result name="E_INVALIDARG">
1885 @a format is a null or empty string.
1886 </result>
1887 </desc>
1888 <param name="format" type="wstring" dir="in">
1889 <desc>
1890 Identifier of the storage format to use for the new hard disk.
1891 </desc>
1892 </param>
1893 <param name="location" type="wstring" dir="in">
1894 <desc>
1895 Location of the storage unit for the new hard disk.
1896 </desc>
1897 </param>
1898 <param name="hardDisk" type="IHardDisk" dir="return">
1899 <desc>Created hard disk object.</desc>
1900 </param>
1901 </method>
1902
1903 <method name="openHardDisk">
1904 <desc>
1905 Opens a hard disk from an existing location, optionally replacing
1906 the image UUID and/or parent UUID.
1907
1908 After the hard disk is successfully opened by this method, it gets
1909 remembered by (known to) this VirtualBox installation and will be
1910 accessible through <link to="#getHardDisk"/> and
1911 <link to="#findHardDisk"/> methods. Remembered root (base) hard disks
1912 are also returned as part of the <link to="#hardDisks"/> array and can
1913 be attached to virtual machines. See IHardDisk for more details.
1914
1915 If a differencing hard disk is to be opened by this method, the
1916 operation will succeed only if its parent hard disk and all ancestors,
1917 if any, are already known to this VirtualBox installation (for example,
1918 were opened by this method before).
1919
1920 This method tries to guess the storage format of the specified hard disk
1921 by reading hard disk data at the specified location.
1922
1923 If @a write is ReadWrite (which it should be), the image is opened for
1924 read/write access and must have according permissions, as VirtualBox
1925 may actually write status information into the disk's metadata sections.
1926
1927 Note that write access is required for all typical image usage in VirtualBox,
1928 since VirtualBox may need to write metadata such as a UUID into the image.
1929 The only exception is opening a source image temporarily for copying and
1930 cloning when the image will quickly be closed again.
1931
1932 Note that the format of the location string is storage format specific.
1933 See <link to="IMedium::location"/>, IHardDisk and
1934 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1935
1936 <result name="VBOX_E_FILE_ERROR">
1937 Invalid hard disk storage file location or could not find the hard
1938 disk at the specified location.
1939 </result>
1940 <result name="VBOX_E_IPRT_ERROR">
1941 Could not get hard disk storage format.
1942 </result>
1943 <result name="E_INVALIDARG">
1944 Invalid hard disk storage format.
1945 </result>
1946
1947 </desc>
1948 <param name="location" type="wstring" dir="in">
1949 <desc>
1950 Location of the storage unit that contains hard disk data in one of
1951 the supported storage formats.
1952 </desc>
1953 </param>
1954 <param name="accessMode" type="AccessMode" dir="in">
1955 <desc>
1956 Determines whether to open the image in read/write or read-only mode.
1957 </desc>
1958 </param>
1959 <param name="setImageId" type="boolean" dir="in">
1960 <desc>
1961 Select whether a new image UUID is set or not.
1962 </desc>
1963 </param>
1964 <param name="imageId" type="wstring" dir="in">
1965 <desc>
1966 New UUID for the image. If an empty string is passed, then a new
1967 UUID is automatically created. Specifying a zero UUIDs is not valid.
1968 </desc>
1969 </param>
1970 <param name="setParentId" type="boolean" dir="in">
1971 <desc>
1972 Select whether a new parent UUID is set or not.
1973 </desc>
1974 </param>
1975 <param name="parentId" type="wstring" dir="in">
1976 <desc>
1977 New parent UUID for the image. If an empty string is passed, then a
1978 new UUID is automatically created, provided @a setParentId is
1979 @c true. A zero UUID is valid.
1980 </desc>
1981 </param>
1982 <param name="hardDisk" type="IHardDisk" dir="return">
1983 <desc>Opened hard disk object.</desc>
1984 </param>
1985 </method>
1986
1987 <method name="getHardDisk" const="yes">
1988 <desc>
1989 Returns a hard disk with the given UUID.
1990
1991 The hard disk with the given UUID must be known to this VirtualBox
1992 installation, i.e. it must be previously created by
1993 <link to="#createHardDisk"/> or opened by <link
1994 to="#openHardDisk"/>, or attached to some known virtual machine.
1995
1996 <result name="VBOX_E_OBJECT_NOT_FOUND">
1997 No hard disk object matching @a id found.
1998 </result>
1999
2000 </desc>
2001 <param name="id" type="wstring" dir="in">
2002 <desc>UUID of the hard disk to look for.</desc>
2003 </param>
2004 <param name="hardDisk" type="IHardDisk" dir="return">
2005 <desc>Found hard disk object.</desc>
2006 </param>
2007 </method>
2008
2009 <method name="findHardDisk">
2010 <desc>
2011 Returns a hard disk that uses the given location to store hard
2012 disk data.
2013
2014 The given hard disk must be known to this VirtualBox installation, i.e.
2015 it must be previously created by
2016 <link to="#createHardDisk"/> or opened by <link
2017 to="#openHardDisk"/>, or attached to some known virtual machine.
2018
2019 The search is done by comparing the value of the @a location argument to
2020 the <link to="IHardDisk::location"/> attribute of each known hard
2021 disk.
2022
2023 For locations represented by file names in the host's file system, the
2024 requested location can be a path relative to the
2025 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
2026 only a file name without any path is given, the
2027 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
2028 folder</link> will be prepended to the file name before searching. Note
2029 that on case sensitive file systems, a case sensitive comparison is
2030 performed, otherwise the case of symbols in the file path is ignored.
2031
2032 <result name="VBOX_E_OBJECT_NOT_FOUND">
2033 No hard disk object matching @a location found.
2034 </result>
2035
2036 </desc>
2037 <param name="location" type="wstring" dir="in">
2038 <desc>Location string to search for.</desc>
2039 </param>
2040 <param name="hardDisk" type="IHardDisk" dir="return">
2041 <desc>Found hard disk object.</desc>
2042 </param>
2043 </method>
2044
2045 <method name="openDVDImage">
2046 <desc>
2047 Opens a CD/DVD image contained in the specified file of the supported
2048 format and assigns it the given UUID.
2049
2050 After the image is successfully opened by this method, it gets
2051 remembered by (known to) this VirtualBox installation and will be
2052 accessible through <link to="#getDVDImage"/> and
2053 <link to="#findDVDImage"/> methods. Remembered images are also
2054 returned as part of the <link to="#DVDImages"/> array and can be mounted
2055 to virtual machines. See IMedium for more details.
2056
2057 See <link to="IMedium::location"/> to get more details about the format
2058 of the location string.
2059
2060 <note>
2061 Currently only ISO 9960 CD/DVD images are supported by VirtualBox.
2062 </note>
2063
2064 <result name="VBOX_E_FILE_ERROR">
2065 Invalid CD/DVD image file location or could not find the CD/DVD
2066 image at the specified location.
2067 </result>
2068 <result name="VBOX_E_INVALID_OBJECT_STATE">
2069 CD/DVD image already exists in the media registry.
2070 </result>
2071
2072 </desc>
2073 <param name="location" type="wstring" dir="in">
2074 <desc>
2075 Full path to the file that contains a valid CD/DVD image.
2076 </desc>
2077 </param>
2078 <param name="id" type="wstring" dir="in">
2079 <desc>
2080 UUID to assign to the given image within this VirtualBox installation.
2081 If an empty (null) UUID is specified, the system will randomly
2082 generate a new UUID.
2083 </desc>
2084 </param>
2085 <param name="image" type="IDVDImage" dir="return">
2086 <desc>Opened CD/DVD image object.</desc>
2087 </param>
2088 </method>
2089
2090 <method name="getDVDImage">
2091 <desc>
2092 Returns a CD/DVD image with the given UUID.
2093
2094 The image with the given UUID must be known to this VirtualBox
2095 installation, i.e. it must be previously opened by <link
2096 to="#openDVDImage"/>, or mounted to some known virtual machine.
2097
2098 <result name="VBOX_E_OBJECT_NOT_FOUND">
2099 No matching DVD image found in the media registry.
2100 </result>
2101
2102 </desc>
2103 <param name="id" type="wstring" dir="in">
2104 <desc>UUID of the image to look for.</desc>
2105 </param>
2106 <param name="image" type="IDVDImage" dir="return">
2107 <desc>Found CD/DVD image object.</desc>
2108 </param>
2109 </method>
2110
2111 <method name="findDVDImage">
2112 <desc>
2113 Returns a CD/DVD image with the given image location.
2114
2115 The image with the given UUID must be known to this VirtualBox
2116 installation, i.e. it must be previously opened by <link
2117 to="#openDVDImage"/>, or mounted to some known virtual machine.
2118
2119 The search is done by comparing the value of the @a location argument to
2120 the <link to="IMedium::location"/> attribute of each known CD/DVD image.
2121
2122 The requested location can be a path relative to the
2123 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
2124 only a file name without any path is given, the
2125 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
2126 folder</link> will be prepended to the file name before searching. Note
2127 that on case sensitive file systems, a case sensitive comparison is
2128 performed, otherwise the case in the file path is ignored.
2129
2130 <result name="VBOX_E_FILE_ERROR">
2131 Invalid image file location.
2132 </result>
2133 <result name="VBOX_E_OBJECT_NOT_FOUND">
2134 No matching DVD image found in the media registry.
2135 </result>
2136
2137 </desc>
2138 <param name="location" type="wstring" dir="in">
2139 <desc>CD/DVD image file path to look for.</desc>
2140 </param>
2141 <param name="image" type="IDVDImage" dir="return">
2142 <desc>Found CD/DVD image object.</desc>
2143 </param>
2144 </method>
2145
2146 <method name="openFloppyImage">
2147 <desc>
2148 Opens a floppy image contained in the specified file of the supported
2149 format and assigns it the given UUID.
2150
2151 After the image is successfully opened by this method, it gets
2152 remembered by (known to) this VirtualBox installation and will be
2153 accessible through <link to="#getFloppyImage"/> and
2154 <link to="#findFloppyImage"/> methods. Remembered images are also
2155 returned as part of the <link to="#floppyImages"/> array and can be
2156 mounted to virtual machines. See IMedium for more details.
2157
2158 See <link to="IMedium::location"/> to get more details about the format
2159 of the location string.
2160
2161 <result name="VBOX_E_FILE_ERROR">
2162 Invalid floppy image file location or could not find the floppy
2163 image at the specified location.
2164 </result>
2165 <result name="VBOX_E_INVALID_OBJECT_STATE">
2166 Floppy image already exists in the media registry.
2167 </result>
2168
2169 <note>
2170 Currently, only raw floppy images are supported by VirtualBox.
2171 </note>
2172 </desc>
2173 <param name="location" type="wstring" dir="in">
2174 <desc>
2175 Full path to the file that contains a valid floppy image.
2176 </desc>
2177 </param>
2178 <param name="id" type="wstring" dir="in">
2179 <desc>
2180 UUID to assign to the given image file within this VirtualBox
2181 installation. If an empty (null) UUID is specified, the system will
2182 randomly generate a new UUID.
2183 </desc>
2184 </param>
2185 <param name="image" type="IFloppyImage" dir="return">
2186 <desc>Opened floppy image object.</desc>
2187 </param>
2188 </method>
2189
2190 <method name="getFloppyImage">
2191 <desc>
2192 Returns a floppy image with the given UUID.
2193
2194 The image with the given UUID must be known to this VirtualBox
2195 installation, i.e. it must be previously opened by <link
2196 to="#openFloppyImage"/>, or mounted to some known virtual machine.
2197
2198 <result name="VBOX_E_OBJECT_NOT_FOUND">
2199 No matching floppy image found in the media registry.
2200 </result>
2201
2202 </desc>
2203 <param name="id" type="wstring" dir="in">
2204 <desc>UUID of the image to look for.</desc>
2205 </param>
2206 <param name="image" type="IFloppyImage" dir="return">
2207 <desc>Found floppy image object.</desc>
2208 </param>
2209 </method>
2210
2211 <method name="findFloppyImage">
2212 <desc>
2213 Returns a floppy image with the given image location.
2214
2215 The image with the given UUID must be known to this VirtualBox
2216 installation, i.e. it must be previously opened by <link
2217 to="#openFloppyImage"/>, or mounted to some known virtual machine.
2218
2219 The search is done by comparing the value of the @a location argument to
2220 the <link to="IMedium::location"/> attribute of each known floppy image.
2221
2222 The requested location can be a path relative to the
2223 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
2224 only a file name without any path is given, the
2225 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
2226 folder</link> will be prepended to the file name before searching. Note
2227 that on case sensitive file systems, a case sensitive comparison is
2228 performed, otherwise the case of symbols in the file path is ignored.
2229
2230 <result name="VBOX_E_FILE_ERROR">
2231 Invalid image file location.
2232 </result>
2233 <result name="VBOX_E_OBJECT_NOT_FOUND">
2234 No matching floppy image found in the media registry.
2235 </result>
2236
2237 </desc>
2238 <param name="location" type="wstring" dir="in">
2239 <desc>Floppy image file path to look for.</desc>
2240 </param>
2241 <param name="image" type="IFloppyImage" dir="return">
2242 <desc>Found floppy image object.</desc>
2243 </param>
2244 </method>
2245
2246 <method name="getGuestOSType">
2247 <desc>
2248 Returns an object describing the specified guest OS type.
2249
2250 The requested guest OS type is specified using a string which is a
2251 mnemonic identifier of the guest operating system, such as
2252 <tt>"win31"</tt> or <tt>"ubuntu"</tt>. The guest OS type ID of a
2253 particular virtual machine can be read or set using the
2254 <link to="IMachine::OSTypeId"/> attribute.
2255
2256 The <link to="IVirtualBox::guestOSTypes"/> collection contains all
2257 available guest OS type objects. Each object has an
2258 <link to="IGuestOSType::id"/> attribute which contains an identifier of
2259 the guest OS this object describes.
2260
2261 <result name="E_INVALIDARG">
2262 @a id is not a valid Guest OS type.
2263 </result>
2264
2265 </desc>
2266 <param name="id" type="wstring" dir="in">
2267 <desc>Guest OS type ID string.</desc>
2268 </param>
2269 <param name="type" type="IGuestOSType" dir="return">
2270 <desc>Guest OS type object.</desc>
2271 </param>
2272 </method>
2273
2274 <method name="createSharedFolder">
2275 <desc>
2276 Creates a new global shared folder by associating the given logical
2277 name with the given host path, adds it to the collection of shared
2278 folders and starts sharing it. Refer to the description of
2279 <link to="ISharedFolder"/> to read more about logical names.
2280 <note>
2281 In the current implementation, this operation is not
2282 implemented.
2283 </note>
2284 </desc>
2285 <param name="name" type="wstring" dir="in">
2286 <desc>Unique logical name of the shared folder.</desc>
2287 </param>
2288 <param name="hostPath" type="wstring" dir="in">
2289 <desc>Full path to the shared folder in the host file system.</desc>
2290 </param>
2291 <param name="writable" type="boolean" dir="in">
2292 <desc>Whether the share is writable or readonly</desc>
2293 </param>
2294 </method>
2295
2296 <method name="removeSharedFolder">
2297 <desc>
2298 Removes the global shared folder with the given name previously
2299 created by <link to="#createSharedFolder"/> from the collection of
2300 shared folders and stops sharing it.
2301 <note>
2302 In the current implementation, this operation is not
2303 implemented.
2304 </note>
2305 </desc>
2306 <param name="name" type="wstring" dir="in">
2307 <desc>Logical name of the shared folder to remove.</desc>
2308 </param>
2309 </method>
2310
2311 <method name="getNextExtraDataKey">
2312 <desc>
2313 Returns the global extra data key name following the supplied key.
2314
2315 An error is returned if the supplied @a key does not exist. @c NULL is
2316 returned in @a nextKey if the supplied key is the last key. When
2317 supplying @c NULL or an empty string for the @a key, the first key item
2318 is returned in @a nextKey (if there is any). @a nextValue is an optional
2319 parameter and if supplied, the next key's value is returned in it.
2320
2321 <result name="VBOX_E_OBJECT_NOT_FOUND">
2322 Extra data @a key not found.
2323 </result>
2324
2325 </desc>
2326 <param name="key" type="wstring" dir="in">
2327 <desc>Name of the data key to follow.</desc>
2328 </param>
2329 <param name="nextKey" type="wstring" dir="out">
2330 <desc>Name of the next data key.</desc>
2331 </param>
2332 <param name="nextValue" type="wstring" dir="out">
2333 <desc>Value of the next data key.</desc>
2334 </param>
2335 </method>
2336
2337 <method name="getExtraData">
2338 <desc>
2339 Returns associated global extra data.
2340
2341 If the requested data @a key does not exist, this function will
2342 succeed and return @c NULL in the @a value argument.
2343
2344 <result name="VBOX_E_FILE_ERROR">
2345 Settings file not accessible.
2346 </result>
2347 <result name="VBOX_E_XML_ERROR">
2348 Could not parse the settings file.
2349 </result>
2350
2351 </desc>
2352 <param name="key" type="wstring" dir="in">
2353 <desc>Name of the data key to get.</desc>
2354 </param>
2355 <param name="value" type="wstring" dir="return">
2356 <desc>Value of the requested data key.</desc>
2357 </param>
2358 </method>
2359
2360 <method name="setExtraData">
2361 <desc>
2362 Sets associated global extra data.
2363
2364 If you pass @c NULL as a key @a value, the given @a key will be
2365 deleted.
2366
2367 <note>
2368 Before performing the actual data change, this method will ask all
2369 registered callbacks using the
2370 <link to="IVirtualBoxCallback::onExtraDataCanChange"/>
2371 notification for a permission. If one of the callbacks refuses the
2372 new value, the change will not be performed.
2373 </note>
2374 <note>
2375 On success, the
2376 <link to="IVirtualBoxCallback::onExtraDataChange"/> notification
2377 is called to inform all registered callbacks about a successful data
2378 change.
2379 </note>
2380
2381 <result name="VBOX_E_FILE_ERROR">
2382 Settings file not accessible.
2383 </result>
2384 <result name="VBOX_E_XML_ERROR">
2385 Could not parse the settings file.
2386 </result>
2387 <result name="E_ACCESSDENIED">
2388 Modification request refused.
2389 </result>
2390
2391 </desc>
2392 <param name="key" type="wstring" dir="in">
2393 <desc>Name of the data key to set.</desc>
2394 </param>
2395 <param name="value" type="wstring" dir="in">
2396 <desc>Value to assign to the key.</desc>
2397 </param>
2398 </method>
2399
2400 <method name="openSession">
2401 <desc>
2402 Opens a new direct session with the given virtual machine.
2403
2404 A direct session acts as a local lock on the given VM.
2405 There can be only one direct session open at a time for every
2406 virtual machine, protecting the VM from being manipulated by
2407 conflicting actions from different processes. Only after a
2408 direct session has been opened, one can change all VM settings
2409 and execute the VM in the process space of the session object.
2410
2411 Sessions therefore can be compared to mutex semaphores that
2412 lock a given VM for modification and execution.
2413 See <link to="ISession">ISession</link> for details.
2414
2415 <note>Unless you are writing a new VM frontend, you will not
2416 want to execute a VM in the current process. To spawn a new
2417 process that executes a VM, use
2418 <link to="IVirtualBox::openRemoteSession" />
2419 instead.</note>
2420
2421 Upon successful return, the session object can be used to
2422 get access to the machine and to the VM console.
2423
2424 In VirtualBox terminology, the machine becomes "mutable" after
2425 a session has been opened. Note that the "mutable" machine
2426 object, on which you may invoke IMachine methods to change its
2427 settings, will be a different object from the immutable IMachine
2428 objects returned by various IVirtualBox methods. To obtain a
2429 mutable IMachine object (upon which you can invoke settings methods),
2430 use the <link to="ISession::machine" /> attribute.
2431
2432 One must always call <link to="ISession::close" /> to release the
2433 lock on the machine, or the machine's state will eventually be
2434 set to "Aborted".
2435
2436 In other words, to change settings on a machine, the following
2437 sequence is typically performed:
2438
2439 <ol>
2440 <li>Call this method (openSession) to have a machine locked for
2441 the current session.</li>
2442
2443 <li>Obtain a mutable IMachine object from <link to="ISession::machine" />.</li>
2444
2445 <li>Change the settings of the machine.</li>
2446
2447 <li>Call <link to="IMachine::saveSettings" />.</li>
2448
2449 <li>Close the session by calling <link to="ISession::close"/>.</li>
2450 </ol>
2451
2452 <result name="E_UNEXPECTED">
2453 Virtual machine not registered.
2454 </result>
2455 <result name="E_ACCESSDENIED">
2456 Process not started by OpenRemoteSession.
2457 </result>
2458 <result name="VBOX_E_OBJECT_NOT_FOUND">
2459 No matching virtual machine found.
2460 </result>
2461 <result name="VBOX_E_INVALID_OBJECT_STATE">
2462 Session already open or being opened.
2463 </result>
2464 <result name="VBOX_E_VM_ERROR">
2465 Failed to assign machine to session.
2466 </result>
2467
2468 </desc>
2469 <param name="session" type="ISession" dir="in">
2470 <desc>
2471 Session object that will represent the opened session after
2472 successful method invocation. This object must not represent
2473 the already open session.
2474 <note>
2475 This session will be automatically closed if the
2476 VirtualBox server is terminated for some reason.
2477 </note>
2478 </desc>
2479 </param>
2480 <param name="machineId" type="wstring" dir="in">
2481 <desc>ID of the virtual machine to open a session with.</desc>
2482 </param>
2483 </method>
2484
2485 <method name="openRemoteSession">
2486 <desc>
2487 Spawns a new process that executes a virtual machine (called a
2488 "remote session").
2489
2490 Opening a remote session causes the VirtualBox server to start a new
2491 process that opens a direct session with the given VM. As a result, the
2492 VM is locked by that direct session in the new process, preventing
2493 conflicting changes from other processes. Since sessions act as locks
2494 that prevent conflicting changes, one cannot open a remote session
2495 for a VM that already has another open session (direct or remote), or
2496 is currently in the process of opening one (see <link
2497 to="IMachine::sessionState"/>).
2498
2499 While the remote session still provides some level of control over the
2500 VM execution to the caller (using the <link to="IConsole" /> interface),
2501 not all VM settings are available for modification within the remote
2502 session context.
2503
2504 This operation can take some time (a new VM is started in a new process,
2505 for which memory and other resources need to be set up). Because of this,
2506 an <link to="IProgress" /> is returned to allow the caller to wait for this
2507 asynchronous operation to be completed. Until then, the remote session
2508 object remains in the closed state, and accessing the machine or its
2509 console through it is invalid. It is recommended to use
2510 <link to="IProgress::waitForCompletion" /> or similar calls to wait for
2511 completion.
2512
2513 As with all <link to="ISession" /> objects, it is recommended to call
2514 <link to="ISession::close" /> on the local session object once openRemoteSession()
2515 has been called. However, the session's state (see <link to="ISession::state" />)
2516 will not return to "Closed" until the remote session has also closed (i.e.
2517 until the VM is no longer running). In that case, however, the state of
2518 the session will automatically change back to "Closed".
2519
2520 Currently supported session types (values of the @a type
2521 argument) are:
2522 <ul>
2523 <li><tt>gui</tt>: VirtualBox Qt GUI session</li>
2524 <li><tt>vrdp</tt>: VirtualBox VRDP Server session</li>
2525 <li><tt>sdl</tt>: VirtualBox SDL GUI session</li>
2526 </ul>
2527
2528 The @a environment argument is a string containing definitions of
2529 environment variables in the following format:
2530 @code
2531 NAME[=VALUE]\n
2532 NAME[=VALUE]\n
2533 ...
2534 @endcode
2535 where <tt>\\n</tt> is the new line character. These environment
2536 variables will be appended to the environment of the VirtualBox server
2537 process. If an environment variable exists both in the server process
2538 and in this list, the value from this list takes precedence over the
2539 server's variable. If the value of the environment variable is
2540 omitted, this variable will be removed from the resulting environment.
2541 If the environment string is @c null, the server environment is
2542 inherited by the started process as is.
2543
2544 <see>openExistingSession</see>
2545
2546 <result name="E_UNEXPECTED">
2547 Virtual machine not registered.
2548 </result>
2549 <result name="E_INVALIDARG">
2550 Invalid session type @a type.
2551 </result>
2552 <result name="VBOX_E_OBJECT_NOT_FOUND">
2553 No machine matching @a machineId found.
2554 </result>
2555 <result name="VBOX_E_INVALID_OBJECT_STATE">
2556 Session already open or being opened.
2557 </result>
2558 <result name="VBOX_E_IPRT_ERROR">
2559 Launching process for machine failed.
2560 </result>
2561 <result name="VBOX_E_VM_ERROR">
2562 Failed to assign machine to session.
2563 </result>
2564
2565 </desc>
2566 <param name="session" type="ISession" dir="in">
2567 <desc>
2568 Session object that will represent the opened remote session
2569 after successful method invocation (this object must not
2570 represent an already open session).
2571 </desc>
2572 </param>
2573 <param name="machineId" type="wstring" dir="in">
2574 <desc>ID of the virtual machine to open a session with.</desc>
2575 </param>
2576 <param name="type" type="wstring" dir="in">
2577 <desc>
2578 Type of the remote session (case sensitive).
2579 </desc>
2580 </param>
2581 <param name="environment" type="wstring" dir="in">
2582 <desc>
2583 Environment to pass to the opened session (may be @c null).
2584 </desc>
2585 </param>
2586 <param name="progress" type="IProgress" dir="return">
2587 <desc>Progress object to track the operation completion.</desc>
2588 </param>
2589 </method>
2590
2591 <method name="openExistingSession">
2592 <desc>
2593 Opens a new remote session with the virtual machine for
2594 which a direct session is already open.
2595
2596 The remote session provides some level of control over the VM
2597 execution (using the IConsole interface) to the caller; however,
2598 within the remote session context, not all VM settings are available
2599 for modification.
2600
2601 As opposed to <link to="#openRemoteSession"/>, the number of
2602 remote sessions opened this way is not limited by the API
2603
2604 <note>
2605 It is an error to open a remote session with the machine that
2606 doesn't have an open direct session.
2607 </note>
2608
2609 <result name="E_UNEXPECTED">
2610 Virtual machine not registered.
2611 </result>
2612 <result name="VBOX_E_OBJECT_NOT_FOUND">
2613 No machine matching @a machineId found.
2614 </result>
2615 <result name="VBOX_E_INVALID_OBJECT_STATE">
2616 Session already open or being opened.
2617 </result>
2618 <result name="VBOX_E_INVALID_SESSION_STATE">
2619 Direct session state not Open.
2620 </result>
2621 <result name="VBOX_E_VM_ERROR">
2622 Failed to get console object from direct session or assign
2623 machine to session.
2624 </result>
2625
2626 <see>openRemoteSession</see>
2627 </desc>
2628 <param name="session" type="ISession" dir="in">
2629 <desc>
2630 Session object that will represent the open remote session
2631 after successful method invocation. This object must not
2632 represent an already open session.
2633 <note>
2634 This session will be automatically closed when the peer
2635 (direct) session dies or gets closed.
2636 </note>
2637 </desc>
2638 </param>
2639 <param name="machineId" type="wstring" dir="in">
2640 <desc>ID of the virtual machine to open a session with.</desc>
2641 </param>
2642 </method>
2643
2644 <method name="registerCallback">
2645 <desc>
2646 Registers a new global VirtualBox callback. The methods of the given
2647 callback object will be called by VirtualBox when an appropriate
2648 event occurs.
2649
2650 <result name="E_INVALIDARG">
2651 A @c NULL callback cannot be registered.
2652 </result>
2653
2654 </desc>
2655 <param name="callback" type="IVirtualBoxCallback" dir="in">
2656 <desc>Callback object to register.</desc>
2657 </param>
2658 </method>
2659
2660 <method name="unregisterCallback">
2661 <desc>
2662 Unregisters the previously registered global VirtualBox callback.
2663
2664 <result name="E_INVALIDARG">
2665 Specified @a callback not registered.
2666 </result>
2667
2668 </desc>
2669 <param name="callback" type="IVirtualBoxCallback" dir="in">
2670 <desc>Callback object to unregister.</desc>
2671 </param>
2672 </method>
2673
2674 <method name="waitForPropertyChange">
2675 <desc>
2676 Blocks the caller until any of the properties represented by the
2677 @a what argument changes the value or until the given timeout interval
2678 expires.
2679
2680 The @a what argument is a comma separated list of property masks that
2681 describe properties the caller is interested in. The property mask is
2682 a string in the following format:
2683
2684 <pre>
2685 [[group.]subgroup.]name
2686 </pre>
2687
2688 where @c name is the property name and @c group, @c subgroup are zero
2689 or more property group specifiers. Each element (group or name) in
2690 the property mask may be either a Latin string or an asterisk symbol
2691 (@c "*") which is used to match any string for the given element. A
2692 property mask that doesn't contain asterisk symbols represents a
2693 single fully qualified property name.
2694
2695 Groups in the fully qualified property name go from more generic (the
2696 left-most part) to more specific (the right-most part). The first
2697 element is usually a name of the object the property belongs to. The
2698 second element may be either a property name, or a child object name,
2699 or an index if the preceding element names an object which is one of
2700 many objects of the same type. This way, property names form a
2701 hierarchy of properties. Here are some examples of property names:
2702
2703 <table>
2704 <tr>
2705 <td><tt>VirtualBox.version</tt></td>
2706 <td><link to="IVirtualBox::version"/> property</td>
2707 </tr>
2708 <tr>
2709 <td><tt>Machine.&lt;UUID&gt;.name</tt></td>
2710 <td><link to="IMachine::name"/> property of the machine with the
2711 given UUID</td>
2712 </tr>
2713 </table>
2714
2715 Most property names directly correspond to the properties of objects
2716 (components) provided by the VirtualBox library and may be used to
2717 track changes to these properties. However, there may be
2718 pseudo-property names that don't correspond to any existing object's
2719 property directly, as well as there may be object properties that
2720 don't have a corresponding property name that is understood by this
2721 method, and therefore changes to such properties cannot be
2722 tracked. See individual object's property descriptions to get a
2723 fully qualified property name that can be used with this method (if
2724 any).
2725
2726 There is a special property mask @c "*" (i.e. a string consisting of a
2727 single asterisk symbol) that can be used to match all properties.
2728 Below are more examples of property masks:
2729
2730 <table>
2731 <tr>
2732 <td><tt>VirtualBox.*</tt></td>
2733 <td>Track all properties of the VirtualBox object</td>
2734 </tr>
2735 <tr>
2736 <td><tt>Machine.*.name</tt></td>
2737 <td>Track changes to the <link to="IMachine::name"/> property of
2738 all registered virtual machines</td>
2739 </tr>
2740 </table>
2741
2742 <note>
2743 This function is not implemented in the current version of the
2744 product.
2745 </note>
2746 </desc>
2747 <param name="what" type="wstring" dir="in">
2748 <desc>Comma separated list of property masks.</desc>
2749 </param>
2750 <param name="timeout" type="unsigned long" dir="in">
2751 <desc>
2752 Wait timeout in milliseconds.
2753 Specify -1 for an indefinite wait.
2754 </desc>
2755 </param>
2756 <param name="changed" type="wstring" dir="out">
2757 <desc>
2758 Comma separated list of properties that have been changed and caused
2759 this method to return to the caller.
2760 </desc>
2761 </param>
2762 <param name="values" type="wstring" dir="out">
2763 <desc>Reserved, not currently used.</desc>
2764 </param>
2765 </method>
2766
2767 <method name="saveSettings">
2768 <desc>
2769 Saves the global settings to the global settings file
2770 (<link to="#settingsFilePath"/>).
2771
2772 This method is only useful for explicitly saving the global settings
2773 file after it has been auto-converted from the old format to the most
2774 recent format (see <link to="#settingsFileVersion"/> for details).
2775 Normally, the global settings file is implicitly saved when a global
2776 setting is changed.
2777
2778 <result name="VBOX_E_FILE_ERROR">
2779 Settings file not accessible.
2780 </result>
2781 <result name="VBOX_E_XML_ERROR">
2782 Could not parse the settings file.
2783 </result>
2784
2785 </desc>
2786 </method>
2787
2788 <method name="saveSettingsWithBackup">
2789 <desc>
2790 Creates a backup copy of the global settings file
2791 (<link to="IVirtualBox::settingsFilePath"/>) in case of auto-conversion,
2792 and then calls <link to="IVirtualBox::saveSettings"/>.
2793
2794 Note that the backup copy is created <b>only</b> if the settings file
2795 auto-conversion took place (see <link to="#settingsFileVersion"/> for
2796 details). Otherwise, this call is fully equivalent to
2797 <link to="IVirtualBox::saveSettings"/> and no backup copying is done.
2798
2799 The backup copy is created in the same directory where the original
2800 settings file is located. It is given the following file name:
2801 <pre>
2802 original.xml.x.y-platform.bak
2803 </pre>
2804 where <tt>original.xml</tt> is the original settings file name
2805 (excluding path), and <tt>x.y-platform</tt> is the version of the old
2806 format of the settings file (before auto-conversion).
2807
2808 If the given backup file already exists, this method will try to add the
2809 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
2810 0 to 9) and copy it again until it succeeds. If all suffixes are
2811 occupied, or if any other copy error occurs, this method will return a
2812 failure.
2813
2814 If the copy operation succeeds, the @a bakFileName return argument will
2815 receive a full path to the created backup file (for informational
2816 purposes). Note that this will happen even if the subsequent
2817 <link to="#saveSettings"/> call performed by this method after the
2818 copy operation, fails.
2819
2820 <note>
2821 The VirtualBox API never calls this method. It is intended purely for
2822 the purposes of creating backup copies of the settings files by
2823 front-ends before saving the results of the automatically performed
2824 settings conversion to disk.
2825 </note>
2826
2827 <see>settingsFileVersion</see>
2828
2829 <result name="VBOX_E_FILE_ERROR">
2830 Settings file not accessible.
2831 </result>
2832 <result name="VBOX_E_XML_ERROR">
2833 Could not parse the settings file.
2834 </result>
2835 <result name="VBOX_E_IPRT_ERROR">
2836 Could not copy the settings file.
2837 </result>
2838
2839 </desc>
2840 <param name="bakFileName" type="wstring" dir="return">
2841 <desc>Full path to the created backup copy.</desc>
2842 </param>
2843 </method>
2844
2845 <!--method name="createDHCPServerForInterface">
2846 <desc>
2847 Creates a dhcp server settings to be used for the given interface
2848 <result name="E_INVALIDARG">
2849 Host network interface @a name already exists.
2850 </result>
2851 </desc>
2852 <param name="interface" type="IHostNetworkInterface" dir="in">
2853 <desc>Network Interface</desc>
2854 </param>
2855 <param name="server" type="IDHCPServer" dir="out">
2856 <desc>Dhcp server settings</desc>
2857 </param>
2858 </method-->
2859
2860 <method name="createDHCPServer">
2861 <desc>
2862 Creates a dhcp server settings to be used for the given internal network name
2863 <result name="E_INVALIDARG">
2864 Host network interface @a name already exists.
2865 </result>
2866 </desc>
2867 <param name="name" type="wstring" dir="in">
2868 <desc>server name</desc>
2869 </param>
2870 <param name="server" type="IDHCPServer" dir="return">
2871 <desc>Dhcp server settings</desc>
2872 </param>
2873 </method>
2874
2875 <method name="findDHCPServerByNetworkName">
2876 <desc>
2877 Searches a dhcp server settings to be used for the given internal network name
2878 <result name="E_INVALIDARG">
2879 Host network interface @a name already exists.
2880 </result>
2881
2882 </desc>
2883 <param name="name" type="wstring" dir="in">
2884 <desc>server name</desc>
2885 </param>
2886 <param name="server" type="IDHCPServer" dir="return">
2887 <desc>Dhcp server settings</desc>
2888 </param>
2889 </method>
2890
2891 <!--method name="findDHCPServerForInterface">
2892 <desc>
2893 Searches a dhcp server settings to be used for the given interface
2894 <result name="E_INVALIDARG">
2895 Host network interface @a name already exists.
2896 </result>
2897 </desc>
2898 <param name="interface" type="IHostNetworkInterface" dir="in">
2899 <desc>Network Interface</desc>
2900 </param>
2901 <param name="server" type="IDHCPServer" dir="out">
2902 <desc>Dhcp server settings</desc>
2903 </param>
2904 </method-->
2905
2906 <method name="removeDHCPServer">
2907 <desc>
2908 Removes the dhcp server settings
2909 <result name="E_INVALIDARG">
2910 Host network interface @a name already exists.
2911 </result>
2912 </desc>
2913 <param name="server" type="IDHCPServer" dir="in">
2914 <desc>Dhcp server settings to be removed</desc>
2915 </param>
2916 </method>
2917
2918 </interface>
2919
2920 <!--
2921 // IVFSExplorer
2922 /////////////////////////////////////////////////////////////////////////
2923 -->
2924
2925 <enum
2926 name="VFSType"
2927 uuid="813999ba-b949-48a8-9230-aadc6285e2f2"
2928 >
2929 <desc>
2930 Supported virtual file systems of VFSExplorer.
2931 </desc>
2932
2933 <const name="File" value="1" />
2934 <const name="Cloud" value="2" />
2935 <const name="S3" value="3" />
2936 <const name="WebDav" value="4" />
2937 </enum>
2938
2939 <enum
2940 name="VFSFileType"
2941 uuid="714333cd-44e2-415f-a245-d378fa9b1242"
2942 >
2943 <desc>
2944 File types known by VFSExplorer.
2945 </desc>
2946
2947 <const name="Unknown" value="1" />
2948 <const name="Fifo" value="2" />
2949 <const name="DevChar" value="3" />
2950 <const name="Directory" value="4" />
2951 <const name="DevBlock" value="5" />
2952 <const name="File" value="6" />
2953 <const name="SymLink" value="7" />
2954 <const name="Socket" value="8" />
2955 <const name="WhiteOut" value="9" />
2956 </enum>
2957
2958 <interface
2959 name="IVFSExplorer" extends="$unknown"
2960 uuid="fd7da337-80ef-4a5c-9122-918435e33003"
2961 wsmap="managed"
2962 >
2963 <desc>
2964 The VFSExplorer interface unify the access to different file system
2965 types. This includes local file systems as well remote file systems like
2966 the S3 one. For a list of supported types see <link to="VFSType" />.
2967 </desc>
2968
2969 <attribute name="path" type="wstring" readonly="yes">
2970 <desc>Return the current path in the virtual file system.</desc>
2971 </attribute>
2972
2973 <attribute name="type" type="VFSType" readonly="yes">
2974 <desc>Return the file system type which is currently in use.</desc>
2975 </attribute>
2976
2977 <method name="update">
2978 <desc>This method updates the internal list of files/directories from the
2979 current directory level. Use <link to="entryList" /> to get the full list
2980 after a call to this method.</desc>
2981
2982 <param name="aProgress" type="IProgress" dir="return">
2983 <desc>Progress object to track the operation completion.</desc>
2984 </param>
2985 </method>
2986
2987 <method name="entryList">
2988 <desc>Fetch the list of files/directories after a call to <link
2989 to="update" />. The user is responcible for keeping this internal list up
2990 do date.</desc>
2991
2992 <param name="aNames" type="wstring" safearray="yes" dir="out">
2993 <desc>The list of names for the entries.</desc>
2994 </param>
2995
2996 <param name="aTypes" type="unsigned long" safearray="yes" dir="out">
2997 <desc>The list of types for the entries.</desc>
2998 </param>
2999 </method>
3000
3001 <method name="exists">
3002 <desc>Check if the given file list exists in the current directory
3003 level.</desc>
3004
3005 <param name="aNames" type="wstring" safearray="yes" dir="in">
3006 <desc>The names to check.</desc>
3007 </param>
3008
3009 <param name="aExists" type="wstring" safearray="yes" dir="return">
3010 <desc>The names which exists.</desc>
3011 </param>
3012 </method>
3013
3014 <method name="remove">
3015 <desc>Remove the given file names from the current directory
3016 level.</desc>
3017
3018 <param name="aNames" type="wstring" safearray="yes" dir="in">
3019 <desc>The names to remove.</desc>
3020 </param>
3021
3022 <param name="aProgress" type="IProgress" dir="return">
3023 <desc>Progress object to track the operation completion.</desc>
3024 </param>
3025 </method>
3026
3027 </interface>
3028
3029 <!--
3030 // IAppliance
3031 /////////////////////////////////////////////////////////////////////////
3032 -->
3033
3034 <enum
3035 name="CIMOSType"
3036 uuid="86ef5f8c-18b2-4db8-a314-33721b59f89b"
3037 >
3038 <desc>
3039 OVF operating system values according to CIM V2.20 (as of Nov 2008); http://www.dmtf.org/standards/cim/cim_schema_v220
3040 </desc>
3041
3042 <const name="CIMOS_Unknown" value="0" /> <!-- "Unknown" -->
3043 <const name="CIMOS_Other" value="1" /> <!-- "Other" -->
3044 <const name="CIMOS_MACOS" value="2" /> <!-- "MACOS" -->
3045 <const name="CIMOS_ATTUNIX" value="3" /> <!-- "ATTUNIX" -->
3046 <const name="CIMOS_DGUX" value="4" /> <!-- "DGUX" -->
3047 <const name="CIMOS_DECNT" value="5" /> <!-- "DECNT" -->
3048 <const name="CIMOS_Tru64UNIX" value="6" /> <!-- "Tru64 UNIX" -->
3049 <const name="CIMOS_OpenVMS" value="7" /> <!-- "OpenVMS" -->
3050 <const name="CIMOS_HPUX" value="8" /> <!-- "HPUX" -->
3051 <const name="CIMOS_AIX" value="9" /> <!-- "AIX" -->
3052 <const name="CIMOS_MVS" value="10" /> <!-- "MVS" -->
3053 <const name="CIMOS_OS400" value="11" /> <!-- "OS400" -->
3054 <const name="CIMOS_OS2" value="12" /> <!-- "OS/2" -->
3055 <const name="CIMOS_JavaVM" value="13" /> <!-- "JavaVM" -->
3056 <const name="CIMOS_MSDOS" value="14" /> <!-- "MSDOS" -->
3057 <const name="CIMOS_WIN3x" value="15" /> <!-- "WIN3x" -->
3058 <const name="CIMOS_WIN95" value="16" /> <!-- "WIN95" -->
3059 <const name="CIMOS_WIN98" value="17" /> <!-- "WIN98" -->
3060 <const name="CIMOS_WINNT" value="18" /> <!-- "WINNT" -->
3061 <const name="CIMOS_WINCE" value="19" /> <!-- "WINCE" -->
3062 <const name="CIMOS_NCR3000" value="20" /> <!-- "NCR3000" -->
3063 <const name="CIMOS_NetWare" value="21" /> <!-- "NetWare" -->
3064 <const name="CIMOS_OSF" value="22" /> <!-- "OSF" -->
3065 <const name="CIMOS_DCOS" value="23" /> <!-- "DC/OS" -->
3066 <const name="CIMOS_ReliantUNIX" value="24" /> <!-- "Reliant UNIX" -->
3067 <const name="CIMOS_SCOUnixWare" value="25" /> <!-- "SCO UnixWare" -->
3068 <const name="CIMOS_SCOOpenServer" value="26" /> <!-- "SCO OpenServer" -->
3069 <const name="CIMOS_Sequent" value="27" /> <!-- "Sequent" -->
3070 <const name="CIMOS_IRIX" value="28" /> <!-- "IRIX" -->
3071 <const name="CIMOS_Solaris" value="29" /> <!-- "Solaris" -->
3072 <const name="CIMOS_SunOS" value="30" /> <!-- "SunOS" -->
3073 <const name="CIMOS_U6000" value="31" /> <!-- "U6000" -->
3074 <const name="CIMOS_ASERIES" value="32" /> <!-- "ASERIES" -->
3075 <const name="CIMOS_HPNonStopOS" value="33" /> <!-- "HP NonStop OS" -->
3076 <const name="CIMOS_HPNonStopOSS" value="34" /> <!-- "HP NonStop OSS" -->
3077 <const name="CIMOS_BS2000" value="35" /> <!-- "BS2000" -->
3078 <const name="CIMOS_LINUX" value="36" /> <!-- "LINUX" -->
3079 <const name="CIMOS_Lynx" value="37" /> <!-- "Lynx" -->
3080 <const name="CIMOS_XENIX" value="38" /> <!-- "XENIX" -->
3081 <const name="CIMOS_VM" value="39" /> <!-- "VM" -->
3082 <const name="CIMOS_InteractiveUNIX" value="40" /> <!-- "Interactive UNIX" -->
3083 <const name="CIMOS_BSDUNIX" value="41" /> <!-- "BSDUNIX" -->
3084 <const name="CIMOS_FreeBSD" value="42" /> <!-- "FreeBSD" -->
3085 <const name="CIMOS_NetBSD" value="43" /> <!-- "NetBSD" -->
3086 <const name="CIMOS_GNUHurd" value="44" /> <!-- "GNU Hurd" -->
3087 <const name="CIMOS_OS9" value="45" /> <!-- "OS9" -->
3088 <const name="CIMOS_MACHKernel" value="46" /> <!-- "MACH Kernel" -->
3089 <const name="CIMOS_Inferno" value="47" /> <!-- "Inferno" -->
3090 <const name="CIMOS_QNX" value="48" /> <!-- "QNX" -->
3091 <const name="CIMOS_EPOC" value="49" /> <!-- "EPOC" -->
3092 <const name="CIMOS_IxWorks" value="50" /> <!-- "IxWorks" -->
3093 <const name="CIMOS_VxWorks" value="51" /> <!-- "VxWorks" -->
3094 <const name="CIMOS_MiNT" value="52" /> <!-- "MiNT" -->
3095 <const name="CIMOS_BeOS" value="53" /> <!-- "BeOS" -->
3096 <const name="CIMOS_HPMPE" value="54" /> <!-- "HP MPE" -->
3097 <const name="CIMOS_NextStep" value="55" /> <!-- "NextStep" -->
3098 <const name="CIMOS_PalmPilot" value="56" /> <!-- "PalmPilot" -->
3099 <const name="CIMOS_Rhapsody" value="57" /> <!-- "Rhapsody" -->
3100 <const name="CIMOS_Windows2000" value="58" /> <!-- "Windows 2000" -->
3101 <const name="CIMOS_Dedicated" value="59" /> <!-- "Dedicated" -->
3102 <const name="CIMOS_OS390" value="60" /> <!-- "OS/390" -->
3103 <const name="CIMOS_VSE" value="61" /> <!-- "VSE" -->
3104 <const name="CIMOS_TPF" value="62" /> <!-- "TPF" -->
3105 <const name="CIMOS_WindowsMe" value="63" /> <!-- "Windows (R) Me" -->
3106 <const name="CIMOS_CalderaOpenUNIX" value="64" /> <!-- "Caldera Open UNIX" -->
3107 <const name="CIMOS_OpenBSD" value="65" /> <!-- "OpenBSD" -->
3108 <const name="CIMOS_NotApplicable" value="66" /> <!-- "Not Applicable" -->
3109 <const name="CIMOS_WindowsXP" value="67" /> <!-- "Windows XP" -->
3110 <const name="CIMOS_zOS" value="68" /> <!-- "z/OS" -->
3111 <const name="CIMOS_MicrosoftWindowsServer2003" value="69" /> <!-- "Microsoft Windows Server 2003" -->
3112 <const name="CIMOS_MicrosoftWindowsServer2003_64" value="70" /> <!-- "Microsoft Windows Server 2003 64-Bit" -->
3113 <const name="CIMOS_WindowsXP_64" value="71" /> <!-- "Windows XP 64-Bit" -->
3114 <const name="CIMOS_WindowsXPEmbedded" value="72" /> <!-- "Windows XP Embedded" -->
3115 <const name="CIMOS_WindowsVista" value="73" /> <!-- "Windows Vista" -->
3116 <const name="CIMOS_WindowsVista_64" value="74" /> <!-- "Windows Vista 64-Bit" -->
3117 <const name="CIMOS_WindowsEmbeddedforPointofService" value="75" /> <!-- "Windows Embedded for Point of Service" -->
3118 <const name="CIMOS_MicrosoftWindowsServer2008" value="76" /> <!-- "Microsoft Windows Server 2008" -->
3119 <const name="CIMOS_MicrosoftWindowsServer2008_64" value="77" /> <!-- "Microsoft Windows Server 2008 64-Bit" -->
3120 <const name="CIMOS_FreeBSD_64" value="78" /> <!-- "FreeBSD 64-Bit" -->
3121 <const name="CIMOS_RedHatEnterpriseLinux" value="79" /> <!-- "RedHat Enterprise Linux" -->
3122 <const name="CIMOS_RedHatEnterpriseLinux_64" value="80" /> <!-- "RedHat Enterprise Linux 64-Bit" -->
3123 <const name="CIMOS_Solaris_64" value="81" /> <!-- "Solaris 64-Bit" -->
3124 <const name="CIMOS_SUSE" value="82" /> <!-- "SUSE" -->
3125 <const name="CIMOS_SUSE_64" value="83" /> <!-- "SUSE 64-Bit" -->
3126 <const name="CIMOS_SLES" value="84" /> <!-- "SLES" -->
3127 <const name="CIMOS_SLES_64" value="85" /> <!-- "SLES 64-Bit" -->
3128 <const name="CIMOS_NovellOES" value="86" /> <!-- "Novell OES" -->
3129 <const name="CIMOS_NovellLinuxDesktop" value="87" /> <!-- "Novell Linux Desktop" -->
3130 <const name="CIMOS_SunJavaDesktopSystem" value="88" /> <!-- "Sun Java Desktop System" -->
3131 <const name="CIMOS_Mandriva" value="89" /> <!-- "Mandriva" -->
3132 <const name="CIMOS_Mandriva_64" value="90" /> <!-- "Mandriva 64-Bit" -->
3133 <const name="CIMOS_TurboLinux" value="91" /> <!-- "TurboLinux" -->
3134 <const name="CIMOS_TurboLinux_64" value="92" /> <!-- "TurboLinux 64-Bit" -->
3135 <const name="CIMOS_Ubuntu" value="93" /> <!-- "Ubuntu" -->
3136 <const name="CIMOS_Ubuntu_64" value="94" /> <!-- "Ubuntu 64-Bit" -->
3137 <const name="CIMOS_Debian" value="95" /> <!-- "Debian" -->
3138 <const name="CIMOS_Debian_64" value="96" /> <!-- "Debian 64-Bit" -->
3139 <const name="CIMOS_Linux_2_4_x" value="97" /> <!-- "Linux 2.4.x" -->
3140 <const name="CIMOS_Linux_2_4_x_64" value="98" /> <!-- "Linux 2.4.x 64-Bit" -->
3141 <const name="CIMOS_Linux_2_6_x" value="99" /> <!-- "Linux 2.6.x" -->
3142 <const name="CIMOS_Linux_2_6_x_64" value="100" /> <!-- "Linux 2.6.x 64-Bit" -->
3143 <const name="CIMOS_Linux_64" value="101" /> <!-- "Linux 64-Bit" -->
3144 <const name="CIMOS_Other_64" value="102" /> <!-- "Other 64-Bit" -->
3145 </enum>
3146
3147 <enum
3148 name="OVFResourceType"
3149 uuid="646a78d7-6f04-49f4-82c4-75c28a75a4cd"
3150 >
3151 <desc>
3152 OVF resource type (as listed with CIM_ResourceAllocationSettingData; see for example
3153 http://msdn.microsoft.com/en-us/library/cc136877(VS.85).aspx).
3154 </desc>
3155
3156 <const name="Other" value="1" />
3157 <const name="ComputerSystem" value="2" />
3158 <const name="Processor" value="3" />
3159 <const name="Memory" value="4" />
3160 <const name="IDEController" value="5" />
3161 <const name="ParallelSCSIHBA" value="6" />
3162 <const name="FCHBA" value="7" />
3163 <const name="iSCSIHBA" value="8" />
3164 <const name="IBHCA" value="9" />
3165 <const name="EthernetAdapter" value="10" />
3166 <const name="OtherNetworkAdapter" value="11" />
3167 <const name="IOSlot" value="12" />
3168 <const name="IODevice" value="13" />
3169 <const name="FloppyDrive" value="14" />
3170 <const name="CDDrive" value="15" />
3171 <const name="DVDDrive" value="16" />
3172 <const name="HardDisk" value="17" />
3173 <const name="OtherStorageDevice" value="20" />
3174 <const name="USBController" value="23" />
3175 <const name="SoundCard" value="35" />
3176 </enum>
3177
3178 <interface
3179 name="IAppliance" extends="$unknown"
3180 uuid="07495095-d16c-4911-8964-5914341ced5d"
3181 wsmap="managed"
3182 >
3183 <desc>
3184 Represents a platform-independent appliance in OVF format. An instance of this is returned
3185 by <link to="IVirtualBox::createAppliance" />, which can then be used to import and export
3186 appliances with VirtualBox.
3187
3188 The OVF standard suggests two different physical file formats:
3189
3190 <ol>
3191 <li>If the OVF is distributed as a set of files, then @a file must be a fully qualified
3192 path name to an existing OVF descriptor file with an <tt>.ovf</tt> file extension. If
3193 this descriptor file references other files, as OVF appliances distributed as a set of
3194 files most likely do, those files must be in the same directory as the descriptor file.</li>
3195
3196 <li>If the OVF is distributed as a single file, it must be in TAR format and have the
3197 <tt>.ova</tt> file extension. This TAR file must then contain at least the OVF descriptor
3198 files and optionally other files.
3199
3200 At this time, VirtualBox does not not yet support the packed (TAR) variant; support will
3201 be added with a later version.</li>
3202 </ol>
3203
3204 <b>Importing</b> an OVF appliance into VirtualBox as instances of
3205 <link to="IMachine" /> involves the following sequence of API calls:
3206
3207 <ol>
3208 <li>Call <link to="IVirtualBox::createAppliance" />. This will create an empty IAppliance object.
3209 </li>
3210
3211 <li>On the new object, call <link to="#read" /> with the full path of the OVF file you
3212 would like to import. So long as this file is syntactically valid, this will succeed
3213 and return an instance of IAppliance that contains the parsed data from the OVF file.
3214 </li>
3215
3216 <li>Next, call <link to="#interpret" />, which analyzes the OVF data and sets up the
3217 contents of the IAppliance attributes accordingly. These can be inspected by a
3218 VirtualBox front-end such as the GUI, and the suggestions can be displayed to the
3219 user. In particular, the <link to="#virtualSystemDescriptions" /> array contains
3220 instances of <link to="IVirtualSystemDescription" /> which represent the virtual
3221 systems in the OVF, which in turn describe the virtual hardware prescribed by the
3222 OVF (network and hardware adapters, virtual disk images, memory size and so on).
3223 The GUI can then give the user the option to confirm and/or change these suggestions.
3224 </li>
3225
3226 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
3227 virtual system to override the suggestions made by the interpret() routine.
3228 </li>
3229
3230 <li>Finally, call <link to="#importMachines" /> to create virtual machines in
3231 VirtualBox as instances of <link to="IMachine" /> that match the information in the
3232 virtual system descriptions.
3233 </li>
3234 </ol>
3235
3236 <b>Exporting</b> VirtualBox machines into an OVF appliance involves the following steps:
3237
3238 <ol>
3239 <li>As with importing, first call <link to="IVirtualBox::createAppliance" /> to create
3240 an empty IAppliance object.
3241 </li>
3242
3243 <li>For each machine you would like to export, call <link to="IMachine::export" />
3244 with the IAppliance object you just created. This creates an instance of
3245 <link to="IVirtualSystemDescription" /> inside the appliance.
3246 </li>
3247
3248 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
3249 virtual system to override the suggestions made by the export() routine.
3250 </li>
3251
3252 <li>Finally, call <link to="#write" /> with a path specification to have the OVF
3253 file written.</li>
3254 </ol>
3255
3256 </desc>
3257
3258 <attribute name="path" type="wstring" readonly="yes">
3259 <desc>Path to the main file of the OVF appliance, which is either the <tt>.ovf</tt> or
3260 the <tt>.ova</tt> file passed to <link to="#read" /> (for import) or
3261 <link to="#write" /> (for export).
3262 This attribute is empty until one of these methods has been called.
3263 </desc>
3264 </attribute>
3265
3266 <attribute name="disks" type="wstring" readonly="yes" safearray="yes">
3267 <desc>
3268 Array of virtual disk definitions. One such description exists for each
3269 disk definition in the OVF; each string array item represents one such piece of
3270 disk information, with the information fields separated by tab (\\t) characters.
3271
3272 The caller should be prepared for additional fields being appended to
3273 this string in future versions of VirtualBox and therefore check for
3274 the number of tabs in the strings returned.
3275
3276 In the current version, the following eight fields are returned per string
3277 in the array:
3278
3279 <ol>
3280 <li>Disk ID (unique string identifier given to disk)</li>
3281
3282 <li>Capacity (unsigned integer indicating the maximum capacity of the disk)</li>
3283
3284 <li>Populated size (optional unsigned integer indicating the current size of the
3285 disk; can be approximate; -1 if unspecified)</li>
3286
3287 <li>Format (string identifying the disk format, typically
3288 "http://www.vmware.com/specifications/vmdk.html#sparse")</li>
3289
3290 <li>Reference (where to find the disk image, typically a file name; if empty,
3291 then the disk should be created on import)</li>
3292
3293 <li>Image size (optional unsigned integer indicating the size of the image,
3294 which need not necessarily be the same as the values specified above, since
3295 the image may be compressed or sparse; -1 if not specified)</li>
3296
3297 <li>Chunk size (optional unsigned integer if the image is split into chunks;
3298 presently unsupported and always -1)</li>
3299
3300 <li>Compression (optional string equalling "gzip" if the image is gzip-compressed)</li>
3301 </ol>
3302 </desc>
3303 </attribute>
3304
3305 <attribute name="virtualSystemDescriptions" type="IVirtualSystemDescription" readonly="yes" safearray="yes">
3306 <desc> Array of virtual system descriptions. One such description is created
3307 for each virtual system found in the OVF.
3308 This array is empty until either <link to="#interpret" /> (for import) or <link to="IMachine::export" />
3309 (for export) has been called.
3310 </desc>
3311 </attribute>
3312
3313 <method name="read">
3314 <desc>
3315 Reads an OVF file into the appliance object.
3316
3317 This method succeeds if the OVF is syntactically valid and, by itself, without errors. The
3318 mere fact that this method returns successfully does not mean that VirtualBox supports all
3319 features requested by the appliance; this can only be examined after a call to <link to="#interpret" />.
3320 </desc>
3321 <param name="file" type="wstring" dir="in">
3322 <desc>
3323 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
3324 on whether the appliance is distributed as a set of files or as a single file, respectively).
3325 </desc>
3326 </param>
3327 </method>
3328
3329 <method name="interpret">
3330 <desc>
3331 Interprets the OVF data that was read when the appliance was constructed. After
3332 calling this method, one can inspect the
3333 <link to="#virtualSystemDescriptions" /> array attribute, which will then contain
3334 one <link to="IVirtualSystemDescription" /> for each virtual machine found in
3335 the appliance.
3336
3337 Calling this method is the second step of importing an appliance into VirtualBox;
3338 see <link to="IAppliance" /> for an overview.
3339
3340 After calling this method, one should call <link to="#getWarnings" /> to find out
3341 if problems were encountered during the processing which might later lead to
3342 errors.
3343 </desc>
3344 </method>
3345
3346 <method name="importMachines">
3347 <desc>
3348 Imports the appliance into VirtualBox by creating instances of <link to="IMachine" />
3349 and other interfaces that match the information contained in the appliance as
3350 closely as possible, as represented by the import instructions in the
3351 <link to="#virtualSystemDescriptions" /> array.
3352
3353 Calling this method is the final step of importing an appliance into VirtualBox;
3354 see <link to="IAppliance" /> for an overview.
3355
3356 Since importing the appliance will most probably involve copying and converting
3357 disk images, which can take a long time, this method operates asynchronously and
3358 returns an IProgress object to allow the caller to monitor the progress.
3359 </desc>
3360
3361 <param name="aProgress" type="IProgress" dir="return">
3362 <desc></desc>
3363 </param>
3364 </method>
3365
3366 <method name="createVFSExplorer">
3367 <desc>Returns a <link to="IVFSExplorer" /> object for the given URI.</desc>
3368
3369 <param name="aUri" type="wstring" dir="in">
3370 <desc>The URI describing the file system to use.</desc>
3371 </param>
3372
3373 <param name="aExplorer" type="IVFSExplorer" dir="return">
3374 <desc></desc>
3375 </param>
3376 </method>
3377
3378 <method name="write">
3379 <desc>
3380 Writes the contents of the appliance exports into a new OVF file.
3381
3382 Calling this method is the final step of exporting an appliance from VirtualBox;
3383 see <link to="IAppliance" /> for an overview.
3384
3385 Since exporting the appliance will most probably involve copying and converting
3386 disk images, which can take a long time, this method operates asynchronously and
3387 returns an IProgress object to allow the caller to monitor the progress.
3388 </desc>
3389 <param name="format" type="wstring" dir="in">
3390 <desc>
3391 Output format, as a string. Currently supported formats are "ovf-0.9" and "ovf-1.0";
3392 future versions of VirtualBox may support additional formats.
3393 </desc>
3394 </param>
3395 <param name="path" type="wstring" dir="in">
3396 <desc>
3397 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
3398 on whether the appliance is distributed as a set of files or as a single file, respectively).
3399 </desc>
3400 </param>
3401 <param name="aProgress" type="IProgress" dir="return">
3402 <desc>Progress object to track the operation completion.</desc>
3403 </param>
3404 </method>
3405
3406 <method name="getWarnings">
3407 <desc>Returns textual warnings which occured during execution of <link to="#interpret" />.</desc>
3408
3409 <param name="aWarnings" type="wstring" dir="return" safearray="yes">
3410 <desc></desc>
3411 </param>
3412 </method>
3413
3414 </interface>
3415
3416 <enum
3417 name="VirtualSystemDescriptionType"
3418 uuid="aacc58de-5b45-4f82-ae2e-dd9a824fc3b5"
3419 >
3420 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of
3421 a configuration value.</desc>
3422
3423 <const name="Ignore" value="1" />
3424 <const name="OS" value="2" />
3425 <const name="Name" value="3" />
3426 <const name="Product" value="4" />
3427 <const name="Vendor" value="5" />
3428 <const name="Version" value="6" />
3429 <const name="ProductUrl" value="7" />
3430 <const name="VendorUrl" value="8" />
3431 <const name="Description" value="9" />
3432 <const name="License" value="10" />
3433 <const name="Miscellaneous" value="11" />
3434 <const name="CPU" value="12" />
3435 <const name="Memory" value="13" />
3436 <const name="HardDiskControllerIDE" value="14" />
3437 <const name="HardDiskControllerSATA" value="15" />
3438 <const name="HardDiskControllerSCSI" value="16" />
3439 <const name="HardDiskImage" value="17" />
3440 <const name="Floppy" value="18" />
3441 <const name="CDROM" value="19" />
3442 <const name="NetworkAdapter" value="20" />
3443 <const name="USBController" value="21" />
3444 <const name="SoundCard" value="22" />
3445
3446 </enum>
3447
3448 <enum
3449 name="VirtualSystemDescriptionValueType"
3450 uuid="56d9403f-3425-4118-9919-36f2a9b8c77c"
3451 >
3452 <desc>Used with <link to="IVirtualSystemDescription::getValuesByType" /> to describe the value
3453 type to fetch.</desc>
3454
3455 <const name="Reference" value="1" />
3456 <const name="Original" value="2" />
3457 <const name="Auto" value="3" />
3458 <const name="ExtraConfig" value="4" />
3459
3460 </enum>
3461
3462 <interface
3463 name="IVirtualSystemDescription" extends="$unknown"
3464 uuid="d7525e6c-531a-4c51-8e04-41235083a3d8"
3465 wsmap="managed"
3466 >
3467
3468 <desc>This interface is used in the <link to="IAppliance::virtualSystemDescriptions" /> array.
3469 After <link to="IAppliance::interpret" /> has been called, that array contains
3470 information about how the virtual systems described in the OVF should best be imported into VirtualBox
3471 virtual machines. See <link to="IAppliance" /> for the steps required to import an OVF
3472 into VirtualBox.
3473 </desc>
3474
3475 <attribute name="count" type="unsigned long" readonly="yes">
3476 <desc>Return the number of virtual system description entries.</desc>
3477 </attribute>
3478
3479 <method name="getDescription">
3480 <desc>Returns information about the virtual system as arrays of instruction items. In each array, the
3481 items with the same indices correspond and jointly represent an import instruction for VirtualBox.
3482
3483 The list below identifies the value sets that are possible depending on the
3484 <link to="VirtualSystemDescriptionType" /> enum value in the array item in aTypes[]. In each case,
3485 the array item with the same index in aOvfValues[] will contain the original value as contained
3486 in the OVF file (just for informational purposes), and the corresponding item in aVBoxValues[]
3487 will contain a suggested value to be used for VirtualBox. Depending on the description type,
3488 the aExtraConfigValues[] array item may also be used.
3489
3490 <ul>
3491 <li>
3492 "OS": the guest operating system type. There must be exactly one such array item on import. The
3493 corresponding item in aVBoxValues[] contains the suggested guest operating system for VirtualBox.
3494 This will be one of the values listed in <link to="IVirtualBox::guestOSTypes" />. The corresponding
3495 item in aOvfValues[] will contain a numerical value that described the operating system in the OVF
3496 (see <link to="CIMOSType" />).
3497 </li>
3498 <li>
3499 "Name": the name to give to the new virtual machine. There can be at most one such array item;
3500 if none is present on import, then an automatic name will be created from the operating system
3501 type. The correponding item im aOvfValues[] will contain the suggested virtual machine name
3502 from the OVF file, and aVBoxValues[] will contain a suggestion for a unique VirtualBox
3503 <link to="IMachine" /> name that does not exist yet.
3504 </li>
3505 <li>
3506 "Description": an arbitrary description.
3507 </li>
3508 <li>
3509 "License": the EULA section from the OVF, if present. It is the responsibility of the calling
3510 code to display such a license for agreement; the Main API does not enforce any such policy.
3511 </li>
3512 <li>
3513 Miscellaneous: reserved for future use.
3514 </li>
3515 <li>
3516 "CPU": the number of CPUs. There can be at most one such item, which will presently be ignored.
3517 </li>
3518 <li>
3519 "Memory": the amount of guest RAM, in bytes. There can be at most one such array item; if none
3520 is present on import, then VirtualBox will set a meaningful default based on the operating system
3521 type.
3522 </li>
3523 <li>
3524 "HarddiskControllerIDE": an IDE hard disk controller. There can be at most one such item. This
3525 has no value in aOvfValues[] or aVBoxValues[].
3526 The matching item in the aRefs[] array will contain an integer that items of the "Harddisk"
3527 type can use to specify which hard disk controller a virtual disk should be connected to.
3528 </li>
3529 <li>
3530 "HarddiskControllerSATA": an SATA hard disk controller. There can be at most one such item. This
3531 has no value in aOvfValues[] or aVBoxValues[].
3532 The matching item in the aRefs[] array will be used as with IDE controllers (see above).
3533 </li>
3534 <li>
3535 "HarddiskControllerSCSI": a SCSI hard disk controller. There can be at most one such item.
3536 The items in aOvfValues[] and aVBoxValues[] will either be "LsiLogic" or "BusLogic".
3537 The matching item in the aRefs[] array will be used as with IDE controllers (see above).
3538 </li>
3539 <li>
3540 "HardDiskImage": a virtual hard disk, most probably as a reference to an image file. There can be an
3541 arbitrary number of these items, one for each virtual disk image that accompanies the OVF.
3542
3543 The array item in aOvfValues[] will contain the file specification from the OVF file (without
3544 a path since the image file should be in the same location as the OVF file itself), whereas the
3545 item in aVBoxValues[] will contain a qualified path specification to where VirtualBox uses the
3546 hard disk image. This means that on import the image will be copied and converted from the
3547 "ovf" location to the "vbox" location; on export, this will be handled the other way round.
3548 On import, the target image will also be registered with VirtualBox.
3549
3550 The matching item in the aExtraConfigValues[] array must contain a string of the following
3551 format: "controller=&lt;index&gt;;channel=&lt;c&gt;"
3552 In this string, &lt;index&gt; must be an integer specifying the hard disk controller to connect
3553 the image to. That number must be the index of an array item with one of the hard disk controller
3554 types (HarddiskControllerSCSI, HarddiskControllerSATA, HarddiskControllerIDE).
3555 In addition, &lt;c&gt; must specify the channel to use on that controller. For IDE controllers,
3556 this can range from 0-2 (which VirtualBox will interpret as primary master, primary slave,
3557 secondary slave; VirtualBox reserves the secondary master for the CD-ROM drive). For SATA and
3558 SCSI conrollers, the channel can range from 0-29.
3559 </li>
3560 <li>
3561 "NetworkAdapter": a network adapter. The array item in aVBoxValues[] will specify the hardware
3562 for the network adapter, whereas the array item in aExtraConfigValues[] will have a string
3563 of the "type=&lt;X&gt;" format, where &lt;X&gt; must be either "NAT" or "Bridged".
3564 </li>
3565 <li>
3566 "USBController": a USB controller. There can be at most one such item. If and only if such an
3567 item ispresent, USB support will be enabled for the new virtual machine.
3568 </li>
3569 <li>
3570 "SoundCard": a sound card. There can be at most one such item. If and only if such an item is
3571 present, sound support will be enabled for the new virtual machine. Note that the virtual
3572 machine in VirtualBox will always be presented with the standard VirtualBox soundcard, which
3573 may be different from the virtual soundcard expected by the appliance.
3574 </li>
3575 </ul>
3576
3577 </desc>
3578
3579 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
3580 <desc></desc>
3581 </param>
3582
3583 <param name="aRefs" type="wstring" dir="out" safearray="yes">
3584 <desc></desc>
3585 </param>
3586
3587 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
3588 <desc></desc>
3589 </param>
3590
3591 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
3592 <desc></desc>
3593 </param>
3594
3595 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
3596 <desc></desc>
3597 </param>
3598
3599 </method>
3600
3601 <method name="getDescriptionByType">
3602 <desc>This is the same as <link to="#getDescription" /> except that you can specify which types
3603 should be returned.</desc>
3604
3605 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
3606 <desc></desc>
3607 </param>
3608
3609 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
3610 <desc></desc>
3611 </param>
3612
3613 <param name="aRefs" type="wstring" dir="out" safearray="yes">
3614 <desc></desc>
3615 </param>
3616
3617 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
3618 <desc></desc>
3619 </param>
3620
3621 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
3622 <desc></desc>
3623 </param>
3624
3625 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
3626 <desc></desc>
3627 </param>
3628
3629 </method>
3630
3631 <method name="getValuesByType">
3632 <desc>This is the same as <link to="#getDescriptionByType" /> except that you can specify which
3633 value types should be returned. See <link to="VirtualSystemDescriptionValueType" /> for possible
3634 values.</desc>
3635
3636 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
3637 <desc></desc>
3638 </param>
3639
3640 <param name="aWhich" type="VirtualSystemDescriptionValueType" dir="in">
3641 <desc></desc>
3642 </param>
3643
3644 <param name="aValues" type="wstring" dir="return" safearray="yes">
3645 <desc></desc>
3646 </param>
3647
3648 </method>
3649
3650 <method name="setFinalValues">
3651 <desc>
3652 This method allows the appliance's user to change the configuration for the virtual
3653 system descriptions. For each array item returned from <link to="#getDescription" />,
3654 you must pass in one boolean value and one configuration value.
3655
3656 Each item in the boolean array determines whether the particular configuration item
3657 should be enabled.
3658 You can only disable items of the types HardDiskControllerIDE, HardDiskControllerSATA,
3659 HardDiskControllerSCSI, HardDiskImage, CDROM, Floppy, NetworkAdapter, USBController
3660 and SoundCard.
3661
3662 For the "vbox" and "extra configuration" values, if you pass in the same arrays
3663 as returned in the aVBoxValues and aExtraConfigValues arrays from getDescription(),
3664 the configuration remains unchanged. Please see the documentation for getDescription()
3665 for valid configuration values for the individual array item types. If the
3666 corresponding item in the aEnabled array is false, the configuration value is ignored.
3667 </desc>
3668
3669 <param name="aEnabled" type="boolean" dir="in" safearray="yes">
3670 <desc></desc>
3671 </param>
3672
3673 <param name="aVBoxValues" type="wstring" dir="in" safearray="yes">
3674 <desc></desc>
3675 </param>
3676
3677 <param name="aExtraConfigValues" type="wstring" dir="in" safearray="yes">
3678 <desc></desc>
3679 </param>
3680 </method>
3681
3682 <method name="addDescription">
3683 <desc>
3684 This method adds an additional description entry to the stack of already
3685 available descriptions for this virtual system. This is handy for writing
3686 values which aren't directly supported by VirtualBox. One example would
3687 be the License type of <link to="VirtualSystemDescriptionType" />.
3688 </desc>
3689
3690 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
3691 <desc></desc>
3692 </param>
3693
3694 <param name="aVBoxValue" type="wstring" dir="in">
3695 <desc></desc>
3696 </param>
3697
3698 <param name="aExtraConfigValue" type="wstring" dir="in">
3699 <desc></desc>
3700 </param>
3701 </method>
3702 </interface>
3703
3704
3705 <!--
3706 // IMachine
3707 /////////////////////////////////////////////////////////////////////////
3708 -->
3709
3710 <interface
3711 name="IInternalMachineControl" extends="$unknown"
3712 uuid="5595cae1-6b18-42c1-b416-bc7493a87618"
3713 internal="yes"
3714 wsmap="suppress"
3715 >
3716 <method name="updateState">
3717 <desc>
3718 Updates the VM state.
3719 <note>
3720 This operation will also update the settings file with
3721 the correct information about the saved state file
3722 and delete this file from disk when appropriate.
3723 </note>
3724 </desc>
3725 <param name="state" type="MachineState" dir="in"/>
3726 </method>
3727
3728 <method name="getIPCId">
3729 <param name="id" type="wstring" dir="return"/>
3730 </method>
3731
3732 <method name="runUSBDeviceFilters">
3733 <desc>
3734 Asks the server to run USB devices filters of the associated
3735 machine against the given USB device and tell if there is
3736 a match.
3737 <note>
3738 Intended to be used only for remote USB devices. Local
3739 ones don't require to call this method (this is done
3740 implicitly by the Host and USBProxyService).
3741 </note>
3742 </desc>
3743 <param name="device" type="IUSBDevice" dir="in"/>
3744 <param name="matched" type="boolean" dir="out"/>
3745 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
3746 </method>
3747
3748 <method name="captureUSBDevice">
3749 <desc>
3750 Requests a capture of the given host USB device.
3751 When the request is completed, the VM process will
3752 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3753 notification.
3754 </desc>
3755 <param name="id" type="wstring" dir="in"/>
3756 </method>
3757
3758 <method name="detachUSBDevice">
3759 <desc>
3760 Notification that a VM is going to detach (done = false) or has
3761 already detached (done = true) the given USB device.
3762 When the done = true request is completed, the VM process will
3763 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
3764 notification.
3765 <note>
3766 In the done = true case, the server must run its own filters
3767 and filters of all VMs but this one on the detached device
3768 as if it were just attached to the host computer.
3769 </note>
3770 </desc>
3771 <param name="id" type="wstring" dir="in"/>
3772 <param name="done" type="boolean" dir="in"/>
3773 </method>
3774
3775 <method name="autoCaptureUSBDevices">
3776 <desc>
3777 Requests a capture all matching USB devices attached to the host.
3778 When the request is completed, the VM process will
3779 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3780 notification per every captured device.
3781 </desc>
3782 </method>
3783
3784 <method name="detachAllUSBDevices">
3785 <desc>
3786 Notification that a VM that is being powered down. The done
3787 parameter indicates whether which stage of the power down
3788 we're at. When done = false the VM is announcing its
3789 intentions, while when done = true the VM is reporting
3790 what it has done.
3791 <note>
3792 In the done = true case, the server must run its own filters
3793 and filters of all VMs but this one on all detach devices as
3794 if they were just attached to the host computer.
3795 </note>
3796 </desc>
3797 <param name="done" type="boolean" dir="in"/>
3798 </method>
3799
3800 <method name="onSessionEnd">
3801 <desc>
3802 Triggered by the given session object when the session is about
3803 to close normally.
3804 </desc>
3805 <param name="session" type="ISession" dir="in">
3806 <desc>Session that is being closed</desc>
3807 </param>
3808 <param name="progress" type="IProgress" dir="return">
3809 <desc>
3810 Used to wait until the corresponding machine is actually
3811 dissociated from the given session on the server.
3812 Returned only when this session is a direct one.
3813 </desc>
3814 </param>
3815 </method>
3816
3817 <method name="beginSavingState">
3818 <desc>
3819 Called by the VM process to inform the server it wants to
3820 save the current state and stop the VM execution.
3821 </desc>
3822 <param name="progress" type="IProgress" dir="in">
3823 <desc>
3824 Progress object created by the VM process to wait until
3825 the state is saved.
3826 </desc>
3827 </param>
3828 <param name="stateFilePath" type="wstring" dir="out">
3829 <desc>
3830 File path the VM process must save the execution state to.
3831 </desc>
3832 </param>
3833 </method>
3834
3835 <method name="endSavingState">
3836 <desc>
3837 Called by the VM process to inform the server that saving
3838 the state previously requested by #beginSavingState is either
3839 successfully finished or there was a failure.
3840
3841 <result name="VBOX_E_FILE_ERROR">
3842 Settings file not accessible.
3843 </result>
3844 <result name="VBOX_E_XML_ERROR">
3845 Could not parse the settings file.
3846 </result>
3847
3848 </desc>
3849
3850 <param name="success" type="boolean" dir="in">
3851 <desc><tt>true</tt> to indicate success and <tt>false</tt>
3852 otherwise.
3853 </desc>
3854 </param>
3855 </method>
3856
3857 <method name="adoptSavedState">
3858 <desc>
3859 Gets called by IConsole::adoptSavedState.
3860 <result name="VBOX_E_FILE_ERROR">
3861 Invalid saved state file path.
3862 </result>
3863 </desc>
3864 <param name="savedStateFile" type="wstring" dir="in">
3865 <desc>Path to the saved state file to adopt.</desc>
3866 </param>
3867 </method>
3868
3869 <method name="beginTakingSnapshot">
3870 <desc>
3871 Called by the VM process to inform the server it wants to
3872 take a snapshot.
3873
3874 <result name="VBOX_E_FILE_ERROR">
3875 Settings file not accessible.
3876 </result>
3877 <result name="VBOX_E_XML_ERROR">
3878 Could not parse the settings file.
3879 </result>
3880 </desc>
3881 <param name="initiator" type="IConsole" dir="in">
3882 <desc>The console object that initiated this call.</desc>
3883 </param>
3884 <param name="name" type="wstring" dir="in">
3885 <desc>Snapshot name.</desc>
3886 </param>
3887 <param name="description" type="wstring" dir="in">
3888 <desc>Snapshot description.</desc>
3889 </param>
3890 <param name="progress" type="IProgress" dir="in">
3891 <desc>
3892 Progress object created by the VM process to wait until
3893 the state is saved (only for online snapshots).
3894 </desc>
3895 </param>
3896 <param name="stateFilePath" type="wstring" dir="out">
3897 <desc>
3898 File path the VM process must save the execution state to.
3899 </desc>
3900 </param>
3901 <param name="serverProgress" type="IProgress" dir="out">
3902 <desc>
3903 Progress object created by the server process to wait until
3904 the snapshot is taken (VDI diff creation, etc.).
3905 </desc>
3906 </param>
3907 </method>
3908
3909 <method name="endTakingSnapshot">
3910 <desc>
3911 Called by the VM process to inform the server that the snapshot
3912 previously requested by #beginTakingSnapshot is either
3913 successfully taken or there was a failure.
3914 </desc>
3915
3916 <param name="success" type="boolean" dir="in">
3917 <desc><tt>true</tt> to indicate success and <tt>false</tt> otherwise</desc>
3918 </param>
3919 </method>
3920
3921 <method name="discardSnapshot">
3922 <desc>
3923 Gets called by IConsole::discardSnapshot.
3924 <result name="VBOX_E_INVALID_OBJECT_STATE">
3925 Snapshot has more than one child snapshot.
3926 </result>
3927 </desc>
3928 <param name="initiator" type="IConsole" dir="in">
3929 <desc>The console object that initiated this call.</desc>
3930 </param>
3931 <param name="id" type="wstring" dir="in">
3932 <desc>UUID of the snapshot to discard.</desc>
3933 </param>
3934 <param name="machineState" type="MachineState" dir="out">
3935 <desc>New machine state after this operation is started.</desc>
3936 </param>
3937 <param name="progress" type="IProgress" dir="return">
3938 <desc>Progress object to track the operation completion.</desc>
3939 </param>
3940 </method>
3941
3942 <method name="discardCurrentState">
3943 <desc>
3944 Gets called by IConsole::discardCurrentState.
3945 <result name="VBOX_E_INVALID_OBJECT_STATE">
3946 Virtual machine does not have any snapshot.
3947 </result>
3948 </desc>
3949 <param name="initiator" type="IConsole" dir="in">
3950 <desc>The console object that initiated this call.</desc>
3951 </param>
3952 <param name="machineState" type="MachineState" dir="out">
3953 <desc>New machine state after this operation is started.</desc>
3954 </param>
3955 <param name="progress" type="IProgress" dir="return">
3956 <desc>Progress object to track the operation completion.</desc>
3957 </param>
3958 </method>
3959
3960 <method name="discardCurrentSnapshotAndState">
3961 <desc>
3962 Gets called by IConsole::discardCurrentSnapshotAndState.
3963 <result name="VBOX_E_INVALID_OBJECT_STATE">
3964 Virtual machine does not have any snapshot.
3965 </result>
3966 </desc>
3967 <param name="initiator" type="IConsole" dir="in">
3968 <desc>The console object that initiated this call.</desc>
3969 </param>
3970 <param name="machineState" type="MachineState" dir="out">
3971 <desc>New machine state after this operation is started.</desc>
3972 </param>
3973 <param name="progress" type="IProgress" dir="return">
3974 <desc>Progress object to track the operation completion.</desc>
3975 </param>
3976 </method>
3977
3978 <method name="pullGuestProperties">
3979 <desc>
3980 Get the list of the guest properties matching a set of patterns along
3981 with their values, time stamps and flags and give responsibility for
3982 managing properties to the console.
3983 </desc>
3984 <param name="name" type="wstring" dir="out" safearray="yes">
3985 <desc>
3986 The names of the properties returned.
3987 </desc>
3988 </param>
3989 <param name="value" type="wstring" dir="out" safearray="yes">
3990 <desc>
3991 The values of the properties returned. The array entries match the
3992 corresponding entries in the @a name array.
3993 </desc>
3994 </param>
3995 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
3996 <desc>
3997 The time stamps of the properties returned. The array entries match
3998 the corresponding entries in the @a name array.
3999 </desc>
4000 </param>
4001 <param name="flags" type="wstring" dir="out" safearray="yes">
4002 <desc>
4003 The flags of the properties returned. The array entries match the
4004 corresponding entries in the @a name array.
4005 </desc>
4006 </param>
4007 </method>
4008
4009 <method name="pushGuestProperties">
4010 <desc>
4011 Set the list of the guest properties matching a set of patterns along
4012 with their values, time stamps and flags and return responsibility for
4013 managing properties to IMachine.
4014 </desc>
4015 <param name="name" type="wstring" dir="in" safearray="yes">
4016 <desc>
4017 The names of the properties.
4018 </desc>
4019 </param>
4020 <param name="value" type="wstring" dir="in" safearray="yes">
4021 <desc>
4022 The values of the properties. The array entries match the
4023 corresponding entries in the @a name array.
4024 </desc>
4025 </param>
4026 <param name="timestamp" type="unsigned long long" dir="in" safearray="yes">
4027 <desc>
4028 The time stamps of the properties. The array entries match
4029 the corresponding entries in the @a name array.
4030 </desc>
4031 </param>
4032 <param name="flags" type="wstring" dir="in" safearray="yes">
4033 <desc>
4034 The flags of the properties. The array entries match the
4035 corresponding entries in the @a name array.
4036 </desc>
4037 </param>
4038 </method>
4039 <method name="pushGuestProperty">
4040 <desc>
4041 Update a single guest property in IMachine.
4042 </desc>
4043 <param name="name" type="wstring" dir="in">
4044 <desc>
4045 The name of the property to be updated.
4046 </desc>
4047 </param>
4048 <param name="value" type="wstring" dir="in">
4049 <desc>
4050 The value of the property.
4051 </desc>
4052 </param>
4053 <param name="timestamp" type="unsigned long long" dir="in">
4054 <desc>
4055 The timestamp of the property.
4056 </desc>
4057 </param>
4058 <param name="flags" type="wstring" dir="in">
4059 <desc>
4060 The flags of the property.
4061 </desc>
4062 </param>
4063 </method>
4064
4065 <method name="lockMedia">
4066 <desc>
4067 Locks all media attached to the machine for writing and parents of
4068 attahced different hard disks (if any) for reading. This operation is
4069 atomic so that if it fails no media is actually locked.
4070
4071 This method is intended to be called when the machine is in Starting or
4072 Restoring state. The locked media will be automatically unlocked when
4073 the machine is powered off or crashed.
4074 </desc>
4075 </method>
4076 </interface>
4077
4078 <interface
4079 name="IBIOSSettings" extends="$unknown"
4080 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
4081 wsmap="managed"
4082 >
4083 <desc>
4084 The IBIOSSettings interface represents BIOS settings of the virtual
4085 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
4086 </desc>
4087 <attribute name="logoFadeIn" type="boolean">
4088 <desc>Fade in flag for BIOS logo animation.</desc>
4089 </attribute>
4090
4091 <attribute name="logoFadeOut" type="boolean">
4092 <desc>Fade out flag for BIOS logo animation.</desc>
4093 </attribute>
4094
4095 <attribute name="logoDisplayTime" type="unsigned long">
4096 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
4097 </attribute>
4098
4099 <attribute name="logoImagePath" type="wstring">
4100 <desc>Local file system path for external BIOS image.</desc>
4101 </attribute>
4102
4103 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
4104 <desc>Mode of the BIOS boot device menu.</desc>
4105 </attribute>
4106
4107 <attribute name="ACPIEnabled" type="boolean">
4108 <desc>ACPI support flag.</desc>
4109 </attribute>
4110
4111 <attribute name="IOAPICEnabled" type="boolean">
4112 <desc>
4113 IO APIC support flag. If set, VirtualBox will provide an IO APIC
4114 and support IRQs above 15.
4115 </desc>
4116 </attribute>
4117
4118 <attribute name="timeOffset" type="long long">
4119 <desc>
4120 Offset in milliseconds from the host system time. This allows for
4121 guests running with a different system date/time than the host.
4122 It is equivalent to setting the system date/time in the BIOS except
4123 it is not an absolute value but a relative one. Guest Additions
4124 time synchronization honors this offset.
4125 </desc>
4126 </attribute>
4127
4128 <attribute name="PXEDebugEnabled" type="boolean">
4129 <desc>
4130 PXE debug logging flag. If set, VirtualBox will write extensive
4131 PXE trace information to the release log.
4132 </desc>
4133 </attribute>
4134
4135 </interface>
4136
4137 <interface
4138 name="IMachine" extends="$unknown"
4139 uuid="4d1df26d-d9c1-4c7e-b689-15e85ecf8ffc"
4140 wsmap="managed"
4141 >
4142 <desc>
4143 The IMachine interface represents a virtual machine, or guest, created
4144 in VirtualBox.
4145
4146 This interface is used in two contexts. First of all, a collection of
4147 objects implementing this interface is stored in the
4148 <link to="IVirtualBox::machines"/> attribute which lists all the virtual
4149 machines that are currently registered with this VirtualBox
4150 installation. Also, once a session has been opened for the given virtual
4151 machine (e.g. the virtual machine is running), the machine object
4152 associated with the open session can be queried from the session object;
4153 see <link to="ISession"/> for details.
4154
4155 The main role of this interface is to expose the settings of the virtual
4156 machine and provide methods to change various aspects of the virtual
4157 machine's configuration. For machine objects stored in the
4158 <link to="IVirtualBox::machines"/> collection, all attributes are
4159 read-only unless explicitly stated otherwise in individual attribute
4160 and method descriptions. In order to change a machine setting, a session
4161 for this machine must be opened using one of
4162 <link to="IVirtualBox::openSession"/>,
4163 <link to="IVirtualBox::openRemoteSession"/> or
4164 <link to="IVirtualBox::openExistingSession"/> methods. After the
4165 session has been successfully opened, a mutable machine object needs to
4166 be queried from the session object and then the desired settings changes
4167 can be applied to the returned object using IMachine attributes and
4168 methods. See the ISession interface description for more information
4169 about sessions.
4170
4171 Note that the IMachine interface does not provide methods to control
4172 virtual machine execution (such as start the machine, or power it
4173 down) -- these methods are grouped in a separate IConsole
4174 interface. Refer to the IConsole interface description to get more
4175 information about this topic.
4176
4177 <see>ISession, IConsole</see>
4178 </desc>
4179
4180 <attribute name="parent" type="IVirtualBox" readonly="yes">
4181 <desc>Associated parent object.</desc>
4182 </attribute>
4183
4184 <attribute name="accessible" type="boolean" readonly="yes">
4185 <desc>
4186 Whether this virtual machine is currently accessible or not.
4187
4188 The machine is considered to be inaccessible when:
4189 <ul>
4190 <li>It is a registered virtual machine, and
4191 </li>
4192 <li>Its settings file is inaccessible (for example, it is
4193 located on a network share that is not accessible during
4194 VirtualBox startup, or becomes inaccessible later, or if
4195 the settings file can be read but is invalid).
4196 </li>
4197 </ul>
4198
4199 Otherwise, the value of this property is always <tt>true</tt>.
4200
4201 Every time this property is read, the accessibility state of
4202 this machine is re-evaluated. If the returned value is |false|,
4203 the <link to="#accessError"/> property may be used to get the
4204 detailed error information describing the reason of
4205 inaccessibility.
4206
4207 When the machine is inaccessible, only the following properties
4208 can be used on it:
4209 <ul>
4210 <li><link to="#parent"/></li>
4211 <li><link to="#id"/></li>
4212 <li><link to="#settingsFilePath"/></li>
4213 <li><link to="#accessible"/></li>
4214 <li><link to="#accessError"/></li>
4215 </ul>
4216
4217 An attempt to access any other property or method will return
4218 an error.
4219
4220 The only possible action you can perform on an inaccessible
4221 machine is to unregister it using the
4222 <link to="IVirtualBox::unregisterMachine"/> call (or, to check
4223 for the accessibility state once more by querying this
4224 property).
4225
4226 <note>
4227 In the current implementation, once this property returns
4228 <tt>true</tt>, the machine will never become inaccessible
4229 later, even if its settings file cannot be successfully
4230 read/written any more (at least, until the VirtualBox
4231 server is restarted). This limitation may be removed in
4232 future releases.
4233 </note>
4234 </desc>
4235 </attribute>
4236
4237 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
4238 <desc>
4239 Error information describing the reason of machine
4240 inaccessibility.
4241
4242 Reading this property is only valid after the last call to
4243 <link to="#accessible"/> returned <tt>false</tt> (i.e. the
4244 machine is currently unaccessible). Otherwise, a null
4245 IVirtualBoxErrorInfo object will be returned.
4246 </desc>
4247 </attribute>
4248
4249 <attribute name="name" type="wstring">
4250 <desc>
4251 Name of the virtual machine.
4252
4253 Besides being used for human-readable identification purposes
4254 everywhere in VirtualBox, the virtual machine name is also used
4255 as a name of the machine's settings file and as a name of the
4256 subdirectory this settings file resides in. Thus, every time you
4257 change the value of this property, the settings file will be
4258 renamed once you call <link to="#saveSettings"/> to confirm the
4259 change. The containing subdirectory will be also renamed, but
4260 only if it has exactly the same name as the settings file
4261 itself prior to changing this property (for backward compatibility
4262 with previous API releases). The above implies the following
4263 limitations:
4264 <ul>
4265 <li>The machine name cannot be empty.</li>
4266 <li>The machine name can contain only characters that are valid
4267 file name characters according to the rules of the file
4268 system used to store VirtualBox configuration.</li>
4269 <li>You cannot have two or more machines with the same name
4270 if they use the same subdirectory for storing the machine
4271 settings files.</li>
4272 <li>You cannot change the name of the machine if it is running,
4273 or if any file in the directory containing the settings file
4274 is being used by another running machine or by any other
4275 process in the host operating system at a time when
4276 <link to="#saveSettings"/> is called.
4277 </li>
4278 </ul>
4279 If any of the above limitations are hit, <link to="#saveSettings"/>
4280 will return an appropriate error message explaining the exact
4281 reason and the changes you made to this machine will not be
4282 saved.
4283 <note>
4284 For "legacy" machines created using the
4285 <link to="IVirtualBox::createLegacyMachine"/> call,
4286 the above naming limitations do not apply because the
4287 machine name does not affect the settings file name.
4288 The settings file name remains the same as it was specified
4289 during machine creation and never changes.
4290 </note>
4291 </desc>
4292 </attribute>
4293
4294 <attribute name="description" type="wstring">
4295 <desc>
4296 Description of the virtual machine.
4297
4298 The description attribute can contain any text and is
4299 typically used to describe the hardware and software
4300 configuration of the virtual machine in detail (i.e. network
4301 settings, versions of the installed software and so on).
4302 </desc>
4303 </attribute>
4304
4305 <attribute name="id" type="wstring" readonly="yes">
4306 <desc>UUID of the virtual machine.</desc>
4307 </attribute>
4308
4309 <attribute name="OSTypeId" type="wstring">
4310 <desc>
4311 User-defined identifier of the Guest OS type.
4312 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
4313 an IGuestOSType object representing details about the given
4314 Guest OS type.
4315 <note>
4316 This value may differ from the value returned by
4317 <link to="IGuest::OSTypeId"/> if Guest Additions are
4318 installed to the guest OS.
4319 </note>
4320 </desc>
4321 </attribute>
4322
4323 <attribute name="HardwareVersion" type="wstring">
4324 <desc>Hardware version identifier. Internal use only for now.</desc>
4325 </attribute>
4326
4327 <attribute name="CPUCount" type="unsigned long">
4328 <desc>Number of virtual CPUs in the VM. In the current version of the product, this is always 1.</desc>
4329 </attribute>
4330
4331 <attribute name="memorySize" type="unsigned long">
4332 <desc>System memory size in megabytes.</desc>
4333 </attribute>
4334
4335 <attribute name="memoryBalloonSize" type="unsigned long">
4336 <desc>Initial memory balloon size in megabytes.</desc>
4337 </attribute>
4338
4339 <attribute name="statisticsUpdateInterval" type="unsigned long">
4340 <desc>Initial interval to update guest statistics in seconds.</desc>
4341 </attribute>
4342
4343 <attribute name="VRAMSize" type="unsigned long">
4344 <desc>Video memory size in megabytes.</desc>
4345 </attribute>
4346
4347 <attribute name="accelerate3DEnabled" type="boolean" default="false">
4348 <desc>
4349 This setting determines whether VirtualBox allows guests to make use
4350 of the 3D graphics support available on the host. Currently limited
4351 to OpenGL only. </desc>
4352 </attribute>
4353
4354 <attribute name="monitorCount" type="unsigned long">
4355 <desc>
4356 Number of virtual monitors.
4357 <note>
4358 Only effective on Windows XP and later guests with
4359 Guest Additions installed.
4360 </note>
4361 </desc>
4362 </attribute>
4363
4364 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
4365 <desc>Object containing all BIOS settings.</desc>
4366 </attribute>
4367
4368 <attribute name="HWVirtExEnabled" type="TSBool">
4369 <desc>
4370 This setting determines whether VirtualBox will try to make use of
4371 the host CPU's hardware virtualization extensions such as Intel VT-x
4372 and AMD-V. Note that in case such extensions are not available,
4373 they will not be used.
4374 </desc>
4375 </attribute>
4376
4377 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" default="false">
4378 <desc>
4379 This setting determines whether VirtualBox will try to make use of
4380 the nested paging extension of Intel VT-x and AMD-V. Note that in case
4381 such extensions are not available, they will not be used.
4382 </desc>
4383 </attribute>
4384
4385 <attribute name="HWVirtExVPIDEnabled" type="boolean" default="false">
4386 <desc>
4387 This setting determines whether VirtualBox will try to make use of
4388 the VPID extension of Intel VT-x. Note that in case such extensions are
4389 not available, they will not be used.
4390 </desc>
4391 </attribute>
4392
4393 <attribute name="PAEEnabled" type="boolean" default="false">
4394 <desc>
4395 This setting determines whether VirtualBox will expose the Physical Address
4396 Extension (PAE) feature of the host CPU to the guest. Note that in case PAE
4397 is not available, it will not be reported.
4398 </desc>
4399 </attribute>
4400
4401 <attribute name="snapshotFolder" type="wstring">
4402 <desc>
4403 Full path to the directory used to store snapshot data
4404 (differencing hard disks and saved state files) of this machine.
4405
4406 The initial value of this property is
4407 <tt>&lt;</tt><link to="#settingsFilePath">
4408 path_to_settings_file</link><tt>&gt;/&lt;</tt>
4409 <link to="#id">machine_uuid</link>
4410 <tt>&gt;</tt>.
4411
4412 Currently, it is an error to try to change this property on
4413 a machine that has snapshots (because this would require to
4414 move possibly large files to a different location).
4415 A separate method will be available for this purpose later.
4416
4417 <note>
4418 Setting this property to <tt>null</tt> will restore the
4419 initial value.
4420 </note>
4421 <note>
4422 When setting this property, the specified path can be
4423 absolute (full path) or relative to the directory where the
4424 <link to="#settingsFilePath">machine settings file</link>
4425 is located. When reading this property, a full path is
4426 always returned.
4427 </note>
4428 <note>
4429 The specified path may not exist, it will be created
4430 when necessary.
4431 </note>
4432 </desc>
4433 </attribute>
4434
4435 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
4436 <desc>VRDP server object.</desc>
4437 </attribute>
4438
4439 <attribute name="hardDiskAttachments" type="IHardDiskAttachment" readonly="yes" safearray="yes">
4440 <desc>Array of hard disks attached to this machine.</desc>
4441 </attribute>
4442
4443 <attribute name="DVDDrive" type="IDVDDrive" readonly="yes">
4444 <desc>Associated DVD drive object.</desc>
4445 </attribute>
4446
4447 <attribute name="floppyDrive" type="IFloppyDrive" readonly="yes">
4448 <desc>Associated floppy drive object.</desc>
4449 </attribute>
4450
4451 <attribute name="USBController" type="IUSBController" readonly="yes">
4452 <desc>
4453 Associated USB controller object.
4454
4455 <note>
4456 If USB functionality is not available in the given edition of
4457 VirtualBox, this method will set the result code to @c E_NOTIMPL.
4458 </note>
4459 </desc>
4460 </attribute>
4461
4462 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
4463 <desc>Associated audio adapter, always present.</desc>
4464 </attribute>
4465
4466 <attribute name="storageControllers" type="IStorageController" readonly="yes" safearray="yes">
4467 <desc>Array of storage controllers attached to this machine.</desc>
4468 </attribute>
4469
4470 <attribute name="settingsFilePath" type="wstring" readonly="yes">
4471 <desc>
4472 Full name of the file containing machine settings data.
4473 </desc>
4474 </attribute>
4475
4476 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
4477 <desc>
4478 Current version of the format of the settings file of this machine
4479 (<link to="IMachine::settingsFilePath"/>).
4480
4481 The version string has the following format:
4482 <pre>
4483 x.y-platform
4484 </pre>
4485 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
4486 versions, and <tt>platform</tt> is the platform identifier.
4487
4488 The current version usually matches the value of the
4489 <link to="IVirtualBox::settingsFormatVersion"/> attribute unless the
4490 settings file was created by an older version of VirtualBox and there
4491 was a change of the settings file format since then.
4492
4493 Note that VirtualBox automatically converts settings files from older
4494 versions to the most recent version when reading them (usually at
4495 VirtualBox startup) but it doesn't save the changes back until
4496 you call a method that implicitly saves settings (such as
4497 <link to="#setExtraData"/>) or call <link to="#saveSettings"/>
4498 explicitly. Therefore, if the value of this attribute differs from the
4499 value of <link to="IVirtualBox::settingsFormatVersion"/>, then it
4500 means that the settings file was converted but the result of the
4501 conversion is not yet saved to disk.
4502
4503 The above feature may be used by interactive front-ends to inform users
4504 about the settings file format change and offer them to explicitly save
4505 all converted settings files (the global and VM-specific ones),
4506 optionally create backup copies of the old settings files before saving,
4507 etc.
4508
4509 <see>IVirtualBox::settingsFormatVersion, saveSettingsWithBackup()</see>
4510 </desc>
4511 </attribute>
4512
4513 <attribute name="settingsModified" type="boolean" readonly="yes">
4514 <desc>
4515 Whether the settings of this machine have been modified
4516 (but neither yet saved nor discarded).
4517 <note>
4518 Reading this property is only valid on instances returned
4519 by <link to="ISession::machine"/> and on new machines
4520 created by <link to="IVirtualBox::createMachine"/> or opened
4521 by <link to="IVirtualBox::openMachine"/> but not
4522 yet registered, or on unregistered machines after calling
4523 <link to="IVirtualBox::unregisterMachine"/>. For all other
4524 cases, the settings can never be modified.
4525 </note>
4526 <note>
4527 For newly created unregistered machines, the value of this
4528 property is always TRUE until <link to="#saveSettings"/>
4529 is called (no matter if any machine settings have been
4530 changed after the creation or not). For opened machines
4531 the value is set to FALSE (and then follows to normal rules).
4532 </note>
4533 </desc>
4534 </attribute>
4535
4536 <attribute name="sessionState" type="SessionState" readonly="yes">
4537 <desc>Current session state for this machine.</desc>
4538 </attribute>
4539
4540 <attribute name="sessionType" type="wstring" readonly="yes">
4541 <desc>
4542 Type of the session. If <link to="#sessionState"/> is
4543 SessionSpawning or SessionOpen, this attribute contains the
4544 same value as passed to the
4545 <link to="IVirtualBox::openRemoteSession"/> method in the
4546 @a type parameter. If the session was opened directly using
4547 <link to="IVirtualBox::openSession"/>, or if
4548 <link to="#sessionState"/> is SessionClosed, the value of this
4549 attribute is @c null.
4550 </desc>
4551 </attribute>
4552
4553 <attribute name="sessionPid" type="unsigned long" readonly="yes">
4554 <desc>
4555 Identifier of the session process. This attribute contains the
4556 platform-dependent identifier of the process that has opened a
4557 direct session for this machine using the
4558 <link to="IVirtualBox::openSession"/> call. The returned value
4559 is only valid if <link to="#sessionState"/> is SessionOpen or
4560 SessionClosing (i.e. a session is currently open or being
4561 closed) by the time this property is read.
4562 </desc>
4563 </attribute>
4564
4565 <attribute name="state" type="MachineState" readonly="yes">
4566 <desc>Current execution state of this machine.</desc>
4567 </attribute>
4568
4569 <attribute name="lastStateChange" type="long long" readonly="yes">
4570 <desc>
4571 Time stamp of the last execution state change,
4572 in milliseconds since 1970-01-01 UTC.
4573 </desc>
4574 </attribute>
4575
4576 <attribute name="stateFilePath" type="wstring" readonly="yes">
4577 <desc>
4578 Full path to the file that stores the execution state of
4579 the machine when it is in the <link to="MachineState_Saved"/> state.
4580 <note>
4581 When the machine is not in the Saved state, this attribute
4582 <tt>null</tt>.
4583 </note>
4584 </desc>
4585 </attribute>
4586
4587 <attribute name="logFolder" type="wstring" readonly="yes">
4588 <desc>
4589 Full path to the folder that stores a set of rotated log files
4590 recorded during machine execution. The most recent log file is
4591 named <tt>VBox.log</tt>, the previous log file is
4592 named <tt>VBox.log.1</tt> and so on (up to <tt>VBox.log.3</tt>
4593 in the current version).
4594 </desc>
4595 </attribute>
4596
4597 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
4598 <desc>
4599 Current snapshot of this machine.
4600 <note>
4601 A <tt>null</tt> object is returned if the machine doesn't
4602 have snapshots.
4603 </note>
4604 <see><link to="ISnapshot"/></see>
4605 </desc>
4606 </attribute>
4607
4608 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
4609 <desc>
4610 Number of snapshots taken on this machine. Zero means the
4611 machine doesn't have any snapshots.
4612 </desc>
4613 </attribute>
4614
4615 <attribute name="currentStateModified" type="boolean" readonly="yes">
4616 <desc>
4617 Returns <tt>true</tt> if the current state of the machine is not
4618 identical to the state stored in the current snapshot.
4619
4620 The current state is identical to the current snapshot right
4621 after one of the following calls are made:
4622 <ul>
4623 <li><link to="IConsole::discardCurrentState"/> or
4624 <link to="IConsole::discardCurrentSnapshotAndState"/>
4625 </li>
4626 <li><link to="IConsole::takeSnapshot"/> (issued on a
4627 powered off or saved machine, for which
4628 <link to="#settingsModified"/> returns <tt>false</tt>)
4629 </li>
4630 <li><link to="IMachine::setCurrentSnapshot"/>
4631 </li>
4632 </ul>
4633
4634 The current state remains identical until one of the following
4635 happens:
4636 <ul>
4637 <li>settings of the machine are changed</li>
4638 <li>the saved state is discarded</li>
4639 <li>the current snapshot is discarded</li>
4640 <li>an attempt to execute the machine is made</li>
4641 </ul>
4642
4643 <note>
4644 For machines that don't have snapshots, this property is
4645 always <tt>false</tt>.
4646 </note>
4647 </desc>
4648 </attribute>
4649
4650 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
4651 <desc>
4652 Collection of shared folders for this machine (permanent shared
4653 folders). These folders are shared automatically at machine startup
4654 and available only to the guest OS installed within this machine.
4655
4656 New shared folders are added to the collection using
4657 <link to="#createSharedFolder"/>. Existing shared folders can be
4658 removed using <link to="#removeSharedFolder"/>.
4659 </desc>
4660 </attribute>
4661
4662 <attribute name="clipboardMode" type="ClipboardMode">
4663 <desc>
4664 Synchronization mode between the host OS clipboard
4665 and the guest OS clipboard.
4666 </desc>
4667 </attribute>
4668
4669 <attribute name="guestPropertyNotificationPatterns" type="wstring">
4670 <desc>
4671 A comma-separated list of simple glob patterns. Changes to guest
4672 properties whose name matches one of the patterns will generate an
4673 <link to="IVirtualBoxCallback::onGuestPropertyChange"/> signal.
4674 </desc>
4675 </attribute>
4676
4677 <method name="setBootOrder">
4678 <desc>
4679 Puts the given device to the specified position in
4680 the boot order.
4681
4682 To indicate that no device is associated with the given position,
4683 <link to="DeviceType_Null"/> should be used.
4684
4685 @todo setHardDiskBootOrder(), setNetworkBootOrder()
4686
4687 <result name="E_INVALIDARG">
4688 Boot @a position out of range.
4689 </result>
4690 <result name="E_NOTIMPL">
4691 Booting from USB @a device currently not supported.
4692 </result>
4693
4694 </desc>
4695 <param name="position" type="unsigned long" dir="in">
4696 <desc>
4697 Position in the boot order (<tt>1</tt> to the total number of
4698 devices the machine can boot from, as returned by
4699 <link to="ISystemProperties::maxBootPosition"/>).
4700 </desc>
4701 </param>
4702 <param name="device" type="DeviceType" dir="in">
4703 <desc>
4704 The type of the device used to boot at the given position.
4705 </desc>
4706 </param>
4707 </method>
4708
4709 <method name="getBootOrder" const="yes">
4710 <desc>
4711 Returns the device type that occupies the specified
4712 position in the boot order.
4713
4714 @todo [remove?]
4715 If the machine can have more than one device of the returned type
4716 (such as hard disks), then a separate method should be used to
4717 retrieve the individual device that occupies the given position.
4718
4719 If here are no devices at the given position, then
4720 <link to="DeviceType_Null"/> is returned.
4721
4722 @todo getHardDiskBootOrder(), getNetworkBootOrder()
4723
4724 <result name="E_INVALIDARG">
4725 Boot @a position out of range.
4726 </result>
4727
4728 </desc>
4729 <param name="position" type="unsigned long" dir="in">
4730 <desc>
4731 Position in the boot order (<tt>1</tt> to the total number of
4732 devices the machine can boot from, as returned by
4733 <link to="ISystemProperties::maxBootPosition"/>).
4734 </desc>
4735 </param>
4736 <param name="device" type="DeviceType" dir="return">
4737 <desc>
4738 Device at the given position.
4739 </desc>
4740 </param>
4741 </method>
4742
4743 <method name="attachHardDisk">
4744 <desc>
4745 Attaches a virtual hard disk (<link to="IHardDisk" />, identified
4746 by the given UUID @a id) to the given hard disk controller
4747 (<link to="IStorageController" />, identified by @a name),
4748 at the indicated port and device.
4749
4750 For the IDE bus, the @a controllerPort parameter can be either
4751 @c 0 or @c 1, to specify the primary or secondary IDE controller,
4752 respectively. For the primary controller of the IDE bus,
4753 @a device can be either @c 0 or @c 1, to specify the master or the
4754 slave device, respectively. For the secondary IDE controller, the
4755 device number must be @c 1 because VirtualBox reserves the
4756 secondary master for the CD-ROM drive.
4757
4758 For an SATA controller, @a controllerPort must be a number ranging
4759 from @c 0 to @c 29. For a SCSI controller, @a controllerPort must
4760 be a number ranging from @c 0 to @c 15.
4761
4762 For both SCSI and SATA, the @a device parameter is unused and must
4763 be @c 0.
4764
4765 The specified device slot must not have another disk attached to it, or
4766 this method will fail.
4767
4768 See <link to="IHardDisk"/> for more detailed information about
4769 attaching hard disks.
4770
4771 <note>
4772 You cannot attach a hard disk to a running machine. Also, you cannot
4773 attach a hard disk to a newly created machine until this machine's
4774 settings are saved to disk using <link to="#saveSettings"/>.
4775 </note>
4776 <note>
4777 If the hard disk is being attached indirectly, a new differencing hard
4778 disk will implicitly be created for it and attached instead. If the
4779 changes made to the machine settings (including this indirect
4780 attachment) are later cancelled using <link to="#discardSettings"/>,
4781 this implicitly created differencing hard disk will implicitly
4782 be deleted.
4783 </note>
4784
4785 <result name="E_INVALIDARG">
4786 SATA device, SATA port, IDE port or IDE slot out of range.
4787 </result>
4788 <result name="VBOX_E_INVALID_OBJECT_STATE">
4789 Attempt to attach hard disk to an unregistered virtual machine.
4790 </result>
4791 <result name="VBOX_E_INVALID_VM_STATE">
4792 Invalid machine state.
4793 </result>
4794 <result name="VBOX_E_OBJECT_IN_USE">
4795 Hard disk already attached to this or another virtual machine.
4796 </result>
4797
4798 </desc>
4799 <param name="id" type="wstring" dir="in">
4800 <desc>UUID of the hard disk to attach.</desc>
4801 </param>
4802 <param name="name" type="wstring" dir="in">
4803 <desc>Name of the storage controller to attach the hard disk to.</desc>
4804 </param>
4805 <param name="controllerPort" type="long" dir="in">
4806 <desc>Port to attach the hard disk to.</desc>
4807 </param>
4808 <param name="device" type="long" dir="in">
4809 <desc>
4810 Device slot in the given port to attach the hard disk to.
4811 </desc>
4812 </param>
4813 </method>
4814
4815 <method name="getHardDisk" const="yes">
4816 <desc>
4817 Returns the virtual hard disk attached to a device slot of the specified
4818 bus.
4819
4820 Note that if the hard disk was indirectly attached by
4821 <link to="#attachHardDisk"/> to the given device slot then this
4822 method will return not the same object as passed to the
4823 <link to="#attachHardDisk"/> call. See <link to="IHardDisk"/> for
4824 more detailed information about attaching hard disks.
4825
4826 <result name="VBOX_E_OBJECT_NOT_FOUND">
4827 No hard disk attached to given slot/bus.
4828 </result>
4829
4830 </desc>
4831 <param name="name" type="wstring" dir="in">
4832 <desc>Name of the storage controller the hard disk is attached to.</desc>
4833 </param>
4834 <param name="controllerPort" type="long" dir="in">
4835 <desc>Port to query.</desc>
4836 </param>
4837 <param name="device" type="long" dir="in">
4838 <desc>Device slot in the given port to query.</desc>
4839 </param>
4840 <param name="hardDisk" type="IHardDisk" dir="return">
4841 <desc>Attached hard disk object.</desc>
4842 </param>
4843 </method>
4844
4845 <method name="detachHardDisk">
4846 <desc>
4847 Detaches the virtual hard disk attached to a device slot of the
4848 specified bus.
4849
4850 Detaching the hard disk from the virtual machine is deferred. This means
4851 that the hard disk remains associated with the machine when this method
4852 returns and gets actually de-associated only after a successful
4853 <link to="#saveSettings"/> call. See <link to="IHardDisk"/>
4854 for more detailed information about attaching hard disks.
4855
4856 <note>
4857 You cannot detach the hard disk from a running machine.
4858 </note>
4859 <note>
4860 Detaching differencing hard disks implicitly created by <link
4861 to="#attachHardDisk"/> for the indirect attachment using this
4862 method will <b>not</b> implicitly delete them. The
4863 <link to="IHardDisk::deleteStorage"/> operation should be
4864 explicitly performed by the caller after the hard disk is successfully
4865 detached and the settings are saved with
4866 <link to="#saveSettings"/>, if it is the desired action.
4867 </note>
4868
4869 <result name="VBOX_E_INVALID_VM_STATE">
4870 Attempt to detach hard disk from a running virtual machine.
4871 </result>
4872 <result name="VBOX_E_OBJECT_NOT_FOUND">
4873 No hard disk attached to given slot/bus.
4874 </result>
4875 <result name="VBOX_E_NOT_SUPPORTED">
4876 Hard disk format does not support storage deletion.
4877 </result>
4878
4879 </desc>
4880 <param name="name" type="wstring" dir="in">
4881 <desc>name of the storage controller to detach the hard disk from.</desc>
4882 </param>
4883 <param name="controllerPort" type="long" dir="in">
4884 <desc>Port number to detach the hard disk from.</desc>
4885 </param>
4886 <param name="device" type="long" dir="in">
4887 <desc>Device slot number to detach the hard disk from.</desc>
4888 </param>
4889 </method>
4890
4891 <method name="getHardDiskAttachmentsOfController" const="yes">
4892 <desc>
4893 Returns an array of hard disk attachments which are attached to the
4894 the controller with the given name.
4895
4896 <result name="VBOX_E_OBJECT_NOT_FOUND">
4897 A storage controller with given name doesn't exist.
4898 </result>
4899 </desc>
4900 <param name="name" type="wstring" dir="in"/>
4901 <param name="hardDiskAttachments" type="IHardDiskAttachment" safearray="yes" dir="return"/>
4902 </method>
4903
4904 <method name="getNetworkAdapter" const="yes">
4905 <desc>
4906 Returns the network adapter associated with the given slot.
4907 Slots are numbered sequentially, starting with zero. The total
4908 number of adapters per machine is defined by the
4909 <link to="ISystemProperties::networkAdapterCount"/> property,
4910 so the maximum slot number is one less than that property's value.
4911
4912 <result name="E_INVALIDARG">
4913 Invalid @a slot number.
4914 </result>
4915
4916 </desc>
4917 <param name="slot" type="unsigned long" dir="in"/>
4918 <param name="adapter" type="INetworkAdapter" dir="return"/>
4919 </method>
4920
4921 <method name="addStorageController">
4922 <desc>
4923 Adds a new storage controller (SCSI or SATA controller) to the
4924 machine and returns it as an instance of
4925 <link to="IStorageController" />.
4926
4927 @a name identifies the controller for subsequent calls such as
4928 <link to="#getStorageControllerByName" /> or
4929 <link to="#removeStorageController" /> or
4930 <link to="#attachHardDisk" />.
4931
4932 After the controller has been added, you can set its exact
4933 type by setting the <link to="IStorageController::controllerType" />.
4934
4935 <result name="VBOX_E_OBJECT_IN_USE">
4936 A storage controller with given name exists already.
4937 </result>
4938 <result name="E_INVALIDARG">
4939 Invalid @a controllerType.
4940 </result>
4941 </desc>
4942 <param name="name" type="wstring" dir="in"/>
4943 <param name="connectionType" type="StorageBus" dir="in"/>
4944 <param name="controller" type="IStorageController" dir="return"/>
4945 </method>
4946
4947 <method name="getStorageControllerByName" const="yes">
4948 <desc>
4949 Returns a storage controller with the given name.
4950
4951 <result name="VBOX_E_OBJECT_NOT_FOUND">
4952 A storage controller with given name doesn't exist.
4953 </result>
4954 </desc>
4955 <param name="name" type="wstring" dir="in"/>
4956 <param name="storageController" type="IStorageController" dir="return"/>
4957 </method>
4958
4959 <method name="removeStorageController">
4960 <desc>
4961 Removes a storage controller from the machine.
4962
4963 <result name="VBOX_E_OBJECT_NOT_FOUND">
4964 A storage controller with given name doesn't exist.
4965 </result>
4966 </desc>
4967 <param name="name" type="wstring" dir="in"/>
4968 </method>
4969
4970 <method name="getSerialPort" const="yes">
4971 <desc>
4972 Returns the serial port associated with the given slot.
4973 Slots are numbered sequentially, starting with zero. The total
4974 number of serial ports per machine is defined by the
4975 <link to="ISystemProperties::serialPortCount"/> property,
4976 so the maximum slot number is one less than that property's value.
4977
4978 <result name="E_INVALIDARG">
4979 Invalid @a slot number.
4980 </result>
4981
4982 </desc>
4983 <param name="slot" type="unsigned long" dir="in"/>
4984 <param name="port" type="ISerialPort" dir="return"/>
4985 </method>
4986
4987 <method name="getParallelPort" const="yes">
4988 <desc>
4989 Returns the parallel port associated with the given slot.
4990 Slots are numbered sequentially, starting with zero. The total
4991 number of parallel ports per machine is defined by the
4992 <link to="ISystemProperties::parallelPortCount"/> property,
4993 so the maximum slot number is one less than that property's value.
4994
4995 <result name="E_INVALIDARG">
4996 Invalid @a slot number.
4997 </result>
4998
4999 </desc>
5000 <param name="slot" type="unsigned long" dir="in"/>
5001 <param name="port" type="IParallelPort" dir="return"/>
5002 </method>
5003
5004 <method name="getNextExtraDataKey">
5005 <desc>
5006 Returns the machine-specific extra data key name following the
5007 supplied key.
5008
5009 An error is returned if the supplied @a key does not exist. @c NULL is
5010 returned in @a nextKey if the supplied key is the last key. When
5011 supplying @c NULL for the @a key, the first key item is returned in
5012 @a nextKey (if there is any). @a nextValue is an optional parameter and
5013 if supplied, the next key's value is returned in it.
5014
5015 <result name="VBOX_E_OBJECT_NOT_FOUND">
5016 Extra data @a key not found.
5017 </result>
5018
5019 </desc>
5020 <param name="key" type="wstring" dir="in">
5021 <desc>Name of the data key to follow.</desc>
5022 </param>
5023 <param name="nextKey" type="wstring" dir="out">
5024 <desc>Name of the next data key.</desc>
5025 </param>
5026 <param name="nextValue" type="wstring" dir="out">
5027 <desc>Value of the next data key.</desc>
5028 </param>
5029 </method>
5030
5031 <method name="getExtraData">
5032 <desc>
5033 Returns associated machine-specific extra data.
5034
5035 If the requested data @a key does not exist, this function will
5036 succeed and return @c NULL in the @a value argument.
5037
5038 <result name="VBOX_E_FILE_ERROR">
5039 Settings file not accessible.
5040 </result>
5041 <result name="VBOX_E_XML_ERROR">
5042 Could not parse the settings file.
5043 </result>
5044
5045 </desc>
5046 <param name="key" type="wstring" dir="in">
5047 <desc>Name of the data key to get.</desc>
5048 </param>
5049 <param name="value" type="wstring" dir="return">
5050 <desc>Value of the requested data key.</desc>
5051 </param>
5052 </method>
5053
5054 <method name="setExtraData">
5055 <desc>
5056 Sets associated machine-specific extra data.
5057
5058 If you pass @c NULL as a key @a value, the given @a key will be
5059 deleted.
5060
5061 <note>
5062 Before performing the actual data change, this method will ask all
5063 registered callbacks using the
5064 <link to="IVirtualBoxCallback::onExtraDataCanChange"/>
5065 notification for a permission. If one of the callbacks refuses the
5066 new value, the change will not be performed.
5067 </note>
5068 <note>
5069 On success, the
5070 <link to="IVirtualBoxCallback::onExtraDataChange"/> notification
5071 is called to inform all registered callbacks about a successful data
5072 change.
5073 </note>
5074 <note>
5075 This method can be called outside the machine session and therefore
5076 it's a caller's responsibility to handle possible race conditions
5077 when several clients change the same key at the same time.
5078 </note>
5079
5080 <result name="VBOX_E_FILE_ERROR">
5081 Settings file not accessible.
5082 </result>
5083 <result name="VBOX_E_XML_ERROR">
5084 Could not parse the settings file.
5085 </result>
5086
5087 </desc>
5088 <param name="key" type="wstring" dir="in">
5089 <desc>Name of the data key to set.</desc>
5090 </param>
5091 <param name="value" type="wstring" dir="in">
5092 <desc>Value to assign to the key.</desc>
5093 </param>
5094 </method>
5095
5096 <method name="saveSettings">
5097 <desc>
5098 Saves any changes to machine settings made since the session
5099 has been opened or a new machine has been created, or since the
5100 last call to <link to="#saveSettings"/> or <link to="#discardSettings"/>.
5101 For registered machines, new settings become visible to all
5102 other VirtualBox clients after successful invocation of this
5103 method.
5104 <note>
5105 The method sends <link to="IVirtualBoxCallback::onMachineDataChange"/>
5106 notification event after the configuration has been successfully
5107 saved (only for registered machines).
5108 </note>
5109 <note>
5110 Calling this method is only valid on instances returned
5111 by <link to="ISession::machine"/> and on new machines
5112 created by <link to="IVirtualBox::createMachine"/> but not
5113 yet registered, or on unregistered machines after calling
5114 <link to="IVirtualBox::unregisterMachine"/>.
5115 </note>
5116
5117 <result name="VBOX_E_FILE_ERROR">
5118 Settings file not accessible.
5119 </result>
5120 <result name="VBOX_E_XML_ERROR">
5121 Could not parse the settings file.
5122 </result>
5123 <result name="E_ACCESSDENIED">
5124 Modification request refused.
5125 </result>
5126
5127 </desc>
5128 </method>
5129
5130 <method name="saveSettingsWithBackup">
5131 <desc>
5132 Creates a backup copy of the machine settings file (<link
5133 to="IMachine::settingsFilePath"/>) in case of auto-conversion, and then calls
5134 <link to="IMachine::saveSettings"/>.
5135
5136 Note that the backup copy is created <b>only</b> if the settings file
5137 auto-conversion took place (see <link to="#settingsFileVersion"/> for
5138 details). Otherwise, this call is fully equivalent to
5139 <link to="IMachine::saveSettings"/> and no backup copying is done.
5140
5141 The backup copy is created in the same directory where the original
5142 settings file is located. It is given the following file name:
5143 <pre>
5144 original.xml.x.y-platform.bak
5145 </pre>
5146 where <tt>original.xml</tt> is the original settings file name
5147 (excluding path), and <tt>x.y-platform</tt> is the version of the old
5148 format of the settings file (before auto-conversion).
5149
5150 If the given backup file already exists, this method will try to add the
5151 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
5152 0 to 9) and copy it again until it succeeds. If all suffixes are
5153 occupied, or if any other copy error occurs, this method will return a
5154 failure.
5155
5156 If the copy operation succeeds, the @a bakFileName return argument will
5157 receive a full path to the created backup file (for informational
5158 purposes). Note that this will happen even if the subsequent
5159 <link to="#saveSettings"/> call performed by this method after the
5160 copy operation, fails.
5161
5162 <note>
5163 The VirtualBox API never calls this method. It is intended purely for
5164 the purposes of creating backup copies of the settings files by
5165 front-ends before saving the results of the automatically performed
5166 settings conversion to disk.
5167 </note>
5168
5169 <see>settingsFileVersion</see>
5170
5171 <result name="VBOX_E_FILE_ERROR">
5172 Settings file not accessible.
5173 </result>
5174 <result name="VBOX_E_XML_ERROR">
5175 Could not parse the settings file.
5176 </result>
5177 <result name="VBOX_E_INVALID_VM_STATE">
5178 Virtual machine is not mutable.
5179 </result>
5180 <result name="E_ACCESSDENIED">
5181 Modification request refused.
5182 </result>
5183
5184 </desc>
5185 <param name="bakFileName" type="wstring" dir="return">
5186 <desc>Full path to the created backup copy.</desc>
5187 </param>
5188 </method>
5189
5190 <method name="discardSettings">
5191 <desc>
5192 Discards any changes to the machine settings made since the session
5193 has been opened or since the last call to <link to="#saveSettings"/>
5194 or <link to="#discardSettings"/>.
5195 <note>
5196 Calling this method is only valid on instances returned
5197 by <link to="ISession::machine"/> and on new machines
5198 created by <link to="IVirtualBox::createMachine"/> or
5199 opened by <link to="IVirtualBox::openMachine"/> but not
5200 yet registered, or on unregistered machines after calling
5201 <link to="IVirtualBox::unregisterMachine"/>.
5202 </note>
5203
5204 <result name="VBOX_E_INVALID_VM_STATE">
5205 Virtual machine is not mutable.
5206 </result>
5207
5208 </desc>
5209 </method>
5210
5211 <method name="deleteSettings">
5212 <desc>
5213 Deletes the settings file of this machine from disk.
5214 The machine must not be registered in order for this operation
5215 to succeed.
5216 <note>
5217 <link to="#settingsModified"/> will return TRUE after this
5218 method successfully returns.
5219 </note>
5220 <note>
5221 Calling this method is only valid on instances returned
5222 by <link to="ISession::machine"/> and on new machines
5223 created by <link to="IVirtualBox::createMachine"/> or
5224 opened by <link to="IVirtualBox::openMachine"/> but not
5225 yet registered, or on unregistered machines after calling
5226 <link to="IVirtualBox::unregisterMachine"/>.
5227 </note>
5228 <note>
5229 The deleted machine settings file can be restored (saved again)
5230 by calling <link to="#saveSettings"/>.
5231 </note>
5232
5233 <result name="VBOX_E_INVALID_VM_STATE">
5234 Cannot delete settings of a registered machine or
5235 machine not mutable.
5236 </result>
5237 <result name="VBOX_E_IPRT_ERROR">
5238 Could not delete the settings file.
5239 </result>
5240
5241 </desc>
5242 </method>
5243
5244 <method name="export">
5245 <desc>Exports the machine to an OVF appliance. See <link to="IAppliance" /> for the
5246 steps required to export VirtualBox machines to OVF.
5247 </desc>
5248
5249 <param name="aAppliance" type="IAppliance" dir="in">
5250 <desc>Appliance to export this machine to.</desc>
5251 </param>
5252 <param name="aDescription" type="IVirtualSystemDescription" dir="return">
5253 <desc>VirtualSystemDescription object which is created for this machine.</desc>
5254 </param>
5255 </method >
5256
5257 <method name="getSnapshot">
5258 <desc>
5259 Returns a snapshot of this machine with the given UUID.
5260 A <tt>null</tt> UUID can be used to obtain the first snapshot
5261 taken on this machine. This is useful if you want to traverse
5262 the whole tree of snapshots starting from the root.
5263
5264 <result name="VBOX_E_OBJECT_NOT_FOUND">
5265 Virtual machine has no snapshots or snapshot not found.
5266 </result>
5267
5268 </desc>
5269 <param name="id" type="wstring" dir="in">
5270 <desc>UUID of the snapshot to get</desc>
5271 </param>
5272 <param name="snapshot" type="ISnapshot" dir="return">
5273 <desc>Snapshot object with the given UUID.</desc>
5274 </param>
5275 </method>
5276
5277 <method name="findSnapshot">
5278 <desc>
5279 Returns a snapshot of this machine with the given name.
5280
5281 <result name="VBOX_E_OBJECT_NOT_FOUND">
5282 Virtual machine has no snapshots or snapshot not found.
5283 </result>
5284
5285 </desc>
5286 <param name="name" type="wstring" dir="in">
5287 <desc>Name of the snapshot to find</desc>
5288 </param>
5289 <param name="snapshot" type="ISnapshot" dir="return">
5290 <desc>Snapshot object with the given name.</desc>
5291 </param>
5292 </method>
5293
5294 <method name="setCurrentSnapshot">
5295 <desc>
5296 Sets the current snapshot of this machine.
5297 <note>
5298 In the current implementation, this operation is not
5299 implemented.
5300 </note>
5301 </desc>
5302 <param name="id" type="wstring" dir="in">
5303 <desc>UUID of the snapshot to set as the current snapshot.</desc>
5304 </param>
5305 </method>
5306
5307 <method name="createSharedFolder">
5308 <desc>
5309 Creates a new permanent shared folder by associating the given logical
5310 name with the given host path, adds it to the collection of shared
5311 folders and starts sharing it. Refer to the description of
5312 <link to="ISharedFolder"/> to read more about logical names.
5313
5314 <result name="VBOX_E_OBJECT_IN_USE">
5315 Shared folder already exists.
5316 </result>
5317 <result name="VBOX_E_FILE_ERROR">
5318 Shared folder @a hostPath not accessible.
5319 </result>
5320
5321 </desc>
5322 <param name="name" type="wstring" dir="in">
5323 <desc>Unique logical name of the shared folder.</desc>
5324 </param>
5325 <param name="hostPath" type="wstring" dir="in">
5326 <desc>Full path to the shared folder in the host file system.</desc>
5327 </param>
5328 <param name="writable" type="boolean" dir="in">
5329 <desc>Whether the share is writable or readonly</desc>
5330 </param>
5331 </method>
5332
5333 <method name="removeSharedFolder">
5334 <desc>
5335 Removes the permanent shared folder with the given name previously
5336 created by <link to="#createSharedFolder"/> from the collection of
5337 shared folders and stops sharing it.
5338
5339 <result name="VBOX_E_INVALID_VM_STATE">
5340 Virtual machine is not mutable.
5341 </result>
5342 <result name="VBOX_E_OBJECT_NOT_FOUND">
5343 Shared folder @a name does not exist.
5344 </result>
5345
5346 </desc>
5347 <param name="name" type="wstring" dir="in">
5348 <desc>Logical name of the shared folder to remove.</desc>
5349 </param>
5350 </method>
5351
5352 <method name="canShowConsoleWindow">
5353 <desc>
5354 Returns @c true if the VM console process can activate the
5355 console window and bring it to foreground on the desktop of
5356 the host PC.
5357 <note>
5358 This method will fail if a session for this machine is not
5359 currently open.
5360 </note>
5361
5362 <result name="VBOX_E_INVALID_VM_STATE">
5363 Machine session is not open.
5364 </result>
5365
5366 </desc>
5367 <param name="canShow" type="boolean" dir="return">
5368 <desc>
5369 @c true if the console window can be shown and @c
5370 false otherwise.
5371 </desc>
5372 </param>
5373 </method>
5374
5375 <method name="showConsoleWindow">
5376 <desc>
5377 Activates the console window and brings it to foreground on
5378 the desktop of the host PC. Many modern window managers on
5379 many platforms implement some sort of focus stealing
5380 prevention logic, so that it may be impossible to activate
5381 a window without the help of the currently active
5382 application. In this case, this method will return a non-zero
5383 identifier that represents the top-level window of the VM
5384 console process. The caller, if it represents a currently
5385 active process, is responsible to use this identifier (in a
5386 platform-dependent manner) to perform actual window
5387 activation.
5388 <note>
5389 This method will fail if a session for this machine is not
5390 currently open.
5391 </note>
5392
5393 <result name="VBOX_E_INVALID_VM_STATE">
5394 Machine session is not open.
5395 </result>
5396
5397 </desc>
5398 <param name="winId" type="unsigned long long" dir="return">
5399 <desc>
5400 Platform-dependent identifier of the top-level VM console
5401 window, or zero if this method has performed all actions
5402 necessary to implement the <i>show window</i> semantics for
5403 the given platform and/or VirtualBox front-end.
5404 </desc>
5405 </param>
5406 </method>
5407
5408 <method name="getGuestProperty">
5409 <desc>
5410 Reads an entry from the machine's guest property store.
5411
5412 <result name="VBOX_E_INVALID_VM_STATE">
5413 Machine session is not open.
5414 </result>
5415
5416 </desc>
5417 <param name="name" type="wstring" dir="in">
5418 <desc>
5419 The name of the property to read.
5420 </desc>
5421 </param>
5422 <param name="value" type="wstring" dir="out">
5423 <desc>
5424 The value of the property. If the property does not exist then this
5425 will be empty.
5426 </desc>
5427 </param>
5428 <param name="timestamp" type="unsigned long long" dir="out">
5429 <desc>
5430 The time at which the property was last modified, as seen by the
5431 server process.
5432 </desc>
5433 </param>
5434 <param name="flags" type="wstring" dir="out">
5435 <desc>
5436 Additional property parameters, passed as a comma-separated list of
5437 "name=value" type entries.
5438 </desc>
5439 </param>
5440 </method>
5441
5442 <method name="getGuestPropertyValue">
5443 <desc>
5444 Reads a value from the machine's guest property store.
5445
5446 <result name="VBOX_E_INVALID_VM_STATE">
5447 Machine session is not open.
5448 </result>
5449
5450 </desc>
5451 <param name="property" type="wstring" dir="in">
5452 <desc>
5453 The name of the property to read.
5454 </desc>
5455 </param>
5456 <param name="value" type="wstring" dir="return">
5457 <desc>
5458 The value of the property. If the property does not exist then this
5459 will be empty.
5460 </desc>
5461 </param>
5462 </method>
5463
5464 <method name="getGuestPropertyTimestamp">
5465 <desc>
5466 Reads a property timestamp from the machine's guest property store.
5467
5468 <result name="VBOX_E_INVALID_VM_STATE">
5469 Machine session is not open.
5470 </result>
5471
5472 </desc>
5473 <param name="property" type="wstring" dir="in">
5474 <desc>
5475 The name of the property to read.
5476 </desc>
5477 </param>
5478 <param name="value" type="unsigned long long" dir="return">
5479 <desc>
5480 The timestamp. If the property does not exist then this will be
5481 empty.
5482 </desc>
5483 </param>
5484 </method>
5485
5486 <method name="setGuestProperty">
5487 <desc>
5488 Sets, changes or deletes an entry in the machine's guest property
5489 store.
5490
5491 <result name="E_ACCESSDENIED">
5492 Property cannot be changed.
5493 </result>
5494 <result name="E_INVALIDARG">
5495 Invalid @a flags.
5496 </result>
5497 <result name="VBOX_E_INVALID_VM_STATE">
5498 Virtual machine is not mutable or session not open.
5499 </result>
5500 <result name="VBOX_E_INVALID_OBJECT_STATE">
5501 Cannot set transient property when machine not running.
5502 </result>
5503
5504 </desc>
5505 <param name="property" type="wstring" dir="in">
5506 <desc>
5507 The name of the property to set, change or delete.
5508 </desc>
5509 </param>
5510 <param name="value" type="wstring" dir="in">
5511 <desc>
5512 The new value of the property to set, change or delete. If the
5513 property does not yet exist and value is non-empty, it will be
5514 created. If the value is empty, the key will be deleted if it
5515 exists.
5516 </desc>
5517 </param>
5518 <param name="flags" type="wstring" dir="in">
5519 <desc>
5520 Additional property parameters, passed as a comma-separated list of
5521 "name=value" type entries.
5522 </desc>
5523 </param>
5524 </method>
5525
5526 <method name="setGuestPropertyValue">
5527 <desc>
5528 Sets, changes or deletes a value in the machine's guest property
5529 store. The flags field will be left unchanged or created empty for a
5530 new property.
5531
5532 <result name="E_ACCESSDENIED">
5533 Property cannot be changed.
5534 </result>
5535 <result name="VBOX_E_INVALID_VM_STATE">
5536 Virtual machine is not mutable or session not open.
5537 </result>
5538 <result name="VBOX_E_INVALID_OBJECT_STATE">
5539 Cannot set transient property when machine not running.
5540 </result>
5541 </desc>
5542
5543 <param name="property" type="wstring" dir="in">
5544 <desc>
5545 The name of the property to set, change or delete.
5546 </desc>
5547 </param>
5548 <param name="value" type="wstring" dir="in">
5549 <desc>
5550 The new value of the property to set, change or delete. If the
5551 property does not yet exist and value is non-empty, it will be
5552 created. If value is empty, the property will be deleted if it
5553 exists.
5554 </desc>
5555 </param>
5556 </method>
5557
5558 <method name="enumerateGuestProperties">
5559 <desc>
5560 Return a list of the guest properties matching a set of patterns along
5561 with their values, time stamps and flags.
5562 </desc>
5563 <param name="patterns" type="wstring" dir="in">
5564 <desc>
5565 The patterns to match the properties against, separated by '|'
5566 characters. If this is empty or NULL, all properties will match.
5567 </desc>
5568 </param>
5569 <param name="name" type="wstring" dir="out" safearray="yes">
5570 <desc>
5571 The names of the properties returned.
5572 </desc>
5573 </param>
5574 <param name="value" type="wstring" dir="out" safearray="yes">
5575 <desc>
5576 The values of the properties returned. The array entries match the
5577 corresponding entries in the @a name array.
5578 </desc>
5579 </param>
5580 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
5581 <desc>
5582 The time stamps of the properties returned. The array entries match
5583 the corresponding entries in the @a name array.
5584 </desc>
5585 </param>
5586 <param name="flags" type="wstring" dir="out" safearray="yes">
5587 <desc>
5588 The flags of the properties returned. The array entries match the
5589 corresponding entries in the @a name array.
5590 </desc>
5591 </param>
5592 </method>
5593</interface>
5594
5595 <!--
5596 // IConsole
5597 /////////////////////////////////////////////////////////////////////////
5598 -->
5599
5600 <interface
5601 name="IConsoleCallback" extends="$unknown"
5602 uuid="13dfbef3-b74d-487d-bada-2304529aefa6"
5603 wsmap="suppress"
5604 >
5605
5606 <desc>
5607 This interface is used by a client of the Main API that need to
5608 be notified of events. For example, a graphical user interface
5609 can use this to learn about machine state changes so they can
5610 update the list of virtual machines without having to rely
5611 on polling.
5612
5613 Whenever relevant events occur in VirtualBox, the callbacks in
5614 objects of this interface are called. In order for this to be
5615 useful, a client needs to create its own subclass that implements
5616 this interface in which the methods for the relevant callbacks
5617 are overridden. An instance of this subclass interface can then
5618 be passed to <link to="IConsole::registerCallback" />.
5619 </desc>
5620
5621 <method name="onMousePointerShapeChange">
5622 <desc>
5623 Notification when the guest mouse pointer shape has
5624 changed. The new shape data is given.
5625 </desc>
5626 <param name="visible" type="boolean" dir="in">
5627 <desc>
5628 Flag whether the pointer is visible.
5629 </desc>
5630 </param>
5631 <param name="alpha" type="boolean" dir="in">
5632 <desc>
5633 Flag whether the pointer has an alpha channel.
5634 </desc>
5635 </param>
5636 <param name="xHot" type="unsigned long" dir="in">
5637 <desc>
5638 The pointer hot spot x coordinate.
5639 </desc>
5640 </param>
5641 <param name="yHot" type="unsigned long" dir="in">
5642 <desc>
5643 The pointer hot spot y coordinate.
5644 </desc>
5645 </param>
5646 <param name="width" type="unsigned long" dir="in">
5647 <desc>
5648 Width of the pointer shape in pixels.
5649 </desc>
5650 </param>
5651 <param name="height" type="unsigned long" dir="in">
5652 <desc>
5653 Height of the pointer shape in pixels.
5654 </desc>
5655 </param>
5656 <param name="shape" type="octet" mod="ptr" dir="in">
5657 <desc>
5658 Address of the shape buffer.
5659
5660 The @a shape buffer contains a 1-bpp (bits per pixel) AND mask
5661 followed by a 32-bpp XOR (color) mask.
5662
5663 For pointers without alpha channel the XOR mask pixels are 32
5664 bit values: (lsb)BGR0(msb). For pointers with alpha channel
5665 the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
5666
5667 An AND mask is used for pointers with alpha channel, so if the
5668 callback does not support alpha, the pointer could be
5669 displayed as a normal color pointer.
5670
5671 The AND mask is a 1-bpp bitmap with byte aligned scanlines. The
5672 size of the AND mask therefore is <tt>cbAnd = (width + 7) / 8 *
5673 height</tt>. The padding bits at the end of each scanline are
5674 undefined.
5675
5676 The XOR mask follows the AND mask on the next 4-byte aligned
5677 offset: <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>.
5678 Bytes in the gap between the AND and the XOR mask are undefined.
5679 The XOR mask scanlines have no gap between them and the size of
5680 the XOR mask is: <tt>cXor = width * 4 * height</tt>.
5681
5682 <note>
5683 If @a shape is 0, only the pointer visibility is changed.
5684 </note>
5685 </desc>
5686 </param>
5687 </method>
5688
5689 <method name="onMouseCapabilityChange">
5690 <desc>
5691 Notification when the mouse capabilities reported by the
5692 guest have changed. The new capabilities are passed.
5693 </desc>
5694 <param name="supportsAbsolute" type="boolean" dir="in"/>
5695 <param name="needsHostCursor" type="boolean" dir="in"/>
5696 </method>
5697
5698 <method name="onKeyboardLedsChange">
5699 <desc>
5700 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
5701 to alter the state of the keyboard LEDs.
5702 </desc>
5703 <param name="numLock" type="boolean" dir="in"/>
5704 <param name="capsLock" type="boolean" dir="in"/>
5705 <param name="scrollLock" type="boolean" dir="in"/>
5706 </method>
5707
5708 <method name="onStateChange">
5709 <desc>
5710 Notification when the execution state of the machine has changed.
5711 The new state will be given.
5712 </desc>
5713 <param name="state" type="MachineState" dir="in"/>
5714 </method>
5715
5716 <method name="onAdditionsStateChange">
5717 <desc>
5718 Notification when a Guest Additions property changes.
5719 Interested callees should query IGuest attributes to
5720 find out what has changed.
5721 </desc>
5722 </method>
5723
5724 <method name="onDVDDriveChange">
5725 <desc>
5726 Notification when a property of the
5727 virtual <link to="IMachine::DVDDrive">DVD drive</link> changes.
5728 Interested callees should use IDVDDrive methods to find out what has
5729 changed.
5730 </desc>
5731 </method>
5732
5733 <method name="onFloppyDriveChange">
5734 <desc>
5735 Notification when a property of the
5736 virtual <link to="IMachine::floppyDrive">floppy drive</link> changes.
5737 Interested callees should use IFloppyDrive methods to find out what
5738 has changed.
5739 </desc>
5740 </method>
5741
5742 <method name="onNetworkAdapterChange">
5743 <desc>
5744 Notification when a property of one of the
5745 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
5746 changes. Interested callees should use INetworkAdapter methods and
5747 attributes to find out what has changed.
5748 </desc>
5749 <param name="networkAdapter" type="INetworkAdapter" dir="in">
5750 <desc>Network adapter that is subject to change.</desc>
5751 </param>
5752 </method>
5753
5754 <method name="onSerialPortChange">
5755 <desc>
5756 Notification when a property of one of the
5757 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
5758 Interested callees should use ISerialPort methods and attributes
5759 to find out what has changed.
5760 </desc>
5761 <param name="serialPort" type="ISerialPort" dir="in">
5762 <desc>Serial port that is subject to change.</desc>
5763 </param>
5764 </method>
5765
5766 <method name="onParallelPortChange">
5767 <desc>
5768 Notification when a property of one of the
5769 virtual <link to="IMachine::getParallelPort">parallel ports</link>
5770 changes. Interested callees should use ISerialPort methods and
5771 attributes to find out what has changed.
5772 </desc>
5773 <param name="parallelPort" type="IParallelPort" dir="in">
5774 <desc>Parallel port that is subject to change.</desc>
5775 </param>
5776 </method>
5777
5778 <method name="onStorageControllerChange">
5779 <desc>
5780 Notification when a property of one of the
5781 virtual <link to="IMachine::storageControllers">storage controllers</link>
5782 changes. Interested callees should query the corresponding collections
5783 to find out what has changed.
5784 </desc>
5785 </method>
5786
5787 <method name="onVRDPServerChange">
5788 <desc>
5789 Notification when a property of the
5790 <link to="IMachine::VRDPServer">VRDP server</link> changes.
5791 Interested callees should use IVRDPServer methods and attributes to
5792 find out what has changed.
5793 </desc>
5794 </method>
5795
5796 <method name="onUSBControllerChange">
5797 <desc>
5798 Notification when a property of the virtual
5799 <link to="IMachine::USBController">USB controller</link> changes.
5800 Interested callees should use IUSBController methods and attributes to
5801 find out what has changed.
5802 </desc>
5803 </method>
5804
5805 <method name="onUSBDeviceStateChange">
5806 <desc>
5807 Notification when a USB device is attached to or detached from
5808 the virtual USB controller.
5809
5810 This notification is sent as a result of the indirect
5811 request to attach the device because it matches one of the
5812 machine USB filters, or as a result of the direct request
5813 issued by <link to="IConsole::attachUSBDevice"/> or
5814 <link to="IConsole::detachUSBDevice"/>.
5815
5816 This notification is sent in case of both a succeeded and a
5817 failed request completion. When the request succeeds, the
5818 @a error parameter is @c null, and the given device has been
5819 already added to (when @a attached is @c true) or removed from
5820 (when @a attached is @c false) the collection represented by
5821 <link to="IConsole::USBDevices"/>. On failure, the collection
5822 doesn't change and the @a error parameter represents the error
5823 message describing the failure.
5824
5825 </desc>
5826 <param name="device" type="IUSBDevice" dir="in">
5827 <desc>Device that is subject to state change.</desc>
5828 </param>
5829 <param name="attached" type="boolean" dir="in">
5830 <desc>
5831 <tt>true</tt> if the device was attached
5832 and <tt>false</tt> otherwise.
5833 </desc>
5834 </param>
5835 <param name="error" type="IVirtualBoxErrorInfo" dir="in">
5836 <desc>
5837 <tt>null</tt> on success or an error message object on
5838 failure.
5839 </desc>
5840 </param>
5841 </method>
5842
5843 <method name="onSharedFolderChange">
5844 <desc>
5845 Notification when a shared folder is added or removed.
5846 The @a scope argument defines one of three scopes:
5847 <link to="IVirtualBox::sharedFolders">global shared folders</link>
5848 (<link to="Scope_Global">Global</link>),
5849 <link to="IMachine::sharedFolders">permanent shared folders</link> of
5850 the machine (<link to="Scope_Machine">Machine</link>) or <link
5851 to="IConsole::sharedFolders">transient shared folders</link> of the
5852 machine (<link to="Scope_Session">Session</link>). Interested callees
5853 should use query the corresponding collections to find out what has
5854 changed.
5855 </desc>
5856 <param name="scope" type="Scope" dir="in">
5857 <desc>Scope of the notification.</desc>
5858 </param>
5859 </method>
5860
5861 <method name="onRuntimeError">
5862 <desc>
5863 Notification when an error happens during the virtual
5864 machine execution.
5865
5866 There are three kinds of runtime errors:
5867 <ul>
5868 <li><i>fatal</i></li>
5869 <li><i>non-fatal with retry</i></li>
5870 <li><i>non-fatal warnings</i></li>
5871 </ul>
5872
5873 <b>Fatal</b> errors are indicated by the @a fatal parameter set
5874 to <tt>true</tt>. In case of fatal errors, the virtual machine
5875 execution is always paused before calling this notification, and
5876 the notification handler is supposed either to immediately save
5877 the virtual machine state using <link to="IConsole::saveState"/>
5878 or power it off using <link to="IConsole::powerDown"/>.
5879 Resuming the execution can lead to unpredictable results.
5880
5881 <b>Non-fatal</b> errors and warnings are indicated by the
5882 @a fatal parameter set to <tt>false</tt>. If the virtual machine
5883 is in the Paused state by the time the error notification is
5884 received, it means that the user can <i>try to resume</i> the machine
5885 execution after attempting to solve the problem that caused the
5886 error. In this case, the notification handler is supposed
5887 to show an appropriate message to the user (depending on the
5888 value of the @a id parameter) that offers several actions such
5889 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
5890 wants to retry, the notification handler should continue
5891 the machine execution using the <link to="IConsole::resume"/>
5892 call. If the machine execution is not Paused during this
5893 notification, then it means this notification is a <i>warning</i>
5894 (for example, about a fatal condition that can happen very soon);
5895 no immediate action is required from the user, the machine
5896 continues its normal execution.
5897
5898 Note that in either case the notification handler
5899 <b>must not</b> perform any action directly on a thread
5900 where this notification is called. Everything it is allowed to
5901 do is to post a message to another thread that will then talk
5902 to the user and take the corresponding action.
5903
5904 Currently, the following error identifiers are known:
5905 <ul>
5906 <li><tt>"HostMemoryLow"</tt></li>
5907 <li><tt>"HostAudioNotResponding"</tt></li>
5908 <li><tt>"VDIStorageFull"</tt></li>
5909 </ul>
5910
5911 <note>
5912 This notification is not designed to be implemented by
5913 more than one callback at a time. If you have multiple
5914 IConsoleCallback instances registered on the given
5915 IConsole object, make sure you simply do nothing but
5916 return @c S_OK from all but one of them that does actual
5917 user notification and performs necessary actions.
5918 </note>
5919
5920 </desc>
5921 <param name="fatal" type="boolean" dir="in">
5922 <desc>Whether the error is fatal or not</desc>
5923 </param>
5924 <param name="id" type="wstring" dir="in">
5925 <desc>Error identifier</desc>
5926 </param>
5927 <param name="message" type="wstring" dir="in">
5928 <desc>Optional error message</desc>
5929 </param>
5930 </method>
5931
5932 <method name="onCanShowWindow">
5933 <desc>
5934 Notification when a call to
5935 <link to="IMachine::canShowConsoleWindow"/> is made by a
5936 front-end to check if a subsequent call to
5937 <link to="IMachine::showConsoleWindow"/> can succeed.
5938
5939 The callee should give an answer appropriate to the current
5940 machine state in the @a canShow argument. This answer must
5941 remain valid at least until the next
5942 <link to="IConsole::state">machine state</link> change.
5943
5944 <note>
5945 This notification is not designed to be implemented by
5946 more than one callback at a time. If you have multiple
5947 IConsoleCallback instances registered on the given
5948 IConsole object, make sure you simply do nothing but
5949 return @c true and @c S_OK from all but one of them that
5950 actually manages console window activation.
5951 </note>
5952 </desc>
5953 <param name="canShow" type="boolean" dir="return">
5954 <desc>
5955 @c true if the console window can be shown and @c
5956 false otherwise.
5957 </desc>
5958 </param>
5959 </method>
5960
5961 <method name="onShowWindow">
5962 <desc>
5963 Notification when a call to
5964 <link to="IMachine::showConsoleWindow"/>
5965 requests the console window to be activated and brought to
5966 foreground on the desktop of the host PC.
5967
5968 This notification should cause the VM console process to
5969 perform the requested action as described above. If it is
5970 impossible to do it at a time of this notification, this
5971 method should return a failure.
5972
5973 Note that many modern window managers on many platforms
5974 implement some sort of focus stealing prevention logic, so
5975 that it may be impossible to activate a window without the
5976 help of the currently active application (which is supposedly
5977 an initiator of this notification). In this case, this method
5978 must return a non-zero identifier that represents the
5979 top-level window of the VM console process. The caller, if it
5980 represents a currently active process, is responsible to use
5981 this identifier (in a platform-dependent manner) to perform
5982 actual window activation.
5983
5984 This method must set @a winId to zero if it has performed all
5985 actions necessary to complete the request and the console
5986 window is now active and in foreground, to indicate that no
5987 further action is required on the caller's side.
5988
5989 <note>
5990 This notification is not designed to be implemented by
5991 more than one callback at a time. If you have multiple
5992 IConsoleCallback instances registered on the given
5993 IConsole object, make sure you simply do nothing but
5994 return @c S_OK from all but one of them that actually
5995 manages console window activation.
5996 </note>
5997 </desc>
5998 <param name="winId" type="unsigned long long" dir="return">
5999 <desc>
6000 Platform-dependent identifier of the top-level VM console
6001 window, or zero if this method has performed all actions
6002 necessary to implement the <i>show window</i> semantics for
6003 the given platform and/or this VirtualBox front-end.
6004 </desc>
6005 </param>
6006 </method>
6007
6008 </interface>
6009
6010 <interface
6011 name="IRemoteDisplayInfo" extends="$unknown"
6012 uuid="550104cd-2dfd-4a6c-857d-f6f8e088e62c"
6013 wsmap="struct"
6014 >
6015 <desc>
6016 Contains information about the remote display (VRDP) capabilities and status.
6017 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
6018 </desc>
6019
6020 <attribute name="active" type="boolean" readonly="yes">
6021 <desc>
6022 Whether the remote display connection is active.
6023 </desc>
6024 </attribute>
6025
6026 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
6027 <desc>
6028 How many times a client connected.
6029 </desc>
6030 </attribute>
6031
6032 <attribute name="beginTime" type="long long" readonly="yes">
6033 <desc>
6034 When the last connection was established, in milliseconds since 1970-01-01 UTC.
6035 </desc>
6036 </attribute>
6037
6038 <attribute name="endTime" type="long long" readonly="yes">
6039 <desc>
6040 When the last connection was terminated or the current time, if
6041 connection is still active, in milliseconds since 1970-01-01 UTC.
6042 </desc>
6043 </attribute>
6044
6045 <attribute name="bytesSent" type="unsigned long long" readonly="yes">
6046 <desc>
6047 How many bytes were sent in last or current, if still active, connection.
6048 </desc>
6049 </attribute>
6050
6051 <attribute name="bytesSentTotal" type="unsigned long long" readonly="yes">
6052 <desc>
6053 How many bytes were sent in all connections.
6054 </desc>
6055 </attribute>
6056
6057 <attribute name="bytesReceived" type="unsigned long long" readonly="yes">
6058 <desc>
6059 How many bytes were received in last or current, if still active, connection.
6060 </desc>
6061 </attribute>
6062
6063 <attribute name="bytesReceivedTotal" type="unsigned long long" readonly="yes">
6064 <desc>
6065 How many bytes were received in all connections.
6066 </desc>
6067 </attribute>
6068
6069 <attribute name="user" type="wstring" readonly="yes">
6070 <desc>
6071 Login user name supplied by the client.
6072 </desc>
6073 </attribute>
6074
6075 <attribute name="domain" type="wstring" readonly="yes">
6076 <desc>
6077 Login domain name supplied by the client.
6078 </desc>
6079 </attribute>
6080
6081 <attribute name="clientName" type="wstring" readonly="yes">
6082 <desc>
6083 The client name supplied by the client.
6084 </desc>
6085 </attribute>
6086
6087 <attribute name="clientIP" type="wstring" readonly="yes">
6088 <desc>
6089 The IP address of the client.
6090 </desc>
6091 </attribute>
6092
6093 <attribute name="clientVersion" type="unsigned long" readonly="yes">
6094 <desc>
6095 The client software version number.
6096 </desc>
6097 </attribute>
6098
6099 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
6100 <desc>
6101 Public key exchange method used when connection was established.
6102 Values: 0 - RDP4 public key exchange scheme.
6103 1 - X509 certificates were sent to client.
6104 </desc>
6105 </attribute>
6106
6107 </interface>
6108
6109 <interface
6110 name="IConsole" extends="$unknown"
6111 uuid="a7f17a42-5b64-488d-977b-4b2c639ada27"
6112 wsmap="managed"
6113 >
6114 <desc>
6115 The IConsole interface represents an interface to control virtual
6116 machine execution.
6117
6118 The console object that implements the IConsole interface is obtained
6119 from a session object after the session for the given machine has been
6120 opened using one of <link to="IVirtualBox::openSession"/>,
6121 <link to="IVirtualBox::openRemoteSession"/> or
6122 <link to="IVirtualBox::openExistingSession"/> methods.
6123
6124 Methods of the IConsole interface allow the caller to query the current
6125 virtual machine execution state, pause the machine or power it down, save
6126 the machine state or take a snapshot, attach and detach removable media
6127 and so on.
6128
6129 <see>ISession</see>
6130 </desc>
6131
6132 <attribute name="machine" type="IMachine" readonly="yes">
6133 <desc>
6134 Machine object this console is sessioned with.
6135 <note>
6136 This is a convenience property, it has the same value as
6137 <link to="ISession::machine"/> of the corresponding session
6138 object.
6139 </note>
6140 </desc>
6141 </attribute>
6142
6143 <attribute name="state" type="MachineState" readonly="yes">
6144 <desc>
6145 Current execution state of the machine.
6146 <note>
6147 This property always returns the same value as the corresponding
6148 property of the IMachine object this console is sessioned with.
6149 For the process that owns (executes) the VM, this is the
6150 preferable way of querying the VM state, because no IPC
6151 calls are made.
6152 </note>
6153 </desc>
6154 </attribute>
6155
6156 <attribute name="guest" type="IGuest" readonly="yes">
6157 <desc>Guest object.</desc>
6158 </attribute>
6159
6160 <attribute name="keyboard" type="IKeyboard" readonly="yes">
6161 <desc>
6162 Virtual keyboard object.
6163 <note>
6164 If the machine is not running, any attempt to use
6165 the returned object will result in an error.
6166 </note>
6167 </desc>
6168 </attribute>
6169
6170 <attribute name="mouse" type="IMouse" readonly="yes">
6171 <desc>
6172 Virtual mouse object.
6173 <note>
6174 If the machine is not running, any attempt to use
6175 the returned object will result in an error.
6176 </note>
6177 </desc>
6178 </attribute>
6179
6180 <attribute name="display" type="IDisplay" readonly="yes">
6181 <desc>Virtual display object.
6182 <note>
6183 If the machine is not running, any attempt to use
6184 the returned object will result in an error.
6185 </note>
6186 </desc>
6187 </attribute>
6188
6189 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
6190 <desc>Debugging interface.</desc>
6191 </attribute>
6192
6193 <attribute name="USBDevices" type="IUSBDevice" readonly="yes" safearray="yes">
6194 <desc>
6195 Collection of USB devices currently attached to the virtual
6196 USB controller.
6197 <note>
6198 The collection is empty if the machine is not running.
6199 </note>
6200 </desc>
6201 </attribute>
6202
6203 <attribute name="remoteUSBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
6204 <desc>
6205 List of USB devices currently attached to the remote VRDP client.
6206 Once a new device is physically attached to the remote host computer,
6207 it appears in this list and remains there until detached.
6208 </desc>
6209 </attribute>
6210
6211 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
6212 <desc>
6213 Collection of shared folders for the current session. These folders
6214 are called transient shared folders because they are available to the
6215 guest OS running inside the associated virtual machine only for the
6216 duration of the session (as opposed to
6217 <link to="IMachine::sharedFolders"/> which represent permanent shared
6218 folders). When the session is closed (e.g. the machine is powered down),
6219 these folders are automatically discarded.
6220
6221 New shared folders are added to the collection using
6222 <link to="#createSharedFolder"/>. Existing shared folders can be
6223 removed using <link to="#removeSharedFolder"/>.
6224 </desc>
6225 </attribute>
6226
6227 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
6228 <desc>
6229 Interface that provides information on Remote Display (VRDP) connection.
6230 </desc>
6231 </attribute>
6232
6233 <method name="powerUp">
6234 <desc>
6235 Starts the virtual machine execution using the current machine
6236 state (that is, its current execution state, current settings and
6237 current hard disks).
6238
6239 If the machine is powered off or aborted, the execution will
6240 start from the beginning (as if the real hardware were just
6241 powered on).
6242
6243 If the machine is in the <link to="MachineState_Saved"/> state,
6244 it will continue its execution the point where the state has
6245 been saved.
6246
6247 <note>
6248 Unless you are trying to write a new VirtualBox front-end that
6249 performs direct machine execution (like the VirtualBox or VBoxSDL
6250 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
6251 session opened by <link to="IVirtualBox::openSession"/> and use this
6252 session only to change virtual machine settings. If you simply want to
6253 start virtual machine execution using one of the existing front-ends
6254 (for example the VirtualBox GUI or headless server), simply use
6255 <link to="IVirtualBox::openRemoteSession"/>; these front-ends will
6256 power up the machine automatically for you.
6257 </note>
6258
6259 <see>#saveState</see>
6260 <result name="VBOX_E_INVALID_VM_STATE">
6261 Virtual machine already running.
6262 </result>
6263 <result name="VBOX_E_HOST_ERROR">
6264 Host interface does not exist or name not set.
6265 </result>
6266 <result name="VBOX_E_FILE_ERROR">
6267 Invalid saved state file.
6268 </result>
6269 </desc>
6270 <param name="progress" type="IProgress" dir="return">
6271 <desc>Progress object to track the operation completion.</desc>
6272 </param>
6273 </method>
6274
6275 <method name="powerUpPaused">
6276 <desc>
6277 Identical to powerUp except that the VM will enter the
6278 <link to="MachineState_Paused"/> state, instead of
6279 <link to="MachineState_Running"/>.
6280
6281 <see>#powerUp</see>
6282 <result name="VBOX_E_INVALID_VM_STATE">
6283 Virtual machine already running.
6284 </result>
6285 <result name="VBOX_E_HOST_ERROR">
6286 Host interface does not exist or name not set.
6287 </result>
6288 <result name="VBOX_E_FILE_ERROR">
6289 Invalid saved state file.
6290 </result>
6291 </desc>
6292 <param name="progress" type="IProgress" dir="return">
6293 <desc>Progress object to track the operation completion.</desc>
6294 </param>
6295 </method>
6296
6297 <method name="powerDown">
6298 <desc>
6299 Stops the virtual machine execution.
6300 After this operation completes, the machine will go to the
6301 PoweredOff state.
6302
6303 @deprecated This method will be removed in VirtualBox 2.1 where the
6304 powerDownAsync() method will take its name. Do not use this method in
6305 the code.
6306 <result name="VBOX_E_INVALID_VM_STATE">
6307 Virtual machine must be Running, Paused or Stuck to be powered down.
6308 </result>
6309 <result name="VBOX_E_VM_ERROR">
6310 Unable to power off or destroy virtual machine.
6311 </result>
6312 </desc>
6313 </method>
6314
6315 <method name="powerDownAsync">
6316 <desc>
6317 Initiates the power down procedure to stop the virtual machine
6318 execution.
6319
6320 The completion of the power down procedure is tracked using the returned
6321 IProgress object. After the operation is complete, the machine will go
6322 to the PoweredOff state.
6323
6324 @warning This method will be renamed to "powerDown" in VirtualBox 2.1
6325 where the original powerDown() method will be removed. You will need to
6326 rename "powerDownAsync" to "powerDown" in your sources to make them
6327 build with version 2.1.
6328 <result name="VBOX_E_INVALID_VM_STATE">
6329 Virtual machine must be Running, Paused or Stuck to be powered down.
6330 </result>
6331 </desc>
6332 <param name="progress" type="IProgress" dir="return">
6333 <desc>Progress object to track the operation completion.</desc>
6334 </param>
6335 </method>
6336
6337 <method name="reset">
6338 <desc>Resets the virtual machine.
6339 <result name="VBOX_E_INVALID_VM_STATE">
6340 Virtual machine not in Running state.
6341 </result>
6342 <result name="VBOX_E_VM_ERROR">
6343 Virtual machine error in reset operation.
6344 </result>
6345 </desc>
6346 </method>
6347
6348 <method name="pause">
6349 <desc>Pauses the virtual machine execution.
6350 <result name="VBOX_E_INVALID_VM_STATE">
6351 Virtual machine not in Running state.
6352 </result>
6353 <result name="VBOX_E_VM_ERROR">
6354 Virtual machine error in suspend operation.
6355 </result>
6356 </desc>
6357 </method>
6358
6359 <method name="resume">
6360 <desc>Resumes the virtual machine execution.
6361 <result name="VBOX_E_INVALID_VM_STATE">
6362 Virtual machine not in Paused state.
6363 </result>
6364 <result name="VBOX_E_VM_ERROR">
6365 Virtual machine error in resume operation.
6366 </result>
6367 </desc>
6368 </method>
6369
6370 <method name="powerButton">
6371 <desc>Sends the ACPI power button event to the guest.
6372 <result name="VBOX_E_INVALID_VM_STATE">
6373 Virtual machine not in Running state.
6374 </result>
6375 <result name="VBOX_E_PDM_ERROR">
6376 Controlled power off failed.
6377 </result>
6378 </desc>
6379 </method>
6380
6381 <method name="sleepButton">
6382 <desc>Sends the ACPI sleep button event to the guest.
6383 <result name="VBOX_E_INVALID_VM_STATE">
6384 Virtual machine not in Running state.
6385 </result>
6386 <result name="VBOX_E_PDM_ERROR">
6387 Sending sleep button event failed.
6388 </result>
6389 </desc>
6390 </method>
6391
6392 <method name="getPowerButtonHandled">
6393 <desc>Checks if the last power button event was handled by guest.
6394 <result name="VBOX_E_PDM_ERROR">
6395 Checking if the event was handled by the guest OS failed.
6396 </result>
6397 </desc>
6398 <param name="handled" type="boolean" dir="return"/>
6399 </method>
6400
6401 <method name="getGuestEnteredACPIMode">
6402 <desc>Checks if the guest entered the ACPI mode G0 (working) or
6403 G1 (sleeping). If this method returns false, the guest will
6404 most likely not respond to external ACPI events.
6405 <result name="VBOX_E_INVALID_VM_STATE">
6406 Virtual machine not in Running state.
6407 </result>
6408 </desc>
6409 <param name="entered" type="boolean" dir="return"/>
6410 </method>
6411
6412 <method name="saveState">
6413 <desc>
6414 Saves the current execution state of a running virtual machine
6415 and stops its execution.
6416
6417 After this operation completes, the machine will go to the
6418 Saved state. Next time it is powered up, this state will
6419 be restored and the machine will continue its execution from
6420 the place where it was saved.
6421
6422 This operation differs from taking a snapshot to the effect
6423 that it doesn't create new differencing hard disks. Also, once
6424 the machine is powered up from the state saved using this method,
6425 the saved state is deleted, so it will be impossible to return
6426 to this state later.
6427
6428 <note>
6429 On success, this method implicitly calls
6430 <link to="IMachine::saveSettings"/> to save all current machine
6431 settings (including runtime changes to the DVD drive, etc.).
6432 Together with the impossibility to change any VM settings when it is
6433 in the Saved state, this guarantees adequate hardware
6434 configuration of the machine when it is restored from the saved
6435 state file.
6436 </note>
6437
6438 <note>
6439 The machine must be in the Running or Paused state, otherwise
6440 the operation will fail.
6441 </note>
6442 <result name="VBOX_E_INVALID_VM_STATE">
6443 Virtual machine state neither Running nor Paused.
6444 </result>
6445 <result name="VBOX_E_FILE_ERROR">
6446 Failed to create directory for saved state file.
6447 </result>
6448
6449 <see><link to="#takeSnapshot"/></see>
6450 </desc>
6451 <param name="progress" type="IProgress" dir="return">
6452 <desc>Progress object to track the operation completion.</desc>
6453 </param>
6454 </method>
6455
6456 <method name="adoptSavedState">
6457 <desc>
6458 Associates the given saved state file to the virtual machine.
6459
6460 On success, the machine will go to the Saved state. Next time it is
6461 powered up, it will be restored from the adopted saved state and
6462 continue execution from the place where the saved state file was
6463 created.
6464
6465 The specified saved state file path may be absolute or relative to the
6466 folder the VM normally saves the state to (usually,
6467 <link to="IMachine::snapshotFolder"/>).
6468
6469 <note>
6470 It's a caller's responsibility to make sure the given saved state
6471 file is compatible with the settings of this virtual machine that
6472 represent its virtual hardware (memory size, hard disk configuration
6473 etc.). If there is a mismatch, the behavior of the virtual machine
6474 is undefined.
6475 </note>
6476 <result name="VBOX_E_INVALID_VM_STATE">
6477 Virtual machine state neither PoweredOff nor Aborted.
6478 </result>
6479 </desc>
6480 <param name="savedStateFile" type="wstring" dir="in">
6481 <desc>Path to the saved state file to adopt.</desc>
6482 </param>
6483 </method>
6484
6485 <method name="discardSavedState">
6486 <desc>
6487 Discards (deletes) the saved state of the virtual machine
6488 previously created by <link to="#saveState"/>. Next time the
6489 machine is powered up, a clean boot will occur.
6490 <note>
6491 This operation is equivalent to resetting or powering off
6492 the machine without doing a proper shutdown in the guest OS.
6493 </note>
6494 <result name="VBOX_E_INVALID_VM_STATE">
6495 Virtual machine not in state Saved.
6496 </result>
6497 </desc>
6498 </method>
6499
6500 <method name="getDeviceActivity">
6501 <desc>
6502 Gets the current activity type of a given device or device group.
6503 <result name="E_INVALIDARG">
6504 Invalid device type.
6505 </result>
6506 </desc>
6507 <param name="type" type="DeviceType" dir="in"/>
6508 <param name="activity" type="DeviceActivity" dir="return"/>
6509 </method>
6510
6511 <method name="attachUSBDevice">
6512 <desc>
6513 Attaches a host USB device with the given UUID to the
6514 USB controller of the virtual machine.
6515
6516 The device needs to be in one of the following states:
6517 <link to="USBDeviceState_Busy"/>,
6518 <link to="USBDeviceState_Available"/> or
6519 <link to="USBDeviceState_Held"/>,
6520 otherwise an error is immediately returned.
6521
6522 When the device state is
6523 <link to="USBDeviceState_Busy">Busy</link>, an error may also
6524 be returned if the host computer refuses to release it for some reason.
6525
6526 <see>IUSBController::deviceFilters, USBDeviceState</see>
6527 <result name="VBOX_E_INVALID_VM_STATE">
6528 Virtual machine state neither Running nor Paused.
6529 </result>
6530 <result name="VBOX_E_PDM_ERROR">
6531 Virtual machine does not have a USB controller.
6532 </result>
6533 </desc>
6534 <param name="id" type="wstring" dir="in">
6535 <desc>UUID of the host USB device to attach.</desc>
6536 </param>
6537 </method>
6538
6539 <method name="detachUSBDevice">
6540 <desc>
6541 Detaches an USB device with the given UUID from the USB controller
6542 of the virtual machine.
6543
6544 After this method succeeds, the VirtualBox server re-initiates
6545 all USB filters as if the device were just physically attached
6546 to the host, but filters of this machine are ignored to avoid
6547 a possible automatic re-attachment.
6548
6549 <see>IUSBController::deviceFilters, USBDeviceState</see>
6550
6551 <result name="VBOX_E_PDM_ERROR">
6552 Virtual machine does not have a USB controller.
6553 </result>
6554 <result name="E_INVALIDARG">
6555 USB device not attached to this virtual machine.
6556 </result>
6557 </desc>
6558 <param name="id" type="wstring" dir="in">
6559 <desc>UUID of the USB device to detach.</desc>
6560 </param>
6561 <param name="device" type="IUSBDevice" dir="return">
6562 <desc>Detached USB device.</desc>
6563 </param>
6564 </method>
6565
6566 <method name="findUSBDeviceByAddress">
6567 <desc>
6568 Searches for a USB device with the given host address.
6569
6570 <result name="VBOX_E_OBJECT_NOT_FOUND">
6571 Given @c name does not correspond to any USB device.
6572 </result>
6573
6574 <see>IUSBDevice::address</see>
6575 </desc>
6576 <param name="name" type="wstring" dir="in">
6577 <desc>
6578 Address of the USB device (as assigned by the host) to
6579 search for.
6580 </desc>
6581 </param>
6582 <param name="device" type="IUSBDevice" dir="return">
6583 <desc>Found USB device object.</desc>
6584 </param>
6585 </method>
6586
6587 <method name="findUSBDeviceById">
6588 <desc>
6589 Searches for a USB device with the given UUID.
6590
6591 <result name="VBOX_E_OBJECT_NOT_FOUND">
6592 Given @c id does not correspond to any USB device.
6593 </result>
6594
6595 <see>IUSBDevice::id</see>
6596 </desc>
6597 <param name="id" type="wstring" dir="in">
6598 <desc>UUID of the USB device to search for.</desc>
6599 </param>
6600 <param name="device" type="IUSBDevice" dir="return">
6601 <desc>Found USB device object.</desc>
6602 </param>
6603 </method>
6604
6605 <method name="createSharedFolder">
6606 <desc>
6607 Creates a transient new shared folder by associating the given logical
6608 name with the given host path, adds it to the collection of shared
6609 folders and starts sharing it. Refer to the description of
6610 <link to="ISharedFolder"/> to read more about logical names.
6611
6612 <result name="VBOX_E_INVALID_VM_STATE">
6613 Virtual machine in Saved state or currently changing state.
6614 </result>
6615 <result name="VBOX_E_FILE_ERROR">
6616 Shared folder already exists or not accessible.
6617 </result>
6618 </desc>
6619 <param name="name" type="wstring" dir="in">
6620 <desc>Unique logical name of the shared folder.</desc>
6621 </param>
6622 <param name="hostPath" type="wstring" dir="in">
6623 <desc>Full path to the shared folder in the host file system.</desc>
6624 </param>
6625 <param name="writable" type="boolean" dir="in">
6626 <desc>Whether the share is writable or readonly</desc>
6627 </param>
6628 </method>
6629
6630 <method name="removeSharedFolder">
6631 <desc>
6632 Removes a transient shared folder with the given name previously
6633 created by <link to="#createSharedFolder"/> from the collection of
6634 shared folders and stops sharing it.
6635 <result name="VBOX_E_INVALID_VM_STATE">
6636 Virtual machine in Saved state or currently changing state.
6637 </result>
6638 <result name="VBOX_E_FILE_ERROR">
6639 Shared folder does not exists.
6640 </result>
6641 </desc>
6642 <param name="name" type="wstring" dir="in">
6643 <desc>Logical name of the shared folder to remove.</desc>
6644 </param>
6645 </method>
6646
6647 <method name="takeSnapshot">
6648 <desc>
6649 Saves the current execution state and all settings of the
6650 machine and creates differencing images for all
6651 normal (non-independent) hard disks.
6652
6653 This method can be called for a PoweredOff, Saved, Running or
6654 Paused virtual machine. When the machine is PoweredOff, an
6655 offline <link to="ISnapshot">snapshot</link> is created,
6656 in all other cases -- an online snapshot.
6657
6658 The taken snapshot is always based on the
6659 <link to="IMachine::currentSnapshot">current
6660 snapshot</link> of the associated virtual machine and becomes
6661 a new current snapshot.
6662
6663 <note>
6664 This method implicitly calls <link to="IMachine::saveSettings"/> to
6665 save all current machine settings before taking an offline snapshot.
6666 </note>
6667
6668 <see>ISnapshot, <link to="#saveState"/></see>
6669 <result name="VBOX_E_INVALID_VM_STATE">
6670 Virtual machine currently changing state.
6671 </result>
6672 </desc>
6673 <param name="name" type="wstring" dir="in">
6674 <desc>Short name for the snapshot.</desc>
6675 </param>
6676 <param name="description" type="wstring" dir="in">
6677 <desc>Optional description of the snapshot.</desc>
6678 </param>
6679 <param name="progress" type="IProgress" dir="return">
6680 <desc>Progress object to track the operation completion.</desc>
6681 </param>
6682 </method>
6683
6684 <method name="discardSnapshot">
6685 <desc>
6686
6687 Starts discarding the specified snapshot. The execution state
6688 and settings of the associated machine stored in the snapshot
6689 will be deleted. The contents of all differencing hard disks of
6690 this snapshot will be merged with the contents of their
6691 dependent child hard disks to keep the, disks valid (in other
6692 words, all changes represented by hard disks being discarded
6693 will be propagated to their child hard disks). After that, this
6694 snapshot's differencing hard disks will be deleted. The parent
6695 of this snapshot will become a new parent for all its child
6696 snapshots.
6697
6698 If the discarded snapshot is the current one, its parent
6699 snapshot will become a new current snapshot. The current machine
6700 state is not directly affected in this case, except that
6701 currently attached differencing hard disks based on hard disks
6702 of the discarded snapshot will be also merged as described
6703 above.
6704
6705 If the discarded snapshot is the first one (the root snapshot)
6706 and it has exactly one child snapshot, this child snapshot will
6707 become the first snapshot after discarding. If there are no
6708 children at all (i.e. the first snapshot is the only snapshot of
6709 the machine), both the current and the first snapshot of the
6710 machine will be set to null. In all other cases, the first
6711 snapshot cannot be discarded.
6712
6713 You cannot discard the snapshot if it
6714 stores <link to="HardDiskType_Normal">normal</link> (non-differencing)
6715 hard disks that have differencing hard disks based on them. Snapshots of
6716 such kind can be discarded only when every normal hard disk has either
6717 no children at all or exactly one child. In the former case, the normal
6718 hard disk simply becomes unused (i.e. not attached to any VM). In the
6719 latter case, it receives all the changes stored in the child hard disk,
6720 and then it replaces the child hard disk in the configuration of the
6721 corresponding snapshot or machine.
6722
6723 Also, you cannot discard the snapshot if it stores hard disks
6724 (of any type) having differencing child hard disks that belong
6725 to other machines. Such snapshots can be only discarded after
6726 you discard all snapshots of other machines containing "foreign"
6727 child disks, or detach these "foreign" child disks from machines
6728 they are attached to.
6729
6730 One particular example of the snapshot storing normal hard disks
6731 is the first snapshot of a virtual machine that had normal hard
6732 disks attached when taking the snapshot. Be careful when
6733 discarding such snapshots because this implicitly commits
6734 changes (made since the snapshot being discarded has been taken)
6735 to normal hard disks (as described above), which may be not what
6736 you want.
6737
6738 The virtual machine is put to
6739 the <link to="MachineState_Discarding">Discarding</link> state until
6740 the discard operation is completed.
6741
6742 <note>
6743 The machine must not be running, otherwise the operation
6744 will fail.
6745 </note>
6746
6747 <note>
6748 Child hard disks of all normal hard disks of the discarded snapshot
6749 must be accessible (see <link to="IMedium::state"/>) for this
6750 operation to succeed. In particular, this means that all virtual
6751 machines, whose hard disks are directly or indirectly based on the
6752 hard disks of discarded snapshot, must be powered off.
6753 </note>
6754 <note>
6755 Merging hard disk contents can be very time and disk space
6756 consuming, if these disks are big in size and have many
6757 children. However, if the snapshot being discarded is the last
6758 (head) snapshot on the branch, the operation will be rather
6759 quick.
6760 </note>
6761 <note>
6762 Note that discarding the current snapshot
6763 will implicitly call <link to="IMachine::saveSettings"/> to
6764 make all current machine settings permanent.
6765 </note>
6766 <result name="VBOX_E_INVALID_VM_STATE">
6767 Virtual machine is running.
6768 </result>
6769 </desc>
6770 <param name="id" type="wstring" dir="in">
6771 <desc>UUID of the snapshot to discard.</desc>
6772 </param>
6773 <param name="progress" type="IProgress" dir="return">
6774 <desc>Progress object to track the operation completion.</desc>
6775 </param>
6776 </method>
6777
6778 <method name="discardCurrentState">
6779 <desc>
6780 This operation is similar to <link to="IConsole::discardSnapshot"/> but
6781 affects the current machine state. This means that the state stored in
6782 the current snapshot will become a new current state, and all current
6783 settings of the machine and changes stored in differencing hard disks
6784 will be lost.
6785
6786 After this operation is successfully completed, new empty differencing
6787 hard disks are created for all normal hard disks of the machine.
6788
6789 If the current snapshot of the machine is an online snapshot, the
6790 machine will go to the <link to="MachineState_Saved"> saved
6791 state</link>, so that the next time it is powered on, the execution
6792 state will be restored from the current snapshot.
6793
6794 <note>
6795 The machine must not be running, otherwise the operation will fail.
6796 </note>
6797
6798 <note>
6799 If the machine state is <link to="MachineState_Saved">Saved</link>
6800 prior to this operation, the saved state file will be implicitly
6801 discarded (as if <link to="IConsole::discardSavedState"/> were
6802 called).
6803 </note>
6804
6805 <result name="VBOX_E_INVALID_VM_STATE">
6806 Virtual machine is running.
6807 </result>
6808 </desc>
6809 <param name="progress" type="IProgress" dir="return">
6810 <desc>Progress object to track the operation completion.</desc>
6811 </param>
6812 </method>
6813
6814 <method name="discardCurrentSnapshotAndState">
6815 <desc>
6816
6817 This method is equivalent to
6818 doing <link to="IConsole::discardSnapshot">discardSnapshot</link>
6819 (currentSnapshot.id(), progress) followed by
6820 <link to="IConsole::discardCurrentState"/>.
6821
6822 As a result, the machine will be fully restored from the
6823 snapshot preceding the current snapshot, while both the current
6824 snapshot and the current machine state will be discarded.
6825
6826 If the current snapshot is the first snapshot of the machine (i.e. it
6827 has the only snapshot), the current machine state will be
6828 discarded <b>before</b> discarding the snapshot. In other words, the
6829 machine will be restored from its last snapshot, before discarding
6830 it. This differs from performing a single
6831 <link to="IConsole::discardSnapshot"/> call (note that no
6832 <link to="IConsole::discardCurrentState"/> will be possible after it)
6833 to the effect that the latter will preserve the current state instead of
6834 discarding it.
6835
6836 Unless explicitly mentioned otherwise, all remarks and
6837 limitations of the above two methods also apply to this method.
6838
6839 <note>
6840 The machine must not be running, otherwise the operation
6841 will fail.
6842 </note>
6843
6844 <note>
6845 If the machine state is <link to="MachineState_Saved">Saved</link>
6846 prior to this operation, the saved state file will be implicitly
6847 discarded (as if <link to="#discardSavedState"/> were
6848 called).
6849 </note>
6850
6851 <note>
6852 This method is more efficient than calling both of the above
6853 methods separately: it requires less IPC calls and provides
6854 a single progress object.
6855 </note>
6856
6857 <result name="VBOX_E_INVALID_VM_STATE">
6858 Virtual machine is running.
6859 </result>
6860 </desc>
6861 <param name="progress" type="IProgress" dir="return">
6862 <desc>Progress object to track the operation completion.</desc>
6863 </param>
6864 </method>
6865
6866 <method name="registerCallback">
6867 <desc>
6868 Registers a new console callback on this instance. The methods of the
6869 callback interface will be called by this instance when the appropriate
6870 event occurs.
6871 </desc>
6872 <param name="callback" type="IConsoleCallback" dir="in"/>
6873 </method>
6874
6875 <method name="unregisterCallback">
6876 <desc>
6877 Unregisters the console callback previously registered using
6878 <link to="#registerCallback"/>.
6879 <result name="E_INVALIDARG">
6880 Given @a callback handler is not registered.
6881 </result>
6882 </desc>
6883 <param name="callback" type="IConsoleCallback" dir="in"/>
6884 </method>
6885 </interface>
6886
6887 <!--
6888 // IHost
6889 /////////////////////////////////////////////////////////////////////////
6890 -->
6891
6892 <interface
6893 name="IHostDVDDrive" extends="$unknown"
6894 uuid="21f86694-202d-4ce4-8b05-a63ff82dbf4c"
6895 wsmap="managed"
6896 >
6897 <desc>
6898 The IHostDVDDrive interface represents the physical CD/DVD drive
6899 hardware on the host. Used indirectly in <link to="IHost::DVDDrives"/>.
6900 </desc>
6901
6902 <attribute name="name" type="wstring" readonly="yes">
6903 <desc>
6904 Returns the platform-specific device identifier.
6905 On DOS-like platforms, it is a drive name (e.g. R:).
6906 On Unix-like platforms, it is a device name (e.g. /dev/hdc).
6907 </desc>
6908 </attribute>
6909 <attribute name="description" type="wstring" readonly="yes">
6910 <desc>
6911 Returns a human readable description for the drive. This
6912 description usually contains the product and vendor name. A
6913 @c null string is returned if the description is not available.
6914 </desc>
6915 </attribute>
6916 <attribute name="udi" type="wstring" readonly="yes">
6917 <desc>
6918 Returns the unique device identifier for the drive. This
6919 attribute is reserved for future use instead of
6920 <link to="#name"/>. Currently it is not used and may return
6921 @c null on some platforms.
6922 </desc>
6923 </attribute>
6924
6925 </interface>
6926
6927 <interface
6928 name="IHostFloppyDrive" extends="$unknown"
6929 uuid="3f02d604-e908-4919-9fd1-8a4afd68fc63"
6930 wsmap="managed"
6931 >
6932 <desc>
6933 The IHostFloppyDrive interface represents the physical floppy drive
6934 hardware on the host. Used indirectly in <link to="IHost::floppyDrives"/>.
6935 </desc>
6936 <attribute name="name" type="wstring" readonly="yes">
6937 <desc>
6938 Returns the platform-specific device identifier.
6939 On DOS-like platforms, it is a drive name (e.g. A:).
6940 On Unix-like platforms, it is a device name (e.g. /dev/fd0).
6941 </desc>
6942 </attribute>
6943 <attribute name="description" type="wstring" readonly="yes">
6944 <desc>
6945 Returns a human readable description for the drive. This
6946 description usually contains the product and vendor name. A
6947 @c null string is returned if the description is not available.
6948 </desc>
6949 </attribute>
6950 <attribute name="udi" type="wstring" readonly="yes">
6951 <desc>
6952 Returns the unique device identifier for the drive. This
6953 attribute is reserved for future use instead of
6954 <link to="#name"/>. Currently it is not used and may return
6955 @c null on some platforms.
6956 </desc>
6957 </attribute>
6958 </interface>
6959
6960 <enum
6961 name="HostNetworkInterfaceMediumType"
6962 uuid="1aa54aaf-2497-45a2-bfb1-8eb225e93d5b"
6963 >
6964 <desc>
6965 Type of encapsulation. Ethernet encapsulation includes both wired and
6966 wireless Ethernet connections.
6967 <see>IHostNetworkInterface</see>
6968 </desc>
6969
6970 <const name="Unknown" value="0">
6971 <desc>
6972 The type of interface cannot be determined.
6973 </desc>
6974 </const>
6975 <const name="Ethernet" value="1">
6976 <desc>
6977 Ethernet frame encapsulation.
6978 </desc>
6979 </const>
6980 <const name="PPP" value="2">
6981 <desc>
6982 Point-to-point protocol encapsulation.
6983 </desc>
6984 </const>
6985 <const name="SLIP" value="3">
6986 <desc>
6987 Serial line IP encapsulation.
6988 </desc>
6989 </const>
6990 </enum>
6991
6992 <enum
6993 name="HostNetworkInterfaceStatus"
6994 uuid="CC474A69-2710-434B-8D99-C38E5D5A6F41"
6995 >
6996 <desc>
6997 Current status of the interface.
6998 <see>IHostNetworkInterface</see>
6999 </desc>
7000
7001 <const name="Unknown" value="0">
7002 <desc>
7003 The state of interface cannot be determined.
7004 </desc>
7005 </const>
7006 <const name="Up" value="1">
7007 <desc>
7008 The interface is fully operational.
7009 </desc>
7010 </const>
7011 <const name="Down" value="2">
7012 <desc>
7013 The interface is not functioning.
7014 </desc>
7015 </const>
7016 </enum>
7017
7018 <enum
7019 name="HostNetworkInterfaceType"
7020 uuid="67431b00-9946-48a2-bc02-b25c5919f4f3"
7021 >
7022 <desc>
7023 Network interface type.
7024 </desc>
7025 <const name="Bridged" value="1"/>
7026 <const name="HostOnly" value="2"/>
7027 </enum>
7028
7029 <interface
7030 name="IHostNetworkInterface" extends="$unknown"
7031 uuid="ce6fae58-7642-4102-b5db-c9005c2320a8"
7032 wsmap="managed"
7033 >
7034 <desc>
7035 Represents one of host's network interfaces. IP V6 address and network
7036 mask are strings of 32 hexdecimal digits grouped by four. Groups are
7037 separated by colons.
7038 For example, fe80:0000:0000:0000:021e:c2ff:fed2:b030.
7039 </desc>
7040 <attribute name="name" type="wstring" readonly="yes">
7041 <desc>Returns the host network interface name.</desc>
7042 </attribute>
7043
7044 <attribute name="id" type="wstring" readonly="yes">
7045 <desc>Returns the interface UUID.</desc>
7046 </attribute>
7047
7048 <attribute name="networkName" type="wstring" readonly="yes">
7049 <desc>Returns the name of a virtual network the interface gets attached to.</desc>
7050 </attribute>
7051
7052 <attribute name="dhcpEnabled" type="boolean" readonly="yes">
7053 <desc>Specifies whether the DHCP is enabled for the interface.</desc>
7054 </attribute>
7055
7056 <attribute name="IPAddress" type="wstring" readonly="yes">
7057 <desc>Returns the IP V4 address of the interface.</desc>
7058 </attribute>
7059
7060 <attribute name="networkMask" type="wstring" readonly="yes">
7061 <desc>Returns the network mask of the interface.</desc>
7062 </attribute>
7063
7064 <attribute name="IPV6Supported" type="boolean" readonly="yes">
7065 <desc>Specifies whether the IP V6 is supported/enabled for the interface.</desc>
7066 </attribute>
7067
7068 <attribute name="IPV6Address" type="wstring" readonly="yes">
7069 <desc>Returns the IP V6 address of the interface.</desc>
7070 </attribute>
7071
7072 <attribute name="IPV6NetworkMaskPrefixLength" type="unsigned long" readonly="yes">
7073 <desc>Returns the length IP V6 network mask prefix of the interface.</desc>
7074 </attribute>
7075
7076 <attribute name="hardwareAddress" type="wstring" readonly="yes">
7077 <desc>Returns the hardware address. For Ethernet it is MAC address.</desc>
7078 </attribute>
7079
7080 <attribute name="mediumType" type="HostNetworkInterfaceMediumType" readonly="yes">
7081 <desc>Type of protocol encapsulation used.</desc>
7082 </attribute>
7083
7084 <attribute name="status" type="HostNetworkInterfaceStatus" readonly="yes">
7085 <desc>Status of the interface.</desc>
7086 </attribute>
7087
7088 <attribute name="interfaceType" type="HostNetworkInterfaceType" readonly="yes">
7089 <desc>specifies the host interface type.</desc>
7090 </attribute>
7091
7092 <method name="enableStaticIpConfig">
7093 <desc>sets and enables the static IP V4 configuration for the given interface.</desc>
7094 <param name="IPAddress" type="wstring" dir="in">
7095 <desc>
7096 IP address.
7097 </desc>
7098 </param>
7099 <param name="networkMask" type="wstring" dir="in">
7100 <desc>
7101 network mask.
7102 </desc>
7103 </param>
7104 </method>
7105
7106 <method name="enableStaticIpConfigV6">
7107 <desc>sets and enables the static IP V6 configuration for the given interface.</desc>
7108 <param name="IPV6Address" type="wstring" dir="in">
7109 <desc>
7110 IP address.
7111 </desc>
7112 </param>
7113 <param name="IPV6NetworkMaskPrefixLength" type="unsigned long" dir="in">
7114 <desc>
7115 network mask.
7116 </desc>
7117 </param>
7118 </method>
7119
7120 <method name="enableDynamicIpConfig">
7121 <desc>enables the dynamic IP configuration.</desc>
7122 </method>
7123
7124 <method name="dhcpRediscover">
7125 <desc>refreshes the IP configuration for dhcp-enabled interface.</desc>
7126 </method>
7127
7128 </interface>
7129
7130 <interface
7131 name="IHost" extends="$unknown"
7132 uuid="a13b5556-5c0b-4f80-9df6-6f804f3336a1"
7133 wsmap="managed"
7134 >
7135 <desc>
7136 The IHost interface represents the physical machine that this VirtualBox
7137 installation runs on.
7138
7139 An object implementing this interface is returned by the
7140 <link to="IVirtualBox::host" /> attribute. This interface contains
7141 read-only information about the host's physical hardware (such as what
7142 processors and disks are available, what the host operating system is,
7143 and so on) and also allows for manipulating some of the host's hardware,
7144 such as global USB device filters and host interface networking.
7145
7146 </desc>
7147 <attribute name="DVDDrives" type="IHostDVDDrive" readonly="yes" safearray="yes">
7148 <desc>List of DVD drives available on the host.</desc>
7149 </attribute>
7150
7151 <attribute name="floppyDrives" type="IHostFloppyDrive" readonly="yes" safearray="yes">
7152 <desc>List of floppy drives available on the host.</desc>
7153 </attribute>
7154
7155 <attribute name="USBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
7156 <desc>
7157 List of USB devices currently attached to the host.
7158 Once a new device is physically attached to the host computer,
7159 it appears in this list and remains there until detached.
7160
7161 <note>
7162 If USB functionality is not available in the given edition of
7163 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7164 </note>
7165 </desc>
7166 </attribute>
7167
7168 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilter" readonly="yes" safearray="yes">
7169 <desc>
7170 List of USB device filters in action.
7171 When a new device is physically attached to the host computer,
7172 filters from this list are applied to it (in order they are stored
7173 in the list). The first matched filter will determine the
7174 <link to="IHostUSBDeviceFilter::action">action</link>
7175 performed on the device.
7176
7177 Unless the device is ignored by these filters, filters of all
7178 currently running virtual machines
7179 (<link to="IUSBController::deviceFilters"/>) are applied to it.
7180
7181 <note>
7182 If USB functionality is not available in the given edition of
7183 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7184 </note>
7185
7186 <see>IHostUSBDeviceFilter, USBDeviceState</see>
7187 </desc>
7188 </attribute>
7189
7190 <attribute name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" readonly="yes">
7191 <desc>List of host network interfaces currently defined on the host.</desc>
7192 </attribute>
7193
7194 <attribute name="processorCount" type="unsigned long" readonly="yes">
7195 <desc>Number of (logical) CPUs installed in the host system.</desc>
7196 </attribute>
7197
7198 <attribute name="processorOnlineCount" type="unsigned long" readonly="yes">
7199 <desc>Number of (logical) CPUs online in the host system.</desc>
7200 </attribute>
7201
7202 <method name="getProcessorSpeed">
7203 <desc>Query the (approximate) maximum speed of a specified host CPU in
7204 Megahertz.
7205 </desc>
7206 <param name="cpuId" type="unsigned long" dir="in">
7207 <desc>
7208 Identifier of the CPU.
7209 </desc>
7210 </param>
7211 <param name="speed" type="unsigned long" dir="return">
7212 <desc>
7213 Speed value. 0 is returned if value is not known or @a cpuId is
7214 invalid.
7215 </desc>
7216 </param>
7217 </method>
7218
7219 <method name="getProcessorFeature">
7220 <desc>Query whether a CPU feature is supported or not.</desc>
7221 <param name="feature" type="ProcessorFeature" dir="in">
7222 <desc>
7223 CPU Feature identifier.
7224 </desc>
7225 </param>
7226 <param name="supported" type="boolean" dir="return">
7227 <desc>
7228 Feature is supported or not.
7229 </desc>
7230 </param>
7231 </method>
7232
7233 <method name="getProcessorDescription">
7234 <desc>Query the model string of a specified host CPU.
7235 <note>
7236 This function is not implemented in the current version of the
7237 product.
7238 </note>
7239 </desc>
7240 <param name="cpuId" type="unsigned long" dir="in">
7241 <desc>
7242 Identifier of the CPU.
7243 </desc>
7244 </param>
7245 <param name="description" type="wstring" dir="return">
7246 <desc>
7247 Model string. A NULL string is returned if value is not known or
7248 @a cpuId is invalid.
7249 </desc>
7250 </param>
7251 </method>
7252
7253 <attribute name="memorySize" type="unsigned long" readonly="yes">
7254 <desc>Amount of system memory in megabytes installed in the host system.</desc>
7255 </attribute>
7256
7257 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
7258 <desc>Available system memory in the host system.</desc>
7259 </attribute>
7260
7261 <attribute name="operatingSystem" type="wstring" readonly="yes">
7262 <desc>Name of the host system's operating system.</desc>
7263 </attribute>
7264
7265 <attribute name="OSVersion" type="wstring" readonly="yes">
7266 <desc>Host operating system's version string.</desc>
7267 </attribute>
7268
7269 <attribute name="UTCTime" type="long long" readonly="yes">
7270 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
7271 </attribute>
7272
7273 <attribute name="Acceleration3DAvailable" type="boolean" readonly="yes">
7274 <desc>Returns true when the host supports 3D hardware acceleration.</desc>
7275 </attribute>
7276
7277 <method name="createHostOnlyNetworkInterface">
7278 <desc>
7279 Creates a new adapter for Host Only Networking.
7280 <result name="E_INVALIDARG">
7281 Host network interface @a name already exists.
7282 </result>
7283 </desc>
7284 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
7285 <desc>
7286 Created host interface object.
7287 </desc>
7288 </param>
7289 <param name="progress" type="IProgress" dir="return">
7290 <desc>
7291 Progress object to track the operation completion.
7292 </desc>
7293 </param>
7294 </method>
7295
7296 <method name="removeHostOnlyNetworkInterface">
7297 <desc>
7298 Removes the given Host Only Networking interface.
7299 <result name="VBOX_E_OBJECT_NOT_FOUND">
7300 No host network interface matching @a id found.
7301 </result>
7302 </desc>
7303 <param name="id" type="wstring" dir="in">
7304 <desc>
7305 Adapter GUID.
7306 </desc>
7307 </param>
7308 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
7309 <desc>
7310 Removed host interface object.
7311 </desc>
7312 </param>
7313 <param name="progress" type="IProgress" dir="return">
7314 <desc>
7315 Progress object to track the operation completion.
7316 </desc>
7317 </param>
7318 </method>
7319
7320 <method name="createUSBDeviceFilter">
7321 <desc>
7322 Creates a new USB device filter. All attributes except
7323 the filter name are set to <tt>null</tt> (any match),
7324 <i>active</i> is <tt>false</tt> (the filter is not active).
7325
7326 The created filter can be added to the list of filters using
7327 <link to="#insertUSBDeviceFilter"/>.
7328
7329 <see>#USBDeviceFilters</see>
7330 </desc>
7331 <param name="name" type="wstring" dir="in">
7332 <desc>
7333 Filter name. See <link to="IHostUSBDeviceFilter::name"/>
7334 for more info.
7335 </desc>
7336 </param>
7337 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
7338 <desc>Created filter object.</desc>
7339 </param>
7340 </method>
7341
7342 <method name="insertUSBDeviceFilter">
7343 <desc>
7344 Inserts the given USB device to the specified position
7345 in the list of filters.
7346
7347 Positions are numbered starting from <tt>0</tt>. If the specified
7348 position is equal to or greater than the number of elements in
7349 the list, the filter is added at the end of the collection.
7350
7351 <note>
7352 Duplicates are not allowed, so an attempt to insert a
7353 filter already in the list is an error.
7354 </note>
7355 <note>
7356 If USB functionality is not available in the given edition of
7357 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7358 </note>
7359
7360 <see>#USBDeviceFilters</see>
7361
7362 <result name="VBOX_E_INVALID_OBJECT_STATE">
7363 USB device filter is not created within this VirtualBox instance.
7364 </result>
7365 <result name="E_INVALIDARG">
7366 USB device filter already in list.
7367 </result>
7368
7369 </desc>
7370 <param name="position" type="unsigned long" dir="in">
7371 <desc>Position to insert the filter to.</desc>
7372 </param>
7373 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
7374 <desc>USB device filter to insert.</desc>
7375 </param>
7376 </method>
7377
7378 <method name="removeUSBDeviceFilter">
7379 <desc>
7380 Removes a USB device filter from the specified position in the
7381 list of filters.
7382
7383 Positions are numbered starting from <tt>0</tt>. Specifying a
7384 position equal to or greater than the number of elements in
7385 the list will produce an error.
7386
7387 <note>
7388 If USB functionality is not available in the given edition of
7389 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7390 </note>
7391
7392 <see>#USBDeviceFilters</see>
7393
7394 <result name="E_INVALIDARG">
7395 USB device filter list empty or invalid @a position.
7396 </result>
7397
7398 </desc>
7399 <param name="position" type="unsigned long" dir="in">
7400 <desc>Position to remove the filter from.</desc>
7401 </param>
7402 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
7403 <desc>Removed USB device filter.</desc>
7404 </param>
7405 </method>
7406
7407 <method name="findHostDVDDrive">
7408 <desc>
7409 Searches for a host DVD drive with the given @c name.
7410
7411 <result name="VBOX_E_OBJECT_NOT_FOUND">
7412 Given @c name does not correspond to any host drive.
7413 </result>
7414
7415 </desc>
7416 <param name="name" type="wstring" dir="in">
7417 <desc>Name of the host drive to search for</desc>
7418 </param>
7419 <param name="drive" type="IHostDVDDrive" dir="return">
7420 <desc>Found host drive object</desc>
7421 </param>
7422 </method>
7423
7424 <method name="findHostFloppyDrive">
7425 <desc>
7426 Searches for a host floppy drive with the given @c name.
7427
7428 <result name="VBOX_E_OBJECT_NOT_FOUND">
7429 Given @c name does not correspond to any host floppy drive.
7430 </result>
7431
7432 </desc>
7433 <param name="name" type="wstring" dir="in">
7434 <desc>Name of the host floppy drive to search for</desc>
7435 </param>
7436 <param name="drive" type="IHostFloppyDrive" dir="return">
7437 <desc>Found host floppy drive object</desc>
7438 </param>
7439 </method>
7440
7441 <method name="findHostNetworkInterfaceByName">
7442 <desc>
7443 Searches through all host network interfaces for an interface with
7444 the given @c name.
7445 <note>
7446 The method returns an error if the given @c name does not
7447 correspond to any host network interface.
7448 </note>
7449 </desc>
7450 <param name="name" type="wstring" dir="in">
7451 <desc>Name of the host network interface to search for.</desc>
7452 </param>
7453 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7454 <desc>Found host network interface object.</desc>
7455 </param>
7456 </method>
7457 <method name="findHostNetworkInterfaceById">
7458 <desc>
7459 Searches through all host network interfaces for an interface with
7460 the given GUID.
7461 <note>
7462 The method returns an error if the given GUID does not
7463 correspond to any host network interface.
7464 </note>
7465 </desc>
7466 <param name="id" type="wstring" dir="in">
7467 <desc>GUID of the host network interface to search for.</desc>
7468 </param>
7469 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7470 <desc>Found host network interface object.</desc>
7471 </param>
7472 </method>
7473 <method name="findHostNetworkInterfacesOfType">
7474 <desc>
7475 Searches through all host network interfaces and returns a list of interfaces of the specified type
7476 </desc>
7477 <param name="type" type="HostNetworkInterfaceType" dir="in">
7478 <desc>type of the host network interfaces to search for.</desc>
7479 </param>
7480 <param name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" dir="return">
7481 <desc>Found host network interface objects.</desc>
7482 </param>
7483 </method>
7484
7485 <method name="findUSBDeviceById">
7486 <desc>
7487 Searches for a USB device with the given UUID.
7488
7489 <result name="VBOX_E_OBJECT_NOT_FOUND">
7490 Given @c id does not correspond to any USB device.
7491 </result>
7492
7493 <see>IHostUSBDevice::id</see>
7494 </desc>
7495 <param name="id" type="wstring" dir="in">
7496 <desc>UUID of the USB device to search for.</desc>
7497 </param>
7498 <param name="device" type="IHostUSBDevice" dir="return">
7499 <desc>Found USB device object.</desc>
7500 </param>
7501 </method>
7502
7503 <method name="findUSBDeviceByAddress">
7504 <desc>
7505 Searches for a USB device with the given host address.
7506
7507 <result name="VBOX_E_OBJECT_NOT_FOUND">
7508 Given @c name does not correspond to any USB device.
7509 </result>
7510
7511 <see>IHostUSBDevice::address</see>
7512 </desc>
7513 <param name="name" type="wstring" dir="in">
7514 <desc>
7515 Address of the USB device (as assigned by the host) to
7516 search for.
7517 </desc>
7518 </param>
7519 <param name="device" type="IHostUSBDevice" dir="return">
7520 <desc>Found USB device object.</desc>
7521 </param>
7522 </method>
7523
7524 </interface>
7525
7526 <!--
7527 // ISystemProperties
7528 /////////////////////////////////////////////////////////////////////////
7529 -->
7530
7531 <interface
7532 name="ISystemProperties"
7533 extends="$unknown"
7534 uuid="63bfd184-df69-4949-9159-a923cf7b1207"
7535 wsmap="managed"
7536 >
7537 <desc>
7538 The ISystemProperties interface represents global properties of the given
7539 VirtualBox installation.
7540
7541 These properties define limits and default values for various attributes
7542 and parameters. Most of the properties are read-only, but some can be
7543 changed by a user.
7544 </desc>
7545
7546 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
7547 <desc>Minimum guest system memory in Megabytes.</desc>
7548 </attribute>
7549
7550 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
7551 <desc>Maximum guest system memory in Megabytes.</desc>
7552 </attribute>
7553
7554 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
7555 <desc>Minimum guest video memory in Megabytes.</desc>
7556 </attribute>
7557
7558 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
7559 <desc>Maximum guest video memory in Megabytes.</desc>
7560 </attribute>
7561
7562 <attribute name="minGuestCPUCount" type="unsigned long" readonly="yes">
7563 <desc>Minimum CPU count.</desc>
7564 </attribute>
7565
7566 <attribute name="maxGuestCPUCount" type="unsigned long" readonly="yes">
7567 <desc>Maximum CPU count.</desc>
7568 </attribute>
7569
7570 <attribute name="maxVDISize" type="unsigned long long" readonly="yes">
7571 <desc>Maximum size of a virtual disk image in Megabytes.</desc>
7572 </attribute>
7573
7574 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
7575 <desc>
7576 Number of network adapters associated with every
7577 <link to="IMachine"/> instance.
7578 </desc>
7579 </attribute>
7580
7581 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
7582 <desc>
7583 Number of serial ports associated with every
7584 <link to="IMachine"/> instance.
7585 </desc>
7586 </attribute>
7587
7588 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
7589 <desc>
7590 Number of parallel ports associated with every
7591 <link to="IMachine"/> instance.
7592 </desc>
7593 </attribute>
7594
7595 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
7596 <desc>
7597 Maximum device position in the boot order. This value corresponds
7598 to the total number of devices a machine can boot from, to make it
7599 possible to include all possible devices to the boot list.
7600 <see><link to="IMachine::setBootOrder"/></see>
7601 </desc>
7602 </attribute>
7603
7604 <attribute name="defaultMachineFolder" type="wstring">
7605 <desc>
7606 Full path to the default directory used to create new or open
7607 existing machines when a settings file name contains no
7608 path.
7609
7610 The initial value of this property is
7611 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
7612 VirtualBox_home</link><tt>&gt;/Machines</tt>.
7613
7614 <note>
7615 Setting this property to <tt>null</tt> will restore the
7616 initial value.
7617 </note>
7618 <note>
7619 When settings this property, the specified path can be
7620 absolute (full path) or relative
7621 to the <link to="IVirtualBox::homeFolder">
7622 VirtualBox home directory</link>.
7623 When reading this property, a full path is
7624 always returned.
7625 </note>
7626 <note>
7627 The specified path may not exist, it will be created
7628 when necessary.
7629 </note>
7630
7631 <see>
7632 <link to="IVirtualBox::createMachine"/>,
7633 <link to="IVirtualBox::openMachine"/>
7634 </see>
7635 </desc>
7636 </attribute>
7637
7638 <attribute name="defaultHardDiskFolder" type="wstring">
7639 <desc>
7640 Full path to the default directory used to create new or open existing
7641 virtual disks.
7642
7643 This path is used when the storage unit of a hard disk is a regular file
7644 in the host's file system and only a file name that contains no path is
7645 given.
7646
7647 The initial value of this property is
7648 <tt>&lt;</tt>
7649 <link to="IVirtualBox::homeFolder">VirtualBox_home</link>
7650 <tt>&gt;/HardDisks</tt>.
7651
7652 <note>
7653 Setting this property to <tt>null</tt> will restore the
7654 initial value.
7655 </note>
7656 <note>
7657 When settings this property, the specified path can be relative
7658 to the
7659 <link to="IVirtualBox::homeFolder">VirtualBox home directory</link> or
7660 absolute. When reading this property, a full path is
7661 always returned.
7662 </note>
7663 <note>
7664 The specified path may not exist, it will be created
7665 when necessary.
7666 </note>
7667
7668 <see>
7669 IHardDisk,
7670 <link to="IVirtualBox::createHardDisk"/>,
7671 <link to="IVirtualBox::openHardDisk"/>,
7672 <link to="IMedium::location"/>
7673 </see>
7674 </desc>
7675 </attribute>
7676
7677 <attribute name="hardDiskFormats" type="IHardDiskFormat" safearray="yes" readonly="yes">
7678 <desc>
7679 List of all hard disk storage formats supported by this VirtualBox
7680 installation.
7681
7682 Keep in mind that the hard disk format identifier
7683 (<link to="IHardDiskFormat::id"/>) used in other API calls like
7684 <link to="IVirtualBox::createHardDisk"/> to refer to a particular
7685 hard disk format is a case-insensitive string. This means that, for
7686 example, all of the following strings:
7687 <pre>
7688 "VDI"
7689 "vdi"
7690 "VdI"</pre>
7691 refer to the same hard disk format.
7692
7693 Note that the virtual hard disk framework is backend-based, therefore
7694 the list of supported formats depends on what backends are currently
7695 installed.
7696
7697 <see>
7698 <link to="IHardDiskFormat"/>,
7699 </see>
7700 </desc>
7701 </attribute>
7702
7703 <attribute name="defaultHardDiskFormat" type="wstring">
7704 <desc>
7705 Identifier of the default hard disk format used by VirtualBox.
7706
7707 The hard disk format set by this attribute is used by VirtualBox
7708 when the hard disk format was not specified explicitly. One example is
7709 <link to="IVirtualBox::createHardDisk"/> with the <tt>null</tt>
7710 format argument. A more complex example is implicit creation of
7711 differencing hard disks when taking a snapshot of a virtual machine:
7712 this operation will try to use a format of the parent hard disk first
7713 and if this format does not support differencing hard disks the default
7714 format specified by this argument will be used.
7715
7716 The list of supported hard disk formats may be obtained by the
7717 <link to="#hardDiskFormats"/> call. Note that the default hard disk
7718 format must have a capability to create differencing hard disks;
7719 otherwise opeartions that create hard disks implicitly may fail
7720 unexpectedly.
7721
7722 The initial value of this property is <tt>VDI</tt> in the current
7723 version of the VirtualBox product, but may change in the future.
7724
7725 <note>
7726 Setting this property to <tt>null</tt> will restore the
7727 initial value.
7728 </note>
7729
7730 <see>
7731 <link to="#hardDiskFormats"/>,
7732 <link to="IHardDiskFormat::id"/>,
7733 <link to="IVirtualBox::createHardDisk"/>
7734 </see>
7735 </desc>
7736 </attribute>
7737
7738 <attribute name="remoteDisplayAuthLibrary" type="wstring">
7739 <desc>
7740 Library that provides authentication for VRDP clients. The library
7741 is used if a virtual machine's authentication type is set to "external"
7742 in the VM RemoteDisplay configuration.
7743
7744 The system library extension (".DLL" or ".so") must be omitted.
7745 A full path can be specified; if not, then the library must reside on the
7746 system's default library path.
7747
7748 The default value of this property is <tt>VRDPAuth</tt>. There is a library
7749 of that name in one of the default VirtualBox library directories.
7750
7751 For details about VirtualBox authentication libraries and how to implement
7752 them, please refer to the VirtualBox manual.
7753
7754 <note>
7755 Setting this property to <tt>null</tt> will restore the
7756 initial value.
7757 </note>
7758 </desc>
7759 </attribute>
7760
7761 <attribute name="webServiceAuthLibrary" type="wstring">
7762 <desc>
7763 Library that provides authentication for webservice clients. The library
7764 is used if a virtual machine's authentication type is set to "external"
7765 in the VM RemoteDisplay configuration and will be called from
7766 within the <link to="IWebsessionManager::logon" /> implementation.
7767
7768 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
7769 there is no per-VM setting for this, as the webservice is a global
7770 resource (if it is running). Only for this setting (for the webservice),
7771 setting this value to a literal "null" string disables authentication,
7772 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
7773 no matter what user name and password are supplied.
7774
7775 The initial value of this property is <tt>VRDPAuth</tt>,
7776 meaning that the webservice will use the same authentication
7777 library that is used by default for VBoxVRDP (again, see
7778 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
7779 The format and calling convention of authentication libraries
7780 is the same for the webservice as it is for VBoxVRDP.
7781
7782 </desc>
7783 </attribute>
7784
7785 <attribute name="HWVirtExEnabled" type="boolean">
7786 <desc>
7787 This specifies the default value for hardware virtualization
7788 extensions. If enabled, virtual machines will make use of
7789 hardware virtualization extensions such as Intel VT-x and
7790 AMD-V by default. This value can be overridden by each VM
7791 using their <link to="IMachine::HWVirtExEnabled" /> property.
7792 </desc>
7793 </attribute>
7794
7795 <attribute name="LogHistoryCount" type="unsigned long">
7796 <desc>
7797 This value specifies how many old release log files are kept.
7798 </desc>
7799 </attribute>
7800
7801 <attribute name="defaultAudioDriver" type="AudioDriverType" readonly="yes">
7802 <desc>This value hold the default audio driver for the current
7803 system.</desc>
7804 </attribute>
7805 </interface>
7806
7807 <!--
7808 // IGuest
7809 /////////////////////////////////////////////////////////////////////////
7810 -->
7811
7812 <interface
7813 name="IGuestOSType" extends="$unknown"
7814 uuid="cfe9e64c-4430-435b-9e7c-e3d8e417bd58"
7815 wsmap="struct"
7816 >
7817 <desc>
7818 </desc>
7819
7820 <attribute name="familyId" type="wstring" readonly="yes">
7821 <desc>Guest OS family identifier string.</desc>
7822 </attribute>
7823
7824 <attribute name="familyDescription" type="wstring" readonly="yes">
7825 <desc>Human readable description of the guest OS family.</desc>
7826 </attribute>
7827
7828 <attribute name="id" type="wstring" readonly="yes">
7829 <desc>Guest OS identifier string.</desc>
7830 </attribute>
7831
7832 <attribute name="description" type="wstring" readonly="yes">
7833 <desc>Human readable description of the guest OS.</desc>
7834 </attribute>
7835
7836 <attribute name="is64Bit" type="boolean" readonly="yes">
7837 <desc>Returns @c true if the given OS is 64-bit</desc>
7838 </attribute>
7839
7840 <attribute name="recommendedIOAPIC" type="boolean" readonly="yes">
7841 <desc>Returns @c true if IO APIC recommended for this OS type.</desc>
7842 </attribute>
7843
7844 <attribute name="recommendedVirtEx" type="boolean" readonly="yes">
7845 <desc>Returns @c true if VT-x or AMD-V recommended for this OS type.</desc>
7846 </attribute>
7847
7848 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
7849 <desc>Recommended RAM size in Megabytes.</desc>
7850 </attribute>
7851
7852 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
7853 <desc>Recommended video RAM size in Megabytes.</desc>
7854 </attribute>
7855
7856 <attribute name="recommendedHDD" type="unsigned long" readonly="yes">
7857 <desc>Recommended hard disk size in Megabytes.</desc>
7858 </attribute>
7859
7860 <attribute name="adapterType" type="NetworkAdapterType" readonly="yes">
7861 <desc>Returns recommended network adapter for this OS type.</desc>
7862 </attribute>
7863 </interface>
7864
7865 <interface
7866 name="IGuest" extends="$unknown"
7867 uuid="d8556fca-81bc-12af-fca3-365528fa38ca"
7868 wsmap="suppress"
7869 >
7870 <desc>
7871 The IGuest interface represents information about the operating system
7872 running inside the virtual machine. Used in
7873 <link to="IConsole::guest"/>.
7874
7875 IGuest provides information about the guest operating system, whether
7876 Guest Additions are installed and other OS-specific virtual machine
7877 properties.
7878 </desc>
7879
7880 <attribute name="OSTypeId" type="wstring" readonly="yes">
7881 <desc>
7882 Identifier of the Guest OS type as reported by the Guest
7883 Additions.
7884 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
7885 an IGuestOSType object representing details about the given
7886 Guest OS type.
7887 <note>
7888 If Guest Additions are not installed, this value will be
7889 the same as <link to="IMachine::OSTypeId"/>.
7890 </note>
7891 </desc>
7892 </attribute>
7893
7894 <attribute name="additionsActive" type="boolean" readonly="yes">
7895 <desc>
7896 Flag whether the Guest Additions are installed and active
7897 in which case their version will be returned by the
7898 <link to="#additionsVersion"/> property.
7899 </desc>
7900 </attribute>
7901
7902 <attribute name="additionsVersion" type="wstring" readonly="yes">
7903 <desc>
7904 Version of the Guest Additions (3 decimal numbers separated
7905 by dots) or empty when the Additions are not installed. The
7906 Additions may also report a version but yet not be active as
7907 the version might be refused by VirtualBox (incompatible) or
7908 other failures occurred.
7909 </desc>
7910 </attribute>
7911
7912 <attribute name="supportsSeamless" type="boolean" readonly="yes">
7913 <desc>
7914 Flag whether seamless guest display rendering (seamless desktop
7915 integration) is supported.
7916 </desc>
7917 </attribute>
7918
7919 <attribute name="supportsGraphics" type="boolean" readonly="yes">
7920 <desc>
7921 Flag whether the guest is in graphics mode. If it is not, then
7922 seamless rendering will not work, resize hints are not immediately
7923 acted on and guest display resizes are probably not initiated by
7924 the guest additions.
7925 </desc>
7926 </attribute>
7927
7928 <attribute name="memoryBalloonSize" type="unsigned long">
7929 <desc>Guest system memory balloon size in megabytes.</desc>
7930 </attribute>
7931
7932 <attribute name="statisticsUpdateInterval" type="unsigned long">
7933 <desc>Interval to update guest statistics in seconds.</desc>
7934 </attribute>
7935
7936 <method name="setCredentials">
7937 <desc>
7938 Store login credentials that can be queried by guest operating
7939 systems with Additions installed. The credentials are transient
7940 to the session and the guest may also choose to erase them. Note
7941 that the caller cannot determine whether the guest operating system
7942 has queried or made use of the credentials.
7943
7944 <result name="VBOX_E_VM_ERROR">
7945 VMM device is not available.
7946 </result>
7947
7948 </desc>
7949 <param name="userName" type="wstring" dir="in">
7950 <desc>User name string, can be empty</desc>
7951 </param>
7952 <param name="password" type="wstring" dir="in">
7953 <desc>Password string, can be empty</desc>
7954 </param>
7955 <param name="domain" type="wstring" dir="in">
7956 <desc>Domain name (guest logon scheme specific), can be empty</desc>
7957 </param>
7958 <param name="allowInteractiveLogon" type="boolean" dir="in">
7959 <desc>
7960 Flag whether the guest should alternatively allow the user to
7961 interactively specify different credentials. This flag might
7962 not be supported by all versions of the Additions.
7963 </desc>
7964 </param>
7965 </method>
7966
7967 <method name="getStatistic">
7968 <desc>
7969 Query specified guest statistics as reported by the VirtualBox Additions.
7970 </desc>
7971 <param name="cpuId" type="unsigned long" dir="in">
7972 <desc>Virtual CPU id; not relevant for all statistic types</desc>
7973 </param>
7974 <param name="statistic" type="GuestStatisticType" dir="in">
7975 <desc>Statistic type.</desc>
7976 </param>
7977 <param name="statVal" type="unsigned long" dir="out">
7978 <desc>Statistics value</desc>
7979 </param>
7980 </method>
7981
7982 </interface>
7983
7984
7985 <!--
7986 // IProgress
7987 /////////////////////////////////////////////////////////////////////////
7988 -->
7989
7990 <interface
7991 name="IProgress" extends="$unknown"
7992 uuid="6fcd0198-7fc5-4c53-8c37-653ac76854b5"
7993 wsmap="managed"
7994 >
7995 <desc>
7996 The IProgress interface is used to track and control
7997 asynchronous tasks within VirtualBox.
7998
7999 An instance of this is returned every time VirtualBox starts
8000 an asynchronous task (in other words, a separate thread) which
8001 continues to run after a method call returns. For example,
8002 <link to="IConsole::saveState" />, which saves the state of
8003 a running virtual machine, can take a long time to complete.
8004 To be able to display a progress bar, a user interface such as
8005 the VirtualBox graphical user interface can use the IProgress
8006 object returned by that method.
8007
8008 Note that IProgress is a "read-only" interface in the sense
8009 that only the VirtualBox internals behind the Main API can
8010 create and manipulate progress objects, whereas client code
8011 can only use the IProgress object to monitor a task's
8012 progress and, if <link to="#cancelable" /> is true,
8013 cancel the task by calling <link to="#cancel" />.
8014
8015 A task represented by IProgress consists of either one or
8016 several sub-operations that run sequentially, one by one (see
8017 <link to="#operation" /> and <link to="#operationCount" />).
8018 Every operation is identified by a number (starting from 0)
8019 and has a separate description.
8020
8021 You can find the individual percentage of completion of the current
8022 operation in <link to="#operationPercent" /> and the
8023 percentage of completion of the task as a whole
8024 in <link to="#percent" />.
8025
8026 Similarly, you can wait for the completion of a particular
8027 operation via <link to="#waitForOperationCompletion" /> or
8028 for the completion of the whole task via
8029 <link to="#waitForCompletion" />.
8030 </desc>
8031
8032 <attribute name="id" type="wstring" readonly="yes">
8033 <desc>ID of the task.</desc>
8034 </attribute>
8035
8036 <attribute name="description" type="wstring" readonly="yes">
8037 <desc>Description of the task.</desc>
8038 </attribute>
8039
8040 <attribute name="initiator" type="$unknown" readonly="yes">
8041 <desc>Initiator of the task.</desc>
8042 </attribute>
8043
8044 <attribute name="cancelable" type="boolean" readonly="yes">
8045 <desc>Whether the task can be interrupted.</desc>
8046 </attribute>
8047
8048 <attribute name="percent" type="unsigned long" readonly="yes">
8049 <desc>
8050 Current progress value of the task as a whole, in percent.
8051 This value depends on how many operations are already complete.
8052 Returns 100 if <link to="#completed" /> is true.
8053 </desc>
8054 </attribute>
8055
8056 <attribute name="timeRemaining" type="long" readonly="yes">
8057 <desc>
8058 Estimated remaining time until the task completes, in
8059 seconds. Returns 0 once the task has completed; returns -1
8060 if the remaining time cannot be computed, in particular if
8061 the current progress is 0.
8062
8063 Even if a value is returned, the estimate will be unreliable
8064 for low progress values. It will become more reliable as the
8065 task progresses; it is not recommended to display an ETA
8066 before at least 20% of a task have completed.
8067 </desc>
8068 </attribute>
8069
8070 <attribute name="completed" type="boolean" readonly="yes">
8071 <desc>Whether the task has been completed.</desc>
8072 </attribute>
8073
8074 <attribute name="canceled" type="boolean" readonly="yes">
8075 <desc>Whether the task has been canceled.</desc>
8076 </attribute>
8077
8078 <attribute name="resultCode" type="long" readonly="yes">
8079 <desc>
8080 Result code of the progress task.
8081 Valid only if <link to="#completed"/> is true.
8082 </desc>
8083 </attribute>
8084
8085 <attribute name="errorInfo" type="IVirtualBoxErrorInfo" readonly="yes">
8086 <desc>
8087 Extended information about the unsuccessful result of the
8088 progress operation. May be NULL if no extended information
8089 is available.
8090 Valid only if <link to="#completed"/> is true and
8091 <link to="#resultCode"/> indicates a failure.
8092 </desc>
8093 </attribute>
8094
8095 <attribute name="operationCount" type="unsigned long" readonly="yes">
8096 <desc>
8097 Number of sub-operations this task is divided into.
8098 Every task consists of at least one suboperation.
8099 </desc>
8100 </attribute>
8101
8102 <attribute name="operation" type="unsigned long" readonly="yes">
8103 <desc>Number of the sub-operation being currently executed.</desc>
8104 </attribute>
8105
8106 <attribute name="operationDescription" type="wstring" readonly="yes">
8107 <desc>
8108 Description of the sub-operation being currently executed.
8109 </desc>
8110 </attribute>
8111
8112 <attribute name="operationPercent" type="unsigned long" readonly="yes">
8113 <desc>Progress value of the current sub-operation only, in percent.</desc>
8114 </attribute>
8115
8116 <method name="waitForCompletion">
8117 <desc>
8118 Waits until the task is done (including all sub-operations)
8119 with a given timeout in milliseconds; specify -1 for an indefinite wait.
8120
8121 <result name="VBOX_E_IPRT_ERROR">
8122 Failed to wait for task completion.
8123 </result>
8124 </desc>
8125
8126 <param name="timeout" type="long" dir="in">
8127 <desc>
8128 Maximum time in milliseconds to wait or -1 to wait indefinitely.
8129 </desc>
8130 </param>
8131 </method>
8132
8133 <method name="waitForOperationCompletion">
8134 <desc>
8135 Waits until the given operation is done with a given timeout in
8136 milliseconds; specify -1 for an indefinite wait.
8137
8138 <result name="VBOX_E_IPRT_ERROR">
8139 Failed to wait for operation completion.
8140 </result>
8141
8142 </desc>
8143 <param name="operation" type="unsigned long" dir="in">
8144 <desc>
8145 Number of the operation to wait for.
8146 Must be less than <link to="#operationCount"/>.
8147 </desc>
8148 </param>
8149 <param name="timeout" type="long" dir="in">
8150 <desc>
8151 Maximum time in milliseconds to wait or -1 to wait indefinitely.
8152 </desc>
8153 </param>
8154 </method>
8155
8156 <method name="cancel">
8157 <desc>
8158 Cancels the task.
8159 <note>
8160 If <link to="#cancelable"/> is <tt>false</tt>, then
8161 this method will fail.
8162 </note>
8163
8164 <result name="VBOX_E_INVALID_OBJECT_STATE">
8165 Operation cannot be canceled.
8166 </result>
8167
8168 </desc>
8169 </method>
8170
8171 </interface>
8172
8173
8174 <!--
8175 // ISnapshot
8176 /////////////////////////////////////////////////////////////////////////
8177 -->
8178
8179 <interface
8180 name="ISnapshot" extends="$unknown"
8181 uuid="1a2d0551-58a4-4107-857e-ef414fc42ffc"
8182 wsmap="managed"
8183 >
8184 <desc>
8185 The ISnapshot interface represents a snapshot of the virtual
8186 machine.
8187
8188 The <i>snapshot</i> stores all the information about a virtual
8189 machine necessary to bring it to exactly the same state as it was at
8190 the time of taking the snapshot. The snapshot includes:
8191
8192 <ul>
8193 <li>all settings of the virtual machine (i.e. its hardware
8194 configuration: RAM size, attached hard disks, etc.)
8195 </li>
8196 <li>the execution state of the virtual machine (memory contents,
8197 CPU state, etc.).
8198 </li>
8199 </ul>
8200
8201 Snapshots can be <i>offline</i> (taken when the VM is powered off)
8202 or <i>online</i> (taken when the VM is running). The execution
8203 state of the offline snapshot is called a <i>zero execution state</i>
8204 (it doesn't actually contain any information about memory contents
8205 or the CPU state, assuming that all hardware is just powered off).
8206
8207 <h3>Snapshot branches</h3>
8208
8209 Snapshots can be chained. Chained snapshots form a branch where
8210 every next snapshot is based on the previous one. This chaining is
8211 mostly related to hard disk branching (see <link to="IHardDisk"/>
8212 description). This means that every time a new snapshot is created,
8213 a new differencing hard disk is implicitly created for all normal
8214 hard disks attached to the given virtual machine. This allows to
8215 fully restore hard disk contents when the machine is later reverted
8216 to a particular snapshot.
8217
8218 In the current implementation, multiple snapshot branches within one
8219 virtual machine are not allowed. Every machine has a single branch,
8220 and <link to="IConsole::takeSnapshot"/> operation adds a new
8221 snapshot to the top of that branch.
8222
8223 Existing snapshots can be discarded using
8224 <link to="IConsole::discardSnapshot"/>.
8225
8226 <h3>Current snapshot</h3>
8227
8228 Every virtual machine has a current snapshot, identified by
8229 <link to="IMachine::currentSnapshot"/>. This snapshot is used as
8230 a base for the <i>current machine state</i> (see below), to the effect
8231 that all normal hard disks of the machine and its execution
8232 state are based on this snapshot.
8233
8234 In the current implementation, the current snapshot is always the
8235 last taken snapshot (i.e. the head snapshot on the branch) and it
8236 cannot be changed.
8237
8238 The current snapshot is <tt>null</tt> if the machine doesn't have
8239 snapshots at all; in this case the current machine state is just
8240 current settings of this machine plus its current execution state.
8241
8242 <h3>Current machine state</h3>
8243
8244 The current machine state is what represented by IMachine instances got
8245 directly from IVirtualBox
8246 using <link
8247 to="IVirtualBox::getMachine">getMachine()</link>, <link
8248 to="IVirtualBox::findMachine">findMachine()</link>, etc. (as opposed
8249 to instances returned by <link to="ISnapshot::machine"/>). This state
8250 is always used when the machine is <link to="IConsole::powerUp"> powered
8251 on</link>.
8252
8253 The current machine state also includes the current execution state.
8254 If the machine is being currently executed
8255 (<link to="IMachine::state"/> is <link to="MachineState_Running"/>
8256 and above), its execution state is just what's happening now.
8257 If it is powered off (<link to="MachineState_PoweredOff"/> or
8258 <link to="MachineState_Aborted"/>), it has a zero execution state.
8259 If the machine is saved (<link to="MachineState_Saved"/>), its
8260 execution state is what saved in the execution state file
8261 (<link to="IMachine::stateFilePath"/>).
8262
8263 If the machine is in the saved state, then, next time it is powered
8264 on, its execution state will be fully restored from the saved state
8265 file and the execution will continue from the point where the state
8266 was saved.
8267
8268 Similarly to snapshots, the current machine state can be discarded
8269 using <link to="IConsole::discardCurrentState"/>.
8270
8271 <h3>Taking and discarding snapshots</h3>
8272
8273 The table below briefly explains the meaning of every snapshot
8274 operation:
8275
8276 <table>
8277 <tr><th>Operation</th><th>Meaning</th><th>Remarks</th></tr>
8278
8279 <tr><td><link to="IConsole::takeSnapshot"/></td>
8280
8281 <td>Save the current state of the virtual machine, including all
8282 settings, contents of normal hard disks and the current modifications
8283 to immutable hard disks (for online snapshots)</td>
8284
8285 <td>The current state is not changed (the machine will continue
8286 execution if it is being executed when the snapshot is
8287 taken)</td></tr>
8288
8289 <tr><td><link to="IConsole::discardSnapshot"/></td>
8290
8291 <td>Forget the state of the virtual machine stored in the snapshot:
8292 dismiss all saved settings and delete the saved execution state (for
8293 online snapshots)</td>
8294
8295 <td>Other snapshots (including child snapshots, if any) and the
8296 current state are not directly affected</td></tr>
8297
8298 <tr><td><link to="IConsole::discardCurrentState"/></td>
8299
8300 <td>Restore the current state of the virtual machine from the state
8301 stored in the current snapshot, including all settings and hard disk
8302 contents</td>
8303
8304 <td>The current state of the machine existed prior to this operation
8305 is lost</td></tr>
8306
8307 <tr><td><link to="IConsole::discardCurrentSnapshotAndState"/></td>
8308
8309 <td>Completely revert the virtual machine to the state it was in
8310 before the current snapshot has been taken</td>
8311
8312 <td>The current state, as well as the current snapshot, are
8313 lost</td></tr>
8314
8315 </table>
8316
8317 </desc>
8318
8319 <attribute name="id" type="wstring" readonly="yes">
8320 <desc>UUID of the snapshot.</desc>
8321 </attribute>
8322
8323 <attribute name="name" type="wstring">
8324 <desc>Short name of the snapshot.</desc>
8325 </attribute>
8326
8327 <attribute name="description" type="wstring">
8328 <desc>Optional description of the snapshot.</desc>
8329 </attribute>
8330
8331 <attribute name="timeStamp" type="long long" readonly="yes">
8332 <desc>
8333 Time stamp of the snapshot, in milliseconds since 1970-01-01 UTC.
8334 </desc>
8335 </attribute>
8336
8337 <attribute name="online" type="boolean" readonly="yes">
8338 <desc>
8339 <tt>true</tt> if this snapshot is an online snapshot and
8340 <tt>false</tt> otherwise.
8341
8342 <note>
8343 When this attribute is <tt>true</tt>, the
8344 <link to="IMachine::stateFilePath"/> attribute of the
8345 <link to="#machine"/> object associated with this snapshot
8346 will point to the saved state file. Otherwise, it will be
8347 <tt>null</tt>.
8348 </note>
8349 </desc>
8350 </attribute>
8351
8352 <attribute name="machine" type="IMachine" readonly="yes">
8353 <desc>
8354 Virtual machine this snapshot is taken on. This object
8355 stores all settings the machine had when taking this snapshot.
8356 <note>
8357 The returned machine object is immutable, i.e. no
8358 any settings can be changed.
8359 </note>
8360 </desc>
8361 </attribute>
8362
8363 <attribute name="parent" type="ISnapshot" readonly="yes">
8364 <desc>
8365 Parent snapshot (a snapshot this one is based on).
8366 <note>
8367 It's not an error to read this attribute on a snapshot
8368 that doesn't have a parent -- a null object will be
8369 returned to indicate this.
8370 </note>
8371 </desc>
8372 </attribute>
8373
8374 <attribute name="children" type="ISnapshot" readonly="yes" safearray="yes">
8375 <desc>
8376 Child snapshots (all snapshots having this one as a parent).
8377 <note>
8378 In the current implementation, there can be only one
8379 child snapshot, or no children at all, meaning this is the
8380 last (head) snapshot.
8381 </note>
8382 </desc>
8383 </attribute>
8384
8385 </interface>
8386
8387
8388 <!--
8389 // IMedia
8390 /////////////////////////////////////////////////////////////////////////
8391 -->
8392
8393 <enum
8394 name="MediaState"
8395 uuid="8b86e03c-2f1c-412a-8fbd-326f62701200"
8396 >
8397 <desc>
8398 Virtual media state.
8399 <see>IMedia</see>
8400 </desc>
8401
8402 <const name="NotCreated" value="0">
8403 <desc>
8404 Associated media storage does not exist (either was not created yet or
8405 was deleted).
8406 </desc>
8407 </const>
8408 <const name="Created" value="1">
8409 <desc>
8410 Associated storage exists and accessible.
8411 </desc>
8412 </const>
8413 <const name="LockedRead" value="2">
8414 <desc>
8415 Media is locked for reading, no data modification is possible.
8416 </desc>
8417 </const>
8418 <const name="LockedWrite" value="3">
8419 <desc>
8420 Media is locked for writing, no concurrent data reading or modification
8421 is possible.
8422 </desc>
8423 </const>
8424 <const name="Inaccessible" value="4">
8425 <desc>
8426 Associated media storage is not accessible.
8427 </desc>
8428 </const>
8429 <const name="Creating" value="5">
8430 <desc>
8431 Associated media storage is being created.
8432 </desc>
8433 </const>
8434 <const name="Deleting" value="6">
8435 <desc>
8436 Associated media storage is being deleted.
8437 </desc>
8438 </const>
8439 </enum>
8440
8441 <interface
8442 name="IMedium" extends="$unknown"
8443 uuid="f585787c-7728-40f6-853a-13705426e936"
8444 wsmap="managed"
8445 >
8446 <desc>
8447 The IMedium interface is a common interface for all objects representing
8448 virtual media such as hard disks, CD/DVD images and floppy images.
8449
8450 Each medium is associated with a storage unit (such as a file on the host
8451 computer or a network resource) that holds actual data. The location of
8452 the storage unit is represented by the #location attribute. The value of
8453 this attribute is media type dependent.
8454
8455 The exact media type may be determined by querying the appropriate
8456 interface such as:
8457 <ul>
8458 <li><link to="IHardDisk" /> (virtual hard disks)</li>
8459 <li><link to="IDVDImage" /> (standard CD/DVD ISO image files)</li>
8460 <li><link to="IFloppyImage" /> (raw floppy image files)</li>
8461 </ul>
8462
8463 Existing media are opened using the following methods, depending on the
8464 media type:
8465 <ul>
8466 <li><link to="IVirtualBox::openHardDisk"/></li>
8467 <li><link to="IVirtualBox::openDVDImage"/></li>
8468 <li><link to="IVirtualBox::openFloppyImage"/></li>
8469 </ul>
8470
8471 New hard disk media are created using the
8472 <link to="IVirtualBox::createHardDisk"/> method. CD/DVD and floppy
8473 images are created outside VirtualBox, usually by storing a copy
8474 of the real medium of the corresponding type in a regular file.
8475
8476 <h3>Known Media</h3>
8477
8478 When an existing medium gets opened for the first time, it gets
8479 automatically remembered by the given VirtualBox installation or, in other
8480 words, becomes a <i>known medium</i>. Known media are stored in the media
8481 registry transparently maintained by VirtualBox and stored in settings
8482 files so that this registry is preserved when VirtualBox is not running.
8483
8484 Newly created virtual hard disks get remembered only when the associated
8485 storage unit is actually created (see IHardDisk for more details).
8486
8487 All known media can be enumerated using
8488 <link to="IVirtualBox::hardDisks"/>,
8489 <link to="IVirtualBox::DVDImages"/> and
8490 <link to="IVirtualBox::floppyImages"/> attributes. Individual media can be
8491 quickly found by UUID using <link to="IVirtualBox::getHardDisk"/>
8492 and similar methods or by location using
8493 <link to="IVirtualBox::findHardDisk"/> and similar methods.
8494
8495 Only known media can be attached to virtual machines.
8496
8497 Removing known media from the media registry is performed when the given
8498 medium is closed using the <link to="#close"/> method or when its
8499 associated storage unit is deleted (only for hard disks).
8500
8501 <h3>Accessibility Checks</h3>
8502
8503 The given medium (with the created storage unit) is considered to be
8504 <i>accessible</i> when its storage unit can be read.
8505 Accessible media are indicated by the <link to="MediaState_Created"/>
8506 value of the <link to="#state"/> attribute. When the storage unit cannot
8507 be read (for example, because it is located on a disconnected network
8508 resource, or was accidentally deleted outside VirtualBox), the medium is
8509 considered to be <i>inaccessible</i> which is indicated by the
8510 <link to="MediaState_Inaccessible"/> state. The details about the reason
8511 of being inaccessible can be obtained using the
8512 <link to="#lastAccessError"/> attribute.
8513
8514 A new accessibility check is performed each time the <link to="#state"/>
8515 attribute is read. Please note that this check may take long time (several
8516 seconds or even minutes, depending on the storage unit location and
8517 format), and will block the calling thread until finished. For this
8518 reason, it is recommended to never read this attribute on the main UI
8519 thread to avoid making the UI unresponsive.
8520
8521 Note that when VirtualBox starts up (e.g. the VirtualBox object gets
8522 created for the first time), all known media are in the
8523 <link to="MediaState_Inaccessible"/> state but the value of the <link
8524 to="#lastAccessError"/> attribute is <tt>null</tt> because no actual
8525 accessibility check is made on startup. This is done to make the
8526 VirtualBox object ready for serving requests as
8527 fast as possible and let the end-user application decide if it needs to
8528 check media accessibility right away or not.
8529 </desc>
8530
8531 <attribute name="id" type="wstring" readonly="yes">
8532 <desc>
8533 UUID of the medium. For a newly created medium, this value is a randomly
8534 generated UUID.
8535
8536 <note>
8537 For media in one of MediaState_NotCreated, MediaState_Creating or
8538 MediaState_Deleting states, the value of this property is undefined
8539 and will most likely be an empty UUID.
8540 </note>
8541 </desc>
8542 </attribute>
8543
8544 <attribute name="description" type="wstring">
8545 <desc>
8546 Optional description of the medium. For newly created media, the value
8547 of this attribute value is <tt>null</tt>.
8548
8549 Media types that don't support this attribute will return E_NOTIMPL in
8550 attempt to get or set this attribute's value.
8551
8552 <note>
8553 For some storage types, reading this attribute may return an outdated
8554 (last known) value when <link to="#state"/> is <link
8555 to="MediaState_Inaccessible"/> or <link
8556 to="MediaState_LockedWrite"/> because the value of this attribute is
8557 stored within the storage unit itself. Also note that changing the
8558 attribute value is not possible in such case, as well as when the
8559 medium is the <link to="MediaState_LockedRead"/> state.
8560 </note>
8561 </desc>
8562 </attribute>
8563
8564 <attribute name="state" type="MediaState" readonly="yes">
8565 <desc>
8566 Current media state. Inspect <link to="MediaState"/> values for details.
8567
8568 Reading this attribute may take a long time because an accessibility
8569 check of the storage unit is performed each time the attribute is read.
8570 This check may cause a significant delay if the storage unit of the
8571 given medium is, for example, a file located on a network share which is
8572 not currently accessible due to connectivity problems -- the call will
8573 not return until a timeout interval defined by the host OS for this
8574 operation expires.
8575
8576 If the last known state of the medium is <link to="MediaState_Created"/>
8577 and the accessibility check fails then the state would be set to
8578 <link to="MediaState_Inaccessible"/> and <link to="#lastAccessError"/>
8579 may be used to get more details about the failure. If the state of the
8580 medium is <link to="MediaState_LockedRead"/> or
8581 <link to="MediaState_LockedWrite"/> then it remains the same, and a
8582 non-null value of <link to="#lastAccessError"/> will indicate a failed
8583 accessibility check in this case.
8584
8585 Note that not all media states are applicable to all media types.
8586 For example, states <link to="MediaState_NotCreated"/>,
8587 <link to="MediaState_LockedWrite"/>, <link to="MediaState_Creating"/>,
8588 <link to="MediaState_Deleting"/> are meaningless for IDVDImage and
8589 IFloppyImage media.
8590 </desc>
8591 </attribute>
8592
8593 <attribute name="location" type="wstring">
8594 <desc>
8595 Location of the storage unit holding media data.
8596
8597 The format of the location string is media type specific. For media
8598 types using regular files in a host's file system, the location
8599 string is the full file name.
8600
8601 Some media types may support changing the storage unit location by
8602 simply changing the value of this property. If this operation is not
8603 supported, the implementation will return E_NOTIMPL in attempt to set
8604 this attribute's value.
8605
8606 When setting a value of the location attribute which is a regular file
8607 in the host's file system, the given file name may be either relative to
8608 the <link to="IVirtualBox::homeFolder">VirtualBox home folder</link> or
8609 absolute. Note that if the given location specification does not contain
8610 the file extension part then a proper default extension will be
8611 automatically appended by the implementation depending on the media type.
8612 </desc>
8613 </attribute>
8614
8615 <attribute name="name" type="wstring" readonly="yes">
8616 <desc>
8617 Name of the storage unit holding media data.
8618
8619 The returned string is a short version of the <link to="#location"/>
8620 attribute that is suitable for representing the medium in situations
8621 where the full location specification is too long (such as lists
8622 and comboboxes in GUI frontends). This string is also used by frontends
8623 to sort the media list alphabetically when needed.
8624
8625 For example, for locations that are regular files in the host's file
8626 system, the value of this attribute is just the file name (+ extension),
8627 without the path specification.
8628
8629 Note that as opposed to the <link to="#location"/> attribute, the name
8630 attribute will not necessary be unique for a list of media of the
8631 given type and format.
8632 </desc>
8633 </attribute>
8634
8635 <attribute name="size" type="unsigned long long" readonly="yes">
8636 <desc>
8637 Physical size of the storage unit used to hold media data (in bytes).
8638
8639 <note>
8640 For media whose <link to="#state"/> is <link
8641 to="MediaState_Inaccessible"/>, the value of this property is the
8642 last known size. For <link to="MediaState_NotCreated"/> media,
8643 the returned value is zero.
8644 </note>
8645 </desc>
8646 </attribute>
8647
8648 <attribute name="lastAccessError" type="wstring" readonly="yes">
8649 <desc>
8650 Text message that represents the result of the last accessibility
8651 check.
8652
8653 Accessibility checks are performed each time the <link to="#state"/>
8654 attribute is read. A @c null string is returned if the last
8655 accessibility check was successful. A non-null string indicates a
8656 failure and should normally describe a reason of the failure (for
8657 example, a file read error).
8658 </desc>
8659 </attribute>
8660
8661 <attribute name="machineIds" type="wstring" safearray="yes" readonly="yes">
8662 <desc>
8663 Array of UUIDs of all machines this medium is attached to.
8664
8665 A <tt>null</tt> array is returned if this medium is not attached to any
8666 machine or to any machine's snapshot.
8667
8668 <note>
8669 The returned array will include a machine even if this medium is not
8670 attached to that machine in the current state but attached to it in
8671 one of the machine's snapshots. See <link to="#getSnapshotIds"/> for
8672 details.
8673 </note>
8674 </desc>
8675 </attribute>
8676
8677 <method name="getSnapshotIds">
8678 <desc>
8679 Returns an array of UUIDs of all snapshots of the given machine where
8680 this medium is attached to.
8681
8682 If the medium is attached to the machine in the current state, then the
8683 first element in the array will always be the ID of the queried machine
8684 (i.e. the value equal to the @c machineId argument), followed by
8685 snapshot IDs (if any).
8686
8687 If the medium is not attached to the machine in the current state, then
8688 the array will contain only snapshot IDs.
8689
8690 The returned array may be <tt>null</tt> if this medium is not attached
8691 to the given machine at all, neither in the current state nor in one of
8692 the snapshots.
8693 </desc>
8694 <param name="machineId" type="wstring" dir="in">
8695 <desc>
8696 UUID of the machine to query.
8697 </desc>
8698 </param>
8699 <param name="snapshotIds" type="wstring" safearray="yes" dir="return">
8700 <desc>
8701 Array of snapshot UUIDs of the given machine using this medium.
8702 </desc>
8703 </param>
8704 </method>
8705
8706 <method name="lockRead">
8707 <desc>
8708 Locks this medium for reading.
8709
8710 The read lock is shared: many clients can simultaneously lock the
8711 same media for reading unless it is already locked for writing (see
8712 <link to="#lockWrite"/>) in which case an error is returned.
8713
8714 When the medium is locked for reading, it cannot be modified
8715 from within VirtualBox. This means that any method that changes
8716 the properties of this medium or contents of the storage unit
8717 will return an error (unless explicitly stated otherwise) and
8718 that an attempt to start a virtual machine that wants to modify
8719 the medium will also fail.
8720
8721 When the virtual machine is started up, it locks for reading all
8722 media it uses in read-only mode. If some media cannot be locked
8723 for reading, the startup procedure will fail.
8724
8725 The medium locked for reading must be unlocked using the <link
8726 to="#unlockRead"/> method. Calls to <link to="#lockRead"/>
8727 can be nested and must be followed by the same number of paired
8728 <link to="#unlockRead"/> calls.
8729
8730 This method sets the media state to <link
8731 to="MediaState_LockedRead" /> on success. The state prior to
8732 this call must be <link to="MediaState_Created" />,
8733 <link to="MediaState_Inaccessible" /> or
8734 <link to="MediaState_LockedRead" />.
8735 As you can see, inaccessible media can be locked too. This is
8736 not an error; this method performs a logical lock that prevents
8737 modifications of this media through the VirtualBox API, not a
8738 physical lock of the underlying storage unit.
8739
8740 This method returns the current state of the medium
8741 <b>before</b> the operation.
8742
8743 <result name="VBOX_E_INVALID_OBJECT_STATE">
8744 Invalid media state (e.g. not created, locked, inaccessible,
8745 creating, deleting).
8746 </result>
8747
8748 </desc>
8749 <param name="state" type="MediaState" dir="return">
8750 <desc>
8751 State of the medium after the operation.
8752 </desc>
8753 </param>
8754 </method>
8755
8756 <method name="unlockRead">
8757 <desc>
8758 Cancels the read lock previously set by <link to="#lockRead"/>.
8759
8760 For both, success and failure, this method returns the current state
8761 of the medium <b>after</b> the operation.
8762
8763 See <link to="#lockRead"/> for more details.
8764
8765 <result name="VBOX_E_INVALID_OBJECT_STATE">
8766 Medium not locked for reading.
8767 </result>
8768
8769 </desc>
8770 <param name="state" type="MediaState" dir="return">
8771 <desc>
8772 State of the medium after the operation.
8773 </desc>
8774 </param>
8775 </method>
8776
8777 <method name="lockWrite">
8778 <desc>
8779 Locks this medium for writing.
8780
8781 The write lock, as opposed to <link to="#lockRead"/>, is
8782 exclusive: there may be only one client holding a write lock
8783 and there may be no read locks while the write lock is held.
8784
8785 When the medium is locked for writing, it cannot be modified
8786 from within VirtualBox and it is not guaranteed that the values
8787 of its properties are up-to-date. Any method that changes the
8788 properties of this medium or contents of the storage unit will
8789 return an error (unless explicitly stated otherwise) and an
8790 attempt to start a virtual machine wanting to modify or to
8791 read the medium will fail.
8792
8793 When the virtual machine is started up, it locks for writing all
8794 media it uses to write data to. If any medium could not be locked
8795 for writing, the startup procedure will fail.
8796
8797 The medium locked for writing must be unlocked using the <link
8798 to="#unlockWrite"/> method. Calls to <link to="#lockWrite"/>
8799 can <b>not</b> be nested and must be followed by a<link
8800 to="#unlockWrite"/> call before the next lockWrite call.
8801
8802 This method sets the media state to <link to="MediaState_LockedWrite" />
8803 on success. The state prior to this call must be <link to="MediaState_Created"/>
8804 or <link to="MediaState_Inaccessible"/>. As you can see, inaccessible
8805 media can be locked too. This is not an error; this method
8806 performs a logical lock preventing modifications of this
8807 media through the VirtualBox API, not a physical lock of the
8808 underlying storage unit.
8809
8810 For both, success and failure, this method returns the current
8811 state of the medium <b>before</b> the operation.
8812
8813 <result name="VBOX_E_INVALID_OBJECT_STATE">
8814 Invalid media state (e.g. not created, locked, inaccessible,
8815 creating, deleting).
8816 </result>
8817
8818 </desc>
8819 <param name="state" type="MediaState" dir="return">
8820 <desc>
8821 State of the medium after the operation.
8822 </desc>
8823 </param>
8824 </method>
8825
8826 <method name="unlockWrite">
8827 <desc>
8828 Cancels the write lock previously set by <link to="#lockWrite"/>.
8829
8830 For both, success and failure, this method returns the current
8831 state of the medium <b>after</b> the operation.
8832
8833 See <link to="#lockWrite"/> for more details.
8834
8835 <result name="VBOX_E_INVALID_OBJECT_STATE">
8836 Medium not locked for writing.
8837 </result>
8838
8839 </desc>
8840 <param name="state" type="MediaState" dir="return">
8841 <desc>
8842 State of the medium after the operation.
8843 </desc>
8844 </param>
8845 </method>
8846
8847 <method name="close">
8848 <desc>
8849 Closes this medium.
8850
8851 The hard disk must not be attached to any known virtual machine
8852 and must not have any known child hard disks, otherwise the
8853 operation will fail.
8854
8855 When the hard disk is successfully closed, it gets removed from
8856 the list of remembered hard disks, but its storage unit is not
8857 deleted. In particular, this means that this hard disk can be
8858 later opened again using the <link
8859 to="IVirtualBox::openHardDisk"/> call.
8860
8861 Note that after this method successfully returns, the given hard
8862 disk object becomes uninitialized. This means that any attempt
8863 to call any of its methods or attributes will fail with the
8864 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error.
8865
8866 <result name="VBOX_E_INVALID_OBJECT_STATE">
8867 Invalid media state (other than not created, created or
8868 inaccessible).
8869 </result>
8870 <result name="VBOX_E_OBJECT_IN_USE">
8871 Medium attached to virtual machine.
8872 </result>
8873 <result name="VBOX_E_FILE_ERROR">
8874 Settings file not accessible.
8875 </result>
8876 <result name="VBOX_E_XML_ERROR">
8877 Could not parse the settings file.
8878 </result>
8879
8880 </desc>
8881 </method>
8882
8883 </interface>
8884
8885
8886 <!--
8887 // IHardDisk
8888 /////////////////////////////////////////////////////////////////////////
8889 -->
8890
8891 <enum
8892 name="HardDiskType"
8893 uuid="a348fafd-a64e-4643-ba65-eb3896bd7e0a"
8894 >
8895 <desc>
8896 Virtual hard disk type.
8897 <see>IHardDisk</see>
8898 </desc>
8899
8900 <const name="Normal" value="0">
8901 <desc>
8902 Normal hard disk (attached directly or indirectly, preserved
8903 when taking snapshots).
8904 </desc>
8905 </const>
8906 <const name="Immutable" value="1">
8907 <desc>
8908 Immutable hard disk (attached indirectly, changes are wiped out
8909 after powering off the virtual machine).
8910 </desc>
8911 </const>
8912 <const name="Writethrough" value="2">
8913 <desc>
8914 Write through hard disk (attached directly, ignored when
8915 taking snapshots).
8916 </desc>
8917 </const>
8918 </enum>
8919
8920 <enum
8921 name="HardDiskVariant"
8922 uuid="eb7fc6b3-ae23-4c5d-a1f6-e3522dd1efb0"
8923 >
8924 <desc>
8925 Virtual hard disk image variant. More than one flag may be set.
8926 <see>IHardDisk</see>
8927 </desc>
8928
8929 <const name="Standard" value="0">
8930 <desc>
8931 No particular variant requested, results in using the backend default.
8932 </desc>
8933 </const>
8934 <const name="VmdkSplit2G" value="0x01">
8935 <desc>
8936 VMDK image split in chunks of less than 2GByte.
8937 </desc>
8938 </const>
8939 <const name="VmdkStreamOptimized" value="0x04">
8940 <desc>
8941 VMDK streamOptimized image. Special import/export format which is
8942 read-only/append-only.
8943 </desc>
8944 </const>
8945 <const name="VmdkESX" value="0x08">
8946 <desc>
8947 VMDK format variant used on ESX products.
8948 </desc>
8949 </const>
8950 <const name="Fixed" value="0x10000">
8951 <desc>
8952 Fixed image. Only allowed for base images.
8953 </desc>
8954 </const>
8955 <const name="Diff" value="0x20000">
8956 <desc>
8957 Fixed image. Only allowed for base images.
8958 </desc>
8959 </const>
8960 </enum>
8961
8962 <interface
8963 name="IHardDiskAttachment" extends="$unknown"
8964 uuid="b1dd04bb-93c0-4ad3-a9cf-82316e595836"
8965 wsmap="struct"
8966 >
8967 <desc>
8968 The IHardDiskAttachment interface represents a hard disk attachment of a
8969 virtual machine.
8970
8971 Every hard disk attachment specifies a slot of the virtual hard disk
8972 controller and a virtual hard disk attached to this slot.
8973
8974 The array of hard disk attachments is returned by
8975 <link to="IMachine::hardDiskAttachments"/>.
8976 </desc>
8977 <attribute name="hardDisk" type="IHardDisk" readonly="yes">
8978 <desc>Hard disk object associated with this attachment.</desc>
8979 </attribute>
8980
8981 <attribute name="controller" type="wstring" readonly="yes">
8982 <desc>Interface bus of this attachment.</desc>
8983 </attribute>
8984
8985 <attribute name="port" type="long" readonly="yes">
8986 <desc>Port number of this attachment.</desc>
8987 </attribute>
8988
8989 <attribute name="device" type="long" readonly="yes">
8990 <desc>Device slot number of this attachment.</desc>
8991 </attribute>
8992
8993 </interface>
8994
8995 <interface
8996 name="IHardDisk" extends="IMedium"
8997 uuid="62551115-83b8-4d20-925f-79e9d3c00f96"
8998 wsmap="managed"
8999 >
9000 <desc>
9001 The IHardDisk interface represents a virtual hard disk drive
9002 used by a virtual machine. This is a subclass of <link to="IMedium" />; see remarks there.
9003
9004 <h3>Hard Disk Types</h3>
9005
9006 There are three types of hard disks:
9007 <link to="HardDiskType_Normal">Normal</link>,
9008 <link to="HardDiskType_Immutable">Immutable</link> and
9009 <link to="HardDiskType_Writethrough">Writethrough</link>. The type of the
9010 hard disk defines how the hard disk is attached to a virtual machine and
9011 what happens when a <link to="ISnapshot">snapshot</link> of the virtual
9012 machine with the attached hard disk is taken. The type of the hard disk is
9013 defined by the <link to="#type"/> attribute.
9014
9015 All hard disks can be also divided in two groups: <i>base</i> hard
9016 disks and <i>differencing</i> hard disks. A base hard disk contains all
9017 sectors of the hard disk data in its own storage and therefore can be
9018 used independently. On the contrary, a differencing hard disk is a
9019 "delta" to some other disk and contains only those sectors which differ
9020 from that other disk, which is then called a <i>parent</i>. The differencing
9021 hard disk is said to be <i>linked to</i> that parent.
9022 The parent may be itself a differencing image, thus forming a chain of
9023 linked hard disks. The last element in that chain (sometimes referred to as
9024 the root hard disk) must always be a base. Note that several differencing
9025 hard disks may be linked to the same parent hard disk.
9026
9027 Differencing hard disks can be distinguished from base hard disks by
9028 querying the <link to="#parent"/> attribute: base hard disks do not have
9029 parents they would depend on, so the value of this attribute is always
9030 <tt>null</tt> for them. Using this attribute, it is possible to walk up
9031 the hard disk tree (from the child hard disk to its parent). It is also
9032 possible to walk down the tree using the <link to="#children"/>
9033 attribute.
9034
9035 Note that the type of all differencing hard disks is
9036 <link to="HardDiskType_Normal" />; all other values are
9037 meaningless for them. Base hard disks may be of any type.
9038
9039 <h3>Creating Hard Disks</h3>
9040
9041 New base hard disks are created using
9042 <link to="IVirtualBox::createHardDisk"/>. Existing hard disks are
9043 opened using <link to="IVirtualBox::openHardDisk"/>. Differencing hard
9044 disks are usually implicitly created by VirtualBox when needed but may
9045 also be created explicitly using <link to="#createDiffStorage"/>.
9046
9047 After the hard disk is successfully created (including the storage unit)
9048 or opened, it becomes a known hard disk (remembered in the internal media
9049 registry). Known hard disks can be attached to a virtual machine, accessed
9050 through <link to="IVirtualBox::getHardDisk"/> and
9051 <link to="IVirtualBox::findHardDisk"/> methods or enumerated using the
9052 <link to="IVirtualBox::hardDisks"/> array (only for base hard disks).
9053
9054 The following methods, besides <link to="IMedium::close"/>,
9055 automatically remove the hard disk from the media registry:
9056 <ul>
9057 <li><link to="#deleteStorage"/></li>
9058 <li><link to="#mergeTo"/></li>
9059 </ul>
9060
9061 If the storage unit of the hard disk is a regular file in the host's
9062 file system then the rules stated in the description of the
9063 <link to="IMedium::location"/> attribute apply when setting its value. In
9064 addition, a plain file name without any path may be given, in which case
9065 the <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
9066 folder</link> will be prepended to it.
9067
9068 <h4>Automatic composition of the file name part</h4>
9069
9070 Another extension to the <link to="IMedium::location"/> attribute is that
9071 there is a possibility to cause VirtualBox to compose a unique value for
9072 the file name part of the location using the UUID of the hard disk. This
9073 applies only to hard disks in <link to="MediaState_NotCreated"/> state,
9074 e.g. before the storage unit is created, and works as follows. You set the
9075 value of the <link to="IMedium::location"/> attribute to a location
9076 specification which only contains the path specification but not the file
9077 name part and ends with either a forward slash or a backslash character.
9078 In response, VirtualBox will generate a new UUID for the hard disk and
9079 compose the file name using the following pattern:
9080 <pre>
9081 &lt;path&gt;/{&lt;uuid&gt;}.&lt;ext&gt;
9082 </pre>
9083 where <tt>&lt;path&gt;</tt> is the supplied path specification,
9084 <tt>&lt;uuid&gt;</tt> is the newly generated UUID and <tt>&lt;ext&gt;</tt>
9085 is the default extension for the storage format of this hard disk. After
9086 that, you may call any of the methods that create a new hard disk storage
9087 unit and they will use the generated UUID and file name.
9088
9089 <h3>Attaching Hard Disks</h3>
9090
9091 Hard disks are attached to virtual machines using the
9092 <link to="IMachine::attachHardDisk"/> method and detached using the
9093 <link to="IMachine::detachHardDisk"/> method. Depending on their
9094 <link to="#type"/>, hard disks are attached either
9095 <i>directly</i> or <i>indirectly</i>.
9096
9097 When a hard disk is being attached directly, it is associated with the
9098 virtual machine and used for hard disk operations when the machine is
9099 running. When a hard disk is being attached indirectly, a new differencing
9100 hard disk linked to it is implicitly created and this differencing hard
9101 disk is associated with the machine and used for hard disk operations.
9102 This also means that if <link to="IMachine::attachHardDisk"/> performs
9103 a direct attachment then the same hard disk will be returned in response
9104 to the subsequent <link to="IMachine::getHardDisk"/> call; however if
9105 an indirect attachment is performed then
9106 <link to="IMachine::getHardDisk"/> will return the implicitly created
9107 differencing hard disk, not the original one passed to <link
9108 to="IMachine::attachHardDisk"/>. The following table shows the
9109 dependency of the attachment type on the hard disk type:
9110
9111 <table>
9112 <tr>
9113 <th>Hard Disk Type</th>
9114 <th>Direct or Indirect?</th>
9115 </tr>
9116 <tr>
9117 <td>Normal (Base)</td>
9118 <td>
9119 Normal base hard disks that do not have children (i.e. differencing
9120 hard disks linked to them) and that are not already attached to
9121 virtual machines in snapshots are attached <b>directly</b>.
9122 Otherwise, they are attached <b>indirectly</b> because having
9123 dependent children or being part of the snapshot makes it impossible
9124 to modify hard disk contents without breaking the integrity of the
9125 dependent party. The <link to="#readOnly"/> attribute allows to
9126 quickly determine the kind of the attachment for the given hard
9127 disk. Note that if a normal base hard disk is to be indirectly
9128 attached to a virtual machine with snapshots then a special
9129 procedure called <i>smart attachment</i> is performed (see below).
9130 </td>
9131 </tr>
9132 <tr>
9133 <td>Normal (Differencing)</td>
9134 <td>
9135 Differencing hard disks are like normal base hard disks: attached
9136 <b>directly</b> if they do not have children and are not attached to
9137 virtual machines in snapshots, and <b>indirectly</b> otherwise. Note
9138 that the smart attachment procedure is never performed for
9139 differencing hard disks.
9140 </td>
9141 </tr>
9142 <tr>
9143 <td>Immutable</td>
9144 <td>
9145 Immutable hard disks are always attached <b>indirectly</b> because
9146 they are designed to be non-writable. If an immutable hard disk is
9147 attached to a virtual machine with snapshots then a special
9148 procedure called smart attachment is performed (see below).
9149 </td>
9150 </tr>
9151 <tr>
9152 <td>Writethrough</td>
9153 <td>
9154 Writethrough hard disks are always attached <b>directly</b>, also as
9155 designed. This also means that writethrough hard disks cannot have
9156 other hard disks linked to them at all.
9157 </td>
9158 </tr>
9159 </table>
9160
9161 Note that the same hard disk, regardless of its type, may be attached to
9162 more than one virtual machine at a time. In this case, the machine that is
9163 started first gains exclusive access to the hard disk and attempts to
9164 start other machines having this hard disk attached will fail until the
9165 first machine is powered down.
9166
9167 Detaching hard disks is performed in a <i>deferred</i> fashion. This means
9168 that the given hard disk remains associated with the given machine after a
9169 successful <link to="IMachine::detachHardDisk"/> call until
9170 <link to="IMachine::saveSettings"/> is called to save all changes to
9171 machine settings to disk. This deferring is necessary to guarantee that
9172 the hard disk configuration may be restored at any time by a call to
9173 <link to="IMachine::discardSettings"/> before the settings
9174 are saved (committed).
9175
9176 Note that if <link to="IMachine::discardSettings"/> is called after
9177 indirectly attaching some hard disks to the machine but before a call to
9178 <link to="IMachine::saveSettings"/> is made, it will implicitly delete
9179 all differencing hard disks implicitly created by
9180 <link to="IMachine::attachHardDisk"/> for these indirect attachments.
9181 Such implicitly created hard disks will also be immediately deleted when
9182 detached explicitly using the <link to="IMachine::detachHardDisk"/>
9183 call if it is made before <link to="IMachine::saveSettings"/>. This
9184 implicit deletion is safe because newly created differencing hard
9185 disks do not contain any user data.
9186
9187 However, keep in mind that detaching differencing hard disks that were
9188 implicitly created by <link to="IMachine::attachHardDisk"/>
9189 before the last <link to="IMachine::saveSettings"/> call will
9190 <b>not</b> implicitly delete them as they may already contain some data
9191 (for example, as a result of virtual machine execution). If these hard
9192 disks are no more necessary, the caller can always delete them explicitly
9193 using <link to="#deleteStorage"/> after they are actually de-associated
9194 from this machine by the <link to="IMachine::saveSettings"/> call.
9195
9196 <h3>Smart Attachment</h3>
9197
9198 When normal base or immutable hard disks are indirectly attached to a
9199 virtual machine then some additional steps are performed to make sure the
9200 virtual machine will have the most recent "view" of the hard disk being
9201 attached. These steps include walking through the machine's snapshots
9202 starting from the current one and going through ancestors up to the first
9203 snapshot. Hard disks attached to the virtual machine in all
9204 of the encountered snapshots are checked whether they are descendants of
9205 the given normal base or immutable hard disk. The first found child (which
9206 is the differencing hard disk) will be used instead of the normal base or
9207 immutable hard disk as a parent for creating a new differencing hard disk
9208 that will be actually attached to the machine. And only if no descendants
9209 are found or if the virtual machine does not have any snapshots then the
9210 normal base or immutable hard disk will be used itself as a parent for
9211 this differencing hard disk.
9212
9213 It is easier to explain what smart attachment does using the
9214 following example:
9215 <pre>
9216BEFORE attaching B.vdi: AFTER attaching B.vdi:
9217
9218Snapshot 1 (B.vdi) Snapshot 1 (B.vdi)
9219 Snapshot 2 (D1->B.vdi) Snapshot 2 (D1->B.vdi)
9220 Snapshot 3 (D2->D1.vdi) Snapshot 3 (D2->D1.vdi)
9221 Snapshot 4 (none) Snapshot 4 (none)
9222 CurState (none) CurState (D3->D2.vdi)
9223
9224 NOT
9225 ...
9226 CurState (D3->B.vdi)
9227 </pre>
9228 The first column is the virtual machine configuration before the base hard
9229 disk <tt>B.vdi</tt> is attached, the second column shows the machine after
9230 this hard disk is attached. Constructs like <tt>D1->B.vdi</tt> and similar
9231 mean that the hard disk that is actually attached to the machine is a
9232 differencing hard disk, <tt>D1.vdi</tt>, which is linked to (based on)
9233 another hard disk, <tt>B.vdi</tt>.
9234
9235 As we can see from the example, the hard disk <tt>B.vdi</tt> was detached
9236 from the machine before taking Snapshot 4. Later, after Snapshot 4 was
9237 taken, the user decides to attach <tt>B.vdi</tt> again. <tt>B.vdi</tt> has
9238 dependent child hard disks (<tt>D1.vdi</tt>, <tt>D2.vdi</tt>), therefore
9239 it cannot be attached directly and needs an indirect attachment (i.e.
9240 implicit creation of a new differencing hard disk). Due to the smart
9241 attachment procedure, the new differencing hard disk
9242 (<tt>D3.vdi</tt>) will be based on <tt>D2.vdi</tt>, not on
9243 <tt>B.vdi</tt> itself, since <tt>D2.vdi</tt> is the most recent view of
9244 <tt>B.vdi</tt> existing for this snapshot branch of the given virtual
9245 machine.
9246
9247 Note that if there is more than one descendant hard disk of the given base
9248 hard disk found in a snapshot, and there is an exact device, channel and
9249 bus match, then this exact match will be used. Otherwise, the youngest
9250 descendant will be picked up.
9251
9252 There is one more important aspect of the smart attachment procedure which
9253 is not related to snapshots at all. Before walking through the snapshots
9254 as described above, the backup copy of the current list of hard disk
9255 attachment is searched for descendants. This backup copy is created when
9256 the hard disk configuration is changed for the first time after the last
9257 <link to="IMachine::saveSettings"/> call and used by
9258 <link to="IMachine::discardSettings"/> to undo the recent hard disk
9259 changes. When such a descendant is found in this backup copy, it will be
9260 simply re-attached back, without creating a new differencing hard disk for
9261 it. This optimization is necessary to make it possible to re-attach the
9262 base or immutable hard disk to a different bus, channel or device slot
9263 without losing the contents of the differencing hard disk actually
9264 attached to the machine in place of it.
9265 </desc>
9266
9267 <attribute name="format" type="wstring" readonly="yes">
9268 <desc>
9269 Storage format of this hard disk.
9270
9271 The value of this attribute is a string that specifies a backend used to
9272 store hard disk data. The storage format is defined when you create a
9273 new hard disk or automatically detected when you open an existing hard
9274 disk medium, and cannot be changed later.
9275
9276 The list of all storage formats supported by this VirtualBox
9277 installation can be obtained using
9278 <link to="ISystemProperties::hardDiskFormats"/>.
9279 </desc>
9280 </attribute>
9281
9282 <attribute name="type" type="HardDiskType">
9283 <desc>
9284 Type (role) of this hard disk.
9285
9286 The following constraints apply when changing the value of this
9287 attribute:
9288 <ul>
9289 <li>If a hard disk is attached to a virtual machine (either in the
9290 current state or in one of the snapshots), its type cannot be
9291 changed.
9292 </li>
9293 <li>As long as the hard disk has children, its type cannot be set
9294 to <link to="HardDiskType_Writethrough"/>.
9295 </li>
9296 <li>The type of all differencing hard disks is
9297 <link to="HardDiskType_Normal"/> and cannot be changed.
9298 </li>
9299 </ul>
9300
9301 The type of a newly created or opened hard disk is set to
9302 <link to="HardDiskType_Normal"/>.
9303 </desc>
9304 </attribute>
9305
9306 <attribute name="parent" type="IHardDisk" readonly="yes">
9307 <desc>
9308 Parent of this hard disk (a hard disk this hard disk is directly based
9309 on).
9310
9311 Only differencing hard disks have parents. For base (non-differencing)
9312 hard disks, <tt>null</tt> is returned.
9313 </desc>
9314 </attribute>
9315
9316 <attribute name="children" type="IHardDisk" safearray="yes" readonly="yes">
9317 <desc>
9318 Children of this hard disk (all differencing hard disks directly based
9319 on this hard disk). A <tt>null</tt> array is returned if this hard disk
9320 does not have any children.
9321 </desc>
9322 </attribute>
9323
9324 <attribute name="root" type="IHardDisk" readonly="yes">
9325 <desc>
9326 Root hard disk of this hard disk.
9327
9328 If this is a differencing hard disk, its root hard disk is the base hard
9329 disk the given hard disk branch starts from. For all other types of hard
9330 disks, this property returns the hard disk object itself (i.e. the same
9331 object this property is read on).
9332 </desc>
9333 </attribute>
9334
9335 <attribute name="readOnly" type="boolean" readonly="yes">
9336 <desc>
9337 Returns <tt>true</tt> if this hard disk is read-only and <tt>false</tt>
9338 otherwise.
9339
9340 A hard disk is considered to be read-only when its contents cannot be
9341 modified without breaking the integrity of other parties that depend on
9342 this hard disk such as its child hard disks or snapshots of virtual
9343 machines where this hard disk is attached to these machines. If there
9344 are no children and no such snapshots then there is no dependency and
9345 the hard disk is not read-only.
9346
9347 The value of this attribute can be used to determine the kind of the
9348 attachment that will take place when attaching this hard disk to a
9349 virtual machine. If the value is <tt>false</tt> then the hard disk will
9350 be attached directly. If the value is <tt>true</tt> then the hard disk
9351 will be attached indirectly by creating a new differencing child hard
9352 disk for that. See the interface description for more information.
9353
9354 Note that all <link to="HardDiskType_Immutable">Immutable</link> hard
9355 disks are always read-only while all
9356 <link to="HardDiskType_Writethrough">Writethrough</link> hard disks are
9357 always not.
9358
9359 <note>
9360 The read-only condition represented by this attribute is related to
9361 the hard disk type and usage, not to the current
9362 <link to="IMedium::state">media state</link> and not to the read-only
9363 state of the storage unit.
9364 </note>
9365 </desc>
9366 </attribute>
9367
9368 <attribute name="logicalSize" type="unsigned long long" readonly="yes">
9369 <desc>
9370 Logical size of this hard disk (in megabytes), as reported to the
9371 guest OS running inside the virtual machine this disk is
9372 attached to. The logical size is defined when the hard disk is created
9373 and cannot be changed later.
9374
9375 <note>
9376 Reading this property on a differencing hard disk will return the size
9377 of its <link to="#root"/> hard disk.
9378 </note>
9379 <note>
9380 For hard disks whose state is <link to="#state"/> is <link
9381 to="MediaState_Inaccessible"/>, the value of this property is the
9382 last known logical size. For <link to="MediaState_NotCreated"/> hard
9383 disks, the returned value is zero.
9384 </note>
9385 </desc>
9386 </attribute>
9387
9388 <attribute name="autoReset" type="boolean">
9389 <desc>
9390 Whether this differencing hard disk will be automatically reset each
9391 time a virtual machine it is attached to is powered up.
9392
9393 See <link to="#reset()"/> for more information about resetting
9394 differencing hard disks.
9395
9396 <note>
9397 Reading this property on a base (non-differencing) hard disk will
9398 always <tt>false</tt>. Changing the value of this property in this
9399 case is not supported.
9400 </note>
9401
9402 <result name="VBOX_E_NOT_SUPPORTED">
9403 This is not a differencing hard disk (when changing the attribute
9404 value).
9405 </result>
9406 </desc>
9407 </attribute>
9408
9409 <!-- storage methods -->
9410
9411 <method name="getProperty">
9412 <desc>
9413 Returns the value of the custom hard disk property with the given name.
9414
9415 The list of all properties supported by the given hard disk format can
9416 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9417
9418 Note that if this method returns a <tt>null</tt> @a value, the requested
9419 property is supported but currently not assigned any value.
9420
9421 <result name="VBOX_E_OBJECT_NOT_FOUND">
9422 Requested property does not exist (not supported by the format).
9423 </result>
9424 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
9425 </desc>
9426 <param name="name" type="wstring" dir="in">
9427 <desc>Name of the property to get.</desc>
9428 </param>
9429 <param name="value" type="wstring" dir="return">
9430 <desc>Current property value.</desc>
9431 </param>
9432 </method>
9433
9434 <method name="setProperty">
9435 <desc>
9436 Sets the value of the custom hard disk property with the given name.
9437
9438 The list of all properties supported by the given hard disk format can
9439 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9440
9441 Note that setting the property value to <tt>null</tt> is equivalent to
9442 deleting the existing value. A default value (if it is defined for this
9443 property) will be used by the format backend in this case.
9444
9445 <result name="VBOX_E_OBJECT_NOT_FOUND">
9446 Requested property does not exist (not supported by the format).
9447 </result>
9448 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
9449 </desc>
9450 <param name="name" type="wstring" dir="in">
9451 <desc>Name of the property to set.</desc>
9452 </param>
9453 <param name="value" type="wstring" dir="in">
9454 <desc>Property value to set.</desc>
9455 </param>
9456 </method>
9457
9458 <method name="getProperties">
9459 <desc>
9460 Returns values for a group of properties in one call.
9461
9462 The names of the properties to get are specified using the @a names
9463 argument which is a list of comma-separated property names or
9464 <tt>null</tt> if all properties are to be returned. Note that currently
9465 the value of this argument is ignored and the method always returns all
9466 existing properties.
9467
9468 The list of all properties supported by the given hard disk format can
9469 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9470
9471 The method returns two arrays, the array of property names corresponding
9472 to the @a names argument and the current values of these properties.
9473 Both arrays have the same number of elements with each elemend at the
9474 given index in the first array corresponds to an element at the same
9475 index in the second array.
9476
9477 Note that for properties that do not have assigned values,
9478 <tt>null</tt> is returned at the appropriate index in the
9479 @a returnValues array.
9480
9481 </desc>
9482 <param name="names" type="wstring" dir="in">
9483 <desc>
9484 Names of properties to get.
9485 </desc>
9486 </param>
9487 <param name="returnNames" type="wstring" safearray="yes" dir="out">
9488 <desc>Names of returned properties.</desc>
9489 </param>
9490 <param name="returnValues" type="wstring" safearray="yes" dir="return">
9491 <desc>Values of returned properties.</desc>
9492 </param>
9493 </method>
9494
9495 <method name="setProperties">
9496 <desc>
9497 Sets values for a group of properties in one call.
9498
9499 The names of the properties to set are passed in the @a names
9500 array along with the new values for them in the @a values array. Both
9501 arrays have the same number of elements with each elemend at the given
9502 index in the first array corresponding to an element at the same index
9503 in the second array.
9504
9505 If there is at least one property name in @a names that is not valid,
9506 the method will fail before changing the values of any other properties
9507 from the @a names array.
9508
9509 Using this method over <link to="#setProperty"/> is preferred if you
9510 need to set several properties at once since it will result into less
9511 IPC calls.
9512
9513 The list of all properties supported by the given hard disk format can
9514 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9515
9516 Note that setting the property value to <tt>null</tt> is equivalent to
9517 deleting the existing value. A default value (if it is defined for this
9518 property) will be used by the format backend in this case.
9519 </desc>
9520 <param name="names" type="wstring" safearray="yes" dir="in">
9521 <desc>Names of properties to set.</desc>
9522 </param>
9523 <param name="values" type="wstring" safearray="yes" dir="in">
9524 <desc>Values of properties to set.</desc>
9525 </param>
9526 </method>
9527
9528 <!-- storage methods -->
9529
9530 <method name="createBaseStorage">
9531 <desc>
9532 Starts creating a hard disk storage unit (fixed/dynamic, according
9533 to the variant flags) in in the background. The previous storage unit
9534 created for this object, if any, must first be deleted using
9535 <link to="#deleteStorage"/>, otherwise the operation will fail.
9536
9537 Before the operation starts, the hard disk is placed in
9538 <link to="MediaState_Creating"/> state. If the create operation
9539 fails, the media will be placed back in <link to="MediaState_NotCreated"/>
9540 state.
9541
9542 After the returned progress object reports that the operation has
9543 successfully completed, the media state will be set to <link
9544 to="MediaState_Created"/>, the hard disk will be remembered by this
9545 VirtualBox installation and may be attached to virtual machines.
9546
9547 <result name="VBOX_E_NOT_SUPPORTED">
9548 The variant of storage creation operation is not supported. See <link
9549 to="IHardDiskFormat::capabilities"/>.
9550 </result>
9551 </desc>
9552 <param name="logicalSize" type="unsigned long long" dir="in">
9553 <desc>Maximum logical size of the hard disk in megabytes.</desc>
9554 </param>
9555 <param name="variant" type="HardDiskVariant" dir="in">
9556 <desc>Exact image variant which should be created.</desc>
9557 </param>
9558 <param name="progress" type="IProgress" dir="return">
9559 <desc>Progress object to track the operation completion.</desc>
9560 </param>
9561 </method>
9562
9563 <method name="deleteStorage">
9564 <desc>
9565 Starts deleting the storage unit of this hard disk.
9566
9567 The hard disk must not be attached to any known virtual machine and must
9568 not have any known child hard disks, otherwise the operation will fail.
9569 It will also fail if there is no storage unit to delete or if deletion
9570 is already in progress, or if the hard disk is being in use (locked for
9571 read or for write) or inaccessible. Therefore, the only valid state for
9572 this operation to succeed is <link to="MediaState_Created"/>.
9573
9574 Before the operation starts, the hard disk is placed to
9575 <link to="MediaState_Deleting"/> state and gets removed from the list
9576 of remembered hard disks (media registry). If the delete operation
9577 fails, the media will be remembered again and placed back to
9578 <link to="MediaState_Created"/> state.
9579
9580 After the returned progress object reports that the operation is
9581 complete, the media state will be set to
9582 <link to="MediaState_NotCreated"/> and you will be able to use one of
9583 the storage creation methods to create it again.
9584
9585 <see>#close()</see>
9586
9587 <result name="VBOX_E_OBJECT_IN_USE">
9588 Hard disk is attached to a virtual machine.
9589 </result>
9590 <result name="VBOX_E_NOT_SUPPORTED">
9591 Storage deletion is not allowed because neither of storage creation
9592 operations are supported. See
9593 <link to="IHardDiskFormat::capabilities"/>.
9594 </result>
9595
9596 <note>
9597 If the deletion operation fails, it is not guaranteed that the storage
9598 unit still exists. You may check the <link to="IMedium::state"/> value
9599 to answer this question.
9600 </note>
9601 </desc>
9602 <param name="progress" type="IProgress" dir="return">
9603 <desc>Progress object to track the operation completion.</desc>
9604 </param>
9605 </method>
9606
9607 <!-- diff methods -->
9608
9609 <method name="createDiffStorage">
9610 <desc>
9611 Starts creating an empty differencing storage unit based on this hard
9612 disk in the format and at the location defined by the @a target
9613 argument.
9614
9615 The target hard disk must be in <link to="MediaState_NotCreated"/>
9616 state (i.e. must not have an existing storage unit). Upon successful
9617 completion, this operation will set the type of the target hard disk to
9618 <link to="HardDiskType_Normal"/> and create a storage unit necessary to
9619 represent the differencing hard disk data in the given format (according
9620 to the storage format of the target object).
9621
9622 After the returned progress object reports that the operation is
9623 successfully complete, the target hard disk gets remembered by this
9624 VirtualBox installation and may be attached to virtual machines.
9625
9626 <note>
9627 The hard disk will be set to <link to="MediaState_LockedRead"/>
9628 state for the duration of this operation.
9629 </note>
9630 <result name="VBOX_E_OBJECT_IN_USE">
9631 Hard disk not in NotCreated state.
9632 </result>
9633 </desc>
9634 <param name="target" type="IHardDisk" dir="in">
9635 <desc>Target hard disk.</desc>
9636 </param>
9637 <param name="variant" type="HardDiskVariant" dir="in">
9638 <desc>Exact image variant which should be created.</desc>
9639 </param>
9640 <param name="progress" type="IProgress" dir="return">
9641 <desc>Progress object to track the operation completion.</desc>
9642 </param>
9643 </method>
9644
9645 <method name="mergeTo">
9646 <desc>
9647 Starts merging the contents of this hard disk and all intermediate
9648 differencing hard disks in the chain to the given target hard disk.
9649
9650 The target hard disk must be either a descendant of this hard disk or
9651 its ancestor (otherwise this method will immediately return a failure).
9652 It follows that there are two logical directions of the merge operation:
9653 from ancestor to descendant (<i>forward merge</i>) and from descendant to
9654 ancestor (<i>backward merge</i>). Let us consider the following hard disk
9655 chain:
9656
9657 <pre>Base &lt;- Diff_1 &lt;- Diff_2</pre>
9658
9659 Here, calling this method on the <tt>Base</tt> hard disk object with
9660 <tt>Diff_2</tt> as an argument will be a forward merge; calling it on
9661 <tt>Diff_2</tt> with <tt>Base</tt> as an argument will be a backward
9662 merge. Note that in both cases the contents of the resulting hard disk
9663 will be the same, the only difference is the hard disk object that takes
9664 the result of the merge operation. In case of the forward merge in the
9665 above example, the result will be written to <tt>Diff_2</tt>; in case of
9666 the backward merge, the result will be written to <tt>Base</tt>. In
9667 other words, the result of the operation is always stored in the target
9668 hard disk.
9669
9670 Upon successful operation completion, the storage units of all hard
9671 disks in the chain between this (source) hard disk and the target hard
9672 disk, including the source hard disk itself, will be automatically
9673 deleted and the relevant hard disk objects (including this hard disk)
9674 will become uninitialized. This means that any attempt to call any of
9675 their methods or attributes will fail with the
9676 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error. Applied to the above
9677 example, the forward merge of <tt>Base</tt> to <tt>Diff_2</tt> will
9678 delete and uninitialize both <tt>Base</tt> and <tt>Diff_1</tt> hard
9679 disks. Note that <tt>Diff_2</tt> in this case will become a base hard
9680 disk itself since it will no longer be based on any other hard disk.
9681
9682 Considering the above, all of the following conditions must be met in
9683 order for the merge operation to succeed:
9684 <ul>
9685 <li>
9686 Neither this (source) hard disk nor any intermediate
9687 differencing hard disk in the chain between it and the target
9688 hard disk is attached to any virtual machine.
9689 </li>
9690 <li>
9691 Neither the source hard disk nor the target hard disk is an
9692 <link to="HardDiskType_Immutable"/> hard disk.
9693 </li>
9694 <li>
9695 The part of the hard disk tree from the source hard disk to the
9696 target hard disk is a linear chain, i.e. all hard disks in this
9697 chain have exactly one child which is the next hard disk in this
9698 chain. The only exception from this rule is the target hard disk in
9699 the forward merge operation; it is allowed to have any number of
9700 child hard disks because the merge operation will hot change its
9701 logical contents (as it is seen by the guest OS or by children).
9702 </li>
9703 <li>
9704 None of the involved hard disks are in
9705 <link to="MediaState_LockedRead"/> or
9706 <link to="MediaState_LockedWrite"/> state.
9707 </li>
9708 </ul>
9709
9710 <note>
9711 This (source) hard disk and all intermediates will be placed to <link
9712 to="MediaState_Deleting"/> state and the target hard disk will be
9713 placed to <link to="MediaState_LockedWrite"/> state and for the
9714 duration of this operation.
9715 </note>
9716 </desc>
9717 <param name="targetId" type="wstring" dir="in">
9718 <desc>UUID of the target ancestor or descendant hard disk.</desc>
9719 </param>
9720 <param name="progress" type="IProgress" dir="return">
9721 <desc>Progress object to track the operation completion.</desc>
9722 </param>
9723 </method>
9724
9725 <!-- clone method -->
9726
9727 <method name="cloneTo">
9728 <desc>
9729 Starts creating a clone of this hard disk in the format and at the
9730 location defined by the @a target argument.
9731
9732 The target hard disk must be in <link to="MediaState_NotCreated"/>
9733 state (i.e. must not have an existing storage unit). Upon successful
9734 completion, the cloned hard disk will contain exactly the same sector
9735 data as the hard disk being cloned, except that a new UUID for the
9736 clone will be randomly generated.
9737
9738 The @a parent argument defines which hard disk will be the parent
9739 of the clone. Passing a NULL reference indicates that the clone will
9740 be a base image, i.e. completely independent. It is possible to specify
9741 an arbitrary hard disk for this parameter, including the parent of the
9742 hard disk which is being cloned. Even cloning to a child of the source
9743 hard disk is possible.
9744
9745 After the returned progress object reports that the operation is
9746 successfully complete, the target hard disk gets remembered by this
9747 VirtualBox installation and may be attached to virtual machines.
9748
9749 <note>
9750 This hard disk will be placed to <link to="MediaState_LockedRead"/>
9751 state for the duration of this operation.
9752 </note>
9753 </desc>
9754 <param name="target" type="IHardDisk" dir="in">
9755 <desc>Target hard disk.</desc>
9756 </param>
9757 <param name="variant" type="HardDiskVariant" dir="in">
9758 <desc>Exact image variant which should be created.</desc>
9759 </param>
9760 <param name="parent" type="IHardDisk" dir="in">
9761 <desc>Parent of the cloned hard disk.</desc>
9762 </param>
9763 <param name="progress" type="IProgress" dir="return">
9764 <desc>Progress object to track the operation completion.</desc>
9765 </param>
9766 </method>
9767
9768 <!-- other methods -->
9769
9770 <method name="compact">
9771 <desc>
9772 Starts compacting of this hard disk. This means that the disk is
9773 transformed into a possibly more compact storage representation.
9774 This potentially creates temporary images, which can require a
9775 substantial amount of additional disk space.
9776
9777 This hard disk will be placed to <link to="MediaState_LockedWrite"/>
9778 state and all its parent hard disks (if any) will be placed to
9779 <link to="MediaState_LockedRead"/> state for the duration of this
9780 operation.
9781
9782 Please note that the results can be either returned straight away,
9783 or later as the result of the background operation via the object
9784 returned via the @a progress parameter.
9785
9786 <result name="VBOX_E_NOT_SUPPORTED">
9787 Hard disk format does not support compacting (but potentially
9788 needs it).
9789 </result>
9790 </desc>
9791 <param name="progress" type="IProgress" dir="return">
9792 <desc>Progress object to track the operation completion.</desc>
9793 </param>
9794 </method>
9795
9796 <method name="reset">
9797 <desc>
9798 Starts erasing the contents of this differencing hard disk.
9799
9800 This operation will reset the differencing hard disk to its initial
9801 state when it does not contain any sector data and any read operation is
9802 redirected to its parent hard disk.
9803
9804 This hard disk will be placed to <link to="MediaState_LockedWrite"/>
9805 for the duration of this operation.
9806
9807 <result name="VBOX_E_NOT_SUPPORTED">
9808 This is not a differencing hard disk.
9809 </result>
9810 <result name="VBOX_E_INVALID_OBJECT_STATE">
9811 Hard disk is not in <link to="MediaState_Created"/> or
9812 <link to="MediaState_Inaccessible"/> state.
9813 </result>
9814 </desc>
9815 <param name="progress" type="IProgress" dir="return">
9816 <desc>Progress object to track the operation completion.</desc>
9817 </param>
9818 </method>
9819
9820 </interface>
9821
9822
9823 <!--
9824 // IHardDiskFormat
9825 /////////////////////////////////////////////////////////////////////////
9826 -->
9827
9828 <enum
9829 name="DataType"
9830 uuid="d90ea51e-a3f1-4a01-beb1-c1723c0d3ba7"
9831 >
9832 <const name="Int32" value="0"/>
9833 <const name="Int8" value="1"/>
9834 <const name="String" value="2"/>
9835 </enum>
9836
9837 <enum
9838 name="DataFlags"
9839 uuid="86884dcf-1d6b-4f1b-b4bf-f5aa44959d60"
9840 >
9841 <const name="None" value="0x00"/>
9842 <const name="Mandatory" value="0x01"/>
9843 <const name="Expert" value="0x02"/>
9844 <const name="Array" value="0x04"/>
9845 <const name="FlagMask" value="0x07"/>
9846 </enum>
9847
9848 <enum
9849 name="HardDiskFormatCapabilities"
9850 uuid="1df1e4aa-d25a-4ba6-b2a2-02f60eb5903b"
9851 >
9852 <desc>
9853 Hard disk format capability flags.
9854 </desc>
9855
9856 <const name="Uuid" value="0x01">
9857 <desc>
9858 Supports UUIDs as expected by VirtualBox code.
9859 </desc>
9860 </const>
9861
9862 <const name="CreateFixed" value="0x02">
9863 <desc>
9864 Supports creating fixed size images, allocating all space instantly.
9865 </desc>
9866 </const>
9867
9868 <const name="CreateDynamic" value="0x04">
9869 <desc>
9870 Supports creating dynamically growing images, allocating space on
9871 demand.
9872 </desc>
9873 </const>
9874
9875 <const name="CreateSplit2G" value="0x08">
9876 <desc>
9877 Supports creating images split in chunks of a bit less than 2 GBytes.
9878 </desc>
9879 </const>
9880
9881 <const name="Differencing" value="0x10">
9882 <desc>
9883 Supports being used as a format for differencing hard disks (see <link
9884 to="IHardDisk::createDiffStorage"/>).
9885 </desc>
9886 </const>
9887
9888 <const name="Asynchronous" value="0x20">
9889 <desc>
9890 Supports asynchronous I/O operations for at least some configurations.
9891 </desc>
9892 </const>
9893
9894 <const name="File" value="0x40">
9895 <desc>
9896 The format backend operates on files (the <link to="IMedium::location"/>
9897 attribute of the hard disk specifies a file used to store hard disk
9898 data; for a list of supported file extensions see
9899 <link to="IHardDiskFormat::fileExtensions"/>).
9900 </desc>
9901 </const>
9902
9903 <const name="Properties" value="0x80">
9904 <desc>
9905 The format backend uses the property interface to configure the storage
9906 location and properties (the <link to="IHardDiskFormat::describeProperties"/>
9907 method is used to get access to properties supported by the given hard
9908 disk format).
9909 </desc>
9910 </const>
9911
9912 <const name="CapabilityMask" value="0xFF"/>
9913 </enum>
9914
9915 <interface
9916 name="IHardDiskFormat" extends="$unknown"
9917 uuid="7f3ba790-3a0b-4a8a-bac2-bb50150123c5"
9918 wsmap="managed"
9919 >
9920 <desc>
9921 The IHardDiskFormat interface represents a virtual hard disk format.
9922
9923 Each hard disk format has an associated backend which is used to handle
9924 hard disks stored in this format. This interface provides information
9925 about the properties of the associated backend.
9926
9927 Each hard disk format is identified by a string represented by the
9928 <link to="#id"/> attribute. This string is used in calls like
9929 <link to="IVirtualBox::createHardDisk"/> to specify the desired
9930 format.
9931
9932 The list of all supported hard disk formats can be obtained using
9933 <link to="ISystemProperties::hardDiskFormats"/>.
9934
9935 <see>IHardDisk</see>
9936 </desc>
9937
9938 <attribute name="id" type="wstring" readonly="yes">
9939 <desc>
9940 Identifier of this format.
9941
9942 The format identifier is a non-null non-empty ASCII string. Note that
9943 this string is case-insensitive. This means that, for example, all of
9944 the following strings:
9945 <pre>
9946 "VDI"
9947 "vdi"
9948 "VdI"</pre>
9949 refer to the same hard disk format.
9950
9951 This string is used in methods of other interfaces where it is necessary
9952 to specify a hard disk format, such as
9953 <link to="IVirtualBox::createHardDisk"/>.
9954 </desc>
9955 </attribute>
9956
9957 <attribute name="name" type="wstring" readonly="yes">
9958 <desc>
9959 Human readable description of this format.
9960
9961 Mainly for use in file open dialogs.
9962 </desc>
9963 </attribute>
9964
9965 <attribute name="fileExtensions" type="wstring" safearray="yes" readonly="yes">
9966 <desc>
9967 Array of strings containing the supported file extensions.
9968
9969 The first extension in the array is the extension preferred by the
9970 backend. It is recommended to use this extension when specifying a
9971 location of the storage unit for a new hard disk.
9972
9973 Note that some backends do not work on files, so this array may be
9974 empty.
9975
9976 <see>IHardDiskFormat::capabilities</see>
9977 </desc>
9978 </attribute>
9979
9980 <attribute name="capabilities" type="unsigned long" readonly="yes">
9981 <desc>
9982 Capabilities of the format as a set of bit flags.
9983
9984 For the meaning of individual capability flags see
9985 <link to="HardDiskFormatCapabilities"/>.
9986 </desc>
9987 </attribute>
9988
9989 <method name="describeProperties">
9990 <desc>
9991 Returns several arrays describing the properties supported by this
9992 format.
9993
9994 An element with the given index in each array describes one
9995 property. Thus, the number of elements in each returned array is the
9996 same and corresponds to the number of supported properties.
9997
9998 The returned arrays are filled in only if the
9999 <link to="HardDiskFormatCapabilities_Properties"/> flag is set.
10000 All arguments must be non-NULL.
10001
10002 <see>DataType</see>
10003 <see>DataFlags</see>
10004 </desc>
10005
10006 <param name="names" type="wstring" safearray="yes" dir="out">
10007 <desc>Array of property names.</desc>
10008 </param>
10009 <param name="description" type="wstring" safearray="yes" dir="out">
10010 <desc>Array of property descriptions.</desc>
10011 </param>
10012 <param name="types" type="DataType" safearray="yes" dir="out">
10013 <desc>Array of property types.</desc>
10014 </param>
10015 <param name="flags" type="unsigned long" safearray="yes" dir="out">
10016 <desc>Array of property flags.</desc>
10017 </param>
10018 <param name="defaults" type="wstring" safearray="yes" dir="out">
10019 <desc>Array of default property values.</desc>
10020 </param>
10021 </method>
10022
10023 </interface>
10024
10025
10026 <!--
10027 // IFloppyImage
10028 /////////////////////////////////////////////////////////////////////////
10029 -->
10030
10031 <interface
10032 name="IFloppyImage" extends="IMedium"
10033 uuid="faa6101f-078c-4b3a-ab75-75670c8170b3"
10034 wsmap="managed"
10035 >
10036 <desc>
10037 The IFloppyImage interface represents a medium containing the image
10038 of a floppy disk. This is a subclass of <link to="IMedium" />; see remarks there.
10039 </desc>
10040
10041 </interface>
10042
10043
10044 <!--
10045 // IDVDImage
10046 /////////////////////////////////////////////////////////////////////////
10047 -->
10048
10049 <interface
10050 name="IDVDImage" extends="IMedium"
10051 uuid="b1f90bbb-e8a9-4484-9af1-3638e943f763"
10052 wsmap="managed"
10053 >
10054 <desc>
10055 The IDVDImage interface represents a medium containing the image
10056 of a CD or DVD disk in the ISO format.
10057
10058 This is a subclass of <link to="IMedium" />; see remarks there.
10059 </desc>
10060
10061 </interface>
10062
10063
10064 <!--
10065 // IDVDDrive
10066 /////////////////////////////////////////////////////////////////////////
10067 -->
10068
10069 <interface
10070 name="IDVDDrive" extends="$unknown"
10071 uuid="156944d1-4c6d-4812-8f12-ab3890767ab4"
10072 wsmap="managed"
10073 >
10074 <desc>
10075 The IDVDDrive interface represents the virtual CD/DVD drive of the
10076 virtual machine. An object of this type is returned by
10077 <link to="IMachine::DVDDrive"/>.
10078 </desc>
10079
10080 <attribute name="state" type="DriveState" readonly="yes">
10081 <desc>Current drive state.</desc>
10082 </attribute>
10083
10084 <attribute name="passthrough" type="boolean">
10085 <desc>
10086 When a host drive is mounted and passthrough is enabled
10087 the guest OS will be able to directly send SCSI commands to
10088 the host drive. This enables the guest OS to use CD/DVD writers
10089 but is potentially dangerous.
10090 </desc>
10091 </attribute>
10092
10093 <method name="mountImage">
10094 <desc>Mounts a CD/DVD image with the specified UUID.
10095
10096 <result name="VBOX_E_FILE_ERROR">
10097 Invalid image file location.
10098 </result>
10099 <result name="VBOX_E_OBJECT_NOT_FOUND">
10100 Could not find a CD/DVD image matching @a imageId.
10101 </result>
10102 <result name="VBOX_E_INVALID_OBJECT_STATE">
10103 Invalid media state.
10104 </result>
10105
10106 </desc>
10107 <param name="imageId" type="wstring" dir="in"/>
10108 </method>
10109
10110 <method name="captureHostDrive">
10111 <desc>Captures the specified host CD/DVD drive.</desc>
10112 <param name="drive" type="IHostDVDDrive" dir="in"/>
10113 </method>
10114
10115 <method name="unmount">
10116 <desc>Unmounts the currently mounted image or host drive.</desc>
10117 </method>
10118
10119 <method name="getImage">
10120 <desc>Returns the currently mounted CD/DVD image.</desc>
10121 <param name="image" type="IDVDImage" dir="return"/>
10122 </method>
10123
10124 <method name="getHostDrive">
10125 <desc>Returns the currently mounted host CD/DVD drive.</desc>
10126 <param name="drive" type="IHostDVDDrive" dir="return"/>
10127 </method>
10128
10129 </interface>
10130
10131
10132 <!--
10133 // IFloppyDrive
10134 /////////////////////////////////////////////////////////////////////////
10135 -->
10136
10137 <interface
10138 name="IFloppyDrive" extends="$unknown"
10139 uuid="a8676d38-5cf0-4b53-85b1-aa693611ab86"
10140 wsmap="managed"
10141 >
10142 <desc>
10143 The IFloppyDrive interface represents the virtual floppy drive of the
10144 virtual machine. An object of this type is returned by
10145 <link to="IMachine::floppyDrive" />.
10146 </desc>
10147
10148 <attribute name="enabled" type="boolean">
10149 <desc>
10150 Flag whether the floppy drive is enabled. If it is disabled,
10151 the floppy drive will not be reported to the guest OS.
10152 </desc>
10153 </attribute>
10154
10155 <attribute name="state" type="DriveState" readonly="yes">
10156 <desc>Current drive state.</desc>
10157 </attribute>
10158
10159 <method name="mountImage">
10160 <desc>Mounts a floppy image with the specified UUID.
10161
10162 <result name="VBOX_E_FILE_ERROR">
10163 Invalid image file location.
10164 </result>
10165 <result name="VBOX_E_OBJECT_NOT_FOUND">
10166 Could not find a floppy image matching @a imageID.
10167 </result>
10168 <result name="VBOX_E_INVALID_OBJECT_STATE">
10169 Invalid media state.
10170 </result>
10171
10172 </desc>
10173 <param name="imageId" type="wstring" dir="in"/>
10174 </method>
10175
10176 <method name="captureHostDrive">
10177 <desc>Captures the specified host floppy drive.</desc>
10178 <param name="drive" type="IHostFloppyDrive" dir="in"/>
10179 </method>
10180
10181 <method name="unmount">
10182 <desc>Unmounts the currently mounted image or host drive.</desc>
10183 </method>
10184
10185 <method name="getImage">
10186 <desc>Returns the currently mounted floppy image.</desc>
10187 <param name="image" type="IFloppyImage" dir="return"/>
10188 </method>
10189
10190 <method name="getHostDrive">
10191 <desc>Returns the currently mounted host floppy drive.</desc>
10192 <param name="drive" type="IHostFloppyDrive" dir="return"/>
10193 </method>
10194
10195 </interface>
10196
10197
10198 <!--
10199 // IKeyboard
10200 /////////////////////////////////////////////////////////////////////////
10201 -->
10202
10203 <interface
10204 name="IKeyboard" extends="$unknown"
10205 uuid="2d1a531b-4c6e-49cc-8af6-5c857b78b5d7"
10206 wsmap="managed"
10207 >
10208 <desc>
10209 The IKeyboard interface represents the virtual machine's keyboard. Used
10210 in <link to="IConsole::keyboard"/>.
10211
10212 Use this interface to send keystrokes or the Ctrl-Alt-Del sequence
10213 to the virtual machine.
10214
10215 </desc>
10216 <method name="putScancode">
10217 <desc>Sends a scancode to the keyboard.
10218
10219 <result name="VBOX_E_IPRT_ERROR">
10220 Could not send scan code to virtual keyboard.
10221 </result>
10222
10223 </desc>
10224 <param name="scancode" type="long" dir="in"/>
10225 </method>
10226
10227 <method name="putScancodes">
10228 <desc>Sends an array of scancodes to the keyboard.
10229
10230 <result name="VBOX_E_IPRT_ERROR">
10231 Could not send all scan codes to virtual keyboard.
10232 </result>
10233
10234 </desc>
10235 <param name="scancodes" type="long" dir="in" safearray="yes"/>
10236 <param name="codesStored" type="unsigned long" dir="return"/>
10237 </method>
10238
10239 <method name="putCAD">
10240 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard. This
10241 function is nothing special, it is just a convenience function
10242 calling <link to="IKeyboard::putScancodes"/> with the proper scancodes.
10243
10244 <result name="VBOX_E_IPRT_ERROR">
10245 Could not send all scan codes to virtual keyboard.
10246 </result>
10247
10248 </desc>
10249 </method>
10250
10251 </interface>
10252
10253
10254 <!--
10255 // IMouse
10256 /////////////////////////////////////////////////////////////////////////
10257 -->
10258
10259 <enum
10260 name="MouseButtonState"
10261 uuid="03131722-2EC5-4173-9794-0DACA46673EF"
10262 >
10263 <desc>
10264 Mouse button state.
10265 </desc>
10266
10267 <const name="LeftButton" value="0x01"/>
10268 <const name="RightButton" value="0x02"/>
10269 <const name="MiddleButton" value="0x04"/>
10270 <const name="WheelUp" value="0x08"/>
10271 <const name="WheelDown" value="0x10"/>
10272 <const name="MouseStateMask" value="0x1F"/>
10273 </enum>
10274
10275 <interface
10276 name="IMouse" extends="$unknown"
10277 uuid="FD443EC1-0006-4F5B-9282-D72760A66916"
10278 wsmap="managed"
10279 >
10280 <desc>
10281 The IMouse interface represents the virtual machine's mouse. Used in
10282 <link to="IConsole::mouse"/>.
10283
10284 Through this interface, the virtual machine's virtual mouse can be
10285 controlled.
10286 </desc>
10287
10288 <attribute name="absoluteSupported" type="boolean" readonly="yes">
10289 <desc>
10290 Whether the guest OS supports absolute mouse pointer positioning
10291 or not.
10292 <note>
10293 VirtualBox Guest Tools need to be installed to the guest OS
10294 in order to enable absolute mouse positioning support.
10295 You can use the <link to="IConsoleCallback::onMouseCapabilityChange"/>
10296 callback to be instantly informed about changes of this attribute
10297 during virtual machine execution.
10298 </note>
10299 <see><link to="#putMouseEventAbsolute"/></see>
10300 </desc>
10301 </attribute>
10302
10303 <method name="putMouseEvent">
10304 <desc>
10305 Initiates a mouse event using relative pointer movements
10306 along x and y axis.
10307
10308 <result name="E_ACCESSDENIED">
10309 Console not powered up.
10310 </result>
10311 <result name="VBOX_E_IPRT_ERROR">
10312 Could not send mouse event to virtual mouse.
10313 </result>
10314
10315 </desc>
10316
10317 <param name="dx" type="long" dir="in">
10318 <desc>
10319 Amount of pixels the mouse should move to the right.
10320 Negative values move the mouse to the left.
10321 </desc>
10322 </param>
10323 <param name="dy" type="long" dir="in">
10324 <desc>
10325 Amount of pixels the mouse should move downwards.
10326 Negative values move the mouse upwards.
10327 </desc>
10328 </param>
10329 <param name="dz" type="long" dir="in">
10330 <desc>
10331 Amount of mouse wheel moves.
10332 Positive values describe clockwise wheel rotations,
10333 negative values describe counterclockwise rotations.
10334 </desc>
10335 </param>
10336 <param name="buttonState" type="long" dir="in">
10337 <desc>
10338 The current state of mouse buttons. Every bit represents
10339 a mouse button as follows:
10340 <table>
10341 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10342 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10343 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10344 </table>
10345 A value of <tt>1</tt> means the corresponding button is pressed.
10346 otherwise it is released.
10347 </desc>
10348 </param>
10349 </method>
10350
10351 <method name="putMouseEventAbsolute">
10352 <desc>
10353 Positions the mouse pointer using absolute x and y coordinates.
10354 These coordinates are expressed in pixels and
10355 start from <tt>[1,1]</tt> which corresponds to the top left
10356 corner of the virtual display.
10357
10358 <result name="E_ACCESSDENIED">
10359 Console not powered up.
10360 </result>
10361 <result name="VBOX_E_IPRT_ERROR">
10362 Could not send mouse event to virtual mouse.
10363 </result>
10364
10365 <note>
10366 This method will have effect only if absolute mouse
10367 positioning is supported by the guest OS.
10368 </note>
10369
10370 <see><link to="#absoluteSupported"/></see>
10371 </desc>
10372
10373 <param name="x" type="long" dir="in">
10374 <desc>
10375 X coordinate of the pointer in pixels, starting from <tt>1</tt>.
10376 </desc>
10377 </param>
10378 <param name="y" type="long" dir="in">
10379 <desc>
10380 Y coordinate of the pointer in pixels, starting from <tt>1</tt>.
10381 </desc>
10382 </param>
10383 <param name="dz" type="long" dir="in">
10384 <desc>
10385 Amount of mouse wheel moves.
10386 Positive values describe clockwise wheel rotations,
10387 negative values describe counterclockwise rotations.
10388 </desc>
10389 </param>
10390 <param name="buttonState" type="long" dir="in">
10391 <desc>
10392 The current state of mouse buttons. Every bit represents
10393 a mouse button as follows:
10394 <table>
10395 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10396 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10397 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10398 </table>
10399 A value of <tt>1</tt> means the corresponding button is pressed.
10400 otherwise it is released.
10401 </desc>
10402 </param>
10403 </method>
10404
10405 </interface>
10406
10407 <!--
10408 // IDisplay
10409 /////////////////////////////////////////////////////////////////////////
10410 -->
10411
10412 <enum
10413 name="FramebufferPixelFormat"
10414 uuid="7acfd5ed-29e3-45e3-8136-73c9224f3d2d"
10415 >
10416 <desc>
10417 Format of the video memory buffer. Constants represented by this enum can
10418 be used to test for particular values of <link
10419 to="IFramebuffer::pixelFormat"/>. See also <link
10420 to="IFramebuffer::requestResize"/>.
10421
10422 See also www.fourcc.org for more information about FOURCC pixel formats.
10423 </desc>
10424
10425 <const name="Opaque" value="0">
10426 <desc>
10427 Unknown buffer format (the user may not assume any particular format of
10428 the buffer).
10429 </desc>
10430 </const>
10431 <const name="FOURCC_RGB" value="0x32424752">
10432 <desc>
10433 Basic RGB format (<link to="IFramebuffer::bitsPerPixel"/> determines the
10434 bit layout).
10435 </desc>
10436 </const>
10437 </enum>
10438
10439 <interface
10440 name="IFramebuffer" extends="$unknown"
10441 uuid="b7ed347a-5765-40a0-ae1c-f543eb4ddeaf"
10442 wsmap="suppress"
10443 >
10444 <attribute name="address" type="octet" mod="ptr" readonly="yes">
10445 <desc>Address of the start byte of the frame buffer.</desc>
10446 </attribute>
10447
10448 <attribute name="width" type="unsigned long" readonly="yes">
10449 <desc>Frame buffer width, in pixels.</desc>
10450 </attribute>
10451
10452 <attribute name="height" type="unsigned long" readonly="yes">
10453 <desc>Frame buffer height, in pixels.</desc>
10454 </attribute>
10455
10456 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10457 <desc>
10458 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
10459 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, valid values
10460 are: 8, 15, 16, 24 and 32.
10461 </desc>
10462 </attribute>
10463
10464 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
10465 <desc>
10466 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
10467 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, the
10468 size of the scan line must be aligned to 32 bits.
10469 </desc>
10470 </attribute>
10471
10472 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
10473 <desc>
10474 Frame buffer pixel format. It's either one of the values defined by <link
10475 to="FramebufferPixelFormat"/> or a raw FOURCC code.
10476 <note>
10477 This attribute must never return <link
10478 to="FramebufferPixelFormat_Opaque"/> -- the format of the buffer
10479 <link to="#address"/> points to must be always known.
10480 </note>
10481 </desc>
10482 </attribute>
10483
10484 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
10485 <desc>
10486 Defines whether this frame buffer uses the virtual video card's memory
10487 buffer (guest VRAM) directly or not. See <link
10488 to="IFramebuffer::requestResize"/> for more information.
10489 </desc>
10490 </attribute>
10491
10492 <attribute name="heightReduction" type="unsigned long" readonly="yes">
10493 <desc>
10494 Hint from the frame buffer about how much of the standard
10495 screen height it wants to use for itself. This information is
10496 exposed to the guest through the VESA BIOS and VMMDev interface
10497 so that it can use it for determining its video mode table. It
10498 is not guaranteed that the guest respects the value.
10499 </desc>
10500 </attribute>
10501
10502 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
10503 <desc>
10504 An alpha-blended overlay which is superposed over the frame buffer.
10505 The initial purpose is to allow the display of icons providing
10506 information about the VM state, including disk activity, in front
10507 ends which do not have other means of doing that. The overlay is
10508 designed to controlled exclusively by IDisplay. It has no locking
10509 of its own, and any changes made to it are not guaranteed to be
10510 visible until the affected portion of IFramebuffer is updated. The
10511 overlay can be created lazily the first time it is requested. This
10512 attribute can also return NULL to signal that the overlay is not
10513 implemented.
10514 </desc>
10515 </attribute>
10516
10517 <attribute name="winId" type="unsigned long long" readonly="yes">
10518 <desc>
10519 Platform-dependent identifier of the window where context of this
10520 frame buffer is drawn, or zero if there's no such window.
10521 </desc>
10522 </attribute>
10523
10524 <method name="lock">
10525 <desc>
10526 Locks the frame buffer.
10527 Gets called by the IDisplay object where this frame buffer is
10528 bound to.
10529 </desc>
10530 </method>
10531
10532 <method name="unlock">
10533 <desc>
10534 Unlocks the frame buffer.
10535 Gets called by the IDisplay object where this frame buffer is
10536 bound to.
10537 </desc>
10538 </method>
10539
10540 <method name="notifyUpdate">
10541 <desc>
10542 Informs about an update.
10543 Gets called by the display object where this buffer is
10544 registered.
10545 </desc>
10546 <param name="x" type="unsigned long" dir="in"/>
10547 <param name="y" type="unsigned long" dir="in"/>
10548 <param name="width" type="unsigned long" dir="in"/>
10549 <param name="height" type="unsigned long" dir="in"/>
10550 </method>
10551
10552 <method name="requestResize">
10553 <desc>
10554 Requests a size and pixel format change.
10555
10556 There are two modes of working with the video buffer of the virtual
10557 machine. The <i>indirect</i> mode implies that the IFramebuffer
10558 implementation allocates a memory buffer for the requested display mode
10559 and provides it to the virtual machine. In <i>direct</i> mode, the
10560 IFramebuffer implementation uses the memory buffer allocated and owned
10561 by the virtual machine. This buffer represents the video memory of the
10562 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
10563 usually faster because the implementation gets a raw pointer to the
10564 guest VRAM buffer which it can directly use for visualizing the contents
10565 of the virtual display, as opposed to the indirect mode where the
10566 contents of guest VRAM are copied to the memory buffer provided by
10567 the implementation every time a display update occurs.
10568
10569 It is important to note that the direct mode is really fast only when
10570 the implementation uses the given guest VRAM buffer directly, for
10571 example, by blitting it to the window representing the virtual machine's
10572 display, which saves at least one copy operation comparing to the
10573 indirect mode. However, using the guest VRAM buffer directly is not
10574 always possible: the format and the color depth of this buffer may be
10575 not supported by the target window, or it may be unknown (opaque) as in
10576 case of text or non-linear multi-plane VGA video modes. In this case,
10577 the indirect mode (that is always available) should be used as a
10578 fallback: when the guest VRAM contents are copied to the
10579 implementation-provided memory buffer, color and format conversion is
10580 done automatically by the underlying code.
10581
10582 The @a pixelFormat parameter defines whether the direct mode is
10583 available or not. If @a pixelFormat is <link
10584 to="FramebufferPixelFormat_Opaque"/> then direct access to the guest
10585 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and
10586 @a bytesPerLine parameters must be ignored and the implementation must use
10587 the indirect mode (where it provides its own buffer in one of the
10588 supported formats). In all other cases, @a pixelFormat together with
10589 @a bitsPerPixel and @a bytesPerLine define the format of the video memory
10590 buffer pointed to by the @a VRAM parameter and the implementation is
10591 free to choose which mode to use. To indicate that this frame buffer uses
10592 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
10593 attribute must return <tt>true</tt> and <link to="#address"/> must
10594 return exactly the same address that is passed in the @a VRAM parameter
10595 of this method; otherwise it is assumed that the indirect strategy is
10596 chosen.
10597
10598 The @a width and @a height parameters represent the size of the
10599 requested display mode in both modes. In case of indirect mode, the
10600 provided memory buffer should be big enough to store data of the given
10601 display mode. In case of direct mode, it is guaranteed that the given
10602 @a VRAM buffer contains enough space to represent the display mode of the
10603 given size. Note that this frame buffer's <link to="#width"/> and <link
10604 to="#height"/> attributes must return exactly the same values as
10605 passed to this method after the resize is completed (see below).
10606
10607 The @a finished output parameter determines if the implementation has
10608 finished resizing the frame buffer or not. If, for some reason, the
10609 resize cannot be finished immediately during this call, @a finished
10610 must be set to @c false, and the implementation must call
10611 <link to="IDisplay::resizeCompleted"/> after it has returned from
10612 this method as soon as possible. If @a finished is @c false, the
10613 machine will not call any frame buffer methods until
10614 <link to="IDisplay::resizeCompleted"/> is called.
10615
10616 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
10617 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
10618 this frame buffer must return exactly the same values as specified in the
10619 parameters of this method, after the resize is completed. If the
10620 indirect mode is chosen, these attributes must return values describing
10621 the format of the implementation's own memory buffer <link
10622 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
10623 value must always correlate with <link to="#pixelFormat"/>. Note that
10624 the <link to="#pixelFormat"/> attribute must never return <link
10625 to="FramebufferPixelFormat_Opaque"/> regardless of the selected mode.
10626
10627 <note>
10628 This method is called by the IDisplay object under the
10629 <link to="#lock"/> provided by this IFramebuffer
10630 implementation. If this method returns @c false in @a finished, then
10631 this lock is not released until
10632 <link to="IDisplay::resizeCompleted"/> is called.
10633 </note>
10634 </desc>
10635 <param name="screenId" type="unsigned long" dir="in">
10636 <desc>
10637 Logical screen number. Must be used in the corresponding call to
10638 <link to="IDisplay::resizeCompleted"/> if this call is made.
10639 </desc>
10640 </param>
10641 <param name="pixelFormat" type="unsigned long" dir="in">
10642 <desc>
10643 Pixel format of the memory buffer pointed to by @a VRAM.
10644 See also <link to="FramebufferPixelFormat"/>.
10645 </desc>
10646 </param>
10647 <param name="VRAM" type="octet" mod="ptr" dir="in">
10648 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
10649 </param>
10650 <param name="bitsPerPixel" type="unsigned long" dir="in">
10651 <desc>Color depth, bits per pixel.</desc>
10652 </param>
10653 <param name="bytesPerLine" type="unsigned long" dir="in">
10654 <desc>Size of one scan line, in bytes.</desc>
10655 </param>
10656 <param name="width" type="unsigned long" dir="in">
10657 <desc>Width of the guest display, in pixels.</desc>
10658 </param>
10659 <param name="height" type="unsigned long" dir="in">
10660 <desc>Height of the guest display, in pixels.</desc>
10661 </param>
10662 <param name="finished" type="boolean" dir="return">
10663 <desc>
10664 Can the VM start using the new frame buffer immediately
10665 after this method returns or it should wait for
10666 <link to="IDisplay::resizeCompleted"/>.
10667 </desc>
10668 </param>
10669 </method>
10670
10671 <method name="videoModeSupported">
10672 <desc>
10673 Returns whether the frame buffer implementation is willing to
10674 support a given video mode. In case it is not able to render
10675 the video mode (or for some reason not willing), it should
10676 return false. Usually this method is called when the guest
10677 asks the VMM device whether a given video mode is supported
10678 so the information returned is directly exposed to the guest.
10679 It is important that this method returns very quickly.
10680 </desc>
10681 <param name="width" type="unsigned long" dir="in"/>
10682 <param name="height" type="unsigned long" dir="in"/>
10683 <param name="bpp" type="unsigned long" dir="in"/>
10684 <param name="supported" type="boolean" dir="return"/>
10685 </method>
10686
10687 <method name="getVisibleRegion">
10688 <desc>
10689 Returns the visible region of this frame buffer.
10690
10691 If the @a rectangles parameter is <tt>NULL</tt> then the value of the
10692 @a count parameter is ignored and the number of elements necessary to
10693 describe the current visible region is returned in @a countCopied.
10694
10695 If @a rectangles is not <tt>NULL</tt> but @a count is less
10696 than the required number of elements to store region data, the method
10697 will report a failure. If @a count is equal or greater than the
10698 required number of elements, then the actual number of elements copied
10699 to the provided array will be returned in @a countCopied.
10700
10701 <note>
10702 The address of the provided array must be in the process space of
10703 this IFramebuffer object.
10704 </note>
10705 <note>
10706 Method not yet implemented.
10707 </note>
10708 </desc>
10709 <param name="rectangles" type="octet" mod="ptr" dir="in">
10710 <desc>Pointer to the <tt>RTRECT</tt> array to receive region data.</desc>
10711 </param>
10712 <param name="count" type="unsigned long" dir="in">
10713 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10714 </param>
10715 <param name="countCopied" type="unsigned long" dir="return">
10716 <desc>Number of elements copied to the @a rectangles array.</desc>
10717 </param>
10718 </method>
10719
10720 <method name="setVisibleRegion">
10721 <desc>
10722 Suggests a new visible region to this frame buffer. This region
10723 represents the area of the VM display which is a union of regions of
10724 all top-level windows of the guest operating system running inside the
10725 VM (if the Guest Additions for this system support this
10726 functionality). This information may be used by the frontends to
10727 implement the seamless desktop integration feature.
10728
10729 <note>
10730 The address of the provided array must be in the process space of
10731 this IFramebuffer object.
10732 </note>
10733 <note>
10734 The IFramebuffer implementation must make a copy of the provided
10735 array of rectangles.
10736 </note>
10737 <note>
10738 Method not yet implemented.
10739 </note>
10740 </desc>
10741 <param name="rectangles" type="octet" mod="ptr" dir="in">
10742 <desc>Pointer to the <tt>RTRECT</tt> array.</desc>
10743 </param>
10744 <param name="count" type="unsigned long" dir="in">
10745 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10746 </param>
10747 </method>
10748
10749 <method name="processVHWACommand">
10750 <desc>
10751 Posts a Video HW Acceleration Command to the frame buffer for processing.
10752 The commands used for 2D video acceleration (DDraw surface creation/destroying, blitting, scaling, color covnersion, overlaying, etc.)
10753 are posted from quest to the host to be processed by the host hardware.
10754
10755 <note>
10756 The address of the provided command must be in the process space of
10757 this IFramebuffer object.
10758 </note>
10759 </desc>
10760
10761 <param name="command" type="octet" mod="ptr" dir="in">
10762 <desc>Pointer to VBOXVHWACMD containing the command to execute.</desc>
10763 </param>
10764 </method>
10765
10766 </interface>
10767
10768 <interface
10769 name="IFramebufferOverlay" extends="IFramebuffer"
10770 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
10771 wsmap="suppress"
10772 >
10773 <desc>
10774 The IFramebufferOverlay interface represents an alpha blended overlay
10775 for displaying status icons above an IFramebuffer. It is always created
10776 not visible, so that it must be explicitly shown. It only covers a
10777 portion of the IFramebuffer, determined by its width, height and
10778 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
10779 that order) format, and may be written to directly. Do re-read the
10780 width though, after setting it, as it may be adjusted (increased) to
10781 make it more suitable for the front end.
10782 </desc>
10783 <attribute name="x" type="unsigned long" readonly="yes">
10784 <desc>X position of the overlay, relative to the frame buffer.</desc>
10785 </attribute>
10786
10787 <attribute name="y" type="unsigned long" readonly="yes">
10788 <desc>Y position of the overlay, relative to the frame buffer.</desc>
10789 </attribute>
10790
10791 <attribute name="visible" type="boolean" readonly="no">
10792 <desc>
10793 Whether the overlay is currently visible.
10794 </desc>
10795 </attribute>
10796
10797 <attribute name="alpha" type="unsigned long" readonly="no">
10798 <desc>
10799 The global alpha value for the overlay. This may or may not be
10800 supported by a given front end.
10801 </desc>
10802 </attribute>
10803
10804 <method name="move">
10805 <desc>
10806 Changes the overlay's position relative to the IFramebuffer.
10807 </desc>
10808 <param name="x" type="unsigned long" dir="in"/>
10809 <param name="y" type="unsigned long" dir="in"/>
10810 </method>
10811
10812 </interface>
10813
10814 <interface
10815 name="IDisplay" extends="$unknown"
10816 uuid="26881797-bc98-444d-ac69-820633b93ec7"
10817 wsmap="managed"
10818 >
10819 <desc>
10820 The IDisplay interface represents the virtual machine's display.
10821
10822 The object implementing this interface is contained in each
10823 <link to="IConsole::display"/> attribute and represents the visual
10824 output of the virtual machine.
10825
10826 The virtual display supports pluggable output targets represented by the
10827 IFramebuffer interface. Examples of the output target are a window on
10828 the host computer or an RDP session's display on a remote computer.
10829 </desc>
10830 <attribute name="width" type="unsigned long" readonly="yes">
10831 <desc>Current display width.</desc>
10832 </attribute>
10833
10834 <attribute name="height" type="unsigned long" readonly="yes">
10835 <desc>Current display height.</desc>
10836 </attribute>
10837
10838 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10839 <desc>
10840 Current guest display color depth. Note that this may differ
10841 from <link to="IFramebuffer::bitsPerPixel"/>.
10842 </desc>
10843 </attribute>
10844
10845 <method name="setFramebuffer">
10846 <desc>
10847 Sets the framebuffer for given screen.
10848 </desc>
10849 <param name="screenId" type="unsigned long" dir="in"/>
10850 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10851 </method>
10852
10853 <method name="getFramebuffer">
10854 <desc>
10855 Queries the framebuffer for given screen.
10856 </desc>
10857 <param name="screenId" type="unsigned long" dir="in"/>
10858 <param name="framebuffer" type="IFramebuffer" dir="out"/>
10859 <param name="xOrigin" type="long" dir="out"/>
10860 <param name="yOrigin" type="long" dir="out"/>
10861 </method>
10862
10863 <method name="setVideoModeHint">
10864 <desc>
10865 Asks VirtualBox to request the given video mode from
10866 the guest. This is just a hint and it cannot be guaranteed
10867 that the requested resolution will be used. Guest Additions
10868 are required for the request to be seen by guests. The caller
10869 should issue the request and wait for a resolution change and
10870 after a timeout retry.
10871
10872 Specifying <tt>0</tt> for either @a width, @a height or @a bitsPerPixel
10873 parameters means that the corresponding values should be taken from the
10874 current video mode (i.e. left unchanged).
10875
10876 If the guest OS supports multi-monitor configuration then the @a display
10877 parameter specifies the number of the guest display to send the hint to:
10878 <tt>0</tt> is the primary display, <tt>1</tt> is the first secondary and
10879 so on. If the multi-monitor configuration is not supported, @a display
10880 must be <tt>0</tt>.
10881
10882 <result name="E_INVALIDARG">
10883 The @a display is not associated with any monitor.
10884 </result>
10885
10886 </desc>
10887 <param name="width" type="unsigned long" dir="in"/>
10888 <param name="height" type="unsigned long" dir="in"/>
10889 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
10890 <param name="display" type="unsigned long" dir="in"/>
10891 </method>
10892
10893 <method name="setSeamlessMode">
10894 <desc>
10895 Enables or disables seamless guest display rendering (seamless desktop
10896 integration) mode.
10897 <note>
10898 Calling this method has no effect if <link
10899 to="IGuest::supportsSeamless"/> returns <tt>false</tt>.
10900 </note>
10901 </desc>
10902 <param name="enabled" type="boolean" dir="in"/>
10903 </method>
10904
10905 <method name="takeScreenShot">
10906 <desc>
10907 Takes a screen shot of the requested size and copies it to the
10908 32-bpp buffer allocated by the caller and pointed to by @a address.
10909
10910 <note>This API can be used only by the COM/XPCOM C++ API as it
10911 requires pointer support. Use <link to="#takeScreenShotSlow" />
10912 with other language bindings.
10913 </note>
10914
10915 <result name="E_NOTIMPL">
10916 Feature not implemented.
10917 </result>
10918 <result name="VBOX_E_IPRT_ERROR">
10919 Could not take a screenshot.
10920 </result>
10921
10922 </desc>
10923 <param name="address" type="octet" mod="ptr" dir="in"/>
10924 <param name="width" type="unsigned long" dir="in"/>
10925 <param name="height" type="unsigned long" dir="in"/>
10926 </method>
10927
10928 <method name="takeScreenShotSlow">
10929 <desc>
10930 Takes a guest screen shot of the requested size and returns it as
10931 an array of bytes in uncompressed 32-bit ARGB format.
10932 This API is slow, but could be the only option to get guest screenshot
10933 for scriptable languages not allowed to manipulate with addresses
10934 directly.
10935
10936 <result name="E_NOTIMPL">
10937 Feature not implemented.
10938 </result>
10939 <result name="VBOX_E_IPRT_ERROR">
10940 Could not take a screenshot.
10941 </result>
10942 </desc>
10943 <param name="width" type="unsigned long" dir="in">
10944 <desc>
10945 Desired image width.
10946 </desc>
10947 </param>
10948 <param name="height" type="unsigned long" dir="in">
10949 <desc>
10950 Desired image height.
10951 </desc>
10952 </param>
10953 <param name="screenData" type="octet" dir="return" safearray="yes">
10954 <desc>
10955 Array with resulting screen data.
10956 </desc>
10957 </param>
10958 </method>
10959
10960 <method name="drawToScreen">
10961 <desc>
10962 Draws a 32-bpp image of the specified size from the given buffer
10963 to the given point on the VM display.
10964
10965 <result name="E_NOTIMPL">
10966 Feature not implemented.
10967 </result>
10968 <result name="VBOX_E_IPRT_ERROR">
10969 Could not draw to screen.
10970 </result>
10971
10972 </desc>
10973 <param name="address" type="octet" mod="ptr" dir="in"/>
10974 <param name="x" type="unsigned long" dir="in"/>
10975 <param name="y" type="unsigned long" dir="in"/>
10976 <param name="width" type="unsigned long" dir="in"/>
10977 <param name="height" type="unsigned long" dir="in"/>
10978 </method>
10979
10980 <method name="invalidateAndUpdate">
10981 <desc>
10982 Does a full invalidation of the VM display and instructs the VM
10983 to update it.
10984
10985 <result name="VBOX_E_IPRT_ERROR">
10986 Could not invalidate and update screen.
10987 </result>
10988
10989 </desc>
10990 </method>
10991
10992 <method name="resizeCompleted">
10993 <desc>
10994 Signals that a framebuffer has completed the resize operation.
10995
10996 <result name="VBOX_E_NOT_SUPPORTED">
10997 Operation only valid for external frame buffers.
10998 </result>
10999
11000 </desc>
11001 <param name="screenId" type="unsigned long" dir="in"/>
11002 </method>
11003
11004 <method name="updateCompleted">
11005 <desc>
11006 Signals that a framebuffer has completed the update operation.
11007
11008 <result name="VBOX_E_NOT_SUPPORTED">
11009 Operation only valid for external frame buffers.
11010 </result>
11011
11012 </desc>
11013 </method>
11014
11015 <method name="completeVHWACommand">
11016 <desc>
11017 Signals that the Video HW Acceleration command has completed.
11018 </desc>
11019
11020 <param name="command" type="octet" mod="ptr" dir="in">
11021 <desc>Pointer to VBOXVHWACMD containing the completed command.</desc>
11022 </param>
11023 </method>
11024
11025 </interface>
11026
11027 <!--
11028 // INetworkAdapter
11029 /////////////////////////////////////////////////////////////////////////
11030 -->
11031
11032 <enum
11033 name="NetworkAttachmentType"
11034 uuid="44bce1ee-99f7-4e8e-89fc-80597fd9eeaf"
11035 >
11036 <desc>
11037 Network attachment type.
11038 </desc>
11039
11040 <const name="Null" value="0">
11041 <desc>Null value, also means "not attached".</desc>
11042 </const>
11043 <const name="NAT" value="1"/>
11044 <const name="Bridged" value="2"/>
11045 <const name="Internal" value="3"/>
11046 <const name="HostOnly" value="4"/>
11047 </enum>
11048
11049 <enum
11050 name="NetworkAdapterType"
11051 uuid="50c3dfd8-07ac-4a31-baac-519c828fbf97"
11052 >
11053 <desc>
11054 Network adapter type.
11055 </desc>
11056
11057 <const name="Null" value="0">
11058 <desc>Null value (never used by the API).</desc>
11059 </const>
11060 <const name="Am79C970A" value="1">
11061 <desc>AMD PCNet-PCI II network card (Am79C970A).</desc>
11062 </const>
11063 <const name="Am79C973" value="2">
11064 <desc>AMD PCNet-FAST III network card (Am79C973).</desc>
11065 </const>
11066 <const name="I82540EM" value="3">
11067 <desc>Intel PRO/1000 MT Desktop network card (82540EM).</desc>
11068 </const>
11069 <const name="I82543GC" value="4">
11070 <desc>Intel PRO/1000 T Server network card (82543GC).</desc>
11071 </const>
11072 <const name="I82545EM" value="5">
11073 <desc>Intel PRO/1000 MT Server network card (82545EM).</desc>
11074 </const>
11075 </enum>
11076
11077 <interface
11078 name="INetworkAdapter" extends="$unknown"
11079 uuid="65607a27-2b73-4d43-b4cc-0ba2c817fbde"
11080 wsmap="managed"
11081 >
11082 <desc>
11083 Represents a virtual network adapter that is attached to a virtual machine.
11084 Each virtual machine has a fixed number of network adapter slots with one
11085 instance of this attached to each of them. Call
11086 <link to="IMachine::getNetworkAdapter" /> to get the network adapter that
11087 is attached to a given slot in a given machine.
11088
11089 Each network adapter can be in one of five attachment modes, which are
11090 represented by the <link to="NetworkAttachmentType" /> enumeration;
11091 see the <link to="#attachmentType" /> attribute.
11092 </desc>
11093
11094 <attribute name="adapterType" type="NetworkAdapterType">
11095 <desc>
11096 Type of the virtual network adapter. Depending on this value,
11097 VirtualBox will provide a different virtual network hardware
11098 to the guest.
11099 </desc>
11100 </attribute>
11101
11102 <attribute name="slot" type="unsigned long" readonly="yes">
11103 <desc>
11104 Slot number this adapter is plugged into. Corresponds to
11105 the value you pass to <link to="IMachine::getNetworkAdapter"/>
11106 to obtain this instance.
11107 </desc>
11108 </attribute>
11109
11110 <attribute name="enabled" type="boolean">
11111 <desc>
11112 Flag whether the network adapter is present in the
11113 guest system. If disabled, the virtual guest hardware will
11114 not contain this network adapter. Can only be changed when
11115 the VM is not running.
11116 </desc>
11117 </attribute>
11118
11119 <attribute name="MACAddress" type="wstring">
11120 <desc>
11121 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
11122 it to NULL, VirtualBox will generate a unique MAC address.
11123 </desc>
11124 </attribute>
11125
11126 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
11127
11128 <attribute name="hostInterface" type="wstring">
11129 <desc>
11130 Name of the host network interface the VM is attached to.
11131 </desc>
11132 </attribute>
11133
11134 <attribute name="internalNetwork" type="wstring">
11135 <desc>
11136 Name of the internal network the VM is attached to.
11137 </desc>
11138 </attribute>
11139
11140 <attribute name="NATNetwork" type="wstring">
11141 <desc>
11142 Name of the NAT network the VM is attached to.
11143 </desc>
11144 </attribute>
11145
11146 <attribute name="cableConnected" type="boolean">
11147 <desc>
11148 Flag whether the adapter reports the cable as connected or not.
11149 It can be used to report offline situations to a VM.
11150 </desc>
11151 </attribute>
11152
11153 <attribute name="lineSpeed" type="unsigned long">
11154 <desc>
11155 Line speed reported by custom drivers, in units of 1 kbps.
11156 </desc>
11157 </attribute>
11158
11159 <attribute name="traceEnabled" type="boolean">
11160 <desc>
11161 Flag whether network traffic from/to the network card should be traced.
11162 Can only be toggled when the VM is turned off.
11163 </desc>
11164 </attribute>
11165
11166 <attribute name="traceFile" type="wstring">
11167 <desc>
11168 Filename where a network trace will be stored. If not set, VBox-pid.pcap
11169 will be used.
11170 </desc>
11171 </attribute>
11172
11173 <method name="attachToNAT">
11174 <desc>
11175 Attach the network adapter to the Network Address Translation (NAT) interface.
11176 </desc>
11177 </method>
11178
11179 <method name="attachToBridgedInterface">
11180 <desc>
11181 Attach the network adapter to a bridged host interface.
11182 </desc>
11183 </method>
11184
11185 <method name="attachToInternalNetwork">
11186 <desc>
11187 Attach the network adapter to an internal network.
11188 </desc>
11189 </method>
11190
11191 <method name="attachToHostOnlyInterface">
11192 <desc>
11193 Attach the network adapter to the host-only network.
11194 </desc>
11195 </method>
11196
11197 <method name="detach">
11198 <desc>
11199 Detach the network adapter
11200 </desc>
11201 </method>
11202 </interface>
11203
11204
11205 <!--
11206 // ISerialPort
11207 /////////////////////////////////////////////////////////////////////////
11208 -->
11209
11210 <enum
11211 name="PortMode"
11212 uuid="533b5fe3-0185-4197-86a7-17e37dd39d76"
11213 >
11214 <desc>
11215 The PortMode enumeration represents possible communication modes for
11216 the virtual serial port device.
11217 </desc>
11218
11219 <const name="Disconnected" value="0">
11220 <desc>Virtual device is not attached to any real host device.</desc>
11221 </const>
11222 <const name="HostPipe" value="1">
11223 <desc>Virtual device is attached to a host pipe.</desc>
11224 </const>
11225 <const name="HostDevice" value="2">
11226 <desc>Virtual device is attached to a host device.</desc>
11227 </const>
11228 <const name="RawFile" value="3">
11229 <desc>Virtual device is attached to a raw file.</desc>
11230 </const>
11231 </enum>
11232
11233 <interface
11234 name="ISerialPort" extends="$unknown"
11235 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
11236 wsmap="managed"
11237 >
11238
11239 <desc>
11240 The ISerialPort interface represents the virtual serial port device.
11241
11242 The virtual serial port device acts like an ordinary serial port
11243 inside the virtual machine. This device communicates to the real
11244 serial port hardware in one of two modes: host pipe or host device.
11245
11246 In host pipe mode, the #path attribute specifies the path to the pipe on
11247 the host computer that represents a serial port. The #server attribute
11248 determines if this pipe is created by the virtual machine process at
11249 machine startup or it must already exist before starting machine
11250 execution.
11251
11252 In host device mode, the #path attribute specifies the name of the
11253 serial port device on the host computer.
11254
11255 There is also a third communication mode: the disconnected mode. In this
11256 mode, the guest OS running inside the virtual machine will be able to
11257 detect the serial port, but all port write operations will be discarded
11258 and all port read operations will return no data.
11259
11260 <see>IMachine::getSerialPort</see>
11261 </desc>
11262
11263 <attribute name="slot" type="unsigned long" readonly="yes">
11264 <desc>
11265 Slot number this serial port is plugged into. Corresponds to
11266 the value you pass to <link to="IMachine::getSerialPort"/>
11267 to obtain this instance.
11268 </desc>
11269 </attribute>
11270
11271 <attribute name="enabled" type="boolean">
11272 <desc>
11273 Flag whether the serial port is enabled. If disabled,
11274 the serial port will not be reported to the guest OS.
11275 </desc>
11276 </attribute>
11277
11278 <attribute name="IOBase" type="unsigned long">
11279 <desc>Base I/O address of the serial port.</desc>
11280 </attribute>
11281
11282 <attribute name="IRQ" type="unsigned long">
11283 <desc>IRQ number of the serial port.</desc>
11284 </attribute>
11285
11286 <attribute name="hostMode" type="PortMode">
11287 <desc>
11288 How is this port connected to the host.
11289 <note>
11290 Changing this attribute may fail if the conditions for
11291 <link to="#path"/> are not met.
11292 </note>
11293 </desc>
11294 </attribute>
11295
11296 <attribute name="server" type="boolean">
11297 <desc>
11298 Flag whether this serial port acts as a server (creates a new pipe on
11299 the host) or as a client (uses the existing pipe). This attribute is
11300 used only when <link to="#hostMode"/> is PortMode_HostPipe.
11301 </desc>
11302 </attribute>
11303
11304 <attribute name="path" type="wstring">
11305 <desc>
11306 Path to the serial port's pipe on the host when <link to="ISerialPort::hostMode"/> is
11307 PortMode_HostPipe, or the host serial device name when
11308 <link to="ISerialPort::hostMode"/> is PortMode_HostDevice. For both
11309 cases, setting a @c null or empty string as the attribute's value
11310 is an error. Otherwise, the value of this property is ignored.
11311 </desc>
11312 </attribute>
11313
11314 </interface>
11315
11316 <!--
11317 // IParallelPort
11318 /////////////////////////////////////////////////////////////////////////
11319 -->
11320
11321 <interface
11322 name="IParallelPort" extends="$unknown"
11323 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
11324 wsmap="managed"
11325 >
11326
11327 <desc>
11328 The IParallelPort interface represents the virtual parallel port device.
11329
11330 The virtual parallel port device acts like an ordinary parallel port
11331 inside the virtual machine. This device communicates to the real
11332 parallel port hardware using the name of the parallel device on the host
11333 computer specified in the #path attribute.
11334
11335 Each virtual parallel port device is assigned a base I/O address and an
11336 IRQ number that will be reported to the guest operating system and used
11337 to operate the given parallel port from within the virtual machine.
11338
11339 <see>IMachine::getParallelPort</see>
11340 </desc>
11341
11342 <attribute name="slot" type="unsigned long" readonly="yes">
11343 <desc>
11344 Slot number this parallel port is plugged into. Corresponds to
11345 the value you pass to <link to="IMachine::getParallelPort"/>
11346 to obtain this instance.
11347 </desc>
11348 </attribute>
11349
11350 <attribute name="enabled" type="boolean">
11351 <desc>
11352 Flag whether the parallel port is enabled. If disabled,
11353 the parallel port will not be reported to the guest OS.
11354 </desc>
11355 </attribute>
11356
11357 <attribute name="IOBase" type="unsigned long">
11358 <desc>Base I/O address of the parallel port.</desc>
11359 </attribute>
11360
11361 <attribute name="IRQ" type="unsigned long">
11362 <desc>IRQ number of the parallel port.</desc>
11363 </attribute>
11364
11365 <attribute name="path" type="wstring">
11366 <desc>
11367 Host parallel device name. If this parallel port is enabled, setting a
11368 @c null or an empty string as this attribute's value will result into
11369 an error.
11370 </desc>
11371 </attribute>
11372
11373 </interface>
11374
11375
11376 <!--
11377 // IMachineDebugger
11378 /////////////////////////////////////////////////////////////////////////
11379 -->
11380
11381 <interface
11382 name="IMachineDebugger" extends="$unknown"
11383 uuid="b0b2a2dd-0627-4502-91c2-ddc5e77609e0"
11384 wsmap="suppress"
11385 >
11386 <method name="resetStats">
11387 <desc>
11388 Reset VM statistics.
11389 </desc>
11390 <param name="pattern" type="wstring" dir="in">
11391 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11392 </param>
11393 </method>
11394
11395 <method name="dumpStats">
11396 <desc>
11397 Dumps VM statistics.
11398 </desc>
11399 <param name="pattern" type="wstring" dir="in">
11400 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11401 </param>
11402 </method>
11403
11404 <method name="getStats">
11405 <desc>
11406 Get the VM statistics in a XMLish format.
11407 </desc>
11408 <param name="pattern" type="wstring" dir="in">
11409 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11410 </param>
11411 <param name="withDescriptions" type="boolean" dir="in">
11412 <desc>Whether to include the descriptions.</desc>
11413 </param>
11414 <param name="stats" type="wstring" dir="out">
11415 <desc>The XML document containing the statistics.</desc>
11416 </param>
11417 </method>
11418
11419 <method name="injectNMI">
11420 <desc>
11421 Inject an NMI into a running VT-x/AMD-V VM.
11422 </desc>
11423 </method>
11424
11425 <attribute name="singlestep" type="boolean">
11426 <desc>Switch for enabling singlestepping.</desc>
11427 </attribute>
11428
11429 <attribute name="recompileUser" type="boolean">
11430 <desc>Switch for forcing code recompilation for user mode code.</desc>
11431 </attribute>
11432
11433 <attribute name="recompileSupervisor" type="boolean">
11434 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
11435 </attribute>
11436
11437 <attribute name="PATMEnabled" type="boolean">
11438 <desc>Switch for enabling and disabling the PATM component.</desc>
11439 </attribute>
11440
11441 <attribute name="CSAMEnabled" type="boolean">
11442 <desc>Switch for enabling and disabling the CSAM component.</desc>
11443 </attribute>
11444
11445 <attribute name="logEnabled" type="boolean">
11446 <desc>Switch for enabling and disabling logging.</desc>
11447 </attribute>
11448
11449 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
11450 <desc>
11451 Flag indicating whether the VM is currently making use of CPU hardware
11452 virtualization extensions.
11453 </desc>
11454 </attribute>
11455
11456 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" readonly="yes">
11457 <desc>
11458 Flag indicating whether the VM is currently making use of the nested paging
11459 CPU hardware virtualization extension.
11460 </desc>
11461 </attribute>
11462
11463 <attribute name="HWVirtExVPIDEnabled" type="boolean" readonly="yes">
11464 <desc>
11465 Flag indicating whether the VM is currently making use of the VPID
11466 VT-x extension.
11467 </desc>
11468 </attribute>
11469
11470 <attribute name="PAEEnabled" type="boolean" readonly="yes">
11471 <desc>
11472 Flag indicating whether the VM is currently making use of the Physical
11473 Address Extension CPU feature.
11474 </desc>
11475 </attribute>
11476
11477 <attribute name="virtualTimeRate" type="unsigned long">
11478 <desc>
11479 The rate at which the virtual time runs expressed as a percentage.
11480 The accepted range is 2% to 20000%.
11481 </desc>
11482 </attribute>
11483
11484 <!-- @todo method for setting log flags, groups and destination! -->
11485
11486 <attribute name="VM" type="unsigned long long" readonly="yes">
11487 <desc>
11488 Gets the VM handle. This is only for internal use while
11489 we carve the details of this interface.
11490 </desc>
11491 </attribute>
11492
11493 </interface>
11494
11495 <!--
11496 // IUSBController
11497 /////////////////////////////////////////////////////////////////////////
11498 -->
11499
11500 <interface
11501 name="IUSBController" extends="$unknown"
11502 uuid="238540fa-4b73-435a-a38e-4e1d9eab5c17"
11503 wsmap="managed"
11504 >
11505 <attribute name="enabled" type="boolean">
11506 <desc>
11507 Flag whether the USB controller is present in the
11508 guest system. If disabled, the virtual guest hardware will
11509 not contain any USB controller. Can only be changed when
11510 the VM is powered off.
11511 </desc>
11512 </attribute>
11513
11514 <attribute name="enabledEhci" type="boolean">
11515 <desc>
11516 Flag whether the USB EHCI controller is present in the
11517 guest system. If disabled, the virtual guest hardware will
11518 not contain a USB EHCI controller. Can only be changed when
11519 the VM is powered off.
11520 </desc>
11521 </attribute>
11522
11523 <attribute name="USBStandard" type="unsigned short" readonly="yes">
11524 <desc>
11525 USB standard version which the controller implements.
11526 This is a BCD which means that the major version is in the
11527 high byte and minor version is in the low byte.
11528 </desc>
11529 </attribute>
11530
11531 <attribute name="deviceFilters" type="IUSBDeviceFilter" readonly="yes" safearray="yes">
11532 <desc>
11533 List of USB device filters associated with the machine.
11534
11535 If the machine is currently running, these filters are activated
11536 every time a new (supported) USB device is attached to the host
11537 computer that was not ignored by global filters
11538 (<link to="IHost::USBDeviceFilters"/>).
11539
11540 These filters are also activated when the machine is powered up.
11541 They are run against a list of all currently available USB
11542 devices (in states
11543 <link to="USBDeviceState_Available"/>,
11544 <link to="USBDeviceState_Busy"/>,
11545 <link to="USBDeviceState_Held"/>) that were not previously
11546 ignored by global filters.
11547
11548 If at least one filter matches the USB device in question, this
11549 device is automatically captured (attached to) the virtual USB
11550 controller of this machine.
11551
11552 <see>IUSBDeviceFilter, ::IUSBController</see>
11553 </desc>
11554 </attribute>
11555
11556 <method name="createDeviceFilter">
11557 <desc>
11558 Creates a new USB device filter. All attributes except
11559 the filter name are set to <tt>null</tt> (any match),
11560 <i>active</i> is <tt>false</tt> (the filter is not active).
11561
11562 The created filter can then be added to the list of filters using
11563 <link to="#insertDeviceFilter"/>.
11564
11565 <result name="VBOX_E_INVALID_VM_STATE">
11566 The virtual machine is not mutable.
11567 </result>
11568
11569 <see>#deviceFilters</see>
11570 </desc>
11571 <param name="name" type="wstring" dir="in">
11572 <desc>
11573 Filter name. See <link to="IUSBDeviceFilter::name"/>
11574 for more info.
11575 </desc>
11576 </param>
11577 <param name="filter" type="IUSBDeviceFilter" dir="return">
11578 <desc>Created filter object.</desc>
11579 </param>
11580 </method>
11581
11582 <method name="insertDeviceFilter">
11583 <desc>
11584 Inserts the given USB device to the specified position
11585 in the list of filters.
11586
11587 Positions are numbered starting from <tt>0</tt>. If the specified
11588 position is equal to or greater than the number of elements in
11589 the list, the filter is added to the end of the collection.
11590
11591 <note>
11592 Duplicates are not allowed, so an attempt to insert a
11593 filter that is already in the collection, will return an
11594 error.
11595 </note>
11596
11597 <result name="VBOX_E_INVALID_VM_STATE">
11598 Virtual machine is not mutable.
11599 </result>
11600 <result name="E_INVALIDARG">
11601 USB device filter not created within this VirtualBox instance.
11602 </result>
11603 <result name="VBOX_E_INVALID_OBJECT_STATE">
11604 USB device filter already in list.
11605 </result>
11606
11607 <see>#deviceFilters</see>
11608 </desc>
11609 <param name="position" type="unsigned long" dir="in">
11610 <desc>Position to insert the filter to.</desc>
11611 </param>
11612 <param name="filter" type="IUSBDeviceFilter" dir="in">
11613 <desc>USB device filter to insert.</desc>
11614 </param>
11615 </method>
11616
11617 <method name="removeDeviceFilter">
11618 <desc>
11619 Removes a USB device filter from the specified position in the
11620 list of filters.
11621
11622 Positions are numbered starting from <tt>0</tt>. Specifying a
11623 position equal to or greater than the number of elements in
11624 the list will produce an error.
11625
11626 <see>#deviceFilters</see>
11627
11628 <result name="VBOX_E_INVALID_VM_STATE">
11629 Virtual machine is not mutable.
11630 </result>
11631 <result name="E_INVALIDARG">
11632 USB device filter list empty or invalid @a position.
11633 </result>
11634
11635 </desc>
11636 <param name="position" type="unsigned long" dir="in">
11637 <desc>Position to remove the filter from.</desc>
11638 </param>
11639 <param name="filter" type="IUSBDeviceFilter" dir="return">
11640 <desc>Removed USB device filter.</desc>
11641 </param>
11642 </method>
11643
11644 </interface>
11645
11646
11647 <!--
11648 // IUSBDevice
11649 /////////////////////////////////////////////////////////////////////////
11650 -->
11651
11652 <interface
11653 name="IUSBDevice" extends="$unknown"
11654 uuid="f8967b0b-4483-400f-92b5-8b675d98a85b"
11655 wsmap="managed"
11656 >
11657 <desc>
11658 The IUSBDevice interface represents a virtual USB device attached to the
11659 virtual machine.
11660
11661 A collection of objects implementing this interface is stored in the
11662 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
11663 attached to a running virtual machine's USB controller.
11664 </desc>
11665
11666 <attribute name="id" type="wstring" readonly="yes">
11667 <desc>
11668 Unique USB device ID. This ID is built from #vendorId,
11669 #productId, #revision and #serialNumber.
11670 </desc>
11671 </attribute>
11672
11673 <attribute name="vendorId" type="unsigned short" readonly="yes">
11674 <desc>Vendor ID.</desc>
11675 </attribute>
11676
11677 <attribute name="productId" type="unsigned short" readonly="yes">
11678 <desc>Product ID.</desc>
11679 </attribute>
11680
11681 <attribute name="revision" type="unsigned short" readonly="yes">
11682 <desc>
11683 Product revision number. This is a packed BCD represented as
11684 unsigned short. The high byte is the integer part and the low
11685 byte is the decimal.
11686 </desc>
11687 </attribute>
11688
11689 <attribute name="manufacturer" type="wstring" readonly="yes">
11690 <desc>Manufacturer string.</desc>
11691 </attribute>
11692
11693 <attribute name="product" type="wstring" readonly="yes">
11694 <desc>Product string.</desc>
11695 </attribute>
11696
11697 <attribute name="serialNumber" type="wstring" readonly="yes">
11698 <desc>Serial number string.</desc>
11699 </attribute>
11700
11701 <attribute name="address" type="wstring" readonly="yes">
11702 <desc>Host specific address of the device.</desc>
11703 </attribute>
11704
11705 <attribute name="port" type="unsigned short" readonly="yes">
11706 <desc>
11707 Host USB port number the device is physically
11708 connected to.
11709 </desc>
11710 </attribute>
11711
11712 <attribute name="version" type="unsigned short" readonly="yes">
11713 <desc>
11714 The major USB version of the device - 1 or 2.
11715 </desc>
11716 </attribute>
11717
11718 <attribute name="portVersion" type="unsigned short" readonly="yes">
11719 <desc>
11720 The major USB version of the host USB port the device is
11721 physically connected to - 1 or 2. For devices not connected to
11722 anything this will have the same value as the version attribute.
11723 </desc>
11724 </attribute>
11725
11726 <attribute name="remote" type="boolean" readonly="yes">
11727 <desc>
11728 Whether the device is physically connected to a remote VRDP
11729 client or to a local host machine.
11730 </desc>
11731 </attribute>
11732
11733 </interface>
11734
11735
11736 <!--
11737 // IUSBDeviceFilter
11738 /////////////////////////////////////////////////////////////////////////
11739 -->
11740
11741 <interface
11742 name="IUSBDeviceFilter" extends="$unknown"
11743 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
11744 wsmap="managed"
11745 >
11746 <desc>
11747 The IUSBDeviceFilter interface represents an USB device filter used
11748 to perform actions on a group of USB devices.
11749
11750 This type of filters is used by running virtual machines to
11751 automatically capture selected USB devices once they are physically
11752 attached to the host computer.
11753
11754 A USB device is matched to the given device filter if and only if all
11755 attributes of the device match the corresponding attributes of the
11756 filter (that is, attributes are joined together using the logical AND
11757 operation). On the other hand, all together, filters in the list of
11758 filters carry the semantics of the logical OR operation. So if it is
11759 desirable to create a match like "this vendor id OR this product id",
11760 one needs to create two filters and specify "any match" (see below)
11761 for unused attributes.
11762
11763 All filter attributes used for matching are strings. Each string
11764 is an expression representing a set of values of the corresponding
11765 device attribute, that will match the given filter. Currently, the
11766 following filtering expressions are supported:
11767
11768 <ul>
11769 <li><i>Interval filters</i>. Used to specify valid intervals for
11770 integer device attributes (Vendor ID, Product ID and Revision).
11771 The format of the string is:
11772
11773 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
11774
11775 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
11776 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
11777 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
11778 is omitted before a dash (<tt>-</tt>), the minimum possible integer
11779 is assumed; if <tt>n</tt> is omitted after a dash, the maximum
11780 possible integer is assumed.
11781 </li>
11782 <li><i>Boolean filters</i>. Used to specify acceptable values for
11783 boolean device attributes. The format of the string is:
11784
11785 <tt>true|false|yes|no|0|1</tt>
11786
11787 </li>
11788 <li><i>Exact match</i>. Used to specify a single value for the given
11789 device attribute. Any string that doesn't start with <tt>int:</tt>
11790 represents the exact match. String device attributes are compared to
11791 this string including case of symbols. Integer attributes are first
11792 converted to a string (see individual filter attributes) and then
11793 compared ignoring case.
11794
11795 </li>
11796 <li><i>Any match</i>. Any value of the corresponding device attribute
11797 will match the given filter. An empty or <tt>null</tt> string is
11798 used to construct this type of filtering expressions.
11799
11800 </li>
11801 </ul>
11802
11803 <note>
11804 On the Windows host platform, interval filters are not currently
11805 available. Also all string filter attributes
11806 (<link to="#manufacturer"/>, <link to="#product"/>,
11807 <link to="#serialNumber"/>) are ignored, so they behave as
11808 <i>any match</i> no matter what string expression is specified.
11809 </note>
11810
11811 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
11812 </desc>
11813
11814 <attribute name="name" type="wstring">
11815 <desc>
11816 Visible name for this filter.
11817 This name is used to visually distinguish one filter from another,
11818 so it can neither be <tt>null</tt> nor an empty string.
11819 </desc>
11820 </attribute>
11821
11822 <attribute name="active" type="boolean">
11823 <desc>Whether this filter active or has been temporarily disabled.</desc>
11824 </attribute>
11825
11826 <attribute name="vendorId" type="wstring">
11827 <desc>
11828 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
11829 The string representation for the <i>exact matching</i>
11830 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11831 (including leading zeroes).
11832 </desc>
11833 </attribute>
11834
11835 <attribute name="productId" type="wstring">
11836 <desc>
11837 <link to="IUSBDevice::productId">Product ID</link> filter.
11838 The string representation for the <i>exact matching</i>
11839 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11840 (including leading zeroes).
11841 </desc>
11842 </attribute>
11843
11844 <attribute name="revision" type="wstring">
11845 <desc>
11846 <link to="IUSBDevice::productId">Product revision number</link>
11847 filter. The string representation for the <i>exact matching</i>
11848 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
11849 of the integer part of the revision, and <tt>F</tt> is the
11850 decimal digit of its fractional part (including leading and
11851 trailing zeros).
11852 Note that for interval filters, it's best to use the hexadecimal
11853 form, because the revision is stored as a 16 bit packed BCD value;
11854 so the expression <tt>int:0x0100-0x0199</tt> will match any
11855 revision from <tt>1.0</tt> to <tt>1.99</tt>.
11856 </desc>
11857 </attribute>
11858
11859 <attribute name="manufacturer" type="wstring">
11860 <desc>
11861 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
11862 </desc>
11863 </attribute>
11864
11865 <attribute name="product" type="wstring">
11866 <desc>
11867 <link to="IUSBDevice::product">Product</link> filter.
11868 </desc>
11869 </attribute>
11870
11871 <attribute name="serialNumber" type="wstring">
11872 <desc>
11873 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
11874 </desc>
11875 </attribute>
11876
11877 <attribute name="port" type="wstring">
11878 <desc>
11879 <link to="IUSBDevice::port">Host USB port</link> filter.
11880 </desc>
11881 </attribute>
11882
11883 <attribute name="remote" type="wstring">
11884 <desc>
11885 <link to="IUSBDevice::remote">Remote state</link> filter.
11886 <note>
11887 This filter makes sense only for machine USB filters,
11888 i.e. it is ignored by IHostUSBDeviceFilter objects.
11889 </note>
11890 </desc>
11891 </attribute>
11892
11893 <attribute name="maskedInterfaces" type="unsigned long">
11894 <desc>
11895 This is an advanced option for hiding one or more USB interfaces
11896 from the guest. The value is a bit mask where the bits that are set
11897 means the corresponding USB interface should be hidden, masked off
11898 if you like.
11899 This feature only works on Linux hosts.
11900 </desc>
11901 </attribute>
11902
11903 </interface>
11904
11905
11906 <!--
11907 // IHostUSBDevice
11908 /////////////////////////////////////////////////////////////////////////
11909 -->
11910
11911 <enum
11912 name="USBDeviceState"
11913 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
11914 >
11915 <desc>
11916 USB device state. This enumeration represents all possible states
11917 of the USB device physically attached to the host computer regarding
11918 its state on the host computer and availability to guest computers
11919 (all currently running virtual machines).
11920
11921 Once a supported USB device is attached to the host, global USB
11922 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
11923 either ignore the device, or put it to USBDeviceState_Held state, or do
11924 nothing. Unless the device is ignored by global filters, filters of all
11925 currently running guests (<link to="IUSBController::deviceFilters"/>) are
11926 activated that can put it to USBDeviceState_Captured state.
11927
11928 If the device was ignored by global filters, or didn't match
11929 any filters at all (including guest ones), it is handled by the host
11930 in a normal way. In this case, the device state is determined by
11931 the host and can be one of USBDeviceState_Unavailable, USBDeviceState_Busy
11932 or USBDeviceState_Available, depending on the current device usage.
11933
11934 Besides auto-capturing based on filters, the device can be manually
11935 captured by guests (<link to="IConsole::attachUSBDevice"/>) if its
11936 state is USBDeviceState_Busy, USBDeviceState_Available or
11937 USBDeviceState_Held.
11938
11939 <note>
11940 Due to differences in USB stack implementations in Linux and Win32,
11941 states USBDeviceState_Busy and USBDeviceState_vailable are applicable
11942 only to the Linux version of the product. This also means that (<link
11943 to="IConsole::attachUSBDevice"/>) can only succeed on Win32 if the
11944 device state is USBDeviceState_Held.
11945 </note>
11946
11947 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
11948 </desc>
11949
11950 <const name="NotSupported" value="0">
11951 <desc>
11952 Not supported by the VirtualBox server, not available to guests.
11953 </desc>
11954 </const>
11955 <const name="Unavailable" value="1">
11956 <desc>
11957 Being used by the host computer exclusively,
11958 not available to guests.
11959 </desc>
11960 </const>
11961 <const name="Busy" value="2">
11962 <desc>
11963 Being used by the host computer, potentially available to guests.
11964 </desc>
11965 </const>
11966 <const name="Available" value="3">
11967 <desc>
11968 Not used by the host computer, available to guests (the host computer
11969 can also start using the device at any time).
11970 </desc>
11971 </const>
11972 <const name="Held" value="4">
11973 <desc>
11974 Held by the VirtualBox server (ignored by the host computer),
11975 available to guests.
11976 </desc>
11977 </const>
11978 <const name="Captured" value="5">
11979 <desc>
11980 Captured by one of the guest computers, not available
11981 to anybody else.
11982 </desc>
11983 </const>
11984 </enum>
11985
11986 <interface
11987 name="IHostUSBDevice" extends="IUSBDevice"
11988 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
11989 wsmap="managed"
11990 >
11991 <desc>
11992 The IHostUSBDevice interface represents a physical USB device attached
11993 to the host computer.
11994
11995 Besides properties inherited from IUSBDevice, this interface adds the
11996 <link to="#state"/> property that holds the current state of the USB
11997 device.
11998
11999 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
12000 </desc>
12001
12002 <attribute name="state" type="USBDeviceState" readonly="yes">
12003 <desc>
12004 Current state of the device.
12005 </desc>
12006 </attribute>
12007
12008 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
12009
12010 </interface>
12011
12012
12013 <!--
12014 // IHostUSBDeviceFilter
12015 /////////////////////////////////////////////////////////////////////////
12016 -->
12017
12018 <enum
12019 name="USBDeviceFilterAction"
12020 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
12021 >
12022 <desc>
12023 Actions for host USB device filters.
12024 <see>IHostUSBDeviceFilter, USBDeviceState</see>
12025 </desc>
12026
12027 <const name="Null" value="0">
12028 <desc>Null value (never used by the API).</desc>
12029 </const>
12030 <const name="Ignore" value="1">
12031 <desc>Ignore the matched USB device.</desc>
12032 </const>
12033 <const name="Hold" value="2">
12034 <desc>Hold the matched USB device.</desc>
12035 </const>
12036 </enum>
12037
12038 <interface
12039 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
12040 uuid="4cc70246-d74a-400f-8222-3900489c0374"
12041 wsmap="managed"
12042 >
12043 <desc>
12044 The IHostUSBDeviceFilter interface represents a global filter for a
12045 physical USB device used by the host computer. Used indirectly in
12046 <link to="IHost::USBDeviceFilters"/>.
12047
12048 Using filters of this type, the host computer determines the initial
12049 state of the USB device after it is physically attached to the
12050 host's USB controller.
12051
12052 <note>
12053 The <link to="#remote"/> attribute is ignored by this type of
12054 filters, because it makes sense only for
12055 <link to="IUSBController::deviceFilters">machine USB filters</link>.
12056 </note>
12057
12058 <see>IHost::USBDeviceFilters</see>
12059 </desc>
12060
12061 <attribute name="action" type="USBDeviceFilterAction">
12062 <desc>
12063 Action performed by the host when an attached USB device
12064 matches this filter.
12065 </desc>
12066 </attribute>
12067
12068 </interface>
12069
12070 <!--
12071 // IAudioAdapter
12072 /////////////////////////////////////////////////////////////////////////
12073 -->
12074
12075 <enum
12076 name="AudioDriverType"
12077 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
12078 >
12079 <desc>
12080 Host audio driver type.
12081 </desc>
12082
12083 <const name="Null" value="0">
12084 <desc>Null value, also means "dummy audio driver".</desc>
12085 </const>
12086 <const name="WinMM" value="1"/>
12087 <const name="OSS" value="2"/>
12088 <const name="ALSA" value="3"/>
12089 <const name="DirectSound" value="4"/>
12090 <const name="CoreAudio" value="5"/>
12091 <const name="MMPM" value="6"/>
12092 <const name="Pulse" value="7"/>
12093 <const name="SolAudio" value="8"/>
12094 </enum>
12095
12096 <enum
12097 name="AudioControllerType"
12098 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
12099 >
12100 <desc>
12101 Virtual audio controller type.
12102 </desc>
12103
12104 <const name="AC97" value="0"/>
12105 <const name="SB16" value="1"/>
12106 </enum>
12107
12108 <interface
12109 name="IAudioAdapter" extends="$unknown"
12110 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
12111 wsmap="managed"
12112 >
12113 <desc>
12114 The IAudioAdapter interface represents the virtual audio adapter of
12115 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
12116 </desc>
12117 <attribute name="enabled" type="boolean">
12118 <desc>
12119 Flag whether the audio adapter is present in the
12120 guest system. If disabled, the virtual guest hardware will
12121 not contain any audio adapter. Can only be changed when
12122 the VM is not running.
12123 </desc>
12124 </attribute>
12125 <attribute name="audioController" type="AudioControllerType">
12126 <desc>
12127 The audio hardware we emulate.
12128 </desc>
12129 </attribute>
12130 <attribute name="audioDriver" type="AudioDriverType">
12131 <desc>
12132 Audio driver the adapter is connected to. This setting
12133 can only be changed when the VM is not running.
12134 </desc>
12135 </attribute>
12136 </interface>
12137
12138 <!--
12139 // IVRDPServer
12140 /////////////////////////////////////////////////////////////////////////
12141 -->
12142
12143 <enum
12144 name="VRDPAuthType"
12145 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
12146 >
12147 <desc>
12148 VRDP authentication type.
12149 </desc>
12150
12151 <const name="Null" value="0">
12152 <desc>Null value, also means "no authentication".</desc>
12153 </const>
12154 <const name="External" value="1"/>
12155 <const name="Guest" value="2"/>
12156 </enum>
12157
12158 <interface
12159 name="IVRDPServer" extends="$unknown"
12160 uuid="f4584ae7-6bce-474b-83d6-17d235e6aa89"
12161 wsmap="managed"
12162 >
12163 <attribute name="enabled" type="boolean">
12164 <desc>VRDP server status.</desc>
12165 </attribute>
12166
12167 <attribute name="port" type="unsigned long">
12168 <desc>
12169 VRDP server port number.
12170 <note>
12171 Setting the value of this property to <tt>0</tt> will reset the port
12172 number to the default value which is
12173 currently <tt>3389</tt>. Reading this property will always return a
12174 real port number, even after it has been set to <tt>0</tt> (in which
12175 case the default port is returned).
12176 </note>
12177 </desc>
12178 </attribute>
12179
12180 <attribute name="netAddress" type="wstring">
12181 <desc>VRDP server address.</desc>
12182 </attribute>
12183
12184 <attribute name="authType" type="VRDPAuthType">
12185 <desc>VRDP authentication method.</desc>
12186 </attribute>
12187
12188 <attribute name="authTimeout" type="unsigned long">
12189 <desc>Timeout for guest authentication. Milliseconds.</desc>
12190 </attribute>
12191
12192 <attribute name="allowMultiConnection" type="boolean">
12193 <desc>
12194 Flag whether multiple simultaneous connections to the VM are permitted.
12195 Note that this will be replaced by a more powerful mechanism in the future.
12196 </desc>
12197 </attribute>
12198
12199 <attribute name="reuseSingleConnection" type="boolean">
12200 <desc>
12201 Flag whether the existing connection must be dropped and a new connection
12202 must be established by the VRDP server, when a new client connects in single
12203 connection mode.
12204 </desc>
12205 </attribute>
12206
12207 </interface>
12208
12209
12210 <!--
12211 // ISharedFolder
12212 /////////////////////////////////////////////////////////////////////////
12213 -->
12214
12215 <interface
12216 name="ISharedFolder" extends="$unknown"
12217 uuid="64637bb2-9e17-471c-b8f3-f8968dd9884e"
12218 wsmap="struct"
12219 >
12220 <desc>
12221 The ISharedFolder interface represents a folder in the host computer's
12222 file system accessible from the guest OS running inside a virtual
12223 machine using an associated logical name.
12224
12225 There are three types of shared folders:
12226 <ul>
12227 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
12228 folders available to all virtual machines.</li>
12229 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
12230 VM-specific shared folders available to the given virtual machine at
12231 startup.</li>
12232 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
12233 VM-specific shared folders created in the session context (for
12234 example, when the virtual machine is running) and automatically
12235 discarded when the session is closed (the VM is powered off).</li>
12236 </ul>
12237
12238 Logical names of shared folders must be unique within the given scope
12239 (global, permanent or transient). However, they do not need to be unique
12240 across scopes. In this case, the definition of the shared folder in a
12241 more specific scope takes precedence over definitions in all other
12242 scopes. The order of precedence is (more specific to more general):
12243 <ol>
12244 <li>Transient definitions</li>
12245 <li>Permanent definitions</li>
12246 <li>Global definitions</li>
12247 </ol>
12248
12249 For example, if MyMachine has a shared folder named
12250 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then creating a
12251 transient shared folder named <tt>C_DRIVE</tt> (that points
12252 to <tt>C:\\\\WINDOWS</tt>) will change the definition
12253 of <tt>C_DRIVE</tt> in the guest OS so
12254 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
12255 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
12256 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
12257 the previous (permanent) definition of <tt>C_DRIVE</tt> that points
12258 to <tt>C:\\</tt> if it still exists.
12259
12260 Note that permanent and transient shared folders of different machines
12261 are in different name spaces, so they don't overlap and don't need to
12262 have unique logical names.
12263
12264 <note>
12265 Global shared folders are not implemented in the current version of the
12266 product.
12267 </note>
12268 </desc>
12269
12270 <attribute name="name" type="wstring" readonly="yes">
12271 <desc>Logical name of the shared folder.</desc>
12272 </attribute>
12273
12274 <attribute name="hostPath" type="wstring" readonly="yes">
12275 <desc>Full path to the shared folder in the host file system.</desc>
12276 </attribute>
12277
12278 <attribute name="accessible" type="boolean" readonly="yes">
12279 <desc>
12280 Whether the folder defined by the host path is currently
12281 accessible or not.
12282 For example, the folder can be unaccessible if it is placed
12283 on the network share that is not available by the time
12284 this property is read.
12285 </desc>
12286 </attribute>
12287
12288 <attribute name="writable" type="boolean" readonly="yes">
12289 <desc>
12290 Whether the folder defined by the host path is writable or
12291 not.
12292 </desc>
12293 </attribute>
12294
12295 <attribute name="lastAccessError" type="wstring" readonly="yes">
12296 <desc>
12297 Text message that represents the result of the last accessibility
12298 check.
12299
12300 Accessibility checks are performed each time the <link to="#accessible"/>
12301 attribute is read. A @c null string is returned if the last
12302 accessibility check was successful. A non-null string indicates a
12303 failure and should normally describe a reason of the failure (for
12304 example, a file read error).
12305 </desc>
12306 </attribute>
12307
12308 </interface>
12309
12310 <!--
12311 // ISession
12312 /////////////////////////////////////////////////////////////////////////
12313 -->
12314
12315 <interface
12316 name="IInternalSessionControl" extends="$unknown"
12317 uuid="b26552e7-9534-4f47-b766-98eac648a90d"
12318 internal="yes"
12319 wsmap="suppress"
12320 >
12321 <method name="getPID">
12322 <desc>PID of the process that has created this Session object.
12323 </desc>
12324 <param name="pid" type="unsigned long" dir="return"/>
12325 </method>
12326
12327 <method name="getRemoteConsole">
12328 <desc>
12329 Returns the console object suitable for remote control.
12330
12331 <result name="VBOX_E_INVALID_VM_STATE">
12332 Session state prevents operation.
12333 </result>
12334 <result name="VBOX_E_INVALID_OBJECT_STATE">
12335 Session type prevents operation.
12336 </result>
12337
12338 </desc>
12339 <param name="console" type="IConsole" dir="return"/>
12340 </method>
12341
12342 <method name="assignMachine">
12343 <desc>
12344 Assigns the machine object associated with this direct-type
12345 session or informs the session that it will be a remote one
12346 (if @a machine == NULL).
12347
12348 <result name="VBOX_E_INVALID_VM_STATE">
12349 Session state prevents operation.
12350 </result>
12351 <result name="VBOX_E_INVALID_OBJECT_STATE">
12352 Session type prevents operation.
12353 </result>
12354
12355 </desc>
12356 <param name="machine" type="IMachine" dir="in"/>
12357 </method>
12358
12359 <method name="assignRemoteMachine">
12360 <desc>
12361 Assigns the machine and the (remote) console object associated with
12362 this remote-type session.
12363
12364 <result name="VBOX_E_INVALID_VM_STATE">
12365 Session state prevents operation.
12366 </result>
12367
12368 </desc>
12369 <param name="machine" type="IMachine" dir="in"/>
12370 <param name="console" type="IConsole" dir="in"/>
12371 </method>
12372
12373 <method name="updateMachineState">
12374 <desc>
12375 Updates the machine state in the VM process.
12376 Must be called only in certain cases
12377 (see the method implementation).
12378
12379 <result name="VBOX_E_INVALID_VM_STATE">
12380 Session state prevents operation.
12381 </result>
12382 <result name="VBOX_E_INVALID_OBJECT_STATE">
12383 Session type prevents operation.
12384 </result>
12385
12386 </desc>
12387 <param name="aMachineState" type="MachineState" dir="in"/>
12388 </method>
12389
12390 <method name="uninitialize">
12391 <desc>
12392 Uninitializes (closes) this session. Used by VirtualBox to close
12393 the corresponding remote session when the direct session dies
12394 or gets closed.
12395
12396 <result name="VBOX_E_INVALID_VM_STATE">
12397 Session state prevents operation.
12398 </result>
12399
12400 </desc>
12401 </method>
12402
12403 <method name="onDVDDriveChange">
12404 <desc>
12405 Triggered when settings of the DVD drive object of the
12406 associated virtual machine have changed.
12407
12408 <result name="VBOX_E_INVALID_VM_STATE">
12409 Session state prevents operation.
12410 </result>
12411 <result name="VBOX_E_INVALID_OBJECT_STATE">
12412 Session type prevents operation.
12413 </result>
12414
12415 </desc>
12416 </method>
12417
12418 <method name="onFloppyDriveChange">
12419 <desc>
12420 Triggered when settings of the floppy drive object of the
12421 associated virtual machine have changed.
12422
12423 <result name="VBOX_E_INVALID_VM_STATE">
12424 Session state prevents operation.
12425 </result>
12426 <result name="VBOX_E_INVALID_OBJECT_STATE">
12427 Session type prevents operation.
12428 </result>
12429
12430 </desc>
12431 </method>
12432
12433 <method name="onNetworkAdapterChange">
12434 <desc>
12435 Triggered when settings of a network adapter of the
12436 associated virtual machine have changed.
12437
12438 <result name="VBOX_E_INVALID_VM_STATE">
12439 Session state prevents operation.
12440 </result>
12441 <result name="VBOX_E_INVALID_OBJECT_STATE">
12442 Session type prevents operation.
12443 </result>
12444
12445 </desc>
12446 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
12447 </method>
12448
12449 <method name="onSerialPortChange">
12450 <desc>
12451 Triggered when settings of a serial port of the
12452 associated virtual machine have changed.
12453
12454 <result name="VBOX_E_INVALID_VM_STATE">
12455 Session state prevents operation.
12456 </result>
12457 <result name="VBOX_E_INVALID_OBJECT_STATE">
12458 Session type prevents operation.
12459 </result>
12460
12461 </desc>
12462 <param name="serialPort" type="ISerialPort" dir="in"/>
12463 </method>
12464
12465 <method name="onParallelPortChange">
12466 <desc>
12467 Triggered when settings of a parallel port of the
12468 associated virtual machine have changed.
12469
12470 <result name="VBOX_E_INVALID_VM_STATE">
12471 Session state prevents operation.
12472 </result>
12473 <result name="VBOX_E_INVALID_OBJECT_STATE">
12474 Session type prevents operation.
12475 </result>
12476
12477 </desc>
12478 <param name="parallelPort" type="IParallelPort" dir="in"/>
12479 </method>
12480
12481 <method name="onStorageControllerChange">
12482 <desc>
12483 Triggered when settings of a storage controller of the
12484 associated virtual machine have changed.
12485
12486 <result name="VBOX_E_INVALID_VM_STATE">
12487 Session state prevents operation.
12488 </result>
12489 <result name="VBOX_E_INVALID_OBJECT_STATE">
12490 Session type prevents operation.
12491 </result>
12492
12493 </desc>
12494 </method>
12495
12496 <method name="onVRDPServerChange">
12497 <desc>
12498 Triggered when settings of the VRDP server object of the
12499 associated virtual machine have changed.
12500
12501 <result name="VBOX_E_INVALID_VM_STATE">
12502 Session state prevents operation.
12503 </result>
12504 <result name="VBOX_E_INVALID_OBJECT_STATE">
12505 Session type prevents operation.
12506 </result>
12507
12508 </desc>
12509 </method>
12510
12511 <method name="onUSBControllerChange">
12512 <desc>
12513 Triggered when settings of the USB controller object of the
12514 associated virtual machine have changed.
12515
12516 <result name="VBOX_E_INVALID_VM_STATE">
12517 Session state prevents operation.
12518 </result>
12519 <result name="VBOX_E_INVALID_OBJECT_STATE">
12520 Session type prevents operation.
12521 </result>
12522
12523 </desc>
12524 </method>
12525
12526 <method name="onSharedFolderChange">
12527 <desc>
12528 Triggered when a permanent (global or machine) shared folder has been
12529 created or removed.
12530 <note>
12531 We don't pass shared folder parameters in this notification because
12532 the order in which parallel notifications are delivered is not defined,
12533 therefore it could happen that these parameters were outdated by the
12534 time of processing this notification.
12535 </note>
12536
12537 <result name="VBOX_E_INVALID_VM_STATE">
12538 Session state prevents operation.
12539 </result>
12540 <result name="VBOX_E_INVALID_OBJECT_STATE">
12541 Session type prevents operation.
12542 </result>
12543
12544 </desc>
12545 <param name="global" type="boolean" dir="in"/>
12546 </method>
12547
12548 <method name="onUSBDeviceAttach">
12549 <desc>
12550 Triggered when a request to capture a USB device (as a result
12551 of matched USB filters or direct call to
12552 <link to="IConsole::attachUSBDevice"/>) has completed.
12553 A @c null @a error object means success, otherwise it
12554 describes a failure.
12555
12556 <result name="VBOX_E_INVALID_VM_STATE">
12557 Session state prevents operation.
12558 </result>
12559 <result name="VBOX_E_INVALID_OBJECT_STATE">
12560 Session type prevents operation.
12561 </result>
12562
12563 </desc>
12564 <param name="device" type="IUSBDevice" dir="in"/>
12565 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12566 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
12567 </method>
12568
12569 <method name="onUSBDeviceDetach">
12570 <desc>
12571 Triggered when a request to release the USB device (as a result
12572 of machine termination or direct call to
12573 <link to="IConsole::detachUSBDevice"/>) has completed.
12574 A @c null @a error object means success, otherwise it
12575
12576 <result name="VBOX_E_INVALID_VM_STATE">
12577 Session state prevents operation.
12578 </result>
12579 <result name="VBOX_E_INVALID_OBJECT_STATE">
12580 Session type prevents operation.
12581 </result>
12582
12583 </desc>
12584 <param name="id" type="wstring" dir="in"/>
12585 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12586 </method>
12587
12588 <method name="onShowWindow">
12589 <desc>
12590 Called by <link to="IMachine::canShowConsoleWindow"/> and by
12591 <link to="IMachine::showConsoleWindow"/> in order to notify
12592 console callbacks
12593 <link to="IConsoleCallback::onCanShowWindow"/>
12594 and <link to="IConsoleCallback::onShowWindow"/>.
12595
12596 <result name="VBOX_E_INVALID_OBJECT_STATE">
12597 Session type prevents operation.
12598 </result>
12599
12600 </desc>
12601 <param name="check" type="boolean" dir="in"/>
12602 <param name="canShow" type="boolean" dir="out"/>
12603 <param name="winId" type="unsigned long long" dir="out"/>
12604 </method>
12605
12606 <method name="accessGuestProperty">
12607 <desc>
12608 Called by <link to="IMachine::getGuestProperty"/> and by
12609 <link to="IMachine::setGuestProperty"/> in order to read and
12610 modify guest properties.
12611
12612 <result name="VBOX_E_INVALID_VM_STATE">
12613 Machine session is not open.
12614 </result>
12615 <result name="VBOX_E_INVALID_OBJECT_STATE">
12616 Session type is not direct.
12617 </result>
12618
12619 </desc>
12620 <param name="name" type="wstring" dir="in"/>
12621 <param name="value" type="wstring" dir="in"/>
12622 <param name="flags" type="wstring" dir="in"/>
12623 <param name="isSetter" type="boolean" dir="in"/>
12624 <param name="retValue" type="wstring" dir="out"/>
12625 <param name="retTimestamp" type="unsigned long long" dir="out"/>
12626 <param name="retFlags" type="wstring" dir="out"/>
12627 </method>
12628
12629 <method name="enumerateGuestProperties">
12630 <desc>
12631 Return a list of the guest properties matching a set of patterns along
12632 with their values, time stamps and flags.
12633
12634 <result name="VBOX_E_INVALID_VM_STATE">
12635 Machine session is not open.
12636 </result>
12637 <result name="VBOX_E_INVALID_OBJECT_STATE">
12638 Session type is not direct.
12639 </result>
12640
12641 </desc>
12642 <param name="patterns" type="wstring" dir="in">
12643 <desc>
12644 The patterns to match the properties against as a comma-separated
12645 string. If this is empty, all properties currently set will be
12646 returned.
12647 </desc>
12648 </param>
12649 <param name="key" type="wstring" dir="out" safearray="yes">
12650 <desc>
12651 The key names of the properties returned.
12652 </desc>
12653 </param>
12654 <param name="value" type="wstring" dir="out" safearray="yes">
12655 <desc>
12656 The values of the properties returned. The array entries match the
12657 corresponding entries in the @a key array.
12658 </desc>
12659 </param>
12660 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
12661 <desc>
12662 The time stamps of the properties returned. The array entries match
12663 the corresponding entries in the @a key array.
12664 </desc>
12665 </param>
12666 <param name="flags" type="wstring" dir="out" safearray="yes">
12667 <desc>
12668 The flags of the properties returned. The array entries match the
12669 corresponding entries in the @a key array.
12670 </desc>
12671 </param>
12672 </method>
12673
12674 </interface>
12675
12676 <interface
12677 name="ISession" extends="$dispatched"
12678 uuid="12F4DCDB-12B2-4ec1-B7CD-DDD9F6C5BF4D"
12679 wsmap="managed"
12680 >
12681 <desc>
12682 The ISession interface represents a serialization primitive for virtual
12683 machines.
12684
12685 With VirtualBox, every time one wishes to manipulate a virtual machine
12686 (e.g. change its settings or start execution), a session object is
12687 required. Such an object must be passed to one of the session methods
12688 that open the given session, which then initiates the machine manipulation.
12689
12690 A session serves several purposes: it identifies to the inter-process VirtualBox
12691 code which process is currently working with the virtual machine, and it ensures
12692 that there are no incompatible requests from several processes for the
12693 same virtual machine. Session objects can therefore be thought of as mutex
12694 semaphores that lock virtual machines to prevent conflicting accesses from
12695 several processes.
12696
12697 How sessions objects are used depends on whether you use the Main API
12698 via COM or via the webservice:
12699
12700 <ul>
12701 <li>When using the COM API directly, an object of the Session class from the
12702 VirtualBox type library needs to be created. In regular COM C++ client code,
12703 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
12704 This object will then act as a local session object in further calls to open
12705 a session.
12706 </li>
12707
12708 <li>In the webservice, the session manager (IWebsessionManager) instead creates
12709 one session object automatically when <link to="IWebsessionManager::logon" />
12710 is called. A managed object reference to that session object can be retrieved by
12711 calling <link to="IWebsessionManager::getSessionObject" />. This session object
12712 reference can then be used to open sessions.
12713 </li>
12714 </ul>
12715
12716 Sessions are mainly used in two variations:
12717
12718 <ul>
12719 <li>
12720 To start a virtual machine in a separate process, one would call
12721 <link to="IVirtualBox::openRemoteSession"/>, which requires a session
12722 object as its first parameter. This session then identifies the caller
12723 and lets him control the started machine (for example, pause machine
12724 execution or power it down) as well as be notified about machine
12725 execution state changes.
12726 </li>
12727
12728 <li>To alter machine settings, or to start machine execution within the
12729 current process, one needs to open a direct session for the machine first by
12730 calling <link to="IVirtualBox::openSession"/>. While a direct session
12731 is open within one process, no any other process may open another direct
12732 session for the same machine. This prevents the machine from being changed
12733 by other processes while it is running or while the machine is being configured.
12734 </li>
12735 </ul>
12736
12737 One also can attach to an existing direct session already opened by
12738 another process (for example, in order to send a control request to the
12739 virtual machine such as the pause or the reset request). This is done by
12740 calling <link to="IVirtualBox::openExistingSession"/>.
12741
12742 <note>
12743 Unless you are trying to write a new VirtualBox front-end that
12744 performs direct machine execution (like the VirtualBox or VBoxSDL
12745 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
12746 session opened by <link to="IVirtualBox::openSession"/> and use this
12747 session only to change virtual machine settings. If you simply want to
12748 start virtual machine execution using one of the existing front-ends
12749 (for example the VirtualBox GUI or headless server), simply use
12750 <link to="IVirtualBox::openRemoteSession"/>; these front-ends
12751 will power up the machine automatically for you.
12752 </note>
12753 </desc>
12754
12755 <attribute name="state" type="SessionState" readonly="yes">
12756 <desc>Current state of this session.</desc>
12757 </attribute>
12758
12759 <attribute name="type" type="SessionType" readonly="yes">
12760 <desc>
12761 Type of this session. The value of this attribute is valid only
12762 if the session is currently open (i.e. its #state is
12763 SessionType_SessionOpen), otherwise an error will be returned.
12764 </desc>
12765 </attribute>
12766
12767 <attribute name="machine" type="IMachine" readonly="yes">
12768 <desc>Machine object associated with this session.</desc>
12769 </attribute>
12770
12771 <attribute name="console" type="IConsole" readonly="yes">
12772 <desc>Console object associated with this session.</desc>
12773 </attribute>
12774
12775 <method name="close">
12776 <desc>
12777 Closes a session that was previously opened.
12778
12779 It is recommended that every time an "open session" method (such as
12780 <link to="IVirtualBox::openRemoteSession" /> or
12781 <link to="IVirtualBox::openSession" />) has been called to
12782 manipulate a virtual machine, the caller invoke
12783 ISession::close() when it's done doing so. Since sessions are
12784 serialization primitives much like ordinary mutexes, they are
12785 best used the same way: for each "open" call, there should be
12786 a matching "close" call, even when errors occur.
12787
12788 Otherwise, if a direct session for a machine opened with
12789 <link to="IVirtualBox::openSession"/> is not explicitly closed
12790 when the application terminates, the state of the machine will
12791 be set to <link to="MachineState_Aborted" /> on the server.
12792
12793 Generally, it is recommended to close all open sessions explicitly
12794 before terminating the application (regardless of the reason for
12795 the termination).
12796
12797 <note>
12798 Do not expect the session state (<link to="ISession::state" />
12799 to return to "Closed" immediately after you invoke
12800 ISession::close(), particularly if you have started a remote
12801 session to execute the VM in a new process. The session state will
12802 automatically return to "Closed" once the VM is no longer executing,
12803 which can of course take a very long time.
12804 </note>
12805
12806 <result name="E_UNEXPECTED">
12807 Session is not open.
12808 </result>
12809
12810 </desc>
12811 </method>
12812
12813 </interface>
12814
12815 <!--
12816 // IStorageController
12817 /////////////////////////////////////////////////////////////////////////
12818 -->
12819
12820 <enum
12821 name="StorageBus"
12822 uuid="f381fdca-5953-41d0-b2bd-0542b012698d"
12823 >
12824 <desc>
12825 The connection type of the storage controller.
12826 </desc>
12827 <const name="Null" value="0">
12828 <desc><tt>null</tt> value. Never used by the API.</desc>
12829 </const>
12830 <const name="IDE" value="1"/>
12831 <const name="SATA" value="2"/>
12832 <const name="SCSI" value="3"/>
12833 </enum>
12834
12835 <enum
12836 name="StorageControllerType"
12837 uuid="685387db-a837-4320-a258-08f46a22f62a"
12838 >
12839 <desc>
12840 Storage controller type.
12841 </desc>
12842
12843 <const name="Null" value="0">
12844 <desc><tt>null</tt> value. Never used by the API.</desc>
12845 </const>
12846 <const name="LsiLogic" value="1"/>
12847 <const name="BusLogic" value="2"/>
12848 <const name="IntelAhci" value="3"/>
12849 <const name="PIIX3" value="4"/>
12850 <const name="PIIX4" value="5"/>
12851 <const name="ICH6" value="6"/>
12852 </enum>
12853
12854 <interface
12855 name="IStorageController" extends="$unknown"
12856 uuid="6bf8335b-d14a-44a5-9b45-ddc49ce7d5b2"
12857 wsmap="managed"
12858 >
12859 <desc>
12860 Represents a storage controller that is attached to a virtual machine
12861 (<link to="IMachine" />). Just as hard disks are attached to storage
12862 controllers in a real computer, virtual hard disks (represented by
12863 <link to="IHardDisk" />) are attached to virtual storage controllers,
12864 represented by this interface.
12865
12866 VirtualBox supports three types of virtual storage controller hardware:
12867 IDE, SCSI, and SATA (see <link to="#bus" />). Depending on which of
12868 these three is used, certain sub-types are available and can be
12869 selected in <link to="#controllerType" />.
12870 </desc>
12871
12872 <attribute name="name" type="wstring" readonly="yes">
12873 <desc>
12874 Name of the storage controller, as originally specified with
12875 <link to="IMachine::addStorageController" />. This then uniquely
12876 identifies this controller with other method calls such as
12877 <link to="IMachine::attachHardDisk" />.
12878 </desc>
12879 </attribute>
12880
12881 <attribute name="maxDevicesPerPortCount" type="unsigned long" readonly="yes">
12882 <desc>
12883 Maximum number of devices which can be attached to one port.
12884 </desc>
12885 </attribute>
12886
12887 <attribute name="minPortCount" type="unsigned long" readonly="yes">
12888 <desc>
12889 Minimum number of ports that <link to="IStorageController::portCount"/> can be set to.
12890 </desc>
12891 </attribute>
12892
12893 <attribute name="maxPortCount" type="unsigned long" readonly="yes">
12894 <desc>
12895 Maximum number of ports that <link to="IStorageController::portCount"/> can be set to.
12896 </desc>
12897 </attribute>
12898
12899 <attribute name="instance" type="unsigned long">
12900 <desc>
12901 The instance number of the device in the running VM.
12902 </desc>
12903 </attribute>
12904
12905 <attribute name="portCount" type="unsigned long">
12906 <desc>
12907 The number of currently usable ports on the controller.
12908 The minimum and maximum number of ports for one controller are
12909 stored in <link to="IStorageController::minPortCount"/>
12910 and <link to="IStorageController::maxPortCount"/>.
12911 </desc>
12912 </attribute>
12913
12914 <attribute name="bus" type="StorageBus" readonly="yes">
12915 <desc>
12916 The connection type of the storage controller.
12917 </desc>
12918 </attribute>
12919
12920 <attribute name="controllerType" type="StorageControllerType">
12921 <desc>
12922 Type of the virtual storage controller. Depending on this value,
12923 VirtualBox will provide a different virtual storage controller hardware
12924 to the guest.
12925
12926 For SCSI controllers, the default type is LsiLogic.
12927 </desc>
12928 </attribute>
12929
12930 <method name="GetIDEEmulationPort">
12931 <desc>
12932 Gets the corresponding port number which is emulated as an IDE device.
12933
12934 <result name="E_INVALIDARG">
12935 The @a devicePosition is not in the range 0 to 3.
12936 </result>
12937 <result name="E_NOTIMPL">
12938 The storage controller type is not SATAIntelAhci.
12939 </result>
12940
12941 </desc>
12942 <param name="devicePosition" type="long" dir="in"/>
12943 <param name="portNumber" type="long" dir="return"/>
12944 </method>
12945
12946 <method name="SetIDEEmulationPort">
12947 <desc>
12948 Sets the port number which is emulated as an IDE device.
12949
12950 <result name="E_INVALIDARG">
12951 The @a devicePosition is not in the range 0 to 3 or the
12952 @a portNumber is not in the range 0 to 29.
12953 </result>
12954 <result name="E_NOTIMPL">
12955 The storage controller type is not SATAIntelAhci.
12956 </result>
12957
12958 </desc>
12959 <param name="devicePosition" type="long" dir="in"/>
12960 <param name="portNumber" type="long" dir="in"/>
12961 </method>
12962
12963 </interface>
12964
12965<if target="wsdl">
12966
12967 <!--
12968 // IManagedObjectRef
12969 /////////////////////////////////////////////////////////////////////////
12970 -->
12971
12972 <interface
12973 name="IManagedObjectRef" extends="$unknown"
12974 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
12975 internal="yes"
12976 wsmap="managed"
12977 wscpp="hardcoded"
12978 >
12979 <desc>
12980 Managed object reference.
12981
12982 Only within the webservice, a managed object reference (which is really
12983 an opaque number) allows a webservice client to address an object
12984 that lives in the address space of the webservice server.
12985
12986 Behind each managed object reference, there is a COM object that lives
12987 in the webservice server's address space. The COM object is not freed
12988 until the managed object reference is released, either by an explicit
12989 call to <link to="IManagedObjectRef::release" /> or by logging off from
12990 the webservice (<link to="IWebsessionManager::logoff" />), which releases
12991 all objects created during the webservice session.
12992
12993 Whenever a method call of the VirtualBox API returns a COM object, the
12994 webservice representation of that method will instead return a
12995 managed object reference, which can then be used to invoke methods
12996 on that object.
12997 </desc>
12998
12999 <method name="getInterfaceName">
13000 <desc>
13001 Returns the name of the interface that this managed object represents,
13002 for example, "IMachine", as a string.
13003 </desc>
13004 <param name="return" type="wstring" dir="return"/>
13005 </method>
13006
13007 <method name="release">
13008 <desc>
13009 Releases this managed object reference and frees the resources that
13010 were allocated for it in the webservice server process. After calling
13011 this method, the identifier of the reference can no longer be used.
13012 </desc>
13013 </method>
13014
13015 </interface>
13016
13017 <!--
13018 // IWebsessionManager
13019 /////////////////////////////////////////////////////////////////////////
13020 -->
13021
13022 <interface
13023 name="IWebsessionManager" extends="$unknown"
13024 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
13025 internal="yes"
13026 wsmap="global"
13027 wscpp="hardcoded"
13028 >
13029 <desc>
13030 Websession manager. This provides essential services
13031 to webservice clients.
13032 </desc>
13033 <method name="logon">
13034 <desc>
13035 Logs a new client onto the webservice and returns a managed object reference to
13036 the IVirtualBox instance, which the client can then use as a basis to further
13037 queries, since all calls to the VirtualBox API are based on the IVirtualBox
13038 interface, in one way or the other.
13039 </desc>
13040 <param name="username" type="wstring" dir="in"/>
13041 <param name="password" type="wstring" dir="in"/>
13042 <param name="return" type="IVirtualBox" dir="return"/>
13043 </method>
13044
13045 <method name="getSessionObject">
13046 <desc>
13047 Returns a managed object reference to the internal ISession object that was created
13048 for this web service session when the client logged on.
13049
13050 <see>ISession</see>
13051 </desc>
13052 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13053 <param name="return" type="ISession" dir="return"/>
13054 </method>
13055
13056 <method name="logoff">
13057 <desc>
13058 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
13059 and destroys all resources associated with the session (most importantly, all
13060 managed objects created in the server while the session was active).
13061 </desc>
13062 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13063 </method>
13064
13065 </interface>
13066
13067</if>
13068
13069 <!--
13070 // IPerformanceCollector & friends
13071 /////////////////////////////////////////////////////////////////////////
13072 -->
13073
13074 <interface
13075 name="IPerformanceMetric" extends="$unknown"
13076 uuid="2a1a60ae-9345-4019-ad53-d34ba41cbfe9" wsmap="managed"
13077 >
13078 <desc>
13079 The IPerformanceMetric interface represents parameters of the given
13080 performance metric.
13081 </desc>
13082
13083 <attribute name="metricName" type="wstring" readonly="yes">
13084 <desc>
13085 Name of the metric.
13086 </desc>
13087 </attribute>
13088
13089 <attribute name="object" type="$unknown" readonly="yes">
13090 <desc>
13091 Object this metric belongs to.
13092 </desc>
13093 </attribute>
13094
13095 <attribute name="description" type="wstring" readonly="yes">
13096 <desc>
13097 Textual description of the metric.
13098 </desc>
13099 </attribute>
13100
13101 <attribute name="period" type="unsigned long" readonly="yes">
13102 <desc>
13103 Time interval between samples, measured in seconds.
13104 </desc>
13105 </attribute>
13106
13107 <attribute name="count" type="unsigned long" readonly="yes">
13108 <desc>
13109 Number of recent samples retained by the performance collector for this
13110 metric.
13111
13112 When the collected sample count exceeds this number, older samples
13113 are discarded.
13114 </desc>
13115 </attribute>
13116
13117 <attribute name="unit" type="wstring" readonly="yes">
13118 <desc>
13119 Unit of measurement.
13120 </desc>
13121 </attribute>
13122
13123 <attribute name="minimumValue" type="long" readonly="yes">
13124 <desc>
13125 Minimum possible value of this metric.
13126 </desc>
13127 </attribute>
13128
13129 <attribute name="maximumValue" type="long" readonly="yes">
13130 <desc>
13131 Maximum possible value of this metric.
13132 </desc>
13133 </attribute>
13134 </interface>
13135
13136 <interface
13137 name="IPerformanceCollector" extends="$unknown"
13138 uuid="e22e1acb-ac4a-43bb-a31c-17321659b0c6"
13139 wsmap="managed"
13140 >
13141 <desc>
13142 The IPerformanceCollector interface represents a service that collects and
13143 stores performance metrics data.
13144
13145 Performance metrics are associated with objects of interfaces like IHost and
13146 IMachine. Each object has a distinct set of performance metrics.
13147 The set can be obtained with <link to="IPerformanceCollector::getMetrics"/>.
13148
13149 Metric data is collected at the specified intervals and is retained
13150 internally. The interval and the number of retained samples can be set
13151 with <link to="IPerformanceCollector::setupMetrics" />.
13152
13153 Metrics are organized hierarchically, with each level separated by a
13154 slash (/) character. Generally, the scheme for metric names is like this:
13155
13156 <tt>Category/Metric[/SubMetric][:aggregation]</tt>
13157
13158 "Category/Metric" together form the base metric name. A base metric is the
13159 smallest unit for which a sampling interval and the number of retained
13160 samples can be set. Only base metrics can be enabled and disabled. All
13161 sub-metrics are collected when their base metric is collected.
13162 Collected values for any set of sub-metrics can be queried with
13163 <link to="IPerformanceCollector::queryMetricsData" />.
13164
13165 For example "CPU/Load/User:avg"
13166 metric name stands for the "CPU" category, "Load" metric, "User" submetric,
13167 "average" aggregate. An aggregate function is computed over all retained
13168 data. Valid aggregate functions are:
13169
13170 <ul>
13171 <li>avg -- average</li>
13172 <li>min -- minimum</li>
13173 <li>max -- maximum</li>
13174 </ul>
13175
13176 When setting up
13177 metric parameters, querying metric data, enabling or disabling metrics
13178 wildcards can be used in metric names to specify a subset of metrics. For
13179 example, to select all CPU-related metrics use <tt>CPU/*</tt>, all
13180 averages can be queried using <tt>*:avg</tt> and so on. To query metric
13181 values without aggregates <tt>*:</tt> can be used.
13182
13183 The valid names for base metrics are:
13184
13185 <ul>
13186 <li>CPU/Load</li>
13187 <li>CPU/MHz</li>
13188 <li>RAM/Usage</li>
13189 </ul>
13190
13191 The general sequence for collecting and retrieving the metrics is:
13192 <ul>
13193 <li>
13194 Obtain an instance of IPerformanceCollector with
13195 <link to="IVirtualBox::performanceCollector" />
13196 </li>
13197 <li>
13198 Allocate and populate an array with references to objects the metrics
13199 will be collected for. Use references to IHost and IMachine objects.
13200 </li>
13201 <li>
13202 Allocate and populate an array with base metric names the data will be
13203 collected for.
13204 </li>
13205 <li>
13206 Call <link to="IPerformanceCollector::setupMetrics" />. From now on the
13207 metric data will be collected and stored.
13208 </li>
13209 <li>
13210 Wait for the data to get collected.
13211 </li>
13212 <li>
13213 Allocate and populate an array with references to objects the metric
13214 values will be queried for. You can re-use the object array used for
13215 setting base metrics.
13216 </li>
13217 <li>
13218 Allocate and populate an array with metric names the data will be
13219 collected for. Note that metric names differ from base metric names.
13220 </li>
13221 <li>
13222 Call <link to="IPerformanceCollector::queryMetricsData" />. The data that
13223 have been collected so far are returned. Note that the values are still
13224 retained internally and data collection continues.
13225 </li>
13226 </ul>
13227
13228 For an example of usage refer to the following files in VirtualBox SDK:
13229 <ul>
13230 <li>
13231 Java: <tt>bindings/webservice/java/jax-ws/samples/metrictest.java</tt>
13232 </li>
13233 <li>
13234 Python: <tt>bindings/xpcom/python/sample/shellcommon.py</tt>
13235 </li>
13236 </ul>
13237 </desc>
13238
13239 <attribute name="metricNames" type="wstring" readonly="yes" safearray="yes">
13240 <desc>
13241 Array of unique names of metrics.
13242
13243 This array represents all metrics supported by the performance
13244 collector. Individual objects do not necessarily support all of them.
13245 <link to="IPerformanceCollector::getMetrics"/> can be used to get the
13246 list of supported metrics for a particular object.
13247 </desc>
13248 </attribute>
13249
13250 <method name="getMetrics">
13251 <desc>
13252 Returns parameters of specified metrics for a set of objects.
13253 <note>
13254 @c Null metrics array means all metrics. @c Null object array means
13255 all existing objects.
13256 </note>
13257 </desc>
13258 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13259 <desc>
13260 Metric name filter. Currently, only a comma-separated list of metrics
13261 is supported.
13262 </desc>
13263 </param>
13264 <param name="objects" type="$unknown" dir="in" safearray="yes">
13265 <desc>
13266 Set of objects to return metric parameters for.
13267 </desc>
13268 </param>
13269 <param name="metrics" type="IPerformanceMetric" dir="return" safearray="yes">
13270 <desc>
13271 Array of returned metric parameters.
13272 </desc>
13273 </param>
13274 </method>
13275
13276 <method name="setupMetrics">
13277 <desc>
13278 Sets parameters of specified base metrics for a set of objects. Returns
13279 an array of <link to="IPerformanceMetric" /> describing the metrics have
13280 been affected.
13281 <note>
13282 @c Null or empty metric name array means all metrics. @c Null or empty
13283 object array means all existing objects. If metric name array contains
13284 a single element and object array contains many, the single metric
13285 name array element is applied to each object array element to form
13286 metric/object pairs.
13287 </note>
13288 </desc>
13289 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13290 <desc>
13291 Metric name filter. Comma-separated list of metrics with wildcard
13292 support.
13293 </desc>
13294 </param>
13295 <param name="objects" type="$unknown" dir="in" safearray="yes">
13296 <desc>
13297 Set of objects to setup metric parameters for.
13298 </desc>
13299 </param>
13300 <param name="period" type="unsigned long" dir="in">
13301 <desc>
13302 Time interval in seconds between two consecutive samples of performance
13303 data.
13304 </desc>
13305 </param>
13306 <param name="count" type="unsigned long" dir="in">
13307 <desc>
13308 Number of samples to retain in performance data history. Older samples
13309 get discarded.
13310 </desc>
13311 </param>
13312 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13313 <desc>
13314 Array of metrics that have been modified by the call to this method.
13315 </desc>
13316 </param>
13317 </method>
13318
13319 <method name="enableMetrics">
13320 <desc>
13321 Turns on collecting specified base metrics. Returns an array of
13322 <link to="IPerformanceMetric" /> describing the metrics have been
13323 affected.
13324 <note>
13325 @c Null or empty metric name array means all metrics. @c Null or empty
13326 object array means all existing objects. If metric name array contains
13327 a single element and object array contains many, the single metric
13328 name array element is applied to each object array element to form
13329 metric/object pairs.
13330 </note>
13331 </desc>
13332 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13333 <desc>
13334 Metric name filter. Comma-separated list of metrics with wildcard
13335 support.
13336 </desc>
13337 </param>
13338 <param name="objects" type="$unknown" dir="in" safearray="yes">
13339 <desc>
13340 Set of objects to enable metrics for.
13341 </desc>
13342 </param>
13343 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13344 <desc>
13345 Array of metrics that have been modified by the call to this method.
13346 </desc>
13347 </param>
13348 </method>
13349
13350 <method name="disableMetrics">
13351 <desc>
13352 Turns off collecting specified base metrics. Returns an array of
13353 <link to="IPerformanceMetric" /> describing the metrics have been
13354 affected.
13355 <note>
13356 @c Null or empty metric name array means all metrics. @c Null or empty
13357 object array means all existing objects. If metric name array contains
13358 a single element and object array contains many, the single metric
13359 name array element is applied to each object array element to form
13360 metric/object pairs.
13361 </note>
13362 </desc>
13363 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13364 <desc>
13365 Metric name filter. Comma-separated list of metrics with wildcard
13366 support.
13367 </desc>
13368 </param>
13369 <param name="objects" type="$unknown" dir="in" safearray="yes">
13370 <desc>
13371 Set of objects to disable metrics for.
13372 </desc>
13373 </param>
13374 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13375 <desc>
13376 Array of metrics that have been modified by the call to this method.
13377 </desc>
13378 </param>
13379 </method>
13380
13381 <method name="queryMetricsData">
13382 <desc>
13383 Queries collected metrics data for a set of objects.
13384
13385 The data itself and related metric information are returned in seven
13386 parallel and one flattened array of arrays. Elements of
13387 <tt>returnMetricNames, returnObjects, returnUnits, returnScales,
13388 returnSequenceNumbers, returnDataIndices and returnDataLengths</tt> with
13389 the same index describe one set of values corresponding to a single
13390 metric.
13391
13392 The <tt>returnData</tt> parameter is a flattened array of arrays. Each
13393 start and length of a sub-array is indicated by
13394 <tt>returnDataIndices</tt> and <tt>returnDataLengths</tt>. The first
13395 value for metric <tt>metricNames[i]</tt> is at
13396 <tt>returnData[returnIndices[i]]</tt>.
13397
13398 <note>
13399 @c Null or empty metric name array means all metrics. @c Null or empty
13400 object array means all existing objects. If metric name array contains
13401 a single element and object array contains many, the single metric
13402 name array element is applied to each object array element to form
13403 metric/object pairs.
13404 </note>
13405 <note>
13406 Data collection continues behind the scenes after call to
13407 @c queryMetricsData. The return data can be seen as the snapshot of
13408 the current state at the time of @c queryMetricsData call. The
13409 internally kept metric values are not cleared by the call. This makes
13410 possible querying different subsets of metrics or aggregates with
13411 subsequent calls. If periodic querying is needed it is highly
13412 suggested to query the values with @c interval*count period to avoid
13413 confusion. This way a completely new set of data values will be
13414 provided by each query.
13415 </note>
13416 </desc>
13417 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13418 <desc>
13419 Metric name filter. Comma-separated list of metrics with wildcard
13420 support.
13421 </desc>
13422 </param>
13423 <param name="objects" type="$unknown" dir="in" safearray="yes">
13424 <desc>
13425 Set of objects to query metrics for.
13426 </desc>
13427 </param>
13428 <param name="returnMetricNames" type="wstring" dir="out" safearray="yes">
13429 <desc>
13430 Names of metrics returned in @c returnData.
13431 </desc>
13432 </param>
13433 <param name="returnObjects" type="$unknown" dir="out" safearray="yes">
13434 <desc>
13435 Objects associated with metrics returned in @c returnData.
13436 </desc>
13437 </param>
13438 <param name="returnUnits" type="wstring" dir="out" safearray="yes">
13439 <desc>
13440 Units of measurement for each returned metric.
13441 </desc>
13442 </param>
13443 <param name="returnScales" type="unsigned long" dir="out" safearray="yes">
13444 <desc>
13445 Divisor that should be applied to return values in order to get
13446 floating point values. For example:
13447 <tt>(double)returnData[returnDataIndices[0]+i] / returnScales[0]</tt>
13448 will retrieve the floating point value of i-th sample of the first
13449 metric.
13450 </desc>
13451 </param>
13452 <param name="returnSequenceNumbers" type="unsigned long" dir="out" safearray="yes">
13453 <desc>
13454 Sequence numbers of the first elements of value sequences of particular metrics
13455 returned in @c returnData. For aggregate metrics it is the sequence number of
13456 the sample the aggregate started calculation from.
13457 </desc>
13458 </param>
13459 <param name="returnDataIndices" type="unsigned long" dir="out" safearray="yes">
13460 <desc>
13461 Indices of the first elements of value sequences of particular metrics
13462 returned in @c returnData.
13463 </desc>
13464 </param>
13465 <param name="returnDataLengths" type="unsigned long" dir="out" safearray="yes">
13466 <desc>
13467 Lengths of value sequences of particular metrics.
13468 </desc>
13469 </param>
13470 <param name="returnData" type="long" dir="return" safearray="yes">
13471 <desc>
13472 Flattened array of all metric data containing sequences of values for
13473 each metric.
13474 </desc>
13475 </param>
13476 </method>
13477
13478 </interface>
13479
13480 <module name="VBoxSVC" context="LocalServer">
13481 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
13482 namespace="virtualbox.org">
13483 <interface name="IVirtualBox" default="yes"/>
13484 </class>
13485 </module>
13486
13487 <module name="VBoxC" context="InprocServer" threadingModel="Free">
13488 <class name="Session" uuid="3C02F46D-C9D2-4f11-A384-53F0CF917214"
13489 namespace="virtualbox.org">
13490 <interface name="ISession" default="yes"/>
13491 </class>
13492 </module>
13493
13494</library>
13495
13496</idl>
13497
13498<!-- vim: set shiftwidth=2 tabstop=2 expandtab: -->
Note: See TracBrowser for help on using the repository browser.

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