VirtualBox

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

Last change on this file since 20842 was 20842, checked in by vboxsync, 15 years ago

API and Frontends: change IVirtualBox::openHardDisk to allow modifying the image UUID and parent UUID on open

  • Property svn:eol-style set to native
File size: 497.2 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 </ul>
2526
2527 The @a environment argument is a string containing definitions of
2528 environment variables in the following format:
2529 @code
2530 NAME[=VALUE]\n
2531 NAME[=VALUE]\n
2532 ...
2533 @endcode
2534 where <tt>\\n</tt> is the new line character. These environment
2535 variables will be appended to the environment of the VirtualBox server
2536 process. If an environment variable exists both in the server process
2537 and in this list, the value from this list takes precedence over the
2538 server's variable. If the value of the environment variable is
2539 omitted, this variable will be removed from the resulting environment.
2540 If the environment string is @c null, the server environment is
2541 inherited by the started process as is.
2542
2543 <see>openExistingSession</see>
2544
2545 <result name="E_UNEXPECTED">
2546 Virtual machine not registered.
2547 </result>
2548 <result name="E_INVALIDARG">
2549 Invalid session type @a type.
2550 </result>
2551 <result name="VBOX_E_OBJECT_NOT_FOUND">
2552 No machine matching @a machineId found.
2553 </result>
2554 <result name="VBOX_E_INVALID_OBJECT_STATE">
2555 Session already open or being opened.
2556 </result>
2557 <result name="VBOX_E_IPRT_ERROR">
2558 Launching process for machine failed.
2559 </result>
2560 <result name="VBOX_E_VM_ERROR">
2561 Failed to assign machine to session.
2562 </result>
2563
2564 </desc>
2565 <param name="session" type="ISession" dir="in">
2566 <desc>
2567 Session object that will represent the opened remote session
2568 after successful method invocation (this object must not
2569 represent an already open session).
2570 </desc>
2571 </param>
2572 <param name="machineId" type="wstring" dir="in">
2573 <desc>ID of the virtual machine to open a session with.</desc>
2574 </param>
2575 <param name="type" type="wstring" dir="in">
2576 <desc>
2577 Type of the remote session (case sensitive).
2578 </desc>
2579 </param>
2580 <param name="environment" type="wstring" dir="in">
2581 <desc>
2582 Environment to pass to the opened session (may be @c null).
2583 </desc>
2584 </param>
2585 <param name="progress" type="IProgress" dir="return">
2586 <desc>Progress object to track the operation completion.</desc>
2587 </param>
2588 </method>
2589
2590 <method name="openExistingSession">
2591 <desc>
2592 Opens a new remote session with the virtual machine for
2593 which a direct session is already open.
2594
2595 The remote session provides some level of control over the VM
2596 execution (using the IConsole interface) to the caller; however,
2597 within the remote session context, not all VM settings are available
2598 for modification.
2599
2600 As opposed to <link to="#openRemoteSession"/>, the number of
2601 remote sessions opened this way is not limited by the API
2602
2603 <note>
2604 It is an error to open a remote session with the machine that
2605 doesn't have an open direct session.
2606 </note>
2607
2608 <result name="E_UNEXPECTED">
2609 Virtual machine not registered.
2610 </result>
2611 <result name="VBOX_E_OBJECT_NOT_FOUND">
2612 No machine matching @a machineId found.
2613 </result>
2614 <result name="VBOX_E_INVALID_OBJECT_STATE">
2615 Session already open or being opened.
2616 </result>
2617 <result name="VBOX_E_INVALID_SESSION_STATE">
2618 Direct session state not Open.
2619 </result>
2620 <result name="VBOX_E_VM_ERROR">
2621 Failed to get console object from direct session or assign
2622 machine to session.
2623 </result>
2624
2625 <see>openRemoteSession</see>
2626 </desc>
2627 <param name="session" type="ISession" dir="in">
2628 <desc>
2629 Session object that will represent the open remote session
2630 after successful method invocation. This object must not
2631 represent an already open session.
2632 <note>
2633 This session will be automatically closed when the peer
2634 (direct) session dies or gets closed.
2635 </note>
2636 </desc>
2637 </param>
2638 <param name="machineId" type="wstring" dir="in">
2639 <desc>ID of the virtual machine to open a session with.</desc>
2640 </param>
2641 </method>
2642
2643 <method name="registerCallback">
2644 <desc>
2645 Registers a new global VirtualBox callback. The methods of the given
2646 callback object will be called by VirtualBox when an appropriate
2647 event occurs.
2648
2649 <result name="E_INVALIDARG">
2650 A @c NULL callback cannot be registered.
2651 </result>
2652
2653 </desc>
2654 <param name="callback" type="IVirtualBoxCallback" dir="in">
2655 <desc>Callback object to register.</desc>
2656 </param>
2657 </method>
2658
2659 <method name="unregisterCallback">
2660 <desc>
2661 Unregisters the previously registered global VirtualBox callback.
2662
2663 <result name="E_INVALIDARG">
2664 Specified @a callback not registered.
2665 </result>
2666
2667 </desc>
2668 <param name="callback" type="IVirtualBoxCallback" dir="in">
2669 <desc>Callback object to unregister.</desc>
2670 </param>
2671 </method>
2672
2673 <method name="waitForPropertyChange">
2674 <desc>
2675 Blocks the caller until any of the properties represented by the
2676 @a what argument changes the value or until the given timeout interval
2677 expires.
2678
2679 The @a what argument is a comma separated list of property masks that
2680 describe properties the caller is interested in. The property mask is
2681 a string in the following format:
2682
2683 <pre>
2684 [[group.]subgroup.]name
2685 </pre>
2686
2687 where @c name is the property name and @c group, @c subgroup are zero
2688 or more property group specifiers. Each element (group or name) in
2689 the property mask may be either a Latin string or an asterisk symbol
2690 (@c "*") which is used to match any string for the given element. A
2691 property mask that doesn't contain asterisk symbols represents a
2692 single fully qualified property name.
2693
2694 Groups in the fully qualified property name go from more generic (the
2695 left-most part) to more specific (the right-most part). The first
2696 element is usually a name of the object the property belongs to. The
2697 second element may be either a property name, or a child object name,
2698 or an index if the preceding element names an object which is one of
2699 many objects of the same type. This way, property names form a
2700 hierarchy of properties. Here are some examples of property names:
2701
2702 <table>
2703 <tr>
2704 <td><tt>VirtualBox.version</tt></td>
2705 <td><link to="IVirtualBox::version"/> property</td>
2706 </tr>
2707 <tr>
2708 <td><tt>Machine.&lt;UUID&gt;.name</tt></td>
2709 <td><link to="IMachine::name"/> property of the machine with the
2710 given UUID</td>
2711 </tr>
2712 </table>
2713
2714 Most property names directly correspond to the properties of objects
2715 (components) provided by the VirtualBox library and may be used to
2716 track changes to these properties. However, there may be
2717 pseudo-property names that don't correspond to any existing object's
2718 property directly, as well as there may be object properties that
2719 don't have a corresponding property name that is understood by this
2720 method, and therefore changes to such properties cannot be
2721 tracked. See individual object's property descriptions to get a
2722 fully qualified property name that can be used with this method (if
2723 any).
2724
2725 There is a special property mask @c "*" (i.e. a string consisting of a
2726 single asterisk symbol) that can be used to match all properties.
2727 Below are more examples of property masks:
2728
2729 <table>
2730 <tr>
2731 <td><tt>VirtualBox.*</tt></td>
2732 <td>Track all properties of the VirtualBox object</td>
2733 </tr>
2734 <tr>
2735 <td><tt>Machine.*.name</tt></td>
2736 <td>Track changes to the <link to="IMachine::name"/> property of
2737 all registered virtual machines</td>
2738 </tr>
2739 </table>
2740
2741 <note>
2742 This function is not implemented in the current version of the
2743 product.
2744 </note>
2745 </desc>
2746 <param name="what" type="wstring" dir="in">
2747 <desc>Comma separated list of property masks.</desc>
2748 </param>
2749 <param name="timeout" type="unsigned long" dir="in">
2750 <desc>
2751 Wait timeout in milliseconds.
2752 Specify -1 for an indefinite wait.
2753 </desc>
2754 </param>
2755 <param name="changed" type="wstring" dir="out">
2756 <desc>
2757 Comma separated list of properties that have been changed and caused
2758 this method to return to the caller.
2759 </desc>
2760 </param>
2761 <param name="values" type="wstring" dir="out">
2762 <desc>Reserved, not currently used.</desc>
2763 </param>
2764 </method>
2765
2766 <method name="saveSettings">
2767 <desc>
2768 Saves the global settings to the global settings file
2769 (<link to="#settingsFilePath"/>).
2770
2771 This method is only useful for explicitly saving the global settings
2772 file after it has been auto-converted from the old format to the most
2773 recent format (see <link to="#settingsFileVersion"/> for details).
2774 Normally, the global settings file is implicitly saved when a global
2775 setting is changed.
2776
2777 <result name="VBOX_E_FILE_ERROR">
2778 Settings file not accessible.
2779 </result>
2780 <result name="VBOX_E_XML_ERROR">
2781 Could not parse the settings file.
2782 </result>
2783
2784 </desc>
2785 </method>
2786
2787 <method name="saveSettingsWithBackup">
2788 <desc>
2789 Creates a backup copy of the global settings file
2790 (<link to="IVirtualBox::settingsFilePath"/>) in case of auto-conversion,
2791 and then calls <link to="IVirtualBox::saveSettings"/>.
2792
2793 Note that the backup copy is created <b>only</b> if the settings file
2794 auto-conversion took place (see <link to="#settingsFileVersion"/> for
2795 details). Otherwise, this call is fully equivalent to
2796 <link to="IVirtualBox::saveSettings"/> and no backup copying is done.
2797
2798 The backup copy is created in the same directory where the original
2799 settings file is located. It is given the following file name:
2800 <pre>
2801 original.xml.x.y-platform.bak
2802 </pre>
2803 where <tt>original.xml</tt> is the original settings file name
2804 (excluding path), and <tt>x.y-platform</tt> is the version of the old
2805 format of the settings file (before auto-conversion).
2806
2807 If the given backup file already exists, this method will try to add the
2808 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
2809 0 to 9) and copy it again until it succeeds. If all suffixes are
2810 occupied, or if any other copy error occurs, this method will return a
2811 failure.
2812
2813 If the copy operation succeeds, the @a bakFileName return argument will
2814 receive a full path to the created backup file (for informational
2815 purposes). Note that this will happen even if the subsequent
2816 <link to="#saveSettings"/> call performed by this method after the
2817 copy operation, fails.
2818
2819 <note>
2820 The VirtualBox API never calls this method. It is intended purely for
2821 the purposes of creating backup copies of the settings files by
2822 front-ends before saving the results of the automatically performed
2823 settings conversion to disk.
2824 </note>
2825
2826 <see>settingsFileVersion</see>
2827
2828 <result name="VBOX_E_FILE_ERROR">
2829 Settings file not accessible.
2830 </result>
2831 <result name="VBOX_E_XML_ERROR">
2832 Could not parse the settings file.
2833 </result>
2834 <result name="VBOX_E_IPRT_ERROR">
2835 Could not copy the settings file.
2836 </result>
2837
2838 </desc>
2839 <param name="bakFileName" type="wstring" dir="return">
2840 <desc>Full path to the created backup copy.</desc>
2841 </param>
2842 </method>
2843
2844 <!--method name="createDHCPServerForInterface">
2845 <desc>
2846 Creates a dhcp server settings to be used for the given interface
2847 <result name="E_INVALIDARG">
2848 Host network interface @a name already exists.
2849 </result>
2850 </desc>
2851 <param name="interface" type="IHostNetworkInterface" dir="in">
2852 <desc>Network Interface</desc>
2853 </param>
2854 <param name="server" type="IDHCPServer" dir="out">
2855 <desc>Dhcp server settings</desc>
2856 </param>
2857 </method-->
2858
2859 <method name="createDHCPServer">
2860 <desc>
2861 Creates a dhcp server settings to be used for the given internal network name
2862 <result name="E_INVALIDARG">
2863 Host network interface @a name already exists.
2864 </result>
2865 </desc>
2866 <param name="name" type="wstring" dir="in">
2867 <desc>server name</desc>
2868 </param>
2869 <param name="server" type="IDHCPServer" dir="return">
2870 <desc>Dhcp server settings</desc>
2871 </param>
2872 </method>
2873
2874 <method name="findDHCPServerByNetworkName">
2875 <desc>
2876 Searches a dhcp server settings to be used for the given internal network name
2877 <result name="E_INVALIDARG">
2878 Host network interface @a name already exists.
2879 </result>
2880
2881 </desc>
2882 <param name="name" type="wstring" dir="in">
2883 <desc>server name</desc>
2884 </param>
2885 <param name="server" type="IDHCPServer" dir="return">
2886 <desc>Dhcp server settings</desc>
2887 </param>
2888 </method>
2889
2890 <!--method name="findDHCPServerForInterface">
2891 <desc>
2892 Searches a dhcp server settings to be used for the given interface
2893 <result name="E_INVALIDARG">
2894 Host network interface @a name already exists.
2895 </result>
2896 </desc>
2897 <param name="interface" type="IHostNetworkInterface" dir="in">
2898 <desc>Network Interface</desc>
2899 </param>
2900 <param name="server" type="IDHCPServer" dir="out">
2901 <desc>Dhcp server settings</desc>
2902 </param>
2903 </method-->
2904
2905 <method name="removeDHCPServer">
2906 <desc>
2907 Removes the dhcp server settings
2908 <result name="E_INVALIDARG">
2909 Host network interface @a name already exists.
2910 </result>
2911 </desc>
2912 <param name="server" type="IDHCPServer" dir="in">
2913 <desc>Dhcp server settings to be removed</desc>
2914 </param>
2915 </method>
2916
2917 </interface>
2918
2919 <!--
2920 // IVFSExplorer
2921 /////////////////////////////////////////////////////////////////////////
2922 -->
2923
2924 <enum
2925 name="VFSType"
2926 uuid="813999ba-b949-48a8-9230-aadc6285e2f2"
2927 >
2928 <desc>
2929 Supported virtual file systems of VFSExplorer.
2930 </desc>
2931
2932 <const name="File" value="1" />
2933 <const name="Cloud" value="2" />
2934 <const name="S3" value="3" />
2935 <const name="WebDav" value="4" />
2936 </enum>
2937
2938 <enum
2939 name="VFSFileType"
2940 uuid="714333cd-44e2-415f-a245-d378fa9b1242"
2941 >
2942 <desc>
2943 File types known by VFSExplorer.
2944 </desc>
2945
2946 <const name="Unknown" value="1" />
2947 <const name="Fifo" value="2" />
2948 <const name="DevChar" value="3" />
2949 <const name="Directory" value="4" />
2950 <const name="DevBlock" value="5" />
2951 <const name="File" value="6" />
2952 <const name="SymLink" value="7" />
2953 <const name="Socket" value="8" />
2954 <const name="WhiteOut" value="9" />
2955 </enum>
2956
2957 <interface
2958 name="IVFSExplorer" extends="$unknown"
2959 uuid="fd7da337-80ef-4a5c-9122-918435e33003"
2960 wsmap="managed"
2961 >
2962 <desc>
2963 The VFSExplorer interface unify the access to different file system
2964 types. This includes local file systems as well remote file systems like
2965 the S3 one. For a list of supported types see <link to="VFSType" />.
2966 </desc>
2967
2968 <attribute name="path" type="wstring" readonly="yes">
2969 <desc>Return the current path in the virtual file system.</desc>
2970 </attribute>
2971
2972 <attribute name="type" type="VFSType" readonly="yes">
2973 <desc>Return the file system type which is currently in use.</desc>
2974 </attribute>
2975
2976 <method name="update">
2977 <desc>This method updates the internal list of files/directories from the
2978 current directory level. Use <link to="entryList" /> to get the full list
2979 after a call to this method.</desc>
2980
2981 <param name="aProgress" type="IProgress" dir="return">
2982 <desc>Progress object to track the operation completion.</desc>
2983 </param>
2984 </method>
2985
2986 <method name="entryList">
2987 <desc>Fetch the list of files/directories after a call to <link
2988 to="update" />. The user is responcible for keeping this internal list up
2989 do date.</desc>
2990
2991 <param name="aNames" type="wstring" safearray="yes" dir="out">
2992 <desc>The list of names for the entries.</desc>
2993 </param>
2994
2995 <param name="aTypes" type="unsigned long" safearray="yes" dir="out">
2996 <desc>The list of types for the entries.</desc>
2997 </param>
2998 </method>
2999
3000 <method name="exists">
3001 <desc>Check if the given file list exists in the current directory
3002 level.</desc>
3003
3004 <param name="aNames" type="wstring" safearray="yes" dir="in">
3005 <desc>The names to check.</desc>
3006 </param>
3007
3008 <param name="aExists" type="wstring" safearray="yes" dir="return">
3009 <desc>The names which exists.</desc>
3010 </param>
3011 </method>
3012
3013 <method name="remove">
3014 <desc>Remove the given file names from the current directory
3015 level.</desc>
3016
3017 <param name="aNames" type="wstring" safearray="yes" dir="in">
3018 <desc>The names to remove.</desc>
3019 </param>
3020
3021 <param name="aProgress" type="IProgress" dir="return">
3022 <desc>Progress object to track the operation completion.</desc>
3023 </param>
3024 </method>
3025
3026 </interface>
3027
3028 <!--
3029 // IAppliance
3030 /////////////////////////////////////////////////////////////////////////
3031 -->
3032
3033 <enum
3034 name="CIMOSType"
3035 uuid="86ef5f8c-18b2-4db8-a314-33721b59f89b"
3036 >
3037 <desc>
3038 OVF operating system values according to CIM V2.20 (as of Nov 2008); http://www.dmtf.org/standards/cim/cim_schema_v220
3039 </desc>
3040
3041 <const name="CIMOS_Unknown" value="0" /> <!-- "Unknown" -->
3042 <const name="CIMOS_Other" value="1" /> <!-- "Other" -->
3043 <const name="CIMOS_MACOS" value="2" /> <!-- "MACOS" -->
3044 <const name="CIMOS_ATTUNIX" value="3" /> <!-- "ATTUNIX" -->
3045 <const name="CIMOS_DGUX" value="4" /> <!-- "DGUX" -->
3046 <const name="CIMOS_DECNT" value="5" /> <!-- "DECNT" -->
3047 <const name="CIMOS_Tru64UNIX" value="6" /> <!-- "Tru64 UNIX" -->
3048 <const name="CIMOS_OpenVMS" value="7" /> <!-- "OpenVMS" -->
3049 <const name="CIMOS_HPUX" value="8" /> <!-- "HPUX" -->
3050 <const name="CIMOS_AIX" value="9" /> <!-- "AIX" -->
3051 <const name="CIMOS_MVS" value="10" /> <!-- "MVS" -->
3052 <const name="CIMOS_OS400" value="11" /> <!-- "OS400" -->
3053 <const name="CIMOS_OS2" value="12" /> <!-- "OS/2" -->
3054 <const name="CIMOS_JavaVM" value="13" /> <!-- "JavaVM" -->
3055 <const name="CIMOS_MSDOS" value="14" /> <!-- "MSDOS" -->
3056 <const name="CIMOS_WIN3x" value="15" /> <!-- "WIN3x" -->
3057 <const name="CIMOS_WIN95" value="16" /> <!-- "WIN95" -->
3058 <const name="CIMOS_WIN98" value="17" /> <!-- "WIN98" -->
3059 <const name="CIMOS_WINNT" value="18" /> <!-- "WINNT" -->
3060 <const name="CIMOS_WINCE" value="19" /> <!-- "WINCE" -->
3061 <const name="CIMOS_NCR3000" value="20" /> <!-- "NCR3000" -->
3062 <const name="CIMOS_NetWare" value="21" /> <!-- "NetWare" -->
3063 <const name="CIMOS_OSF" value="22" /> <!-- "OSF" -->
3064 <const name="CIMOS_DCOS" value="23" /> <!-- "DC/OS" -->
3065 <const name="CIMOS_ReliantUNIX" value="24" /> <!-- "Reliant UNIX" -->
3066 <const name="CIMOS_SCOUnixWare" value="25" /> <!-- "SCO UnixWare" -->
3067 <const name="CIMOS_SCOOpenServer" value="26" /> <!-- "SCO OpenServer" -->
3068 <const name="CIMOS_Sequent" value="27" /> <!-- "Sequent" -->
3069 <const name="CIMOS_IRIX" value="28" /> <!-- "IRIX" -->
3070 <const name="CIMOS_Solaris" value="29" /> <!-- "Solaris" -->
3071 <const name="CIMOS_SunOS" value="30" /> <!-- "SunOS" -->
3072 <const name="CIMOS_U6000" value="31" /> <!-- "U6000" -->
3073 <const name="CIMOS_ASERIES" value="32" /> <!-- "ASERIES" -->
3074 <const name="CIMOS_HPNonStopOS" value="33" /> <!-- "HP NonStop OS" -->
3075 <const name="CIMOS_HPNonStopOSS" value="34" /> <!-- "HP NonStop OSS" -->
3076 <const name="CIMOS_BS2000" value="35" /> <!-- "BS2000" -->
3077 <const name="CIMOS_LINUX" value="36" /> <!-- "LINUX" -->
3078 <const name="CIMOS_Lynx" value="37" /> <!-- "Lynx" -->
3079 <const name="CIMOS_XENIX" value="38" /> <!-- "XENIX" -->
3080 <const name="CIMOS_VM" value="39" /> <!-- "VM" -->
3081 <const name="CIMOS_InteractiveUNIX" value="40" /> <!-- "Interactive UNIX" -->
3082 <const name="CIMOS_BSDUNIX" value="41" /> <!-- "BSDUNIX" -->
3083 <const name="CIMOS_FreeBSD" value="42" /> <!-- "FreeBSD" -->
3084 <const name="CIMOS_NetBSD" value="43" /> <!-- "NetBSD" -->
3085 <const name="CIMOS_GNUHurd" value="44" /> <!-- "GNU Hurd" -->
3086 <const name="CIMOS_OS9" value="45" /> <!-- "OS9" -->
3087 <const name="CIMOS_MACHKernel" value="46" /> <!-- "MACH Kernel" -->
3088 <const name="CIMOS_Inferno" value="47" /> <!-- "Inferno" -->
3089 <const name="CIMOS_QNX" value="48" /> <!-- "QNX" -->
3090 <const name="CIMOS_EPOC" value="49" /> <!-- "EPOC" -->
3091 <const name="CIMOS_IxWorks" value="50" /> <!-- "IxWorks" -->
3092 <const name="CIMOS_VxWorks" value="51" /> <!-- "VxWorks" -->
3093 <const name="CIMOS_MiNT" value="52" /> <!-- "MiNT" -->
3094 <const name="CIMOS_BeOS" value="53" /> <!-- "BeOS" -->
3095 <const name="CIMOS_HPMPE" value="54" /> <!-- "HP MPE" -->
3096 <const name="CIMOS_NextStep" value="55" /> <!-- "NextStep" -->
3097 <const name="CIMOS_PalmPilot" value="56" /> <!-- "PalmPilot" -->
3098 <const name="CIMOS_Rhapsody" value="57" /> <!-- "Rhapsody" -->
3099 <const name="CIMOS_Windows2000" value="58" /> <!-- "Windows 2000" -->
3100 <const name="CIMOS_Dedicated" value="59" /> <!-- "Dedicated" -->
3101 <const name="CIMOS_OS390" value="60" /> <!-- "OS/390" -->
3102 <const name="CIMOS_VSE" value="61" /> <!-- "VSE" -->
3103 <const name="CIMOS_TPF" value="62" /> <!-- "TPF" -->
3104 <const name="CIMOS_WindowsMe" value="63" /> <!-- "Windows (R) Me" -->
3105 <const name="CIMOS_CalderaOpenUNIX" value="64" /> <!-- "Caldera Open UNIX" -->
3106 <const name="CIMOS_OpenBSD" value="65" /> <!-- "OpenBSD" -->
3107 <const name="CIMOS_NotApplicable" value="66" /> <!-- "Not Applicable" -->
3108 <const name="CIMOS_WindowsXP" value="67" /> <!-- "Windows XP" -->
3109 <const name="CIMOS_zOS" value="68" /> <!-- "z/OS" -->
3110 <const name="CIMOS_MicrosoftWindowsServer2003" value="69" /> <!-- "Microsoft Windows Server 2003" -->
3111 <const name="CIMOS_MicrosoftWindowsServer2003_64" value="70" /> <!-- "Microsoft Windows Server 2003 64-Bit" -->
3112 <const name="CIMOS_WindowsXP_64" value="71" /> <!-- "Windows XP 64-Bit" -->
3113 <const name="CIMOS_WindowsXPEmbedded" value="72" /> <!-- "Windows XP Embedded" -->
3114 <const name="CIMOS_WindowsVista" value="73" /> <!-- "Windows Vista" -->
3115 <const name="CIMOS_WindowsVista_64" value="74" /> <!-- "Windows Vista 64-Bit" -->
3116 <const name="CIMOS_WindowsEmbeddedforPointofService" value="75" /> <!-- "Windows Embedded for Point of Service" -->
3117 <const name="CIMOS_MicrosoftWindowsServer2008" value="76" /> <!-- "Microsoft Windows Server 2008" -->
3118 <const name="CIMOS_MicrosoftWindowsServer2008_64" value="77" /> <!-- "Microsoft Windows Server 2008 64-Bit" -->
3119 <const name="CIMOS_FreeBSD_64" value="78" /> <!-- "FreeBSD 64-Bit" -->
3120 <const name="CIMOS_RedHatEnterpriseLinux" value="79" /> <!-- "RedHat Enterprise Linux" -->
3121 <const name="CIMOS_RedHatEnterpriseLinux_64" value="80" /> <!-- "RedHat Enterprise Linux 64-Bit" -->
3122 <const name="CIMOS_Solaris_64" value="81" /> <!-- "Solaris 64-Bit" -->
3123 <const name="CIMOS_SUSE" value="82" /> <!-- "SUSE" -->
3124 <const name="CIMOS_SUSE_64" value="83" /> <!-- "SUSE 64-Bit" -->
3125 <const name="CIMOS_SLES" value="84" /> <!-- "SLES" -->
3126 <const name="CIMOS_SLES_64" value="85" /> <!-- "SLES 64-Bit" -->
3127 <const name="CIMOS_NovellOES" value="86" /> <!-- "Novell OES" -->
3128 <const name="CIMOS_NovellLinuxDesktop" value="87" /> <!-- "Novell Linux Desktop" -->
3129 <const name="CIMOS_SunJavaDesktopSystem" value="88" /> <!-- "Sun Java Desktop System" -->
3130 <const name="CIMOS_Mandriva" value="89" /> <!-- "Mandriva" -->
3131 <const name="CIMOS_Mandriva_64" value="90" /> <!-- "Mandriva 64-Bit" -->
3132 <const name="CIMOS_TurboLinux" value="91" /> <!-- "TurboLinux" -->
3133 <const name="CIMOS_TurboLinux_64" value="92" /> <!-- "TurboLinux 64-Bit" -->
3134 <const name="CIMOS_Ubuntu" value="93" /> <!-- "Ubuntu" -->
3135 <const name="CIMOS_Ubuntu_64" value="94" /> <!-- "Ubuntu 64-Bit" -->
3136 <const name="CIMOS_Debian" value="95" /> <!-- "Debian" -->
3137 <const name="CIMOS_Debian_64" value="96" /> <!-- "Debian 64-Bit" -->
3138 <const name="CIMOS_Linux_2_4_x" value="97" /> <!-- "Linux 2.4.x" -->
3139 <const name="CIMOS_Linux_2_4_x_64" value="98" /> <!-- "Linux 2.4.x 64-Bit" -->
3140 <const name="CIMOS_Linux_2_6_x" value="99" /> <!-- "Linux 2.6.x" -->
3141 <const name="CIMOS_Linux_2_6_x_64" value="100" /> <!-- "Linux 2.6.x 64-Bit" -->
3142 <const name="CIMOS_Linux_64" value="101" /> <!-- "Linux 64-Bit" -->
3143 <const name="CIMOS_Other_64" value="102" /> <!-- "Other 64-Bit" -->
3144 </enum>
3145
3146 <enum
3147 name="OVFResourceType"
3148 uuid="646a78d7-6f04-49f4-82c4-75c28a75a4cd"
3149 >
3150 <desc>
3151 OVF resource type (as listed with CIM_ResourceAllocationSettingData; see for example
3152 http://msdn.microsoft.com/en-us/library/cc136877(VS.85).aspx).
3153 </desc>
3154
3155 <const name="Other" value="1" />
3156 <const name="ComputerSystem" value="2" />
3157 <const name="Processor" value="3" />
3158 <const name="Memory" value="4" />
3159 <const name="IDEController" value="5" />
3160 <const name="ParallelSCSIHBA" value="6" />
3161 <const name="FCHBA" value="7" />
3162 <const name="iSCSIHBA" value="8" />
3163 <const name="IBHCA" value="9" />
3164 <const name="EthernetAdapter" value="10" />
3165 <const name="OtherNetworkAdapter" value="11" />
3166 <const name="IOSlot" value="12" />
3167 <const name="IODevice" value="13" />
3168 <const name="FloppyDrive" value="14" />
3169 <const name="CDDrive" value="15" />
3170 <const name="DVDDrive" value="16" />
3171 <const name="HardDisk" value="17" />
3172 <const name="OtherStorageDevice" value="20" />
3173 <const name="USBController" value="23" />
3174 <const name="SoundCard" value="35" />
3175 </enum>
3176
3177 <interface
3178 name="IAppliance" extends="$unknown"
3179 uuid="07495095-d16c-4911-8964-5914341ced5d"
3180 wsmap="managed"
3181 >
3182 <desc>
3183 Represents a platform-independent appliance in OVF format. An instance of this is returned
3184 by <link to="IVirtualBox::createAppliance" />, which can then be used to import and export
3185 appliances with VirtualBox.
3186
3187 The OVF standard suggests two different physical file formats:
3188
3189 <ol>
3190 <li>If the OVF is distributed as a set of files, then @a file must be a fully qualified
3191 path name to an existing OVF descriptor file with an <tt>.ovf</tt> file extension. If
3192 this descriptor file references other files, as OVF appliances distributed as a set of
3193 files most likely do, those files must be in the same directory as the descriptor file.</li>
3194
3195 <li>If the OVF is distributed as a single file, it must be in TAR format and have the
3196 <tt>.ova</tt> file extension. This TAR file must then contain at least the OVF descriptor
3197 files and optionally other files.
3198
3199 At this time, VirtualBox does not not yet support the packed (TAR) variant; support will
3200 be added with a later version.</li>
3201 </ol>
3202
3203 <b>Importing</b> an OVF appliance into VirtualBox as instances of
3204 <link to="IMachine" /> involves the following sequence of API calls:
3205
3206 <ol>
3207 <li>Call <link to="IVirtualBox::createAppliance" />. This will create an empty IAppliance object.
3208 </li>
3209
3210 <li>On the new object, call <link to="#read" /> with the full path of the OVF file you
3211 would like to import. So long as this file is syntactically valid, this will succeed
3212 and return an instance of IAppliance that contains the parsed data from the OVF file.
3213 </li>
3214
3215 <li>Next, call <link to="#interpret" />, which analyzes the OVF data and sets up the
3216 contents of the IAppliance attributes accordingly. These can be inspected by a
3217 VirtualBox front-end such as the GUI, and the suggestions can be displayed to the
3218 user. In particular, the <link to="#virtualSystemDescriptions" /> array contains
3219 instances of <link to="IVirtualSystemDescription" /> which represent the virtual
3220 systems in the OVF, which in turn describe the virtual hardware prescribed by the
3221 OVF (network and hardware adapters, virtual disk images, memory size and so on).
3222 The GUI can then give the user the option to confirm and/or change these suggestions.
3223 </li>
3224
3225 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
3226 virtual system to override the suggestions made by the interpret() routine.
3227 </li>
3228
3229 <li>Finally, call <link to="#importMachines" /> to create virtual machines in
3230 VirtualBox as instances of <link to="IMachine" /> that match the information in the
3231 virtual system descriptions.
3232 </li>
3233 </ol>
3234
3235 <b>Exporting</b> VirtualBox machines into an OVF appliance involves the following steps:
3236
3237 <ol>
3238 <li>As with importing, first call <link to="IVirtualBox::createAppliance" /> to create
3239 an empty IAppliance object.
3240 </li>
3241
3242 <li>For each machine you would like to export, call <link to="IMachine::export" />
3243 with the IAppliance object you just created. This creates an instance of
3244 <link to="IVirtualSystemDescription" /> inside the appliance.
3245 </li>
3246
3247 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
3248 virtual system to override the suggestions made by the export() routine.
3249 </li>
3250
3251 <li>Finally, call <link to="#write" /> with a path specification to have the OVF
3252 file written.</li>
3253 </ol>
3254
3255 </desc>
3256
3257 <attribute name="path" type="wstring" readonly="yes">
3258 <desc>Path to the main file of the OVF appliance, which is either the <tt>.ovf</tt> or
3259 the <tt>.ova</tt> file passed to <link to="#read" /> (for import) or
3260 <link to="#write" /> (for export).
3261 This attribute is empty until one of these methods has been called.
3262 </desc>
3263 </attribute>
3264
3265 <attribute name="disks" type="wstring" readonly="yes" safearray="yes">
3266 <desc>
3267 Array of virtual disk definitions. One such description exists for each
3268 disk definition in the OVF; each string array item represents one such piece of
3269 disk information, with the information fields separated by tab (\\t) characters.
3270
3271 The caller should be prepared for additional fields being appended to
3272 this string in future versions of VirtualBox and therefore check for
3273 the number of tabs in the strings returned.
3274
3275 In the current version, the following eight fields are returned per string
3276 in the array:
3277
3278 <ol>
3279 <li>Disk ID (unique string identifier given to disk)</li>
3280
3281 <li>Capacity (unsigned integer indicating the maximum capacity of the disk)</li>
3282
3283 <li>Populated size (optional unsigned integer indicating the current size of the
3284 disk; can be approximate; -1 if unspecified)</li>
3285
3286 <li>Format (string identifying the disk format, typically
3287 "http://www.vmware.com/specifications/vmdk.html#sparse")</li>
3288
3289 <li>Reference (where to find the disk image, typically a file name; if empty,
3290 then the disk should be created on import)</li>
3291
3292 <li>Image size (optional unsigned integer indicating the size of the image,
3293 which need not necessarily be the same as the values specified above, since
3294 the image may be compressed or sparse; -1 if not specified)</li>
3295
3296 <li>Chunk size (optional unsigned integer if the image is split into chunks;
3297 presently unsupported and always -1)</li>
3298
3299 <li>Compression (optional string equalling "gzip" if the image is gzip-compressed)</li>
3300 </ol>
3301 </desc>
3302 </attribute>
3303
3304 <attribute name="virtualSystemDescriptions" type="IVirtualSystemDescription" readonly="yes" safearray="yes">
3305 <desc> Array of virtual system descriptions. One such description is created
3306 for each virtual system found in the OVF.
3307 This array is empty until either <link to="#interpret" /> (for import) or <link to="IMachine::export" />
3308 (for export) has been called.
3309 </desc>
3310 </attribute>
3311
3312 <method name="read">
3313 <desc>
3314 Reads an OVF file into the appliance object.
3315
3316 This method succeeds if the OVF is syntactically valid and, by itself, without errors. The
3317 mere fact that this method returns successfully does not mean that VirtualBox supports all
3318 features requested by the appliance; this can only be examined after a call to <link to="#interpret" />.
3319 </desc>
3320 <param name="file" type="wstring" dir="in">
3321 <desc>
3322 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
3323 on whether the appliance is distributed as a set of files or as a single file, respectively).
3324 </desc>
3325 </param>
3326 </method>
3327
3328 <method name="interpret">
3329 <desc>
3330 Interprets the OVF data that was read when the appliance was constructed. After
3331 calling this method, one can inspect the
3332 <link to="#virtualSystemDescriptions" /> array attribute, which will then contain
3333 one <link to="IVirtualSystemDescription" /> for each virtual machine found in
3334 the appliance.
3335
3336 Calling this method is the second step of importing an appliance into VirtualBox;
3337 see <link to="IAppliance" /> for an overview.
3338
3339 After calling this method, one should call <link to="#getWarnings" /> to find out
3340 if problems were encountered during the processing which might later lead to
3341 errors.
3342 </desc>
3343 </method>
3344
3345 <method name="importMachines">
3346 <desc>
3347 Imports the appliance into VirtualBox by creating instances of <link to="IMachine" />
3348 and other interfaces that match the information contained in the appliance as
3349 closely as possible, as represented by the import instructions in the
3350 <link to="#virtualSystemDescriptions" /> array.
3351
3352 Calling this method is the final step of importing an appliance into VirtualBox;
3353 see <link to="IAppliance" /> for an overview.
3354
3355 Since importing the appliance will most probably involve copying and converting
3356 disk images, which can take a long time, this method operates asynchronously and
3357 returns an IProgress object to allow the caller to monitor the progress.
3358 </desc>
3359
3360 <param name="aProgress" type="IProgress" dir="return">
3361 <desc></desc>
3362 </param>
3363 </method>
3364
3365 <method name="createVFSExplorer">
3366 <desc>Returns a <link to="IVFSExplorer" /> object for the given URI.</desc>
3367
3368 <param name="aUri" type="wstring" dir="in">
3369 <desc>The URI describing the file system to use.</desc>
3370 </param>
3371
3372 <param name="aExplorer" type="IVFSExplorer" dir="return">
3373 <desc></desc>
3374 </param>
3375 </method>
3376
3377 <method name="write">
3378 <desc>
3379 Writes the contents of the appliance exports into a new OVF file.
3380
3381 Calling this method is the final step of exporting an appliance from VirtualBox;
3382 see <link to="IAppliance" /> for an overview.
3383
3384 Since exporting the appliance will most probably involve copying and converting
3385 disk images, which can take a long time, this method operates asynchronously and
3386 returns an IProgress object to allow the caller to monitor the progress.
3387 </desc>
3388 <param name="format" type="wstring" dir="in">
3389 <desc>
3390 Output format, as a string. Currently supported formats are "ovf-0.9" and "ovf-1.0";
3391 future versions of VirtualBox may support additional formats.
3392 </desc>
3393 </param>
3394 <param name="path" type="wstring" dir="in">
3395 <desc>
3396 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
3397 on whether the appliance is distributed as a set of files or as a single file, respectively).
3398 </desc>
3399 </param>
3400 <param name="aProgress" type="IProgress" dir="return">
3401 <desc>Progress object to track the operation completion.</desc>
3402 </param>
3403 </method>
3404
3405 <method name="getWarnings">
3406 <desc>Returns textual warnings which occured during execution of <link to="#interpret" />.</desc>
3407
3408 <param name="aWarnings" type="wstring" dir="return" safearray="yes">
3409 <desc></desc>
3410 </param>
3411 </method>
3412
3413 </interface>
3414
3415 <enum
3416 name="VirtualSystemDescriptionType"
3417 uuid="aacc58de-5b45-4f82-ae2e-dd9a824fc3b5"
3418 >
3419 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of
3420 a configuration value.</desc>
3421
3422 <const name="Ignore" value="1" />
3423 <const name="OS" value="2" />
3424 <const name="Name" value="3" />
3425 <const name="Product" value="4" />
3426 <const name="Vendor" value="5" />
3427 <const name="Version" value="6" />
3428 <const name="ProductUrl" value="7" />
3429 <const name="VendorUrl" value="8" />
3430 <const name="Description" value="9" />
3431 <const name="License" value="10" />
3432 <const name="Miscellaneous" value="11" />
3433 <const name="CPU" value="12" />
3434 <const name="Memory" value="13" />
3435 <const name="HardDiskControllerIDE" value="14" />
3436 <const name="HardDiskControllerSATA" value="15" />
3437 <const name="HardDiskControllerSCSI" value="16" />
3438 <const name="HardDiskImage" value="17" />
3439 <const name="Floppy" value="18" />
3440 <const name="CDROM" value="19" />
3441 <const name="NetworkAdapter" value="20" />
3442 <const name="USBController" value="21" />
3443 <const name="SoundCard" value="22" />
3444
3445 </enum>
3446
3447 <enum
3448 name="VirtualSystemDescriptionValueType"
3449 uuid="56d9403f-3425-4118-9919-36f2a9b8c77c"
3450 >
3451 <desc>Used with <link to="IVirtualSystemDescription::getValuesByType" /> to describe the value
3452 type to fetch.</desc>
3453
3454 <const name="Reference" value="1" />
3455 <const name="Original" value="2" />
3456 <const name="Auto" value="3" />
3457 <const name="ExtraConfig" value="4" />
3458
3459 </enum>
3460
3461 <interface
3462 name="IVirtualSystemDescription" extends="$unknown"
3463 uuid="d7525e6c-531a-4c51-8e04-41235083a3d8"
3464 wsmap="managed"
3465 >
3466
3467 <desc>This interface is used in the <link to="IAppliance::virtualSystemDescriptions" /> array.
3468 After <link to="IAppliance::interpret" /> has been called, that array contains
3469 information about how the virtual systems described in the OVF should best be imported into VirtualBox
3470 virtual machines. See <link to="IAppliance" /> for the steps required to import an OVF
3471 into VirtualBox.
3472 </desc>
3473
3474 <attribute name="count" type="unsigned long" readonly="yes">
3475 <desc>Return the number of virtual system description entries.</desc>
3476 </attribute>
3477
3478 <method name="getDescription">
3479 <desc>Returns information about the virtual system as arrays of instruction items. In each array, the
3480 items with the same indices correspond and jointly represent an import instruction for VirtualBox.
3481
3482 The list below identifies the value sets that are possible depending on the
3483 <link to="VirtualSystemDescriptionType" /> enum value in the array item in aTypes[]. In each case,
3484 the array item with the same index in aOvfValues[] will contain the original value as contained
3485 in the OVF file (just for informational purposes), and the corresponding item in aVBoxValues[]
3486 will contain a suggested value to be used for VirtualBox. Depending on the description type,
3487 the aExtraConfigValues[] array item may also be used.
3488
3489 <ul>
3490 <li>
3491 "OS": the guest operating system type. There must be exactly one such array item on import. The
3492 corresponding item in aVBoxValues[] contains the suggested guest operating system for VirtualBox.
3493 This will be one of the values listed in <link to="IVirtualBox::guestOSTypes" />. The corresponding
3494 item in aOvfValues[] will contain a numerical value that described the operating system in the OVF
3495 (see <link to="CIMOSType" />).
3496 </li>
3497 <li>
3498 "Name": the name to give to the new virtual machine. There can be at most one such array item;
3499 if none is present on import, then an automatic name will be created from the operating system
3500 type. The correponding item im aOvfValues[] will contain the suggested virtual machine name
3501 from the OVF file, and aVBoxValues[] will contain a suggestion for a unique VirtualBox
3502 <link to="IMachine" /> name that does not exist yet.
3503 </li>
3504 <li>
3505 "Description": an arbitrary description.
3506 </li>
3507 <li>
3508 "License": the EULA section from the OVF, if present. It is the responsibility of the calling
3509 code to display such a license for agreement; the Main API does not enforce any such policy.
3510 </li>
3511 <li>
3512 Miscellaneous: reserved for future use.
3513 </li>
3514 <li>
3515 "CPU": the number of CPUs. There can be at most one such item, which will presently be ignored.
3516 </li>
3517 <li>
3518 "Memory": the amount of guest RAM, in bytes. There can be at most one such array item; if none
3519 is present on import, then VirtualBox will set a meaningful default based on the operating system
3520 type.
3521 </li>
3522 <li>
3523 "HarddiskControllerIDE": an IDE hard disk controller. There can be at most one such item. This
3524 has no value in aOvfValues[] or aVBoxValues[].
3525 The matching item in the aRefs[] array will contain an integer that items of the "Harddisk"
3526 type can use to specify which hard disk controller a virtual disk should be connected to.
3527 </li>
3528 <li>
3529 "HarddiskControllerSATA": an SATA hard disk controller. There can be at most one such item. This
3530 has no value in aOvfValues[] or aVBoxValues[].
3531 The matching item in the aRefs[] array will be used as with IDE controllers (see above).
3532 </li>
3533 <li>
3534 "HarddiskControllerSCSI": a SCSI hard disk controller. There can be at most one such item.
3535 The items in aOvfValues[] and aVBoxValues[] will either be "LsiLogic" or "BusLogic".
3536 The matching item in the aRefs[] array will be used as with IDE controllers (see above).
3537 </li>
3538 <li>
3539 "HardDiskImage": a virtual hard disk, most probably as a reference to an image file. There can be an
3540 arbitrary number of these items, one for each virtual disk image that accompanies the OVF.
3541
3542 The array item in aOvfValues[] will contain the file specification from the OVF file (without
3543 a path since the image file should be in the same location as the OVF file itself), whereas the
3544 item in aVBoxValues[] will contain a qualified path specification to where VirtualBox uses the
3545 hard disk image. This means that on import the image will be copied and converted from the
3546 "ovf" location to the "vbox" location; on export, this will be handled the other way round.
3547 On import, the target image will also be registered with VirtualBox.
3548
3549 The matching item in the aExtraConfigValues[] array must contain a string of the following
3550 format: "controller=&lt;index&gt;;channel=&lt;c&gt;"
3551 In this string, &lt;index&gt; must be an integer specifying the hard disk controller to connect
3552 the image to. That number must be the index of an array item with one of the hard disk controller
3553 types (HarddiskControllerSCSI, HarddiskControllerSATA, HarddiskControllerIDE).
3554 In addition, &lt;c&gt; must specify the channel to use on that controller. For IDE controllers,
3555 this can range from 0-2 (which VirtualBox will interpret as primary master, primary slave,
3556 secondary slave; VirtualBox reserves the secondary master for the CD-ROM drive). For SATA and
3557 SCSI conrollers, the channel can range from 0-29.
3558 </li>
3559 <li>
3560 "NetworkAdapter": a network adapter. The array item in aVBoxValues[] will specify the hardware
3561 for the network adapter, whereas the array item in aExtraConfigValues[] will have a string
3562 of the "type=&lt;X&gt;" format, where &lt;X&gt; must be either "NAT" or "Bridged".
3563 </li>
3564 <li>
3565 "USBController": a USB controller. There can be at most one such item. If and only if such an
3566 item ispresent, USB support will be enabled for the new virtual machine.
3567 </li>
3568 <li>
3569 "SoundCard": a sound card. There can be at most one such item. If and only if such an item is
3570 present, sound support will be enabled for the new virtual machine. Note that the virtual
3571 machine in VirtualBox will always be presented with the standard VirtualBox soundcard, which
3572 may be different from the virtual soundcard expected by the appliance.
3573 </li>
3574 </ul>
3575
3576 </desc>
3577
3578 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
3579 <desc></desc>
3580 </param>
3581
3582 <param name="aRefs" type="wstring" dir="out" safearray="yes">
3583 <desc></desc>
3584 </param>
3585
3586 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
3587 <desc></desc>
3588 </param>
3589
3590 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
3591 <desc></desc>
3592 </param>
3593
3594 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
3595 <desc></desc>
3596 </param>
3597
3598 </method>
3599
3600 <method name="getDescriptionByType">
3601 <desc>This is the same as <link to="#getDescription" /> except that you can specify which types
3602 should be returned.</desc>
3603
3604 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
3605 <desc></desc>
3606 </param>
3607
3608 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
3609 <desc></desc>
3610 </param>
3611
3612 <param name="aRefs" type="wstring" dir="out" safearray="yes">
3613 <desc></desc>
3614 </param>
3615
3616 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
3617 <desc></desc>
3618 </param>
3619
3620 <param name="aVBoxValues" type="wstring" dir="out" safearray="yes">
3621 <desc></desc>
3622 </param>
3623
3624 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
3625 <desc></desc>
3626 </param>
3627
3628 </method>
3629
3630 <method name="getValuesByType">
3631 <desc>This is the same as <link to="#getDescriptionByType" /> except that you can specify which
3632 value types should be returned. See <link to="VirtualSystemDescriptionValueType" /> for possible
3633 values.</desc>
3634
3635 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
3636 <desc></desc>
3637 </param>
3638
3639 <param name="aWhich" type="VirtualSystemDescriptionValueType" dir="in">
3640 <desc></desc>
3641 </param>
3642
3643 <param name="aValues" type="wstring" dir="return" safearray="yes">
3644 <desc></desc>
3645 </param>
3646
3647 </method>
3648
3649 <method name="setFinalValues">
3650 <desc>
3651 This method allows the appliance's user to change the configuration for the virtual
3652 system descriptions. For each array item returned from <link to="#getDescription" />,
3653 you must pass in one boolean value and one configuration value.
3654
3655 Each item in the boolean array determines whether the particular configuration item
3656 should be enabled.
3657 You can only disable items of the types HardDiskControllerIDE, HardDiskControllerSATA,
3658 HardDiskControllerSCSI, HardDiskImage, CDROM, Floppy, NetworkAdapter, USBController
3659 and SoundCard.
3660
3661 For the "vbox" and "extra configuration" values, if you pass in the same arrays
3662 as returned in the aVBoxValues and aExtraConfigValues arrays from getDescription(),
3663 the configuration remains unchanged. Please see the documentation for getDescription()
3664 for valid configuration values for the individual array item types. If the
3665 corresponding item in the aEnabled array is false, the configuration value is ignored.
3666 </desc>
3667
3668 <param name="aEnabled" type="boolean" dir="in" safearray="yes">
3669 <desc></desc>
3670 </param>
3671
3672 <param name="aVBoxValues" type="wstring" dir="in" safearray="yes">
3673 <desc></desc>
3674 </param>
3675
3676 <param name="aExtraConfigValues" type="wstring" dir="in" safearray="yes">
3677 <desc></desc>
3678 </param>
3679 </method>
3680
3681 <method name="addDescription">
3682 <desc>
3683 This method adds an additional description entry to the stack of already
3684 available descriptions for this virtual system. This is handy for writing
3685 values which aren't directly supported by VirtualBox. One example would
3686 be the License type of <link to="VirtualSystemDescriptionType" />.
3687 </desc>
3688
3689 <param name="aType" type="VirtualSystemDescriptionType" dir="in">
3690 <desc></desc>
3691 </param>
3692
3693 <param name="aVBoxValue" type="wstring" dir="in">
3694 <desc></desc>
3695 </param>
3696
3697 <param name="aExtraConfigValue" type="wstring" dir="in">
3698 <desc></desc>
3699 </param>
3700 </method>
3701 </interface>
3702
3703
3704 <!--
3705 // IMachine
3706 /////////////////////////////////////////////////////////////////////////
3707 -->
3708
3709 <interface
3710 name="IInternalMachineControl" extends="$unknown"
3711 uuid="5595cae1-6b18-42c1-b416-bc7493a87618"
3712 internal="yes"
3713 wsmap="suppress"
3714 >
3715 <method name="updateState">
3716 <desc>
3717 Updates the VM state.
3718 <note>
3719 This operation will also update the settings file with
3720 the correct information about the saved state file
3721 and delete this file from disk when appropriate.
3722 </note>
3723 </desc>
3724 <param name="state" type="MachineState" dir="in"/>
3725 </method>
3726
3727 <method name="getIPCId">
3728 <param name="id" type="wstring" dir="return"/>
3729 </method>
3730
3731 <method name="runUSBDeviceFilters">
3732 <desc>
3733 Asks the server to run USB devices filters of the associated
3734 machine against the given USB device and tell if there is
3735 a match.
3736 <note>
3737 Intended to be used only for remote USB devices. Local
3738 ones don't require to call this method (this is done
3739 implicitly by the Host and USBProxyService).
3740 </note>
3741 </desc>
3742 <param name="device" type="IUSBDevice" dir="in"/>
3743 <param name="matched" type="boolean" dir="out"/>
3744 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
3745 </method>
3746
3747 <method name="captureUSBDevice">
3748 <desc>
3749 Requests a capture of the given host USB device.
3750 When the request is completed, the VM process will
3751 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3752 notification.
3753 </desc>
3754 <param name="id" type="wstring" dir="in"/>
3755 </method>
3756
3757 <method name="detachUSBDevice">
3758 <desc>
3759 Notification that a VM is going to detach (done = false) or has
3760 already detached (done = true) the given USB device.
3761 When the done = true request is completed, the VM process will
3762 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
3763 notification.
3764 <note>
3765 In the done = true case, the server must run its own filters
3766 and filters of all VMs but this one on the detached device
3767 as if it were just attached to the host computer.
3768 </note>
3769 </desc>
3770 <param name="id" type="wstring" dir="in"/>
3771 <param name="done" type="boolean" dir="in"/>
3772 </method>
3773
3774 <method name="autoCaptureUSBDevices">
3775 <desc>
3776 Requests a capture all matching USB devices attached to the host.
3777 When the request is completed, the VM process will
3778 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3779 notification per every captured device.
3780 </desc>
3781 </method>
3782
3783 <method name="detachAllUSBDevices">
3784 <desc>
3785 Notification that a VM that is being powered down. The done
3786 parameter indicates whether which stage of the power down
3787 we're at. When done = false the VM is announcing its
3788 intentions, while when done = true the VM is reporting
3789 what it has done.
3790 <note>
3791 In the done = true case, the server must run its own filters
3792 and filters of all VMs but this one on all detach devices as
3793 if they were just attached to the host computer.
3794 </note>
3795 </desc>
3796 <param name="done" type="boolean" dir="in"/>
3797 </method>
3798
3799 <method name="onSessionEnd">
3800 <desc>
3801 Triggered by the given session object when the session is about
3802 to close normally.
3803 </desc>
3804 <param name="session" type="ISession" dir="in">
3805 <desc>Session that is being closed</desc>
3806 </param>
3807 <param name="progress" type="IProgress" dir="return">
3808 <desc>
3809 Used to wait until the corresponding machine is actually
3810 dissociated from the given session on the server.
3811 Returned only when this session is a direct one.
3812 </desc>
3813 </param>
3814 </method>
3815
3816 <method name="beginSavingState">
3817 <desc>
3818 Called by the VM process to inform the server it wants to
3819 save the current state and stop the VM execution.
3820 </desc>
3821 <param name="progress" type="IProgress" dir="in">
3822 <desc>
3823 Progress object created by the VM process to wait until
3824 the state is saved.
3825 </desc>
3826 </param>
3827 <param name="stateFilePath" type="wstring" dir="out">
3828 <desc>
3829 File path the VM process must save the execution state to.
3830 </desc>
3831 </param>
3832 </method>
3833
3834 <method name="endSavingState">
3835 <desc>
3836 Called by the VM process to inform the server that saving
3837 the state previously requested by #beginSavingState is either
3838 successfully finished or there was a failure.
3839
3840 <result name="VBOX_E_FILE_ERROR">
3841 Settings file not accessible.
3842 </result>
3843 <result name="VBOX_E_XML_ERROR">
3844 Could not parse the settings file.
3845 </result>
3846
3847 </desc>
3848
3849 <param name="success" type="boolean" dir="in">
3850 <desc><tt>true</tt> to indicate success and <tt>false</tt>
3851 otherwise.
3852 </desc>
3853 </param>
3854 </method>
3855
3856 <method name="adoptSavedState">
3857 <desc>
3858 Gets called by IConsole::adoptSavedState.
3859 <result name="VBOX_E_FILE_ERROR">
3860 Invalid saved state file path.
3861 </result>
3862 </desc>
3863 <param name="savedStateFile" type="wstring" dir="in">
3864 <desc>Path to the saved state file to adopt.</desc>
3865 </param>
3866 </method>
3867
3868 <method name="beginTakingSnapshot">
3869 <desc>
3870 Called by the VM process to inform the server it wants to
3871 take a snapshot.
3872
3873 <result name="VBOX_E_FILE_ERROR">
3874 Settings file not accessible.
3875 </result>
3876 <result name="VBOX_E_XML_ERROR">
3877 Could not parse the settings file.
3878 </result>
3879 </desc>
3880 <param name="initiator" type="IConsole" dir="in">
3881 <desc>The console object that initiated this call.</desc>
3882 </param>
3883 <param name="name" type="wstring" dir="in">
3884 <desc>Snapshot name.</desc>
3885 </param>
3886 <param name="description" type="wstring" dir="in">
3887 <desc>Snapshot description.</desc>
3888 </param>
3889 <param name="progress" type="IProgress" dir="in">
3890 <desc>
3891 Progress object created by the VM process to wait until
3892 the state is saved (only for online snapshots).
3893 </desc>
3894 </param>
3895 <param name="stateFilePath" type="wstring" dir="out">
3896 <desc>
3897 File path the VM process must save the execution state to.
3898 </desc>
3899 </param>
3900 <param name="serverProgress" type="IProgress" dir="out">
3901 <desc>
3902 Progress object created by the server process to wait until
3903 the snapshot is taken (VDI diff creation, etc.).
3904 </desc>
3905 </param>
3906 </method>
3907
3908 <method name="endTakingSnapshot">
3909 <desc>
3910 Called by the VM process to inform the server that the snapshot
3911 previously requested by #beginTakingSnapshot is either
3912 successfully taken or there was a failure.
3913 </desc>
3914
3915 <param name="success" type="boolean" dir="in">
3916 <desc><tt>true</tt> to indicate success and <tt>false</tt> otherwise</desc>
3917 </param>
3918 </method>
3919
3920 <method name="discardSnapshot">
3921 <desc>
3922 Gets called by IConsole::discardSnapshot.
3923 <result name="VBOX_E_INVALID_OBJECT_STATE">
3924 Snapshot has more than one child snapshot.
3925 </result>
3926 </desc>
3927 <param name="initiator" type="IConsole" dir="in">
3928 <desc>The console object that initiated this call.</desc>
3929 </param>
3930 <param name="id" type="wstring" dir="in">
3931 <desc>UUID of the snapshot to discard.</desc>
3932 </param>
3933 <param name="machineState" type="MachineState" dir="out">
3934 <desc>New machine state after this operation is started.</desc>
3935 </param>
3936 <param name="progress" type="IProgress" dir="return">
3937 <desc>Progress object to track the operation completion.</desc>
3938 </param>
3939 </method>
3940
3941 <method name="discardCurrentState">
3942 <desc>
3943 Gets called by IConsole::discardCurrentState.
3944 <result name="VBOX_E_INVALID_OBJECT_STATE">
3945 Virtual machine does not have any snapshot.
3946 </result>
3947 </desc>
3948 <param name="initiator" type="IConsole" dir="in">
3949 <desc>The console object that initiated this call.</desc>
3950 </param>
3951 <param name="machineState" type="MachineState" dir="out">
3952 <desc>New machine state after this operation is started.</desc>
3953 </param>
3954 <param name="progress" type="IProgress" dir="return">
3955 <desc>Progress object to track the operation completion.</desc>
3956 </param>
3957 </method>
3958
3959 <method name="discardCurrentSnapshotAndState">
3960 <desc>
3961 Gets called by IConsole::discardCurrentSnapshotAndState.
3962 <result name="VBOX_E_INVALID_OBJECT_STATE">
3963 Virtual machine does not have any snapshot.
3964 </result>
3965 </desc>
3966 <param name="initiator" type="IConsole" dir="in">
3967 <desc>The console object that initiated this call.</desc>
3968 </param>
3969 <param name="machineState" type="MachineState" dir="out">
3970 <desc>New machine state after this operation is started.</desc>
3971 </param>
3972 <param name="progress" type="IProgress" dir="return">
3973 <desc>Progress object to track the operation completion.</desc>
3974 </param>
3975 </method>
3976
3977 <method name="pullGuestProperties">
3978 <desc>
3979 Get the list of the guest properties matching a set of patterns along
3980 with their values, time stamps and flags and give responsibility for
3981 managing properties to the console.
3982 </desc>
3983 <param name="name" type="wstring" dir="out" safearray="yes">
3984 <desc>
3985 The names of the properties returned.
3986 </desc>
3987 </param>
3988 <param name="value" type="wstring" dir="out" safearray="yes">
3989 <desc>
3990 The values of the properties returned. The array entries match the
3991 corresponding entries in the @a name array.
3992 </desc>
3993 </param>
3994 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
3995 <desc>
3996 The time stamps of the properties returned. The array entries match
3997 the corresponding entries in the @a name array.
3998 </desc>
3999 </param>
4000 <param name="flags" type="wstring" dir="out" safearray="yes">
4001 <desc>
4002 The flags of the properties returned. The array entries match the
4003 corresponding entries in the @a name array.
4004 </desc>
4005 </param>
4006 </method>
4007
4008 <method name="pushGuestProperties">
4009 <desc>
4010 Set the list of the guest properties matching a set of patterns along
4011 with their values, time stamps and flags and return responsibility for
4012 managing properties to IMachine.
4013 </desc>
4014 <param name="name" type="wstring" dir="in" safearray="yes">
4015 <desc>
4016 The names of the properties.
4017 </desc>
4018 </param>
4019 <param name="value" type="wstring" dir="in" safearray="yes">
4020 <desc>
4021 The values of the properties. The array entries match the
4022 corresponding entries in the @a name array.
4023 </desc>
4024 </param>
4025 <param name="timestamp" type="unsigned long long" dir="in" safearray="yes">
4026 <desc>
4027 The time stamps of the properties. The array entries match
4028 the corresponding entries in the @a name array.
4029 </desc>
4030 </param>
4031 <param name="flags" type="wstring" dir="in" safearray="yes">
4032 <desc>
4033 The flags of the properties. The array entries match the
4034 corresponding entries in the @a name array.
4035 </desc>
4036 </param>
4037 </method>
4038 <method name="pushGuestProperty">
4039 <desc>
4040 Update a single guest property in IMachine.
4041 </desc>
4042 <param name="name" type="wstring" dir="in">
4043 <desc>
4044 The name of the property to be updated.
4045 </desc>
4046 </param>
4047 <param name="value" type="wstring" dir="in">
4048 <desc>
4049 The value of the property.
4050 </desc>
4051 </param>
4052 <param name="timestamp" type="unsigned long long" dir="in">
4053 <desc>
4054 The timestamp of the property.
4055 </desc>
4056 </param>
4057 <param name="flags" type="wstring" dir="in">
4058 <desc>
4059 The flags of the property.
4060 </desc>
4061 </param>
4062 </method>
4063
4064 <method name="lockMedia">
4065 <desc>
4066 Locks all media attached to the machine for writing and parents of
4067 attahced different hard disks (if any) for reading. This operation is
4068 atomic so that if it fails no media is actually locked.
4069
4070 This method is intended to be called when the machine is in Starting or
4071 Restoring state. The locked media will be automatically unlocked when
4072 the machine is powered off or crashed.
4073 </desc>
4074 </method>
4075 </interface>
4076
4077 <interface
4078 name="IBIOSSettings" extends="$unknown"
4079 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
4080 wsmap="managed"
4081 >
4082 <desc>
4083 The IBIOSSettings interface represents BIOS settings of the virtual
4084 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
4085 </desc>
4086 <attribute name="logoFadeIn" type="boolean">
4087 <desc>Fade in flag for BIOS logo animation.</desc>
4088 </attribute>
4089
4090 <attribute name="logoFadeOut" type="boolean">
4091 <desc>Fade out flag for BIOS logo animation.</desc>
4092 </attribute>
4093
4094 <attribute name="logoDisplayTime" type="unsigned long">
4095 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
4096 </attribute>
4097
4098 <attribute name="logoImagePath" type="wstring">
4099 <desc>Local file system path for external BIOS image.</desc>
4100 </attribute>
4101
4102 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
4103 <desc>Mode of the BIOS boot device menu.</desc>
4104 </attribute>
4105
4106 <attribute name="ACPIEnabled" type="boolean">
4107 <desc>ACPI support flag.</desc>
4108 </attribute>
4109
4110 <attribute name="IOAPICEnabled" type="boolean">
4111 <desc>
4112 IO APIC support flag. If set, VirtualBox will provide an IO APIC
4113 and support IRQs above 15.
4114 </desc>
4115 </attribute>
4116
4117 <attribute name="timeOffset" type="long long">
4118 <desc>
4119 Offset in milliseconds from the host system time. This allows for
4120 guests running with a different system date/time than the host.
4121 It is equivalent to setting the system date/time in the BIOS except
4122 it is not an absolute value but a relative one. Guest Additions
4123 time synchronization honors this offset.
4124 </desc>
4125 </attribute>
4126
4127 <attribute name="PXEDebugEnabled" type="boolean">
4128 <desc>
4129 PXE debug logging flag. If set, VirtualBox will write extensive
4130 PXE trace information to the release log.
4131 </desc>
4132 </attribute>
4133
4134 </interface>
4135
4136 <interface
4137 name="IMachine" extends="$unknown"
4138 uuid="4d1df26d-d9c1-4c7e-b689-15e85ecf8ffc"
4139 wsmap="managed"
4140 >
4141 <desc>
4142 The IMachine interface represents a virtual machine, or guest, created
4143 in VirtualBox.
4144
4145 This interface is used in two contexts. First of all, a collection of
4146 objects implementing this interface is stored in the
4147 <link to="IVirtualBox::machines"/> attribute which lists all the virtual
4148 machines that are currently registered with this VirtualBox
4149 installation. Also, once a session has been opened for the given virtual
4150 machine (e.g. the virtual machine is running), the machine object
4151 associated with the open session can be queried from the session object;
4152 see <link to="ISession"/> for details.
4153
4154 The main role of this interface is to expose the settings of the virtual
4155 machine and provide methods to change various aspects of the virtual
4156 machine's configuration. For machine objects stored in the
4157 <link to="IVirtualBox::machines"/> collection, all attributes are
4158 read-only unless explicitly stated otherwise in individual attribute
4159 and method descriptions. In order to change a machine setting, a session
4160 for this machine must be opened using one of
4161 <link to="IVirtualBox::openSession"/>,
4162 <link to="IVirtualBox::openRemoteSession"/> or
4163 <link to="IVirtualBox::openExistingSession"/> methods. After the
4164 session has been successfully opened, a mutable machine object needs to
4165 be queried from the session object and then the desired settings changes
4166 can be applied to the returned object using IMachine attributes and
4167 methods. See the ISession interface description for more information
4168 about sessions.
4169
4170 Note that the IMachine interface does not provide methods to control
4171 virtual machine execution (such as start the machine, or power it
4172 down) -- these methods are grouped in a separate IConsole
4173 interface. Refer to the IConsole interface description to get more
4174 information about this topic.
4175
4176 <see>ISession, IConsole</see>
4177 </desc>
4178
4179 <attribute name="parent" type="IVirtualBox" readonly="yes">
4180 <desc>Associated parent object.</desc>
4181 </attribute>
4182
4183 <attribute name="accessible" type="boolean" readonly="yes">
4184 <desc>
4185 Whether this virtual machine is currently accessible or not.
4186
4187 The machine is considered to be inaccessible when:
4188 <ul>
4189 <li>It is a registered virtual machine, and
4190 </li>
4191 <li>Its settings file is inaccessible (for example, it is
4192 located on a network share that is not accessible during
4193 VirtualBox startup, or becomes inaccessible later, or if
4194 the settings file can be read but is invalid).
4195 </li>
4196 </ul>
4197
4198 Otherwise, the value of this property is always <tt>true</tt>.
4199
4200 Every time this property is read, the accessibility state of
4201 this machine is re-evaluated. If the returned value is |false|,
4202 the <link to="#accessError"/> property may be used to get the
4203 detailed error information describing the reason of
4204 inaccessibility.
4205
4206 When the machine is inaccessible, only the following properties
4207 can be used on it:
4208 <ul>
4209 <li><link to="#parent"/></li>
4210 <li><link to="#id"/></li>
4211 <li><link to="#settingsFilePath"/></li>
4212 <li><link to="#accessible"/></li>
4213 <li><link to="#accessError"/></li>
4214 </ul>
4215
4216 An attempt to access any other property or method will return
4217 an error.
4218
4219 The only possible action you can perform on an inaccessible
4220 machine is to unregister it using the
4221 <link to="IVirtualBox::unregisterMachine"/> call (or, to check
4222 for the accessibility state once more by querying this
4223 property).
4224
4225 <note>
4226 In the current implementation, once this property returns
4227 <tt>true</tt>, the machine will never become inaccessible
4228 later, even if its settings file cannot be successfully
4229 read/written any more (at least, until the VirtualBox
4230 server is restarted). This limitation may be removed in
4231 future releases.
4232 </note>
4233 </desc>
4234 </attribute>
4235
4236 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
4237 <desc>
4238 Error information describing the reason of machine
4239 inaccessibility.
4240
4241 Reading this property is only valid after the last call to
4242 <link to="#accessible"/> returned <tt>false</tt> (i.e. the
4243 machine is currently unaccessible). Otherwise, a null
4244 IVirtualBoxErrorInfo object will be returned.
4245 </desc>
4246 </attribute>
4247
4248 <attribute name="name" type="wstring">
4249 <desc>
4250 Name of the virtual machine.
4251
4252 Besides being used for human-readable identification purposes
4253 everywhere in VirtualBox, the virtual machine name is also used
4254 as a name of the machine's settings file and as a name of the
4255 subdirectory this settings file resides in. Thus, every time you
4256 change the value of this property, the settings file will be
4257 renamed once you call <link to="#saveSettings"/> to confirm the
4258 change. The containing subdirectory will be also renamed, but
4259 only if it has exactly the same name as the settings file
4260 itself prior to changing this property (for backward compatibility
4261 with previous API releases). The above implies the following
4262 limitations:
4263 <ul>
4264 <li>The machine name cannot be empty.</li>
4265 <li>The machine name can contain only characters that are valid
4266 file name characters according to the rules of the file
4267 system used to store VirtualBox configuration.</li>
4268 <li>You cannot have two or more machines with the same name
4269 if they use the same subdirectory for storing the machine
4270 settings files.</li>
4271 <li>You cannot change the name of the machine if it is running,
4272 or if any file in the directory containing the settings file
4273 is being used by another running machine or by any other
4274 process in the host operating system at a time when
4275 <link to="#saveSettings"/> is called.
4276 </li>
4277 </ul>
4278 If any of the above limitations are hit, <link to="#saveSettings"/>
4279 will return an appropriate error message explaining the exact
4280 reason and the changes you made to this machine will not be
4281 saved.
4282 <note>
4283 For "legacy" machines created using the
4284 <link to="IVirtualBox::createLegacyMachine"/> call,
4285 the above naming limitations do not apply because the
4286 machine name does not affect the settings file name.
4287 The settings file name remains the same as it was specified
4288 during machine creation and never changes.
4289 </note>
4290 </desc>
4291 </attribute>
4292
4293 <attribute name="description" type="wstring">
4294 <desc>
4295 Description of the virtual machine.
4296
4297 The description attribute can contain any text and is
4298 typically used to describe the hardware and software
4299 configuration of the virtual machine in detail (i.e. network
4300 settings, versions of the installed software and so on).
4301 </desc>
4302 </attribute>
4303
4304 <attribute name="id" type="wstring" readonly="yes">
4305 <desc>UUID of the virtual machine.</desc>
4306 </attribute>
4307
4308 <attribute name="OSTypeId" type="wstring">
4309 <desc>
4310 User-defined identifier of the Guest OS type.
4311 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
4312 an IGuestOSType object representing details about the given
4313 Guest OS type.
4314 <note>
4315 This value may differ from the value returned by
4316 <link to="IGuest::OSTypeId"/> if Guest Additions are
4317 installed to the guest OS.
4318 </note>
4319 </desc>
4320 </attribute>
4321
4322 <attribute name="HardwareVersion" type="wstring">
4323 <desc>Hardware version identifier. Internal use only for now.</desc>
4324 </attribute>
4325
4326 <attribute name="CPUCount" type="unsigned long">
4327 <desc>Number of virtual CPUs in the VM. In the current version of the product, this is always 1.</desc>
4328 </attribute>
4329
4330 <attribute name="memorySize" type="unsigned long">
4331 <desc>System memory size in megabytes.</desc>
4332 </attribute>
4333
4334 <attribute name="memoryBalloonSize" type="unsigned long">
4335 <desc>Initial memory balloon size in megabytes.</desc>
4336 </attribute>
4337
4338 <attribute name="statisticsUpdateInterval" type="unsigned long">
4339 <desc>Initial interval to update guest statistics in seconds.</desc>
4340 </attribute>
4341
4342 <attribute name="VRAMSize" type="unsigned long">
4343 <desc>Video memory size in megabytes.</desc>
4344 </attribute>
4345
4346 <attribute name="accelerate3DEnabled" type="boolean" default="false">
4347 <desc>
4348 This setting determines whether VirtualBox allows guests to make use
4349 of the 3D graphics support available on the host. Currently limited
4350 to OpenGL only. </desc>
4351 </attribute>
4352
4353 <attribute name="monitorCount" type="unsigned long">
4354 <desc>
4355 Number of virtual monitors.
4356 <note>
4357 Only effective on Windows XP and later guests with
4358 Guest Additions installed.
4359 </note>
4360 </desc>
4361 </attribute>
4362
4363 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
4364 <desc>Object containing all BIOS settings.</desc>
4365 </attribute>
4366
4367 <attribute name="HWVirtExEnabled" type="TSBool">
4368 <desc>
4369 This setting determines whether VirtualBox will try to make use of
4370 the host CPU's hardware virtualization extensions such as Intel VT-x
4371 and AMD-V. Note that in case such extensions are not available,
4372 they will not be used.
4373 </desc>
4374 </attribute>
4375
4376 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" default="false">
4377 <desc>
4378 This setting determines whether VirtualBox will try to make use of
4379 the nested paging extension of Intel VT-x and AMD-V. Note that in case
4380 such extensions are not available, they will not be used.
4381 </desc>
4382 </attribute>
4383
4384 <attribute name="HWVirtExVPIDEnabled" type="boolean" default="false">
4385 <desc>
4386 This setting determines whether VirtualBox will try to make use of
4387 the VPID extension of Intel VT-x. Note that in case such extensions are
4388 not available, they will not be used.
4389 </desc>
4390 </attribute>
4391
4392 <attribute name="PAEEnabled" type="boolean" default="false">
4393 <desc>
4394 This setting determines whether VirtualBox will expose the Physical Address
4395 Extension (PAE) feature of the host CPU to the guest. Note that in case PAE
4396 is not available, it will not be reported.
4397 </desc>
4398 </attribute>
4399
4400 <attribute name="snapshotFolder" type="wstring">
4401 <desc>
4402 Full path to the directory used to store snapshot data
4403 (differencing hard disks and saved state files) of this machine.
4404
4405 The initial value of this property is
4406 <tt>&lt;</tt><link to="#settingsFilePath">
4407 path_to_settings_file</link><tt>&gt;/&lt;</tt>
4408 <link to="#id">machine_uuid</link>
4409 <tt>&gt;</tt>.
4410
4411 Currently, it is an error to try to change this property on
4412 a machine that has snapshots (because this would require to
4413 move possibly large files to a different location).
4414 A separate method will be available for this purpose later.
4415
4416 <note>
4417 Setting this property to <tt>null</tt> will restore the
4418 initial value.
4419 </note>
4420 <note>
4421 When setting this property, the specified path can be
4422 absolute (full path) or relative to the directory where the
4423 <link to="#settingsFilePath">machine settings file</link>
4424 is located. When reading this property, a full path is
4425 always returned.
4426 </note>
4427 <note>
4428 The specified path may not exist, it will be created
4429 when necessary.
4430 </note>
4431 </desc>
4432 </attribute>
4433
4434 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
4435 <desc>VRDP server object.</desc>
4436 </attribute>
4437
4438 <attribute name="hardDiskAttachments" type="IHardDiskAttachment" readonly="yes" safearray="yes">
4439 <desc>Array of hard disks attached to this machine.</desc>
4440 </attribute>
4441
4442 <attribute name="DVDDrive" type="IDVDDrive" readonly="yes">
4443 <desc>Associated DVD drive object.</desc>
4444 </attribute>
4445
4446 <attribute name="floppyDrive" type="IFloppyDrive" readonly="yes">
4447 <desc>Associated floppy drive object.</desc>
4448 </attribute>
4449
4450 <attribute name="USBController" type="IUSBController" readonly="yes">
4451 <desc>
4452 Associated USB controller object.
4453
4454 <note>
4455 If USB functionality is not available in the given edition of
4456 VirtualBox, this method will set the result code to @c E_NOTIMPL.
4457 </note>
4458 </desc>
4459 </attribute>
4460
4461 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
4462 <desc>Associated audio adapter, always present.</desc>
4463 </attribute>
4464
4465 <attribute name="storageControllers" type="IStorageController" readonly="yes" safearray="yes">
4466 <desc>Array of storage controllers attached to this machine.</desc>
4467 </attribute>
4468
4469 <attribute name="settingsFilePath" type="wstring" readonly="yes">
4470 <desc>
4471 Full name of the file containing machine settings data.
4472 </desc>
4473 </attribute>
4474
4475 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
4476 <desc>
4477 Current version of the format of the settings file of this machine
4478 (<link to="IMachine::settingsFilePath"/>).
4479
4480 The version string has the following format:
4481 <pre>
4482 x.y-platform
4483 </pre>
4484 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
4485 versions, and <tt>platform</tt> is the platform identifier.
4486
4487 The current version usually matches the value of the
4488 <link to="IVirtualBox::settingsFormatVersion"/> attribute unless the
4489 settings file was created by an older version of VirtualBox and there
4490 was a change of the settings file format since then.
4491
4492 Note that VirtualBox automatically converts settings files from older
4493 versions to the most recent version when reading them (usually at
4494 VirtualBox startup) but it doesn't save the changes back until
4495 you call a method that implicitly saves settings (such as
4496 <link to="#setExtraData"/>) or call <link to="#saveSettings"/>
4497 explicitly. Therefore, if the value of this attribute differs from the
4498 value of <link to="IVirtualBox::settingsFormatVersion"/>, then it
4499 means that the settings file was converted but the result of the
4500 conversion is not yet saved to disk.
4501
4502 The above feature may be used by interactive front-ends to inform users
4503 about the settings file format change and offer them to explicitly save
4504 all converted settings files (the global and VM-specific ones),
4505 optionally create backup copies of the old settings files before saving,
4506 etc.
4507
4508 <see>IVirtualBox::settingsFormatVersion, saveSettingsWithBackup()</see>
4509 </desc>
4510 </attribute>
4511
4512 <attribute name="settingsModified" type="boolean" readonly="yes">
4513 <desc>
4514 Whether the settings of this machine have been modified
4515 (but neither yet saved nor discarded).
4516 <note>
4517 Reading this property is only valid on instances returned
4518 by <link to="ISession::machine"/> and on new machines
4519 created by <link to="IVirtualBox::createMachine"/> or opened
4520 by <link to="IVirtualBox::openMachine"/> but not
4521 yet registered, or on unregistered machines after calling
4522 <link to="IVirtualBox::unregisterMachine"/>. For all other
4523 cases, the settings can never be modified.
4524 </note>
4525 <note>
4526 For newly created unregistered machines, the value of this
4527 property is always TRUE until <link to="#saveSettings"/>
4528 is called (no matter if any machine settings have been
4529 changed after the creation or not). For opened machines
4530 the value is set to FALSE (and then follows to normal rules).
4531 </note>
4532 </desc>
4533 </attribute>
4534
4535 <attribute name="sessionState" type="SessionState" readonly="yes">
4536 <desc>Current session state for this machine.</desc>
4537 </attribute>
4538
4539 <attribute name="sessionType" type="wstring" readonly="yes">
4540 <desc>
4541 Type of the session. If <link to="#sessionState"/> is
4542 SessionSpawning or SessionOpen, this attribute contains the
4543 same value as passed to the
4544 <link to="IVirtualBox::openRemoteSession"/> method in the
4545 @a type parameter. If the session was opened directly using
4546 <link to="IVirtualBox::openSession"/>, or if
4547 <link to="#sessionState"/> is SessionClosed, the value of this
4548 attribute is @c null.
4549 </desc>
4550 </attribute>
4551
4552 <attribute name="sessionPid" type="unsigned long" readonly="yes">
4553 <desc>
4554 Identifier of the session process. This attribute contains the
4555 platform-dependent identifier of the process that has opened a
4556 direct session for this machine using the
4557 <link to="IVirtualBox::openSession"/> call. The returned value
4558 is only valid if <link to="#sessionState"/> is SessionOpen or
4559 SessionClosing (i.e. a session is currently open or being
4560 closed) by the time this property is read.
4561 </desc>
4562 </attribute>
4563
4564 <attribute name="state" type="MachineState" readonly="yes">
4565 <desc>Current execution state of this machine.</desc>
4566 </attribute>
4567
4568 <attribute name="lastStateChange" type="long long" readonly="yes">
4569 <desc>
4570 Time stamp of the last execution state change,
4571 in milliseconds since 1970-01-01 UTC.
4572 </desc>
4573 </attribute>
4574
4575 <attribute name="stateFilePath" type="wstring" readonly="yes">
4576 <desc>
4577 Full path to the file that stores the execution state of
4578 the machine when it is in the <link to="MachineState_Saved"/> state.
4579 <note>
4580 When the machine is not in the Saved state, this attribute
4581 <tt>null</tt>.
4582 </note>
4583 </desc>
4584 </attribute>
4585
4586 <attribute name="logFolder" type="wstring" readonly="yes">
4587 <desc>
4588 Full path to the folder that stores a set of rotated log files
4589 recorded during machine execution. The most recent log file is
4590 named <tt>VBox.log</tt>, the previous log file is
4591 named <tt>VBox.log.1</tt> and so on (up to <tt>VBox.log.3</tt>
4592 in the current version).
4593 </desc>
4594 </attribute>
4595
4596 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
4597 <desc>
4598 Current snapshot of this machine.
4599 <note>
4600 A <tt>null</tt> object is returned if the machine doesn't
4601 have snapshots.
4602 </note>
4603 <see><link to="ISnapshot"/></see>
4604 </desc>
4605 </attribute>
4606
4607 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
4608 <desc>
4609 Number of snapshots taken on this machine. Zero means the
4610 machine doesn't have any snapshots.
4611 </desc>
4612 </attribute>
4613
4614 <attribute name="currentStateModified" type="boolean" readonly="yes">
4615 <desc>
4616 Returns <tt>true</tt> if the current state of the machine is not
4617 identical to the state stored in the current snapshot.
4618
4619 The current state is identical to the current snapshot right
4620 after one of the following calls are made:
4621 <ul>
4622 <li><link to="IConsole::discardCurrentState"/> or
4623 <link to="IConsole::discardCurrentSnapshotAndState"/>
4624 </li>
4625 <li><link to="IConsole::takeSnapshot"/> (issued on a
4626 powered off or saved machine, for which
4627 <link to="#settingsModified"/> returns <tt>false</tt>)
4628 </li>
4629 <li><link to="IMachine::setCurrentSnapshot"/>
4630 </li>
4631 </ul>
4632
4633 The current state remains identical until one of the following
4634 happens:
4635 <ul>
4636 <li>settings of the machine are changed</li>
4637 <li>the saved state is discarded</li>
4638 <li>the current snapshot is discarded</li>
4639 <li>an attempt to execute the machine is made</li>
4640 </ul>
4641
4642 <note>
4643 For machines that don't have snapshots, this property is
4644 always <tt>false</tt>.
4645 </note>
4646 </desc>
4647 </attribute>
4648
4649 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
4650 <desc>
4651 Collection of shared folders for this machine (permanent shared
4652 folders). These folders are shared automatically at machine startup
4653 and available only to the guest OS installed within this machine.
4654
4655 New shared folders are added to the collection using
4656 <link to="#createSharedFolder"/>. Existing shared folders can be
4657 removed using <link to="#removeSharedFolder"/>.
4658 </desc>
4659 </attribute>
4660
4661 <attribute name="clipboardMode" type="ClipboardMode">
4662 <desc>
4663 Synchronization mode between the host OS clipboard
4664 and the guest OS clipboard.
4665 </desc>
4666 </attribute>
4667
4668 <attribute name="guestPropertyNotificationPatterns" type="wstring">
4669 <desc>
4670 A comma-separated list of simple glob patterns. Changes to guest
4671 properties whose name matches one of the patterns will generate an
4672 <link to="IVirtualBoxCallback::onGuestPropertyChange"/> signal.
4673 </desc>
4674 </attribute>
4675
4676 <method name="setBootOrder">
4677 <desc>
4678 Puts the given device to the specified position in
4679 the boot order.
4680
4681 To indicate that no device is associated with the given position,
4682 <link to="DeviceType_Null"/> should be used.
4683
4684 @todo setHardDiskBootOrder(), setNetworkBootOrder()
4685
4686 <result name="E_INVALIDARG">
4687 Boot @a position out of range.
4688 </result>
4689 <result name="E_NOTIMPL">
4690 Booting from USB @a device currently not supported.
4691 </result>
4692
4693 </desc>
4694 <param name="position" type="unsigned long" dir="in">
4695 <desc>
4696 Position in the boot order (<tt>1</tt> to the total number of
4697 devices the machine can boot from, as returned by
4698 <link to="ISystemProperties::maxBootPosition"/>).
4699 </desc>
4700 </param>
4701 <param name="device" type="DeviceType" dir="in">
4702 <desc>
4703 The type of the device used to boot at the given position.
4704 </desc>
4705 </param>
4706 </method>
4707
4708 <method name="getBootOrder" const="yes">
4709 <desc>
4710 Returns the device type that occupies the specified
4711 position in the boot order.
4712
4713 @todo [remove?]
4714 If the machine can have more than one device of the returned type
4715 (such as hard disks), then a separate method should be used to
4716 retrieve the individual device that occupies the given position.
4717
4718 If here are no devices at the given position, then
4719 <link to="DeviceType_Null"/> is returned.
4720
4721 @todo getHardDiskBootOrder(), getNetworkBootOrder()
4722
4723 <result name="E_INVALIDARG">
4724 Boot @a position out of range.
4725 </result>
4726
4727 </desc>
4728 <param name="position" type="unsigned long" dir="in">
4729 <desc>
4730 Position in the boot order (<tt>1</tt> to the total number of
4731 devices the machine can boot from, as returned by
4732 <link to="ISystemProperties::maxBootPosition"/>).
4733 </desc>
4734 </param>
4735 <param name="device" type="DeviceType" dir="return">
4736 <desc>
4737 Device at the given position.
4738 </desc>
4739 </param>
4740 </method>
4741
4742 <method name="attachHardDisk">
4743 <desc>
4744 Attaches a virtual hard disk (<link to="IHardDisk" />, identified
4745 by the given UUID @a id) to the given hard disk controller
4746 (<link to="IStorageController" />, identified by @a name),
4747 at the indicated port and device.
4748
4749 For the IDE bus, the @a controllerPort parameter can be either
4750 @c 0 or @c 1, to specify the primary or secondary IDE controller,
4751 respectively. For the primary controller of the IDE bus,
4752 @a device can be either @c 0 or @c 1, to specify the master or the
4753 slave device, respectively. For the secondary IDE controller, the
4754 device number must be @c 1 because VirtualBox reserves the
4755 secondary master for the CD-ROM drive.
4756
4757 For an SATA controller, @a controllerPort must be a number ranging
4758 from @c 0 to @c 29. For a SCSI controller, @a controllerPort must
4759 be a number ranging from @c 0 to @c 15.
4760
4761 For both SCSI and SATA, the @a device parameter is unused and must
4762 be @c 0.
4763
4764 The specified device slot must not have another disk attached to it, or
4765 this method will fail.
4766
4767 See <link to="IHardDisk"/> for more detailed information about
4768 attaching hard disks.
4769
4770 <note>
4771 You cannot attach a hard disk to a running machine. Also, you cannot
4772 attach a hard disk to a newly created machine until this machine's
4773 settings are saved to disk using <link to="#saveSettings"/>.
4774 </note>
4775 <note>
4776 If the hard disk is being attached indirectly, a new differencing hard
4777 disk will implicitly be created for it and attached instead. If the
4778 changes made to the machine settings (including this indirect
4779 attachment) are later cancelled using <link to="#discardSettings"/>,
4780 this implicitly created differencing hard disk will implicitly
4781 be deleted.
4782 </note>
4783
4784 <result name="E_INVALIDARG">
4785 SATA device, SATA port, IDE port or IDE slot out of range.
4786 </result>
4787 <result name="VBOX_E_INVALID_OBJECT_STATE">
4788 Attempt to attach hard disk to an unregistered virtual machine.
4789 </result>
4790 <result name="VBOX_E_INVALID_VM_STATE">
4791 Invalid machine state.
4792 </result>
4793 <result name="VBOX_E_OBJECT_IN_USE">
4794 Hard disk already attached to this or another virtual machine.
4795 </result>
4796
4797 </desc>
4798 <param name="id" type="wstring" dir="in">
4799 <desc>UUID of the hard disk to attach.</desc>
4800 </param>
4801 <param name="name" type="wstring" dir="in">
4802 <desc>Name of the storage controller to attach the hard disk to.</desc>
4803 </param>
4804 <param name="controllerPort" type="long" dir="in">
4805 <desc>Port to attach the hard disk to.</desc>
4806 </param>
4807 <param name="device" type="long" dir="in">
4808 <desc>
4809 Device slot in the given port to attach the hard disk to.
4810 </desc>
4811 </param>
4812 </method>
4813
4814 <method name="getHardDisk" const="yes">
4815 <desc>
4816 Returns the virtual hard disk attached to a device slot of the specified
4817 bus.
4818
4819 Note that if the hard disk was indirectly attached by
4820 <link to="#attachHardDisk"/> to the given device slot then this
4821 method will return not the same object as passed to the
4822 <link to="#attachHardDisk"/> call. See <link to="IHardDisk"/> for
4823 more detailed information about attaching hard disks.
4824
4825 <result name="VBOX_E_OBJECT_NOT_FOUND">
4826 No hard disk attached to given slot/bus.
4827 </result>
4828
4829 </desc>
4830 <param name="name" type="wstring" dir="in">
4831 <desc>Name of the storage controller the hard disk is attached to.</desc>
4832 </param>
4833 <param name="controllerPort" type="long" dir="in">
4834 <desc>Port to query.</desc>
4835 </param>
4836 <param name="device" type="long" dir="in">
4837 <desc>Device slot in the given port to query.</desc>
4838 </param>
4839 <param name="hardDisk" type="IHardDisk" dir="return">
4840 <desc>Attached hard disk object.</desc>
4841 </param>
4842 </method>
4843
4844 <method name="detachHardDisk">
4845 <desc>
4846 Detaches the virtual hard disk attached to a device slot of the
4847 specified bus.
4848
4849 Detaching the hard disk from the virtual machine is deferred. This means
4850 that the hard disk remains associated with the machine when this method
4851 returns and gets actually de-associated only after a successful
4852 <link to="#saveSettings"/> call. See <link to="IHardDisk"/>
4853 for more detailed information about attaching hard disks.
4854
4855 <note>
4856 You cannot detach the hard disk from a running machine.
4857 </note>
4858 <note>
4859 Detaching differencing hard disks implicitly created by <link
4860 to="#attachHardDisk"/> for the indirect attachment using this
4861 method will <b>not</b> implicitly delete them. The
4862 <link to="IHardDisk::deleteStorage"/> operation should be
4863 explicitly performed by the caller after the hard disk is successfully
4864 detached and the settings are saved with
4865 <link to="#saveSettings"/>, if it is the desired action.
4866 </note>
4867
4868 <result name="VBOX_E_INVALID_VM_STATE">
4869 Attempt to detach hard disk from a running virtual machine.
4870 </result>
4871 <result name="VBOX_E_OBJECT_NOT_FOUND">
4872 No hard disk attached to given slot/bus.
4873 </result>
4874 <result name="VBOX_E_NOT_SUPPORTED">
4875 Hard disk format does not support storage deletion.
4876 </result>
4877
4878 </desc>
4879 <param name="name" type="wstring" dir="in">
4880 <desc>name of the storage controller to detach the hard disk from.</desc>
4881 </param>
4882 <param name="controllerPort" type="long" dir="in">
4883 <desc>Port number to detach the hard disk from.</desc>
4884 </param>
4885 <param name="device" type="long" dir="in">
4886 <desc>Device slot number to detach the hard disk from.</desc>
4887 </param>
4888 </method>
4889
4890 <method name="getHardDiskAttachmentsOfController" const="yes">
4891 <desc>
4892 Returns an array of hard disk attachments which are attached to the
4893 the controller with the given name.
4894
4895 <result name="VBOX_E_OBJECT_NOT_FOUND">
4896 A storage controller with given name doesn't exist.
4897 </result>
4898 </desc>
4899 <param name="name" type="wstring" dir="in"/>
4900 <param name="hardDiskAttachments" type="IHardDiskAttachment" safearray="yes" dir="return"/>
4901 </method>
4902
4903 <method name="getNetworkAdapter" const="yes">
4904 <desc>
4905 Returns the network adapter associated with the given slot.
4906 Slots are numbered sequentially, starting with zero. The total
4907 number of adapters per machine is defined by the
4908 <link to="ISystemProperties::networkAdapterCount"/> property,
4909 so the maximum slot number is one less than that property's value.
4910
4911 <result name="E_INVALIDARG">
4912 Invalid @a slot number.
4913 </result>
4914
4915 </desc>
4916 <param name="slot" type="unsigned long" dir="in"/>
4917 <param name="adapter" type="INetworkAdapter" dir="return"/>
4918 </method>
4919
4920 <method name="addStorageController">
4921 <desc>
4922 Adds a new storage controller (SCSI or SATA controller) to the
4923 machine and returns it as an instance of
4924 <link to="IStorageController" />.
4925
4926 @a name identifies the controller for subsequent calls such as
4927 <link to="#getStorageControllerByName" /> or
4928 <link to="#removeStorageController" /> or
4929 <link to="#attachHardDisk" />.
4930
4931 After the controller has been added, you can set its exact
4932 type by setting the <link to="IStorageController::controllerType" />.
4933
4934 <result name="VBOX_E_OBJECT_IN_USE">
4935 A storage controller with given name exists already.
4936 </result>
4937 <result name="E_INVALIDARG">
4938 Invalid @a controllerType.
4939 </result>
4940 </desc>
4941 <param name="name" type="wstring" dir="in"/>
4942 <param name="connectionType" type="StorageBus" dir="in"/>
4943 <param name="controller" type="IStorageController" dir="return"/>
4944 </method>
4945
4946 <method name="getStorageControllerByName" const="yes">
4947 <desc>
4948 Returns a storage controller with the given name.
4949
4950 <result name="VBOX_E_OBJECT_NOT_FOUND">
4951 A storage controller with given name doesn't exist.
4952 </result>
4953 </desc>
4954 <param name="name" type="wstring" dir="in"/>
4955 <param name="storageController" type="IStorageController" dir="return"/>
4956 </method>
4957
4958 <method name="removeStorageController">
4959 <desc>
4960 Removes a storage controller from the machine.
4961
4962 <result name="VBOX_E_OBJECT_NOT_FOUND">
4963 A storage controller with given name doesn't exist.
4964 </result>
4965 </desc>
4966 <param name="name" type="wstring" dir="in"/>
4967 </method>
4968
4969 <method name="getSerialPort" const="yes">
4970 <desc>
4971 Returns the serial port associated with the given slot.
4972 Slots are numbered sequentially, starting with zero. The total
4973 number of serial ports per machine is defined by the
4974 <link to="ISystemProperties::serialPortCount"/> property,
4975 so the maximum slot number is one less than that property's value.
4976
4977 <result name="E_INVALIDARG">
4978 Invalid @a slot number.
4979 </result>
4980
4981 </desc>
4982 <param name="slot" type="unsigned long" dir="in"/>
4983 <param name="port" type="ISerialPort" dir="return"/>
4984 </method>
4985
4986 <method name="getParallelPort" const="yes">
4987 <desc>
4988 Returns the parallel port associated with the given slot.
4989 Slots are numbered sequentially, starting with zero. The total
4990 number of parallel ports per machine is defined by the
4991 <link to="ISystemProperties::parallelPortCount"/> property,
4992 so the maximum slot number is one less than that property's value.
4993
4994 <result name="E_INVALIDARG">
4995 Invalid @a slot number.
4996 </result>
4997
4998 </desc>
4999 <param name="slot" type="unsigned long" dir="in"/>
5000 <param name="port" type="IParallelPort" dir="return"/>
5001 </method>
5002
5003 <method name="getNextExtraDataKey">
5004 <desc>
5005 Returns the machine-specific extra data key name following the
5006 supplied key.
5007
5008 An error is returned if the supplied @a key does not exist. @c NULL is
5009 returned in @a nextKey if the supplied key is the last key. When
5010 supplying @c NULL for the @a key, the first key item is returned in
5011 @a nextKey (if there is any). @a nextValue is an optional parameter and
5012 if supplied, the next key's value is returned in it.
5013
5014 <result name="VBOX_E_OBJECT_NOT_FOUND">
5015 Extra data @a key not found.
5016 </result>
5017
5018 </desc>
5019 <param name="key" type="wstring" dir="in">
5020 <desc>Name of the data key to follow.</desc>
5021 </param>
5022 <param name="nextKey" type="wstring" dir="out">
5023 <desc>Name of the next data key.</desc>
5024 </param>
5025 <param name="nextValue" type="wstring" dir="out">
5026 <desc>Value of the next data key.</desc>
5027 </param>
5028 </method>
5029
5030 <method name="getExtraData">
5031 <desc>
5032 Returns associated machine-specific extra data.
5033
5034 If the requested data @a key does not exist, this function will
5035 succeed and return @c NULL in the @a value argument.
5036
5037 <result name="VBOX_E_FILE_ERROR">
5038 Settings file not accessible.
5039 </result>
5040 <result name="VBOX_E_XML_ERROR">
5041 Could not parse the settings file.
5042 </result>
5043
5044 </desc>
5045 <param name="key" type="wstring" dir="in">
5046 <desc>Name of the data key to get.</desc>
5047 </param>
5048 <param name="value" type="wstring" dir="return">
5049 <desc>Value of the requested data key.</desc>
5050 </param>
5051 </method>
5052
5053 <method name="setExtraData">
5054 <desc>
5055 Sets associated machine-specific extra data.
5056
5057 If you pass @c NULL as a key @a value, the given @a key will be
5058 deleted.
5059
5060 <note>
5061 Before performing the actual data change, this method will ask all
5062 registered callbacks using the
5063 <link to="IVirtualBoxCallback::onExtraDataCanChange"/>
5064 notification for a permission. If one of the callbacks refuses the
5065 new value, the change will not be performed.
5066 </note>
5067 <note>
5068 On success, the
5069 <link to="IVirtualBoxCallback::onExtraDataChange"/> notification
5070 is called to inform all registered callbacks about a successful data
5071 change.
5072 </note>
5073 <note>
5074 This method can be called outside the machine session and therefore
5075 it's a caller's responsibility to handle possible race conditions
5076 when several clients change the same key at the same time.
5077 </note>
5078
5079 <result name="VBOX_E_FILE_ERROR">
5080 Settings file not accessible.
5081 </result>
5082 <result name="VBOX_E_XML_ERROR">
5083 Could not parse the settings file.
5084 </result>
5085
5086 </desc>
5087 <param name="key" type="wstring" dir="in">
5088 <desc>Name of the data key to set.</desc>
5089 </param>
5090 <param name="value" type="wstring" dir="in">
5091 <desc>Value to assign to the key.</desc>
5092 </param>
5093 </method>
5094
5095 <method name="saveSettings">
5096 <desc>
5097 Saves any changes to machine settings made since the session
5098 has been opened or a new machine has been created, or since the
5099 last call to <link to="#saveSettings"/> or <link to="#discardSettings"/>.
5100 For registered machines, new settings become visible to all
5101 other VirtualBox clients after successful invocation of this
5102 method.
5103 <note>
5104 The method sends <link to="IVirtualBoxCallback::onMachineDataChange"/>
5105 notification event after the configuration has been successfully
5106 saved (only for registered machines).
5107 </note>
5108 <note>
5109 Calling this method is only valid on instances returned
5110 by <link to="ISession::machine"/> and on new machines
5111 created by <link to="IVirtualBox::createMachine"/> but not
5112 yet registered, or on unregistered machines after calling
5113 <link to="IVirtualBox::unregisterMachine"/>.
5114 </note>
5115
5116 <result name="VBOX_E_FILE_ERROR">
5117 Settings file not accessible.
5118 </result>
5119 <result name="VBOX_E_XML_ERROR">
5120 Could not parse the settings file.
5121 </result>
5122 <result name="E_ACCESSDENIED">
5123 Modification request refused.
5124 </result>
5125
5126 </desc>
5127 </method>
5128
5129 <method name="saveSettingsWithBackup">
5130 <desc>
5131 Creates a backup copy of the machine settings file (<link
5132 to="IMachine::settingsFilePath"/>) in case of auto-conversion, and then calls
5133 <link to="IMachine::saveSettings"/>.
5134
5135 Note that the backup copy is created <b>only</b> if the settings file
5136 auto-conversion took place (see <link to="#settingsFileVersion"/> for
5137 details). Otherwise, this call is fully equivalent to
5138 <link to="IMachine::saveSettings"/> and no backup copying is done.
5139
5140 The backup copy is created in the same directory where the original
5141 settings file is located. It is given the following file name:
5142 <pre>
5143 original.xml.x.y-platform.bak
5144 </pre>
5145 where <tt>original.xml</tt> is the original settings file name
5146 (excluding path), and <tt>x.y-platform</tt> is the version of the old
5147 format of the settings file (before auto-conversion).
5148
5149 If the given backup file already exists, this method will try to add the
5150 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
5151 0 to 9) and copy it again until it succeeds. If all suffixes are
5152 occupied, or if any other copy error occurs, this method will return a
5153 failure.
5154
5155 If the copy operation succeeds, the @a bakFileName return argument will
5156 receive a full path to the created backup file (for informational
5157 purposes). Note that this will happen even if the subsequent
5158 <link to="#saveSettings"/> call performed by this method after the
5159 copy operation, fails.
5160
5161 <note>
5162 The VirtualBox API never calls this method. It is intended purely for
5163 the purposes of creating backup copies of the settings files by
5164 front-ends before saving the results of the automatically performed
5165 settings conversion to disk.
5166 </note>
5167
5168 <see>settingsFileVersion</see>
5169
5170 <result name="VBOX_E_FILE_ERROR">
5171 Settings file not accessible.
5172 </result>
5173 <result name="VBOX_E_XML_ERROR">
5174 Could not parse the settings file.
5175 </result>
5176 <result name="VBOX_E_INVALID_VM_STATE">
5177 Virtual machine is not mutable.
5178 </result>
5179 <result name="E_ACCESSDENIED">
5180 Modification request refused.
5181 </result>
5182
5183 </desc>
5184 <param name="bakFileName" type="wstring" dir="return">
5185 <desc>Full path to the created backup copy.</desc>
5186 </param>
5187 </method>
5188
5189 <method name="discardSettings">
5190 <desc>
5191 Discards any changes to the machine settings made since the session
5192 has been opened or since the last call to <link to="#saveSettings"/>
5193 or <link to="#discardSettings"/>.
5194 <note>
5195 Calling this method is only valid on instances returned
5196 by <link to="ISession::machine"/> and on new machines
5197 created by <link to="IVirtualBox::createMachine"/> or
5198 opened by <link to="IVirtualBox::openMachine"/> but not
5199 yet registered, or on unregistered machines after calling
5200 <link to="IVirtualBox::unregisterMachine"/>.
5201 </note>
5202
5203 <result name="VBOX_E_INVALID_VM_STATE">
5204 Virtual machine is not mutable.
5205 </result>
5206
5207 </desc>
5208 </method>
5209
5210 <method name="deleteSettings">
5211 <desc>
5212 Deletes the settings file of this machine from disk.
5213 The machine must not be registered in order for this operation
5214 to succeed.
5215 <note>
5216 <link to="#settingsModified"/> will return TRUE after this
5217 method successfully returns.
5218 </note>
5219 <note>
5220 Calling this method is only valid on instances returned
5221 by <link to="ISession::machine"/> and on new machines
5222 created by <link to="IVirtualBox::createMachine"/> or
5223 opened by <link to="IVirtualBox::openMachine"/> but not
5224 yet registered, or on unregistered machines after calling
5225 <link to="IVirtualBox::unregisterMachine"/>.
5226 </note>
5227 <note>
5228 The deleted machine settings file can be restored (saved again)
5229 by calling <link to="#saveSettings"/>.
5230 </note>
5231
5232 <result name="VBOX_E_INVALID_VM_STATE">
5233 Cannot delete settings of a registered machine or
5234 machine not mutable.
5235 </result>
5236 <result name="VBOX_E_IPRT_ERROR">
5237 Could not delete the settings file.
5238 </result>
5239
5240 </desc>
5241 </method>
5242
5243 <method name="export">
5244 <desc>Exports the machine to an OVF appliance. See <link to="IAppliance" /> for the
5245 steps required to export VirtualBox machines to OVF.
5246 </desc>
5247
5248 <param name="aAppliance" type="IAppliance" dir="in">
5249 <desc>Appliance to export this machine to.</desc>
5250 </param>
5251 <param name="aDescription" type="IVirtualSystemDescription" dir="return">
5252 <desc>VirtualSystemDescription object which is created for this machine.</desc>
5253 </param>
5254 </method >
5255
5256 <method name="getSnapshot">
5257 <desc>
5258 Returns a snapshot of this machine with the given UUID.
5259 A <tt>null</tt> UUID can be used to obtain the first snapshot
5260 taken on this machine. This is useful if you want to traverse
5261 the whole tree of snapshots starting from the root.
5262
5263 <result name="VBOX_E_OBJECT_NOT_FOUND">
5264 Virtual machine has no snapshots or snapshot not found.
5265 </result>
5266
5267 </desc>
5268 <param name="id" type="wstring" dir="in">
5269 <desc>UUID of the snapshot to get</desc>
5270 </param>
5271 <param name="snapshot" type="ISnapshot" dir="return">
5272 <desc>Snapshot object with the given UUID.</desc>
5273 </param>
5274 </method>
5275
5276 <method name="findSnapshot">
5277 <desc>
5278 Returns a snapshot of this machine with the given name.
5279
5280 <result name="VBOX_E_OBJECT_NOT_FOUND">
5281 Virtual machine has no snapshots or snapshot not found.
5282 </result>
5283
5284 </desc>
5285 <param name="name" type="wstring" dir="in">
5286 <desc>Name of the snapshot to find</desc>
5287 </param>
5288 <param name="snapshot" type="ISnapshot" dir="return">
5289 <desc>Snapshot object with the given name.</desc>
5290 </param>
5291 </method>
5292
5293 <method name="setCurrentSnapshot">
5294 <desc>
5295 Sets the current snapshot of this machine.
5296 <note>
5297 In the current implementation, this operation is not
5298 implemented.
5299 </note>
5300 </desc>
5301 <param name="id" type="wstring" dir="in">
5302 <desc>UUID of the snapshot to set as the current snapshot.</desc>
5303 </param>
5304 </method>
5305
5306 <method name="createSharedFolder">
5307 <desc>
5308 Creates a new permanent shared folder by associating the given logical
5309 name with the given host path, adds it to the collection of shared
5310 folders and starts sharing it. Refer to the description of
5311 <link to="ISharedFolder"/> to read more about logical names.
5312
5313 <result name="VBOX_E_OBJECT_IN_USE">
5314 Shared folder already exists.
5315 </result>
5316 <result name="VBOX_E_FILE_ERROR">
5317 Shared folder @a hostPath not accessible.
5318 </result>
5319
5320 </desc>
5321 <param name="name" type="wstring" dir="in">
5322 <desc>Unique logical name of the shared folder.</desc>
5323 </param>
5324 <param name="hostPath" type="wstring" dir="in">
5325 <desc>Full path to the shared folder in the host file system.</desc>
5326 </param>
5327 <param name="writable" type="boolean" dir="in">
5328 <desc>Whether the share is writable or readonly</desc>
5329 </param>
5330 </method>
5331
5332 <method name="removeSharedFolder">
5333 <desc>
5334 Removes the permanent shared folder with the given name previously
5335 created by <link to="#createSharedFolder"/> from the collection of
5336 shared folders and stops sharing it.
5337
5338 <result name="VBOX_E_INVALID_VM_STATE">
5339 Virtual machine is not mutable.
5340 </result>
5341 <result name="VBOX_E_OBJECT_NOT_FOUND">
5342 Shared folder @a name does not exist.
5343 </result>
5344
5345 </desc>
5346 <param name="name" type="wstring" dir="in">
5347 <desc>Logical name of the shared folder to remove.</desc>
5348 </param>
5349 </method>
5350
5351 <method name="canShowConsoleWindow">
5352 <desc>
5353 Returns @c true if the VM console process can activate the
5354 console window and bring it to foreground on the desktop of
5355 the host PC.
5356 <note>
5357 This method will fail if a session for this machine is not
5358 currently open.
5359 </note>
5360
5361 <result name="VBOX_E_INVALID_VM_STATE">
5362 Machine session is not open.
5363 </result>
5364
5365 </desc>
5366 <param name="canShow" type="boolean" dir="return">
5367 <desc>
5368 @c true if the console window can be shown and @c
5369 false otherwise.
5370 </desc>
5371 </param>
5372 </method>
5373
5374 <method name="showConsoleWindow">
5375 <desc>
5376 Activates the console window and brings it to foreground on
5377 the desktop of the host PC. Many modern window managers on
5378 many platforms implement some sort of focus stealing
5379 prevention logic, so that it may be impossible to activate
5380 a window without the help of the currently active
5381 application. In this case, this method will return a non-zero
5382 identifier that represents the top-level window of the VM
5383 console process. The caller, if it represents a currently
5384 active process, is responsible to use this identifier (in a
5385 platform-dependent manner) to perform actual window
5386 activation.
5387 <note>
5388 This method will fail if a session for this machine is not
5389 currently open.
5390 </note>
5391
5392 <result name="VBOX_E_INVALID_VM_STATE">
5393 Machine session is not open.
5394 </result>
5395
5396 </desc>
5397 <param name="winId" type="unsigned long long" dir="return">
5398 <desc>
5399 Platform-dependent identifier of the top-level VM console
5400 window, or zero if this method has performed all actions
5401 necessary to implement the <i>show window</i> semantics for
5402 the given platform and/or VirtualBox front-end.
5403 </desc>
5404 </param>
5405 </method>
5406
5407 <method name="getGuestProperty">
5408 <desc>
5409 Reads an entry from the machine's guest property store.
5410
5411 <result name="VBOX_E_INVALID_VM_STATE">
5412 Machine session is not open.
5413 </result>
5414
5415 </desc>
5416 <param name="name" type="wstring" dir="in">
5417 <desc>
5418 The name of the property to read.
5419 </desc>
5420 </param>
5421 <param name="value" type="wstring" dir="out">
5422 <desc>
5423 The value of the property. If the property does not exist then this
5424 will be empty.
5425 </desc>
5426 </param>
5427 <param name="timestamp" type="unsigned long long" dir="out">
5428 <desc>
5429 The time at which the property was last modified, as seen by the
5430 server process.
5431 </desc>
5432 </param>
5433 <param name="flags" type="wstring" dir="out">
5434 <desc>
5435 Additional property parameters, passed as a comma-separated list of
5436 "name=value" type entries.
5437 </desc>
5438 </param>
5439 </method>
5440
5441 <method name="getGuestPropertyValue">
5442 <desc>
5443 Reads a value from the machine's guest property store.
5444
5445 <result name="VBOX_E_INVALID_VM_STATE">
5446 Machine session is not open.
5447 </result>
5448
5449 </desc>
5450 <param name="property" type="wstring" dir="in">
5451 <desc>
5452 The name of the property to read.
5453 </desc>
5454 </param>
5455 <param name="value" type="wstring" dir="return">
5456 <desc>
5457 The value of the property. If the property does not exist then this
5458 will be empty.
5459 </desc>
5460 </param>
5461 </method>
5462
5463 <method name="getGuestPropertyTimestamp">
5464 <desc>
5465 Reads a property timestamp from the machine's guest property store.
5466
5467 <result name="VBOX_E_INVALID_VM_STATE">
5468 Machine session is not open.
5469 </result>
5470
5471 </desc>
5472 <param name="property" type="wstring" dir="in">
5473 <desc>
5474 The name of the property to read.
5475 </desc>
5476 </param>
5477 <param name="value" type="unsigned long long" dir="return">
5478 <desc>
5479 The timestamp. If the property does not exist then this will be
5480 empty.
5481 </desc>
5482 </param>
5483 </method>
5484
5485 <method name="setGuestProperty">
5486 <desc>
5487 Sets, changes or deletes an entry in the machine's guest property
5488 store.
5489
5490 <result name="E_ACCESSDENIED">
5491 Property cannot be changed.
5492 </result>
5493 <result name="E_INVALIDARG">
5494 Invalid @a flags.
5495 </result>
5496 <result name="VBOX_E_INVALID_VM_STATE">
5497 Virtual machine is not mutable or session not open.
5498 </result>
5499 <result name="VBOX_E_INVALID_OBJECT_STATE">
5500 Cannot set transient property when machine not running.
5501 </result>
5502
5503 </desc>
5504 <param name="property" type="wstring" dir="in">
5505 <desc>
5506 The name of the property to set, change or delete.
5507 </desc>
5508 </param>
5509 <param name="value" type="wstring" dir="in">
5510 <desc>
5511 The new value of the property to set, change or delete. If the
5512 property does not yet exist and value is non-empty, it will be
5513 created. If the value is empty, the key will be deleted if it
5514 exists.
5515 </desc>
5516 </param>
5517 <param name="flags" type="wstring" dir="in">
5518 <desc>
5519 Additional property parameters, passed as a comma-separated list of
5520 "name=value" type entries.
5521 </desc>
5522 </param>
5523 </method>
5524
5525 <method name="setGuestPropertyValue">
5526 <desc>
5527 Sets, changes or deletes a value in the machine's guest property
5528 store. The flags field will be left unchanged or created empty for a
5529 new property.
5530
5531 <result name="E_ACCESSDENIED">
5532 Property cannot be changed.
5533 </result>
5534 <result name="VBOX_E_INVALID_VM_STATE">
5535 Virtual machine is not mutable or session not open.
5536 </result>
5537 <result name="VBOX_E_INVALID_OBJECT_STATE">
5538 Cannot set transient property when machine not running.
5539 </result>
5540 </desc>
5541
5542 <param name="property" type="wstring" dir="in">
5543 <desc>
5544 The name of the property to set, change or delete.
5545 </desc>
5546 </param>
5547 <param name="value" type="wstring" dir="in">
5548 <desc>
5549 The new value of the property to set, change or delete. If the
5550 property does not yet exist and value is non-empty, it will be
5551 created. If value is empty, the property will be deleted if it
5552 exists.
5553 </desc>
5554 </param>
5555 </method>
5556
5557 <method name="enumerateGuestProperties">
5558 <desc>
5559 Return a list of the guest properties matching a set of patterns along
5560 with their values, time stamps and flags.
5561 </desc>
5562 <param name="patterns" type="wstring" dir="in">
5563 <desc>
5564 The patterns to match the properties against, separated by '|'
5565 characters. If this is empty or NULL, all properties will match.
5566 </desc>
5567 </param>
5568 <param name="name" type="wstring" dir="out" safearray="yes">
5569 <desc>
5570 The names of the properties returned.
5571 </desc>
5572 </param>
5573 <param name="value" type="wstring" dir="out" safearray="yes">
5574 <desc>
5575 The values of the properties returned. The array entries match the
5576 corresponding entries in the @a name array.
5577 </desc>
5578 </param>
5579 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
5580 <desc>
5581 The time stamps of the properties returned. The array entries match
5582 the corresponding entries in the @a name array.
5583 </desc>
5584 </param>
5585 <param name="flags" type="wstring" dir="out" safearray="yes">
5586 <desc>
5587 The flags of the properties returned. The array entries match the
5588 corresponding entries in the @a name array.
5589 </desc>
5590 </param>
5591 </method>
5592</interface>
5593
5594 <!--
5595 // IConsole
5596 /////////////////////////////////////////////////////////////////////////
5597 -->
5598
5599 <interface
5600 name="IConsoleCallback" extends="$unknown"
5601 uuid="13dfbef3-b74d-487d-bada-2304529aefa6"
5602 wsmap="suppress"
5603 >
5604
5605 <desc>
5606 This interface is used by a client of the Main API that need to
5607 be notified of events. For example, a graphical user interface
5608 can use this to learn about machine state changes so they can
5609 update the list of virtual machines without having to rely
5610 on polling.
5611
5612 Whenever relevant events occur in VirtualBox, the callbacks in
5613 objects of this interface are called. In order for this to be
5614 useful, a client needs to create its own subclass that implements
5615 this interface in which the methods for the relevant callbacks
5616 are overridden. An instance of this subclass interface can then
5617 be passed to <link to="IConsole::registerCallback" />.
5618 </desc>
5619
5620 <method name="onMousePointerShapeChange">
5621 <desc>
5622 Notification when the guest mouse pointer shape has
5623 changed. The new shape data is given.
5624 </desc>
5625 <param name="visible" type="boolean" dir="in">
5626 <desc>
5627 Flag whether the pointer is visible.
5628 </desc>
5629 </param>
5630 <param name="alpha" type="boolean" dir="in">
5631 <desc>
5632 Flag whether the pointer has an alpha channel.
5633 </desc>
5634 </param>
5635 <param name="xHot" type="unsigned long" dir="in">
5636 <desc>
5637 The pointer hot spot x coordinate.
5638 </desc>
5639 </param>
5640 <param name="yHot" type="unsigned long" dir="in">
5641 <desc>
5642 The pointer hot spot y coordinate.
5643 </desc>
5644 </param>
5645 <param name="width" type="unsigned long" dir="in">
5646 <desc>
5647 Width of the pointer shape in pixels.
5648 </desc>
5649 </param>
5650 <param name="height" type="unsigned long" dir="in">
5651 <desc>
5652 Height of the pointer shape in pixels.
5653 </desc>
5654 </param>
5655 <param name="shape" type="octet" mod="ptr" dir="in">
5656 <desc>
5657 Address of the shape buffer.
5658
5659 The @a shape buffer contains a 1-bpp (bits per pixel) AND mask
5660 followed by a 32-bpp XOR (color) mask.
5661
5662 For pointers without alpha channel the XOR mask pixels are 32
5663 bit values: (lsb)BGR0(msb). For pointers with alpha channel
5664 the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
5665
5666 An AND mask is used for pointers with alpha channel, so if the
5667 callback does not support alpha, the pointer could be
5668 displayed as a normal color pointer.
5669
5670 The AND mask is a 1-bpp bitmap with byte aligned scanlines. The
5671 size of the AND mask therefore is <tt>cbAnd = (width + 7) / 8 *
5672 height</tt>. The padding bits at the end of each scanline are
5673 undefined.
5674
5675 The XOR mask follows the AND mask on the next 4-byte aligned
5676 offset: <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>.
5677 Bytes in the gap between the AND and the XOR mask are undefined.
5678 The XOR mask scanlines have no gap between them and the size of
5679 the XOR mask is: <tt>cXor = width * 4 * height</tt>.
5680
5681 <note>
5682 If @a shape is 0, only the pointer visibility is changed.
5683 </note>
5684 </desc>
5685 </param>
5686 </method>
5687
5688 <method name="onMouseCapabilityChange">
5689 <desc>
5690 Notification when the mouse capabilities reported by the
5691 guest have changed. The new capabilities are passed.
5692 </desc>
5693 <param name="supportsAbsolute" type="boolean" dir="in"/>
5694 <param name="needsHostCursor" type="boolean" dir="in"/>
5695 </method>
5696
5697 <method name="onKeyboardLedsChange">
5698 <desc>
5699 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
5700 to alter the state of the keyboard LEDs.
5701 </desc>
5702 <param name="numLock" type="boolean" dir="in"/>
5703 <param name="capsLock" type="boolean" dir="in"/>
5704 <param name="scrollLock" type="boolean" dir="in"/>
5705 </method>
5706
5707 <method name="onStateChange">
5708 <desc>
5709 Notification when the execution state of the machine has changed.
5710 The new state will be given.
5711 </desc>
5712 <param name="state" type="MachineState" dir="in"/>
5713 </method>
5714
5715 <method name="onAdditionsStateChange">
5716 <desc>
5717 Notification when a Guest Additions property changes.
5718 Interested callees should query IGuest attributes to
5719 find out what has changed.
5720 </desc>
5721 </method>
5722
5723 <method name="onDVDDriveChange">
5724 <desc>
5725 Notification when a property of the
5726 virtual <link to="IMachine::DVDDrive">DVD drive</link> changes.
5727 Interested callees should use IDVDDrive methods to find out what has
5728 changed.
5729 </desc>
5730 </method>
5731
5732 <method name="onFloppyDriveChange">
5733 <desc>
5734 Notification when a property of the
5735 virtual <link to="IMachine::floppyDrive">floppy drive</link> changes.
5736 Interested callees should use IFloppyDrive methods to find out what
5737 has changed.
5738 </desc>
5739 </method>
5740
5741 <method name="onNetworkAdapterChange">
5742 <desc>
5743 Notification when a property of one of the
5744 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
5745 changes. Interested callees should use INetworkAdapter methods and
5746 attributes to find out what has changed.
5747 </desc>
5748 <param name="networkAdapter" type="INetworkAdapter" dir="in">
5749 <desc>Network adapter that is subject to change.</desc>
5750 </param>
5751 </method>
5752
5753 <method name="onSerialPortChange">
5754 <desc>
5755 Notification when a property of one of the
5756 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
5757 Interested callees should use ISerialPort methods and attributes
5758 to find out what has changed.
5759 </desc>
5760 <param name="serialPort" type="ISerialPort" dir="in">
5761 <desc>Serial port that is subject to change.</desc>
5762 </param>
5763 </method>
5764
5765 <method name="onParallelPortChange">
5766 <desc>
5767 Notification when a property of one of the
5768 virtual <link to="IMachine::getParallelPort">parallel ports</link>
5769 changes. Interested callees should use ISerialPort methods and
5770 attributes to find out what has changed.
5771 </desc>
5772 <param name="parallelPort" type="IParallelPort" dir="in">
5773 <desc>Parallel port that is subject to change.</desc>
5774 </param>
5775 </method>
5776
5777 <method name="onStorageControllerChange">
5778 <desc>
5779 Notification when a property of one of the
5780 virtual <link to="IMachine::storageControllers">storage controllers</link>
5781 changes. Interested callees should query the corresponding collections
5782 to find out what has changed.
5783 </desc>
5784 </method>
5785
5786 <method name="onVRDPServerChange">
5787 <desc>
5788 Notification when a property of the
5789 <link to="IMachine::VRDPServer">VRDP server</link> changes.
5790 Interested callees should use IVRDPServer methods and attributes to
5791 find out what has changed.
5792 </desc>
5793 </method>
5794
5795 <method name="onUSBControllerChange">
5796 <desc>
5797 Notification when a property of the virtual
5798 <link to="IMachine::USBController">USB controller</link> changes.
5799 Interested callees should use IUSBController methods and attributes to
5800 find out what has changed.
5801 </desc>
5802 </method>
5803
5804 <method name="onUSBDeviceStateChange">
5805 <desc>
5806 Notification when a USB device is attached to or detached from
5807 the virtual USB controller.
5808
5809 This notification is sent as a result of the indirect
5810 request to attach the device because it matches one of the
5811 machine USB filters, or as a result of the direct request
5812 issued by <link to="IConsole::attachUSBDevice"/> or
5813 <link to="IConsole::detachUSBDevice"/>.
5814
5815 This notification is sent in case of both a succeeded and a
5816 failed request completion. When the request succeeds, the
5817 @a error parameter is @c null, and the given device has been
5818 already added to (when @a attached is @c true) or removed from
5819 (when @a attached is @c false) the collection represented by
5820 <link to="IConsole::USBDevices"/>. On failure, the collection
5821 doesn't change and the @a error parameter represents the error
5822 message describing the failure.
5823
5824 </desc>
5825 <param name="device" type="IUSBDevice" dir="in">
5826 <desc>Device that is subject to state change.</desc>
5827 </param>
5828 <param name="attached" type="boolean" dir="in">
5829 <desc>
5830 <tt>true</tt> if the device was attached
5831 and <tt>false</tt> otherwise.
5832 </desc>
5833 </param>
5834 <param name="error" type="IVirtualBoxErrorInfo" dir="in">
5835 <desc>
5836 <tt>null</tt> on success or an error message object on
5837 failure.
5838 </desc>
5839 </param>
5840 </method>
5841
5842 <method name="onSharedFolderChange">
5843 <desc>
5844 Notification when a shared folder is added or removed.
5845 The @a scope argument defines one of three scopes:
5846 <link to="IVirtualBox::sharedFolders">global shared folders</link>
5847 (<link to="Scope_Global">Global</link>),
5848 <link to="IMachine::sharedFolders">permanent shared folders</link> of
5849 the machine (<link to="Scope_Machine">Machine</link>) or <link
5850 to="IConsole::sharedFolders">transient shared folders</link> of the
5851 machine (<link to="Scope_Session">Session</link>). Interested callees
5852 should use query the corresponding collections to find out what has
5853 changed.
5854 </desc>
5855 <param name="scope" type="Scope" dir="in">
5856 <desc>Scope of the notification.</desc>
5857 </param>
5858 </method>
5859
5860 <method name="onRuntimeError">
5861 <desc>
5862 Notification when an error happens during the virtual
5863 machine execution.
5864
5865 There are three kinds of runtime errors:
5866 <ul>
5867 <li><i>fatal</i></li>
5868 <li><i>non-fatal with retry</i></li>
5869 <li><i>non-fatal warnings</i></li>
5870 </ul>
5871
5872 <b>Fatal</b> errors are indicated by the @a fatal parameter set
5873 to <tt>true</tt>. In case of fatal errors, the virtual machine
5874 execution is always paused before calling this notification, and
5875 the notification handler is supposed either to immediately save
5876 the virtual machine state using <link to="IConsole::saveState"/>
5877 or power it off using <link to="IConsole::powerDown"/>.
5878 Resuming the execution can lead to unpredictable results.
5879
5880 <b>Non-fatal</b> errors and warnings are indicated by the
5881 @a fatal parameter set to <tt>false</tt>. If the virtual machine
5882 is in the Paused state by the time the error notification is
5883 received, it means that the user can <i>try to resume</i> the machine
5884 execution after attempting to solve the problem that caused the
5885 error. In this case, the notification handler is supposed
5886 to show an appropriate message to the user (depending on the
5887 value of the @a id parameter) that offers several actions such
5888 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
5889 wants to retry, the notification handler should continue
5890 the machine execution using the <link to="IConsole::resume"/>
5891 call. If the machine execution is not Paused during this
5892 notification, then it means this notification is a <i>warning</i>
5893 (for example, about a fatal condition that can happen very soon);
5894 no immediate action is required from the user, the machine
5895 continues its normal execution.
5896
5897 Note that in either case the notification handler
5898 <b>must not</b> perform any action directly on a thread
5899 where this notification is called. Everything it is allowed to
5900 do is to post a message to another thread that will then talk
5901 to the user and take the corresponding action.
5902
5903 Currently, the following error identifiers are known:
5904 <ul>
5905 <li><tt>"HostMemoryLow"</tt></li>
5906 <li><tt>"HostAudioNotResponding"</tt></li>
5907 <li><tt>"VDIStorageFull"</tt></li>
5908 </ul>
5909
5910 <note>
5911 This notification is not designed to be implemented by
5912 more than one callback at a time. If you have multiple
5913 IConsoleCallback instances registered on the given
5914 IConsole object, make sure you simply do nothing but
5915 return @c S_OK from all but one of them that does actual
5916 user notification and performs necessary actions.
5917 </note>
5918
5919 </desc>
5920 <param name="fatal" type="boolean" dir="in">
5921 <desc>Whether the error is fatal or not</desc>
5922 </param>
5923 <param name="id" type="wstring" dir="in">
5924 <desc>Error identifier</desc>
5925 </param>
5926 <param name="message" type="wstring" dir="in">
5927 <desc>Optional error message</desc>
5928 </param>
5929 </method>
5930
5931 <method name="onCanShowWindow">
5932 <desc>
5933 Notification when a call to
5934 <link to="IMachine::canShowConsoleWindow"/> is made by a
5935 front-end to check if a subsequent call to
5936 <link to="IMachine::showConsoleWindow"/> can succeed.
5937
5938 The callee should give an answer appropriate to the current
5939 machine state in the @a canShow argument. This answer must
5940 remain valid at least until the next
5941 <link to="IConsole::state">machine state</link> change.
5942
5943 <note>
5944 This notification is not designed to be implemented by
5945 more than one callback at a time. If you have multiple
5946 IConsoleCallback instances registered on the given
5947 IConsole object, make sure you simply do nothing but
5948 return @c true and @c S_OK from all but one of them that
5949 actually manages console window activation.
5950 </note>
5951 </desc>
5952 <param name="canShow" type="boolean" dir="return">
5953 <desc>
5954 @c true if the console window can be shown and @c
5955 false otherwise.
5956 </desc>
5957 </param>
5958 </method>
5959
5960 <method name="onShowWindow">
5961 <desc>
5962 Notification when a call to
5963 <link to="IMachine::showConsoleWindow"/>
5964 requests the console window to be activated and brought to
5965 foreground on the desktop of the host PC.
5966
5967 This notification should cause the VM console process to
5968 perform the requested action as described above. If it is
5969 impossible to do it at a time of this notification, this
5970 method should return a failure.
5971
5972 Note that many modern window managers on many platforms
5973 implement some sort of focus stealing prevention logic, so
5974 that it may be impossible to activate a window without the
5975 help of the currently active application (which is supposedly
5976 an initiator of this notification). In this case, this method
5977 must return a non-zero identifier that represents the
5978 top-level window of the VM console process. The caller, if it
5979 represents a currently active process, is responsible to use
5980 this identifier (in a platform-dependent manner) to perform
5981 actual window activation.
5982
5983 This method must set @a winId to zero if it has performed all
5984 actions necessary to complete the request and the console
5985 window is now active and in foreground, to indicate that no
5986 further action is required on the caller's side.
5987
5988 <note>
5989 This notification is not designed to be implemented by
5990 more than one callback at a time. If you have multiple
5991 IConsoleCallback instances registered on the given
5992 IConsole object, make sure you simply do nothing but
5993 return @c S_OK from all but one of them that actually
5994 manages console window activation.
5995 </note>
5996 </desc>
5997 <param name="winId" type="unsigned long long" dir="return">
5998 <desc>
5999 Platform-dependent identifier of the top-level VM console
6000 window, or zero if this method has performed all actions
6001 necessary to implement the <i>show window</i> semantics for
6002 the given platform and/or this VirtualBox front-end.
6003 </desc>
6004 </param>
6005 </method>
6006
6007 </interface>
6008
6009 <interface
6010 name="IRemoteDisplayInfo" extends="$unknown"
6011 uuid="550104cd-2dfd-4a6c-857d-f6f8e088e62c"
6012 wsmap="struct"
6013 >
6014 <desc>
6015 Contains information about the remote display (VRDP) capabilities and status.
6016 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
6017 </desc>
6018
6019 <attribute name="active" type="boolean" readonly="yes">
6020 <desc>
6021 Whether the remote display connection is active.
6022 </desc>
6023 </attribute>
6024
6025 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
6026 <desc>
6027 How many times a client connected.
6028 </desc>
6029 </attribute>
6030
6031 <attribute name="beginTime" type="long long" readonly="yes">
6032 <desc>
6033 When the last connection was established, in milliseconds since 1970-01-01 UTC.
6034 </desc>
6035 </attribute>
6036
6037 <attribute name="endTime" type="long long" readonly="yes">
6038 <desc>
6039 When the last connection was terminated or the current time, if
6040 connection is still active, in milliseconds since 1970-01-01 UTC.
6041 </desc>
6042 </attribute>
6043
6044 <attribute name="bytesSent" type="unsigned long long" readonly="yes">
6045 <desc>
6046 How many bytes were sent in last or current, if still active, connection.
6047 </desc>
6048 </attribute>
6049
6050 <attribute name="bytesSentTotal" type="unsigned long long" readonly="yes">
6051 <desc>
6052 How many bytes were sent in all connections.
6053 </desc>
6054 </attribute>
6055
6056 <attribute name="bytesReceived" type="unsigned long long" readonly="yes">
6057 <desc>
6058 How many bytes were received in last or current, if still active, connection.
6059 </desc>
6060 </attribute>
6061
6062 <attribute name="bytesReceivedTotal" type="unsigned long long" readonly="yes">
6063 <desc>
6064 How many bytes were received in all connections.
6065 </desc>
6066 </attribute>
6067
6068 <attribute name="user" type="wstring" readonly="yes">
6069 <desc>
6070 Login user name supplied by the client.
6071 </desc>
6072 </attribute>
6073
6074 <attribute name="domain" type="wstring" readonly="yes">
6075 <desc>
6076 Login domain name supplied by the client.
6077 </desc>
6078 </attribute>
6079
6080 <attribute name="clientName" type="wstring" readonly="yes">
6081 <desc>
6082 The client name supplied by the client.
6083 </desc>
6084 </attribute>
6085
6086 <attribute name="clientIP" type="wstring" readonly="yes">
6087 <desc>
6088 The IP address of the client.
6089 </desc>
6090 </attribute>
6091
6092 <attribute name="clientVersion" type="unsigned long" readonly="yes">
6093 <desc>
6094 The client software version number.
6095 </desc>
6096 </attribute>
6097
6098 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
6099 <desc>
6100 Public key exchange method used when connection was established.
6101 Values: 0 - RDP4 public key exchange scheme.
6102 1 - X509 certificates were sent to client.
6103 </desc>
6104 </attribute>
6105
6106 </interface>
6107
6108 <interface
6109 name="IConsole" extends="$unknown"
6110 uuid="a7f17a42-5b64-488d-977b-4b2c639ada27"
6111 wsmap="managed"
6112 >
6113 <desc>
6114 The IConsole interface represents an interface to control virtual
6115 machine execution.
6116
6117 The console object that implements the IConsole interface is obtained
6118 from a session object after the session for the given machine has been
6119 opened using one of <link to="IVirtualBox::openSession"/>,
6120 <link to="IVirtualBox::openRemoteSession"/> or
6121 <link to="IVirtualBox::openExistingSession"/> methods.
6122
6123 Methods of the IConsole interface allow the caller to query the current
6124 virtual machine execution state, pause the machine or power it down, save
6125 the machine state or take a snapshot, attach and detach removable media
6126 and so on.
6127
6128 <see>ISession</see>
6129 </desc>
6130
6131 <attribute name="machine" type="IMachine" readonly="yes">
6132 <desc>
6133 Machine object this console is sessioned with.
6134 <note>
6135 This is a convenience property, it has the same value as
6136 <link to="ISession::machine"/> of the corresponding session
6137 object.
6138 </note>
6139 </desc>
6140 </attribute>
6141
6142 <attribute name="state" type="MachineState" readonly="yes">
6143 <desc>
6144 Current execution state of the machine.
6145 <note>
6146 This property always returns the same value as the corresponding
6147 property of the IMachine object this console is sessioned with.
6148 For the process that owns (executes) the VM, this is the
6149 preferable way of querying the VM state, because no IPC
6150 calls are made.
6151 </note>
6152 </desc>
6153 </attribute>
6154
6155 <attribute name="guest" type="IGuest" readonly="yes">
6156 <desc>Guest object.</desc>
6157 </attribute>
6158
6159 <attribute name="keyboard" type="IKeyboard" readonly="yes">
6160 <desc>
6161 Virtual keyboard object.
6162 <note>
6163 If the machine is not running, any attempt to use
6164 the returned object will result in an error.
6165 </note>
6166 </desc>
6167 </attribute>
6168
6169 <attribute name="mouse" type="IMouse" readonly="yes">
6170 <desc>
6171 Virtual mouse object.
6172 <note>
6173 If the machine is not running, any attempt to use
6174 the returned object will result in an error.
6175 </note>
6176 </desc>
6177 </attribute>
6178
6179 <attribute name="display" type="IDisplay" readonly="yes">
6180 <desc>Virtual display object.
6181 <note>
6182 If the machine is not running, any attempt to use
6183 the returned object will result in an error.
6184 </note>
6185 </desc>
6186 </attribute>
6187
6188 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
6189 <desc>Debugging interface.</desc>
6190 </attribute>
6191
6192 <attribute name="USBDevices" type="IUSBDevice" readonly="yes" safearray="yes">
6193 <desc>
6194 Collection of USB devices currently attached to the virtual
6195 USB controller.
6196 <note>
6197 The collection is empty if the machine is not running.
6198 </note>
6199 </desc>
6200 </attribute>
6201
6202 <attribute name="remoteUSBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
6203 <desc>
6204 List of USB devices currently attached to the remote VRDP client.
6205 Once a new device is physically attached to the remote host computer,
6206 it appears in this list and remains there until detached.
6207 </desc>
6208 </attribute>
6209
6210 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
6211 <desc>
6212 Collection of shared folders for the current session. These folders
6213 are called transient shared folders because they are available to the
6214 guest OS running inside the associated virtual machine only for the
6215 duration of the session (as opposed to
6216 <link to="IMachine::sharedFolders"/> which represent permanent shared
6217 folders). When the session is closed (e.g. the machine is powered down),
6218 these folders are automatically discarded.
6219
6220 New shared folders are added to the collection using
6221 <link to="#createSharedFolder"/>. Existing shared folders can be
6222 removed using <link to="#removeSharedFolder"/>.
6223 </desc>
6224 </attribute>
6225
6226 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
6227 <desc>
6228 Interface that provides information on Remote Display (VRDP) connection.
6229 </desc>
6230 </attribute>
6231
6232 <method name="powerUp">
6233 <desc>
6234 Starts the virtual machine execution using the current machine
6235 state (that is, its current execution state, current settings and
6236 current hard disks).
6237
6238 If the machine is powered off or aborted, the execution will
6239 start from the beginning (as if the real hardware were just
6240 powered on).
6241
6242 If the machine is in the <link to="MachineState_Saved"/> state,
6243 it will continue its execution the point where the state has
6244 been saved.
6245
6246 <note>
6247 Unless you are trying to write a new VirtualBox front-end that
6248 performs direct machine execution (like the VirtualBox or VBoxSDL
6249 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
6250 session opened by <link to="IVirtualBox::openSession"/> and use this
6251 session only to change virtual machine settings. If you simply want to
6252 start virtual machine execution using one of the existing front-ends
6253 (for example the VirtualBox GUI or headless server), simply use
6254 <link to="IVirtualBox::openRemoteSession"/>; these front-ends will
6255 power up the machine automatically for you.
6256 </note>
6257
6258 <see>#saveState</see>
6259 <result name="VBOX_E_INVALID_VM_STATE">
6260 Virtual machine already running.
6261 </result>
6262 <result name="VBOX_E_HOST_ERROR">
6263 Host interface does not exist or name not set.
6264 </result>
6265 <result name="VBOX_E_FILE_ERROR">
6266 Invalid saved state file.
6267 </result>
6268 </desc>
6269 <param name="progress" type="IProgress" dir="return">
6270 <desc>Progress object to track the operation completion.</desc>
6271 </param>
6272 </method>
6273
6274 <method name="powerUpPaused">
6275 <desc>
6276 Identical to powerUp except that the VM will enter the
6277 <link to="MachineState_Paused"/> state, instead of
6278 <link to="MachineState_Running"/>.
6279
6280 <see>#powerUp</see>
6281 <result name="VBOX_E_INVALID_VM_STATE">
6282 Virtual machine already running.
6283 </result>
6284 <result name="VBOX_E_HOST_ERROR">
6285 Host interface does not exist or name not set.
6286 </result>
6287 <result name="VBOX_E_FILE_ERROR">
6288 Invalid saved state file.
6289 </result>
6290 </desc>
6291 <param name="progress" type="IProgress" dir="return">
6292 <desc>Progress object to track the operation completion.</desc>
6293 </param>
6294 </method>
6295
6296 <method name="powerDown">
6297 <desc>
6298 Stops the virtual machine execution.
6299 After this operation completes, the machine will go to the
6300 PoweredOff state.
6301
6302 @deprecated This method will be removed in VirtualBox 2.1 where the
6303 powerDownAsync() method will take its name. Do not use this method in
6304 the code.
6305 <result name="VBOX_E_INVALID_VM_STATE">
6306 Virtual machine must be Running, Paused or Stuck to be powered down.
6307 </result>
6308 <result name="VBOX_E_VM_ERROR">
6309 Unable to power off or destroy virtual machine.
6310 </result>
6311 </desc>
6312 </method>
6313
6314 <method name="powerDownAsync">
6315 <desc>
6316 Initiates the power down procedure to stop the virtual machine
6317 execution.
6318
6319 The completion of the power down procedure is tracked using the returned
6320 IProgress object. After the operation is complete, the machine will go
6321 to the PoweredOff state.
6322
6323 @warning This method will be renamed to "powerDown" in VirtualBox 2.1
6324 where the original powerDown() method will be removed. You will need to
6325 rename "powerDownAsync" to "powerDown" in your sources to make them
6326 build with version 2.1.
6327 <result name="VBOX_E_INVALID_VM_STATE">
6328 Virtual machine must be Running, Paused or Stuck to be powered down.
6329 </result>
6330 </desc>
6331 <param name="progress" type="IProgress" dir="return">
6332 <desc>Progress object to track the operation completion.</desc>
6333 </param>
6334 </method>
6335
6336 <method name="reset">
6337 <desc>Resets the virtual machine.
6338 <result name="VBOX_E_INVALID_VM_STATE">
6339 Virtual machine not in Running state.
6340 </result>
6341 <result name="VBOX_E_VM_ERROR">
6342 Virtual machine error in reset operation.
6343 </result>
6344 </desc>
6345 </method>
6346
6347 <method name="pause">
6348 <desc>Pauses the virtual machine execution.
6349 <result name="VBOX_E_INVALID_VM_STATE">
6350 Virtual machine not in Running state.
6351 </result>
6352 <result name="VBOX_E_VM_ERROR">
6353 Virtual machine error in suspend operation.
6354 </result>
6355 </desc>
6356 </method>
6357
6358 <method name="resume">
6359 <desc>Resumes the virtual machine execution.
6360 <result name="VBOX_E_INVALID_VM_STATE">
6361 Virtual machine not in Paused state.
6362 </result>
6363 <result name="VBOX_E_VM_ERROR">
6364 Virtual machine error in resume operation.
6365 </result>
6366 </desc>
6367 </method>
6368
6369 <method name="powerButton">
6370 <desc>Sends the ACPI power button event to the guest.
6371 <result name="VBOX_E_INVALID_VM_STATE">
6372 Virtual machine not in Running state.
6373 </result>
6374 <result name="VBOX_E_PDM_ERROR">
6375 Controlled power off failed.
6376 </result>
6377 </desc>
6378 </method>
6379
6380 <method name="sleepButton">
6381 <desc>Sends the ACPI sleep button event to the guest.
6382 <result name="VBOX_E_INVALID_VM_STATE">
6383 Virtual machine not in Running state.
6384 </result>
6385 <result name="VBOX_E_PDM_ERROR">
6386 Sending sleep button event failed.
6387 </result>
6388 </desc>
6389 </method>
6390
6391 <method name="getPowerButtonHandled">
6392 <desc>Checks if the last power button event was handled by guest.
6393 <result name="VBOX_E_PDM_ERROR">
6394 Checking if the event was handled by the guest OS failed.
6395 </result>
6396 </desc>
6397 <param name="handled" type="boolean" dir="return"/>
6398 </method>
6399
6400 <method name="getGuestEnteredACPIMode">
6401 <desc>Checks if the guest entered the ACPI mode G0 (working) or
6402 G1 (sleeping). If this method returns false, the guest will
6403 most likely not respond to external ACPI events.
6404 <result name="VBOX_E_INVALID_VM_STATE">
6405 Virtual machine not in Running state.
6406 </result>
6407 </desc>
6408 <param name="entered" type="boolean" dir="return"/>
6409 </method>
6410
6411 <method name="saveState">
6412 <desc>
6413 Saves the current execution state of a running virtual machine
6414 and stops its execution.
6415
6416 After this operation completes, the machine will go to the
6417 Saved state. Next time it is powered up, this state will
6418 be restored and the machine will continue its execution from
6419 the place where it was saved.
6420
6421 This operation differs from taking a snapshot to the effect
6422 that it doesn't create new differencing hard disks. Also, once
6423 the machine is powered up from the state saved using this method,
6424 the saved state is deleted, so it will be impossible to return
6425 to this state later.
6426
6427 <note>
6428 On success, this method implicitly calls
6429 <link to="IMachine::saveSettings"/> to save all current machine
6430 settings (including runtime changes to the DVD drive, etc.).
6431 Together with the impossibility to change any VM settings when it is
6432 in the Saved state, this guarantees adequate hardware
6433 configuration of the machine when it is restored from the saved
6434 state file.
6435 </note>
6436
6437 <note>
6438 The machine must be in the Running or Paused state, otherwise
6439 the operation will fail.
6440 </note>
6441 <result name="VBOX_E_INVALID_VM_STATE">
6442 Virtual machine state neither Running nor Paused.
6443 </result>
6444 <result name="VBOX_E_FILE_ERROR">
6445 Failed to create directory for saved state file.
6446 </result>
6447
6448 <see><link to="#takeSnapshot"/></see>
6449 </desc>
6450 <param name="progress" type="IProgress" dir="return">
6451 <desc>Progress object to track the operation completion.</desc>
6452 </param>
6453 </method>
6454
6455 <method name="adoptSavedState">
6456 <desc>
6457 Associates the given saved state file to the virtual machine.
6458
6459 On success, the machine will go to the Saved state. Next time it is
6460 powered up, it will be restored from the adopted saved state and
6461 continue execution from the place where the saved state file was
6462 created.
6463
6464 The specified saved state file path may be absolute or relative to the
6465 folder the VM normally saves the state to (usually,
6466 <link to="IMachine::snapshotFolder"/>).
6467
6468 <note>
6469 It's a caller's responsibility to make sure the given saved state
6470 file is compatible with the settings of this virtual machine that
6471 represent its virtual hardware (memory size, hard disk configuration
6472 etc.). If there is a mismatch, the behavior of the virtual machine
6473 is undefined.
6474 </note>
6475 <result name="VBOX_E_INVALID_VM_STATE">
6476 Virtual machine state neither PoweredOff nor Aborted.
6477 </result>
6478 </desc>
6479 <param name="savedStateFile" type="wstring" dir="in">
6480 <desc>Path to the saved state file to adopt.</desc>
6481 </param>
6482 </method>
6483
6484 <method name="discardSavedState">
6485 <desc>
6486 Discards (deletes) the saved state of the virtual machine
6487 previously created by <link to="#saveState"/>. Next time the
6488 machine is powered up, a clean boot will occur.
6489 <note>
6490 This operation is equivalent to resetting or powering off
6491 the machine without doing a proper shutdown in the guest OS.
6492 </note>
6493 <result name="VBOX_E_INVALID_VM_STATE">
6494 Virtual machine not in state Saved.
6495 </result>
6496 </desc>
6497 </method>
6498
6499 <method name="getDeviceActivity">
6500 <desc>
6501 Gets the current activity type of a given device or device group.
6502 <result name="E_INVALIDARG">
6503 Invalid device type.
6504 </result>
6505 </desc>
6506 <param name="type" type="DeviceType" dir="in"/>
6507 <param name="activity" type="DeviceActivity" dir="return"/>
6508 </method>
6509
6510 <method name="attachUSBDevice">
6511 <desc>
6512 Attaches a host USB device with the given UUID to the
6513 USB controller of the virtual machine.
6514
6515 The device needs to be in one of the following states:
6516 <link to="USBDeviceState_Busy"/>,
6517 <link to="USBDeviceState_Available"/> or
6518 <link to="USBDeviceState_Held"/>,
6519 otherwise an error is immediately returned.
6520
6521 When the device state is
6522 <link to="USBDeviceState_Busy">Busy</link>, an error may also
6523 be returned if the host computer refuses to release it for some reason.
6524
6525 <see>IUSBController::deviceFilters, USBDeviceState</see>
6526 <result name="VBOX_E_INVALID_VM_STATE">
6527 Virtual machine state neither Running nor Paused.
6528 </result>
6529 <result name="VBOX_E_PDM_ERROR">
6530 Virtual machine does not have a USB controller.
6531 </result>
6532 </desc>
6533 <param name="id" type="wstring" dir="in">
6534 <desc>UUID of the host USB device to attach.</desc>
6535 </param>
6536 </method>
6537
6538 <method name="detachUSBDevice">
6539 <desc>
6540 Detaches an USB device with the given UUID from the USB controller
6541 of the virtual machine.
6542
6543 After this method succeeds, the VirtualBox server re-initiates
6544 all USB filters as if the device were just physically attached
6545 to the host, but filters of this machine are ignored to avoid
6546 a possible automatic re-attachment.
6547
6548 <see>IUSBController::deviceFilters, USBDeviceState</see>
6549
6550 <result name="VBOX_E_PDM_ERROR">
6551 Virtual machine does not have a USB controller.
6552 </result>
6553 <result name="E_INVALIDARG">
6554 USB device not attached to this virtual machine.
6555 </result>
6556 </desc>
6557 <param name="id" type="wstring" dir="in">
6558 <desc>UUID of the USB device to detach.</desc>
6559 </param>
6560 <param name="device" type="IUSBDevice" dir="return">
6561 <desc>Detached USB device.</desc>
6562 </param>
6563 </method>
6564
6565 <method name="findUSBDeviceByAddress">
6566 <desc>
6567 Searches for a USB device with the given host address.
6568
6569 <result name="VBOX_E_OBJECT_NOT_FOUND">
6570 Given @c name does not correspond to any USB device.
6571 </result>
6572
6573 <see>IUSBDevice::address</see>
6574 </desc>
6575 <param name="name" type="wstring" dir="in">
6576 <desc>
6577 Address of the USB device (as assigned by the host) to
6578 search for.
6579 </desc>
6580 </param>
6581 <param name="device" type="IUSBDevice" dir="return">
6582 <desc>Found USB device object.</desc>
6583 </param>
6584 </method>
6585
6586 <method name="findUSBDeviceById">
6587 <desc>
6588 Searches for a USB device with the given UUID.
6589
6590 <result name="VBOX_E_OBJECT_NOT_FOUND">
6591 Given @c id does not correspond to any USB device.
6592 </result>
6593
6594 <see>IUSBDevice::id</see>
6595 </desc>
6596 <param name="id" type="wstring" dir="in">
6597 <desc>UUID of the USB device to search for.</desc>
6598 </param>
6599 <param name="device" type="IUSBDevice" dir="return">
6600 <desc>Found USB device object.</desc>
6601 </param>
6602 </method>
6603
6604 <method name="createSharedFolder">
6605 <desc>
6606 Creates a transient new shared folder by associating the given logical
6607 name with the given host path, adds it to the collection of shared
6608 folders and starts sharing it. Refer to the description of
6609 <link to="ISharedFolder"/> to read more about logical names.
6610
6611 <result name="VBOX_E_INVALID_VM_STATE">
6612 Virtual machine in Saved state or currently changing state.
6613 </result>
6614 <result name="VBOX_E_FILE_ERROR">
6615 Shared folder already exists or not accessible.
6616 </result>
6617 </desc>
6618 <param name="name" type="wstring" dir="in">
6619 <desc>Unique logical name of the shared folder.</desc>
6620 </param>
6621 <param name="hostPath" type="wstring" dir="in">
6622 <desc>Full path to the shared folder in the host file system.</desc>
6623 </param>
6624 <param name="writable" type="boolean" dir="in">
6625 <desc>Whether the share is writable or readonly</desc>
6626 </param>
6627 </method>
6628
6629 <method name="removeSharedFolder">
6630 <desc>
6631 Removes a transient shared folder with the given name previously
6632 created by <link to="#createSharedFolder"/> from the collection of
6633 shared folders and stops sharing it.
6634 <result name="VBOX_E_INVALID_VM_STATE">
6635 Virtual machine in Saved state or currently changing state.
6636 </result>
6637 <result name="VBOX_E_FILE_ERROR">
6638 Shared folder does not exists.
6639 </result>
6640 </desc>
6641 <param name="name" type="wstring" dir="in">
6642 <desc>Logical name of the shared folder to remove.</desc>
6643 </param>
6644 </method>
6645
6646 <method name="takeSnapshot">
6647 <desc>
6648 Saves the current execution state and all settings of the
6649 machine and creates differencing images for all
6650 normal (non-independent) hard disks.
6651
6652 This method can be called for a PoweredOff, Saved, Running or
6653 Paused virtual machine. When the machine is PoweredOff, an
6654 offline <link to="ISnapshot">snapshot</link> is created,
6655 in all other cases -- an online snapshot.
6656
6657 The taken snapshot is always based on the
6658 <link to="IMachine::currentSnapshot">current
6659 snapshot</link> of the associated virtual machine and becomes
6660 a new current snapshot.
6661
6662 <note>
6663 This method implicitly calls <link to="IMachine::saveSettings"/> to
6664 save all current machine settings before taking an offline snapshot.
6665 </note>
6666
6667 <see>ISnapshot, <link to="#saveState"/></see>
6668 <result name="VBOX_E_INVALID_VM_STATE">
6669 Virtual machine currently changing state.
6670 </result>
6671 </desc>
6672 <param name="name" type="wstring" dir="in">
6673 <desc>Short name for the snapshot.</desc>
6674 </param>
6675 <param name="description" type="wstring" dir="in">
6676 <desc>Optional description of the snapshot.</desc>
6677 </param>
6678 <param name="progress" type="IProgress" dir="return">
6679 <desc>Progress object to track the operation completion.</desc>
6680 </param>
6681 </method>
6682
6683 <method name="discardSnapshot">
6684 <desc>
6685
6686 Starts discarding the specified snapshot. The execution state
6687 and settings of the associated machine stored in the snapshot
6688 will be deleted. The contents of all differencing hard disks of
6689 this snapshot will be merged with the contents of their
6690 dependent child hard disks to keep the, disks valid (in other
6691 words, all changes represented by hard disks being discarded
6692 will be propagated to their child hard disks). After that, this
6693 snapshot's differencing hard disks will be deleted. The parent
6694 of this snapshot will become a new parent for all its child
6695 snapshots.
6696
6697 If the discarded snapshot is the current one, its parent
6698 snapshot will become a new current snapshot. The current machine
6699 state is not directly affected in this case, except that
6700 currently attached differencing hard disks based on hard disks
6701 of the discarded snapshot will be also merged as described
6702 above.
6703
6704 If the discarded snapshot is the first one (the root snapshot)
6705 and it has exactly one child snapshot, this child snapshot will
6706 become the first snapshot after discarding. If there are no
6707 children at all (i.e. the first snapshot is the only snapshot of
6708 the machine), both the current and the first snapshot of the
6709 machine will be set to null. In all other cases, the first
6710 snapshot cannot be discarded.
6711
6712 You cannot discard the snapshot if it
6713 stores <link to="HardDiskType_Normal">normal</link> (non-differencing)
6714 hard disks that have differencing hard disks based on them. Snapshots of
6715 such kind can be discarded only when every normal hard disk has either
6716 no children at all or exactly one child. In the former case, the normal
6717 hard disk simply becomes unused (i.e. not attached to any VM). In the
6718 latter case, it receives all the changes stored in the child hard disk,
6719 and then it replaces the child hard disk in the configuration of the
6720 corresponding snapshot or machine.
6721
6722 Also, you cannot discard the snapshot if it stores hard disks
6723 (of any type) having differencing child hard disks that belong
6724 to other machines. Such snapshots can be only discarded after
6725 you discard all snapshots of other machines containing "foreign"
6726 child disks, or detach these "foreign" child disks from machines
6727 they are attached to.
6728
6729 One particular example of the snapshot storing normal hard disks
6730 is the first snapshot of a virtual machine that had normal hard
6731 disks attached when taking the snapshot. Be careful when
6732 discarding such snapshots because this implicitly commits
6733 changes (made since the snapshot being discarded has been taken)
6734 to normal hard disks (as described above), which may be not what
6735 you want.
6736
6737 The virtual machine is put to
6738 the <link to="MachineState_Discarding">Discarding</link> state until
6739 the discard operation is completed.
6740
6741 <note>
6742 The machine must not be running, otherwise the operation
6743 will fail.
6744 </note>
6745
6746 <note>
6747 Child hard disks of all normal hard disks of the discarded snapshot
6748 must be accessible (see <link to="IMedium::state"/>) for this
6749 operation to succeed. In particular, this means that all virtual
6750 machines, whose hard disks are directly or indirectly based on the
6751 hard disks of discarded snapshot, must be powered off.
6752 </note>
6753 <note>
6754 Merging hard disk contents can be very time and disk space
6755 consuming, if these disks are big in size and have many
6756 children. However, if the snapshot being discarded is the last
6757 (head) snapshot on the branch, the operation will be rather
6758 quick.
6759 </note>
6760 <note>
6761 Note that discarding the current snapshot
6762 will implicitly call <link to="IMachine::saveSettings"/> to
6763 make all current machine settings permanent.
6764 </note>
6765 <result name="VBOX_E_INVALID_VM_STATE">
6766 Virtual machine is running.
6767 </result>
6768 </desc>
6769 <param name="id" type="wstring" dir="in">
6770 <desc>UUID of the snapshot to discard.</desc>
6771 </param>
6772 <param name="progress" type="IProgress" dir="return">
6773 <desc>Progress object to track the operation completion.</desc>
6774 </param>
6775 </method>
6776
6777 <method name="discardCurrentState">
6778 <desc>
6779 This operation is similar to <link to="IConsole::discardSnapshot"/> but
6780 affects the current machine state. This means that the state stored in
6781 the current snapshot will become a new current state, and all current
6782 settings of the machine and changes stored in differencing hard disks
6783 will be lost.
6784
6785 After this operation is successfully completed, new empty differencing
6786 hard disks are created for all normal hard disks of the machine.
6787
6788 If the current snapshot of the machine is an online snapshot, the
6789 machine will go to the <link to="MachineState_Saved"> saved
6790 state</link>, so that the next time it is powered on, the execution
6791 state will be restored from the current snapshot.
6792
6793 <note>
6794 The machine must not be running, otherwise the operation will fail.
6795 </note>
6796
6797 <note>
6798 If the machine state is <link to="MachineState_Saved">Saved</link>
6799 prior to this operation, the saved state file will be implicitly
6800 discarded (as if <link to="IConsole::discardSavedState"/> were
6801 called).
6802 </note>
6803
6804 <result name="VBOX_E_INVALID_VM_STATE">
6805 Virtual machine is running.
6806 </result>
6807 </desc>
6808 <param name="progress" type="IProgress" dir="return">
6809 <desc>Progress object to track the operation completion.</desc>
6810 </param>
6811 </method>
6812
6813 <method name="discardCurrentSnapshotAndState">
6814 <desc>
6815
6816 This method is equivalent to
6817 doing <link to="IConsole::discardSnapshot">discardSnapshot</link>
6818 (currentSnapshot.id(), progress) followed by
6819 <link to="IConsole::discardCurrentState"/>.
6820
6821 As a result, the machine will be fully restored from the
6822 snapshot preceding the current snapshot, while both the current
6823 snapshot and the current machine state will be discarded.
6824
6825 If the current snapshot is the first snapshot of the machine (i.e. it
6826 has the only snapshot), the current machine state will be
6827 discarded <b>before</b> discarding the snapshot. In other words, the
6828 machine will be restored from its last snapshot, before discarding
6829 it. This differs from performing a single
6830 <link to="IConsole::discardSnapshot"/> call (note that no
6831 <link to="IConsole::discardCurrentState"/> will be possible after it)
6832 to the effect that the latter will preserve the current state instead of
6833 discarding it.
6834
6835 Unless explicitly mentioned otherwise, all remarks and
6836 limitations of the above two methods also apply to this method.
6837
6838 <note>
6839 The machine must not be running, otherwise the operation
6840 will fail.
6841 </note>
6842
6843 <note>
6844 If the machine state is <link to="MachineState_Saved">Saved</link>
6845 prior to this operation, the saved state file will be implicitly
6846 discarded (as if <link to="#discardSavedState"/> were
6847 called).
6848 </note>
6849
6850 <note>
6851 This method is more efficient than calling both of the above
6852 methods separately: it requires less IPC calls and provides
6853 a single progress object.
6854 </note>
6855
6856 <result name="VBOX_E_INVALID_VM_STATE">
6857 Virtual machine is running.
6858 </result>
6859 </desc>
6860 <param name="progress" type="IProgress" dir="return">
6861 <desc>Progress object to track the operation completion.</desc>
6862 </param>
6863 </method>
6864
6865 <method name="registerCallback">
6866 <desc>
6867 Registers a new console callback on this instance. The methods of the
6868 callback interface will be called by this instance when the appropriate
6869 event occurs.
6870 </desc>
6871 <param name="callback" type="IConsoleCallback" dir="in"/>
6872 </method>
6873
6874 <method name="unregisterCallback">
6875 <desc>
6876 Unregisters the console callback previously registered using
6877 <link to="#registerCallback"/>.
6878 <result name="E_INVALIDARG">
6879 Given @a callback handler is not registered.
6880 </result>
6881 </desc>
6882 <param name="callback" type="IConsoleCallback" dir="in"/>
6883 </method>
6884 </interface>
6885
6886 <!--
6887 // IHost
6888 /////////////////////////////////////////////////////////////////////////
6889 -->
6890
6891 <interface
6892 name="IHostDVDDrive" extends="$unknown"
6893 uuid="21f86694-202d-4ce4-8b05-a63ff82dbf4c"
6894 wsmap="managed"
6895 >
6896 <desc>
6897 The IHostDVDDrive interface represents the physical CD/DVD drive
6898 hardware on the host. Used indirectly in <link to="IHost::DVDDrives"/>.
6899 </desc>
6900
6901 <attribute name="name" type="wstring" readonly="yes">
6902 <desc>
6903 Returns the platform-specific device identifier.
6904 On DOS-like platforms, it is a drive name (e.g. R:).
6905 On Unix-like platforms, it is a device name (e.g. /dev/hdc).
6906 </desc>
6907 </attribute>
6908 <attribute name="description" type="wstring" readonly="yes">
6909 <desc>
6910 Returns a human readable description for the drive. This
6911 description usually contains the product and vendor name. A
6912 @c null string is returned if the description is not available.
6913 </desc>
6914 </attribute>
6915 <attribute name="udi" type="wstring" readonly="yes">
6916 <desc>
6917 Returns the unique device identifier for the drive. This
6918 attribute is reserved for future use instead of
6919 <link to="#name"/>. Currently it is not used and may return
6920 @c null on some platforms.
6921 </desc>
6922 </attribute>
6923
6924 </interface>
6925
6926 <interface
6927 name="IHostFloppyDrive" extends="$unknown"
6928 uuid="3f02d604-e908-4919-9fd1-8a4afd68fc63"
6929 wsmap="managed"
6930 >
6931 <desc>
6932 The IHostFloppyDrive interface represents the physical floppy drive
6933 hardware on the host. Used indirectly in <link to="IHost::floppyDrives"/>.
6934 </desc>
6935 <attribute name="name" type="wstring" readonly="yes">
6936 <desc>
6937 Returns the platform-specific device identifier.
6938 On DOS-like platforms, it is a drive name (e.g. A:).
6939 On Unix-like platforms, it is a device name (e.g. /dev/fd0).
6940 </desc>
6941 </attribute>
6942 <attribute name="description" type="wstring" readonly="yes">
6943 <desc>
6944 Returns a human readable description for the drive. This
6945 description usually contains the product and vendor name. A
6946 @c null string is returned if the description is not available.
6947 </desc>
6948 </attribute>
6949 <attribute name="udi" type="wstring" readonly="yes">
6950 <desc>
6951 Returns the unique device identifier for the drive. This
6952 attribute is reserved for future use instead of
6953 <link to="#name"/>. Currently it is not used and may return
6954 @c null on some platforms.
6955 </desc>
6956 </attribute>
6957 </interface>
6958
6959 <enum
6960 name="HostNetworkInterfaceMediumType"
6961 uuid="1aa54aaf-2497-45a2-bfb1-8eb225e93d5b"
6962 >
6963 <desc>
6964 Type of encapsulation. Ethernet encapsulation includes both wired and
6965 wireless Ethernet connections.
6966 <see>IHostNetworkInterface</see>
6967 </desc>
6968
6969 <const name="Unknown" value="0">
6970 <desc>
6971 The type of interface cannot be determined.
6972 </desc>
6973 </const>
6974 <const name="Ethernet" value="1">
6975 <desc>
6976 Ethernet frame encapsulation.
6977 </desc>
6978 </const>
6979 <const name="PPP" value="2">
6980 <desc>
6981 Point-to-point protocol encapsulation.
6982 </desc>
6983 </const>
6984 <const name="SLIP" value="3">
6985 <desc>
6986 Serial line IP encapsulation.
6987 </desc>
6988 </const>
6989 </enum>
6990
6991 <enum
6992 name="HostNetworkInterfaceStatus"
6993 uuid="CC474A69-2710-434B-8D99-C38E5D5A6F41"
6994 >
6995 <desc>
6996 Current status of the interface.
6997 <see>IHostNetworkInterface</see>
6998 </desc>
6999
7000 <const name="Unknown" value="0">
7001 <desc>
7002 The state of interface cannot be determined.
7003 </desc>
7004 </const>
7005 <const name="Up" value="1">
7006 <desc>
7007 The interface is fully operational.
7008 </desc>
7009 </const>
7010 <const name="Down" value="2">
7011 <desc>
7012 The interface is not functioning.
7013 </desc>
7014 </const>
7015 </enum>
7016
7017 <enum
7018 name="HostNetworkInterfaceType"
7019 uuid="67431b00-9946-48a2-bc02-b25c5919f4f3"
7020 >
7021 <desc>
7022 Network interface type.
7023 </desc>
7024 <const name="Bridged" value="1"/>
7025 <const name="HostOnly" value="2"/>
7026 </enum>
7027
7028 <interface
7029 name="IHostNetworkInterface" extends="$unknown"
7030 uuid="ce6fae58-7642-4102-b5db-c9005c2320a8"
7031 wsmap="managed"
7032 >
7033 <desc>
7034 Reprents one of host's network interfaces. IP V6 address and network
7035 mask are strings of 32 hexdecimal digits grouped by four. Groups are
7036 separated by colons.
7037 For example, fe80:0000:0000:0000:021e:c2ff:fed2:b030.
7038 </desc>
7039 <attribute name="name" type="wstring" readonly="yes">
7040 <desc>Returns the host network interface name.</desc>
7041 </attribute>
7042
7043 <attribute name="id" type="wstring" readonly="yes">
7044 <desc>Returns the interface UUID.</desc>
7045 </attribute>
7046
7047 <attribute name="networkName" type="wstring" readonly="yes">
7048 <desc>Returns the name of a virtual network the interface gets attached to.</desc>
7049 </attribute>
7050
7051 <attribute name="dhcpEnabled" type="boolean" readonly="yes">
7052 <desc>Specifies whether the DHCP is enabled for the interface.</desc>
7053 </attribute>
7054
7055 <attribute name="IPAddress" type="wstring" readonly="yes">
7056 <desc>Returns the IP V4 address of the interface.</desc>
7057 </attribute>
7058
7059 <attribute name="networkMask" type="wstring" readonly="yes">
7060 <desc>Returns the network mask of the interface.</desc>
7061 </attribute>
7062
7063 <attribute name="IPV6Supported" type="boolean" readonly="yes">
7064 <desc>Specifies whether the IP V6 is supported/enabled for the interface.</desc>
7065 </attribute>
7066
7067 <attribute name="IPV6Address" type="wstring" readonly="yes">
7068 <desc>Returns the IP V6 address of the interface.</desc>
7069 </attribute>
7070
7071 <attribute name="IPV6NetworkMaskPrefixLength" type="unsigned long" readonly="yes">
7072 <desc>Returns the length IP V6 network mask prefix of the interface.</desc>
7073 </attribute>
7074
7075 <attribute name="hardwareAddress" type="wstring" readonly="yes">
7076 <desc>Returns the hardware address. For Ethernet it is MAC address.</desc>
7077 </attribute>
7078
7079 <attribute name="mediumType" type="HostNetworkInterfaceMediumType" readonly="yes">
7080 <desc>Type of protocol encapsulation used.</desc>
7081 </attribute>
7082
7083 <attribute name="status" type="HostNetworkInterfaceStatus" readonly="yes">
7084 <desc>Status of the interface.</desc>
7085 </attribute>
7086
7087 <attribute name="interfaceType" type="HostNetworkInterfaceType" readonly="yes">
7088 <desc>specifies the host interface type.</desc>
7089 </attribute>
7090
7091 <method name="enableStaticIpConfig">
7092 <desc>sets and enables the static IP V4 configuration for the given interface.</desc>
7093 <param name="IPAddress" type="wstring" dir="in">
7094 <desc>
7095 IP address.
7096 </desc>
7097 </param>
7098 <param name="networkMask" type="wstring" dir="in">
7099 <desc>
7100 network mask.
7101 </desc>
7102 </param>
7103 </method>
7104
7105 <method name="enableStaticIpConfigV6">
7106 <desc>sets and enables the static IP V6 configuration for the given interface.</desc>
7107 <param name="IPV6Address" type="wstring" dir="in">
7108 <desc>
7109 IP address.
7110 </desc>
7111 </param>
7112 <param name="IPV6NetworkMaskPrefixLength" type="unsigned long" dir="in">
7113 <desc>
7114 network mask.
7115 </desc>
7116 </param>
7117 </method>
7118
7119 <method name="enableDynamicIpConfig">
7120 <desc>enables the dynamic IP configuration.</desc>
7121 </method>
7122
7123 <method name="dhcpRediscover">
7124 <desc>refreshes the IP configuration for dhcp-enabled interface.</desc>
7125 </method>
7126
7127 </interface>
7128
7129 <interface
7130 name="IHost" extends="$unknown"
7131 uuid="a13b5556-5c0b-4f80-9df6-6f804f3336a1"
7132 wsmap="managed"
7133 >
7134 <desc>
7135 The IHost interface represents the physical machine that this VirtualBox
7136 installation runs on.
7137
7138 An object implementing this interface is returned by the
7139 <link to="IVirtualBox::host" /> attribute. This interface contains
7140 read-only information about the host's physical hardware (such as what
7141 processors and disks are available, what the host operating system is,
7142 and so on) and also allows for manipulating some of the host's hardware,
7143 such as global USB device filters and host interface networking.
7144
7145 </desc>
7146 <attribute name="DVDDrives" type="IHostDVDDrive" readonly="yes" safearray="yes">
7147 <desc>List of DVD drives available on the host.</desc>
7148 </attribute>
7149
7150 <attribute name="floppyDrives" type="IHostFloppyDrive" readonly="yes" safearray="yes">
7151 <desc>List of floppy drives available on the host.</desc>
7152 </attribute>
7153
7154 <attribute name="USBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
7155 <desc>
7156 List of USB devices currently attached to the host.
7157 Once a new device is physically attached to the host computer,
7158 it appears in this list and remains there until detached.
7159
7160 <note>
7161 If USB functionality is not available in the given edition of
7162 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7163 </note>
7164 </desc>
7165 </attribute>
7166
7167 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilter" readonly="yes" safearray="yes">
7168 <desc>
7169 List of USB device filters in action.
7170 When a new device is physically attached to the host computer,
7171 filters from this list are applied to it (in order they are stored
7172 in the list). The first matched filter will determine the
7173 <link to="IHostUSBDeviceFilter::action">action</link>
7174 performed on the device.
7175
7176 Unless the device is ignored by these filters, filters of all
7177 currently running virtual machines
7178 (<link to="IUSBController::deviceFilters"/>) are applied to it.
7179
7180 <note>
7181 If USB functionality is not available in the given edition of
7182 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7183 </note>
7184
7185 <see>IHostUSBDeviceFilter, USBDeviceState</see>
7186 </desc>
7187 </attribute>
7188
7189 <attribute name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" readonly="yes">
7190 <desc>List of host network interfaces currently defined on the host.</desc>
7191 </attribute>
7192
7193 <attribute name="processorCount" type="unsigned long" readonly="yes">
7194 <desc>Number of (logical) CPUs installed in the host system.</desc>
7195 </attribute>
7196
7197 <attribute name="processorOnlineCount" type="unsigned long" readonly="yes">
7198 <desc>Number of (logical) CPUs online in the host system.</desc>
7199 </attribute>
7200
7201 <method name="getProcessorSpeed">
7202 <desc>Query the (approximate) maximum speed of a specified host CPU in
7203 Megahertz.
7204 </desc>
7205 <param name="cpuId" type="unsigned long" dir="in">
7206 <desc>
7207 Identifier of the CPU.
7208 </desc>
7209 </param>
7210 <param name="speed" type="unsigned long" dir="return">
7211 <desc>
7212 Speed value. 0 is returned if value is not known or @a cpuId is
7213 invalid.
7214 </desc>
7215 </param>
7216 </method>
7217
7218 <method name="getProcessorFeature">
7219 <desc>Query whether a CPU feature is supported or not.</desc>
7220 <param name="feature" type="ProcessorFeature" dir="in">
7221 <desc>
7222 CPU Feature identifier.
7223 </desc>
7224 </param>
7225 <param name="supported" type="boolean" dir="return">
7226 <desc>
7227 Feature is supported or not.
7228 </desc>
7229 </param>
7230 </method>
7231
7232 <method name="getProcessorDescription">
7233 <desc>Query the model string of a specified host CPU.
7234 <note>
7235 This function is not implemented in the current version of the
7236 product.
7237 </note>
7238 </desc>
7239 <param name="cpuId" type="unsigned long" dir="in">
7240 <desc>
7241 Identifier of the CPU.
7242 </desc>
7243 </param>
7244 <param name="description" type="wstring" dir="return">
7245 <desc>
7246 Model string. A NULL string is returned if value is not known or
7247 @a cpuId is invalid.
7248 </desc>
7249 </param>
7250 </method>
7251
7252 <attribute name="memorySize" type="unsigned long" readonly="yes">
7253 <desc>Amount of system memory in megabytes installed in the host system.</desc>
7254 </attribute>
7255
7256 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
7257 <desc>Available system memory in the host system.</desc>
7258 </attribute>
7259
7260 <attribute name="operatingSystem" type="wstring" readonly="yes">
7261 <desc>Name of the host system's operating system.</desc>
7262 </attribute>
7263
7264 <attribute name="OSVersion" type="wstring" readonly="yes">
7265 <desc>Host operating system's version string.</desc>
7266 </attribute>
7267
7268 <attribute name="UTCTime" type="long long" readonly="yes">
7269 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
7270 </attribute>
7271
7272 <attribute name="Acceleration3DAvailable" type="boolean" readonly="yes">
7273 <desc>Returns true when the host supports 3D hardware acceleration.</desc>
7274 </attribute>
7275
7276 <method name="createHostOnlyNetworkInterface">
7277 <desc>
7278 Creates a new adapter for Host Only Networking.
7279 <result name="E_INVALIDARG">
7280 Host network interface @a name already exists.
7281 </result>
7282 </desc>
7283 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
7284 <desc>
7285 Created host interface object.
7286 </desc>
7287 </param>
7288 <param name="progress" type="IProgress" dir="return">
7289 <desc>
7290 Progress object to track the operation completion.
7291 </desc>
7292 </param>
7293 </method>
7294
7295 <method name="removeHostOnlyNetworkInterface">
7296 <desc>
7297 Removes the given Host Only Networking interface.
7298 <result name="VBOX_E_OBJECT_NOT_FOUND">
7299 No host network interface matching @a id found.
7300 </result>
7301 </desc>
7302 <param name="id" type="wstring" dir="in">
7303 <desc>
7304 Adapter GUID.
7305 </desc>
7306 </param>
7307 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
7308 <desc>
7309 Removed host interface object.
7310 </desc>
7311 </param>
7312 <param name="progress" type="IProgress" dir="return">
7313 <desc>
7314 Progress object to track the operation completion.
7315 </desc>
7316 </param>
7317 </method>
7318
7319 <method name="createUSBDeviceFilter">
7320 <desc>
7321 Creates a new USB device filter. All attributes except
7322 the filter name are set to <tt>null</tt> (any match),
7323 <i>active</i> is <tt>false</tt> (the filter is not active).
7324
7325 The created filter can be added to the list of filters using
7326 <link to="#insertUSBDeviceFilter"/>.
7327
7328 <see>#USBDeviceFilters</see>
7329 </desc>
7330 <param name="name" type="wstring" dir="in">
7331 <desc>
7332 Filter name. See <link to="IHostUSBDeviceFilter::name"/>
7333 for more info.
7334 </desc>
7335 </param>
7336 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
7337 <desc>Created filter object.</desc>
7338 </param>
7339 </method>
7340
7341 <method name="insertUSBDeviceFilter">
7342 <desc>
7343 Inserts the given USB device to the specified position
7344 in the list of filters.
7345
7346 Positions are numbered starting from <tt>0</tt>. If the specified
7347 position is equal to or greater than the number of elements in
7348 the list, the filter is added at the end of the collection.
7349
7350 <note>
7351 Duplicates are not allowed, so an attempt to insert a
7352 filter already in the list is an error.
7353 </note>
7354 <note>
7355 If USB functionality is not available in the given edition of
7356 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7357 </note>
7358
7359 <see>#USBDeviceFilters</see>
7360
7361 <result name="VBOX_E_INVALID_OBJECT_STATE">
7362 USB device filter is not created within this VirtualBox instance.
7363 </result>
7364 <result name="E_INVALIDARG">
7365 USB device filter already in list.
7366 </result>
7367
7368 </desc>
7369 <param name="position" type="unsigned long" dir="in">
7370 <desc>Position to insert the filter to.</desc>
7371 </param>
7372 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
7373 <desc>USB device filter to insert.</desc>
7374 </param>
7375 </method>
7376
7377 <method name="removeUSBDeviceFilter">
7378 <desc>
7379 Removes a USB device filter from the specified position in the
7380 list of filters.
7381
7382 Positions are numbered starting from <tt>0</tt>. Specifying a
7383 position equal to or greater than the number of elements in
7384 the list will produce an error.
7385
7386 <note>
7387 If USB functionality is not available in the given edition of
7388 VirtualBox, this method will set the result code to @c E_NOTIMPL.
7389 </note>
7390
7391 <see>#USBDeviceFilters</see>
7392
7393 <result name="E_INVALIDARG">
7394 USB device filter list empty or invalid @a position.
7395 </result>
7396
7397 </desc>
7398 <param name="position" type="unsigned long" dir="in">
7399 <desc>Position to remove the filter from.</desc>
7400 </param>
7401 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
7402 <desc>Removed USB device filter.</desc>
7403 </param>
7404 </method>
7405
7406 <method name="findHostDVDDrive">
7407 <desc>
7408 Searches for a host DVD drive with the given @c name.
7409
7410 <result name="VBOX_E_OBJECT_NOT_FOUND">
7411 Given @c name does not correspond to any host drive.
7412 </result>
7413
7414 </desc>
7415 <param name="name" type="wstring" dir="in">
7416 <desc>Name of the host drive to search for</desc>
7417 </param>
7418 <param name="drive" type="IHostDVDDrive" dir="return">
7419 <desc>Found host drive object</desc>
7420 </param>
7421 </method>
7422
7423 <method name="findHostFloppyDrive">
7424 <desc>
7425 Searches for a host floppy drive with the given @c name.
7426
7427 <result name="VBOX_E_OBJECT_NOT_FOUND">
7428 Given @c name does not correspond to any host floppy drive.
7429 </result>
7430
7431 </desc>
7432 <param name="name" type="wstring" dir="in">
7433 <desc>Name of the host floppy drive to search for</desc>
7434 </param>
7435 <param name="drive" type="IHostFloppyDrive" dir="return">
7436 <desc>Found host floppy drive object</desc>
7437 </param>
7438 </method>
7439
7440 <method name="findHostNetworkInterfaceByName">
7441 <desc>
7442 Searches through all host network interfaces for an interface with
7443 the given @c name.
7444 <note>
7445 The method returns an error if the given @c name does not
7446 correspond to any host network interface.
7447 </note>
7448 </desc>
7449 <param name="name" type="wstring" dir="in">
7450 <desc>Name of the host network interface to search for.</desc>
7451 </param>
7452 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7453 <desc>Found host network interface object.</desc>
7454 </param>
7455 </method>
7456 <method name="findHostNetworkInterfaceById">
7457 <desc>
7458 Searches through all host network interfaces for an interface with
7459 the given GUID.
7460 <note>
7461 The method returns an error if the given GUID does not
7462 correspond to any host network interface.
7463 </note>
7464 </desc>
7465 <param name="id" type="wstring" dir="in">
7466 <desc>GUID of the host network interface to search for.</desc>
7467 </param>
7468 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
7469 <desc>Found host network interface object.</desc>
7470 </param>
7471 </method>
7472 <method name="findHostNetworkInterfacesOfType">
7473 <desc>
7474 Searches through all host network interfaces and returns a list of interfaces of the specified type
7475 </desc>
7476 <param name="type" type="HostNetworkInterfaceType" dir="in">
7477 <desc>type of the host network interfaces to search for.</desc>
7478 </param>
7479 <param name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" dir="return">
7480 <desc>Found host network interface objects.</desc>
7481 </param>
7482 </method>
7483
7484 <method name="findUSBDeviceById">
7485 <desc>
7486 Searches for a USB device with the given UUID.
7487
7488 <result name="VBOX_E_OBJECT_NOT_FOUND">
7489 Given @c id does not correspond to any USB device.
7490 </result>
7491
7492 <see>IHostUSBDevice::id</see>
7493 </desc>
7494 <param name="id" type="wstring" dir="in">
7495 <desc>UUID of the USB device to search for.</desc>
7496 </param>
7497 <param name="device" type="IHostUSBDevice" dir="return">
7498 <desc>Found USB device object.</desc>
7499 </param>
7500 </method>
7501
7502 <method name="findUSBDeviceByAddress">
7503 <desc>
7504 Searches for a USB device with the given host address.
7505
7506 <result name="VBOX_E_OBJECT_NOT_FOUND">
7507 Given @c name does not correspond to any USB device.
7508 </result>
7509
7510 <see>IHostUSBDevice::address</see>
7511 </desc>
7512 <param name="name" type="wstring" dir="in">
7513 <desc>
7514 Address of the USB device (as assigned by the host) to
7515 search for.
7516 </desc>
7517 </param>
7518 <param name="device" type="IHostUSBDevice" dir="return">
7519 <desc>Found USB device object.</desc>
7520 </param>
7521 </method>
7522
7523 </interface>
7524
7525 <!--
7526 // ISystemProperties
7527 /////////////////////////////////////////////////////////////////////////
7528 -->
7529
7530 <interface
7531 name="ISystemProperties"
7532 extends="$unknown"
7533 uuid="63bfd184-df69-4949-9159-a923cf7b1207"
7534 wsmap="managed"
7535 >
7536 <desc>
7537 The ISystemProperties interface represents global properties of the given
7538 VirtualBox installation.
7539
7540 These properties define limits and default values for various attributes
7541 and parameters. Most of the properties are read-only, but some can be
7542 changed by a user.
7543 </desc>
7544
7545 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
7546 <desc>Minimum guest system memory in Megabytes.</desc>
7547 </attribute>
7548
7549 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
7550 <desc>Maximum guest system memory in Megabytes.</desc>
7551 </attribute>
7552
7553 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
7554 <desc>Minimum guest video memory in Megabytes.</desc>
7555 </attribute>
7556
7557 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
7558 <desc>Maximum guest video memory in Megabytes.</desc>
7559 </attribute>
7560
7561 <attribute name="minGuestCPUCount" type="unsigned long" readonly="yes">
7562 <desc>Minimum CPU count.</desc>
7563 </attribute>
7564
7565 <attribute name="maxGuestCPUCount" type="unsigned long" readonly="yes">
7566 <desc>Maximum CPU count.</desc>
7567 </attribute>
7568
7569 <attribute name="maxVDISize" type="unsigned long long" readonly="yes">
7570 <desc>Maximum size of a virtual disk image in Megabytes.</desc>
7571 </attribute>
7572
7573 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
7574 <desc>
7575 Number of network adapters associated with every
7576 <link to="IMachine"/> instance.
7577 </desc>
7578 </attribute>
7579
7580 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
7581 <desc>
7582 Number of serial ports associated with every
7583 <link to="IMachine"/> instance.
7584 </desc>
7585 </attribute>
7586
7587 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
7588 <desc>
7589 Number of parallel ports associated with every
7590 <link to="IMachine"/> instance.
7591 </desc>
7592 </attribute>
7593
7594 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
7595 <desc>
7596 Maximum device position in the boot order. This value corresponds
7597 to the total number of devices a machine can boot from, to make it
7598 possible to include all possible devices to the boot list.
7599 <see><link to="IMachine::setBootOrder"/></see>
7600 </desc>
7601 </attribute>
7602
7603 <attribute name="defaultMachineFolder" type="wstring">
7604 <desc>
7605 Full path to the default directory used to create new or open
7606 existing machines when a settings file name contains no
7607 path.
7608
7609 The initial value of this property is
7610 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
7611 VirtualBox_home</link><tt>&gt;/Machines</tt>.
7612
7613 <note>
7614 Setting this property to <tt>null</tt> will restore the
7615 initial value.
7616 </note>
7617 <note>
7618 When settings this property, the specified path can be
7619 absolute (full path) or relative
7620 to the <link to="IVirtualBox::homeFolder">
7621 VirtualBox home directory</link>.
7622 When reading this property, a full path is
7623 always returned.
7624 </note>
7625 <note>
7626 The specified path may not exist, it will be created
7627 when necessary.
7628 </note>
7629
7630 <see>
7631 <link to="IVirtualBox::createMachine"/>,
7632 <link to="IVirtualBox::openMachine"/>
7633 </see>
7634 </desc>
7635 </attribute>
7636
7637 <attribute name="defaultHardDiskFolder" type="wstring">
7638 <desc>
7639 Full path to the default directory used to create new or open existing
7640 virtual disks.
7641
7642 This path is used when the storage unit of a hard disk is a regular file
7643 in the host's file system and only a file name that contains no path is
7644 given.
7645
7646 The initial value of this property is
7647 <tt>&lt;</tt>
7648 <link to="IVirtualBox::homeFolder">VirtualBox_home</link>
7649 <tt>&gt;/HardDisks</tt>.
7650
7651 <note>
7652 Setting this property to <tt>null</tt> will restore the
7653 initial value.
7654 </note>
7655 <note>
7656 When settings this property, the specified path can be relative
7657 to the
7658 <link to="IVirtualBox::homeFolder">VirtualBox home directory</link> or
7659 absolute. When reading this property, a full path is
7660 always returned.
7661 </note>
7662 <note>
7663 The specified path may not exist, it will be created
7664 when necessary.
7665 </note>
7666
7667 <see>
7668 IHardDisk,
7669 <link to="IVirtualBox::createHardDisk"/>,
7670 <link to="IVirtualBox::openHardDisk"/>,
7671 <link to="IMedium::location"/>
7672 </see>
7673 </desc>
7674 </attribute>
7675
7676 <attribute name="hardDiskFormats" type="IHardDiskFormat" safearray="yes" readonly="yes">
7677 <desc>
7678 List of all hard disk storage formats supported by this VirtualBox
7679 installation.
7680
7681 Keep in mind that the hard disk format identifier
7682 (<link to="IHardDiskFormat::id"/>) used in other API calls like
7683 <link to="IVirtualBox::createHardDisk"/> to refer to a particular
7684 hard disk format is a case-insensitive string. This means that, for
7685 example, all of the following strings:
7686 <pre>
7687 "VDI"
7688 "vdi"
7689 "VdI"</pre>
7690 refer to the same hard disk format.
7691
7692 Note that the virtual hard disk framework is backend-based, therefore
7693 the list of supported formats depends on what backends are currently
7694 installed.
7695
7696 <see>
7697 <link to="IHardDiskFormat"/>,
7698 </see>
7699 </desc>
7700 </attribute>
7701
7702 <attribute name="defaultHardDiskFormat" type="wstring">
7703 <desc>
7704 Identifier of the default hard disk format used by VirtualBox.
7705
7706 The hard disk format set by this attribute is used by VirtualBox
7707 when the hard disk format was not specified explicitly. One example is
7708 <link to="IVirtualBox::createHardDisk"/> with the <tt>null</tt>
7709 format argument. A more complex example is implicit creation of
7710 differencing hard disks when taking a snapshot of a virtual machine:
7711 this operation will try to use a format of the parent hard disk first
7712 and if this format does not support differencing hard disks the default
7713 format specified by this argument will be used.
7714
7715 The list of supported hard disk formats may be obtained by the
7716 <link to="#hardDiskFormats"/> call. Note that the default hard disk
7717 format must have a capability to create differencing hard disks;
7718 otherwise opeartions that create hard disks implicitly may fail
7719 unexpectedly.
7720
7721 The initial value of this property is <tt>VDI</tt> in the current
7722 version of the VirtualBox product, but may change in the future.
7723
7724 <note>
7725 Setting this property to <tt>null</tt> will restore the
7726 initial value.
7727 </note>
7728
7729 <see>
7730 <link to="#hardDiskFormats"/>,
7731 <link to="IHardDiskFormat::id"/>,
7732 <link to="IVirtualBox::createHardDisk"/>
7733 </see>
7734 </desc>
7735 </attribute>
7736
7737 <attribute name="remoteDisplayAuthLibrary" type="wstring">
7738 <desc>
7739 Library that provides authentication for VRDP clients. The library
7740 is used if a virtual machine's authentication type is set to "external"
7741 in the VM RemoteDisplay configuration.
7742
7743 The system library extension (".DLL" or ".so") must be omitted.
7744 A full path can be specified; if not, then the library must reside on the
7745 system's default library path.
7746
7747 The default value of this property is <tt>VRDPAuth</tt>. There is a library
7748 of that name in one of the default VirtualBox library directories.
7749
7750 For details about VirtualBox authentication libraries and how to implement
7751 them, please refer to the VirtualBox manual.
7752
7753 <note>
7754 Setting this property to <tt>null</tt> will restore the
7755 initial value.
7756 </note>
7757 </desc>
7758 </attribute>
7759
7760 <attribute name="webServiceAuthLibrary" type="wstring">
7761 <desc>
7762 Library that provides authentication for webservice clients. The library
7763 is used if a virtual machine's authentication type is set to "external"
7764 in the VM RemoteDisplay configuration and will be called from
7765 within the <link to="IWebsessionManager::logon" /> implementation.
7766
7767 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
7768 there is no per-VM setting for this, as the webservice is a global
7769 resource (if it is running). Only for this setting (for the webservice),
7770 setting this value to a literal "null" string disables authentication,
7771 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
7772 no matter what user name and password are supplied.
7773
7774 The initial value of this property is <tt>VRDPAuth</tt>,
7775 meaning that the webservice will use the same authentication
7776 library that is used by default for VBoxVRDP (again, see
7777 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
7778 The format and calling convention of authentication libraries
7779 is the same for the webservice as it is for VBoxVRDP.
7780
7781 </desc>
7782 </attribute>
7783
7784 <attribute name="HWVirtExEnabled" type="boolean">
7785 <desc>
7786 This specifies the default value for hardware virtualization
7787 extensions. If enabled, virtual machines will make use of
7788 hardware virtualization extensions such as Intel VT-x and
7789 AMD-V by default. This value can be overridden by each VM
7790 using their <link to="IMachine::HWVirtExEnabled" /> property.
7791 </desc>
7792 </attribute>
7793
7794 <attribute name="LogHistoryCount" type="unsigned long">
7795 <desc>
7796 This value specifies how many old release log files are kept.
7797 </desc>
7798 </attribute>
7799
7800 <attribute name="defaultAudioDriver" type="AudioDriverType" readonly="yes">
7801 <desc>This value hold the default audio driver for the current
7802 system.</desc>
7803 </attribute>
7804 </interface>
7805
7806 <!--
7807 // IGuest
7808 /////////////////////////////////////////////////////////////////////////
7809 -->
7810
7811 <interface
7812 name="IGuestOSType" extends="$unknown"
7813 uuid="cfe9e64c-4430-435b-9e7c-e3d8e417bd58"
7814 wsmap="struct"
7815 >
7816 <desc>
7817 </desc>
7818
7819 <attribute name="familyId" type="wstring" readonly="yes">
7820 <desc>Guest OS family identifier string.</desc>
7821 </attribute>
7822
7823 <attribute name="familyDescription" type="wstring" readonly="yes">
7824 <desc>Human readable description of the guest OS family.</desc>
7825 </attribute>
7826
7827 <attribute name="id" type="wstring" readonly="yes">
7828 <desc>Guest OS identifier string.</desc>
7829 </attribute>
7830
7831 <attribute name="description" type="wstring" readonly="yes">
7832 <desc>Human readable description of the guest OS.</desc>
7833 </attribute>
7834
7835 <attribute name="is64Bit" type="boolean" readonly="yes">
7836 <desc>Returns @c true if the given OS is 64-bit</desc>
7837 </attribute>
7838
7839 <attribute name="recommendedIOAPIC" type="boolean" readonly="yes">
7840 <desc>Returns @c true if IO APIC recommended for this OS type.</desc>
7841 </attribute>
7842
7843 <attribute name="recommendedVirtEx" type="boolean" readonly="yes">
7844 <desc>Returns @c true if VT-x or AMD-V recommended for this OS type.</desc>
7845 </attribute>
7846
7847 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
7848 <desc>Recommended RAM size in Megabytes.</desc>
7849 </attribute>
7850
7851 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
7852 <desc>Recommended video RAM size in Megabytes.</desc>
7853 </attribute>
7854
7855 <attribute name="recommendedHDD" type="unsigned long" readonly="yes">
7856 <desc>Recommended hard disk size in Megabytes.</desc>
7857 </attribute>
7858
7859 <attribute name="adapterType" type="NetworkAdapterType" readonly="yes">
7860 <desc>Returns recommended network adapter for this OS type.</desc>
7861 </attribute>
7862 </interface>
7863
7864 <interface
7865 name="IGuest" extends="$unknown"
7866 uuid="d8556fca-81bc-12af-fca3-365528fa38ca"
7867
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 Virtual hard disk objects virtualize the hard disk hardware and look like
9005 regular hard disks for the guest OS running inside the virtual machine.
9006
9007 <h3>Hard Disk Types</h3>
9008
9009 There are three types of hard disks:
9010 <link to="HardDiskType_Normal">Normal</link>,
9011 <link to="HardDiskType_Immutable">Immutable</link> and
9012 <link to="HardDiskType_Writethrough">Writethrough</link>. The type of the
9013 hard disk defines how the hard disk is attached to a virtual machine and
9014 what happens when a <link to="ISnapshot">snapshot</link> of the virtual
9015 machine with the attached hard disk is taken. The type of the hard disk is
9016 defined by the <link to="#type"/> attribute.
9017
9018 All hard disks can be also divided in two big groups: <i>base</i> hard
9019 disks and <i>differencing</i> hard disks. A base hard disk contains all
9020 sectors of the hard disk data in its storage unit and therefore can be
9021 used independently. On the contrary, a differencing hard disk contains
9022 only some part of the hard disk data (a subset of sectors) and needs
9023 another hard disk to get access to the missing sectors of data. This
9024 another hard disk is called a <i>parent</i> hard disk and defines a hard
9025 disk to which this differencing hard disk is known to be <i>linked to</i>.
9026 The parent hard disk may be itself a differencing hard disk. This
9027 way, differencing hard disks form a linked hard disk chain. This chain
9028 always ends with the base hard disk which is sometimes referred to as the
9029 root hard disk of this chain. Note that several differencing hard disks
9030 may be linked to the same parent hard disk. This way, all known hard disks
9031 form a hard disk tree which is based on their parent-child relationship.
9032
9033 Differencing hard disks can be distinguished from base hard disks by
9034 querying the <link to="#parent"/> attribute: base hard disks do not have
9035 parents they would depend on, so the value of this attribute is always
9036 <tt>null</tt> for them. Using this attribute, it is possible to walk up
9037 the hard disk tree (from the child hard disk to its parent). It is also
9038 possible to walk down the tree using the <link to="#children"/>
9039 attribute.
9040
9041 Note that the type of all differencing hard disks is
9042 <link to="HardDiskType_Normal">Normal</link>; all other values are
9043 meaningless for them. Base hard disks may be of any type.
9044
9045 <h3>Creating Hard Disks</h3>
9046
9047 New base hard disks are created using
9048 <link to="IVirtualBox::createHardDisk"/>. Existing hard disks are
9049 opened using <link to="IVirtualBox::openHardDisk"/>. Differencing hard
9050 disks are usually implicitly created by VirtualBox when needed but may
9051 also be created explicitly using <link to="#createDiffStorage"/>.
9052
9053 After the hard disk is successfully created (including the storage unit)
9054 or opened, it becomes a known hard disk (remembered in the internal media
9055 registry). Known hard disks can be attached to a virtual machine, accessed
9056 through <link to="IVirtualBox::getHardDisk"/> and
9057 <link to="IVirtualBox::findHardDisk"/> methods or enumerated using the
9058 <link to="IVirtualBox::hardDisks"/> array (only for base hard disks).
9059
9060 The following methods, besides <link to="IMedium::close"/>,
9061 automatically remove the hard disk from the media registry:
9062 <ul>
9063 <li><link to="#deleteStorage"/></li>
9064 <li><link to="#mergeTo"/></li>
9065 </ul>
9066
9067 If the storage unit of the hard disk is a regular file in the host's
9068 file system then the rules stated in the description of the
9069 <link to="IMedium::location"/> attribute apply when setting its value. In
9070 addition, a plain file name without any path may be given, in which case
9071 the <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
9072 folder</link> will be prepended to it.
9073
9074 <h4>Automatic composition of the file name part</h4>
9075
9076 Another extension to the <link to="IMedium::location"/> attribute is that
9077 there is a possibility to cause VirtualBox to compose a unique value for
9078 the file name part of the location using the UUID of the hard disk. This
9079 applies only to hard disks in <link to="MediaState_NotCreated"/> state,
9080 e.g. before the storage unit is created, and works as follows. You set the
9081 value of the <link to="IMedium::location"/> attribute to a location
9082 specification which only contains the path specification but not the file
9083 name part and ends with either a forward slash or a backslash character.
9084 In response, VirtualBox will generate a new UUID for the hard disk and
9085 compose the file name using the following pattern:
9086 <pre>
9087 &lt;path&gt;/{&lt;uuid&gt;}.&lt;ext&gt;
9088 </pre>
9089 where <tt>&lt;path&gt;</tt> is the supplied path specification,
9090 <tt>&lt;uuid&gt;</tt> is the newly generated UUID and <tt>&lt;ext&gt;</tt>
9091 is the default extension for the storage format of this hard disk. After
9092 that, you may call any of the methods that create a new hard disk storage
9093 unit and they will use the generated UUID and file name.
9094
9095 <h3>Attaching Hard Disks</h3>
9096
9097 Hard disks are attached to virtual machines using the
9098 <link to="IMachine::attachHardDisk"/> method and detached using the
9099 <link to="IMachine::detachHardDisk"/> method. Depending on their
9100 <link to="#type"/>, hard disks are attached either
9101 <i>directly</i> or <i>indirectly</i>.
9102
9103 When a hard disk is being attached directly, it is associated with the
9104 virtual machine and used for hard disk operations when the machine is
9105 running. When a hard disk is being attached indirectly, a new differencing
9106 hard disk linked to it is implicitly created and this differencing hard
9107 disk is associated with the machine and used for hard disk operations.
9108 This also means that if <link to="IMachine::attachHardDisk"/> performs
9109 a direct attachment then the same hard disk will be returned in response
9110 to the subsequent <link to="IMachine::getHardDisk"/> call; however if
9111 an indirect attachment is performed then
9112 <link to="IMachine::getHardDisk"/> will return the implicitly created
9113 differencing hard disk, not the original one passed to <link
9114 to="IMachine::attachHardDisk"/>. The following table shows the
9115 dependency of the attachment type on the hard disk type:
9116
9117 <table>
9118 <tr>
9119 <th>Hard Disk Type</th>
9120 <th>Direct or Indirect?</th>
9121 </tr>
9122 <tr>
9123 <td>Normal (Base)</td>
9124 <td>
9125 Normal base hard disks that do not have children (i.e. differencing
9126 hard disks linked to them) and that are not already attached to
9127 virtual machines in snapshots are attached <b>directly</b>.
9128 Otherwise, they are attached <b>indirectly</b> because having
9129 dependent children or being part of the snapshot makes it impossible
9130 to modify hard disk contents without breaking the integrity of the
9131 dependent party. The <link to="#readOnly"/> attribute allows to
9132 quickly determine the kind of the attachment for the given hard
9133 disk. Note that if a normal base hard disk is to be indirectly
9134 attached to a virtual machine with snapshots then a special
9135 procedure called <i>smart attachment</i> is performed (see below).
9136 </td>
9137 </tr>
9138 <tr>
9139 <td>Normal (Differencing)</td>
9140 <td>
9141 Differencing hard disks are like normal base hard disks: attached
9142 <b>directly</b> if they do not have children and are not attached to
9143 virtual machines in snapshots, and <b>indirectly</b> otherwise. Note
9144 that the smart attachment procedure is never performed for
9145 differencing hard disks.
9146 </td>
9147 </tr>
9148 <tr>
9149 <td>Immutable</td>
9150 <td>
9151 Immutable hard disks are always attached <b>indirectly</b> because
9152 they are designed to be non-writable. If an immutable hard disk is
9153 attached to a virtual machine with snapshots then a special
9154 procedure called smart attachment is performed (see below).
9155 </td>
9156 </tr>
9157 <tr>
9158 <td>Writethrough</td>
9159 <td>
9160 Writethrough hard disks are always attached <b>directly</b>, also as
9161 designed. This also means that writethrough hard disks cannot have
9162 other hard disks linked to them at all.
9163 </td>
9164 </tr>
9165 </table>
9166
9167 Note that the same hard disk, regardless of its type, may be attached to
9168 more than one virtual machine at a time. In this case, the machine that is
9169 started first gains exclusive access to the hard disk and attempts to
9170 start other machines having this hard disk attached will fail until the
9171 first machine is powered down.
9172
9173 Detaching hard disks is performed in a <i>deferred</i> fashion. This means
9174 that the given hard disk remains associated with the given machine after a
9175 successful <link to="IMachine::detachHardDisk"/> call until
9176 <link to="IMachine::saveSettings"/> is called to save all changes to
9177 machine settings to disk. This deferring is necessary to guarantee that
9178 the hard disk configuration may be restored at any time by a call to
9179 <link to="IMachine::discardSettings"/> before the settings
9180 are saved (committed).
9181
9182 Note that if <link to="IMachine::discardSettings"/> is called after
9183 indirectly attaching some hard disks to the machine but before a call to
9184 <link to="IMachine::saveSettings"/> is made, it will implicitly delete
9185 all differencing hard disks implicitly created by
9186 <link to="IMachine::attachHardDisk"/> for these indirect attachments.
9187 Such implicitly created hard disks will also be immediately deleted when
9188 detached explicitly using the <link to="IMachine::detachHardDisk"/>
9189 call if it is made before <link to="IMachine::saveSettings"/>. This
9190 implicit deletion is safe because newly created differencing hard
9191 disks do not contain any user data.
9192
9193 However, keep in mind that detaching differencing hard disks that were
9194 implicitly created by <link to="IMachine::attachHardDisk"/>
9195 before the last <link to="IMachine::saveSettings"/> call will
9196 <b>not</b> implicitly delete them as they may already contain some data
9197 (for example, as a result of virtual machine execution). If these hard
9198 disks are no more necessary, the caller can always delete them explicitly
9199 using <link to="#deleteStorage"/> after they are actually de-associated
9200 from this machine by the <link to="IMachine::saveSettings"/> call.
9201
9202 <h3>Smart Attachment</h3>
9203
9204 When normal base or immutable hard disks are indirectly attached to a
9205 virtual machine then some additional steps are performed to make sure the
9206 virtual machine will have the most recent "view" of the hard disk being
9207 attached. These steps include walking through the machine's snapshots
9208 starting from the current one and going through ancestors up to the first
9209 snapshot. Hard disks attached to the virtual machine in all
9210 of the encountered snapshots are checked whether they are descendants of
9211 the given normal base or immutable hard disk. The first found child (which
9212 is the differencing hard disk) will be used instead of the normal base or
9213 immutable hard disk as a parent for creating a new differencing hard disk
9214 that will be actually attached to the machine. And only if no descendants
9215 are found or if the virtual machine does not have any snapshots then the
9216 normal base or immutable hard disk will be used itself as a parent for
9217 this differencing hard disk.
9218
9219 It is easier to explain what smart attachment does using the
9220 following example:
9221 <pre>
9222BEFORE attaching B.vdi: AFTER attaching B.vdi:
9223
9224Snapshot 1 (B.vdi) Snapshot 1 (B.vdi)
9225 Snapshot 2 (D1->B.vdi) Snapshot 2 (D1->B.vdi)
9226 Snapshot 3 (D2->D1.vdi) Snapshot 3 (D2->D1.vdi)
9227 Snapshot 4 (none) Snapshot 4 (none)
9228 CurState (none) CurState (D3->D2.vdi)
9229
9230 NOT
9231 ...
9232 CurState (D3->B.vdi)
9233 </pre>
9234 The first column is the virtual machine configuration before the base hard
9235 disk <tt>B.vdi</tt> is attached, the second column shows the machine after
9236 this hard disk is attached. Constructs like <tt>D1->B.vdi</tt> and similar
9237 mean that the hard disk that is actually attached to the machine is a
9238 differencing hard disk, <tt>D1.vdi</tt>, which is linked to (based on)
9239 another hard disk, <tt>B.vdi</tt>.
9240
9241 As we can see from the example, the hard disk <tt>B.vdi</tt> was detached
9242 from the machine before taking Snapshot 4. Later, after Snapshot 4 was
9243 taken, the user decides to attach <tt>B.vdi</tt> again. <tt>B.vdi</tt> has
9244 dependent child hard disks (<tt>D1.vdi</tt>, <tt>D2.vdi</tt>), therefore
9245 it cannot be attached directly and needs an indirect attachment (i.e.
9246 implicit creation of a new differencing hard disk). Due to the smart
9247 attachment procedure, the new differencing hard disk
9248 (<tt>D3.vdi</tt>) will be based on <tt>D2.vdi</tt>, not on
9249 <tt>B.vdi</tt> itself, since <tt>D2.vdi</tt> is the most recent view of
9250 <tt>B.vdi</tt> existing for this snapshot branch of the given virtual
9251 machine.
9252
9253 Note that if there is more than one descendant hard disk of the given base
9254 hard disk found in a snapshot, and there is an exact device, channel and
9255 bus match, then this exact match will be used. Otherwise, the youngest
9256 descendant will be picked up.
9257
9258 There is one more important aspect of the smart attachment procedure which
9259 is not related to snapshots at all. Before walking through the snapshots
9260 as described above, the backup copy of the current list of hard disk
9261 attachment is searched for descendants. This backup copy is created when
9262 the hard disk configuration is changed for the first time after the last
9263 <link to="IMachine::saveSettings"/> call and used by
9264 <link to="IMachine::discardSettings"/> to undo the recent hard disk
9265 changes. When such a descendant is found in this backup copy, it will be
9266 simply re-attached back, without creating a new differencing hard disk for
9267 it. This optimization is necessary to make it possible to re-attach the
9268 base or immutable hard disk to a different bus, channel or device slot
9269 without losing the contents of the differencing hard disk actually
9270 attached to the machine in place of it.
9271 </desc>
9272
9273 <attribute name="format" type="wstring" readonly="yes">
9274 <desc>
9275 Storage format of this hard disk.
9276
9277 The value of this attribute is a string that specifies a backend used to
9278 store hard disk data. The storage format is defined when you create a
9279 new hard disk or automatically detected when you open an existing hard
9280 disk medium, and cannot be changed later.
9281
9282 The list of all storage formats supported by this VirtualBox
9283 installation can be obtained using
9284 <link to="ISystemProperties::hardDiskFormats"/>.
9285 </desc>
9286 </attribute>
9287
9288 <attribute name="type" type="HardDiskType">
9289 <desc>
9290 Type (role) of this hard disk.
9291
9292 The following constraints apply when changing the value of this
9293 attribute:
9294 <ul>
9295 <li>If a hard disk is attached to a virtual machine (either in the
9296 current state or in one of the snapshots), its type cannot be
9297 changed.
9298 </li>
9299 <li>As long as the hard disk has children, its type cannot be set
9300 to <link to="HardDiskType_Writethrough"/>.
9301 </li>
9302 <li>The type of all differencing hard disks is
9303 <link to="HardDiskType_Normal"/> and cannot be changed.
9304 </li>
9305 </ul>
9306
9307 The type of a newly created or opened hard disk is set to
9308 <link to="HardDiskType_Normal"/>.
9309 </desc>
9310 </attribute>
9311
9312 <attribute name="parent" type="IHardDisk" readonly="yes">
9313 <desc>
9314 Parent of this hard disk (a hard disk this hard disk is directly based
9315 on).
9316
9317 Only differencing hard disks have parents. For base (non-differencing)
9318 hard disks, <tt>null</tt> is returned.
9319 </desc>
9320 </attribute>
9321
9322 <attribute name="children" type="IHardDisk" safearray="yes" readonly="yes">
9323 <desc>
9324 Children of this hard disk (all differencing hard disks directly based
9325 on this hard disk). A <tt>null</tt> array is returned if this hard disk
9326 does not have any children.
9327 </desc>
9328 </attribute>
9329
9330 <attribute name="root" type="IHardDisk" readonly="yes">
9331 <desc>
9332 Root hard disk of this hard disk.
9333
9334 If this is a differencing hard disk, its root hard disk is the base hard
9335 disk the given hard disk branch starts from. For all other types of hard
9336 disks, this property returns the hard disk object itself (i.e. the same
9337 object this property is read on).
9338 </desc>
9339 </attribute>
9340
9341 <attribute name="readOnly" type="boolean" readonly="yes">
9342 <desc>
9343 Returns <tt>true</tt> if this hard disk is read-only and <tt>false</tt>
9344 otherwise.
9345
9346 A hard disk is considered to be read-only when its contents cannot be
9347 modified without breaking the integrity of other parties that depend on
9348 this hard disk such as its child hard disks or snapshots of virtual
9349 machines where this hard disk is attached to these machines. If there
9350 are no children and no such snapshots then there is no dependency and
9351 the hard disk is not read-only.
9352
9353 The value of this attribute can be used to determine the kind of the
9354 attachment that will take place when attaching this hard disk to a
9355 virtual machine. If the value is <tt>false</tt> then the hard disk will
9356 be attached directly. If the value is <tt>true</tt> then the hard disk
9357 will be attached indirectly by creating a new differencing child hard
9358 disk for that. See the interface description for more information.
9359
9360 Note that all <link to="HardDiskType_Immutable">Immutable</link> hard
9361 disks are always read-only while all
9362 <link to="HardDiskType_Writethrough">Writethrough</link> hard disks are
9363 always not.
9364
9365 <note>
9366 The read-only condition represented by this attribute is related to
9367 the hard disk type and usage, not to the current
9368 <link to="IMedium::state">media state</link> and not to the read-only
9369 state of the storage unit.
9370 </note>
9371 </desc>
9372 </attribute>
9373
9374 <attribute name="logicalSize" type="unsigned long long" readonly="yes">
9375 <desc>
9376 Logical size of this hard disk (in megabytes), as reported to the
9377 guest OS running inside the virtual machine this disk is
9378 attached to. The logical size is defined when the hard disk is created
9379 and cannot be changed later.
9380
9381 <note>
9382 Reading this property on a differencing hard disk will return the size
9383 of its <link to="#root"/> hard disk.
9384 </note>
9385 <note>
9386 For hard disks whose state is <link to="#state"/> is <link
9387 to="MediaState_Inaccessible"/>, the value of this property is the
9388 last known logical size. For <link to="MediaState_NotCreated"/> hard
9389 disks, the returned value is zero.
9390 </note>
9391 </desc>
9392 </attribute>
9393
9394 <attribute name="autoReset" type="boolean">
9395 <desc>
9396 Whether this differencing hard disk will be automatically reset each
9397 time a virtual machine it is attached to is powered up.
9398
9399 See <link to="#reset()"/> for more information about resetting
9400 differencing hard disks.
9401
9402 <note>
9403 Reading this property on a base (non-differencing) hard disk will
9404 always <tt>false</tt>. Changing the value of this property in this
9405 case is not supported.
9406 </note>
9407
9408 <result name="VBOX_E_NOT_SUPPORTED">
9409 This is not a differencing hard disk (when changing the attribute
9410 value).
9411 </result>
9412 </desc>
9413 </attribute>
9414
9415 <!-- storage methods -->
9416
9417 <method name="getProperty">
9418 <desc>
9419 Returns the value of the custom hard disk property with the given name.
9420
9421 The list of all properties supported by the given hard disk format can
9422 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9423
9424 Note that if this method returns a <tt>null</tt> @a value, the requested
9425 property is supported but currently not assigned any value.
9426
9427 <result name="VBOX_E_OBJECT_NOT_FOUND">
9428 Requested property does not exist (not supported by the format).
9429 </result>
9430 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
9431 </desc>
9432 <param name="name" type="wstring" dir="in">
9433 <desc>Name of the property to get.</desc>
9434 </param>
9435 <param name="value" type="wstring" dir="return">
9436 <desc>Current property value.</desc>
9437 </param>
9438 </method>
9439
9440 <method name="setProperty">
9441 <desc>
9442 Sets the value of the custom hard disk property with the given name.
9443
9444 The list of all properties supported by the given hard disk format can
9445 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9446
9447 Note that setting the property value to <tt>null</tt> is equivalent to
9448 deleting the existing value. A default value (if it is defined for this
9449 property) will be used by the format backend in this case.
9450
9451 <result name="VBOX_E_OBJECT_NOT_FOUND">
9452 Requested property does not exist (not supported by the format).
9453 </result>
9454 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
9455 </desc>
9456 <param name="name" type="wstring" dir="in">
9457 <desc>Name of the property to set.</desc>
9458 </param>
9459 <param name="value" type="wstring" dir="in">
9460 <desc>Property value to set.</desc>
9461 </param>
9462 </method>
9463
9464 <method name="getProperties">
9465 <desc>
9466 Returns values for a group of properties in one call.
9467
9468 The names of the properties to get are specified using the @a names
9469 argument which is a list of comma-separated property names or
9470 <tt>null</tt> if all properties are to be returned. Note that currently
9471 the value of this argument is ignored and the method always returns all
9472 existing properties.
9473
9474 The list of all properties supported by the given hard disk format can
9475 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9476
9477 The method returns two arrays, the array of property names corresponding
9478 to the @a names argument and the current values of these properties.
9479 Both arrays have the same number of elements with each elemend at the
9480 given index in the first array corresponds to an element at the same
9481 index in the second array.
9482
9483 Note that for properties that do not have assigned values,
9484 <tt>null</tt> is returned at the appropriate index in the
9485 @a returnValues array.
9486
9487 </desc>
9488 <param name="names" type="wstring" dir="in">
9489 <desc>
9490 Names of properties to get.
9491 </desc>
9492 </param>
9493 <param name="returnNames" type="wstring" safearray="yes" dir="out">
9494 <desc>Names of returned properties.</desc>
9495 </param>
9496 <param name="returnValues" type="wstring" safearray="yes" dir="return">
9497 <desc>Values of returned properties.</desc>
9498 </param>
9499 </method>
9500
9501 <method name="setProperties">
9502 <desc>
9503 Sets values for a group of properties in one call.
9504
9505 The names of the properties to set are passed in the @a names
9506 array along with the new values for them in the @a values array. Both
9507 arrays have the same number of elements with each elemend at the given
9508 index in the first array corresponding to an element at the same index
9509 in the second array.
9510
9511 If there is at least one property name in @a names that is not valid,
9512 the method will fail before changing the values of any other properties
9513 from the @a names array.
9514
9515 Using this method over <link to="#setProperty"/> is preferred if you
9516 need to set several properties at once since it will result into less
9517 IPC calls.
9518
9519 The list of all properties supported by the given hard disk format can
9520 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
9521
9522 Note that setting the property value to <tt>null</tt> is equivalent to
9523 deleting the existing value. A default value (if it is defined for this
9524 property) will be used by the format backend in this case.
9525 </desc>
9526 <param name="names" type="wstring" safearray="yes" dir="in">
9527 <desc>Names of properties to set.</desc>
9528 </param>
9529 <param name="values" type="wstring" safearray="yes" dir="in">
9530 <desc>Values of properties to set.</desc>
9531 </param>
9532 </method>
9533
9534 <!-- storage methods -->
9535
9536 <method name="createBaseStorage">
9537 <desc>
9538 Starts creating a hard disk storage unit (fixed/dynamic, according
9539 to the variant flags) in in the background. The previous storage unit
9540 created for this object, if any, must first be deleted using
9541 <link to="#deleteStorage"/>, otherwise the operation will fail.
9542
9543 Before the operation starts, the hard disk is placed in
9544 <link to="MediaState_Creating"/> state. If the create operation
9545 fails, the media will be placed back in <link to="MediaState_NotCreated"/>
9546 state.
9547
9548 After the returned progress object reports that the operation has
9549 successfully completed, the media state will be set to <link
9550 to="MediaState_Created"/>, the hard disk will be remembered by this
9551 VirtualBox installation and may be attached to virtual machines.
9552
9553 <result name="VBOX_E_NOT_SUPPORTED">
9554 The variant of storage creation operation is not supported. See <link
9555 to="IHardDiskFormat::capabilities"/>.
9556 </result>
9557 </desc>
9558 <param name="logicalSize" type="unsigned long long" dir="in">
9559 <desc>Maximum logical size of the hard disk in megabytes.</desc>
9560 </param>
9561 <param name="variant" type="HardDiskVariant" dir="in">
9562 <desc>Exact image variant which should be created.</desc>
9563 </param>
9564 <param name="progress" type="IProgress" dir="return">
9565 <desc>Progress object to track the operation completion.</desc>
9566 </param>
9567 </method>
9568
9569 <method name="deleteStorage">
9570 <desc>
9571 Starts deleting the storage unit of this hard disk.
9572
9573 The hard disk must not be attached to any known virtual machine and must
9574 not have any known child hard disks, otherwise the operation will fail.
9575 It will also fail if there is no storage unit to delete or if deletion
9576 is already in progress, or if the hard disk is being in use (locked for
9577 read or for write) or inaccessible. Therefore, the only valid state for
9578 this operation to succeed is <link to="MediaState_Created"/>.
9579
9580 Before the operation starts, the hard disk is placed to
9581 <link to="MediaState_Deleting"/> state and gets removed from the list
9582 of remembered hard disks (media registry). If the delete operation
9583 fails, the media will be remembered again and placed back to
9584 <link to="MediaState_Created"/> state.
9585
9586 After the returned progress object reports that the operation is
9587 complete, the media state will be set to
9588 <link to="MediaState_NotCreated"/> and you will be able to use one of
9589 the storage creation methods to create it again.
9590
9591 <see>#close()</see>
9592
9593 <result name="VBOX_E_OBJECT_IN_USE">
9594 Hard disk is attached to a virtual machine.
9595 </result>
9596 <result name="VBOX_E_NOT_SUPPORTED">
9597 Storage deletion is not allowed because neither of storage creation
9598 operations are supported. See
9599 <link to="IHardDiskFormat::capabilities"/>.
9600 </result>
9601
9602 <note>
9603 If the deletion operation fails, it is not guaranteed that the storage
9604 unit still exists. You may check the <link to="IMedium::state"/> value
9605 to answer this question.
9606 </note>
9607 </desc>
9608 <param name="progress" type="IProgress" dir="return">
9609 <desc>Progress object to track the operation completion.</desc>
9610 </param>
9611 </method>
9612
9613 <!-- diff methods -->
9614
9615 <method name="createDiffStorage">
9616 <desc>
9617 Starts creating an empty differencing storage unit based on this hard
9618 disk in the format and at the location defined by the @a target
9619 argument.
9620
9621 The target hard disk must be in <link to="MediaState_NotCreated"/>
9622 state (i.e. must not have an existing storage unit). Upon successful
9623 completion, this operation will set the type of the target hard disk to
9624 <link to="HardDiskType_Normal"/> and create a storage unit necessary to
9625 represent the differencing hard disk data in the given format (according
9626 to the storage format of the target object).
9627
9628 After the returned progress object reports that the operation is
9629 successfully complete, the target hard disk gets remembered by this
9630 VirtualBox installation and may be attached to virtual machines.
9631
9632 <note>
9633 The hard disk will be set to <link to="MediaState_LockedRead"/>
9634 state for the duration of this operation.
9635 </note>
9636 <result name="VBOX_E_OBJECT_IN_USE">
9637 Hard disk not in NotCreated state.
9638 </result>
9639 </desc>
9640 <param name="target" type="IHardDisk" dir="in">
9641 <desc>Target hard disk.</desc>
9642 </param>
9643 <param name="variant" type="HardDiskVariant" dir="in">
9644 <desc>Exact image variant which should be created.</desc>
9645 </param>
9646 <param name="progress" type="IProgress" dir="return">
9647 <desc>Progress object to track the operation completion.</desc>
9648 </param>
9649 </method>
9650
9651 <method name="mergeTo">
9652 <desc>
9653 Starts merging the contents of this hard disk and all intermediate
9654 differencing hard disks in the chain to the given target hard disk.
9655
9656 The target hard disk must be either a descendant of this hard disk or
9657 its ancestor (otherwise this method will immediately return a failure).
9658 It follows that there are two logical directions of the merge operation:
9659 from ancestor to descendant (<i>forward merge</i>) and from descendant to
9660 ancestor (<i>backward merge</i>). Let us consider the following hard disk
9661 chain:
9662
9663 <pre>Base &lt;- Diff_1 &lt;- Diff_2</pre>
9664
9665 Here, calling this method on the <tt>Base</tt> hard disk object with
9666 <tt>Diff_2</tt> as an argument will be a forward merge; calling it on
9667 <tt>Diff_2</tt> with <tt>Base</tt> as an argument will be a backward
9668 merge. Note that in both cases the contents of the resulting hard disk
9669 will be the same, the only difference is the hard disk object that takes
9670 the result of the merge operation. In case of the forward merge in the
9671 above example, the result will be written to <tt>Diff_2</tt>; in case of
9672 the backward merge, the result will be written to <tt>Base</tt>. In
9673 other words, the result of the operation is always stored in the target
9674 hard disk.
9675
9676 Upon successful operation completion, the storage units of all hard
9677 disks in the chain between this (source) hard disk and the target hard
9678 disk, including the source hard disk itself, will be automatically
9679 deleted and the relevant hard disk objects (including this hard disk)
9680 will become uninitialized. This means that any attempt to call any of
9681 their methods or attributes will fail with the
9682 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error. Applied to the above
9683 example, the forward merge of <tt>Base</tt> to <tt>Diff_2</tt> will
9684 delete and uninitialize both <tt>Base</tt> and <tt>Diff_1</tt> hard
9685 disks. Note that <tt>Diff_2</tt> in this case will become a base hard
9686 disk itself since it will no longer be based on any other hard disk.
9687
9688 Considering the above, all of the following conditions must be met in
9689 order for the merge operation to succeed:
9690 <ul>
9691 <li>
9692 Neither this (source) hard disk nor any intermediate
9693 differencing hard disk in the chain between it and the target
9694 hard disk is attached to any virtual machine.
9695 </li>
9696 <li>
9697 Neither the source hard disk nor the target hard disk is an
9698 <link to="HardDiskType_Immutable"/> hard disk.
9699 </li>
9700 <li>
9701 The part of the hard disk tree from the source hard disk to the
9702 target hard disk is a linear chain, i.e. all hard disks in this
9703 chain have exactly one child which is the next hard disk in this
9704 chain. The only exception from this rule is the target hard disk in
9705 the forward merge operation; it is allowed to have any number of
9706 child hard disks because the merge operation will hot change its
9707 logical contents (as it is seen by the guest OS or by children).
9708 </li>
9709 <li>
9710 None of the involved hard disks are in
9711 <link to="MediaState_LockedRead"/> or
9712 <link to="MediaState_LockedWrite"/> state.
9713 </li>
9714 </ul>
9715
9716 <note>
9717 This (source) hard disk and all intermediates will be placed to <link
9718 to="MediaState_Deleting"/> state and the target hard disk will be
9719 placed to <link to="MediaState_LockedWrite"/> state and for the
9720 duration of this operation.
9721 </note>
9722 </desc>
9723 <param name="targetId" type="wstring" dir="in">
9724 <desc>UUID of the target ancestor or descendant hard disk.</desc>
9725 </param>
9726 <param name="progress" type="IProgress" dir="return">
9727 <desc>Progress object to track the operation completion.</desc>
9728 </param>
9729 </method>
9730
9731 <!-- clone method -->
9732
9733 <method name="cloneTo">
9734 <desc>
9735 Starts creating a clone of this hard disk in the format and at the
9736 location defined by the @a target argument.
9737
9738 The target hard disk must be in <link to="MediaState_NotCreated"/>
9739 state (i.e. must not have an existing storage unit). Upon successful
9740 completion, the cloned hard disk will contain exactly the same sector
9741 data as the hard disk being cloned, except that a new UUID for the
9742 clone will be randomly generated.
9743
9744 The @a parent argument defines which hard disk will be the parent
9745 of the clone. Passing a NULL reference indicates that the clone will
9746 be a base image, i.e. completely independent. It is possible to specify
9747 an arbitrary hard disk for this parameter, including the parent of the
9748 hard disk which is being cloned. Even cloning to a child of the source
9749 hard disk is possible.
9750
9751 After the returned progress object reports that the operation is
9752 successfully complete, the target hard disk gets remembered by this
9753 VirtualBox installation and may be attached to virtual machines.
9754
9755 <note>
9756 This hard disk will be placed to <link to="MediaState_LockedRead"/>
9757 state for the duration of this operation.
9758 </note>
9759 </desc>
9760 <param name="target" type="IHardDisk" dir="in">
9761 <desc>Target hard disk.</desc>
9762 </param>
9763 <param name="variant" type="HardDiskVariant" dir="in">
9764 <desc>Exact image variant which should be created.</desc>
9765 </param>
9766 <param name="parent" type="IHardDisk" dir="in">
9767 <desc>Parent of the cloned hard disk.</desc>
9768 </param>
9769 <param name="progress" type="IProgress" dir="return">
9770 <desc>Progress object to track the operation completion.</desc>
9771 </param>
9772 </method>
9773
9774 <!-- other methods -->
9775
9776 <method name="compact">
9777 <desc>
9778 Starts compacting of this hard disk. This means that the disk is
9779 transformed into a possibly more compact storage representation.
9780 This potentially creates temporary images, which can require a
9781 substantial amount of additional disk space.
9782
9783 This hard disk will be placed to <link to="MediaState_LockedWrite"/>
9784 state and all its parent hard disks (if any) will be placed to
9785 <link to="MediaState_LockedRead"/> state for the duration of this
9786 operation.
9787
9788 Please note that the results can be either returned straight away,
9789 or later as the result of the background operation via the object
9790 returned via the @a progress parameter.
9791
9792 <result name="VBOX_E_NOT_SUPPORTED">
9793 Hard disk format does not support compacting (but potentially
9794 needs it).
9795 </result>
9796 </desc>
9797 <param name="progress" type="IProgress" dir="return">
9798 <desc>Progress object to track the operation completion.</desc>
9799 </param>
9800 </method>
9801
9802 <method name="reset">
9803 <desc>
9804 Starts erasing the contents of this differencing hard disk.
9805
9806 This operation will reset the differencing hard disk to its initial
9807 state when it does not contain any sector data and any read operation is
9808 redirected to its parent hard disk.
9809
9810 This hard disk will be placed to <link to="MediaState_LockedWrite"/>
9811 for the duration of this operation.
9812
9813 <result name="VBOX_E_NOT_SUPPORTED">
9814 This is not a differencing hard disk.
9815 </result>
9816 <result name="VBOX_E_INVALID_OBJECT_STATE">
9817 Hard disk is not in <link to="MediaState_Created"/> or
9818 <link to="MediaState_Inaccessible"/> state.
9819 </result>
9820 </desc>
9821 <param name="progress" type="IProgress" dir="return">
9822 <desc>Progress object to track the operation completion.</desc>
9823 </param>
9824 </method>
9825
9826 </interface>
9827
9828
9829 <!--
9830 // IHardDiskFormat
9831 /////////////////////////////////////////////////////////////////////////
9832 -->
9833
9834 <enum
9835 name="DataType"
9836 uuid="d90ea51e-a3f1-4a01-beb1-c1723c0d3ba7"
9837 >
9838 <const name="Int32" value="0"/>
9839 <const name="Int8" value="1"/>
9840 <const name="String" value="2"/>
9841 </enum>
9842
9843 <enum
9844 name="DataFlags"
9845 uuid="86884dcf-1d6b-4f1b-b4bf-f5aa44959d60"
9846 >
9847 <const name="None" value="0x00"/>
9848 <const name="Mandatory" value="0x01"/>
9849 <const name="Expert" value="0x02"/>
9850 <const name="Array" value="0x04"/>
9851 <const name="FlagMask" value="0x07"/>
9852 </enum>
9853
9854 <enum
9855 name="HardDiskFormatCapabilities"
9856 uuid="1df1e4aa-d25a-4ba6-b2a2-02f60eb5903b"
9857 >
9858 <desc>
9859 Hard disk format capability flags.
9860 </desc>
9861
9862 <const name="Uuid" value="0x01">
9863 <desc>
9864 Supports UUIDs as expected by VirtualBox code.
9865 </desc>
9866 </const>
9867
9868 <const name="CreateFixed" value="0x02">
9869 <desc>
9870 Supports creating fixed size images, allocating all space instantly.
9871 </desc>
9872 </const>
9873
9874 <const name="CreateDynamic" value="0x04">
9875 <desc>
9876 Supports creating dynamically growing images, allocating space on
9877 demand.
9878 </desc>
9879 </const>
9880
9881 <const name="CreateSplit2G" value="0x08">
9882 <desc>
9883 Supports creating images split in chunks of a bit less than 2 GBytes.
9884 </desc>
9885 </const>
9886
9887 <const name="Differencing" value="0x10">
9888 <desc>
9889 Supports being used as a format for differencing hard disks (see <link
9890 to="IHardDisk::createDiffStorage"/>).
9891 </desc>
9892 </const>
9893
9894 <const name="Asynchronous" value="0x20">
9895 <desc>
9896 Supports asynchronous I/O operations for at least some configurations.
9897 </desc>
9898 </const>
9899
9900 <const name="File" value="0x40">
9901 <desc>
9902 The format backend operates on files (the <link to="IMedium::location"/>
9903 attribute of the hard disk specifies a file used to store hard disk
9904 data; for a list of supported file extensions see
9905 <link to="IHardDiskFormat::fileExtensions"/>).
9906 </desc>
9907 </const>
9908
9909 <const name="Properties" value="0x80">
9910 <desc>
9911 The format backend uses the property interface to configure the storage
9912 location and properties (the <link to="IHardDiskFormat::describeProperties"/>
9913 method is used to get access to properties supported by the given hard
9914 disk format).
9915 </desc>
9916 </const>
9917
9918 <const name="CapabilityMask" value="0xFF"/>
9919 </enum>
9920
9921 <interface
9922 name="IHardDiskFormat" extends="$unknown"
9923 uuid="7f3ba790-3a0b-4a8a-bac2-bb50150123c5"
9924 wsmap="managed"
9925 >
9926 <desc>
9927 The IHardDiskFormat interface represents a virtual hard disk format.
9928
9929 Each hard disk format has an associated backend which is used to handle
9930 hard disks stored in this format. This interface provides information
9931 about the properties of the associated backend.
9932
9933 Each hard disk format is identified by a string represented by the
9934 <link to="#id"/> attribute. This string is used in calls like
9935 <link to="IVirtualBox::createHardDisk"/> to specify the desired
9936 format.
9937
9938 The list of all supported hard disk formats can be obtained using
9939 <link to="ISystemProperties::hardDiskFormats"/>.
9940
9941 <see>IHardDisk</see>
9942 </desc>
9943
9944 <attribute name="id" type="wstring" readonly="yes">
9945 <desc>
9946 Identifier of this format.
9947
9948 The format identifier is a non-null non-empty ASCII string. Note that
9949 this string is case-insensitive. This means that, for example, all of
9950 the following strings:
9951 <pre>
9952 "VDI"
9953 "vdi"
9954 "VdI"</pre>
9955 refer to the same hard disk format.
9956
9957 This string is used in methods of other interfaces where it is necessary
9958 to specify a hard disk format, such as
9959 <link to="IVirtualBox::createHardDisk"/>.
9960 </desc>
9961 </attribute>
9962
9963 <attribute name="name" type="wstring" readonly="yes">
9964 <desc>
9965 Human readable description of this format.
9966
9967 Mainly for use in file open dialogs.
9968 </desc>
9969 </attribute>
9970
9971 <attribute name="fileExtensions" type="wstring" safearray="yes" readonly="yes">
9972 <desc>
9973 Array of strings containing the supported file extensions.
9974
9975 The first extension in the array is the extension preferred by the
9976 backend. It is recommended to use this extension when specifying a
9977 location of the storage unit for a new hard disk.
9978
9979 Note that some backends do not work on files, so this array may be
9980 empty.
9981
9982 <see>IHardDiskFormat::capabilities</see>
9983 </desc>
9984 </attribute>
9985
9986 <attribute name="capabilities" type="unsigned long" readonly="yes">
9987 <desc>
9988 Capabilities of the format as a set of bit flags.
9989
9990 For the meaning of individual capability flags see
9991 <link to="HardDiskFormatCapabilities"/>.
9992 </desc>
9993 </attribute>
9994
9995 <method name="describeProperties">
9996 <desc>
9997 Returns several arrays describing the properties supported by this
9998 format.
9999
10000 An element with the given index in each array describes one
10001 property. Thus, the number of elements in each returned array is the
10002 same and corresponds to the number of supported properties.
10003
10004 The returned arrays are filled in only if the
10005 <link to="HardDiskFormatCapabilities_Properties"/> flag is set.
10006 All arguments must be non-NULL.
10007
10008 <see>DataType</see>
10009 <see>DataFlags</see>
10010 </desc>
10011
10012 <param name="names" type="wstring" safearray="yes" dir="out">
10013 <desc>Array of property names.</desc>
10014 </param>
10015 <param name="description" type="wstring" safearray="yes" dir="out">
10016 <desc>Array of property descriptions.</desc>
10017 </param>
10018 <param name="types" type="DataType" safearray="yes" dir="out">
10019 <desc>Array of property types.</desc>
10020 </param>
10021 <param name="flags" type="unsigned long" safearray="yes" dir="out">
10022 <desc>Array of property flags.</desc>
10023 </param>
10024 <param name="defaults" type="wstring" safearray="yes" dir="out">
10025 <desc>Array of default property values.</desc>
10026 </param>
10027 </method>
10028
10029 </interface>
10030
10031
10032 <!--
10033 // IFloppyImage
10034 /////////////////////////////////////////////////////////////////////////
10035 -->
10036
10037 <interface
10038 name="IFloppyImage" extends="IMedium"
10039 uuid="faa6101f-078c-4b3a-ab75-75670c8170b3"
10040 wsmap="managed"
10041 >
10042 <desc>
10043 The IFloppyImage interface represents a medium containing the image
10044 of a floppy disk. This is a subclass of <link to="IMedium" />; see remarks there.
10045 </desc>
10046
10047 </interface>
10048
10049
10050 <!--
10051 // IDVDImage
10052 /////////////////////////////////////////////////////////////////////////
10053 -->
10054
10055 <interface
10056 name="IDVDImage" extends="IMedium"
10057 uuid="b1f90bbb-e8a9-4484-9af1-3638e943f763"
10058 wsmap="managed"
10059 >
10060 <desc>
10061 The IDVDImage interface represents a medium containing the image
10062 of a CD or DVD disk in the ISO format.
10063
10064 This is a subclass of <link to="IMedium" />; see remarks there.
10065 </desc>
10066
10067 </interface>
10068
10069
10070 <!--
10071 // IDVDDrive
10072 /////////////////////////////////////////////////////////////////////////
10073 -->
10074
10075 <interface
10076 name="IDVDDrive" extends="$unknown"
10077 uuid="156944d1-4c6d-4812-8f12-ab3890767ab4"
10078 wsmap="managed"
10079 >
10080 <desc>
10081 The IDVDDrive interface represents the virtual CD/DVD drive of the
10082 virtual machine. An object of this type is returned by
10083 <link to="IMachine::DVDDrive"/>.
10084 </desc>
10085
10086 <attribute name="state" type="DriveState" readonly="yes">
10087 <desc>Current drive state.</desc>
10088 </attribute>
10089
10090 <attribute name="passthrough" type="boolean">
10091 <desc>
10092 When a host drive is mounted and passthrough is enabled
10093 the guest OS will be able to directly send SCSI commands to
10094 the host drive. This enables the guest OS to use CD/DVD writers
10095 but is potentially dangerous.
10096 </desc>
10097 </attribute>
10098
10099 <method name="mountImage">
10100 <desc>Mounts a CD/DVD image with the specified UUID.
10101
10102 <result name="VBOX_E_FILE_ERROR">
10103 Invalid image file location.
10104 </result>
10105 <result name="VBOX_E_OBJECT_NOT_FOUND">
10106 Could not find a CD/DVD image matching @a imageId.
10107 </result>
10108 <result name="VBOX_E_INVALID_OBJECT_STATE">
10109 Invalid media state.
10110 </result>
10111
10112 </desc>
10113 <param name="imageId" type="wstring" dir="in"/>
10114 </method>
10115
10116 <method name="captureHostDrive">
10117 <desc>Captures the specified host CD/DVD drive.</desc>
10118 <param name="drive" type="IHostDVDDrive" dir="in"/>
10119 </method>
10120
10121 <method name="unmount">
10122 <desc>Unmounts the currently mounted image or host drive.</desc>
10123 </method>
10124
10125 <method name="getImage">
10126 <desc>Returns the currently mounted CD/DVD image.</desc>
10127 <param name="image" type="IDVDImage" dir="return"/>
10128 </method>
10129
10130 <method name="getHostDrive">
10131 <desc>Returns the currently mounted host CD/DVD drive.</desc>
10132 <param name="drive" type="IHostDVDDrive" dir="return"/>
10133 </method>
10134
10135 </interface>
10136
10137
10138 <!--
10139 // IFloppyDrive
10140 /////////////////////////////////////////////////////////////////////////
10141 -->
10142
10143 <interface
10144 name="IFloppyDrive" extends="$unknown"
10145 uuid="a8676d38-5cf0-4b53-85b1-aa693611ab86"
10146 wsmap="managed"
10147 >
10148 <desc>
10149 The IFloppyDrive interface represents the virtual floppy drive of the
10150 virtual machine. An object of this type is returned by
10151 <link to="IMachine::floppyDrive" />.
10152 </desc>
10153
10154 <attribute name="enabled" type="boolean">
10155 <desc>
10156 Flag whether the floppy drive is enabled. If it is disabled,
10157 the floppy drive will not be reported to the guest OS.
10158 </desc>
10159 </attribute>
10160
10161 <attribute name="state" type="DriveState" readonly="yes">
10162 <desc>Current drive state.</desc>
10163 </attribute>
10164
10165 <method name="mountImage">
10166 <desc>Mounts a floppy image with the specified UUID.
10167
10168 <result name="VBOX_E_FILE_ERROR">
10169 Invalid image file location.
10170 </result>
10171 <result name="VBOX_E_OBJECT_NOT_FOUND">
10172 Could not find a floppy image matching @a imageID.
10173 </result>
10174 <result name="VBOX_E_INVALID_OBJECT_STATE">
10175 Invalid media state.
10176 </result>
10177
10178 </desc>
10179 <param name="imageId" type="wstring" dir="in"/>
10180 </method>
10181
10182 <method name="captureHostDrive">
10183 <desc>Captures the specified host floppy drive.</desc>
10184 <param name="drive" type="IHostFloppyDrive" dir="in"/>
10185 </method>
10186
10187 <method name="unmount">
10188 <desc>Unmounts the currently mounted image or host drive.</desc>
10189 </method>
10190
10191 <method name="getImage">
10192 <desc>Returns the currently mounted floppy image.</desc>
10193 <param name="image" type="IFloppyImage" dir="return"/>
10194 </method>
10195
10196 <method name="getHostDrive">
10197 <desc>Returns the currently mounted host floppy drive.</desc>
10198 <param name="drive" type="IHostFloppyDrive" dir="return"/>
10199 </method>
10200
10201 </interface>
10202
10203
10204 <!--
10205 // IKeyboard
10206 /////////////////////////////////////////////////////////////////////////
10207 -->
10208
10209 <interface
10210 name="IKeyboard" extends="$unknown"
10211 uuid="2d1a531b-4c6e-49cc-8af6-5c857b78b5d7"
10212 wsmap="managed"
10213 >
10214 <desc>
10215 The IKeyboard interface represents the virtual machine's keyboard. Used
10216 in <link to="IConsole::keyboard"/>.
10217
10218 Use this interface to send keystrokes or the Ctrl-Alt-Del sequence
10219 to the virtual machine.
10220
10221 </desc>
10222 <method name="putScancode">
10223 <desc>Sends a scancode to the keyboard.
10224
10225 <result name="VBOX_E_IPRT_ERROR">
10226 Could not send scan code to virtual keyboard.
10227 </result>
10228
10229 </desc>
10230 <param name="scancode" type="long" dir="in"/>
10231 </method>
10232
10233 <method name="putScancodes">
10234 <desc>Sends an array of scancodes to the keyboard.
10235
10236 <result name="VBOX_E_IPRT_ERROR">
10237 Could not send all scan codes to virtual keyboard.
10238 </result>
10239
10240 </desc>
10241 <param name="scancodes" type="long" dir="in" safearray="yes"/>
10242 <param name="codesStored" type="unsigned long" dir="return"/>
10243 </method>
10244
10245 <method name="putCAD">
10246 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard. This
10247 function is nothing special, it is just a convenience function
10248 calling <link to="IKeyboard::putScancodes"/> with the proper scancodes.
10249
10250 <result name="VBOX_E_IPRT_ERROR">
10251 Could not send all scan codes to virtual keyboard.
10252 </result>
10253
10254 </desc>
10255 </method>
10256
10257 </interface>
10258
10259
10260 <!--
10261 // IMouse
10262 /////////////////////////////////////////////////////////////////////////
10263 -->
10264
10265 <enum
10266 name="MouseButtonState"
10267 uuid="03131722-2EC5-4173-9794-0DACA46673EF"
10268 >
10269 <desc>
10270 Mouse button state.
10271 </desc>
10272
10273 <const name="LeftButton" value="0x01"/>
10274 <const name="RightButton" value="0x02"/>
10275 <const name="MiddleButton" value="0x04"/>
10276 <const name="WheelUp" value="0x08"/>
10277 <const name="WheelDown" value="0x10"/>
10278 <const name="MouseStateMask" value="0x1F"/>
10279 </enum>
10280
10281 <interface
10282 name="IMouse" extends="$unknown"
10283 uuid="FD443EC1-0006-4F5B-9282-D72760A66916"
10284 wsmap="managed"
10285 >
10286 <desc>
10287 The IMouse interface represents the virtual machine's mouse. Used in
10288 <link to="IConsole::mouse"/>.
10289
10290 Through this interface, the virtual machine's virtual mouse can be
10291 controlled.
10292 </desc>
10293
10294 <attribute name="absoluteSupported" type="boolean" readonly="yes">
10295 <desc>
10296 Whether the guest OS supports absolute mouse pointer positioning
10297 or not.
10298 <note>
10299 VirtualBox Guest Tools need to be installed to the guest OS
10300 in order to enable absolute mouse positioning support.
10301 You can use the <link to="IConsoleCallback::onMouseCapabilityChange"/>
10302 callback to be instantly informed about changes of this attribute
10303 during virtual machine execution.
10304 </note>
10305 <see><link to="#putMouseEventAbsolute"/></see>
10306 </desc>
10307 </attribute>
10308
10309 <method name="putMouseEvent">
10310 <desc>
10311 Initiates a mouse event using relative pointer movements
10312 along x and y axis.
10313
10314 <result name="E_ACCESSDENIED">
10315 Console not powered up.
10316 </result>
10317 <result name="VBOX_E_IPRT_ERROR">
10318 Could not send mouse event to virtual mouse.
10319 </result>
10320
10321 </desc>
10322
10323 <param name="dx" type="long" dir="in">
10324 <desc>
10325 Amount of pixels the mouse should move to the right.
10326 Negative values move the mouse to the left.
10327 </desc>
10328 </param>
10329 <param name="dy" type="long" dir="in">
10330 <desc>
10331 Amount of pixels the mouse should move downwards.
10332 Negative values move the mouse upwards.
10333 </desc>
10334 </param>
10335 <param name="dz" type="long" dir="in">
10336 <desc>
10337 Amount of mouse wheel moves.
10338 Positive values describe clockwise wheel rotations,
10339 negative values describe counterclockwise rotations.
10340 </desc>
10341 </param>
10342 <param name="buttonState" type="long" dir="in">
10343 <desc>
10344 The current state of mouse buttons. Every bit represents
10345 a mouse button as follows:
10346 <table>
10347 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10348 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10349 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10350 </table>
10351 A value of <tt>1</tt> means the corresponding button is pressed.
10352 otherwise it is released.
10353 </desc>
10354 </param>
10355 </method>
10356
10357 <method name="putMouseEventAbsolute">
10358 <desc>
10359 Positions the mouse pointer using absolute x and y coordinates.
10360 These coordinates are expressed in pixels and
10361 start from <tt>[1,1]</tt> which corresponds to the top left
10362 corner of the virtual display.
10363
10364 <result name="E_ACCESSDENIED">
10365 Console not powered up.
10366 </result>
10367 <result name="VBOX_E_IPRT_ERROR">
10368 Could not send mouse event to virtual mouse.
10369 </result>
10370
10371 <note>
10372 This method will have effect only if absolute mouse
10373 positioning is supported by the guest OS.
10374 </note>
10375
10376 <see><link to="#absoluteSupported"/></see>
10377 </desc>
10378
10379 <param name="x" type="long" dir="in">
10380 <desc>
10381 X coordinate of the pointer in pixels, starting from <tt>1</tt>.
10382 </desc>
10383 </param>
10384 <param name="y" type="long" dir="in">
10385 <desc>
10386 Y coordinate of the pointer in pixels, starting from <tt>1</tt>.
10387 </desc>
10388 </param>
10389 <param name="dz" type="long" dir="in">
10390 <desc>
10391 Amount of mouse wheel moves.
10392 Positive values describe clockwise wheel rotations,
10393 negative values describe counterclockwise rotations.
10394 </desc>
10395 </param>
10396 <param name="buttonState" type="long" dir="in">
10397 <desc>
10398 The current state of mouse buttons. Every bit represents
10399 a mouse button as follows:
10400 <table>
10401 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
10402 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
10403 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
10404 </table>
10405 A value of <tt>1</tt> means the corresponding button is pressed.
10406 otherwise it is released.
10407 </desc>
10408 </param>
10409 </method>
10410
10411 </interface>
10412
10413 <!--
10414 // IDisplay
10415 /////////////////////////////////////////////////////////////////////////
10416 -->
10417
10418 <enum
10419 name="FramebufferPixelFormat"
10420 uuid="7acfd5ed-29e3-45e3-8136-73c9224f3d2d"
10421 >
10422 <desc>
10423 Format of the video memory buffer. Constants represented by this enum can
10424 be used to test for particular values of <link
10425 to="IFramebuffer::pixelFormat"/>. See also <link
10426 to="IFramebuffer::requestResize"/>.
10427
10428 See also www.fourcc.org for more information about FOURCC pixel formats.
10429 </desc>
10430
10431 <const name="Opaque" value="0">
10432 <desc>
10433 Unknown buffer format (the user may not assume any particular format of
10434 the buffer).
10435 </desc>
10436 </const>
10437 <const name="FOURCC_RGB" value="0x32424752">
10438 <desc>
10439 Basic RGB format (<link to="IFramebuffer::bitsPerPixel"/> determines the
10440 bit layout).
10441 </desc>
10442 </const>
10443 </enum>
10444
10445 <interface
10446 name="IFramebuffer" extends="$unknown"
10447 uuid="b7ed347a-5765-40a0-ae1c-f543eb4ddeaf"
10448 wsmap="suppress"
10449 >
10450 <attribute name="address" type="octet" mod="ptr" readonly="yes">
10451 <desc>Address of the start byte of the frame buffer.</desc>
10452 </attribute>
10453
10454 <attribute name="width" type="unsigned long" readonly="yes">
10455 <desc>Frame buffer width, in pixels.</desc>
10456 </attribute>
10457
10458 <attribute name="height" type="unsigned long" readonly="yes">
10459 <desc>Frame buffer height, in pixels.</desc>
10460 </attribute>
10461
10462 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10463 <desc>
10464 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
10465 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, valid values
10466 are: 8, 15, 16, 24 and 32.
10467 </desc>
10468 </attribute>
10469
10470 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
10471 <desc>
10472 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
10473 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, the
10474 size of the scan line must be aligned to 32 bits.
10475 </desc>
10476 </attribute>
10477
10478 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
10479 <desc>
10480 Frame buffer pixel format. It's either one of the values defined by <link
10481 to="FramebufferPixelFormat"/> or a raw FOURCC code.
10482 <note>
10483 This attribute must never return <link
10484 to="FramebufferPixelFormat_Opaque"/> -- the format of the buffer
10485 <link to="#address"/> points to must be always known.
10486 </note>
10487 </desc>
10488 </attribute>
10489
10490 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
10491 <desc>
10492 Defines whether this frame buffer uses the virtual video card's memory
10493 buffer (guest VRAM) directly or not. See <link
10494 to="IFramebuffer::requestResize"/> for more information.
10495 </desc>
10496 </attribute>
10497
10498 <attribute name="heightReduction" type="unsigned long" readonly="yes">
10499 <desc>
10500 Hint from the frame buffer about how much of the standard
10501 screen height it wants to use for itself. This information is
10502 exposed to the guest through the VESA BIOS and VMMDev interface
10503 so that it can use it for determining its video mode table. It
10504 is not guaranteed that the guest respects the value.
10505 </desc>
10506 </attribute>
10507
10508 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
10509 <desc>
10510 An alpha-blended overlay which is superposed over the frame buffer.
10511 The initial purpose is to allow the display of icons providing
10512 information about the VM state, including disk activity, in front
10513 ends which do not have other means of doing that. The overlay is
10514 designed to controlled exclusively by IDisplay. It has no locking
10515 of its own, and any changes made to it are not guaranteed to be
10516 visible until the affected portion of IFramebuffer is updated. The
10517 overlay can be created lazily the first time it is requested. This
10518 attribute can also return NULL to signal that the overlay is not
10519 implemented.
10520 </desc>
10521 </attribute>
10522
10523 <attribute name="winId" type="unsigned long long" readonly="yes">
10524 <desc>
10525 Platform-dependent identifier of the window where context of this
10526 frame buffer is drawn, or zero if there's no such window.
10527 </desc>
10528 </attribute>
10529
10530 <method name="lock">
10531 <desc>
10532 Locks the frame buffer.
10533 Gets called by the IDisplay object where this frame buffer is
10534 bound to.
10535 </desc>
10536 </method>
10537
10538 <method name="unlock">
10539 <desc>
10540 Unlocks the frame buffer.
10541 Gets called by the IDisplay object where this frame buffer is
10542 bound to.
10543 </desc>
10544 </method>
10545
10546 <method name="notifyUpdate">
10547 <desc>
10548 Informs about an update.
10549 Gets called by the display object where this buffer is
10550 registered.
10551 </desc>
10552 <param name="x" type="unsigned long" dir="in"/>
10553 <param name="y" type="unsigned long" dir="in"/>
10554 <param name="width" type="unsigned long" dir="in"/>
10555 <param name="height" type="unsigned long" dir="in"/>
10556 </method>
10557
10558 <method name="requestResize">
10559 <desc>
10560 Requests a size and pixel format change.
10561
10562 There are two modes of working with the video buffer of the virtual
10563 machine. The <i>indirect</i> mode implies that the IFramebuffer
10564 implementation allocates a memory buffer for the requested display mode
10565 and provides it to the virtual machine. In <i>direct</i> mode, the
10566 IFramebuffer implementation uses the memory buffer allocated and owned
10567 by the virtual machine. This buffer represents the video memory of the
10568 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
10569 usually faster because the implementation gets a raw pointer to the
10570 guest VRAM buffer which it can directly use for visualizing the contents
10571 of the virtual display, as opposed to the indirect mode where the
10572 contents of guest VRAM are copied to the memory buffer provided by
10573 the implementation every time a display update occurs.
10574
10575 It is important to note that the direct mode is really fast only when
10576 the implementation uses the given guest VRAM buffer directly, for
10577 example, by blitting it to the window representing the virtual machine's
10578 display, which saves at least one copy operation comparing to the
10579 indirect mode. However, using the guest VRAM buffer directly is not
10580 always possible: the format and the color depth of this buffer may be
10581 not supported by the target window, or it may be unknown (opaque) as in
10582 case of text or non-linear multi-plane VGA video modes. In this case,
10583 the indirect mode (that is always available) should be used as a
10584 fallback: when the guest VRAM contents are copied to the
10585 implementation-provided memory buffer, color and format conversion is
10586 done automatically by the underlying code.
10587
10588 The @a pixelFormat parameter defines whether the direct mode is
10589 available or not. If @a pixelFormat is <link
10590 to="FramebufferPixelFormat_Opaque"/> then direct access to the guest
10591 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and
10592 @a bytesPerLine parameters must be ignored and the implementation must use
10593 the indirect mode (where it provides its own buffer in one of the
10594 supported formats). In all other cases, @a pixelFormat together with
10595 @a bitsPerPixel and @a bytesPerLine define the format of the video memory
10596 buffer pointed to by the @a VRAM parameter and the implementation is
10597 free to choose which mode to use. To indicate that this frame buffer uses
10598 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
10599 attribute must return <tt>true</tt> and <link to="#address"/> must
10600 return exactly the same address that is passed in the @a VRAM parameter
10601 of this method; otherwise it is assumed that the indirect strategy is
10602 chosen.
10603
10604 The @a width and @a height parameters represent the size of the
10605 requested display mode in both modes. In case of indirect mode, the
10606 provided memory buffer should be big enough to store data of the given
10607 display mode. In case of direct mode, it is guaranteed that the given
10608 @a VRAM buffer contains enough space to represent the display mode of the
10609 given size. Note that this frame buffer's <link to="#width"/> and <link
10610 to="#height"/> attributes must return exactly the same values as
10611 passed to this method after the resize is completed (see below).
10612
10613 The @a finished output parameter determines if the implementation has
10614 finished resizing the frame buffer or not. If, for some reason, the
10615 resize cannot be finished immediately during this call, @a finished
10616 must be set to @c false, and the implementation must call
10617 <link to="IDisplay::resizeCompleted"/> after it has returned from
10618 this method as soon as possible. If @a finished is @c false, the
10619 machine will not call any frame buffer methods until
10620 <link to="IDisplay::resizeCompleted"/> is called.
10621
10622 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
10623 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
10624 this frame buffer must return exactly the same values as specified in the
10625 parameters of this method, after the resize is completed. If the
10626 indirect mode is chosen, these attributes must return values describing
10627 the format of the implementation's own memory buffer <link
10628 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
10629 value must always correlate with <link to="#pixelFormat"/>. Note that
10630 the <link to="#pixelFormat"/> attribute must never return <link
10631 to="FramebufferPixelFormat_Opaque"/> regardless of the selected mode.
10632
10633 <note>
10634 This method is called by the IDisplay object under the
10635 <link to="#lock"/> provided by this IFramebuffer
10636 implementation. If this method returns @c false in @a finished, then
10637 this lock is not released until
10638 <link to="IDisplay::resizeCompleted"/> is called.
10639 </note>
10640 </desc>
10641 <param name="screenId" type="unsigned long" dir="in">
10642 <desc>
10643 Logical screen number. Must be used in the corresponding call to
10644 <link to="IDisplay::resizeCompleted"/> if this call is made.
10645 </desc>
10646 </param>
10647 <param name="pixelFormat" type="unsigned long" dir="in">
10648 <desc>
10649 Pixel format of the memory buffer pointed to by @a VRAM.
10650 See also <link to="FramebufferPixelFormat"/>.
10651 </desc>
10652 </param>
10653 <param name="VRAM" type="octet" mod="ptr" dir="in">
10654 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
10655 </param>
10656 <param name="bitsPerPixel" type="unsigned long" dir="in">
10657 <desc>Color depth, bits per pixel.</desc>
10658 </param>
10659 <param name="bytesPerLine" type="unsigned long" dir="in">
10660 <desc>Size of one scan line, in bytes.</desc>
10661 </param>
10662 <param name="width" type="unsigned long" dir="in">
10663 <desc>Width of the guest display, in pixels.</desc>
10664 </param>
10665 <param name="height" type="unsigned long" dir="in">
10666 <desc>Height of the guest display, in pixels.</desc>
10667 </param>
10668 <param name="finished" type="boolean" dir="return">
10669 <desc>
10670 Can the VM start using the new frame buffer immediately
10671 after this method returns or it should wait for
10672 <link to="IDisplay::resizeCompleted"/>.
10673 </desc>
10674 </param>
10675 </method>
10676
10677 <method name="videoModeSupported">
10678 <desc>
10679 Returns whether the frame buffer implementation is willing to
10680 support a given video mode. In case it is not able to render
10681 the video mode (or for some reason not willing), it should
10682 return false. Usually this method is called when the guest
10683 asks the VMM device whether a given video mode is supported
10684 so the information returned is directly exposed to the guest.
10685 It is important that this method returns very quickly.
10686 </desc>
10687 <param name="width" type="unsigned long" dir="in"/>
10688 <param name="height" type="unsigned long" dir="in"/>
10689 <param name="bpp" type="unsigned long" dir="in"/>
10690 <param name="supported" type="boolean" dir="return"/>
10691 </method>
10692
10693 <method name="getVisibleRegion">
10694 <desc>
10695 Returns the visible region of this frame buffer.
10696
10697 If the @a rectangles parameter is <tt>NULL</tt> then the value of the
10698 @a count parameter is ignored and the number of elements necessary to
10699 describe the current visible region is returned in @a countCopied.
10700
10701 If @a rectangles is not <tt>NULL</tt> but @a count is less
10702 than the required number of elements to store region data, the method
10703 will report a failure. If @a count is equal or greater than the
10704 required number of elements, then the actual number of elements copied
10705 to the provided array will be returned in @a countCopied.
10706
10707 <note>
10708 The address of the provided array must be in the process space of
10709 this IFramebuffer object.
10710 </note>
10711 <note>
10712 Method not yet implemented.
10713 </note>
10714 </desc>
10715 <param name="rectangles" type="octet" mod="ptr" dir="in">
10716 <desc>Pointer to the <tt>RTRECT</tt> array to receive region data.</desc>
10717 </param>
10718 <param name="count" type="unsigned long" dir="in">
10719 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10720 </param>
10721 <param name="countCopied" type="unsigned long" dir="return">
10722 <desc>Number of elements copied to the @a rectangles array.</desc>
10723 </param>
10724 </method>
10725
10726 <method name="setVisibleRegion">
10727 <desc>
10728 Suggests a new visible region to this frame buffer. This region
10729 represents the area of the VM display which is a union of regions of
10730 all top-level windows of the guest operating system running inside the
10731 VM (if the Guest Additions for this system support this
10732 functionality). This information may be used by the frontends to
10733 implement the seamless desktop integration feature.
10734
10735 <note>
10736 The address of the provided array must be in the process space of
10737 this IFramebuffer object.
10738 </note>
10739 <note>
10740 The IFramebuffer implementation must make a copy of the provided
10741 array of rectangles.
10742 </note>
10743 <note>
10744 Method not yet implemented.
10745 </note>
10746 </desc>
10747 <param name="rectangles" type="octet" mod="ptr" dir="in">
10748 <desc>Pointer to the <tt>RTRECT</tt> array.</desc>
10749 </param>
10750 <param name="count" type="unsigned long" dir="in">
10751 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10752 </param>
10753 </method>
10754
10755 <method name="processVHWACommand">
10756 <desc>
10757 Posts a Video HW Acceleration Command to the frame buffer for processing.
10758 The commands used for 2D video acceleration (DDraw surface creation/destroying, blitting, scaling, color covnersion, overlaying, etc.)
10759 are posted from quest to the host to be processed by the host hardware.
10760
10761 <note>
10762 The address of the provided command must be in the process space of
10763 this IFramebuffer object.
10764 </note>
10765 </desc>
10766
10767 <param name="command" type="octet" mod="ptr" dir="in">
10768 <desc>Pointer to VBOXVHWACMD containing the command to execute.</desc>
10769 </param>
10770 </method>
10771
10772 </interface>
10773
10774 <interface
10775 name="IFramebufferOverlay" extends="IFramebuffer"
10776 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
10777 wsmap="suppress"
10778 >
10779 <desc>
10780 The IFramebufferOverlay interface represents an alpha blended overlay
10781 for displaying status icons above an IFramebuffer. It is always created
10782 not visible, so that it must be explicitly shown. It only covers a
10783 portion of the IFramebuffer, determined by its width, height and
10784 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
10785 that order) format, and may be written to directly. Do re-read the
10786 width though, after setting it, as it may be adjusted (increased) to
10787 make it more suitable for the front end.
10788 </desc>
10789 <attribute name="x" type="unsigned long" readonly="yes">
10790 <desc>X position of the overlay, relative to the frame buffer.</desc>
10791 </attribute>
10792
10793 <attribute name="y" type="unsigned long" readonly="yes">
10794 <desc>Y position of the overlay, relative to the frame buffer.</desc>
10795 </attribute>
10796
10797 <attribute name="visible" type="boolean" readonly="no">
10798 <desc>
10799 Whether the overlay is currently visible.
10800 </desc>
10801 </attribute>
10802
10803 <attribute name="alpha" type="unsigned long" readonly="no">
10804 <desc>
10805 The global alpha value for the overlay. This may or may not be
10806 supported by a given front end.
10807 </desc>
10808 </attribute>
10809
10810 <method name="move">
10811 <desc>
10812 Changes the overlay's position relative to the IFramebuffer.
10813 </desc>
10814 <param name="x" type="unsigned long" dir="in"/>
10815 <param name="y" type="unsigned long" dir="in"/>
10816 </method>
10817
10818 </interface>
10819
10820 <interface
10821 name="IDisplay" extends="$unknown"
10822 uuid="26881797-bc98-444d-ac69-820633b93ec7"
10823 wsmap="suppress"
10824 >
10825 <desc>
10826 The IDisplay interface represents the virtual machine's display.
10827
10828 The object implementing this interface is contained in each
10829 <link to="IConsole::display"/> attribute and represents the visual
10830 output of the virtual machine.
10831
10832 The virtual display supports pluggable output targets represented by the
10833 IFramebuffer interface. Examples of the output target are a window on
10834 the host computer or an RDP session's display on a remote computer.
10835 </desc>
10836 <attribute name="width" type="unsigned long" readonly="yes">
10837 <desc>Current display width.</desc>
10838 </attribute>
10839
10840 <attribute name="height" type="unsigned long" readonly="yes">
10841 <desc>Current display height.</desc>
10842 </attribute>
10843
10844 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10845 <desc>
10846 Current guest display color depth. Note that this may differ
10847 from <link to="IFramebuffer::bitsPerPixel"/>.
10848 </desc>
10849 </attribute>
10850
10851 <method name="setFramebuffer">
10852 <desc>
10853 Sets the framebuffer for given screen.
10854 </desc>
10855 <param name="screenId" type="unsigned long" dir="in"/>
10856 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10857 </method>
10858
10859 <method name="getFramebuffer">
10860 <desc>
10861 Queries the framebuffer for given screen.
10862 </desc>
10863 <param name="screenId" type="unsigned long" dir="in"/>
10864 <param name="framebuffer" type="IFramebuffer" dir="out"/>
10865 <param name="xOrigin" type="long" dir="out"/>
10866 <param name="yOrigin" type="long" dir="out"/>
10867 </method>
10868
10869 <method name="setVideoModeHint">
10870 <desc>
10871 Asks VirtualBox to request the given video mode from
10872 the guest. This is just a hint and it cannot be guaranteed
10873 that the requested resolution will be used. Guest Additions
10874 are required for the request to be seen by guests. The caller
10875 should issue the request and wait for a resolution change and
10876 after a timeout retry.
10877
10878 Specifying <tt>0</tt> for either @a width, @a height or @a bitsPerPixel
10879 parameters means that the corresponding values should be taken from the
10880 current video mode (i.e. left unchanged).
10881
10882 If the guest OS supports multi-monitor configuration then the @a display
10883 parameter specifies the number of the guest display to send the hint to:
10884 <tt>0</tt> is the primary display, <tt>1</tt> is the first secondary and
10885 so on. If the multi-monitor configuration is not supported, @a display
10886 must be <tt>0</tt>.
10887
10888 <result name="E_INVALIDARG">
10889 The @a display is not associated with any monitor.
10890 </result>
10891
10892 </desc>
10893 <param name="width" type="unsigned long" dir="in"/>
10894 <param name="height" type="unsigned long" dir="in"/>
10895 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
10896 <param name="display" type="unsigned long" dir="in"/>
10897 </method>
10898
10899 <method name="setSeamlessMode">
10900 <desc>
10901 Enables or disables seamless guest display rendering (seamless desktop
10902 integration) mode.
10903 <note>
10904 Calling this method has no effect if <link
10905 to="IGuest::supportsSeamless"/> returns <tt>false</tt>.
10906 </note>
10907 </desc>
10908 <param name="enabled" type="boolean" dir="in"/>
10909 </method>
10910
10911 <method name="takeScreenShot">
10912 <desc>
10913 Takes a screen shot of the requested size and copies it to the
10914 32-bpp buffer allocated by the caller.
10915
10916 <result name="E_NOTIMPL">
10917 Feature not implemented.
10918 </result>
10919 <result name="VBOX_E_IPRT_ERROR">
10920 Could not take a screenshot.
10921 </result>
10922
10923 </desc>
10924 <param name="address" type="octet" mod="ptr" dir="in"/>
10925 <param name="width" type="unsigned long" dir="in"/>
10926 <param name="height" type="unsigned long" dir="in"/>
10927 </method>
10928
10929 <method name="takeScreenShotSlow">
10930 <desc>
10931 Takes guest screen shot of the requested size and returns it as
10932 an array of bytes in uncompressed 32-bit ARGB format.
10933 This API is slow, but could be the only option to get guest screenshot
10934 for scriptable languages not allowed to manipulate with addresses
10935 directly.
10936
10937 <result name="E_NOTIMPL">
10938 Feature not implemented.
10939 </result>
10940 <result name="VBOX_E_IPRT_ERROR">
10941 Could not take a screenshot.
10942 </result>
10943 </desc>
10944 <param name="width" type="unsigned long" dir="in">
10945 <desc>
10946 Desired image width.
10947 </desc>
10948 </param>
10949 <param name="height" type="unsigned long" dir="in">
10950 <desc>
10951 Desired image height.
10952 </desc>
10953 </param>
10954 <param name="screenData" type="octet" dir="out" safearray="yes">
10955 <desc>
10956 Array with resulting screen data.
10957 </desc>
10958 </param>
10959 </method>
10960
10961 <method name="drawToScreen">
10962 <desc>
10963 Draws a 32-bpp image of the specified size from the given buffer
10964 to the given point on the VM display.
10965
10966 <result name="E_NOTIMPL">
10967 Feature not implemented.
10968 </result>
10969 <result name="VBOX_E_IPRT_ERROR">
10970 Could not draw to screen.
10971 </result>
10972
10973 </desc>
10974 <param name="address" type="octet" mod="ptr" dir="in"/>
10975 <param name="x" type="unsigned long" dir="in"/>
10976 <param name="y" type="unsigned long" dir="in"/>
10977 <param name="width" type="unsigned long" dir="in"/>
10978 <param name="height" type="unsigned long" dir="in"/>
10979 </method>
10980
10981 <method name="invalidateAndUpdate">
10982 <desc>
10983 Does a full invalidation of the VM display and instructs the VM
10984 to update it.
10985
10986 <result name="VBOX_E_IPRT_ERROR">
10987 Could not invalidate and update screen.
10988 </result>
10989
10990 </desc>
10991 </method>
10992
10993 <method name="resizeCompleted">
10994 <desc>
10995 Signals that a framebuffer has completed the resize operation.
10996
10997 <result name="VBOX_E_NOT_SUPPORTED">
10998 Operation only valid for external frame buffers.
10999 </result>
11000
11001 </desc>
11002 <param name="screenId" type="unsigned long" dir="in"/>
11003 </method>
11004
11005 <method name="updateCompleted">
11006 <desc>
11007 Signals that a framebuffer has completed the update operation.
11008
11009 <result name="VBOX_E_NOT_SUPPORTED">
11010 Operation only valid for external frame buffers.
11011 </result>
11012
11013 </desc>
11014 </method>
11015
11016 <method name="completeVHWACommand">
11017 <desc>
11018 Signals that the Video HW Acceleration command has completed.
11019 </desc>
11020
11021 <param name="command" type="octet" mod="ptr" dir="in">
11022 <desc>Pointer to VBOXVHWACMD containing the completed command.</desc>
11023 </param>
11024 </method>
11025
11026 </interface>
11027
11028 <!--
11029 // INetworkAdapter
11030 /////////////////////////////////////////////////////////////////////////
11031 -->
11032
11033 <enum
11034 name="NetworkAttachmentType"
11035 uuid="44bce1ee-99f7-4e8e-89fc-80597fd9eeaf"
11036 >
11037 <desc>
11038 Network attachment type.
11039 </desc>
11040
11041 <const name="Null" value="0">
11042 <desc>Null value, also means "not attached".</desc>
11043 </const>
11044 <const name="NAT" value="1"/>
11045 <const name="Bridged" value="2"/>
11046 <const name="Internal" value="3"/>
11047 <const name="HostOnly" value="4"/>
11048 </enum>
11049
11050 <enum
11051 name="NetworkAdapterType"
11052 uuid="50c3dfd8-07ac-4a31-baac-519c828fbf97"
11053 >
11054 <desc>
11055 Network adapter type.
11056 </desc>
11057
11058 <const name="Null" value="0">
11059 <desc>Null value (never used by the API).</desc>
11060 </const>
11061 <const name="Am79C970A" value="1">
11062 <desc>AMD PCNet-PCI II network card (Am79C970A).</desc>
11063 </const>
11064 <const name="Am79C973" value="2">
11065 <desc>AMD PCNet-FAST III network card (Am79C973).</desc>
11066 </const>
11067 <const name="I82540EM" value="3">
11068 <desc>Intel PRO/1000 MT Desktop network card (82540EM).</desc>
11069 </const>
11070 <const name="I82543GC" value="4">
11071 <desc>Intel PRO/1000 T Server network card (82543GC).</desc>
11072 </const>
11073 <const name="I82545EM" value="5">
11074 <desc>Intel PRO/1000 MT Server network card (82545EM).</desc>
11075 </const>
11076 </enum>
11077
11078 <interface
11079 name="INetworkAdapter" extends="$unknown"
11080 uuid="65607a27-2b73-4d43-b4cc-0ba2c817fbde"
11081 wsmap="managed"
11082 >
11083 <desc>
11084 Represents a virtual network adapter that is attached to a virtual machine.
11085 Each virtual machine has a fixed number of network adapter slots with one
11086 instance of this attached to each of them. Call
11087 <link to="IMachine::getNetworkAdapter" /> to get the network adapter that
11088 is attached to a given slot in a given machine.
11089
11090 Each network adapter can be in one of five attachment modes, which are
11091 represented by the <link to="NetworkAttachmentType" /> enumeration;
11092 see the <link to="#attachmentType" /> attribute.
11093 </desc>
11094
11095 <attribute name="adapterType" type="NetworkAdapterType">
11096 <desc>
11097 Type of the virtual network adapter. Depending on this value,
11098 VirtualBox will provide a different virtual network hardware
11099 to the guest.
11100 </desc>
11101 </attribute>
11102
11103 <attribute name="slot" type="unsigned long" readonly="yes">
11104 <desc>
11105 Slot number this adapter is plugged into. Corresponds to
11106 the value you pass to <link to="IMachine::getNetworkAdapter"/>
11107 to obtain this instance.
11108 </desc>
11109 </attribute>
11110
11111 <attribute name="enabled" type="boolean">
11112 <desc>
11113 Flag whether the network adapter is present in the
11114 guest system. If disabled, the virtual guest hardware will
11115 not contain this network adapter. Can only be changed when
11116 the VM is not running.
11117 </desc>
11118 </attribute>
11119
11120 <attribute name="MACAddress" type="wstring">
11121 <desc>
11122 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
11123 it to NULL, VirtualBox will generate a unique MAC address.
11124 </desc>
11125 </attribute>
11126
11127 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
11128
11129 <attribute name="hostInterface" type="wstring">
11130 <desc>
11131 Name of the host network interface the VM is attached to.
11132 </desc>
11133 </attribute>
11134
11135 <attribute name="internalNetwork" type="wstring">
11136 <desc>
11137 Name of the internal network the VM is attached to.
11138 </desc>
11139 </attribute>
11140
11141 <attribute name="NATNetwork" type="wstring">
11142 <desc>
11143 Name of the NAT network the VM is attached to.
11144 </desc>
11145 </attribute>
11146
11147 <attribute name="cableConnected" type="boolean">
11148 <desc>
11149 Flag whether the adapter reports the cable as connected or not.
11150 It can be used to report offline situations to a VM.
11151 </desc>
11152 </attribute>
11153
11154 <attribute name="lineSpeed" type="unsigned long">
11155 <desc>
11156 Line speed reported by custom drivers, in units of 1 kbps.
11157 </desc>
11158 </attribute>
11159
11160 <attribute name="traceEnabled" type="boolean">
11161 <desc>
11162 Flag whether network traffic from/to the network card should be traced.
11163 Can only be toggled when the VM is turned off.
11164 </desc>
11165 </attribute>
11166
11167 <attribute name="traceFile" type="wstring">
11168 <desc>
11169 Filename where a network trace will be stored. If not set, VBox-pid.pcap
11170 will be used.
11171 </desc>
11172 </attribute>
11173
11174 <method name="attachToNAT">
11175 <desc>
11176 Attach the network adapter to the Network Address Translation (NAT) interface.
11177 </desc>
11178 </method>
11179
11180 <method name="attachToBridgedInterface">
11181 <desc>
11182 Attach the network adapter to a bridged host interface.
11183 </desc>
11184 </method>
11185
11186 <method name="attachToInternalNetwork">
11187 <desc>
11188 Attach the network adapter to an internal network.
11189 </desc>
11190 </method>
11191
11192 <method name="attachToHostOnlyInterface">
11193 <desc>
11194 Attach the network adapter to the host-only network.
11195 </desc>
11196 </method>
11197
11198 <method name="detach">
11199 <desc>
11200 Detach the network adapter
11201 </desc>
11202 </method>
11203 </interface>
11204
11205
11206 <!--
11207 // ISerialPort
11208 /////////////////////////////////////////////////////////////////////////
11209 -->
11210
11211 <enum
11212 name="PortMode"
11213 uuid="533b5fe3-0185-4197-86a7-17e37dd39d76"
11214 >
11215 <desc>
11216 The PortMode enumeration represents possible communication modes for
11217 the virtual serial port device.
11218 </desc>
11219
11220 <const name="Disconnected" value="0">
11221 <desc>Virtual device is not attached to any real host device.</desc>
11222 </const>
11223 <const name="HostPipe" value="1">
11224 <desc>Virtual device is attached to a host pipe.</desc>
11225 </const>
11226 <const name="HostDevice" value="2">
11227 <desc>Virtual device is attached to a host device.</desc>
11228 </const>
11229 <const name="RawFile" value="3">
11230 <desc>Virtual device is attached to a raw file.</desc>
11231 </const>
11232 </enum>
11233
11234 <interface
11235 name="ISerialPort" extends="$unknown"
11236 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
11237 wsmap="managed"
11238 >
11239
11240 <desc>
11241 The ISerialPort interface represents the virtual serial port device.
11242
11243 The virtual serial port device acts like an ordinary serial port
11244 inside the virtual machine. This device communicates to the real
11245 serial port hardware in one of two modes: host pipe or host device.
11246
11247 In host pipe mode, the #path attribute specifies the path to the pipe on
11248 the host computer that represents a serial port. The #server attribute
11249 determines if this pipe is created by the virtual machine process at
11250 machine startup or it must already exist before starting machine
11251 execution.
11252
11253 In host device mode, the #path attribute specifies the name of the
11254 serial port device on the host computer.
11255
11256 There is also a third communication mode: the disconnected mode. In this
11257 mode, the guest OS running inside the virtual machine will be able to
11258 detect the serial port, but all port write operations will be discarded
11259 and all port read operations will return no data.
11260
11261 <see>IMachine::getSerialPort</see>
11262 </desc>
11263
11264 <attribute name="slot" type="unsigned long" readonly="yes">
11265 <desc>
11266 Slot number this serial port is plugged into. Corresponds to
11267 the value you pass to <link to="IMachine::getSerialPort"/>
11268 to obtain this instance.
11269 </desc>
11270 </attribute>
11271
11272 <attribute name="enabled" type="boolean">
11273 <desc>
11274 Flag whether the serial port is enabled. If disabled,
11275 the serial port will not be reported to the guest OS.
11276 </desc>
11277 </attribute>
11278
11279 <attribute name="IOBase" type="unsigned long">
11280 <desc>Base I/O address of the serial port.</desc>
11281 </attribute>
11282
11283 <attribute name="IRQ" type="unsigned long">
11284 <desc>IRQ number of the serial port.</desc>
11285 </attribute>
11286
11287 <attribute name="hostMode" type="PortMode">
11288 <desc>
11289 How is this port connected to the host.
11290 <note>
11291 Changing this attribute may fail if the conditions for
11292 <link to="#path"/> are not met.
11293 </note>
11294 </desc>
11295 </attribute>
11296
11297 <attribute name="server" type="boolean">
11298 <desc>
11299 Flag whether this serial port acts as a server (creates a new pipe on
11300 the host) or as a client (uses the existing pipe). This attribute is
11301 used only when <link to="#hostMode"/> is PortMode_HostPipe.
11302 </desc>
11303 </attribute>
11304
11305 <attribute name="path" type="wstring">
11306 <desc>
11307 Path to the serial port's pipe on the host when <link to="ISerialPort::hostMode"/> is
11308 PortMode_HostPipe, or the host serial device name when
11309 <link to="ISerialPort::hostMode"/> is PortMode_HostDevice. For both
11310 cases, setting a @c null or empty string as the attribute's value
11311 is an error. Otherwise, the value of this property is ignored.
11312 </desc>
11313 </attribute>
11314
11315 </interface>
11316
11317 <!--
11318 // IParallelPort
11319 /////////////////////////////////////////////////////////////////////////
11320 -->
11321
11322 <interface
11323 name="IParallelPort" extends="$unknown"
11324 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
11325 wsmap="managed"
11326 >
11327
11328 <desc>
11329 The IParallelPort interface represents the virtual parallel port device.
11330
11331 The virtual parallel port device acts like an ordinary parallel port
11332 inside the virtual machine. This device communicates to the real
11333 parallel port hardware using the name of the parallel device on the host
11334 computer specified in the #path attribute.
11335
11336 Each virtual parallel port device is assigned a base I/O address and an
11337 IRQ number that will be reported to the guest operating system and used
11338 to operate the given parallel port from within the virtual machine.
11339
11340 <see>IMachine::getParallelPort</see>
11341 </desc>
11342
11343 <attribute name="slot" type="unsigned long" readonly="yes">
11344 <desc>
11345 Slot number this parallel port is plugged into. Corresponds to
11346 the value you pass to <link to="IMachine::getParallelPort"/>
11347 to obtain this instance.
11348 </desc>
11349 </attribute>
11350
11351 <attribute name="enabled" type="boolean">
11352 <desc>
11353 Flag whether the parallel port is enabled. If disabled,
11354 the parallel port will not be reported to the guest OS.
11355 </desc>
11356 </attribute>
11357
11358 <attribute name="IOBase" type="unsigned long">
11359 <desc>Base I/O address of the parallel port.</desc>
11360 </attribute>
11361
11362 <attribute name="IRQ" type="unsigned long">
11363 <desc>IRQ number of the parallel port.</desc>
11364 </attribute>
11365
11366 <attribute name="path" type="wstring">
11367 <desc>
11368 Host parallel device name. If this parallel port is enabled, setting a
11369 @c null or an empty string as this attribute's value will result into
11370 an error.
11371 </desc>
11372 </attribute>
11373
11374 </interface>
11375
11376
11377 <!--
11378 // IMachineDebugger
11379 /////////////////////////////////////////////////////////////////////////
11380 -->
11381
11382 <interface
11383 name="IMachineDebugger" extends="$unknown"
11384 uuid="b0b2a2dd-0627-4502-91c2-ddc5e77609e0"
11385 wsmap="suppress"
11386 >
11387 <method name="resetStats">
11388 <desc>
11389 Reset VM statistics.
11390 </desc>
11391 <param name="pattern" type="wstring" dir="in">
11392 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11393 </param>
11394 </method>
11395
11396 <method name="dumpStats">
11397 <desc>
11398 Dumps VM statistics.
11399 </desc>
11400 <param name="pattern" type="wstring" dir="in">
11401 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11402 </param>
11403 </method>
11404
11405 <method name="getStats">
11406 <desc>
11407 Get the VM statistics in a XMLish format.
11408 </desc>
11409 <param name="pattern" type="wstring" dir="in">
11410 <desc>The selection pattern. A bit similar to filename globbing.</desc>
11411 </param>
11412 <param name="withDescriptions" type="boolean" dir="in">
11413 <desc>Whether to include the descriptions.</desc>
11414 </param>
11415 <param name="stats" type="wstring" dir="out">
11416 <desc>The XML document containing the statistics.</desc>
11417 </param>
11418 </method>
11419
11420 <method name="injectNMI">
11421 <desc>
11422 Inject an NMI into a running VT-x/AMD-V VM.
11423 </desc>
11424 </method>
11425
11426 <attribute name="singlestep" type="boolean">
11427 <desc>Switch for enabling singlestepping.</desc>
11428 </attribute>
11429
11430 <attribute name="recompileUser" type="boolean">
11431 <desc>Switch for forcing code recompilation for user mode code.</desc>
11432 </attribute>
11433
11434 <attribute name="recompileSupervisor" type="boolean">
11435 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
11436 </attribute>
11437
11438 <attribute name="PATMEnabled" type="boolean">
11439 <desc>Switch for enabling and disabling the PATM component.</desc>
11440 </attribute>
11441
11442 <attribute name="CSAMEnabled" type="boolean">
11443 <desc>Switch for enabling and disabling the CSAM component.</desc>
11444 </attribute>
11445
11446 <attribute name="logEnabled" type="boolean">
11447 <desc>Switch for enabling and disabling logging.</desc>
11448 </attribute>
11449
11450 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
11451 <desc>
11452 Flag indicating whether the VM is currently making use of CPU hardware
11453 virtualization extensions.
11454 </desc>
11455 </attribute>
11456
11457 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" readonly="yes">
11458 <desc>
11459 Flag indicating whether the VM is currently making use of the nested paging
11460 CPU hardware virtualization extension.
11461 </desc>
11462 </attribute>
11463
11464 <attribute name="HWVirtExVPIDEnabled" type="boolean" readonly="yes">
11465 <desc>
11466 Flag indicating whether the VM is currently making use of the VPID
11467 VT-x extension.
11468 </desc>
11469 </attribute>
11470
11471 <attribute name="PAEEnabled" type="boolean" readonly="yes">
11472 <desc>
11473 Flag indicating whether the VM is currently making use of the Physical
11474 Address Extension CPU feature.
11475 </desc>
11476 </attribute>
11477
11478 <attribute name="virtualTimeRate" type="unsigned long">
11479 <desc>
11480 The rate at which the virtual time runs expressed as a percentage.
11481 The accepted range is 2% to 20000%.
11482 </desc>
11483 </attribute>
11484
11485 <!-- @todo method for setting log flags, groups and destination! -->
11486
11487 <attribute name="VM" type="unsigned long long" readonly="yes">
11488 <desc>
11489 Gets the VM handle. This is only for internal use while
11490 we carve the details of this interface.
11491 </desc>
11492 </attribute>
11493
11494 </interface>
11495
11496 <!--
11497 // IUSBController
11498 /////////////////////////////////////////////////////////////////////////
11499 -->
11500
11501 <interface
11502 name="IUSBController" extends="$unknown"
11503 uuid="238540fa-4b73-435a-a38e-4e1d9eab5c17"
11504 wsmap="managed"
11505 >
11506 <attribute name="enabled" type="boolean">
11507 <desc>
11508 Flag whether the USB controller is present in the
11509 guest system. If disabled, the virtual guest hardware will
11510 not contain any USB controller. Can only be changed when
11511 the VM is powered off.
11512 </desc>
11513 </attribute>
11514
11515 <attribute name="enabledEhci" type="boolean">
11516 <desc>
11517 Flag whether the USB EHCI controller is present in the
11518 guest system. If disabled, the virtual guest hardware will
11519 not contain a USB EHCI controller. Can only be changed when
11520 the VM is powered off.
11521 </desc>
11522 </attribute>
11523
11524 <attribute name="USBStandard" type="unsigned short" readonly="yes">
11525 <desc>
11526 USB standard version which the controller implements.
11527 This is a BCD which means that the major version is in the
11528 high byte and minor version is in the low byte.
11529 </desc>
11530 </attribute>
11531
11532 <attribute name="deviceFilters" type="IUSBDeviceFilter" readonly="yes" safearray="yes">
11533 <desc>
11534 List of USB device filters associated with the machine.
11535
11536 If the machine is currently running, these filters are activated
11537 every time a new (supported) USB device is attached to the host
11538 computer that was not ignored by global filters
11539 (<link to="IHost::USBDeviceFilters"/>).
11540
11541 These filters are also activated when the machine is powered up.
11542 They are run against a list of all currently available USB
11543 devices (in states
11544 <link to="USBDeviceState_Available"/>,
11545 <link to="USBDeviceState_Busy"/>,
11546 <link to="USBDeviceState_Held"/>) that were not previously
11547 ignored by global filters.
11548
11549 If at least one filter matches the USB device in question, this
11550 device is automatically captured (attached to) the virtual USB
11551 controller of this machine.
11552
11553 <see>IUSBDeviceFilter, ::IUSBController</see>
11554 </desc>
11555 </attribute>
11556
11557 <method name="createDeviceFilter">
11558 <desc>
11559 Creates a new USB device filter. All attributes except
11560 the filter name are set to <tt>null</tt> (any match),
11561 <i>active</i> is <tt>false</tt> (the filter is not active).
11562
11563 The created filter can then be added to the list of filters using
11564 <link to="#insertDeviceFilter"/>.
11565
11566 <result name="VBOX_E_INVALID_VM_STATE">
11567 The virtual machine is not mutable.
11568 </result>
11569
11570 <see>#deviceFilters</see>
11571 </desc>
11572 <param name="name" type="wstring" dir="in">
11573 <desc>
11574 Filter name. See <link to="IUSBDeviceFilter::name"/>
11575 for more info.
11576 </desc>
11577 </param>
11578 <param name="filter" type="IUSBDeviceFilter" dir="return">
11579 <desc>Created filter object.</desc>
11580 </param>
11581 </method>
11582
11583 <method name="insertDeviceFilter">
11584 <desc>
11585 Inserts the given USB device to the specified position
11586 in the list of filters.
11587
11588 Positions are numbered starting from <tt>0</tt>. If the specified
11589 position is equal to or greater than the number of elements in
11590 the list, the filter is added to the end of the collection.
11591
11592 <note>
11593 Duplicates are not allowed, so an attempt to insert a
11594 filter that is already in the collection, will return an
11595 error.
11596 </note>
11597
11598 <result name="VBOX_E_INVALID_VM_STATE">
11599 Virtual machine is not mutable.
11600 </result>
11601 <result name="E_INVALIDARG">
11602 USB device filter not created within this VirtualBox instance.
11603 </result>
11604 <result name="VBOX_E_INVALID_OBJECT_STATE">
11605 USB device filter already in list.
11606 </result>
11607
11608 <see>#deviceFilters</see>
11609 </desc>
11610 <param name="position" type="unsigned long" dir="in">
11611 <desc>Position to insert the filter to.</desc>
11612 </param>
11613 <param name="filter" type="IUSBDeviceFilter" dir="in">
11614 <desc>USB device filter to insert.</desc>
11615 </param>
11616 </method>
11617
11618 <method name="removeDeviceFilter">
11619 <desc>
11620 Removes a USB device filter from the specified position in the
11621 list of filters.
11622
11623 Positions are numbered starting from <tt>0</tt>. Specifying a
11624 position equal to or greater than the number of elements in
11625 the list will produce an error.
11626
11627 <see>#deviceFilters</see>
11628
11629 <result name="VBOX_E_INVALID_VM_STATE">
11630 Virtual machine is not mutable.
11631 </result>
11632 <result name="E_INVALIDARG">
11633 USB device filter list empty or invalid @a position.
11634 </result>
11635
11636 </desc>
11637 <param name="position" type="unsigned long" dir="in">
11638 <desc>Position to remove the filter from.</desc>
11639 </param>
11640 <param name="filter" type="IUSBDeviceFilter" dir="return">
11641 <desc>Removed USB device filter.</desc>
11642 </param>
11643 </method>
11644
11645 </interface>
11646
11647
11648 <!--
11649 // IUSBDevice
11650 /////////////////////////////////////////////////////////////////////////
11651 -->
11652
11653 <interface
11654 name="IUSBDevice" extends="$unknown"
11655 uuid="f8967b0b-4483-400f-92b5-8b675d98a85b"
11656 wsmap="managed"
11657 >
11658 <desc>
11659 The IUSBDevice interface represents a virtual USB device attached to the
11660 virtual machine.
11661
11662 A collection of objects implementing this interface is stored in the
11663 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
11664 attached to a running virtual machine's USB controller.
11665 </desc>
11666
11667 <attribute name="id" type="wstring" readonly="yes">
11668 <desc>
11669 Unique USB device ID. This ID is built from #vendorId,
11670 #productId, #revision and #serialNumber.
11671 </desc>
11672 </attribute>
11673
11674 <attribute name="vendorId" type="unsigned short" readonly="yes">
11675 <desc>Vendor ID.</desc>
11676 </attribute>
11677
11678 <attribute name="productId" type="unsigned short" readonly="yes">
11679 <desc>Product ID.</desc>
11680 </attribute>
11681
11682 <attribute name="revision" type="unsigned short" readonly="yes">
11683 <desc>
11684 Product revision number. This is a packed BCD represented as
11685 unsigned short. The high byte is the integer part and the low
11686 byte is the decimal.
11687 </desc>
11688 </attribute>
11689
11690 <attribute name="manufacturer" type="wstring" readonly="yes">
11691 <desc>Manufacturer string.</desc>
11692 </attribute>
11693
11694 <attribute name="product" type="wstring" readonly="yes">
11695 <desc>Product string.</desc>
11696 </attribute>
11697
11698 <attribute name="serialNumber" type="wstring" readonly="yes">
11699 <desc>Serial number string.</desc>
11700 </attribute>
11701
11702 <attribute name="address" type="wstring" readonly="yes">
11703 <desc>Host specific address of the device.</desc>
11704 </attribute>
11705
11706 <attribute name="port" type="unsigned short" readonly="yes">
11707 <desc>
11708 Host USB port number the device is physically
11709 connected to.
11710 </desc>
11711 </attribute>
11712
11713 <attribute name="version" type="unsigned short" readonly="yes">
11714 <desc>
11715 The major USB version of the device - 1 or 2.
11716 </desc>
11717 </attribute>
11718
11719 <attribute name="portVersion" type="unsigned short" readonly="yes">
11720 <desc>
11721 The major USB version of the host USB port the device is
11722 physically connected to - 1 or 2. For devices not connected to
11723 anything this will have the same value as the version attribute.
11724 </desc>
11725 </attribute>
11726
11727 <attribute name="remote" type="boolean" readonly="yes">
11728 <desc>
11729 Whether the device is physically connected to a remote VRDP
11730 client or to a local host machine.
11731 </desc>
11732 </attribute>
11733
11734 </interface>
11735
11736
11737 <!--
11738 // IUSBDeviceFilter
11739 /////////////////////////////////////////////////////////////////////////
11740 -->
11741
11742 <interface
11743 name="IUSBDeviceFilter" extends="$unknown"
11744 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
11745 wsmap="managed"
11746 >
11747 <desc>
11748 The IUSBDeviceFilter interface represents an USB device filter used
11749 to perform actions on a group of USB devices.
11750
11751 This type of filters is used by running virtual machines to
11752 automatically capture selected USB devices once they are physically
11753 attached to the host computer.
11754
11755 A USB device is matched to the given device filter if and only if all
11756 attributes of the device match the corresponding attributes of the
11757 filter (that is, attributes are joined together using the logical AND
11758 operation). On the other hand, all together, filters in the list of
11759 filters carry the semantics of the logical OR operation. So if it is
11760 desirable to create a match like "this vendor id OR this product id",
11761 one needs to create two filters and specify "any match" (see below)
11762 for unused attributes.
11763
11764 All filter attributes used for matching are strings. Each string
11765 is an expression representing a set of values of the corresponding
11766 device attribute, that will match the given filter. Currently, the
11767 following filtering expressions are supported:
11768
11769 <ul>
11770 <li><i>Interval filters</i>. Used to specify valid intervals for
11771 integer device attributes (Vendor ID, Product ID and Revision).
11772 The format of the string is:
11773
11774 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
11775
11776 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
11777 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
11778 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
11779 is omitted before a dash (<tt>-</tt>), the minimum possible integer
11780 is assumed; if <tt>n</tt> is omitted after a dash, the maximum
11781 possible integer is assumed.
11782 </li>
11783 <li><i>Boolean filters</i>. Used to specify acceptable values for
11784 boolean device attributes. The format of the string is:
11785
11786 <tt>true|false|yes|no|0|1</tt>
11787
11788 </li>
11789 <li><i>Exact match</i>. Used to specify a single value for the given
11790 device attribute. Any string that doesn't start with <tt>int:</tt>
11791 represents the exact match. String device attributes are compared to
11792 this string including case of symbols. Integer attributes are first
11793 converted to a string (see individual filter attributes) and then
11794 compared ignoring case.
11795
11796 </li>
11797 <li><i>Any match</i>. Any value of the corresponding device attribute
11798 will match the given filter. An empty or <tt>null</tt> string is
11799 used to construct this type of filtering expressions.
11800
11801 </li>
11802 </ul>
11803
11804 <note>
11805 On the Windows host platform, interval filters are not currently
11806 available. Also all string filter attributes
11807 (<link to="#manufacturer"/>, <link to="#product"/>,
11808 <link to="#serialNumber"/>) are ignored, so they behave as
11809 <i>any match</i> no matter what string expression is specified.
11810 </note>
11811
11812 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
11813 </desc>
11814
11815 <attribute name="name" type="wstring">
11816 <desc>
11817 Visible name for this filter.
11818 This name is used to visually distinguish one filter from another,
11819 so it can neither be <tt>null</tt> nor an empty string.
11820 </desc>
11821 </attribute>
11822
11823 <attribute name="active" type="boolean">
11824 <desc>Whether this filter active or has been temporarily disabled.</desc>
11825 </attribute>
11826
11827 <attribute name="vendorId" type="wstring">
11828 <desc>
11829 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
11830 The string representation for the <i>exact matching</i>
11831 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11832 (including leading zeroes).
11833 </desc>
11834 </attribute>
11835
11836 <attribute name="productId" type="wstring">
11837 <desc>
11838 <link to="IUSBDevice::productId">Product ID</link> filter.
11839 The string representation for the <i>exact matching</i>
11840 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11841 (including leading zeroes).
11842 </desc>
11843 </attribute>
11844
11845 <attribute name="revision" type="wstring">
11846 <desc>
11847 <link to="IUSBDevice::productId">Product revision number</link>
11848 filter. The string representation for the <i>exact matching</i>
11849 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
11850 of the integer part of the revision, and <tt>F</tt> is the
11851 decimal digit of its fractional part (including leading and
11852 trailing zeros).
11853 Note that for interval filters, it's best to use the hexadecimal
11854 form, because the revision is stored as a 16 bit packed BCD value;
11855 so the expression <tt>int:0x0100-0x0199</tt> will match any
11856 revision from <tt>1.0</tt> to <tt>1.99</tt>.
11857 </desc>
11858 </attribute>
11859
11860 <attribute name="manufacturer" type="wstring">
11861 <desc>
11862 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
11863 </desc>
11864 </attribute>
11865
11866 <attribute name="product" type="wstring">
11867 <desc>
11868 <link to="IUSBDevice::product">Product</link> filter.
11869 </desc>
11870 </attribute>
11871
11872 <attribute name="serialNumber" type="wstring">
11873 <desc>
11874 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
11875 </desc>
11876 </attribute>
11877
11878 <attribute name="port" type="wstring">
11879 <desc>
11880 <link to="IUSBDevice::port">Host USB port</link> filter.
11881 </desc>
11882 </attribute>
11883
11884 <attribute name="remote" type="wstring">
11885 <desc>
11886 <link to="IUSBDevice::remote">Remote state</link> filter.
11887 <note>
11888 This filter makes sense only for machine USB filters,
11889 i.e. it is ignored by IHostUSBDeviceFilter objects.
11890 </note>
11891 </desc>
11892 </attribute>
11893
11894 <attribute name="maskedInterfaces" type="unsigned long">
11895 <desc>
11896 This is an advanced option for hiding one or more USB interfaces
11897 from the guest. The value is a bit mask where the bits that are set
11898 means the corresponding USB interface should be hidden, masked off
11899 if you like.
11900 This feature only works on Linux hosts.
11901 </desc>
11902 </attribute>
11903
11904 </interface>
11905
11906
11907 <!--
11908 // IHostUSBDevice
11909 /////////////////////////////////////////////////////////////////////////
11910 -->
11911
11912 <enum
11913 name="USBDeviceState"
11914 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
11915 >
11916 <desc>
11917 USB device state. This enumeration represents all possible states
11918 of the USB device physically attached to the host computer regarding
11919 its state on the host computer and availability to guest computers
11920 (all currently running virtual machines).
11921
11922 Once a supported USB device is attached to the host, global USB
11923 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
11924 either ignore the device, or put it to USBDeviceState_Held state, or do
11925 nothing. Unless the device is ignored by global filters, filters of all
11926 currently running guests (<link to="IUSBController::deviceFilters"/>) are
11927 activated that can put it to USBDeviceState_Captured state.
11928
11929 If the device was ignored by global filters, or didn't match
11930 any filters at all (including guest ones), it is handled by the host
11931 in a normal way. In this case, the device state is determined by
11932 the host and can be one of USBDeviceState_Unavailable, USBDeviceState_Busy
11933 or USBDeviceState_Available, depending on the current device usage.
11934
11935 Besides auto-capturing based on filters, the device can be manually
11936 captured by guests (<link to="IConsole::attachUSBDevice"/>) if its
11937 state is USBDeviceState_Busy, USBDeviceState_Available or
11938 USBDeviceState_Held.
11939
11940 <note>
11941 Due to differences in USB stack implementations in Linux and Win32,
11942 states USBDeviceState_Busy and USBDeviceState_vailable are applicable
11943 only to the Linux version of the product. This also means that (<link
11944 to="IConsole::attachUSBDevice"/>) can only succeed on Win32 if the
11945 device state is USBDeviceState_Held.
11946 </note>
11947
11948 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
11949 </desc>
11950
11951 <const name="NotSupported" value="0">
11952 <desc>
11953 Not supported by the VirtualBox server, not available to guests.
11954 </desc>
11955 </const>
11956 <const name="Unavailable" value="1">
11957 <desc>
11958 Being used by the host computer exclusively,
11959 not available to guests.
11960 </desc>
11961 </const>
11962 <const name="Busy" value="2">
11963 <desc>
11964 Being used by the host computer, potentially available to guests.
11965 </desc>
11966 </const>
11967 <const name="Available" value="3">
11968 <desc>
11969 Not used by the host computer, available to guests (the host computer
11970 can also start using the device at any time).
11971 </desc>
11972 </const>
11973 <const name="Held" value="4">
11974 <desc>
11975 Held by the VirtualBox server (ignored by the host computer),
11976 available to guests.
11977 </desc>
11978 </const>
11979 <const name="Captured" value="5">
11980 <desc>
11981 Captured by one of the guest computers, not available
11982 to anybody else.
11983 </desc>
11984 </const>
11985 </enum>
11986
11987 <interface
11988 name="IHostUSBDevice" extends="IUSBDevice"
11989 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
11990 wsmap="managed"
11991 >
11992 <desc>
11993 The IHostUSBDevice interface represents a physical USB device attached
11994 to the host computer.
11995
11996 Besides properties inherited from IUSBDevice, this interface adds the
11997 <link to="#state"/> property that holds the current state of the USB
11998 device.
11999
12000 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
12001 </desc>
12002
12003 <attribute name="state" type="USBDeviceState" readonly="yes">
12004 <desc>
12005 Current state of the device.
12006 </desc>
12007 </attribute>
12008
12009 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
12010
12011 </interface>
12012
12013
12014 <!--
12015 // IHostUSBDeviceFilter
12016 /////////////////////////////////////////////////////////////////////////
12017 -->
12018
12019 <enum
12020 name="USBDeviceFilterAction"
12021 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
12022 >
12023 <desc>
12024 Actions for host USB device filters.
12025 <see>IHostUSBDeviceFilter, USBDeviceState</see>
12026 </desc>
12027
12028 <const name="Null" value="0">
12029 <desc>Null value (never used by the API).</desc>
12030 </const>
12031 <const name="Ignore" value="1">
12032 <desc>Ignore the matched USB device.</desc>
12033 </const>
12034 <const name="Hold" value="2">
12035 <desc>Hold the matched USB device.</desc>
12036 </const>
12037 </enum>
12038
12039 <interface
12040 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
12041 uuid="4cc70246-d74a-400f-8222-3900489c0374"
12042 wsmap="managed"
12043 >
12044 <desc>
12045 The IHostUSBDeviceFilter interface represents a global filter for a
12046 physical USB device used by the host computer. Used indirectly in
12047 <link to="IHost::USBDeviceFilters"/>.
12048
12049 Using filters of this type, the host computer determines the initial
12050 state of the USB device after it is physically attached to the
12051 host's USB controller.
12052
12053 <note>
12054 The <link to="#remote"/> attribute is ignored by this type of
12055 filters, because it makes sense only for
12056 <link to="IUSBController::deviceFilters">machine USB filters</link>.
12057 </note>
12058
12059 <see>IHost::USBDeviceFilters</see>
12060 </desc>
12061
12062 <attribute name="action" type="USBDeviceFilterAction">
12063 <desc>
12064 Action performed by the host when an attached USB device
12065 matches this filter.
12066 </desc>
12067 </attribute>
12068
12069 </interface>
12070
12071 <!--
12072 // IAudioAdapter
12073 /////////////////////////////////////////////////////////////////////////
12074 -->
12075
12076 <enum
12077 name="AudioDriverType"
12078 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
12079 >
12080 <desc>
12081 Host audio driver type.
12082 </desc>
12083
12084 <const name="Null" value="0">
12085 <desc>Null value, also means "dummy audio driver".</desc>
12086 </const>
12087 <const name="WinMM" value="1"/>
12088 <const name="OSS" value="2"/>
12089 <const name="ALSA" value="3"/>
12090 <const name="DirectSound" value="4"/>
12091 <const name="CoreAudio" value="5"/>
12092 <const name="MMPM" value="6"/>
12093 <const name="Pulse" value="7"/>
12094 <const name="SolAudio" value="8"/>
12095 </enum>
12096
12097 <enum
12098 name="AudioControllerType"
12099 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
12100 >
12101 <desc>
12102 Virtual audio controller type.
12103 </desc>
12104
12105 <const name="AC97" value="0"/>
12106 <const name="SB16" value="1"/>
12107 </enum>
12108
12109 <interface
12110 name="IAudioAdapter" extends="$unknown"
12111 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
12112 wsmap="managed"
12113 >
12114 <desc>
12115 The IAudioAdapter interface represents the virtual audio adapter of
12116 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
12117 </desc>
12118 <attribute name="enabled" type="boolean">
12119 <desc>
12120 Flag whether the audio adapter is present in the
12121 guest system. If disabled, the virtual guest hardware will
12122 not contain any audio adapter. Can only be changed when
12123 the VM is not running.
12124 </desc>
12125 </attribute>
12126 <attribute name="audioController" type="AudioControllerType">
12127 <desc>
12128 The audio hardware we emulate.
12129 </desc>
12130 </attribute>
12131 <attribute name="audioDriver" type="AudioDriverType">
12132 <desc>
12133 Audio driver the adapter is connected to. This setting
12134 can only be changed when the VM is not running.
12135 </desc>
12136 </attribute>
12137 </interface>
12138
12139 <!--
12140 // IVRDPServer
12141 /////////////////////////////////////////////////////////////////////////
12142 -->
12143
12144 <enum
12145 name="VRDPAuthType"
12146 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
12147 >
12148 <desc>
12149 VRDP authentication type.
12150 </desc>
12151
12152 <const name="Null" value="0">
12153 <desc>Null value, also means "no authentication".</desc>
12154 </const>
12155 <const name="External" value="1"/>
12156 <const name="Guest" value="2"/>
12157 </enum>
12158
12159 <interface
12160 name="IVRDPServer" extends="$unknown"
12161 uuid="f4584ae7-6bce-474b-83d6-17d235e6aa89"
12162 wsmap="managed"
12163 >
12164 <attribute name="enabled" type="boolean">
12165 <desc>VRDP server status.</desc>
12166 </attribute>
12167
12168 <attribute name="port" type="unsigned long">
12169 <desc>
12170 VRDP server port number.
12171 <note>
12172 Setting the value of this property to <tt>0</tt> will reset the port
12173 number to the default value which is
12174 currently <tt>3389</tt>. Reading this property will always return a
12175 real port number, even after it has been set to <tt>0</tt> (in which
12176 case the default port is returned).
12177 </note>
12178 </desc>
12179 </attribute>
12180
12181 <attribute name="netAddress" type="wstring">
12182 <desc>VRDP server address.</desc>
12183 </attribute>
12184
12185 <attribute name="authType" type="VRDPAuthType">
12186 <desc>VRDP authentication method.</desc>
12187 </attribute>
12188
12189 <attribute name="authTimeout" type="unsigned long">
12190 <desc>Timeout for guest authentication. Milliseconds.</desc>
12191 </attribute>
12192
12193 <attribute name="allowMultiConnection" type="boolean">
12194 <desc>
12195 Flag whether multiple simultaneous connections to the VM are permitted.
12196 Note that this will be replaced by a more powerful mechanism in the future.
12197 </desc>
12198 </attribute>
12199
12200 <attribute name="reuseSingleConnection" type="boolean">
12201 <desc>
12202 Flag whether the existing connection must be dropped and a new connection
12203 must be established by the VRDP server, when a new client connects in single
12204 connection mode.
12205 </desc>
12206 </attribute>
12207
12208 </interface>
12209
12210
12211 <!--
12212 // ISharedFolder
12213 /////////////////////////////////////////////////////////////////////////
12214 -->
12215
12216 <interface
12217 name="ISharedFolder" extends="$unknown"
12218 uuid="64637bb2-9e17-471c-b8f3-f8968dd9884e"
12219 wsmap="struct"
12220 >
12221 <desc>
12222 The ISharedFolder interface represents a folder in the host computer's
12223 file system accessible from the guest OS running inside a virtual
12224 machine using an associated logical name.
12225
12226 There are three types of shared folders:
12227 <ul>
12228 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
12229 folders available to all virtual machines.</li>
12230 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
12231 VM-specific shared folders available to the given virtual machine at
12232 startup.</li>
12233 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
12234 VM-specific shared folders created in the session context (for
12235 example, when the virtual machine is running) and automatically
12236 discarded when the session is closed (the VM is powered off).</li>
12237 </ul>
12238
12239 Logical names of shared folders must be unique within the given scope
12240 (global, permanent or transient). However, they do not need to be unique
12241 across scopes. In this case, the definition of the shared folder in a
12242 more specific scope takes precedence over definitions in all other
12243 scopes. The order of precedence is (more specific to more general):
12244 <ol>
12245 <li>Transient definitions</li>
12246 <li>Permanent definitions</li>
12247 <li>Global definitions</li>
12248 </ol>
12249
12250 For example, if MyMachine has a shared folder named
12251 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then creating a
12252 transient shared folder named <tt>C_DRIVE</tt> (that points
12253 to <tt>C:\\\\WINDOWS</tt>) will change the definition
12254 of <tt>C_DRIVE</tt> in the guest OS so
12255 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
12256 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
12257 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
12258 the previous (permanent) definition of <tt>C_DRIVE</tt> that points
12259 to <tt>C:\\</tt> if it still exists.
12260
12261 Note that permanent and transient shared folders of different machines
12262 are in different name spaces, so they don't overlap and don't need to
12263 have unique logical names.
12264
12265 <note>
12266 Global shared folders are not implemented in the current version of the
12267 product.
12268 </note>
12269 </desc>
12270
12271 <attribute name="name" type="wstring" readonly="yes">
12272 <desc>Logical name of the shared folder.</desc>
12273 </attribute>
12274
12275 <attribute name="hostPath" type="wstring" readonly="yes">
12276 <desc>Full path to the shared folder in the host file system.</desc>
12277 </attribute>
12278
12279 <attribute name="accessible" type="boolean" readonly="yes">
12280 <desc>
12281 Whether the folder defined by the host path is currently
12282 accessible or not.
12283 For example, the folder can be unaccessible if it is placed
12284 on the network share that is not available by the time
12285 this property is read.
12286 </desc>
12287 </attribute>
12288
12289 <attribute name="writable" type="boolean" readonly="yes">
12290 <desc>
12291 Whether the folder defined by the host path is writable or
12292 not.
12293 </desc>
12294 </attribute>
12295
12296 <attribute name="lastAccessError" type="wstring" readonly="yes">
12297 <desc>
12298 Text message that represents the result of the last accessibility
12299 check.
12300
12301 Accessibility checks are performed each time the <link to="#accessible"/>
12302 attribute is read. A @c null string is returned if the last
12303 accessibility check was successful. A non-null string indicates a
12304 failure and should normally describe a reason of the failure (for
12305 example, a file read error).
12306 </desc>
12307 </attribute>
12308
12309 </interface>
12310
12311 <!--
12312 // ISession
12313 /////////////////////////////////////////////////////////////////////////
12314 -->
12315
12316 <interface
12317 name="IInternalSessionControl" extends="$unknown"
12318 uuid="b26552e7-9534-4f47-b766-98eac648a90d"
12319 internal="yes"
12320 wsmap="suppress"
12321 >
12322 <method name="getPID">
12323 <desc>PID of the process that has created this Session object.
12324 </desc>
12325 <param name="pid" type="unsigned long" dir="return"/>
12326 </method>
12327
12328 <method name="getRemoteConsole">
12329 <desc>
12330 Returns the console object suitable for remote control.
12331
12332 <result name="VBOX_E_INVALID_VM_STATE">
12333 Session state prevents operation.
12334 </result>
12335 <result name="VBOX_E_INVALID_OBJECT_STATE">
12336 Session type prevents operation.
12337 </result>
12338
12339 </desc>
12340 <param name="console" type="IConsole" dir="return"/>
12341 </method>
12342
12343 <method name="assignMachine">
12344 <desc>
12345 Assigns the machine object associated with this direct-type
12346 session or informs the session that it will be a remote one
12347 (if @a machine == NULL).
12348
12349 <result name="VBOX_E_INVALID_VM_STATE">
12350 Session state prevents operation.
12351 </result>
12352 <result name="VBOX_E_INVALID_OBJECT_STATE">
12353 Session type prevents operation.
12354 </result>
12355
12356 </desc>
12357 <param name="machine" type="IMachine" dir="in"/>
12358 </method>
12359
12360 <method name="assignRemoteMachine">
12361 <desc>
12362 Assigns the machine and the (remote) console object associated with
12363 this remote-type session.
12364
12365 <result name="VBOX_E_INVALID_VM_STATE">
12366 Session state prevents operation.
12367 </result>
12368
12369 </desc>
12370 <param name="machine" type="IMachine" dir="in"/>
12371 <param name="console" type="IConsole" dir="in"/>
12372 </method>
12373
12374 <method name="updateMachineState">
12375 <desc>
12376 Updates the machine state in the VM process.
12377 Must be called only in certain cases
12378 (see the method implementation).
12379
12380 <result name="VBOX_E_INVALID_VM_STATE">
12381 Session state prevents operation.
12382 </result>
12383 <result name="VBOX_E_INVALID_OBJECT_STATE">
12384 Session type prevents operation.
12385 </result>
12386
12387 </desc>
12388 <param name="aMachineState" type="MachineState" dir="in"/>
12389 </method>
12390
12391 <method name="uninitialize">
12392 <desc>
12393 Uninitializes (closes) this session. Used by VirtualBox to close
12394 the corresponding remote session when the direct session dies
12395 or gets closed.
12396
12397 <result name="VBOX_E_INVALID_VM_STATE">
12398 Session state prevents operation.
12399 </result>
12400
12401 </desc>
12402 </method>
12403
12404 <method name="onDVDDriveChange">
12405 <desc>
12406 Triggered when settings of the DVD drive object of the
12407 associated virtual machine have changed.
12408
12409 <result name="VBOX_E_INVALID_VM_STATE">
12410 Session state prevents operation.
12411 </result>
12412 <result name="VBOX_E_INVALID_OBJECT_STATE">
12413 Session type prevents operation.
12414 </result>
12415
12416 </desc>
12417 </method>
12418
12419 <method name="onFloppyDriveChange">
12420 <desc>
12421 Triggered when settings of the floppy drive object of the
12422 associated virtual machine have changed.
12423
12424 <result name="VBOX_E_INVALID_VM_STATE">
12425 Session state prevents operation.
12426 </result>
12427 <result name="VBOX_E_INVALID_OBJECT_STATE">
12428 Session type prevents operation.
12429 </result>
12430
12431 </desc>
12432 </method>
12433
12434 <method name="onNetworkAdapterChange">
12435 <desc>
12436 Triggered when settings of a network adapter of the
12437 associated virtual machine have changed.
12438
12439 <result name="VBOX_E_INVALID_VM_STATE">
12440 Session state prevents operation.
12441 </result>
12442 <result name="VBOX_E_INVALID_OBJECT_STATE">
12443 Session type prevents operation.
12444 </result>
12445
12446 </desc>
12447 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
12448 </method>
12449
12450 <method name="onSerialPortChange">
12451 <desc>
12452 Triggered when settings of a serial port of the
12453 associated virtual machine have changed.
12454
12455 <result name="VBOX_E_INVALID_VM_STATE">
12456 Session state prevents operation.
12457 </result>
12458 <result name="VBOX_E_INVALID_OBJECT_STATE">
12459 Session type prevents operation.
12460 </result>
12461
12462 </desc>
12463 <param name="serialPort" type="ISerialPort" dir="in"/>
12464 </method>
12465
12466 <method name="onParallelPortChange">
12467 <desc>
12468 Triggered when settings of a parallel port of the
12469 associated virtual machine have changed.
12470
12471 <result name="VBOX_E_INVALID_VM_STATE">
12472 Session state prevents operation.
12473 </result>
12474 <result name="VBOX_E_INVALID_OBJECT_STATE">
12475 Session type prevents operation.
12476 </result>
12477
12478 </desc>
12479 <param name="parallelPort" type="IParallelPort" dir="in"/>
12480 </method>
12481
12482 <method name="onStorageControllerChange">
12483 <desc>
12484 Triggered when settings of a storage controller of the
12485 associated virtual machine have changed.
12486
12487 <result name="VBOX_E_INVALID_VM_STATE">
12488 Session state prevents operation.
12489 </result>
12490 <result name="VBOX_E_INVALID_OBJECT_STATE">
12491 Session type prevents operation.
12492 </result>
12493
12494 </desc>
12495 </method>
12496
12497 <method name="onVRDPServerChange">
12498 <desc>
12499 Triggered when settings of the VRDP server object of the
12500 associated virtual machine have changed.
12501
12502 <result name="VBOX_E_INVALID_VM_STATE">
12503 Session state prevents operation.
12504 </result>
12505 <result name="VBOX_E_INVALID_OBJECT_STATE">
12506 Session type prevents operation.
12507 </result>
12508
12509 </desc>
12510 </method>
12511
12512 <method name="onUSBControllerChange">
12513 <desc>
12514 Triggered when settings of the USB controller object of the
12515 associated virtual machine have changed.
12516
12517 <result name="VBOX_E_INVALID_VM_STATE">
12518 Session state prevents operation.
12519 </result>
12520 <result name="VBOX_E_INVALID_OBJECT_STATE">
12521 Session type prevents operation.
12522 </result>
12523
12524 </desc>
12525 </method>
12526
12527 <method name="onSharedFolderChange">
12528 <desc>
12529 Triggered when a permanent (global or machine) shared folder has been
12530 created or removed.
12531 <note>
12532 We don't pass shared folder parameters in this notification because
12533 the order in which parallel notifications are delivered is not defined,
12534 therefore it could happen that these parameters were outdated by the
12535 time of processing this notification.
12536 </note>
12537
12538 <result name="VBOX_E_INVALID_VM_STATE">
12539 Session state prevents operation.
12540 </result>
12541 <result name="VBOX_E_INVALID_OBJECT_STATE">
12542 Session type prevents operation.
12543 </result>
12544
12545 </desc>
12546 <param name="global" type="boolean" dir="in"/>
12547 </method>
12548
12549 <method name="onUSBDeviceAttach">
12550 <desc>
12551 Triggered when a request to capture a USB device (as a result
12552 of matched USB filters or direct call to
12553 <link to="IConsole::attachUSBDevice"/>) has completed.
12554 A @c null @a error object means success, otherwise it
12555 describes a failure.
12556
12557 <result name="VBOX_E_INVALID_VM_STATE">
12558 Session state prevents operation.
12559 </result>
12560 <result name="VBOX_E_INVALID_OBJECT_STATE">
12561 Session type prevents operation.
12562 </result>
12563
12564 </desc>
12565 <param name="device" type="IUSBDevice" dir="in"/>
12566 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12567 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
12568 </method>
12569
12570 <method name="onUSBDeviceDetach">
12571 <desc>
12572 Triggered when a request to release the USB device (as a result
12573 of machine termination or direct call to
12574 <link to="IConsole::detachUSBDevice"/>) has completed.
12575 A @c null @a error object means success, otherwise it
12576
12577 <result name="VBOX_E_INVALID_VM_STATE">
12578 Session state prevents operation.
12579 </result>
12580 <result name="VBOX_E_INVALID_OBJECT_STATE">
12581 Session type prevents operation.
12582 </result>
12583
12584 </desc>
12585 <param name="id" type="wstring" dir="in"/>
12586 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12587 </method>
12588
12589 <method name="onShowWindow">
12590 <desc>
12591 Called by <link to="IMachine::canShowConsoleWindow"/> and by
12592 <link to="IMachine::showConsoleWindow"/> in order to notify
12593 console callbacks
12594 <link to="IConsoleCallback::onCanShowWindow"/>
12595 and <link to="IConsoleCallback::onShowWindow"/>.
12596
12597 <result name="VBOX_E_INVALID_OBJECT_STATE">
12598 Session type prevents operation.
12599 </result>
12600
12601 </desc>
12602 <param name="check" type="boolean" dir="in"/>
12603 <param name="canShow" type="boolean" dir="out"/>
12604 <param name="winId" type="unsigned long long" dir="out"/>
12605 </method>
12606
12607 <method name="accessGuestProperty">
12608 <desc>
12609 Called by <link to="IMachine::getGuestProperty"/> and by
12610 <link to="IMachine::setGuestProperty"/> in order to read and
12611 modify guest properties.
12612
12613 <result name="VBOX_E_INVALID_VM_STATE">
12614 Machine session is not open.
12615 </result>
12616 <result name="VBOX_E_INVALID_OBJECT_STATE">
12617 Session type is not direct.
12618 </result>
12619
12620 </desc>
12621 <param name="name" type="wstring" dir="in"/>
12622 <param name="value" type="wstring" dir="in"/>
12623 <param name="flags" type="wstring" dir="in"/>
12624 <param name="isSetter" type="boolean" dir="in"/>
12625 <param name="retValue" type="wstring" dir="out"/>
12626 <param name="retTimestamp" type="unsigned long long" dir="out"/>
12627 <param name="retFlags" type="wstring" dir="out"/>
12628 </method>
12629
12630 <method name="enumerateGuestProperties">
12631 <desc>
12632 Return a list of the guest properties matching a set of patterns along
12633 with their values, time stamps and flags.
12634
12635 <result name="VBOX_E_INVALID_VM_STATE">
12636 Machine session is not open.
12637 </result>
12638 <result name="VBOX_E_INVALID_OBJECT_STATE">
12639 Session type is not direct.
12640 </result>
12641
12642 </desc>
12643 <param name="patterns" type="wstring" dir="in">
12644 <desc>
12645 The patterns to match the properties against as a comma-separated
12646 string. If this is empty, all properties currently set will be
12647 returned.
12648 </desc>
12649 </param>
12650 <param name="key" type="wstring" dir="out" safearray="yes">
12651 <desc>
12652 The key names of the properties returned.
12653 </desc>
12654 </param>
12655 <param name="value" type="wstring" dir="out" safearray="yes">
12656 <desc>
12657 The values of the properties returned. The array entries match the
12658 corresponding entries in the @a key array.
12659 </desc>
12660 </param>
12661 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
12662 <desc>
12663 The time stamps of the properties returned. The array entries match
12664 the corresponding entries in the @a key array.
12665 </desc>
12666 </param>
12667 <param name="flags" type="wstring" dir="out" safearray="yes">
12668 <desc>
12669 The flags of the properties returned. The array entries match the
12670 corresponding entries in the @a key array.
12671 </desc>
12672 </param>
12673 </method>
12674
12675 </interface>
12676
12677 <interface
12678 name="ISession" extends="$dispatched"
12679 uuid="12F4DCDB-12B2-4ec1-B7CD-DDD9F6C5BF4D"
12680 wsmap="managed"
12681 >
12682 <desc>
12683 The ISession interface represents a serialization primitive for virtual
12684 machines.
12685
12686 With VirtualBox, every time one wishes to manipulate a virtual machine
12687 (e.g. change its settings or start execution), a session object is
12688 required. Such an object must be passed to one of the session methods
12689 that open the given session, which then initiates the machine manipulation.
12690
12691 A session serves several purposes: it identifies to the inter-process VirtualBox
12692 code which process is currently working with the virtual machine, and it ensures
12693 that there are no incompatible requests from several processes for the
12694 same virtual machine. Session objects can therefore be thought of as mutex
12695 semaphores that lock virtual machines to prevent conflicting accesses from
12696 several processes.
12697
12698 How sessions objects are used depends on whether you use the Main API
12699 via COM or via the webservice:
12700
12701 <ul>
12702 <li>When using the COM API directly, an object of the Session class from the
12703 VirtualBox type library needs to be created. In regular COM C++ client code,
12704 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
12705 This object will then act as a local session object in further calls to open
12706 a session.
12707 </li>
12708
12709 <li>In the webservice, the session manager (IWebsessionManager) instead creates
12710 one session object automatically when <link to="IWebsessionManager::logon" />
12711 is called. A managed object reference to that session object can be retrieved by
12712 calling <link to="IWebsessionManager::getSessionObject" />. This session object
12713 reference can then be used to open sessions.
12714 </li>
12715 </ul>
12716
12717 Sessions are mainly used in two variations:
12718
12719 <ul>
12720 <li>
12721 To start a virtual machine in a separate process, one would call
12722 <link to="IVirtualBox::openRemoteSession"/>, which requires a session
12723 object as its first parameter. This session then identifies the caller
12724 and lets him control the started machine (for example, pause machine
12725 execution or power it down) as well as be notified about machine
12726 execution state changes.
12727 </li>
12728
12729 <li>To alter machine settings, or to start machine execution within the
12730 current process, one needs to open a direct session for the machine first by
12731 calling <link to="IVirtualBox::openSession"/>. While a direct session
12732 is open within one process, no any other process may open another direct
12733 session for the same machine. This prevents the machine from being changed
12734 by other processes while it is running or while the machine is being configured.
12735 </li>
12736 </ul>
12737
12738 One also can attach to an existing direct session already opened by
12739 another process (for example, in order to send a control request to the
12740 virtual machine such as the pause or the reset request). This is done by
12741 calling <link to="IVirtualBox::openExistingSession"/>.
12742
12743 <note>
12744 Unless you are trying to write a new VirtualBox front-end that
12745 performs direct machine execution (like the VirtualBox or VBoxSDL
12746 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
12747 session opened by <link to="IVirtualBox::openSession"/> and use this
12748 session only to change virtual machine settings. If you simply want to
12749 start virtual machine execution using one of the existing front-ends
12750 (for example the VirtualBox GUI or headless server), simply use
12751 <link to="IVirtualBox::openRemoteSession"/>; these front-ends
12752 will power up the machine automatically for you.
12753 </note>
12754 </desc>
12755
12756 <attribute name="state" type="SessionState" readonly="yes">
12757 <desc>Current state of this session.</desc>
12758 </attribute>
12759
12760 <attribute name="type" type="SessionType" readonly="yes">
12761 <desc>
12762 Type of this session. The value of this attribute is valid only
12763 if the session is currently open (i.e. its #state is
12764 SessionType_SessionOpen), otherwise an error will be returned.
12765 </desc>
12766 </attribute>
12767
12768 <attribute name="machine" type="IMachine" readonly="yes">
12769 <desc>Machine object associated with this session.</desc>
12770 </attribute>
12771
12772 <attribute name="console" type="IConsole" readonly="yes">
12773 <desc>Console object associated with this session.</desc>
12774 </attribute>
12775
12776 <method name="close">
12777 <desc>
12778 Closes a session that was previously opened.
12779
12780 It is recommended that every time an "open session" method (such as
12781 <link to="IVirtualBox::openRemoteSession" /> or
12782 <link to="IVirtualBox::openSession" />) has been called to
12783 manipulate a virtual machine, the caller invoke
12784 ISession::close() when it's done doing so. Since sessions are
12785 serialization primitives much like ordinary mutexes, they are
12786 best used the same way: for each "open" call, there should be
12787 a matching "close" call, even when errors occur.
12788
12789 Otherwise, if a direct session for a machine opened with
12790 <link to="IVirtualBox::openSession"/> is not explicitly closed
12791 when the application terminates, the state of the machine will
12792 be set to <link to="MachineState_Aborted" /> on the server.
12793
12794 Generally, it is recommended to close all open sessions explicitly
12795 before terminating the application (regardless of the reason for
12796 the termination).
12797
12798 <note>
12799 Do not expect the session state (<link to="ISession::state" />
12800 to return to "Closed" immediately after you invoke
12801 ISession::close(), particularly if you have started a remote
12802 session to execute the VM in a new process. The session state will
12803 automatically return to "Closed" once the VM is no longer executing,
12804 which can of course take a very long time.
12805 </note>
12806
12807 <result name="E_UNEXPECTED">
12808 Session is not open.
12809 </result>
12810
12811 </desc>
12812 </method>
12813
12814 </interface>
12815
12816 <!--
12817 // IStorageController
12818 /////////////////////////////////////////////////////////////////////////
12819 -->
12820
12821 <enum
12822 name="StorageBus"
12823 uuid="f381fdca-5953-41d0-b2bd-0542b012698d"
12824 >
12825 <desc>
12826 The connection type of the storage controller.
12827 </desc>
12828 <const name="Null" value="0">
12829 <desc><tt>null</tt> value. Never used by the API.</desc>
12830 </const>
12831 <const name="IDE" value="1"/>
12832 <const name="SATA" value="2"/>
12833 <const name="SCSI" value="3"/>
12834 </enum>
12835
12836 <enum
12837 name="StorageControllerType"
12838 uuid="685387db-a837-4320-a258-08f46a22f62a"
12839 >
12840 <desc>
12841 Storage controller type.
12842 </desc>
12843
12844 <const name="Null" value="0">
12845 <desc><tt>null</tt> value. Never used by the API.</desc>
12846 </const>
12847 <const name="LsiLogic" value="1"/>
12848 <const name="BusLogic" value="2"/>
12849 <const name="IntelAhci" value="3"/>
12850 <const name="PIIX3" value="4"/>
12851 <const name="PIIX4" value="5"/>
12852 <const name="ICH6" value="6"/>
12853 </enum>
12854
12855 <interface
12856 name="IStorageController" extends="$unknown"
12857 uuid="6bf8335b-d14a-44a5-9b45-ddc49ce7d5b2"
12858 wsmap="managed"
12859 >
12860 <desc>
12861 Represents a storage controller that is attached to a virtual machine
12862 (<link to="IMachine" />). Just as hard disks are attached to storage
12863 controllers in a real computer, virtual hard disks (represented by
12864 <link to="IHardDisk" />) are attached to virtual storage controllers,
12865 represented by this interface.
12866
12867 VirtualBox supports three types of virtual storage controller hardware:
12868 IDE, SCSI, and SATA (see <link to="#bus" />). Depending on which of
12869 these three is used, certain sub-types are available and can be
12870 selected in <link to="#controllerType" />.
12871 </desc>
12872
12873 <attribute name="name" type="wstring" readonly="yes">
12874 <desc>
12875 Name of the storage controller, as originally specified with
12876 <link to="IMachine::addStorageController" />. This then uniquely
12877 identifies this controller with other method calls such as
12878 <link to="IMachine::attachHardDisk" />.
12879 </desc>
12880 </attribute>
12881
12882 <attribute name="maxDevicesPerPortCount" type="unsigned long" readonly="yes">
12883 <desc>
12884 Maximum number of devices which can be attached to one port.
12885 </desc>
12886 </attribute>
12887
12888 <attribute name="minPortCount" type="unsigned long" readonly="yes">
12889 <desc>
12890 Minimum number of ports that <link to="IStorageController::portCount"/> can be set to.
12891 </desc>
12892 </attribute>
12893
12894 <attribute name="maxPortCount" type="unsigned long" readonly="yes">
12895 <desc>
12896 Maximum number of ports that <link to="IStorageController::portCount"/> can be set to.
12897 </desc>
12898 </attribute>
12899
12900 <attribute name="instance" type="unsigned long">
12901 <desc>
12902 The instance number of the device in the running VM.
12903 </desc>
12904 </attribute>
12905
12906 <attribute name="portCount" type="unsigned long">
12907 <desc>
12908 The number of currently usable ports on the controller.
12909 The minimum and maximum number of ports for one controller are
12910 stored in <link to="IStorageController::minPortCount"/>
12911 and <link to="IStorageController::maxPortCount"/>.
12912 </desc>
12913 </attribute>
12914
12915 <attribute name="bus" type="StorageBus" readonly="yes">
12916 <desc>
12917 The connection type of the storage controller.
12918 </desc>
12919 </attribute>
12920
12921 <attribute name="controllerType" type="StorageControllerType">
12922 <desc>
12923 Type of the virtual storage controller. Depending on this value,
12924 VirtualBox will provide a different virtual storage controller hardware
12925 to the guest.
12926
12927 For SCSI controllers, the default type is LsiLogic.
12928 </desc>
12929 </attribute>
12930
12931 <method name="GetIDEEmulationPort">
12932 <desc>
12933 Gets the corresponding port number which is emulated as an IDE device.
12934
12935 <result name="E_INVALIDARG">
12936 The @a devicePosition is not in the range 0 to 3.
12937 </result>
12938 <result name="E_NOTIMPL">
12939 The storage controller type is not SATAIntelAhci.
12940 </result>
12941
12942 </desc>
12943 <param name="devicePosition" type="long" dir="in"/>
12944 <param name="portNumber" type="long" dir="return"/>
12945 </method>
12946
12947 <method name="SetIDEEmulationPort">
12948 <desc>
12949 Sets the port number which is emulated as an IDE device.
12950
12951 <result name="E_INVALIDARG">
12952 The @a devicePosition is not in the range 0 to 3 or the
12953 @a portNumber is not in the range 0 to 29.
12954 </result>
12955 <result name="E_NOTIMPL">
12956 The storage controller type is not SATAIntelAhci.
12957 </result>
12958
12959 </desc>
12960 <param name="devicePosition" type="long" dir="in"/>
12961 <param name="portNumber" type="long" dir="in"/>
12962 </method>
12963
12964 </interface>
12965
12966<if target="wsdl">
12967
12968 <!--
12969 // IManagedObjectRef
12970 /////////////////////////////////////////////////////////////////////////
12971 -->
12972
12973 <interface
12974 name="IManagedObjectRef" extends="$unknown"
12975 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
12976 internal="yes"
12977 wsmap="managed"
12978 wscpp="hardcoded"
12979 >
12980 <desc>
12981 Managed object reference.
12982
12983 Only within the webservice, a managed object reference (which is really
12984 an opaque number) allows a webservice client to address an object
12985 that lives in the address space of the webservice server.
12986
12987 Behind each managed object reference, there is a COM object that lives
12988 in the webservice server's address space. The COM object is not freed
12989 until the managed object reference is released, either by an explicit
12990 call to <link to="IManagedObjectRef::release" /> or by logging off from
12991 the webservice (<link to="IWebsessionManager::logoff" />), which releases
12992 all objects created during the webservice session.
12993
12994 Whenever a method call of the VirtualBox API returns a COM object, the
12995 webservice representation of that method will instead return a
12996 managed object reference, which can then be used to invoke methods
12997 on that object.
12998 </desc>
12999
13000 <method name="getInterfaceName">
13001 <desc>
13002 Returns the name of the interface that this managed object represents,
13003 for example, "IMachine", as a string.
13004 </desc>
13005 <param name="return" type="wstring" dir="return"/>
13006 </method>
13007
13008 <method name="release">
13009 <desc>
13010 Releases this managed object reference and frees the resources that
13011 were allocated for it in the webservice server process. After calling
13012 this method, the identifier of the reference can no longer be used.
13013 </desc>
13014 </method>
13015
13016 </interface>
13017
13018 <!--
13019 // IWebsessionManager
13020 /////////////////////////////////////////////////////////////////////////
13021 -->
13022
13023 <interface
13024 name="IWebsessionManager" extends="$unknown"
13025 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
13026 internal="yes"
13027 wsmap="global"
13028 wscpp="hardcoded"
13029 >
13030 <desc>
13031 Websession manager. This provides essential services
13032 to webservice clients.
13033 </desc>
13034 <method name="logon">
13035 <desc>
13036 Logs a new client onto the webservice and returns a managed object reference to
13037 the IVirtualBox instance, which the client can then use as a basis to further
13038 queries, since all calls to the VirtualBox API are based on the IVirtualBox
13039 interface, in one way or the other.
13040 </desc>
13041 <param name="username" type="wstring" dir="in"/>
13042 <param name="password" type="wstring" dir="in"/>
13043 <param name="return" type="IVirtualBox" dir="return"/>
13044 </method>
13045
13046 <method name="getSessionObject">
13047 <desc>
13048 Returns a managed object reference to the internal ISession object that was created
13049 for this web service session when the client logged on.
13050
13051 <see>ISession</see>
13052 </desc>
13053 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13054 <param name="return" type="ISession" dir="return"/>
13055 </method>
13056
13057 <method name="logoff">
13058 <desc>
13059 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
13060 and destroys all resources associated with the session (most importantly, all
13061 managed objects created in the server while the session was active).
13062 </desc>
13063 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
13064 </method>
13065
13066 </interface>
13067
13068</if>
13069
13070 <!--
13071 // IPerformanceCollector & friends
13072 /////////////////////////////////////////////////////////////////////////
13073 -->
13074
13075 <interface
13076 name="IPerformanceMetric" extends="$unknown"
13077 uuid="2a1a60ae-9345-4019-ad53-d34ba41cbfe9" wsmap="managed"
13078 >
13079 <desc>
13080 The IPerformanceMetric interface represents parameters of the given
13081 performance metric.
13082 </desc>
13083
13084 <attribute name="metricName" type="wstring" readonly="yes">
13085 <desc>
13086 Name of the metric.
13087 </desc>
13088 </attribute>
13089
13090 <attribute name="object" type="$unknown" readonly="yes">
13091 <desc>
13092 Object this metric belongs to.
13093 </desc>
13094 </attribute>
13095
13096 <attribute name="description" type="wstring" readonly="yes">
13097 <desc>
13098 Textual description of the metric.
13099 </desc>
13100 </attribute>
13101
13102 <attribute name="period" type="unsigned long" readonly="yes">
13103 <desc>
13104 Time interval between samples, measured in seconds.
13105 </desc>
13106 </attribute>
13107
13108 <attribute name="count" type="unsigned long" readonly="yes">
13109 <desc>
13110 Number of recent samples retained by the performance collector for this
13111 metric.
13112
13113 When the collected sample count exceeds this number, older samples
13114 are discarded.
13115 </desc>
13116 </attribute>
13117
13118 <attribute name="unit" type="wstring" readonly="yes">
13119 <desc>
13120 Unit of measurement.
13121 </desc>
13122 </attribute>
13123
13124 <attribute name="minimumValue" type="long" readonly="yes">
13125 <desc>
13126 Minimum possible value of this metric.
13127 </desc>
13128 </attribute>
13129
13130 <attribute name="maximumValue" type="long" readonly="yes">
13131 <desc>
13132 Maximum possible value of this metric.
13133 </desc>
13134 </attribute>
13135 </interface>
13136
13137 <interface
13138 name="IPerformanceCollector" extends="$unknown"
13139 uuid="e22e1acb-ac4a-43bb-a31c-17321659b0c6"
13140 wsmap="managed"
13141 >
13142 <desc>
13143 The IPerformanceCollector interface represents a service that collects and
13144 stores performance metrics data.
13145
13146 Performance metrics are associated with objects of interfaces like IHost and
13147 IMachine. Each object has a distinct set of performance metrics.
13148 The set can be obtained with <link to="IPerformanceCollector::getMetrics"/>.
13149
13150 Metric data is collected at the specified intervals and is retained
13151 internally. The interval and the number of retained samples can be set
13152 with <link to="IPerformanceCollector::setupMetrics" />.
13153
13154 Metrics are organized hierarchically, with each level separated by a
13155 slash (/) character. Generally, the scheme for metric names is like this:
13156
13157 <tt>Category/Metric[/SubMetric][:aggregation]</tt>
13158
13159 "Category/Metric" together form the base metric name. A base metric is the
13160 smallest unit for which a sampling interval and the number of retained
13161 samples can be set. Only base metrics can be enabled and disabled. All
13162 sub-metrics are collected when their base metric is collected.
13163 Collected values for any set of sub-metrics can be queried with
13164 <link to="IPerformanceCollector::queryMetricsData" />.
13165
13166 For example "CPU/Load/User:avg"
13167 metric name stands for the "CPU" category, "Load" metric, "User" submetric,
13168 "average" aggregate. An aggregate function is computed over all retained
13169 data. Valid aggregate functions are:
13170
13171 <ul>
13172 <li>avg -- average</li>
13173 <li>min -- minimum</li>
13174 <li>max -- maximum</li>
13175 </ul>
13176
13177 When setting up
13178 metric parameters, querying metric data, enabling or disabling metrics
13179 wildcards can be used in metric names to specify a subset of metrics. For
13180 example, to select all CPU-related metrics use <tt>CPU/*</tt>, all
13181 averages can be queried using <tt>*:avg</tt> and so on. To query metric
13182 values without aggregates <tt>*:</tt> can be used.
13183
13184 The valid names for base metrics are:
13185
13186 <ul>
13187 <li>CPU/Load</li>
13188 <li>CPU/MHz</li>
13189 <li>RAM/Usage</li>
13190 </ul>
13191
13192 The general sequence for collecting and retrieving the metrics is:
13193 <ul>
13194 <li>
13195 Obtain an instance of IPerformanceCollector with
13196 <link to="IVirtualBox::performanceCollector" />
13197 </li>
13198 <li>
13199 Allocate and populate an array with references to objects the metrics
13200 will be collected for. Use references to IHost and IMachine objects.
13201 </li>
13202 <li>
13203 Allocate and populate an array with base metric names the data will be
13204 collected for.
13205 </li>
13206 <li>
13207 Call <link to="IPerformanceCollector::setupMetrics" />. From now on the
13208 metric data will be collected and stored.
13209 </li>
13210 <li>
13211 Wait for the data to get collected.
13212 </li>
13213 <li>
13214 Allocate and populate an array with references to objects the metric
13215 values will be queried for. You can re-use the object array used for
13216 setting base metrics.
13217 </li>
13218 <li>
13219 Allocate and populate an array with metric names the data will be
13220 collected for. Note that metric names differ from base metric names.
13221 </li>
13222 <li>
13223 Call <link to="IPerformanceCollector::queryMetricsData" />. The data that
13224 have been collected so far are returned. Note that the values are still
13225 retained internally and data collection continues.
13226 </li>
13227 </ul>
13228
13229 For an example of usage refer to the following files in VirtualBox SDK:
13230 <ul>
13231 <li>
13232 Java: <tt>bindings/webservice/java/jax-ws/samples/metrictest.java</tt>
13233 </li>
13234 <li>
13235 Python: <tt>bindings/xpcom/python/sample/shellcommon.py</tt>
13236 </li>
13237 </ul>
13238 </desc>
13239
13240 <attribute name="metricNames" type="wstring" readonly="yes" safearray="yes">
13241 <desc>
13242 Array of unique names of metrics.
13243
13244 This array represents all metrics supported by the performance
13245 collector. Individual objects do not necessarily support all of them.
13246 <link to="IPerformanceCollector::getMetrics"/> can be used to get the
13247 list of supported metrics for a particular object.
13248 </desc>
13249 </attribute>
13250
13251 <method name="getMetrics">
13252 <desc>
13253 Returns parameters of specified metrics for a set of objects.
13254 <note>
13255 @c Null metrics array means all metrics. @c Null object array means
13256 all existing objects.
13257 </note>
13258 </desc>
13259 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13260 <desc>
13261 Metric name filter. Currently, only a comma-separated list of metrics
13262 is supported.
13263 </desc>
13264 </param>
13265 <param name="objects" type="$unknown" dir="in" safearray="yes">
13266 <desc>
13267 Set of objects to return metric parameters for.
13268 </desc>
13269 </param>
13270 <param name="metrics" type="IPerformanceMetric" dir="return" safearray="yes">
13271 <desc>
13272 Array of returned metric parameters.
13273 </desc>
13274 </param>
13275 </method>
13276
13277 <method name="setupMetrics">
13278 <desc>
13279 Sets parameters of specified base metrics for a set of objects. Returns
13280 an array of <link to="IPerformanceMetric" /> describing the metrics have
13281 been affected.
13282 <note>
13283 @c Null or empty metric name array means all metrics. @c Null or empty
13284 object array means all existing objects. If metric name array contains
13285 a single element and object array contains many, the single metric
13286 name array element is applied to each object array element to form
13287 metric/object pairs.
13288 </note>
13289 </desc>
13290 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13291 <desc>
13292 Metric name filter. Comma-separated list of metrics with wildcard
13293 support.
13294 </desc>
13295 </param>
13296 <param name="objects" type="$unknown" dir="in" safearray="yes">
13297 <desc>
13298 Set of objects to setup metric parameters for.
13299 </desc>
13300 </param>
13301 <param name="period" type="unsigned long" dir="in">
13302 <desc>
13303 Time interval in seconds between two consecutive samples of performance
13304 data.
13305 </desc>
13306 </param>
13307 <param name="count" type="unsigned long" dir="in">
13308 <desc>
13309 Number of samples to retain in performance data history. Older samples
13310 get discarded.
13311 </desc>
13312 </param>
13313 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13314 <desc>
13315 Array of metrics that have been modified by the call to this method.
13316 </desc>
13317 </param>
13318 </method>
13319
13320 <method name="enableMetrics">
13321 <desc>
13322 Turns on collecting specified base metrics. Returns an array of
13323 <link to="IPerformanceMetric" /> describing the metrics have been
13324 affected.
13325 <note>
13326 @c Null or empty metric name array means all metrics. @c Null or empty
13327 object array means all existing objects. If metric name array contains
13328 a single element and object array contains many, the single metric
13329 name array element is applied to each object array element to form
13330 metric/object pairs.
13331 </note>
13332 </desc>
13333 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13334 <desc>
13335 Metric name filter. Comma-separated list of metrics with wildcard
13336 support.
13337 </desc>
13338 </param>
13339 <param name="objects" type="$unknown" dir="in" safearray="yes">
13340 <desc>
13341 Set of objects to enable metrics for.
13342 </desc>
13343 </param>
13344 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13345 <desc>
13346 Array of metrics that have been modified by the call to this method.
13347 </desc>
13348 </param>
13349 </method>
13350
13351 <method name="disableMetrics">
13352 <desc>
13353 Turns off collecting specified base metrics. Returns an array of
13354 <link to="IPerformanceMetric" /> describing the metrics have been
13355 affected.
13356 <note>
13357 @c Null or empty metric name array means all metrics. @c Null or empty
13358 object array means all existing objects. If metric name array contains
13359 a single element and object array contains many, the single metric
13360 name array element is applied to each object array element to form
13361 metric/object pairs.
13362 </note>
13363 </desc>
13364 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13365 <desc>
13366 Metric name filter. Comma-separated list of metrics with wildcard
13367 support.
13368 </desc>
13369 </param>
13370 <param name="objects" type="$unknown" dir="in" safearray="yes">
13371 <desc>
13372 Set of objects to disable metrics for.
13373 </desc>
13374 </param>
13375 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
13376 <desc>
13377 Array of metrics that have been modified by the call to this method.
13378 </desc>
13379 </param>
13380 </method>
13381
13382 <method name="queryMetricsData">
13383 <desc>
13384 Queries collected metrics data for a set of objects.
13385
13386 The data itself and related metric information are returned in seven
13387 parallel and one flattened array of arrays. Elements of
13388 <tt>returnMetricNames, returnObjects, returnUnits, returnScales,
13389 returnSequenceNumbers, returnDataIndices and returnDataLengths</tt> with
13390 the same index describe one set of values corresponding to a single
13391 metric.
13392
13393 The <tt>returnData</tt> parameter is a flattened array of arrays. Each
13394 start and length of a sub-array is indicated by
13395 <tt>returnDataIndices</tt> and <tt>returnDataLengths</tt>. The first
13396 value for metric <tt>metricNames[i]</tt> is at
13397 <tt>returnData[returnIndices[i]]</tt>.
13398
13399 <note>
13400 @c Null or empty metric name array means all metrics. @c Null or empty
13401 object array means all existing objects. If metric name array contains
13402 a single element and object array contains many, the single metric
13403 name array element is applied to each object array element to form
13404 metric/object pairs.
13405 </note>
13406 <note>
13407 Data collection continues behind the scenes after call to
13408 @c queryMetricsData. The return data can be seen as the snapshot of
13409 the current state at the time of @c queryMetricsData call. The
13410 internally kept metric values are not cleared by the call. This makes
13411 possible querying different subsets of metrics or aggregates with
13412 subsequent calls. If periodic querying is needed it is highly
13413 suggested to query the values with @c interval*count period to avoid
13414 confusion. This way a completely new set of data values will be
13415 provided by each query.
13416 </note>
13417 </desc>
13418 <param name="metricNames" type="wstring" dir="in" safearray="yes">
13419 <desc>
13420 Metric name filter. Comma-separated list of metrics with wildcard
13421 support.
13422 </desc>
13423 </param>
13424 <param name="objects" type="$unknown" dir="in" safearray="yes">
13425 <desc>
13426 Set of objects to query metrics for.
13427 </desc>
13428 </param>
13429 <param name="returnMetricNames" type="wstring" dir="out" safearray="yes">
13430 <desc>
13431 Names of metrics returned in @c returnData.
13432 </desc>
13433 </param>
13434 <param name="returnObjects" type="$unknown" dir="out" safearray="yes">
13435 <desc>
13436 Objects associated with metrics returned in @c returnData.
13437 </desc>
13438 </param>
13439 <param name="returnUnits" type="wstring" dir="out" safearray="yes">
13440 <desc>
13441 Units of measurement for each returned metric.
13442 </desc>
13443 </param>
13444 <param name="returnScales" type="unsigned long" dir="out" safearray="yes">
13445 <desc>
13446 Divisor that should be applied to return values in order to get
13447 floating point values. For example:
13448 <tt>(double)returnData[returnDataIndices[0]+i] / returnScales[0]</tt>
13449 will retrieve the floating point value of i-th sample of the first
13450 metric.
13451 </desc>
13452 </param>
13453 <param name="returnSequenceNumbers" type="unsigned long" dir="out" safearray="yes">
13454 <desc>
13455 Sequence numbers of the first elements of value sequences of particular metrics
13456 returned in @c returnData. For aggregate metrics it is the sequence number of
13457 the sample the aggregate started calculation from.
13458 </desc>
13459 </param>
13460 <param name="returnDataIndices" type="unsigned long" dir="out" safearray="yes">
13461 <desc>
13462 Indices of the first elements of value sequences of particular metrics
13463 returned in @c returnData.
13464 </desc>
13465 </param>
13466 <param name="returnDataLengths" type="unsigned long" dir="out" safearray="yes">
13467 <desc>
13468 Lengths of value sequences of particular metrics.
13469 </desc>
13470 </param>
13471 <param name="returnData" type="long" dir="return" safearray="yes">
13472 <desc>
13473 Flattened array of all metric data containing sequences of values for
13474 each metric.
13475 </desc>
13476 </param>
13477 </method>
13478
13479 </interface>
13480
13481 <module name="VBoxSVC" context="LocalServer">
13482 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
13483 namespace="virtualbox.org">
13484 <interface name="IVirtualBox" default="yes"/>
13485 </class>
13486 </module>
13487
13488 <module name="VBoxC" context="InprocServer" threadingModel="Free">
13489 <class name="Session" uuid="3C02F46D-C9D2-4f11-A384-53F0CF917214"
13490 namespace="virtualbox.org">
13491 <interface name="ISession" default="yes"/>
13492 </class>
13493 </module>
13494
13495</library>
13496
13497</idl>
13498
13499<!-- 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