VirtualBox

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

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

OVF: added count attribute to receive the current number of entries

  • Property svn:eol-style set to native
File size: 468.9 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-2008 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="MachineState"
363 uuid="73bf04d0-7c4f-4684-9abf-d65a9ad74343"
364 >
365 <desc>
366 Virtual machine execution state.
367
368 This enumeration represents possible values of the <link
369 to="IMachine::state"/> attribute.
370
371 Below is the basic virtual machine state diagram. It shows how the state
372 changes during virtual machine execution. The text in square braces shows
373 a method of the IConsole interface that performs the given state
374 transition.
375
376 <pre>
377 +---------[powerDown()] &lt;- Stuck &lt;--[failure]-+
378 V |
379 +-&gt; PoweredOff --+--&gt;[powerUp()]--&gt; Starting --+ | +-----[resume()]-----+
380 | | | | V |
381 | Aborted -----+ +--&gt; Running --[pause()]--&gt; Paused
382 | | ^ | ^ |
383 | Saved -----------[powerUp()]--&gt; Restoring -+ | | | |
384 | ^ | | | |
385 | | +-----------------------------------------+-|-------------------+ +
386 | | | | |
387 | | +-- Saving &lt;--------[takeSnapshot()]&lt;-------+---------------------+
388 | | | |
389 | +-------- Saving &lt;--------[saveState()]&lt;----------+---------------------+
390 | | |
391 +-------------- Stopping -------[powerDown()]&lt;----------+---------------------+
392 </pre>
393
394 Note that states to the right from PoweredOff, Aborted and Saved in the
395 above diagram are called <i>online VM states</i>. These states
396 represent the virtual machine which is being executed in a dedicated
397 process (usually with a GUI window attached to it where you can see the
398 activity of the virtual machine and interact with it). There are two
399 special pseudo-states, FirstOnline and LastOnline, that can be used in
400 relational expressions to detect if the given machine state is online or
401 not:
402
403 <pre>
404 if (machine.GetState() &gt;= MachineState_FirstOnline &amp;&amp;
405 machine.GetState() &lt;= MachineState_LastOnline)
406 {
407 ...the machine is being executed...
408 }
409 </pre>
410
411 When the virtual machine is in one of the online VM states (that is, being
412 executed), only a few machine settings can be modified. Methods working
413 with such settings contain an explicit note about that. An attempt to
414 change any oter setting or perform a modifying operation during this time
415 will result in the <link to="VBOX_E_INVALID_VM_STATE"/> error.
416
417 All online states except Running, Paused and Stuck are transitional: they
418 represent temporary conditions of the virtual machine that will last as
419 long as the operation that initiated such a condition.
420
421 The Stuck state is a special case. It means that execution of the machine
422 has reached the "Guru Meditation" condition. This condition indicates an
423 internal VMM (virtual machine manager) failure which may happen as a
424 result of either an unhandled low-level virtual hardware exception or one
425 of the recompiler exceptions (such as the <i>too-many-traps</i>
426 condition).
427
428 Note also that any online VM state may transit to the Aborted state. This
429 happens if the process that is executing the virtual machine terminates
430 unexpectedly (for example, crashes). Other than that, the Aborted state is
431 equivalent to PoweredOff.
432
433 There are also a few additional state diagrams that do not deal with
434 virtual machine execution and therefore are shown separately. The states
435 shown on these diagrams are called <i>offline VM states</i> (this includes
436 PoweredOff, Aborted and Saved too).
437
438 The first diagram shows what happens when a lengthy setup operation is
439 being executed (such as <link to="IMachine::attachHardDisk2()"/>).
440
441 <pre>
442 +-----------------------------------(same sate as before the call)------+
443 | |
444 +-&gt; PoweredOff --+ |
445 | | |
446 |-&gt; Aborted -----+--&gt;[lengthy VM configuration call] --&gt; SettingUp -----+
447 | |
448 +-&gt; Saved -------+
449 </pre>
450
451 The next two diagrams demonstrate the process of taking a snapshot of a
452 powered off virtual machine and performing one of the "discard..."
453 operations, respectively.
454
455 <pre>
456 +-----------------------------------(same sate as before the call)------+
457 | |
458 +-&gt; PoweredOff --+ |
459 | +--&gt;[takeSnapshot()] -------------------&gt; Saving ------+
460 +-&gt; Aborted -----+
461
462 +-&gt; PoweredOff --+
463 | |
464 | Aborted -----+--&gt;[discardSnapshot() ]-------------&gt; Discarding --+
465 | | [discardCurrentState()] |
466 +-&gt; Saved -------+ [discardCurrentSnapshotAndState()] |
467 | |
468 +---(Saved if restored from an online snapshot, PoweredOff otherwise)---+
469 </pre>
470
471 Note that the Saving state is present in both the offline state group and
472 online state group. Currently, the only way to determine what group is
473 assumed in a particular case is to remember the previous machine state: if
474 it was Running or Paused, then Saving is an online state, otherwise it is
475 an offline state. This inconsistency may be removed in one of the future
476 versions of VirtualBox by adding a new state.
477
478 <note internal="yes">
479 For whoever decides to touch this enum: In order to keep the
480 comparisons involving FirstOnline and LastOnline pseudo-states valid,
481 the numeric values of these states must be correspondingly updated if
482 needed: for any online VM state, the condition
483 <tt>FirstOnline &lt;= state &lt;= LastOnline</tt> must be
484 <tt>true</tt>. The same relates to transient states for which
485 the condition <tt>FirstOnline &lt;= state &lt;= LastOnline</tt> must be
486 <tt>true</tt>.
487 </note>
488 </desc>
489
490 <const name="Null" value="0">
491 <desc>Null value (nver used by the API).</desc>
492 </const>
493 <const name="PoweredOff" value="1">
494 <desc>
495 The machine is not running.
496 </desc>
497 </const>
498 <const name="Saved" value="2">
499 <desc>
500 The machine is not currently running, but the execution state of the machine
501 has been saved to an external file when it was running.
502 </desc>
503 </const>
504 <const name="Aborted" value="3">
505 <desc>
506 The process running the machine has terminated abnormally.
507 </desc>
508 </const>
509 <const name="Running" value="4">
510 <desc>
511 The machine is currently being executed.
512 <note internal="yes">
513 For whoever decides to touch this enum: In order to keep the
514 comparisons in the old source code valid, this state must immediately
515 precede the Paused state.
516 </note>
517 </desc>
518 </const>
519 <const name="Paused" value="5">
520 <desc>
521 Execution of the machine has been paused.
522 <note internal="yes">
523 For whoever decides to touch this enum: In order to keep the
524 comparisons in the old source code valid, this state must immediately
525 follow the Running state.
526 </note>
527 </desc>
528 </const>
529 <const name="Stuck" value="6">
530 <desc>
531 Execution of the machine has reached the "Guru Meditation"
532 condition.
533 </desc>
534 </const>
535 <const name="Starting" value="7">
536 <desc>
537 Machine is being started after powering it on from a
538 zero execution state.
539 </desc>
540 </const>
541 <const name="Stopping" value="8">
542 <desc>
543 Machine is being normally stopped powering it off, or after the guest OS
544 has initiated a shutdown sequence.
545 </desc>
546 </const>
547 <const name="Saving" value="9">
548 <desc>
549 Machine is saving its execution state to a file or an online
550 snapshot of the machine is being taken.
551 </desc>
552 </const>
553 <const name="Restoring" value="10">
554 <desc>
555 Execution state of the machine is being restored from a file
556 after powering it on from the saved execution state.
557 </desc>
558 </const>
559 <const name="Discarding" value="11">
560 <desc>
561 Snapshot of the machine is being discarded.
562 </desc>
563 </const>
564 <const name="SettingUp" value="12">
565 <desc>
566 Lengthy setup operation is in progress.
567 </desc>
568 </const>
569
570 <const name="FirstOnline" value="4" wsmap="suppress"> <!-- Running -->
571 <desc>
572 Pseudo-state: first online state (for use in relational expressions).
573 </desc>
574 </const>
575 <const name="LastOnline" value="10" wsmap="suppress"> <!-- Restoring -->
576 <desc>
577 Pseudo-state: last online state (for use in relational expressions).
578 </desc>
579 </const>
580
581 <const name="FirstTransient" value="7" wsmap="suppress"> <!-- Starting -->
582 <desc>
583 Pseudo-state: first transient state (for use in relational expressions).
584 </desc>
585 </const>
586 <const name="LastTransient" value="12" wsmap="suppress"> <!-- SettingUp -->
587 <desc>
588 Pseudo-state: last transient state (for use in relational expressions).
589 </desc>
590 </const>
591
592 </enum>
593
594 <enum
595 name="SessionState"
596 uuid="CF2700C0-EA4B-47ae-9725-7810114B94D8"
597 >
598 <desc>
599 Session state. This enumeration represents possible values of
600 <link to="IMachine::sessionState"/> and <link to="ISession::state"/>
601 attributes. See individual enumerator descriptions for the meaning for
602 every value.
603 </desc>
604
605 <const name="Null" value="0">
606 <desc>Null value (never used by the API).</desc>
607 </const>
608 <const name="Closed" value="1">
609 <desc>
610 The machine has no open sessions (<link to="IMachine::sessionState"/>);
611 the session is closed (<link to="ISession::state"/>)
612 </desc>
613 </const>
614 <const name="Open" value="2">
615 <desc>
616 The machine has an open direct session (<link to="IMachine::sessionState"/>);
617 the session is open (<link to="ISession::state"/>)
618 </desc>
619 </const>
620 <const name="Spawning" value="3">
621 <desc>
622 A new (direct) session is being opened for the machine
623 as a result of <link to="IVirtualBox::openRemoteSession()"/>
624 call (<link to="IMachine::sessionState"/>);
625 the session is currently being opened
626 as a result of <link to="IVirtualBox::openRemoteSession()"/>
627 call (<link to="ISession::state"/>)
628 </desc>
629 </const>
630 <const name="Closing" value="4">
631 <desc>
632 The direct session is being closed (<link to="IMachine::sessionState"/>);
633 the session is being closed (<link to="ISession::state"/>)
634 </desc>
635 </const>
636 </enum>
637
638 <enum
639 name="SessionType"
640 uuid="A13C02CB-0C2C-421E-8317-AC0E8AAA153A"
641 >
642 <desc>
643 Session type. This enumeration represents possible values of the
644 <link to="ISession::type"/> attribute.
645 </desc>
646
647 <const name="Null" value="0">
648 <desc>Null value (never used by the API).</desc>
649 </const>
650 <const name="Direct" value="1">
651 <desc>
652 Direct session
653 (opened by <link to="IVirtualBox::openSession()"/>)
654 </desc>
655 </const>
656 <const name="Remote" value="2">
657 <desc>
658 Remote session
659 (opened by <link to="IVirtualBox::openRemoteSession()"/>)
660 </desc>
661 </const>
662 <const name="Existing" value="3">
663 <desc>
664 Existing session
665 (opened by <link to="IVirtualBox::openExistingSession()"/>)
666 </desc>
667 </const>
668 </enum>
669
670 <enum
671 name="DeviceType"
672 uuid="6d9420f7-0b56-4636-99f9-7346f1b01e57"
673 >
674 <desc>
675 Device type.
676 </desc>
677 <const name="Null" value="0">
678 <desc>
679 Null value, may also mean "no device" (not allowed for
680 <link to="IConsole::getDeviceActivity"/>).
681 </desc>
682 </const>
683 <const name="Floppy" value="1">
684 <desc>Floppy device.</desc>
685 </const>
686 <const name="DVD" value="2">
687 <desc>CD/DVD-ROM device.</desc>
688 </const>
689 <const name="HardDisk" value="3">
690 <desc>Hard disk device.</desc>
691 </const>
692 <const name="Network" value="4">
693 <desc>Network device.</desc>
694 </const>
695 <const name="USB" value="5">
696 <desc>USB device.</desc>
697 </const>
698 <const name="SharedFolder" value="6">
699 <desc>Shared folder device.</desc>
700 </const>
701 </enum>
702
703 <enum
704 name="DeviceActivity"
705 uuid="6FC8AEAA-130A-4eb5-8954-3F921422D707"
706 >
707 <desc>
708 Device activity for <link to="IConsole::getDeviceActivity"/>.
709 </desc>
710
711 <const name="Null" value="0"/>
712 <const name="Idle" value="1"/>
713 <const name="Reading" value="2"/>
714 <const name="Writing" value="3"/>
715 </enum>
716
717 <enum
718 name="StorageBus"
719 uuid="715984a5-093c-43bb-aa42-a16ed16828dd"
720 >
721 <desc>Interface bus type for storage devices.</desc>
722
723 <const name="Null" value="0">
724 <desc>Null value (never used by the API).</desc>
725 </const>
726
727 <const name="IDE" value="1"/>
728 <const name="SATA" value="2"/>
729 </enum>
730
731 <enum
732 name="ClipboardMode"
733 uuid="33364716-4008-4701-8f14-be0fa3d62950"
734 >
735 <desc>
736 Host-Guest clipboard interchange mode.
737 </desc>
738
739 <const name="Disabled" value="0"/>
740 <const name="HostToGuest" value="1"/>
741 <const name="GuestToHost" value="2"/>
742 <const name="Bidirectional" value="3"/>
743 </enum>
744
745 <enum
746 name="Scope"
747 uuid="7c91096e-499e-4eca-9f9b-9001438d7855"
748 >
749 <desc>
750 Scope of the operation.
751
752 A generic enumeration used in various methods to define the action or
753 argument scope.
754 </desc>
755
756 <const name="Global" value="0"/>
757 <const name="Machine" value="1"/>
758 <const name="Session" value="2"/>
759 </enum>
760
761 <enum
762 name="GuestStatisticType"
763 uuid="aa7c1d71-aafe-47a8-9608-27d2d337cf55"
764 >
765 <desc>
766 Statistics type for <link to="IGuest::getStatistic"/>.
767 </desc>
768
769 <const name="CPULoad_Idle" value="0">
770 <desc>
771 Idle CPU load (0-100%) for last interval.
772 </desc>
773 </const>
774 <const name="CPULoad_Kernel" value="1">
775 <desc>
776 Kernel CPU load (0-100%) for last interval.
777 </desc>
778 </const>
779 <const name="CPULoad_User" value="2">
780 <desc>
781 User CPU load (0-100%) for last interval.
782 </desc>
783 </const>
784 <const name="Threads" value="3">
785 <desc>
786 Total number of threads in the system.
787 </desc>
788 </const>
789 <const name="Processes" value="4">
790 <desc>
791 Total number of processes in the system.
792 </desc>
793 </const>
794 <const name="Handles" value="5">
795 <desc>
796 Total number of handles in the system.
797 </desc>
798 </const>
799 <const name="MemoryLoad" value="6">
800 <desc>
801 Memory load (0-100%).
802 </desc>
803 </const>
804 <const name="PhysMemTotal" value="7">
805 <desc>
806 Total physical memory in megabytes.
807 </desc>
808 </const>
809 <const name="PhysMemAvailable" value="8">
810 <desc>
811 Free physical memory in megabytes.
812 </desc>
813 </const>
814 <const name="PhysMemBalloon" value="9">
815 <desc>
816 Ballooned physical memory in megabytes.
817 </desc>
818 </const>
819 <const name="MemCommitTotal" value="10">
820 <desc>
821 Total amount of memory in the committed state in megabytes.
822 </desc>
823 </const>
824 <const name="MemKernelTotal" value="11">
825 <desc>
826 Total amount of memory used by the guest OS's kernel in megabytes.
827 </desc>
828 </const>
829 <const name="MemKernelPaged" value="12">
830 <desc>
831 Total amount of paged memory used by the guest OS's kernel in megabytes.
832 </desc>
833 </const>
834 <const name="MemKernelNonpaged" value="13">
835 <desc>
836 Total amount of non-paged memory used by the guest OS's kernel in megabytes.
837 </desc>
838 </const>
839 <const name="MemSystemCache" value="14">
840 <desc>
841 Total amount of memory used by the guest OS's system cache in megabytes.
842 </desc>
843 </const>
844 <const name="PageFileSize" value="15">
845 <desc>
846 Pagefile size in megabytes.
847 </desc>
848 </const>
849 <const name="SampleNumber" value="16">
850 <desc>
851 Statistics sample number
852 </desc>
853 </const>
854 <const name="MaxVal" value="17"/>
855 </enum>
856
857 <enum
858 name="BIOSBootMenuMode"
859 uuid="ae4fb9f7-29d2-45b4-b2c7-d579603135d5"
860 >
861 <desc>
862 BIOS boot menu mode.
863 </desc>
864
865 <const name="Disabled" value="0"/>
866 <const name="MenuOnly" value="1"/>
867 <const name="MessageAndMenu" value="2"/>
868 </enum>
869
870 <enum
871 name="IDEControllerType"
872 uuid="445330e3-202a-4dab-854f-ce22e6cb9715"
873 >
874 <desc>
875 IDE controller type.
876 </desc>
877
878 <const name="Null" value="0">
879 <desc>Null value (never used by the API).</desc>
880 </const>
881 <const name="PIIX3" value="1"/>
882 <const name="PIIX4" value="2"/>
883 </enum>
884
885 <enum
886 name="DriveState"
887 uuid="cb7233b7-c519-42a5-8310-1830953cacbc"
888 >
889 <const name="Null" value="0">
890 <desc>Null value (never used by the API).</desc>
891 </const>
892 <const name="NotMounted" value="1"/>
893 <const name="ImageMounted" value="2"/>
894 <const name="HostDriveCaptured" value="3"/>
895 </enum>
896
897 <enum
898 name="ProcessorFeature"
899 uuid="b8353b35-705d-4796-9967-ebfb7ba54af4"
900 >
901 <desc>
902 CPU features.
903 </desc>
904
905 <const name="HWVirtEx" value="0"/>
906 <const name="PAE" value="1"/>
907 <const name="LongMode" value="2"/>
908 </enum>
909
910
911 <!--
912 // IVirtualBoxErrorInfo
913 /////////////////////////////////////////////////////////////////////////
914 -->
915
916 <interface
917 name="IVirtualBoxErrorInfo" extends="$errorinfo"
918 uuid="e98b5376-8eb4-4eea-812a-3964bf3bb26f"
919 supportsErrorInfo="no"
920 wsmap="suppress"
921 >
922 <desc>
923 The IVirtualBoxErrorInfo interface represents extended error information.
924
925 Extended error information can be set by VirtualBox components after
926 unsuccessful or partially successful method invocation. This information
927 can be retrieved by the calling party as an IVirtualBoxErrorInfo object
928 and then shown to the client in addition to the plain 32-bit result code.
929
930 In MS COM, this interface extends the IErrorInfo interface,
931 in XPCOM, it extends the nsIException interface. In both cases,
932 it provides a set of common attributes to retrieve error
933 information.
934
935 Sometimes invocation of some component's method may involve methods of
936 other components that may also fail (independently of this method's
937 failure), or a series of non-fatal errors may precede a fatal error that
938 causes method failure. In cases like that, it may be desirable to preserve
939 information about all errors happened during method invocation and deliver
940 it to the caller. The <link to="#next"/> attribute is intended
941 specifically for this purpose and allows to represent a chain of errors
942 through a single IVirtualBoxErrorInfo object set after method invocation.
943
944 Note that errors are stored to a chain in the reverse order, i.e. the
945 initial error object you query right after method invocation is the last
946 error set by the callee, the object it points to in the @a next attribute
947 is the previous error and so on, up to the first error (which is the last
948 in the chain).
949 </desc>
950
951 <attribute name="resultCode" type="result" readonly="yes">
952 <desc>
953 Result code of the error.
954 Usually, it will be the same as the result code returned
955 by the method that provided this error information, but not
956 always. For example, on Win32, CoCreateInstance() will most
957 likely return E_NOINTERFACE upon unsuccessful component
958 instantiation attempt, but not the value the component factory
959 returned.
960 <note>
961 In MS COM, there is no equivalent.
962 In XPCOM, it is the same as nsIException::result.
963 </note>
964 </desc>
965 </attribute>
966
967 <attribute name="interfaceID" type="uuid" readonly="yes">
968 <desc>
969 UUID of the interface that defined the error.
970 <note>
971 In MS COM, it is the same as IErrorInfo::GetGUID.
972 In XPCOM, there is no equivalent.
973 </note>
974 </desc>
975 </attribute>
976
977 <attribute name="component" type="wstring" readonly="yes">
978 <desc>
979 Name of the component that generated the error.
980 <note>
981 In MS COM, it is the same as IErrorInfo::GetSource.
982 In XPCOM, there is no equivalent.
983 </note>
984 </desc>
985 </attribute>
986
987 <attribute name="text" type="wstring" readonly="yes">
988 <desc>
989 Text description of the error.
990 <note>
991 In MS COM, it is the same as IErrorInfo::GetDescription.
992 In XPCOM, it is the same as nsIException::message.
993 </note>
994 </desc>
995 </attribute>
996
997 <attribute name="next" type="IVirtualBoxErrorInfo" readonly="yes">
998 <desc>
999 Next error object if there is any, or @c null otherwise.
1000 <note>
1001 In MS COM, there is no equivalent.
1002 In XPCOM, it is the same as nsIException::inner.
1003 </note>
1004 </desc>
1005 </attribute>
1006
1007 </interface>
1008
1009
1010 <!--
1011 // IVirtualBox
1012 /////////////////////////////////////////////////////////////////////////
1013 -->
1014
1015 <interface
1016 name="IVirtualBoxCallback" extends="$unknown"
1017 uuid="5516cc08-fb81-47a6-b184-031e7bbd2997"
1018 wsmap="suppress"
1019 >
1020 <method name="onMachineStateChange">
1021 <desc>
1022 The execution state of the given machine has changed.
1023 <see>IMachine::state</see>
1024 </desc>
1025 <param name="machineId" type="uuid" dir="in">
1026 <desc>ID of the machine this event relates to.</desc>
1027 </param>
1028 <param name="state" type="MachineState" dir="in">
1029 <desc>New execution state.</desc>
1030 </param>
1031 </method>
1032
1033 <method name="onMachineDataChange">
1034 <desc>
1035 Any of the settings of the given machine has changed.
1036 </desc>
1037 <param name="machineId" type="uuid" dir="in">
1038 <desc>ID of the machine this event relates to.</desc>
1039 </param>
1040 </method>
1041
1042 <method name="onExtraDataCanChange">
1043 <desc>
1044 Notification when someone tries to change extra data for
1045 either the given machine or (if null) global extra data.
1046 This gives the chance to veto against changes.
1047 </desc>
1048 <param name="machineId" type="uuid" dir="in">
1049 <desc>
1050 ID of the machine this event relates to
1051 (null ID for global extra data change requests).
1052 </desc>
1053 </param>
1054 <param name="key" type="wstring" dir="in">
1055 <desc>
1056 Extra data key for the attempted write.
1057 </desc>
1058 </param>
1059 <param name="value" type="wstring" dir="in">
1060 <desc>
1061 Extra data value for the given key.
1062 </desc>
1063 </param>
1064 <param name="error" type="wstring" dir="out">
1065 <desc>
1066 Optional error message describing the reason of the
1067 veto (ignored if this notification returns @c true).
1068 </desc>
1069 </param>
1070 <param name="allowChange" type="boolean" dir="return">
1071 <desc>
1072 Flag to indicate whether the callee agrees (@c true)
1073 or vetoes against the change (@c false).
1074 </desc>
1075 </param>
1076 </method>
1077
1078 <method name="onExtraDataChange">
1079 <desc>
1080 Notification when machine specific or global extra data
1081 has changed.
1082 </desc>
1083 <param name="machineId" type="uuid" dir="in">
1084 <desc>
1085 ID of the machine this event relates to.
1086 Null for global extra data changes.
1087 </desc>
1088 </param>
1089 <param name="key" type="wstring" dir="in">
1090 <desc>
1091 Extra data key that has changed.
1092 </desc>
1093 </param>
1094 <param name="value" type="wstring" dir="in">
1095 <desc>
1096 Extra data value for the given key.
1097 </desc>
1098 </param>
1099 </method>
1100
1101 <method name="onMediaRegistered">
1102 <desc>
1103 The given media was registered or unregistered
1104 within this VirtualBox installation.
1105
1106 The @a mediaType parameter describes what type of
1107 media the specified @a mediaId refers to. Possible
1108 values are:
1109
1110 <ul>
1111 <li><link to="DeviceType_HardDisk"/>: the media is a hard disk
1112 that, if registered, can be obtained using the
1113 <link to="IVirtualBox::getHardDisk2()"/> call.</li>
1114 <li><link to="DeviceType_DVD"/>: the media is a CD/DVD image
1115 that, if registered, can be obtained using the
1116 <link to="IVirtualBox::getDVDImage()"/> call.</li>
1117 <li><link to="DeviceType_Floppy"/>: the media is a Floppy image
1118 that, if registered, can be obtained using the
1119 <link to="IVirtualBox::getFloppyImage()"/> call.</li>
1120 </ul>
1121
1122 Note that if this is a deregistration notification,
1123 there is no way to access the object representing the
1124 unregistered media. It is supposed that the
1125 application will do required cleanup based on the @a
1126 mediaId value.
1127 </desc>
1128 <param name="mediaId" type="uuid" dir="in">
1129 <desc>ID of the media this event relates to.</desc>
1130 </param>
1131 <param name="mediaType" type="DeviceType" dir="in">
1132 <desc>Type of the media this event relates to.</desc>
1133 </param>
1134 <param name="registered" type="boolean" dir="in">
1135 <desc>
1136 If true, the media was registered, otherwise it was
1137 unregistered.
1138 </desc>
1139 </param>
1140 </method>
1141
1142 <method name="onMachineRegistered">
1143 <desc>
1144 The given machine was registered or unregistered
1145 within this VirtualBox installation.
1146 </desc>
1147 <param name="machineId" type="uuid" dir="in">
1148 <desc>ID of the machine this event relates to.</desc>
1149 </param>
1150 <param name="registered" type="boolean" dir="in">
1151 <desc>
1152 If true, the machine was registered, otherwise it was
1153 unregistered.
1154 </desc>
1155 </param>
1156 </method>
1157
1158 <method name="onSessionStateChange">
1159 <desc>
1160 The state of the session for the given machine was changed.
1161 <see>IMachine::sessionState</see>
1162 </desc>
1163 <param name="machineId" type="uuid" dir="in">
1164 <desc>ID of the machine this event relates to.</desc>
1165 </param>
1166 <param name="state" type="SessionState" dir="in">
1167 <desc>New session state.</desc>
1168 </param>
1169 </method>
1170
1171 <method name="onSnapshotTaken">
1172 <desc>
1173 A new snapshot of the machine has been taken.
1174 <see>ISnapshot</see>
1175 </desc>
1176 <param name="machineId" type="uuid" dir="in">
1177 <desc>ID of the machine this event relates to.</desc>
1178 </param>
1179 <param name="snapshotId" type="uuid" dir="in">
1180 <desc>ID of the new snapshot.</desc>
1181 </param>
1182 </method>
1183
1184 <method name="onSnapshotDiscarded">
1185 <desc>
1186 Snapshot of the given machine has been discarded.
1187
1188 <note>
1189 This notification is delivered <b>after</b> the snapshot
1190 object has been uninitialized on the server (so that any
1191 attempt to call its methods will return an error).
1192 </note>
1193
1194 <see>ISnapshot</see>
1195 </desc>
1196 <param name="machineId" type="uuid" dir="in">
1197 <desc>ID of the machine this event relates to.</desc>
1198 </param>
1199 <param name="snapshotId" type="uuid" dir="in">
1200 <desc>
1201 ID of the discarded snapshot. <tt>null</tt> means the
1202 current machine state has been discarded (restored from
1203 the current snapshot).
1204 </desc>
1205 </param>
1206 </method>
1207
1208 <method name="onSnapshotChange">
1209 <desc>
1210 Snapshot properties (name and/or description) have been changed.
1211 <see>ISnapshot</see>
1212 </desc>
1213 <param name="machineId" type="uuid" dir="in">
1214 <desc>ID of the machine this event relates to.</desc>
1215 </param>
1216 <param name="snapshotId" type="uuid" dir="in">
1217 <desc>ID of the changed snapshot.</desc>
1218 </param>
1219 </method>
1220
1221 <method name="onGuestPropertyChange">
1222 <desc>
1223 Notification when a guest property has changed.
1224 </desc>
1225 <param name="machineId" type="uuid" dir="in">
1226 <desc>
1227 ID of the machine this event relates to.
1228 </desc>
1229 </param>
1230 <param name="name" type="wstring" dir="in">
1231 <desc>
1232 The name of the property that has changed.
1233 </desc>
1234 </param>
1235 <param name="value" type="wstring" dir="in">
1236 <desc>
1237 The new property value.
1238 </desc>
1239 </param>
1240 <param name="flags" type="wstring" dir="in">
1241 <desc>
1242 The new property flags.
1243 </desc>
1244 </param>
1245 </method>
1246
1247 </interface>
1248
1249 <interface
1250 name="IVirtualBox" extends="$dispatched"
1251 uuid="339abca2-f47a-4302-87f5-7bc324e6bbde"
1252 wsmap="managed"
1253 >
1254 <desc>
1255 The IVirtualBox interface represents the main interface exposed by the
1256 product that provides virtual machine management.
1257
1258 An instance of IVirtualBox is required for the product to do anything
1259 useful. Even though the interface does not expose this, internally,
1260 IVirtualBox is implemented as a singleton and actually lives in the
1261 process of the VirtualBox server (VBoxSVC.exe). This makes sure that
1262 IVirtualBox can track the state of all virtual machines on a particular
1263 host, regardless of which frontend started them.
1264
1265 To enumerate all the virtual machines on the host, use the
1266 <link to="IVirtualBox::machines2"/> attribute.
1267 </desc>
1268
1269 <attribute name="version" type="wstring" readonly="yes">
1270 <desc>
1271 A string representing the version number of the product. The
1272 format is 3 integer numbers divided by dots (e.g. 1.0.1). The
1273 last number represents the build number and will frequently change.
1274 </desc>
1275 </attribute>
1276
1277 <attribute name="revision" type="unsigned long" readonly="yes">
1278 <desc>
1279 The internal build revision number of the product.
1280 </desc>
1281 </attribute>
1282
1283 <attribute name="packageType" type="wstring" readonly="yes">
1284 <desc>
1285 A string representing the package type of this product. The
1286 format is OS_ARCH_DIST where OS is either WINDOWS, LINUX,
1287 SOLARIS, DARWIN. ARCH is either 32BITS or 64BITS. DIST
1288 is either GENERIC, UBUNTU_606, UBUNTU_710, or something like
1289 this.
1290 </desc>
1291 </attribute>
1292
1293 <attribute name="homeFolder" type="wstring" readonly="yes">
1294 <desc>
1295 Full path to the directory where the global settings file,
1296 <tt>VirtualBox.xml</tt>, is stored.
1297
1298 In this version of VirtualBox, the value of this property is
1299 always <tt>&lt;user_dir&gt;/.VirtualBox</tt> (where
1300 <tt>&lt;user_dir&gt;</tt> is the path to the user directory,
1301 as determined by the host OS), and cannot be changed.
1302
1303 This path is also used as the base to resolve relative paths in
1304 places where relative paths are allowed (unless otherwise
1305 expressly indicated).
1306 </desc>
1307 </attribute>
1308
1309 <attribute name="settingsFilePath" type="wstring" readonly="yes">
1310 <desc>
1311 Full name of the global settings file.
1312 The value of this property corresponds to the value of
1313 <link to="#homeFolder"/> plus <tt>/VirtualBox.xml</tt>.
1314 </desc>
1315 </attribute>
1316
1317 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
1318 <desc>
1319 Current version of the format of the global VirtualBox settings file
1320 (<tt>VirtualBox.xml</tt>).
1321
1322 The version string has the following format:
1323 <pre>
1324 x.y-platform
1325 </pre>
1326 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
1327 versions, and <tt>platform</tt> is the platform identifier.
1328
1329 The current version usually matches the value of the
1330 <link to="#settingsFormatVersion"/> attribute unless the
1331 settings file was created by an older version of VirtualBox and there
1332 was a change of the settings file format since then.
1333
1334 Note that VirtualBox automatically converts settings files from older
1335 versions to the most recent version when reading them (usually at
1336 VirtualBox startup) but it doesn't save the changes back until
1337 you call a method that implicitly saves settings (such as
1338 <link to="#setExtraData()"/>) or call <link to="#saveSettings()"/>
1339 explicitly. Therefore, if the value of this attribute differs from the
1340 value of <link to="#settingsFormatVersion"/>, then it
1341 means that the settings file was converted but the result of the
1342 conversion is not yet saved to disk.
1343
1344 The above feature may be used by interactive front-ends to inform users
1345 about the settings file format change and offer them to explicitly save
1346 all converted settings files (the global and VM-specific ones),
1347 optionally create backup copies of the old settings files before saving,
1348 etc.
1349
1350 <see>settingsFormatVersion, saveSettingsWithBackup()</see>
1351 </desc>
1352 </attribute>
1353
1354 <attribute name="settingsFormatVersion" type="wstring" readonly="yes">
1355 <desc>
1356 Most recent version of the settings file format.
1357
1358 The version string has the following format:
1359 <pre>
1360 x.y-platform
1361 </pre>
1362 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
1363 versions, and <tt>platform</tt> is the platform identifier.
1364
1365 VirtualBox uses this version of the format when saving settings files
1366 (either as a result of method calls that require to save settings or as
1367 a result of an explicit call to <link to="#saveSettings()"/>).
1368
1369 <see>settingsFileVersion</see>
1370 </desc>
1371 </attribute>
1372
1373 <attribute name="host" type="IHost" readonly="yes">
1374 <desc>Associated host object.</desc>
1375 </attribute>
1376
1377 <attribute name="systemProperties" type="ISystemProperties" readonly="yes">
1378 <desc>Associated system information object.</desc>
1379 </attribute>
1380
1381 <attribute name="machines2" type="IMachine" readonly="yes" safearray="yes">
1382 <desc>
1383 Array of machine objects registered within this VirtualBox instance.
1384 </desc>
1385 </attribute>
1386
1387 <attribute name="hardDisks2" type="IHardDisk2" readonly="yes" safearray="yes">
1388 <desc>
1389 Array of hard disk objects known to this VirtualBox installation.
1390
1391 This array contains only base (root) hard disks. All differencing
1392 hard disks of the given base hard disk can be enumerated using
1393 <link to="IHardDisk2::children"/>.
1394 </desc>
1395 </attribute>
1396
1397 <attribute name="DVDImages" type="IDVDImage2" readonly="yes" safearray="yes">
1398 <desc>
1399 Array of CD/DVD image objects registered with this VirtualBox instance.
1400 </desc>
1401 </attribute>
1402
1403 <attribute name="floppyImages" type="IFloppyImage2" readonly="yes" safearray="yes">
1404 <desc>
1405 Array of floppy image objects registered with this VirtualBox instance.
1406 </desc>
1407 </attribute>
1408
1409 <attribute name="progressOperations" type="IProgressCollection" readonly="yes"/>
1410
1411 <attribute name="guestOSTypes" type="IGuestOSTypeCollection" readonly="yes"/>
1412
1413 <attribute name="sharedFolders" type="ISharedFolderCollection" readonly="yes">
1414 <desc>
1415 Collection of global shared folders. Global shared folders are
1416 available to all virtual machines.
1417
1418 New shared folders are added to the collection using
1419 <link to="#createSharedFolder"/>. Existing shared folders can be
1420 removed using <link to="#removeSharedFolder"/>.
1421
1422 <note>
1423 In the current version of the product, global shared folders are not
1424 implemented and therefore this collection is always empty.
1425 </note>
1426 </desc>
1427 </attribute>
1428
1429 <attribute name="performanceCollector" type="IPerformanceCollector" readonly="yes">
1430 <desc>
1431 Associated performance collector object.
1432 </desc>
1433 </attribute>
1434
1435 <method name="createMachine">
1436 <desc>
1437 Creates a new virtual machine.
1438
1439 The new machine is created unregistered, with the initial configuration
1440 set according to the specified guest OS type. A typical sequence of
1441 actions to create a new virtual machine is as follows:
1442
1443 <ol>
1444 <li>
1445 Call this method to have a new machine created. The returned machine
1446 object will be "mutable" allowing to change any machine property.
1447 </li>
1448
1449 <li>
1450 Configure the machine using the appropriate attributes and methods.
1451 </li>
1452
1453 <li>
1454 Call <link to="IMachine::saveSettings()" /> to write the settings
1455 to the machine's XML settings file. The configuration of the newly
1456 created machine will not be saved to disk until this method is
1457 called.
1458 </li>
1459
1460 <li>
1461 Call <link to="#registerMachine()" /> to add the machine to the list
1462 of machines known to VirtualBox.
1463 </li>
1464 </ol>
1465
1466 You should specify valid name for the newly created machine when calling
1467 this method. See the <link to="IMachine::name"/> attribute description
1468 for more details about the machine name.
1469
1470 The specified guest OS type identifier must match an ID of one of known
1471 guest OS types listed in the <link to="IVirtualBox::guestOSTypes"/>
1472 array.
1473
1474 Every machine has a <i>settings file</i> that is used to store
1475 the machine configuration. This file is stored in a directory called the
1476 <i>machine settings subfolder</i>. Both the settings subfolder and file
1477 will have a name that corresponds to the name of the virtual machine.
1478 You can specify where to create the machine setting subfolder using the
1479 @a baseFolder argument. The base folder can be absolute (full path) or
1480 relative to the <link to="IVirtualBox::homeFolder">VirtualBox home
1481 directory</link>.
1482
1483 If @a baseFolder is a null or empty string (which is recommended), the
1484 <link to="ISystemProperties::defaultMachineFolder">default machine
1485 settings folder</link> will be used as a base folder for the created
1486 machine. Otherwise the given base folder will be used. In either case,
1487 the full path to the resulting settings file has the following
1488 structure:
1489 <pre>
1490 &lt;base_folder&gt;/&lt;machine_name&gt;/&lt;machine_name&gt;.xml
1491 </pre>
1492
1493 Note that if the resulting settings file already exists, this method
1494 will fail with <link to="VBOX_E_FILE_ERROR"/>.
1495
1496 Optionally, you may specify an UUID of to assign to the created machine.
1497 However, this is not recommended and you should normally pass an empty
1498 (null) UUID to this method so that a new UUID will be automatically
1499 generated for every created machine.
1500
1501 <note>
1502 There is no way to change the name of the settings file or
1503 subfolder of the created machine directly.
1504 </note>
1505
1506 <result name="VBOX_E_OBJECT_NOT_FOUND">
1507 @a osTypeId is invalid.
1508 </result>
1509 <result name="VBOX_E_FILE_ERROR">
1510 Resulting settings file name is invalid or the settings file already
1511 exists or could not be created due to an I/O error.
1512 </result>
1513 <result name="E_INVALIDARG">
1514 @a name is empty or null.
1515 </result>
1516 </desc>
1517
1518 <param name="name" type="wstring" dir="in">
1519 <desc>Machine name.</desc>
1520 </param>
1521 <param name="osTypeId" type="wstring" dir="in">
1522 <desc>Guest OS Type ID.</desc>
1523 </param>
1524 <param name="baseFolder" type="wstring" dir="in">
1525 <desc>Base machine folder (optional).</desc>
1526 </param>
1527 <param name="id" type="uuid" dir="in">
1528 <desc>Machine UUID (optional).</desc>
1529 </param>
1530 <param name="machine" type="IMachine" dir="return">
1531 <desc>Created machine object.</desc>
1532 </param>
1533 </method>
1534
1535 <method name="createLegacyMachine">
1536 <desc>
1537 Creates a new virtual machine in "legacy" mode, using the specified
1538 settings file to store machine settings.
1539
1540 As opposed to machines created by <link to="#createMachine()"/>,
1541 the settings file of the machine created in "legacy" mode is not
1542 automatically renamed when the machine name is changed -- it will always
1543 remain the same as specified in this method call.
1544
1545 The specified settings file name can be absolute (full path) or relative
1546 to the <link to="IVirtualBox::homeFolder">VirtualBox home
1547 directory</link>. If the file name doesn't contain an extension, the
1548 default extension (.xml) will be appended.
1549
1550 Note that the configuration of the newly created machine is not
1551 saved to disk (and therefore no settings file is created)
1552 until <link to="IMachine::saveSettings()"/> is called. If the
1553 specified settings file already exists, this method
1554 will fail with <link to="VBOX_E_FILE_ERROR"/>..
1555
1556 See <link to="#createMachine()"/> for more information.
1557
1558 @deprecated This method may be removed later. Use <link
1559 to="IVirtualBox::createMachine()"/> instead.
1560
1561 <note>
1562 There is no way to change the name of the settings file
1563 of the machine created in "legacy" mode.
1564 </note>
1565
1566 <result name="VBOX_E_OBJECT_NOT_FOUND">
1567 @a osTypeId is invalid.
1568 </result>
1569 <result name="VBOX_E_FILE_ERROR">
1570 @a settingsFile is invalid or the settings file already exists or
1571 could not be created due to an I/O error.
1572 </result>
1573 <result name="E_INVALIDARG">
1574 @a name or @a settingsFile is empty or null.
1575 </result>
1576 </desc>
1577
1578 <param name="name" type="wstring" dir="in">
1579 <desc>Machine name.</desc>
1580 </param>
1581 <param name="osTypeId" type="wstring" dir="in">
1582 <desc>Machine OS Type ID.</desc>
1583 </param>
1584 <param name="settingsFile" type="wstring" dir="in">
1585 <desc>Name of the machine settings file.</desc>
1586 </param>
1587 <param name="id" type="uuid" dir="in">
1588 <desc>Machine UUID (optional).</desc>
1589 </param>
1590 <param name="machine" type="IMachine" dir="return">
1591 <desc>Created machine object.</desc>
1592 </param>
1593 </method>
1594
1595 <method name="openMachine">
1596 <desc>
1597 Opens a virtual machine from the existing settings file.
1598 The opened machine remains unregistered until you call
1599 <link to="#registerMachine()"/>.
1600
1601 The specified settings file name can be absolute
1602 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1603 VirtualBox home directory</link>. This file must exist
1604 and must be a valid machine settings file whose contents
1605 will be used to construct the machine object.
1606
1607 @deprecated Will be removed soon.
1608 <result name="VBOX_E_FILE_ERROR">
1609 Settings file name invalid, not found or sharing violation.
1610 </result>
1611 </desc>
1612 <param name="settingsFile" type="wstring" dir="in">
1613 <desc>
1614 Name of the machine settings file.
1615 </desc>
1616 </param>
1617 <param name="machine" type="IMachine" dir="return">
1618 <desc>Opened machine object.</desc>
1619 </param>
1620 <note>
1621 <link to="IMachine::settingsModified"/> will return
1622 false for the created machine, until any of machine settings
1623 are changed.
1624 </note>
1625 </method>
1626
1627 <method name="registerMachine">
1628 <desc>
1629
1630 Registers the machine previously created using
1631 <link to="#createMachine()"/> or opened using
1632 <link to="#openMachine()"/> within this VirtualBox installation. After
1633 successful method invocation, the
1634 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1635 to all registered callbacks.
1636
1637 <note>
1638 This method implicitly calls <link to="IMachine::saveSettings"/>
1639 to save all current machine settings before registering it.
1640 </note>
1641
1642 <result name="VBOX_E_OBJECT_NOT_FOUND">
1643 No matching virtual machine found.
1644 </result>
1645 <result name="VBOX_E_INVALID_OBJECT_STATE">
1646 Virtual machine was not created within this VirtualBox instance.
1647 </result>
1648
1649 </desc>
1650 <param name="machine" type="IMachine" dir="in"/>
1651 </method>
1652
1653 <method name="getMachine">
1654 <desc>
1655 Attempts to find a virtual machine given its UUID.
1656 To look up a machine by name, use <link to="IVirtualBox::findMachine" />
1657 instead.
1658
1659 <result name="VBOX_E_OBJECT_NOT_FOUND">
1660 Could not find registered machine matching @a id.
1661 </result>
1662
1663 </desc>
1664 <param name="id" type="uuid" dir="in"/>
1665 <param name="machine" type="IMachine" dir="return"/>
1666 </method>
1667
1668 <method name="findMachine">
1669 <desc>
1670 Attempts to find a virtual machine given its name.
1671 To look up a machine by UUID, use <link to="IVirtualBox::getMachine" />
1672 instead.
1673
1674 <result name="VBOX_E_OBJECT_NOT_FOUND">
1675 Could not find registered machine matching @a name.
1676 </result>
1677
1678 </desc>
1679 <param name="name" type="wstring" dir="in"/>
1680 <param name="machine" type="IMachine" dir="return"/>
1681 </method>
1682
1683 <method name="unregisterMachine">
1684 <desc>
1685
1686 Unregisters the machine previously registered using
1687 <link to="#registerMachine"/>. After successful method invocation, the
1688 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1689 to all registered callbacks.
1690
1691 <note>
1692 The specified machine must not be in the Saved state, have an open
1693 (or a spawning) direct session associated with it, have snapshots or
1694 have hard disks attached.
1695 </note>
1696
1697 <note>
1698 This method implicitly calls <link to="IMachine::saveSettings"/> to
1699 save all current machine settings before unregistering it.
1700 </note>
1701
1702 <note>
1703 If the given machine is inaccessible (see
1704 <link to="IMachine::accessible"/>), it will be unregistered and
1705 fully uninitialized right afterwards. As a result, the returned
1706 machine object will be unusable and an attempt to call
1707 <b>any</b> method will return the "Object not ready" error.
1708 </note>
1709
1710 <result name="VBOX_E_OBJECT_NOT_FOUND">
1711 Could not find registered machine matching @a id.
1712 </result>
1713 <result name="VBOX_E_INVALID_VM_STATE">
1714 Machine is in Saved state.
1715 </result>
1716 <result name="VBOX_E_INVALID_OBJECT_STATE">
1717 Machine has snapshot or open session or hard disk attached.
1718 </result>
1719
1720 </desc>
1721 <param name="id" type="uuid" dir="in">
1722 <desc>UUID of the machine to unregister.</desc>
1723 </param>
1724 <param name="machine" type="IMachine" dir="return">
1725 <desc>Unregistered machine object.</desc>
1726 </param>
1727 </method>
1728
1729 <method name="openAppliance">
1730 <desc>
1731 Attempts to open the given appliance, which must be in Open Virtual Machine Format (OVF).
1732
1733 As prescribed by the OVF standard, VirtualBox supports OVF in two formats:
1734
1735 <ol>
1736 <li>If the OVF is distributed as a set of files, then @a file must be a fully qualified
1737 path name to an existing OVF descriptor file with an <tt>.ovf</tt> file extension. If
1738 this descriptor file references other files, as OVF appliances distributed as a set of
1739 files most likely do, those files must be in the same directory as the descriptor file.</li>
1740
1741 <li>If the OVF is distributed as a single file, it must be in TAR format and have the
1742 <tt>.ova</tt> file extension. This TAR file must then contain at least the OVF descriptor
1743 files and optionally other files.</li>
1744 </ol>
1745
1746 In both cases, VirtualBox will open the OVF descriptor file, parse its contents and create a
1747 new instance of IAppliance representing the OVF file.
1748
1749 This method succeeds if the OVF is syntactically valid and, by itself, without errors. The
1750 returned IAppliance object can then be used to retrieve information about the appliance and
1751 import it into VirtualBox. The mere fact that this method returns successfully does not mean
1752 that VirtualBox supports all features requested by the appliance; see the documentation for
1753 <link to="IAppliance" /> for details.
1754
1755 </desc>
1756 <param name="file" type="wstring" dir="in">
1757 <desc>
1758 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
1759 on whether the appliance is distributed as a set of files or as a single file, respectively).
1760 </desc>
1761 </param>
1762 <param name="machine" type="IAppliance" dir="return">
1763 <desc>New appliance.</desc>
1764 </param>
1765 </method>
1766
1767 <method name="createHardDisk2">
1768 <desc>
1769 Creates a new base hard disk object that will use the given storage
1770 format and location for hard disk data.
1771
1772 Note that the actual storage unit is not created by this method. In
1773 order to do it, and before you are able to attach the created hard disk
1774 to virtual machines, you must call one of the following methods to
1775 allocate a format-specific storage unit at the specified location:
1776 <ul>
1777 <li><link to="IHardDisk2::createDynamicStorage()"/></li>
1778 <li><link to="IHardDisk2::createFixedStorage()"/></li>
1779 <li><link to="IHardDisk2::createDiffStorage()"/></li>
1780 </ul>
1781
1782 Some hard disk attributes, such as <link to="IHardDisk2::id"/>, may
1783 remain uninitialized until the hard disk storage unit is successfully
1784 created by one of the above methods.
1785
1786 After the storage unit is successfully created, the hard disk gets
1787 remembered by this VirtualBox installation and will be accessible
1788 through <link to="#getHardDisk2()"/> and <link to="#findHardDisk2()"/>
1789 methods. Remembered root (base) hard disks are also returned as part of
1790 the <link to="#hardDisks2"/> array. See IHardDisk2 for more details.
1791
1792 The list of all storage formats supported by this VirtualBox
1793 installation can be obtained using
1794 <link to="ISystemProperties::hardDiskFormats"/>. If the @a format
1795 attribute is empty or <tt>null</tt> then the default storage format
1796 specified by <link to="ISystemProperties::defaultHardDiskFormat"/> will
1797 be used for creating a storage unit of the hard disk.
1798
1799 Note that the format of the location string is storage format specific.
1800 See <link to="IMedium::location"/>, IHardDisk2 and
1801 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1802
1803 <result name="VBOX_E_OBJECT_NOT_FOUND">
1804 @a format identifier is invalid. See
1805 <link to="ISystemProperties::hardDiskFormats"/>.
1806 </result>
1807 <result name="VBOX_E_FILE_ERROR">
1808 @a location is a not valid file name (for file-based formats only).
1809 </result>
1810 <result name="E_INVALIDARG">
1811 @a format is a null or empty string.
1812 </result>
1813 </desc>
1814 <param name="format" type="wstring" dir="in">
1815 <desc>
1816 Identifier of the storage format to use for the new hard disk.
1817 </desc>
1818 </param>
1819 <param name="location" type="wstring" dir="in">
1820 <desc>
1821 Location of the storage unit for the new hard disk.
1822 </desc>
1823 </param>
1824 <param name="hardDisk" type="IHardDisk2" dir="return">
1825 <desc>Created hard disk object.</desc>
1826 </param>
1827 </method>
1828
1829 <method name="openHardDisk2">
1830 <desc>
1831 Opens a hard disk from an existing location.
1832
1833 After the hard disk is successfully opened by this method, it gets
1834 remembered by (known to) this VirtualBox installation and will be
1835 accessible through <link to="#getHardDisk2()"/> and
1836 <link to="#findHardDisk2()"/> methods. Remembered root (base) hard disks
1837 are also returned as part of the <link to="#hardDisks2"/> array and can
1838 be attached to virtual machines. See IHardDisk2 for more details.
1839
1840 If a differencing hard disk is to be opened by this method, the
1841 operation will succeed only if its parent hard disk and all ancestors,
1842 if any, are already known to this VirtualBox installation (for example,
1843 were opened by this method before).
1844
1845 This method tries to guess the storage format of the specified hard disk
1846 by reading hard disk data at the specified location.
1847
1848 Note that the format of the location string is storage format specific.
1849 See <link to="IMedium::location"/>, IHardDisk2 and
1850 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1851
1852
1853 <result name="VBOX_E_FILE_ERROR">
1854 Invalid hard disk storage file location.
1855 </result>
1856 <result name="VBOX_E_IPRT_ERROR">
1857 Could not get hard disk storage format.
1858 </result>
1859 <result name="E_INVALIDARG">
1860 Invalid hard disk storage format.
1861 </result>
1862
1863 </desc>
1864 <param name="location" type="wstring" dir="in">
1865 <desc>
1866 Location of the storage unit that contains hard disk data in one of
1867 the supported storage formats.
1868 </desc>
1869 </param>
1870 <param name="hardDisk" type="IHardDisk2" dir="return">
1871 <desc>Opened hard disk object.</desc>
1872 </param>
1873 </method>
1874
1875 <method name="getHardDisk2" const="yes">
1876 <desc>
1877 Returns a hard disk with the given UUID.
1878
1879 The hard disk with the given UUID must be known to this VirtualBox
1880 installation, i.e. it must be previously created by
1881 <link to="#createHardDisk2()"/> or opened by <link
1882 to="#openHardDisk2()"/>, or attached to some known virtual machine.
1883
1884 <result name="VBOX_E_OBJECT_NOT_FOUND">
1885 No hard disk object matching @a id found.
1886 </result>
1887
1888 </desc>
1889 <param name="id" type="uuid" dir="in">
1890 <desc>UUID of the hard disk to look for.</desc>
1891 </param>
1892 <param name="hardDisk" type="IHardDisk2" dir="return">
1893 <desc>Found hard disk object.</desc>
1894 </param>
1895 </method>
1896
1897 <method name="findHardDisk2">
1898 <desc>
1899 Returns a hard disk that uses the given location to store hard
1900 disk data.
1901
1902 The given hard disk must be known to this VirtualBox installation, i.e.
1903 it must be previously created by
1904 <link to="#createHardDisk2()"/> or opened by <link
1905 to="#openHardDisk2()"/>, or attached to some known virtual machine.
1906
1907 The search is done by comparing the value of the @a location argument to
1908 the <link to="IHardDisk2::location"/> attribute of each known hard
1909 disk.
1910
1911 For locations represented by file names in the host's file system, the
1912 requested location can be a path relative to the
1913 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
1914 only a file name without any path is given, the
1915 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
1916 folder</link> will be prepended to the file name before searching. Note
1917 that on case sensitive file systems, a case sensitive comparison is
1918 performed, otherwise the case of symbols in the file path is ignored.
1919
1920 <result name="VBOX_E_OBJECT_NOT_FOUND">
1921 No hard disk object matching @a location found.
1922 </result>
1923
1924 </desc>
1925 <param name="location" type="wstring" dir="in">
1926 <desc>Location string to search for.</desc>
1927 </param>
1928 <param name="hardDisk" type="IHardDisk2" dir="return">
1929 <desc>Found hard disk object.</desc>
1930 </param>
1931 </method>
1932
1933 <method name="openDVDImage">
1934 <desc>
1935 Opens a CD/DVD image contained in the specified file of the supported
1936 format and assigns it the given UUID.
1937
1938 After the image is successfully opened by this method, it gets
1939 remembered by (known to) this VirtualBox installation and will be
1940 accessible through <link to="#getDVDImage()"/> and
1941 <link to="#findDVDImage()"/> methods. Remembered images are also
1942 returned as part of the <link to="#DVDImages"/> array and can be mounted
1943 to virtual machines. See IMedium for more details.
1944
1945 See <link to="IMedium::location"/> to get more details about the format
1946 of the location string.
1947
1948 <note>
1949 Currently only ISO 9960 CD/DVD images are supported by VirtualBox.
1950 </note>
1951
1952 <result name="VBOX_E_INVALID_OBJECT_STATE">
1953 CD/DVD image already exists in the media registry.
1954 </result>
1955
1956 </desc>
1957 <param name="location" type="wstring" dir="in">
1958 <desc>
1959 Full path to the file that contains a valid CD/DVD image.
1960 </desc>
1961 </param>
1962 <param name="id" type="uuid" dir="in">
1963 <desc>
1964 UUID to assign to the given image within this VirtualBox installation.
1965 If an empty (null) UUID is specified, the system will randomly
1966 generate a new UUID.
1967 </desc>
1968 </param>
1969 <param name="image" type="IDVDImage2" dir="return">
1970 <desc>Opened CD/DVD image object.</desc>
1971 </param>
1972 </method>
1973
1974 <method name="getDVDImage">
1975 <desc>
1976 Returns a CD/DVD image with the given UUID.
1977
1978 The image with the given UUID must be known to this VirtualBox
1979 installation, i.e. it must be previously opened by <link
1980 to="#openDVDImage()"/>, or mounted to some known virtual machine.
1981
1982 <result name="VBOX_E_OBJECT_NOT_FOUND">
1983 No matching DVD image found in the media registry.
1984 </result>
1985
1986 </desc>
1987 <param name="id" type="uuid" dir="in">
1988 <desc>UUID of the image to look for.</desc>
1989 </param>
1990 <param name="image" type="IDVDImage2" dir="return">
1991 <desc>Found CD/DVD image object.</desc>
1992 </param>
1993 </method>
1994
1995 <method name="findDVDImage">
1996 <desc>
1997 Returns a CD/DVD image with the given image location.
1998
1999 The image with the given UUID must be known to this VirtualBox
2000 installation, i.e. it must be previously opened by <link
2001 to="#openDVDImage()"/>, or mounted to some known virtual machine.
2002
2003 The search is done by comparing the value of the @a location argument to
2004 the <link to="IMedium::location"/> attribute of each known CD/DVD image.
2005
2006 The requested location can be a path relative to the
2007 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
2008 only a file name without any path is given, the
2009 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
2010 folder</link> will be prepended to the file name before searching. Note
2011 that on case sensitive file systems, a case sensitive comparison is
2012 performed, otherwise the case in the file path is ignored.
2013
2014 <result name="VBOX_E_FILE_ERROR">
2015 Invalid image file location.
2016 </result>
2017 <result name="VBOX_E_OBJECT_NOT_FOUND">
2018 No matching DVD image found in the media registry.
2019 </result>
2020
2021 </desc>
2022 <param name="location" type="wstring" dir="in">
2023 <desc>CD/DVD image file path to look for.</desc>
2024 </param>
2025 <param name="image" type="IDVDImage2" dir="return">
2026 <desc>Found CD/DVD image object.</desc>
2027 </param>
2028 </method>
2029
2030 <method name="openFloppyImage">
2031 <desc>
2032 Opens a floppy image contained in the specified file of the supported
2033 format and assigns it the given UUID.
2034
2035 After the image is successfully opened by this method, it gets
2036 remembered by (known to) this VirtualBox installation and will be
2037 accessible through <link to="#getFloppyImage()"/> and
2038 <link to="#findFloppyImage()"/> methods. Remembered images are also
2039 returned as part of the <link to="#floppyImages"/> array and can be
2040 mounted to virtual machines. See IMedium for more details.
2041
2042 See <link to="IMedium::location"/> to get more details about the format
2043 of the location string.
2044
2045 <result name="VBOX_E_FILE_ERROR">
2046 Floppy image specified by @a location not accessible.
2047 </result>
2048 <result name="VBOX_E_INVALID_OBJECT_STATE">
2049 Floppy image already exists in the media registry.
2050 </result>
2051
2052 <note>
2053 Currently, only raw floppy images are supported by VirtualBox.
2054 </note>
2055 </desc>
2056 <param name="location" type="wstring" dir="in">
2057 <desc>
2058 Full path to the file that contains a valid floppy image.
2059 </desc>
2060 </param>
2061 <param name="id" type="uuid" dir="in">
2062 <desc>
2063 UUID to assign to the given image file within this VirtualBox
2064 installation. If an empty (null) UUID is specified, the system will
2065 randomly generate a new UUID.
2066 </desc>
2067 </param>
2068 <param name="image" type="IFloppyImage2" dir="return">
2069 <desc>Opened floppy image object.</desc>
2070 </param>
2071 </method>
2072
2073 <method name="getFloppyImage">
2074 <desc>
2075 Returns a floppy image with the given UUID.
2076
2077 The image with the given UUID must be known to this VirtualBox
2078 installation, i.e. it must be previously opened by <link
2079 to="#openFloppyImage()"/>, or mounted to some known virtual machine.
2080
2081 <result name="VBOX_E_OBJECT_NOT_FOUND">
2082 No matching floppy image found in the media registry.
2083 </result>
2084
2085 </desc>
2086 <param name="id" type="uuid" dir="in">
2087 <desc>UUID of the image to look for.</desc>
2088 </param>
2089 <param name="image" type="IFloppyImage2" dir="return">
2090 <desc>Found floppy image object.</desc>
2091 </param>
2092 </method>
2093
2094 <method name="findFloppyImage">
2095 <desc>
2096 Returns a floppy image with the given image location.
2097
2098 The image with the given UUID must be known to this VirtualBox
2099 installation, i.e. it must be previously opened by <link
2100 to="#openFloppyImage()"/>, or mounted to some known virtual machine.
2101
2102 The search is done by comparing the value of the @a location argument to
2103 the <link to="IMedium::location"/> attribute of each known floppy image.
2104
2105 The requested location can be a path relative to the
2106 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
2107 only a file name without any path is given, the
2108 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
2109 folder</link> will be prepended to the file name before searching. Note
2110 that on case sensitive file systems, a case sensitive comparison is
2111 performed, otherwise the case of symbols in the file path is ignored.
2112
2113 <result name="VBOX_E_FILE_ERROR">
2114 Invalid image file location.
2115 </result>
2116 <result name="VBOX_E_OBJECT_NOT_FOUND">
2117 No matching floppy image found in the media registry.
2118 </result>
2119
2120 </desc>
2121 <param name="location" type="wstring" dir="in">
2122 <desc>Floppy image file path to look for.</desc>
2123 </param>
2124 <param name="image" type="IFloppyImage2" dir="return">
2125 <desc>Found floppy image object.</desc>
2126 </param>
2127 </method>
2128
2129 <method name="getGuestOSType">
2130 <desc>
2131 Returns an object describing the specified guest OS type.
2132
2133 The requested guest OS type is specified using a string which is a
2134 mnemonic identifier of the guest operating system, such as
2135 <tt>"win31"</tt> or <tt>"ubuntu"</tt>. The guest OS type ID of a
2136 particular virtual machine can be read or set using the
2137 <link to="IMachine::OSTypeId"/> attribute.
2138
2139 The <link to="IVirtualBox::guestOSTypes"/> collection contains all
2140 available guest OS type objects. Each object has an
2141 <link to="IGuestOSType::id"/> attribute which contains an identifier of
2142 the guest OS this object describes.
2143
2144 <result name="E_INVALIDARG">
2145 @a id is not a valid Guest OS type.
2146 </result>
2147
2148 </desc>
2149 <param name="id" type="wstring" dir="in">
2150 <desc>Guest OS type ID string.</desc>
2151 </param>
2152 <param name="type" type="IGuestOSType" dir="return">
2153 <desc>Guest OS type object.</desc>
2154 </param>
2155 </method>
2156
2157 <method name="createSharedFolder">
2158 <desc>
2159 Creates a new global shared folder by associating the given logical
2160 name with the given host path, adds it to the collection of shared
2161 folders and starts sharing it. Refer to the description of
2162 <link to="ISharedFolder"/> to read more about logical names.
2163 <note>
2164 In the current implementation, this operation is not
2165 implemented.
2166 </note>
2167 </desc>
2168 <param name="name" type="wstring" dir="in">
2169 <desc>Unique logical name of the shared folder.</desc>
2170 </param>
2171 <param name="hostPath" type="wstring" dir="in">
2172 <desc>Full path to the shared folder in the host file system.</desc>
2173 </param>
2174 <param name="writable" type="boolean" dir="in">
2175 <desc>Whether the share is writable or readonly</desc>
2176 </param>
2177 </method>
2178
2179 <method name="removeSharedFolder">
2180 <desc>
2181 Removes the global shared folder with the given name previously
2182 created by <link to="#createSharedFolder"/> from the collection of
2183 shared folders and stops sharing it.
2184 <note>
2185 In the current implementation, this operation is not
2186 implemented.
2187 </note>
2188 </desc>
2189 <param name="name" type="wstring" dir="in">
2190 <desc>Logical name of the shared folder to remove.</desc>
2191 </param>
2192 </method>
2193
2194 <method name="getNextExtraDataKey">
2195 <desc>
2196 Returns the global extra data key name following the supplied key.
2197
2198 An error is returned if the supplied @a key does not exist. @c NULL is
2199 returned in @a nextKey if the supplied key is the last key. When
2200 supplying @c NULL for the @a key, the first key item is returned in @a
2201 nextKey (if there is any). @a nextValue is an optional parameter and
2202 if supplied, the next key's value is returned in it.
2203
2204 <result name="VBOX_E_OBJECT_NOT_FOUND">
2205 Extra data @a key not found.
2206 </result>
2207
2208 </desc>
2209 <param name="key" type="wstring" dir="in">
2210 <desc>Name of the data key to follow.</desc>
2211 </param>
2212 <param name="nextKey" type="wstring" dir="out">
2213 <desc>Name of the next data key.</desc>
2214 </param>
2215 <param name="nextValue" type="wstring" dir="out">
2216 <desc>Value of the next data key.</desc>
2217 </param>
2218 </method>
2219
2220 <method name="getExtraData">
2221 <desc>
2222 Returns associated global extra data.
2223
2224 If the requested data @a key does not exist, this function will
2225 succeed and return @c NULL in the @a value argument.
2226
2227 <result name="VBOX_E_FILE_ERROR">
2228 Settings file not accessible.
2229 </result>
2230 <result name="VBOX_E_XML_ERROR">
2231 Could not parse the settings file.
2232 </result>
2233
2234 </desc>
2235 <param name="key" type="wstring" dir="in">
2236 <desc>Name of the data key to get.</desc>
2237 </param>
2238 <param name="value" type="wstring" dir="return">
2239 <desc>Value of the requested data key.</desc>
2240 </param>
2241 </method>
2242
2243 <method name="setExtraData">
2244 <desc>
2245 Sets associated global extra data.
2246
2247 If you pass @c NULL as a key @a value, the given @a key will be
2248 deleted.
2249
2250 <note>
2251 Before performing the actual data change, this method will ask all
2252 registered callbacks using the
2253 <link to="IVirtualBoxCallback::onExtraDataCanChange()"/>
2254 notification for a permission. If one of the callbacks refuses the
2255 new value, the change will not be performed.
2256 </note>
2257 <note>
2258 On success, the
2259 <link to="IVirtualBoxCallback::onExtraDataChange()"/> notification
2260 is called to inform all registered callbacks about a successful data
2261 change.
2262 </note>
2263
2264 <result name="VBOX_E_FILE_ERROR">
2265 Settings file not accessible.
2266 </result>
2267 <result name="VBOX_E_XML_ERROR">
2268 Could not parse the settings file.
2269 </result>
2270 <result name="E_ACCESSDENIED">
2271 Modification request refused.
2272 </result>
2273
2274 </desc>
2275 <param name="key" type="wstring" dir="in">
2276 <desc>Name of the data key to set.</desc>
2277 </param>
2278 <param name="value" type="wstring" dir="in">
2279 <desc>Value to assign to the key.</desc>
2280 </param>
2281 </method>
2282
2283 <method name="openSession">
2284 <desc>
2285 Opens a new direct session with the given virtual machine.
2286
2287 A direct session acts as a local lock on the given VM.
2288 There can be only one direct session open at a time for every
2289 virtual machine, protecting the VM from being manipulated by
2290 conflicting actions from different processes. Only after a
2291 direct session has been opened, one can change all VM settings
2292 and execute the VM in the process space of the session object.
2293
2294 Sessions therefore can be compared to mutex semaphores that
2295 lock a given VM for modification and execution.
2296 See <link to="ISession">ISession</link> for details.
2297
2298 <note>Unless you are writing a new VM frontend, you will not
2299 want to execute a VM in the current process. To spawn a new
2300 process that executes a VM, use
2301 <link to="IVirtualBox::openRemoteSession" />
2302 instead.</note>
2303
2304 Upon successful return, the session object can be used to
2305 get access to the machine and to the VM console.
2306
2307 In VirtualBox terminology, the machine becomes "mutable" after
2308 a session has been opened. Note that the "mutable" machine
2309 object, on which you may invoke IMachine methods to change its
2310 settings, will be a different object from the immutable IMachine
2311 objects returned by various IVirtualBox methods. To obtain a
2312 mutable IMachine object (upon which you can invoke settings methods),
2313 use the <link to="ISession::machine" /> attribute.
2314
2315 One must always call <link to="ISession::close" /> to release the
2316 lock on the machine, or the machine's state will eventually be
2317 set to "Aborted".
2318
2319 In other words, to change settings on a machine, the following
2320 sequence is typically performed:
2321
2322 <ol>
2323 <li>Call this method (openSession) to have a machine locked for
2324 the current session.</li>
2325
2326 <li>Obtain a mutable IMachine object from <link to="ISession::machine" />.</li>
2327
2328 <li>Change the settings of the machine.</li>
2329
2330 <li>Call <link to="IMachine::saveSettings" />.</li>
2331
2332 <li>Close the session by calling <link to="ISession::close()"/>.</li>
2333 </ol>
2334
2335 <result name="E_UNEXPECTED">
2336 Virtual machine not registered.
2337 </result>
2338 <result name="E_ACCESSDENIED">
2339 Process not started by OpenRemoteSession.
2340 </result>
2341 <result name="VBOX_E_OBJECT_NOT_FOUND">
2342 No matching virtual machine found.
2343 </result>
2344 <result name="VBOX_E_INVALID_OBJECT_STATE">
2345 Session already open or being opened.
2346 </result>
2347 <result name="VBOX_E_VM_ERROR">
2348 Failed to assign machine to session.
2349 </result>
2350
2351 </desc>
2352 <param name="session" type="ISession" dir="in">
2353 <desc>
2354 Session object that will represent the opened session after
2355 successful method invocation. This object must not represent
2356 the already open session.
2357 <note>
2358 This session will be automatically closed if the
2359 VirtualBox server is terminated for some reason.
2360 </note>
2361 </desc>
2362 </param>
2363 <param name="machineId" type="uuid" dir="in">
2364 <desc>ID of the virtual machine to open a session with.</desc>
2365 </param>
2366 </method>
2367
2368 <method name="openRemoteSession">
2369 <desc>
2370 Spawns a new process that executes a virtual machine (called a
2371 "remote session").
2372
2373 Opening a remote session causes the VirtualBox server to start a new
2374 process that opens a direct session with the given VM. As a result, the
2375 VM is locked by that direct session in the new process, preventing
2376 conflicting changes from other processes. Since sessions act as locks
2377 that prevent conflicting changes, one cannot open a remote session
2378 for a VM that already has another open session (direct or remote), or
2379 is currently in the process of opening one (see <link
2380 to="IMachine::sessionState"/>).
2381
2382 While the remote session still provides some level of control over the
2383 VM execution to the caller (using the <link to="IConsole" /> interface),
2384 not all VM settings are available for modification within the remote
2385 session context.
2386
2387 This operation can take some time (a new VM is started in a new process,
2388 for which memory and other resources need to be set up). Because of this,
2389 an <link to="IProgress" /> is returned to allow the caller to wait for this
2390 asynchronous operation to be completed. Until then, the remote session
2391 object remains in the closed state, and accessing the machine or its
2392 console through it is invalid. It is recommended to use
2393 <link to="IProgress::waitForCompletion" /> or similar calls to wait for
2394 completion.
2395
2396 As with all <link to="ISession" /> objects, it is recommended to call
2397 <link to="ISession::close" /> on the local session object once openRemoteSession()
2398 has been called. However, the session's state (see <link to="ISession::state" />)
2399 will not return to "Closed" until the remote session has also closed (i.e.
2400 until the VM is no longer running). In that case, however, the state of
2401 the session will automatically change back to "Closed".
2402
2403 Currently supported session types (values of the @a type
2404 argument) are:
2405 <ul>
2406 <li><tt>gui</tt>: VirtualBox Qt GUI session</li>
2407 <li><tt>vrdp</tt>: VirtualBox VRDP Server session</li>
2408 </ul>
2409
2410 The @a environment argument is a string containing definitions of
2411 environment variables in the following format:
2412 @code
2413 NAME[=VALUE]\n
2414 NAME[=VALUE]\n
2415 ...
2416 @endcode
2417 where <tt>\\n</tt> is the new line character. These environment
2418 variables will be appended to the environment of the VirtualBox server
2419 process. If an environment variable exists both in the server process
2420 and in this list, the value from this list takes precedence over the
2421 server's variable. If the value of the environment variable is
2422 omitted, this variable will be removed from the resulting environment.
2423 If the environment string is @c null, the server environment is
2424 inherited by the started process as is.
2425
2426 <see>openExistingSession</see>
2427
2428 <result name="E_UNEXPECTED">
2429 Virtual machine not registered.
2430 </result>
2431 <result name="E_INVALIDARG">
2432 Invalid session type @a type.
2433 </result>
2434 <result name="VBOX_E_OBJECT_NOT_FOUND">
2435 No machine matching @a machineId found.
2436 </result>
2437 <result name="VBOX_E_INVALID_OBJECT_STATE">
2438 Session already open or being opened.
2439 </result>
2440 <result name="VBOX_E_IPRT_ERROR">
2441 Launching process for machine failed.
2442 </result>
2443 <result name="VBOX_E_VM_ERROR">
2444 Failed to assign machine to session.
2445 </result>
2446
2447 </desc>
2448 <param name="session" type="ISession" dir="in">
2449 <desc>
2450 Session object that will represent the opened remote session
2451 after successful method invocation (this object must not
2452 represent an already open session).
2453 </desc>
2454 </param>
2455 <param name="machineId" type="uuid" dir="in">
2456 <desc>ID of the virtual machine to open a session with.</desc>
2457 </param>
2458 <param name="type" type="wstring" dir="in">
2459 <desc>
2460 Type of the remote session (case sensitive).
2461 </desc>
2462 </param>
2463 <param name="environment" type="wstring" dir="in">
2464 <desc>
2465 Environment to pass to the opened session (may be @c null).
2466 </desc>
2467 </param>
2468 <param name="progress" type="IProgress" dir="return">
2469 <desc>Progress object to track the operation completion.</desc>
2470 </param>
2471 </method>
2472
2473 <method name="openExistingSession">
2474 <desc>
2475 Opens a new remote session with the virtual machine for
2476 which a direct session is already open.
2477
2478 The remote session provides some level of control over the VM
2479 execution (using the IConsole interface) to the caller; however,
2480 within the remote session context, not all VM settings are available
2481 for modification.
2482
2483 As opposed to <link to="#openRemoteSession()"/>, the number of
2484 remote sessions opened this way is not limited by the API
2485
2486 <note>
2487 It is an error to open a remote session with the machine that
2488 doesn't have an open direct session.
2489 </note>
2490
2491 <result name="E_UNEXPECTED">
2492 Virtual machine not registered.
2493 </result>
2494 <result name="VBOX_E_OBJECT_NOT_FOUND">
2495 No machine matching @a machineId found.
2496 </result>
2497 <result name="VBOX_E_INVALID_OBJECT_STATE">
2498 Session already open or being opened.
2499 </result>
2500 <result name="VBOX_E_INVALID_SESSION_STATE">
2501 Direct session state not Open.
2502 </result>
2503 <result name="VBOX_E_VM_ERROR">
2504 Failed to get console object from direct session or assign
2505 machine to session.
2506 </result>
2507
2508 <see>openRemoteSession</see>
2509 </desc>
2510 <param name="session" type="ISession" dir="in">
2511 <desc>
2512 Session object that will represent the open remote session
2513 after successful method invocation. This object must not
2514 represent an already open session.
2515 <note>
2516 This session will be automatically closed when the peer
2517 (direct) session dies or gets closed.
2518 </note>
2519 </desc>
2520 </param>
2521 <param name="machineId" type="uuid" dir="in">
2522 <desc>ID of the virtual machine to open a session with.</desc>
2523 </param>
2524 </method>
2525
2526 <method name="registerCallback">
2527 <desc>
2528 Registers a new global VirtualBox callback. The methods of the given
2529 callback object will be called by VirtualBox when an appropriate
2530 event occurs.
2531
2532 <result name="E_INVALIDARG">
2533 Registering a @c NULL @a callback is pretty pointless, ain't it?
2534 <!-- See if someone is actually reading this and objects :-) -->
2535 </result>
2536
2537 </desc>
2538 <param name="callback" type="IVirtualBoxCallback" dir="in">
2539 <desc>Callback object to register.</desc>
2540 </param>
2541 </method>
2542
2543 <method name="unregisterCallback">
2544 <desc>
2545 Unregisters the previously registered global VirtualBox callback.
2546
2547 <result name="E_INVALIDARG">
2548 Specified @a callback not registered.
2549 </result>
2550
2551 </desc>
2552 <param name="callback" type="IVirtualBoxCallback" dir="in">
2553 <desc>Callback object to unregister.</desc>
2554 </param>
2555 </method>
2556
2557 <method name="waitForPropertyChange">
2558 <desc>
2559 Blocks the caller until any of the properties represented by the @a
2560 what argument changes the value or until the given timeout interval
2561 expires.
2562
2563 The @a what argument is a comma separated list of property masks that
2564 describe properties the caller is interested in. The property mask is
2565 a string in the following format:
2566
2567 <pre>
2568 [[group.]subgroup.]name
2569 </pre>
2570
2571 where @c name is the property name and @c group, @c subgroup are zero
2572 or more property group specifiers. Each element (group or name) in
2573 the property mask may be either a Latin string or an asterisk symbol
2574 (@c "*") which is used to match any string for the given element. A
2575 property mask that doesn't contain asterisk symbols represents a
2576 single fully qualified property name.
2577
2578 Groups in the fully qualified property name go from more generic (the
2579 left-most part) to more specific (the right-most part). The first
2580 element is usually a name of the object the property belongs to. The
2581 second element may be either a property name, or a child object name,
2582 or an index if the preceding element names an object which is one of
2583 many objects of the same type. This way, property names form a
2584 hierarchy of properties. Here are some examples of property names:
2585
2586 <table>
2587 <tr>
2588 <td><tt>VirtualBox.version</tt></td>
2589 <td><link to="IVirtualBox::version"/> property</td>
2590 </tr>
2591 <tr>
2592 <td><tt>Machine.&lt;UUID&gt;.name</tt></td>
2593 <td><link to="IMachine::name"/> property of the machine with the
2594 given UUID</td>
2595 </tr>
2596 </table>
2597
2598 Most property names directly correspond to the properties of objects
2599 (components) provided by the VirtualBox library and may be used to
2600 track changes to these properties. However, there may be
2601 pseudo-property names that don't correspond to any existing object's
2602 property directly, as well as there may be object properties that
2603 don't have a corresponding property name that is understood by this
2604 method, and therefore changes to such properties cannot be
2605 tracked. See individual object's property descriptions to get a
2606 fully qualified property name that can be used with this method (if
2607 any).
2608
2609 There is a special property mask @c "*" (i.e. a string consisting of a
2610 single asterisk symbol) that can be used to match all properties.
2611 Below are more examples of property masks:
2612
2613 <table>
2614 <tr>
2615 <td><tt>VirtualBox.*</tt></td>
2616 <td>Track all properties of the VirtualBox object</td>
2617 </tr>
2618 <tr>
2619 <td><tt>Machine.*.name</tt></td>
2620 <td>Track changes to the <link to="IMachine::name"/> property of
2621 all registered virtual machines</td>
2622 </tr>
2623 </table>
2624
2625 <note>
2626 This function is not implemented in the current version of the
2627 product.
2628 </note>
2629 </desc>
2630 <param name="what" type="wstring" dir="in">
2631 <desc>Comma separated list of property masks.</desc>
2632 </param>
2633 <param name="timeout" type="unsigned long" dir="in">
2634 <desc>
2635 Wait timeout in milliseconds.
2636 Specify -1 for an indefinite wait.
2637 </desc>
2638 </param>
2639 <param name="changed" type="wstring" dir="out">
2640 <desc>
2641 Comma separated list of properties that have been changed and caused
2642 this method to return to the caller.
2643 </desc>
2644 </param>
2645 <param name="values" type="wstring" dir="out">
2646 <desc>Reserved, not currently used.</desc>
2647 </param>
2648 </method>
2649
2650 <method name="saveSettings">
2651 <desc>
2652 Saves the global settings to the global settings file
2653 (<link to="#settingsFilePath"/>).
2654
2655 This method is only useful for explicitly saving the global settings
2656 file after it has been auto-converted from the old format to the most
2657 recent format (see <link to="#settingsFileVersion"/> for details).
2658 Normally, the global settings file is implicitly saved when a global
2659 setting is changed.
2660
2661 <result name="VBOX_E_FILE_ERROR">
2662 Settings file not accessible.
2663 </result>
2664 <result name="VBOX_E_XML_ERROR">
2665 Could not parse the settings file.
2666 </result>
2667
2668 </desc>
2669 </method>
2670
2671 <method name="saveSettingsWithBackup">
2672 <desc>
2673 Creates a backup copy of the global settings file
2674 (<link to="#settingsFilePath"/>) in case of auto-conversion, and then
2675 calls <link to="#saveSettings()"/>.
2676
2677 Note that the backup copy is created <b>only</b> if the settings file
2678 auto-conversion took place (see <link to="#settingsFileVersion"/> for
2679 details). Otherwise, this call is fully equivalent to
2680 <link to="#saveSettings()"/> and no backup copying is done.
2681
2682 The backup copy is created in the same directory where the original
2683 settings file is located. It is given the following file name:
2684 <pre>
2685 original.xml.x.y-platform.bak
2686 </pre>
2687 where <tt>original.xml</tt> is the original settings file name
2688 (excluding path), and <tt>x.y-platform</tt> is the version of the old
2689 format of the settings file (before auto-conversion).
2690
2691 If the given backup file already exists, this method will try to add the
2692 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
2693 0 to 9) and copy it again until it succeeds. If all suffixes are
2694 occupied, or if any other copy error occurs, this method will return a
2695 failure.
2696
2697 If the copy operation succeeds, the @a bakFileName return argument will
2698 receive a full path to the created backup file (for informational
2699 purposes). Note that this will happen even if the subsequent
2700 <link to="#saveSettings()"/> call performed by this method after the
2701 copy operation, fails.
2702
2703 <note>
2704 The VirtualBox API never calls this method. It is intended purely for
2705 the purposes of creating backup copies of the settings files by
2706 front-ends before saving the results of the automatically performed
2707 settings conversion to disk.
2708 </note>
2709
2710 <see>settingsFileVersion</see>
2711
2712 <result name="VBOX_E_FILE_ERROR">
2713 Settings file not accessible.
2714 </result>
2715 <result name="VBOX_E_XML_ERROR">
2716 Could not parse the settings file.
2717 </result>
2718 <result name="VBOX_E_IPRT_ERROR">
2719 Could not copy the settings file.
2720 </result>
2721
2722 </desc>
2723 <param name="bakFileName" type="wstring" dir="return">
2724 <desc>Full path to the created backup copy.</desc>
2725 </param>
2726 </method>
2727
2728 </interface>
2729
2730 <!--
2731 // IAppliance
2732 /////////////////////////////////////////////////////////////////////////
2733 -->
2734
2735 <enum
2736 name="CIMOSType"
2737 uuid="86ef5f8c-18b2-4db8-a314-33721b59f89b"
2738 >
2739 <desc>
2740 OVF operating system values according to CIM V2.20 (as of Nov 2008); http://www.dmtf.org/standards/cim/cim_schema_v220
2741 </desc>
2742
2743 <const name="CIMOS_Unknown" value="0" /> <!-- "Unknown" -->
2744 <const name="CIMOS_Other" value="1" /> <!-- "Other" -->
2745 <const name="CIMOS_MACOS" value="2" /> <!-- "MACOS" -->
2746 <const name="CIMOS_ATTUNIX" value="3" /> <!-- "ATTUNIX" -->
2747 <const name="CIMOS_DGUX" value="4" /> <!-- "DGUX" -->
2748 <const name="CIMOS_DECNT" value="5" /> <!-- "DECNT" -->
2749 <const name="CIMOS_Tru64UNIX" value="6" /> <!-- "Tru64 UNIX" -->
2750 <const name="CIMOS_OpenVMS" value="7" /> <!-- "OpenVMS" -->
2751 <const name="CIMOS_HPUX" value="8" /> <!-- "HPUX" -->
2752 <const name="CIMOS_AIX" value="9" /> <!-- "AIX" -->
2753 <const name="CIMOS_MVS" value="10" /> <!-- "MVS" -->
2754 <const name="CIMOS_OS400" value="11" /> <!-- "OS400" -->
2755 <const name="CIMOS_OS2" value="12" /> <!-- "OS/2" -->
2756 <const name="CIMOS_JavaVM" value="13" /> <!-- "JavaVM" -->
2757 <const name="CIMOS_MSDOS" value="14" /> <!-- "MSDOS" -->
2758 <const name="CIMOS_WIN3x" value="15" /> <!-- "WIN3x" -->
2759 <const name="CIMOS_WIN95" value="16" /> <!-- "WIN95" -->
2760 <const name="CIMOS_WIN98" value="17" /> <!-- "WIN98" -->
2761 <const name="CIMOS_WINNT" value="18" /> <!-- "WINNT" -->
2762 <const name="CIMOS_WINCE" value="19" /> <!-- "WINCE" -->
2763 <const name="CIMOS_NCR3000" value="20" /> <!-- "NCR3000" -->
2764 <const name="CIMOS_NetWare" value="21" /> <!-- "NetWare" -->
2765 <const name="CIMOS_OSF" value="22" /> <!-- "OSF" -->
2766 <const name="CIMOS_DCOS" value="23" /> <!-- "DC/OS" -->
2767 <const name="CIMOS_ReliantUNIX" value="24" /> <!-- "Reliant UNIX" -->
2768 <const name="CIMOS_SCOUnixWare" value="25" /> <!-- "SCO UnixWare" -->
2769 <const name="CIMOS_SCOOpenServer" value="26" /> <!-- "SCO OpenServer" -->
2770 <const name="CIMOS_Sequent" value="27" /> <!-- "Sequent" -->
2771 <const name="CIMOS_IRIX" value="28" /> <!-- "IRIX" -->
2772 <const name="CIMOS_Solaris" value="29" /> <!-- "Solaris" -->
2773 <const name="CIMOS_SunOS" value="30" /> <!-- "SunOS" -->
2774 <const name="CIMOS_U6000" value="31" /> <!-- "U6000" -->
2775 <const name="CIMOS_ASERIES" value="32" /> <!-- "ASERIES" -->
2776 <const name="CIMOS_HPNonStopOS" value="33" /> <!-- "HP NonStop OS" -->
2777 <const name="CIMOS_HPNonStopOSS" value="34" /> <!-- "HP NonStop OSS" -->
2778 <const name="CIMOS_BS2000" value="35" /> <!-- "BS2000" -->
2779 <const name="CIMOS_LINUX" value="36" /> <!-- "LINUX" -->
2780 <const name="CIMOS_Lynx" value="37" /> <!-- "Lynx" -->
2781 <const name="CIMOS_XENIX" value="38" /> <!-- "XENIX" -->
2782 <const name="CIMOS_VM" value="39" /> <!-- "VM" -->
2783 <const name="CIMOS_InteractiveUNIX" value="40" /> <!-- "Interactive UNIX" -->
2784 <const name="CIMOS_BSDUNIX" value="41" /> <!-- "BSDUNIX" -->
2785 <const name="CIMOS_FreeBSD" value="42" /> <!-- "FreeBSD" -->
2786 <const name="CIMOS_NetBSD" value="43" /> <!-- "NetBSD" -->
2787 <const name="CIMOS_GNUHurd" value="44" /> <!-- "GNU Hurd" -->
2788 <const name="CIMOS_OS9" value="45" /> <!-- "OS9" -->
2789 <const name="CIMOS_MACHKernel" value="46" /> <!-- "MACH Kernel" -->
2790 <const name="CIMOS_Inferno" value="47" /> <!-- "Inferno" -->
2791 <const name="CIMOS_QNX" value="48" /> <!-- "QNX" -->
2792 <const name="CIMOS_EPOC" value="49" /> <!-- "EPOC" -->
2793 <const name="CIMOS_IxWorks" value="50" /> <!-- "IxWorks" -->
2794 <const name="CIMOS_VxWorks" value="51" /> <!-- "VxWorks" -->
2795 <const name="CIMOS_MiNT" value="52" /> <!-- "MiNT" -->
2796 <const name="CIMOS_BeOS" value="53" /> <!-- "BeOS" -->
2797 <const name="CIMOS_HPMPE" value="54" /> <!-- "HP MPE" -->
2798 <const name="CIMOS_NextStep" value="55" /> <!-- "NextStep" -->
2799 <const name="CIMOS_PalmPilot" value="56" /> <!-- "PalmPilot" -->
2800 <const name="CIMOS_Rhapsody" value="57" /> <!-- "Rhapsody" -->
2801 <const name="CIMOS_Windows2000" value="58" /> <!-- "Windows 2000" -->
2802 <const name="CIMOS_Dedicated" value="59" /> <!-- "Dedicated" -->
2803 <const name="CIMOS_OS390" value="60" /> <!-- "OS/390" -->
2804 <const name="CIMOS_VSE" value="61" /> <!-- "VSE" -->
2805 <const name="CIMOS_TPF" value="62" /> <!-- "TPF" -->
2806 <const name="CIMOS_WindowsMe" value="63" /> <!-- "Windows (R) Me" -->
2807 <const name="CIMOS_CalderaOpenUNIX" value="64" /> <!-- "Caldera Open UNIX" -->
2808 <const name="CIMOS_OpenBSD" value="65" /> <!-- "OpenBSD" -->
2809 <const name="CIMOS_NotApplicable" value="66" /> <!-- "Not Applicable" -->
2810 <const name="CIMOS_WindowsXP" value="67" /> <!-- "Windows XP" -->
2811 <const name="CIMOS_zOS" value="68" /> <!-- "z/OS" -->
2812 <const name="CIMOS_MicrosoftWindowsServer2003" value="69" /> <!-- "Microsoft Windows Server 2003" -->
2813 <const name="CIMOS_MicrosoftWindowsServer2003_64" value="70" /> <!-- "Microsoft Windows Server 2003 64-Bit" -->
2814 <const name="CIMOS_WindowsXP_64" value="71" /> <!-- "Windows XP 64-Bit" -->
2815 <const name="CIMOS_WindowsXPEmbedded" value="72" /> <!-- "Windows XP Embedded" -->
2816 <const name="CIMOS_WindowsVista" value="73" /> <!-- "Windows Vista" -->
2817 <const name="CIMOS_WindowsVista_64" value="74" /> <!-- "Windows Vista 64-Bit" -->
2818 <const name="CIMOS_WindowsEmbeddedforPointofService" value="75" /> <!-- "Windows Embedded for Point of Service" -->
2819 <const name="CIMOS_MicrosoftWindowsServer2008" value="76" /> <!-- "Microsoft Windows Server 2008" -->
2820 <const name="CIMOS_MicrosoftWindowsServer2008_64" value="77" /> <!-- "Microsoft Windows Server 2008 64-Bit" -->
2821 <const name="CIMOS_FreeBSD_64" value="78" /> <!-- "FreeBSD 64-Bit" -->
2822 <const name="CIMOS_RedHatEnterpriseLinux" value="79" /> <!-- "RedHat Enterprise Linux" -->
2823 <const name="CIMOS_RedHatEnterpriseLinux_64" value="80" /> <!-- "RedHat Enterprise Linux 64-Bit" -->
2824 <const name="CIMOS_Solaris_64" value="81" /> <!-- "Solaris 64-Bit" -->
2825 <const name="CIMOS_SUSE" value="82" /> <!-- "SUSE" -->
2826 <const name="CIMOS_SUSE_64" value="83" /> <!-- "SUSE 64-Bit" -->
2827 <const name="CIMOS_SLES" value="84" /> <!-- "SLES" -->
2828 <const name="CIMOS_SLES_64" value="85" /> <!-- "SLES 64-Bit" -->
2829 <const name="CIMOS_NovellOES" value="86" /> <!-- "Novell OES" -->
2830 <const name="CIMOS_NovellLinuxDesktop" value="87" /> <!-- "Novell Linux Desktop" -->
2831 <const name="CIMOS_SunJavaDesktopSystem" value="88" /> <!-- "Sun Java Desktop System" -->
2832 <const name="CIMOS_Mandriva" value="89" /> <!-- "Mandriva" -->
2833 <const name="CIMOS_Mandriva_64" value="90" /> <!-- "Mandriva 64-Bit" -->
2834 <const name="CIMOS_TurboLinux" value="91" /> <!-- "TurboLinux" -->
2835 <const name="CIMOS_TurboLinux_64" value="92" /> <!-- "TurboLinux 64-Bit" -->
2836 <const name="CIMOS_Ubuntu" value="93" /> <!-- "Ubuntu" -->
2837 <const name="CIMOS_Ubuntu_64" value="94" /> <!-- "Ubuntu 64-Bit" -->
2838 <const name="CIMOS_Debian" value="95" /> <!-- "Debian" -->
2839 <const name="CIMOS_Debian_64" value="96" /> <!-- "Debian 64-Bit" -->
2840 <const name="CIMOS_Linux_2_4_x" value="97" /> <!-- "Linux 2.4.x" -->
2841 <const name="CIMOS_Linux_2_4_x_64" value="98" /> <!-- "Linux 2.4.x 64-Bit" -->
2842 <const name="CIMOS_Linux_2_6_x" value="99" /> <!-- "Linux 2.6.x" -->
2843 <const name="CIMOS_Linux_2_6_x_64" value="100" /> <!-- "Linux 2.6.x 64-Bit" -->
2844 <const name="CIMOS_Linux_64" value="101" /> <!-- "Linux 64-Bit" -->
2845 <const name="CIMOS_Other_64" value="102" /> <!-- "Other 64-Bit" -->
2846 </enum>
2847
2848 <enum
2849 name="OVFResourceType"
2850 uuid="646a78d7-6f04-49f4-82c4-75c28a75a4cd"
2851 >
2852 <desc>
2853 OVF resource type.
2854 </desc>
2855
2856 <const name="Other" value="1" />
2857 <const name="ComputerSystem" value="2" />
2858 <const name="Processor" value="3" />
2859 <const name="Memory" value="4" />
2860 <const name="IdeController" value="5" />
2861 <const name="ParallelScsiHba" value="6" />
2862 <const name="FcHba" value="7" />
2863 <const name="iScsiHba" value="8" />
2864 <const name="IbHca" value="9" />
2865 <const name="EthernetAdapter" value="10" />
2866 <const name="OtherNetworkAdapter" value="11" />
2867 <const name="IoSlot" value="12" />
2868 <const name="IoDevice" value="13" />
2869 <const name="FloppyDrive" value="14" />
2870 <const name="CdDrive" value="15" />
2871 <const name="DvdDrive" value="16" />
2872 <const name="HardDisk" value="17" />
2873 <const name="UsbController" value="23" />
2874 <const name="SoundCard" value="35" />
2875 </enum>
2876
2877 <interface
2878 name="IAppliance" extends="$unknown"
2879 uuid="a7a71c1f-20d3-4483-95c0-7357dda77f50"
2880 wsmap="managed"
2881 >
2882 <desc>
2883 Represents an appliance in OVF format. An instance of this is returned by
2884 <link to="IVirtualBox::openAppliance" />.
2885
2886 Importing an OVF appliance into VirtualBox is a three-step process:
2887
2888 <ol>
2889 <li>
2890 Call <link to="IVirtualBox::openAppliance" /> with the full path of the OVF
2891 file. So long as the appliance file is syntactically valid, this will succeed
2892 and return an instance of IAppliance that contains the parsed data from the
2893 OVF file.
2894 </li>
2895
2896 <li>The caller should then invoke <link to="#interpret" />, which
2897 analyzes the OVF data and sets up the contents of the IAppliance attributes
2898 accordingly. These can be inspected by a VirtualBox front-end such as the GUI,
2899 and the suggestions can be displayed to the user. For example, the virtual system
2900 will contain the virtual hardware prescribed by the OVF (network and hardware
2901 adapters, virtual disk images, memory size and so on), and the GUI can then give
2902 the user the option to confirm and/or change these suggestions.
2903 </li>
2904
2905 <li>Finally, the caller should invoke <link to="#importAppliance" />, which will
2906 create virtual machines in VirtualBox as instances of <link to="IMachine" /> that
2907 match the information in the virtual system descriptions.
2908 </li>
2909 </ol>
2910
2911 </desc>
2912
2913 <attribute name="path" type="wstring" readonly="yes">
2914 <desc>Path to the main file of the OVF appliance, which is either the <tt>.ovf</tt> or
2915 the <tt>.ova</tt> file passed to <link to="IVirtualBox::openAppliance" />.</desc>
2916 </attribute>
2917
2918 <attribute name="disks" type="wstring" readonly="yes" safearray="yes">
2919 <desc>
2920 Array of virtual disk definitions. One such description exists for each
2921 disk definition in the OVF; each string array item represents one such piece of
2922 disk information, with the information fields separated by tab (\t) characters.
2923
2924 The caller should be prepared for additional fields being appended to
2925 this string in future versions of VirtualBox and therefore check for
2926 the number of tabs in the strings returned.
2927
2928 In the current version, the following eight fields are returned per string
2929 in the array:
2930
2931 <ol>
2932 <li>Disk ID (unique string identifier given to disk)</li>
2933 <li>Capacity (unsigned integer indicating the maximum capacity of the disk)</li>
2934 <li>Populated size (optional unsigned integer indicating the current size of the
2935 disk; can be approximate; -1 if unspecified)</li>
2936 <li>Format (string identifying the disk format, typically
2937 "http://www.vmware.com/specifications/vmdk.html#sparse")</li>
2938 <li>Reference (where to find the disk image, typically a file name; if empty,
2939 then the disk should be created on import)</li>
2940 <li>Image size (optional unsigned integer indicating the size of the image,
2941 which need not necessarily be the same as the values specified above, since
2942 the image may be compressed or sparse; -1 if not specified)</li>
2943 <li>Chunk size (optional unsigned integer if the image is split into chunks;
2944 presently unsupported and always -1)</li>
2945 <li>Compression (optional string equalling "gzip" if the image is gzip-compressed)</li>
2946 </ol>
2947 </desc>
2948 </attribute>
2949
2950 <attribute name="virtualSystemDescriptions" type="IVirtualSystemDescription" readonly="yes" safearray="yes">
2951 <desc>
2952 Array of virtual system descriptions. One such description is created
2953 for each virtual system found in the OVF. The array is empty until after <link to="#interpret" />
2954 has been called.
2955 </desc>
2956 </attribute>
2957
2958 <method name="interpret">
2959 <desc>
2960 Interprets the OVF data that was read when the appliance was constructed. After
2961 calling this method, one can inspect the
2962 <link to="#virtualSystemDescriptions" /> array attribute, which will then contain
2963 one <link to="IVirtualSystemDescription" /> for each virtual machine found in
2964 the appliance.
2965
2966 Calling this method is the second step of importing an appliance into VirtualBox;
2967 see <link to="IAppliance" /> for an overview.
2968 </desc>
2969 </method>
2970
2971 <method name="importAppliance">
2972 <desc>
2973 Imports the appliance into VirtualBox by creating instances of <link to="IMachine" />
2974 and other interfaces that match the information contained in the appliance as
2975 closely as possible, as represented by the import instructions in the
2976 <link to="#virtualSystemDescriptions" /> array.
2977
2978 Calling this method is the final step of importing an appliance into VirtualBox;
2979 see <link to="IAppliance" /> for an overview.
2980
2981 Since importing the appliance may imply copying disk images, which can take a long
2982 time, this method operates asynchronously and returns an IProgress object to allow
2983 the caller to monitor the progress.
2984 </desc>
2985
2986 <param name="aProgress" type="IProgress" dir="return">
2987 <desc></desc>
2988 </param>
2989 </method>
2990
2991 </interface>
2992
2993 <enum
2994 name="VirtualSystemDescriptionType"
2995 uuid="8ac36d00-bb7c-4a35-a835-3f004b27427b"
2996 >
2997 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of
2998 a configuration value.</desc>
2999
3000 <const name="Ignore" value="1" />
3001 <const name="Name" value="2" />
3002 <const name="OS" value="3" />
3003 <const name="CPU" value="4" />
3004 <const name="Memory" value="5" />
3005 <const name="HardDiskControllerIDE" value="6" />
3006 <const name="HardDiskControllerSATA" value="7" />
3007 <const name="HardDiskControllerSCSI" value="8" />
3008 <const name="HardDiskImage" value="9" />
3009 <const name="CDROM" value="10" />
3010 <const name="Floppy" value="11" />
3011 <const name="NetworkAdapter" value="12" />
3012 <const name="USBController" value="13" />
3013 <const name="SoundCard" value="14" />
3014
3015 </enum>
3016
3017 <interface
3018 name="IVirtualSystemDescription" extends="$unknown"
3019 uuid="8606c2ae-c06f-487f-9573-1465b44f9524"
3020 wsmap="managed"
3021 >
3022
3023 <desc>This interface is used in the <link to="IAppliance::virtualSystemDescriptions" /> array.
3024 After <link to="IAppliance::interpret" /> has been called, that array contains
3025 information about how the virtual systems described in the OVF should best be imported into VirtualBox
3026 virtual machines. See <link to="IAppliance" /> for the steps required to import an OVF
3027 into VirtualBox.
3028 </desc>
3029
3030 <attribute name="count" type="unsigned long" readonly="yes">
3031 <desc>Return the number of virtual system description entries.</desc>
3032 </attribute>
3033
3034 <method name="getDescription">
3035 <desc>Returns information about the virtual system as arrays of instruction items. In each array, the
3036 items with the same indices correspond and jointly represent an import instruction for VirtualBox.
3037
3038 The list below identifies the value sets that are possible depending on the
3039 <link to="VirtualSystemDescriptionType" /> enum value in the array item in aTypes[]. In each case,
3040 the array item with the same index in aOrigValue[] will contain the original value as contained
3041 in the OVF file (just for informational purposes), and the corresponding item in aConfigValues[]
3042 will contain a suggested value to be used for VirtualBox. Depending on the description type,
3043 the aExtraConfigValues[] array item may also be used.
3044
3045 <ul>
3046 <li>
3047 "OS": the guest operating system type. There must be exactly one such array item on import. The
3048 corresponding item in aConfigValues[] contains the suggested guest operating system for VirtualBox.
3049 This will be one of the values listed in <link to="IVirtualBox::guestOSTypes" />. The corresponding
3050 item in aOrigValues[] will contain a numerical value that described the operating system in the OVF
3051 (see <link to="CIMOSType" />).
3052 </li>
3053 <li>
3054 "Name": the name to give to the new virtual machine. There can be at most one such array item;
3055 if none is present on import, then an automatic name will be created from the operating system
3056 type. The correponding item im aOrigValues[] will contain the suggested virtual machine name
3057 from the OVF file, and aConfigValues[] will contain a suggestion for a unique VirtualBox
3058 <link to="IMachine" /> name that does not exist yet.
3059 </li>
3060 <li>
3061 "CPU": the number of CPUs. There can be at most one such item, which will presently be ignored.
3062 </li>
3063 <li>
3064 "Memory": the amount of guest RAM, in bytes. There can be at most one such array item; if none
3065 is present on import, then VirtualBox will set a meaningful default based on the operating system
3066 type.
3067 </li>
3068 <li>
3069 "HarddiskControllerSCSI": a SCSI hard disk controller. There can be at most one such item.
3070 The items in aOrigValues[] and aConfigValues[] will either be "LsiLogic" or "BusLogic". The
3071 matching item in the aRefs[] array will contain an integer that other items of the "Harddisk"
3072 type can use to specify which hard disk controller a virtual disk should be connected to.
3073 </li>
3074 <li>
3075 "HarddiskControllerIDE": an IDE hard disk controller. There can be at most one such item. This
3076 has no value in aOrigValues[] or aAutoValues[]. The matching item in the aRefs[] array will be
3077 used as with SCSI controllers (see above).
3078 </li>
3079 <li>
3080 "Harddisk": a virtual hard disk, most probably as a reference to an image file. There can be an
3081 arbitrary number of these items, one for each virtual disk image that accompanies the OVF. The
3082 array item in aOrigValues[] will contain the file specification from the OVF file, whereas the item
3083 in aConfigValues[] will contain a qualified path specification where the hard disk image should
3084 be copied to; this target image will then be registered with VirtualBox.
3085 The matching item in the aRefs[] array must contain a integer specifying the hard disk controller
3086 to connect the image to. This number must be the same as the integer used by one of the hard disk
3087 controller items (SCSI, SATA or IDE; see above).
3088 </li>
3089 <li>
3090 "NetworkAdapter": a network adapter. (todo document)
3091 </li>
3092 <li>
3093 "SoundCard": a sound card. There can be at most one such item. If and only if such an item is
3094 present, sound support will be enabled for the new virtual machine. Note that the virtual
3095 machine in VirtualBox will always be presented with the standard VirtualBox soundcard, which
3096 may be different from the virtual soundcard expected by the appliance.
3097 </li>
3098 </ul>
3099
3100 </desc>
3101
3102 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
3103 <desc></desc>
3104 </param>
3105
3106 <param name="aRefs" type="wstring" dir="out" safearray="yes">
3107 <desc></desc>
3108 </param>
3109
3110 <param name="aOrigValues" type="wstring" dir="out" safearray="yes">
3111 <desc></desc>
3112 </param>
3113
3114 <param name="aConfigValues" type="wstring" dir="out" safearray="yes">
3115 <desc></desc>
3116 </param>
3117
3118 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
3119 <desc></desc>
3120 </param>
3121
3122 </method>
3123
3124 <method name="disableItem">
3125 <desc>
3126 Disables part of the configuration, as represented by the array items returned by
3127 <link to="getDescription" />. For example, to disable USB support for a given
3128 virtual system, pass in the array item index of the USB controller; its type will
3129 then be changed by this method from "USBController" to "Ignore".
3130
3131 This works only for items of the types HardDiskControllerIDE, HardDiskControllerSATA,
3132 HardDiskControllerSCSI, HardDiskImage, CDROM, Floppy, NetworkAdapter, USBController
3133 and SoundCard.
3134 </desc>
3135
3136 <param name="index" type="unsigned long" dir="in">
3137 </param>
3138 </method>
3139
3140 <method name="SetFinalValues">
3141 <desc></desc>
3142
3143 <param name="aFinaleValues" type="wstring" dir="in" safearray="yes">
3144 <desc></desc>
3145 </param>
3146
3147 </method>
3148
3149 <method name="getWarnings">
3150 <desc>Returns textual warnings which occurs on the virtual system
3151 interpretion.</desc>
3152
3153 <param name="aWarnings" type="wstring" dir="return" safearray="yes">
3154 <desc></desc>
3155 </param>
3156 </method>
3157
3158 </interface>
3159
3160
3161 <!--
3162 // IMachine
3163 /////////////////////////////////////////////////////////////////////////
3164 -->
3165
3166 <enumerator
3167 name="IMachineEnumerator" type="IMachine"
3168 uuid="1b554149-be0a-4465-9252-9ff8f420af55"
3169 />
3170
3171 <collection
3172 name="IMachineCollection" type="IMachine" enumerator="IMachineEnumerator"
3173 uuid="FD443EC1-3007-4F5B-9282-D72760A66916"
3174 readonly="yes"
3175 />
3176
3177 <interface
3178 name="IInternalMachineControl" extends="$unknown"
3179 uuid="4042ddf2-93d3-4749-8517-dde3f17ea630"
3180 internal="yes"
3181 wsmap="suppress"
3182 >
3183 <method name="updateState">
3184 <desc>
3185 Updates the VM state.
3186 <note>
3187 This operation will also update the settings file with
3188 the correct information about the saved state file
3189 and delete this file from disk when appropriate.
3190 </note>
3191 </desc>
3192 <param name="state" type="MachineState" dir="in"/>
3193 </method>
3194
3195 <method name="getIPCId">
3196 <param name="id" type="wstring" dir="return"/>
3197 </method>
3198
3199 <method name="runUSBDeviceFilters">
3200 <desc>
3201 Asks the server to run USB devices filters of the associated
3202 machine against the given USB device and tell if there is
3203 a match.
3204 <note>
3205 Intended to be used only for remote USB devices. Local
3206 ones don't require to call this method (this is done
3207 implicitly by the Host and USBProxyService).
3208 </note>
3209 </desc>
3210 <param name="device" type="IUSBDevice" dir="in"/>
3211 <param name="matched" type="boolean" dir="out"/>
3212 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
3213 </method>
3214
3215 <method name="captureUSBDevice">
3216 <desc>
3217 Requests a capture of the given host USB device.
3218 When the request is completed, the VM process will
3219 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3220 notification.
3221 </desc>
3222 <param name="id" type="uuid" dir="in"/>
3223 </method>
3224
3225 <method name="detachUSBDevice">
3226 <desc>
3227 Notification that a VM is going to detach (done = false) or has
3228 already detached (done = true) the given USB device.
3229 When the done = true request is completed, the VM process will
3230 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
3231 notification.
3232 <note>
3233 In the done = true case, the server must run its own filters
3234 and filters of all VMs but this one on the detached device
3235 as if it were just attached to the host computer.
3236 </note>
3237 </desc>
3238 <param name="id" type="uuid" dir="in"/>
3239 <param name="done" type="boolean" dir="in"/>
3240 </method>
3241
3242 <method name="autoCaptureUSBDevices">
3243 <desc>
3244 Requests a capture all matching USB devices attached to the host.
3245 When the request is completed, the VM process will
3246 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3247 notification per every captured device.
3248 </desc>
3249 </method>
3250
3251 <method name="detachAllUSBDevices">
3252 <desc>
3253 Notification that a VM that is being powered down. The done
3254 parameter indicates whether which stage of the power down
3255 we're at. When done = false the VM is announcing its
3256 intentions, while when done = true the VM is reporting
3257 what it has done.
3258 <note>
3259 In the done = true case, the server must run its own filters
3260 and filters of all VMs but this one on all detach devices as
3261 if they were just attached to the host computer.
3262 </note>
3263 </desc>
3264 <param name="done" type="boolean" dir="in"/>
3265 </method>
3266
3267 <method name="onSessionEnd">
3268 <desc>
3269 Triggered by the given session object when the session is about
3270 to close normally.
3271 </desc>
3272 <param name="session" type="ISession" dir="in">
3273 <desc>Session that is being closed</desc>
3274 </param>
3275 <param name="progress" type="IProgress" dir="return">
3276 <desc>
3277 Used to wait until the corresponding machine is actually
3278 dissociated from the given session on the server.
3279 Returned only when this session is a direct one.
3280 </desc>
3281 </param>
3282 </method>
3283
3284 <method name="beginSavingState">
3285 <desc>
3286 Called by the VM process to inform the server it wants to
3287 save the current state and stop the VM execution.
3288 </desc>
3289 <param name="progress" type="IProgress" dir="in">
3290 <desc>
3291 Progress object created by the VM process to wait until
3292 the state is saved.
3293 </desc>
3294 </param>
3295 <param name="stateFilePath" type="wstring" dir="out">
3296 <desc>
3297 File path the VM process must save the execution state to.
3298 </desc>
3299 </param>
3300 </method>
3301
3302 <method name="endSavingState">
3303 <desc>
3304 Called by the VM process to inform the server that saving
3305 the state previously requested by #beginSavingState is either
3306 successfully finished or there was a failure.
3307
3308 <result name="VBOX_E_FILE_ERROR">
3309 Settings file not accessible.
3310 </result>
3311 <result name="VBOX_E_XML_ERROR">
3312 Could not parse the settings file.
3313 </result>
3314
3315 </desc>
3316
3317 <param name="success" type="boolean" dir="in">
3318 <desc><tt>true</tt> to indicate success and <tt>false</tt>
3319 otherwise.
3320 </desc>
3321 </param>
3322 </method>
3323
3324 <method name="adoptSavedState">
3325 <desc>
3326 Gets called by IConsole::adoptSavedState.
3327 <result name="VBOX_E_FILE_ERROR">
3328 Invalid saved state file path.
3329 </result>
3330 </desc>
3331 <param name="savedStateFile" type="wstring" dir="in">
3332 <desc>Path to the saved state file to adopt.</desc>
3333 </param>
3334 </method>
3335
3336 <method name="beginTakingSnapshot">
3337 <desc>
3338 Called by the VM process to inform the server it wants to
3339 take a snapshot.
3340
3341 <result name="VBOX_E_FILE_ERROR">
3342 Settings file not accessible.
3343 </result>
3344 <result name="VBOX_E_XML_ERROR">
3345 Could not parse the settings file.
3346 </result>
3347 </desc>
3348 <param name="initiator" type="IConsole" dir="in">
3349 <desc>The console object that initiated this call.</desc>
3350 </param>
3351 <param name="name" type="wstring" dir="in">
3352 <desc>Snapshot name.</desc>
3353 </param>
3354 <param name="description" type="wstring" dir="in">
3355 <desc>Snapshot description.</desc>
3356 </param>
3357 <param name="progress" type="IProgress" dir="in">
3358 <desc>
3359 Progress object created by the VM process to wait until
3360 the state is saved (only for online snapshots).
3361 </desc>
3362 </param>
3363 <param name="stateFilePath" type="wstring" dir="out">
3364 <desc>
3365 File path the VM process must save the execution state to.
3366 </desc>
3367 </param>
3368 <param name="serverProgress" type="IProgress" dir="out">
3369 <desc>
3370 Progress object created by the server process to wait until
3371 the snapshot is taken (VDI diff creation, etc.).
3372 </desc>
3373 </param>
3374 </method>
3375
3376 <method name="endTakingSnapshot">
3377 <desc>
3378 Called by the VM process to inform the server that the snapshot
3379 previously requested by #beginTakingSnapshot is either
3380 successfully taken or there was a failure.
3381 </desc>
3382
3383 <param name="success" type="boolean" dir="in">
3384 <desc><tt>true</tt> to indicate success and <tt>false</tt> otherwise</desc>
3385 </param>
3386 </method>
3387
3388 <method name="discardSnapshot">
3389 <desc>
3390 Gets called by IConsole::discardSnapshot.
3391 <result name="VBOX_E_INVALID_OBJECT_STATE">
3392 Snapshot has more than one child snapshot.
3393 </result>
3394 </desc>
3395 <param name="initiator" type="IConsole" dir="in">
3396 <desc>The console object that initiated this call.</desc>
3397 </param>
3398 <param name="id" type="uuid" dir="in">
3399 <desc>UUID of the snapshot to discard.</desc>
3400 </param>
3401 <param name="machineState" type="MachineState" dir="out">
3402 <desc>New machine state after this operation is started.</desc>
3403 </param>
3404 <param name="progress" type="IProgress" dir="return">
3405 <desc>Progress object to track the operation completion.</desc>
3406 </param>
3407 </method>
3408
3409 <method name="discardCurrentState">
3410 <desc>
3411 Gets called by IConsole::discardCurrentState.
3412 <result name="VBOX_E_INVALID_OBJECT_STATE">
3413 Virtual machine does not have any snapshot.
3414 </result>
3415 </desc>
3416 <param name="initiator" type="IConsole" dir="in">
3417 <desc>The console object that initiated this call.</desc>
3418 </param>
3419 <param name="machineState" type="MachineState" dir="out">
3420 <desc>New machine state after this operation is started.</desc>
3421 </param>
3422 <param name="progress" type="IProgress" dir="return">
3423 <desc>Progress object to track the operation completion.</desc>
3424 </param>
3425 </method>
3426
3427 <method name="discardCurrentSnapshotAndState">
3428 <desc>
3429 Gets called by IConsole::discardCurrentSnapshotAndState.
3430 <result name="VBOX_E_INVALID_OBJECT_STATE">
3431 Virtual machine does not have any snapshot.
3432 </result>
3433 </desc>
3434 <param name="initiator" type="IConsole" dir="in">
3435 <desc>The console object that initiated this call.</desc>
3436 </param>
3437 <param name="machineState" type="MachineState" dir="out">
3438 <desc>New machine state after this operation is started.</desc>
3439 </param>
3440 <param name="progress" type="IProgress" dir="return">
3441 <desc>Progress object to track the operation completion.</desc>
3442 </param>
3443 </method>
3444
3445 <method name="pullGuestProperties">
3446 <desc>
3447 Get the list of the guest properties matching a set of patterns along
3448 with their values, time stamps and flags and give responsibility for
3449 managing properties to the console.
3450 </desc>
3451 <param name="name" type="wstring" dir="out" safearray="yes">
3452 <desc>
3453 The names of the properties returned.
3454 </desc>
3455 </param>
3456 <param name="value" type="wstring" dir="out" safearray="yes">
3457 <desc>
3458 The values of the properties returned. The array entries match the
3459 corresponding entries in the @a name array.
3460 </desc>
3461 </param>
3462 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
3463 <desc>
3464 The time stamps of the properties returned. The array entries match
3465 the corresponding entries in the @a name array.
3466 </desc>
3467 </param>
3468 <param name="flags" type="wstring" dir="out" safearray="yes">
3469 <desc>
3470 The flags of the properties returned. The array entries match the
3471 corresponding entries in the @a name array.
3472 </desc>
3473 </param>
3474 </method>
3475
3476 <method name="pushGuestProperties">
3477 <desc>
3478 Set the list of the guest properties matching a set of patterns along
3479 with their values, time stamps and flags and return responsibility for
3480 managing properties to IMachine.
3481 </desc>
3482 <param name="name" type="wstring" dir="in" safearray="yes">
3483 <desc>
3484 The names of the properties.
3485 </desc>
3486 </param>
3487 <param name="value" type="wstring" dir="in" safearray="yes">
3488 <desc>
3489 The values of the properties. The array entries match the
3490 corresponding entries in the @a name array.
3491 </desc>
3492 </param>
3493 <param name="timestamp" type="unsigned long long" dir="in" safearray="yes">
3494 <desc>
3495 The time stamps of the properties. The array entries match
3496 the corresponding entries in the @a name array.
3497 </desc>
3498 </param>
3499 <param name="flags" type="wstring" dir="in" safearray="yes">
3500 <desc>
3501 The flags of the properties. The array entries match the
3502 corresponding entries in the @a name array.
3503 </desc>
3504 </param>
3505 </method>
3506 <method name="pushGuestProperty">
3507 <desc>
3508 Update a single guest property in IMachine.
3509 </desc>
3510 <param name="name" type="wstring" dir="in">
3511 <desc>
3512 The name of the property to be updated.
3513 </desc>
3514 </param>
3515 <param name="value" type="wstring" dir="in">
3516 <desc>
3517 The value of the property.
3518 </desc>
3519 </param>
3520 <param name="timestamp" type="unsigned long long" dir="in">
3521 <desc>
3522 The timestamp of the property.
3523 </desc>
3524 </param>
3525 <param name="flags" type="wstring" dir="in">
3526 <desc>
3527 The flags of the property.
3528 </desc>
3529 </param>
3530 </method>
3531 </interface>
3532
3533 <interface
3534 name="IBIOSSettings" extends="$unknown"
3535 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
3536 wsmap="managed"
3537 >
3538 <desc>
3539 The IBIOSSettings interface represents BIOS settings of the virtual
3540 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
3541 </desc>
3542 <attribute name="logoFadeIn" type="boolean">
3543 <desc>Fade in flag for BIOS logo animation.</desc>
3544 </attribute>
3545
3546 <attribute name="logoFadeOut" type="boolean">
3547 <desc>Fade out flag for BIOS logo animation.</desc>
3548 </attribute>
3549
3550 <attribute name="logoDisplayTime" type="unsigned long">
3551 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
3552 </attribute>
3553
3554 <attribute name="logoImagePath" type="wstring">
3555 <desc>Local file system path for external BIOS image.</desc>
3556 </attribute>
3557
3558 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
3559 <desc>Mode of the BIOS boot device menu.</desc>
3560 </attribute>
3561
3562 <attribute name="ACPIEnabled" type="boolean">
3563 <desc>ACPI support flag.</desc>
3564 </attribute>
3565
3566 <attribute name="IOAPICEnabled" type="boolean">
3567 <desc>
3568 IO APIC support flag. If set, VirtualBox will provide an IO APIC
3569 and support IRQs above 15.
3570 </desc>
3571 </attribute>
3572
3573 <attribute name="timeOffset" type="long long">
3574 <desc>
3575 Offset in milliseconds from the host system time. This allows for
3576 guests running with a different system date/time than the host.
3577 It is equivalent to setting the system date/time in the BIOS except
3578 it is not an absolute value but a relative one. Guest Additions
3579 time synchronization honors this offset.
3580 </desc>
3581 </attribute>
3582
3583 <attribute name="PXEDebugEnabled" type="boolean">
3584 <desc>
3585 PXE debug logging flag. If set, VirtualBox will write extensive
3586 PXE trace information to the release log.
3587 </desc>
3588 </attribute>
3589
3590 <attribute name="IDEControllerType" type="IDEControllerType">
3591 <desc>
3592 Type of the virtual IDE controller. Depending on this value,
3593 VirtualBox will provide different virtual IDE hardware
3594 devices to the guest.
3595 </desc>
3596 </attribute>
3597
3598 </interface>
3599
3600 <interface
3601 name="IMachine" extends="$unknown"
3602 uuid="ea6fb7ea-1993-4642-b113-f29eb39e0df0"
3603 wsmap="managed"
3604 >
3605 <desc>
3606 The IMachine interface represents a virtual machine, or guest, created
3607 in VirtualBox.
3608
3609 This interface is used in two contexts. First of all, a collection of
3610 objects implementing this interface is stored in the
3611 <link to="IVirtualBox::machines2"/> attribute which lists all the virtual
3612 machines that are currently registered with this VirtualBox
3613 installation. Also, once a session has been opened for the given virtual
3614 machine (e.g. the virtual machine is running), the machine object
3615 associated with the open session can be queried from the session object;
3616 see <link to="ISession"/> for details.
3617
3618 The main role of this interface is to expose the settings of the virtual
3619 machine and provide methods to change various aspects of the virtual
3620 machine's configuration. For machine objects stored in the
3621 <link to="IVirtualBox::machines2"/> collection, all attributes are
3622 read-only unless explicitly stated otherwise in individual attribute
3623 and method descriptions. In order to change a machine setting, a session
3624 for this machine must be opened using one of
3625 <link to="IVirtualBox::openSession"/>,
3626 <link to="IVirtualBox::openRemoteSession"/> or
3627 <link to="IVirtualBox::openExistingSession"/> methods. After the
3628 session has been successfully opened, a mutable machine object needs to
3629 be queried from the session object and then the desired settings changes
3630 can be applied to the returned object using IMachine attributes and
3631 methods. See the ISession interface description for more information
3632 about sessions.
3633
3634 Note that the IMachine interface does not provide methods to control
3635 virtual machine execution (such as start the machine, or power it
3636 down) -- these methods are grouped in a separate IConsole
3637 interface. Refer to the IConsole interface description to get more
3638 information about this topic.
3639
3640 <see>ISession, IConsole</see>
3641 </desc>
3642
3643 <attribute name="parent" type="IVirtualBox" readonly="yes">
3644 <desc>Associated parent object.</desc>
3645 </attribute>
3646
3647 <attribute name="accessible" type="boolean" readonly="yes">
3648 <desc>
3649 Whether this virtual machine is currently accessible or not.
3650
3651 The machine is considered to be inaccessible when:
3652 <ul>
3653 <li>It is a registered virtual machine, and
3654 </li>
3655 <li>Its settings file is inaccessible (for example, it is
3656 located on a network share that is not accessible during
3657 VirtualBox startup, or becomes inaccessible later, or if
3658 the settings file can be read but is invalid).
3659 </li>
3660 </ul>
3661
3662 Otherwise, the value of this property is always <tt>true</tt>.
3663
3664 Every time this property is read, the accessibility state of
3665 this machine is re-evaluated. If the returned value is |false|,
3666 the <link to="#accessError"/> property may be used to get the
3667 detailed error information describing the reason of
3668 inaccessibility.
3669
3670 When the machine is inaccessible, only the following properties
3671 can be used on it:
3672 <ul>
3673 <li><link to="#parent"/></li>
3674 <li><link to="#id"/></li>
3675 <li><link to="#settingsFilePath"/></li>
3676 <li><link to="#accessible"/></li>
3677 <li><link to="#accessError"/></li>
3678 </ul>
3679
3680 An attempt to access any other property or method will return
3681 an error.
3682
3683 The only possible action you can perform on an inaccessible
3684 machine is to unregister it using the
3685 <link to="IVirtualBox::unregisterMachine"/> call (or, to check
3686 for the accessibility state once more by querying this
3687 property).
3688
3689 <note>
3690 In the current implementation, once this property returns
3691 <tt>true</tt>, the machine will never become inaccessible
3692 later, even if its settings file cannot be successfully
3693 read/written any more (at least, until the VirtualBox
3694 server is restarted). This limitation may be removed in
3695 future releases.
3696 </note>
3697 </desc>
3698 </attribute>
3699
3700 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
3701 <desc>
3702 Error information describing the reason of machine
3703 inaccessibility.
3704
3705 Reading this property is only valid after the last call to
3706 <link to="#accessible"/> returned <tt>false</tt> (i.e. the
3707 machine is currently unaccessible). Otherwise, a null
3708 IVirtualBoxErrorInfo object will be returned.
3709 </desc>
3710 </attribute>
3711
3712 <attribute name="name" type="wstring">
3713 <desc>
3714 Name of the virtual machine.
3715
3716 Besides being used for human-readable identification purposes
3717 everywhere in VirtualBox, the virtual machine name is also used
3718 as a name of the machine's settings file and as a name of the
3719 subdirectory this settings file resides in. Thus, every time you
3720 change the value of this property, the settings file will be
3721 renamed once you call <link to="#saveSettings()"/> to confirm the
3722 change. The containing subdirectory will be also renamed, but
3723 only if it has exactly the same name as the settings file
3724 itself prior to changing this property (for backward compatibility
3725 with previous API releases). The above implies the following
3726 limitations:
3727 <ul>
3728 <li>The machine name cannot be empty.</li>
3729 <li>The machine name can contain only characters that are valid
3730 file name characters according to the rules of the file
3731 system used to store VirtualBox configuration.</li>
3732 <li>You cannot have two or more machines with the same name
3733 if they use the same subdirectory for storing the machine
3734 settings files.</li>
3735 <li>You cannot change the name of the machine if it is running,
3736 or if any file in the directory containing the settings file
3737 is being used by another running machine or by any other
3738 process in the host operating system at a time when
3739 <link to="#saveSettings()"/> is called.
3740 </li>
3741 </ul>
3742 If any of the above limitations are hit, <link to="#saveSettings()"/>
3743 will return an appropriate error message explaining the exact
3744 reason and the changes you made to this machine will not be
3745 saved.
3746 <note>
3747 For "legacy" machines created using the
3748 <link to="IVirtualBox::createLegacyMachine()"/> call,
3749 the above naming limitations do not apply because the
3750 machine name does not affect the settings file name.
3751 The settings file name remains the same as it was specified
3752 during machine creation and never changes.
3753 </note>
3754 </desc>
3755 </attribute>
3756
3757 <attribute name="description" type="wstring">
3758 <desc>
3759 Description of the virtual machine.
3760
3761 The description attribute can contain any text and is
3762 typically used to describe the hardware and software
3763 configuration of the virtual machine in detail (i.e. network
3764 settings, versions of the installed software and so on).
3765 </desc>
3766 </attribute>
3767
3768 <attribute name="id" type="uuid" readonly="yes">
3769 <desc>UUID of the virtual machine.</desc>
3770 </attribute>
3771
3772 <attribute name="OSTypeId" type="wstring">
3773 <desc>
3774 User-defined identifier of the Guest OS type.
3775 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
3776 an IGuestOSType object representing details about the given
3777 Guest OS type.
3778 <note>
3779 This value may differ from the value returned by
3780 <link to="IGuest::OSTypeId"/> if Guest Additions are
3781 installed to the guest OS.
3782 </note>
3783 </desc>
3784 </attribute>
3785
3786 <attribute name="HardwareVersion" type="wstring">
3787 <desc>Hardware version identifier. Internal use only for now.</desc>
3788 </attribute>
3789
3790 <attribute name="CPUCount" type="unsigned long">
3791 <desc>Number of virtual CPUs in the VM. In the current version of the product, this is always 1.</desc>
3792 </attribute>
3793
3794 <attribute name="memorySize" type="unsigned long">
3795 <desc>System memory size in megabytes.</desc>
3796 </attribute>
3797
3798 <attribute name="memoryBalloonSize" type="unsigned long">
3799 <desc>Initial memory balloon size in megabytes.</desc>
3800 </attribute>
3801
3802 <attribute name="statisticsUpdateInterval" type="unsigned long">
3803 <desc>Initial interval to update guest statistics in seconds.</desc>
3804 </attribute>
3805
3806 <attribute name="VRAMSize" type="unsigned long">
3807 <desc>Video memory size in megabytes.</desc>
3808 </attribute>
3809
3810 <attribute name="accelerate3DEnabled" type="boolean" default="false">
3811 <desc>
3812 This setting determines whether VirtualBox allows guests to make use
3813 of the 3D graphics support available on the host. Currently limited
3814 to OpenGL only. </desc>
3815 </attribute>
3816
3817 <attribute name="monitorCount" type="unsigned long">
3818 <desc>
3819 Number of virtual monitors.
3820 <note>
3821 Only effective on Windows XP and later guests with
3822 Guest Additions installed.
3823 </note>
3824 </desc>
3825 </attribute>
3826
3827 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
3828 <desc>Object containing all BIOS settings.</desc>
3829 </attribute>
3830
3831 <attribute name="HWVirtExEnabled" type="TSBool">
3832 <desc>
3833 This setting determines whether VirtualBox will try to make use of
3834 the host CPU's hardware virtualization extensions such as Intel VT-x
3835 and AMD-V. Note that in case such extensions are not available,
3836 they will not be used.
3837 </desc>
3838 </attribute>
3839
3840 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" default="false">
3841 <desc>
3842 This setting determines whether VirtualBox will try to make use of
3843 the nested paging extension of Intel VT-x and AMD-V. Note that in case
3844 such extensions are not available, they will not be used.
3845 </desc>
3846 </attribute>
3847
3848 <attribute name="HWVirtExVPIDEnabled" type="boolean" default="false">
3849 <desc>
3850 This setting determines whether VirtualBox will try to make use of
3851 the VPID extension of Intel VT-x. Note that in case such extensions are
3852 not available, they will not be used.
3853 </desc>
3854 </attribute>
3855
3856 <attribute name="PAEEnabled" type="boolean" default="false">
3857 <desc>
3858 This setting determines whether VirtualBox will expose the Physical Address
3859 Extension (PAE) feature of the host CPU to the guest. Note that in case PAE
3860 is not available, it will not be reported.
3861 </desc>
3862 </attribute>
3863
3864 <attribute name="snapshotFolder" type="wstring">
3865 <desc>
3866 Full path to the directory used to store snapshot data
3867 (differencing hard disks and saved state files) of this machine.
3868
3869 The initial value of this property is
3870 <tt>&lt;</tt><link to="#settingsFilePath">
3871 path_to_settings_file</link><tt>&gt;/&lt;</tt>
3872 <link to="#id">machine_uuid</link>
3873 <tt>&gt;</tt>.
3874
3875 Currently, it is an error to try to change this property on
3876 a machine that has snapshots (because this would require to
3877 move possibly large files to a different location).
3878 A separate method will be available for this purpose later.
3879
3880 <note>
3881 Setting this property to <tt>null</tt> will restore the
3882 initial value.
3883 </note>
3884 <note>
3885 When setting this property, the specified path can be
3886 absolute (full path) or relative to the directory where the
3887 <link to="#settingsFilePath">machine settings file</link>
3888 is located. When reading this property, a full path is
3889 always returned.
3890 </note>
3891 <note>
3892 The specified path may not exist, it will be created
3893 when necessary.
3894 </note>
3895 </desc>
3896 </attribute>
3897
3898 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
3899 <desc>VRDP server object.</desc>
3900 </attribute>
3901
3902 <attribute name="hardDisk2Attachments" type="IHardDisk2Attachment" readonly="yes" safearray="yes">
3903 <desc>Array of hard disks attached to this machine.</desc>
3904 </attribute>
3905
3906 <attribute name="DVDDrive" type="IDVDDrive" readonly="yes">
3907 <desc>Associated DVD drive object.</desc>
3908 </attribute>
3909
3910 <attribute name="floppyDrive" type="IFloppyDrive" readonly="yes">
3911 <desc>Associated floppy drive object.</desc>
3912 </attribute>
3913
3914 <attribute name="USBController" type="IUSBController" readonly="yes">
3915 <desc>
3916 Associated USB controller object.
3917
3918 <note>
3919 This method may set a @ref com_warnings "warning result code".
3920 </note>
3921 <note>
3922 If USB functionality is not available in the given edition of
3923 VirtualBox, this method will set the result code to @c E_NOTIMPL.
3924 </note>
3925 </desc>
3926 </attribute>
3927
3928 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
3929 <desc>Associated audio adapter, always present.</desc>
3930 </attribute>
3931
3932 <attribute name="SATAController" type="ISATAController" readonly="yes">
3933 <desc>
3934 Associated SATA controller object.
3935 </desc>
3936 </attribute>
3937
3938 <attribute name="settingsFilePath" type="wstring" readonly="yes">
3939 <desc>
3940 Full name of the file containing machine settings data.
3941 </desc>
3942 </attribute>
3943
3944 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
3945 <desc>
3946 Current version of the format of the settings file of this machine
3947 (<link to="#settingsFilePath"/>).
3948
3949 The version string has the following format:
3950 <pre>
3951 x.y-platform
3952 </pre>
3953 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
3954 versions, and <tt>platform</tt> is the platform identifier.
3955
3956 The current version usually matches the value of the
3957 <link to="IVirtualBox::settingsFormatVersion"/> attribute unless the
3958 settings file was created by an older version of VirtualBox and there
3959 was a change of the settings file format since then.
3960
3961 Note that VirtualBox automatically converts settings files from older
3962 versions to the most recent version when reading them (usually at
3963 VirtualBox startup) but it doesn't save the changes back until
3964 you call a method that implicitly saves settings (such as
3965 <link to="#setExtraData()"/>) or call <link to="#saveSettings()"/>
3966 explicitly. Therefore, if the value of this attribute differs from the
3967 value of <link to="IVirtualBox::settingsFormatVersion"/>, then it
3968 means that the settings file was converted but the result of the
3969 conversion is not yet saved to disk.
3970
3971 The above feature may be used by interactive front-ends to inform users
3972 about the settings file format change and offer them to explicitly save
3973 all converted settings files (the global and VM-specific ones),
3974 optionally create backup copies of the old settings files before saving,
3975 etc.
3976
3977 <see>IVirtualBox::settingsFormatVersion, saveSettingsWithBackup()</see>
3978 </desc>
3979 </attribute>
3980
3981 <attribute name="settingsModified" type="boolean" readonly="yes">
3982 <desc>
3983 Whether the settings of this machine have been modified
3984 (but neither yet saved nor discarded).
3985 <note>
3986 Reading this property is only valid on instances returned
3987 by <link to="ISession::machine"/> and on new machines
3988 created by <link to="IVirtualBox::createMachine"/> or opened
3989 by <link to="IVirtualBox::openMachine"/> but not
3990 yet registered, or on unregistered machines after calling
3991 <link to="IVirtualBox::unregisterMachine"/>. For all other
3992 cases, the settings can never be modified.
3993 </note>
3994 <note>
3995 For newly created unregistered machines, the value of this
3996 property is always TRUE until <link to="#saveSettings()"/>
3997 is called (no matter if any machine settings have been
3998 changed after the creation or not). For opened machines
3999 the value is set to FALSE (and then follows to normal rules).
4000 </note>
4001 </desc>
4002 </attribute>
4003
4004 <attribute name="sessionState" type="SessionState" readonly="yes">
4005 <desc>Current session state for this machine.</desc>
4006 </attribute>
4007
4008 <attribute name="sessionType" type="wstring" readonly="yes">
4009 <desc>
4010 Type of the session. If <link to="#sessionState"/> is
4011 SessionSpawning or SessionOpen, this attribute contains the
4012 same value as passed to the
4013 <link to="IVirtualBox::openRemoteSession()"/> method in the @a
4014 type parameter. If the session was opened directly using
4015 <link to="IVirtualBox::openSession()"/>, or if
4016 <link to="#sessionState"/> is SessionClosed, the value of this
4017 attribute is @c null.
4018 </desc>
4019 </attribute>
4020
4021 <attribute name="sessionPid" type="unsigned long" readonly="yes">
4022 <desc>
4023 Identifier of the session process. This attribute contains the
4024 platform-dependent identifier of the process that has opened a
4025 direct session for this machine using the
4026 <link to="IVirtualBox::openSession()"/> call. The returned value
4027 is only valid if <link to="#sessionState"/> is SessionOpen or
4028 SessionClosing (i.e. a session is currently open or being
4029 closed) by the time this property is read.
4030 </desc>
4031 </attribute>
4032
4033 <attribute name="state" type="MachineState" readonly="yes">
4034 <desc>Current execution state of this machine.</desc>
4035 </attribute>
4036
4037 <attribute name="lastStateChange" type="long long" readonly="yes">
4038 <desc>
4039 Time stamp of the last execution state change,
4040 in milliseconds since 1970-01-01 UTC.
4041 </desc>
4042 </attribute>
4043
4044 <attribute name="stateFilePath" type="wstring" readonly="yes">
4045 <desc>
4046 Full path to the file that stores the execution state of
4047 the machine when it is in the <link to="MachineState_Saved"/> state.
4048 <note>
4049 When the machine is not in the Saved state, this attribute
4050 <tt>null</tt>.
4051 </note>
4052 </desc>
4053 </attribute>
4054
4055 <attribute name="logFolder" type="wstring" readonly="yes">
4056 <desc>
4057 Full path to the folder that stores a set of rotated log files
4058 recorded during machine execution. The most recent log file is
4059 named <tt>VBox.log</tt>, the previous log file is
4060 named <tt>VBox.log.1</tt> and so on (up to <tt>VBox.log.3</tt>
4061 in the current version).
4062 </desc>
4063 </attribute>
4064
4065 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
4066 <desc>
4067 Current snapshot of this machine.
4068 <note>
4069 A <tt>null</tt> object is returned if the machine doesn't
4070 have snapshots.
4071 </note>
4072 <see><link to="ISnapshot"/></see>
4073 </desc>
4074 </attribute>
4075
4076 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
4077 <desc>
4078 Number of snapshots taken on this machine. Zero means the
4079 machine doesn't have any snapshots.
4080 </desc>
4081 </attribute>
4082
4083 <attribute name="currentStateModified" type="boolean" readonly="yes">
4084 <desc>
4085 Returns <tt>true</tt> if the current state of the machine is not
4086 identical to the state stored in the current snapshot.
4087
4088 The current state is identical to the current snapshot right
4089 after one of the following calls are made:
4090 <ul>
4091 <li><link to="IConsole::discardCurrentState"/> or
4092 <link to="IConsole::discardCurrentSnapshotAndState"/>
4093 </li>
4094 <li><link to="IConsole::takeSnapshot"/> (issued on a
4095 powered off or saved machine, for which
4096 <link to="#settingsModified"/> returns <tt>false</tt>)
4097 </li>
4098 <li><link to="IMachine::setCurrentSnapshot"/>
4099 </li>
4100 </ul>
4101
4102 The current state remains identical until one of the following
4103 happens:
4104 <ul>
4105 <li>settings of the machine are changed</li>
4106 <li>the saved state is discarded</li>
4107 <li>the current snapshot is discarded</li>
4108 <li>an attempt to execute the machine is made</li>
4109 </ul>
4110
4111 <note>
4112 For machines that don't have snapshots, this property is
4113 always <tt>false</tt>.
4114 </note>
4115 </desc>
4116 </attribute>
4117
4118 <attribute name="sharedFolders" type="ISharedFolderCollection" readonly="yes">
4119 <desc>
4120 Collection of shared folders for this machine (permanent shared
4121 folders). These folders are shared automatically at machine startup
4122 and available only to the guest OS installed within this machine.
4123
4124 New shared folders are added to the collection using
4125 <link to="#createSharedFolder"/>. Existing shared folders can be
4126 removed using <link to="#removeSharedFolder"/>.
4127 </desc>
4128 </attribute>
4129
4130 <attribute name="clipboardMode" type="ClipboardMode">
4131 <desc>
4132 Synchronization mode between the host OS clipboard
4133 and the guest OS clipboard.
4134 </desc>
4135 </attribute>
4136
4137 <attribute name="guestPropertyNotificationPatterns" type="wstring">
4138 <desc>
4139 A comma-separated list of simple glob patterns. Changes to guest
4140 properties whose name matches one of the patterns will generate an
4141 <link to="IVirtualBoxCallback::onGuestPropertyChange"/> signal.
4142 </desc>
4143 </attribute>
4144
4145 <method name="setBootOrder">
4146 <desc>
4147 Puts the given device to the specified position in
4148 the boot order.
4149
4150 To indicate that no device is associated with the given position,
4151 <link to="DeviceType_Null"/> should be used.
4152
4153 @todo setHardDiskBootOrder(), setNetworkBootOrder()
4154
4155 <result name="E_INVALIDARG">
4156 Boot @a position out of range.
4157 </result>
4158 <result name="E_NOTIMPL">
4159 Booting from USB @a device currently not supported.
4160 </result>
4161
4162 </desc>
4163 <param name="position" type="unsigned long" dir="in">
4164 <desc>
4165 Position in the boot order (<tt>1</tt> to the total number of
4166 devices the machine can boot from, as returned by
4167 <link to="ISystemProperties::maxBootPosition"/>).
4168 </desc>
4169 </param>
4170 <param name="device" type="DeviceType" dir="in">
4171 <desc>
4172 The type of the device used to boot at the given position.
4173 </desc>
4174 </param>
4175 </method>
4176
4177 <method name="getBootOrder" const="yes">
4178 <desc>
4179 Returns the device type that occupies the specified
4180 position in the boot order.
4181
4182 @todo [remove?]
4183 If the machine can have more than one device of the returned type
4184 (such as hard disks), then a separate method should be used to
4185 retrieve the individual device that occupies the given position.
4186
4187 If here are no devices at the given position, then
4188 <link to="DeviceType_Null"/> is returned.
4189
4190 @todo getHardDiskBootOrder(), getNetworkBootOrder()
4191
4192 <result name="E_INVALIDARG">
4193 Boot @a position out of range.
4194 </result>
4195
4196 </desc>
4197 <param name="position" type="unsigned long" dir="in">
4198 <desc>
4199 Position in the boot order (<tt>1</tt> to the total number of
4200 devices the machine can boot from, as returned by
4201 <link to="ISystemProperties::maxBootPosition"/>).
4202 </desc>
4203 </param>
4204 <param name="device" type="DeviceType" dir="return">
4205 <desc>
4206 Device at the given position.
4207 </desc>
4208 </param>
4209 </method>
4210
4211 <method name="attachHardDisk2">
4212 <desc>
4213 Attaches a virtual hard disk identified by the given UUID @a id
4214 to a device slot of the specified bus.
4215
4216 For the IDE bus, the @a channel parameter can be either @c 0 or @c 1, to
4217 specify the primary or secondary IDE controller, respectively. The
4218 SATA bus supports 30 channels, so this parameter can be a number
4219 ranging from @c 0 to @c 29.
4220
4221 For the primary controller of the IDE bus, the @a device number can be
4222 either @c 0 or @c 1, to specify the master or the slave device,
4223 respectively. For the secondary IDE controller, the device number is
4224 always @c 1 because the master device is reserved for the CD-ROM drive.
4225
4226 For the SATA bus, the @a device parameter is currently unused and
4227 must be @c 0.
4228
4229 The specified device slot must not have another disk attached to it, or
4230 this method will fail.
4231
4232 See <link to="IHardDisk2"/> for more detailed information about
4233 attaching hard disks.
4234
4235 <note>
4236 You cannot attach a hard disk to a running machine. Also, you cannot
4237 attach a hard disk to a newly created machine until this machine's
4238 settings are saved to disk using <link to="#saveSettings()"/>.
4239 </note>
4240 <note>
4241 If the hard disk is being attached indirectly, a new differencing hard
4242 disk will implicitly be created for it and attached instead. If the
4243 changes made to the machine settings (including this indirect
4244 attachment) are later cancelled using <link to="#discardSettings()"/>,
4245 this implicitly created differencing hard disk will implicitly
4246 be deleted.
4247 </note>
4248
4249 <result name="E_INVALIDARG">
4250 SATA device, SATA channel, IDE channel or IDE slot out of range.
4251 </result>
4252 <result name="VBOX_E_INVALID_OBJECT_STATE">
4253 Attempt to attach hard disk to an unregistered virtual machine.
4254 </result>
4255 <result name="VBOX_E_INVALID_VM_STATE">
4256 Invalid machine state.
4257 </result>
4258 <result name="VBOX_E_OBJECT_IN_USE">
4259 Hard disk already attached to this or another virtual machine.
4260 </result>
4261
4262 </desc>
4263 <param name="id" type="uuid" dir="in">
4264 <desc>UUID of the hard disk to attach.</desc>
4265 </param>
4266 <param name="bus" type="StorageBus" dir="in">
4267 <desc>Type of the storage bus to use (IDE or SATA).</desc>
4268 </param>
4269 <param name="channel" type="long" dir="in">
4270 <desc>Channel to attach the hard disk to.</desc>
4271 </param>
4272 <param name="device" type="long" dir="in">
4273 <desc>
4274 Device slot in the given channel to attach the hard disk to.
4275 </desc>
4276 </param>
4277 </method>
4278
4279 <method name="getHardDisk2" const="yes">
4280 <desc>
4281 Returns the virtual hard disk attached to a device slot of the specified
4282 bus.
4283
4284 Note that if the hard disk was indirectly attached by
4285 <link to="#attachHardDisk2()"/> to the given device slot then this
4286 method will return not the same object as passed to the
4287 <link to="#attachHardDisk2()"/> call. See <link to="IHardDisk2"/> for
4288 more detailed information about attaching hard disks.
4289
4290 <result name="VBOX_E_OBJECT_NOT_FOUND">
4291 No hard disk attached to given slot/bus.
4292 </result>
4293
4294 </desc>
4295 <param name="bus" type="StorageBus" dir="in">
4296 <desc>Type of the storage bus to query (IDE or SATA).</desc>
4297 </param>
4298 <param name="channel" type="long" dir="in">
4299 <desc>Channel to query.</desc>
4300 </param>
4301 <param name="device" type="long" dir="in">
4302 <desc>Device slot in the given channel to query.</desc>
4303 </param>
4304 <param name="hardDisk" type="IHardDisk2" dir="return">
4305 <desc>Attached hard disk object.</desc>
4306 </param>
4307 </method>
4308
4309 <method name="detachHardDisk2">
4310 <desc>
4311 Detaches the virtual hard disk attached to a device slot of the
4312 specified bus.
4313
4314 Detaching the hard disk from the virtual machine is deferred. This means
4315 that the hard disk remains associated with the machine when this method
4316 returns and gets actually de-associated only after a successful
4317 <link to="#saveSettings()"/> call. See <link to="IHardDisk2"/>
4318 for more detailed information about attaching hard disks.
4319
4320 <note>
4321 You cannot detach the hard disk from a running machine.
4322 </note>
4323 <note>
4324 Detaching differencing hard disks implicitly created by <link
4325 to="#attachHardDisk2()"/> for the indirect attachment using this
4326 method will <b>not</b> implicitly delete them. The
4327 <link to="IHardDisk2::deleteStorage()"/> operation should be
4328 explicitly performed by the caller after the hard disk is successfully
4329 detached and the settings are saved with
4330 <link to="#saveSettings()"/>, if it is the desired action.
4331 </note>
4332
4333 <result name="VBOX_E_INVALID_VM_STATE">
4334 Attempt to detach hard disk from a running virtual machine.
4335 </result>
4336 <result name="VBOX_E_OBJECT_NOT_FOUND">
4337 No hard disk attached to given slot/bus.
4338 </result>
4339 <result name="VBOX_E_NOT_SUPPORTED">
4340 Hard disk format does not support storage deletion.
4341 </result>
4342
4343 </desc>
4344 <param name="bus" type="StorageBus" dir="in">
4345 <desc>Bus to detach the hard disk from.</desc>
4346 </param>
4347 <param name="channel" type="long" dir="in">
4348 <desc>Channel number to detach the hard disk from.</desc>
4349 </param>
4350 <param name="device" type="long" dir="in">
4351 <desc>Device slot number to detach the hard disk from.</desc>
4352 </param>
4353 </method>
4354
4355 <method name="getNetworkAdapter" const="yes">
4356 <desc>
4357 Returns the network adapter associated with the given slot.
4358 Slots are numbered sequentially, starting with zero. The total
4359 number of adapters per machine is defined by the
4360 <link to="ISystemProperties::networkAdapterCount"/> property,
4361 so the maximum slot number is one less than that property's value.
4362
4363 <result name="E_INVALIDARG">
4364 Invalid @a slot number.
4365 </result>
4366
4367 </desc>
4368 <param name="slot" type="unsigned long" dir="in"/>
4369 <param name="adapter" type="INetworkAdapter" dir="return"/>
4370 </method>
4371
4372 <method name="getSerialPort" const="yes">
4373 <desc>
4374 Returns the serial port associated with the given slot.
4375 Slots are numbered sequentially, starting with zero. The total
4376 number of serial ports per machine is defined by the
4377 <link to="ISystemProperties::serialPortCount"/> property,
4378 so the maximum slot number is one less than that property's value.
4379
4380 <result name="E_INVALIDARG">
4381 Invalid @a slot number.
4382 </result>
4383
4384 </desc>
4385 <param name="slot" type="unsigned long" dir="in"/>
4386 <param name="port" type="ISerialPort" dir="return"/>
4387 </method>
4388
4389 <method name="getParallelPort" const="yes">
4390 <desc>
4391 Returns the parallel port associated with the given slot.
4392 Slots are numbered sequentially, starting with zero. The total
4393 number of parallel ports per machine is defined by the
4394 <link to="ISystemProperties::parallelPortCount"/> property,
4395 so the maximum slot number is one less than that property's value.
4396
4397 <result name="E_INVALIDARG">
4398 Invalid @a slot number.
4399 </result>
4400
4401 </desc>
4402 <param name="slot" type="unsigned long" dir="in"/>
4403 <param name="port" type="IParallelPort" dir="return"/>
4404 </method>
4405
4406 <method name="getNextExtraDataKey">
4407 <desc>
4408 Returns the machine-specific extra data key name following the
4409 supplied key.
4410
4411 An error is returned if the supplied @a key does not exist. @c NULL is
4412 returned in @a nextKey if the supplied key is the last key. When
4413 supplying @c NULL for the @a key, the first key item is returned in @a
4414 nextKey (if there is any). @a nextValue is an optional parameter and
4415 if supplied, the next key's value is returned in it.
4416
4417 <result name="VBOX_E_OBJECT_NOT_FOUND">
4418 Extra data @a key not found.
4419 </result>
4420
4421 </desc>
4422 <param name="key" type="wstring" dir="in">
4423 <desc>Name of the data key to follow.</desc>
4424 </param>
4425 <param name="nextKey" type="wstring" dir="out">
4426 <desc>Name of the next data key.</desc>
4427 </param>
4428 <param name="nextValue" type="wstring" dir="out">
4429 <desc>Value of the next data key.</desc>
4430 </param>
4431 </method>
4432
4433 <method name="getExtraData">
4434 <desc>
4435 Returns associated machine-specific extra data.
4436
4437 If the requested data @a key does not exist, this function will
4438 succeed and return @c NULL in the @a value argument.
4439
4440 <result name="VBOX_E_FILE_ERROR">
4441 Settings file not accessible.
4442 </result>
4443 <result name="VBOX_E_XML_ERROR">
4444 Could not parse the settings file.
4445 </result>
4446
4447 </desc>
4448 <param name="key" type="wstring" dir="in">
4449 <desc>Name of the data key to get.</desc>
4450 </param>
4451 <param name="value" type="wstring" dir="return">
4452 <desc>Value of the requested data key.</desc>
4453 </param>
4454 </method>
4455
4456 <method name="setExtraData">
4457 <desc>
4458 Sets associated machine-specific extra data.
4459
4460 If you pass @c NULL as a key @a value, the given @a key will be
4461 deleted.
4462
4463 <note>
4464 Before performing the actual data change, this method will ask all
4465 registered callbacks using the
4466 <link to="IVirtualBoxCallback::onExtraDataCanChange()"/>
4467 notification for a permission. If one of the callbacks refuses the
4468 new value, the change will not be performed.
4469 </note>
4470 <note>
4471 On success, the
4472 <link to="IVirtualBoxCallback::onExtraDataChange()"/> notification
4473 is called to inform all registered callbacks about a successful data
4474 change.
4475 </note>
4476 <note>
4477 This method can be called outside the machine session and therefore
4478 it's a caller's responsibility to handle possible race conditions
4479 when several clients change the same key at the same time.
4480 </note>
4481
4482 <result name="VBOX_E_FILE_ERROR">
4483 Settings file not accessible.
4484 </result>
4485 <result name="VBOX_E_XML_ERROR">
4486 Could not parse the settings file.
4487 </result>
4488
4489 </desc>
4490 <param name="key" type="wstring" dir="in">
4491 <desc>Name of the data key to set.</desc>
4492 </param>
4493 <param name="value" type="wstring" dir="in">
4494 <desc>Value to assign to the key.</desc>
4495 </param>
4496 </method>
4497
4498 <method name="saveSettings">
4499 <desc>
4500 Saves any changes to machine settings made since the session
4501 has been opened or a new machine has been created, or since the
4502 last call to <link to="#saveSettings()"/> or <link to="#discardSettings()"/>.
4503 For registered machines, new settings become visible to all
4504 other VirtualBox clients after successful invocation of this
4505 method.
4506 <note>
4507 The method sends <link to="IVirtualBoxCallback::onMachineDataChange()"/>
4508 notification event after the configuration has been successfully
4509 saved (only for registered machines).
4510 </note>
4511 <note>
4512 Calling this method is only valid on instances returned
4513 by <link to="ISession::machine"/> and on new machines
4514 created by <link to="IVirtualBox::createMachine"/> but not
4515 yet registered, or on unregistered machines after calling
4516 <link to="IVirtualBox::unregisterMachine"/>.
4517 </note>
4518
4519 <result name="VBOX_E_FILE_ERROR">
4520 Settings file not accessible.
4521 </result>
4522 <result name="VBOX_E_XML_ERROR">
4523 Could not parse the settings file.
4524 </result>
4525 <result name="E_ACCESSDENIED">
4526 Modification request refused.
4527 </result>
4528
4529 </desc>
4530 </method>
4531
4532 <method name="saveSettingsWithBackup">
4533 <desc>
4534 Creates a backup copy of the machine settings file (<link
4535 to="#settingsFilePath"/>) in case of auto-conversion, and then calls
4536 <link to="#saveSettings()"/>.
4537
4538 Note that the backup copy is created <b>only</b> if the settings file
4539 auto-conversion took place (see <link to="#settingsFileVersion"/> for
4540 details). Otherwise, this call is fully equivalent to
4541 <link to="#saveSettings()"/> and no backup copying is done.
4542
4543 The backup copy is created in the same directory where the original
4544 settings file is located. It is given the following file name:
4545 <pre>
4546 original.xml.x.y-platform.bak
4547 </pre>
4548 where <tt>original.xml</tt> is the original settings file name
4549 (excluding path), and <tt>x.y-platform</tt> is the version of the old
4550 format of the settings file (before auto-conversion).
4551
4552 If the given backup file already exists, this method will try to add the
4553 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
4554 0 to 9) and copy it again until it succeeds. If all suffixes are
4555 occupied, or if any other copy error occurs, this method will return a
4556 failure.
4557
4558 If the copy operation succeeds, the @a bakFileName return argument will
4559 receive a full path to the created backup file (for informational
4560 purposes). Note that this will happen even if the subsequent
4561 <link to="#saveSettings()"/> call performed by this method after the
4562 copy operation, fails.
4563
4564 <note>
4565 The VirtualBox API never calls this method. It is intended purely for
4566 the purposes of creating backup copies of the settings files by
4567 front-ends before saving the results of the automatically performed
4568 settings conversion to disk.
4569 </note>
4570
4571 <see>settingsFileVersion</see>
4572
4573 <result name="VBOX_E_FILE_ERROR">
4574 Settings file not accessible.
4575 </result>
4576 <result name="VBOX_E_XML_ERROR">
4577 Could not parse the settings file.
4578 </result>
4579 <result name="VBOX_E_INVALID_VM_STATE">
4580 Virtual machine is not mutable.
4581 </result>
4582 <result name="E_ACCESSDENIED">
4583 Modification request refused.
4584 </result>
4585
4586 </desc>
4587 <param name="bakFileName" type="wstring" dir="return">
4588 <desc>Full path to the created backup copy.</desc>
4589 </param>
4590 </method>
4591
4592 <method name="discardSettings">
4593 <desc>
4594 Discards any changes to the machine settings made since the session
4595 has been opened or since the last call to <link to="#saveSettings()"/>
4596 or <link to="#discardSettings"/>.
4597 <note>
4598 Calling this method is only valid on instances returned
4599 by <link to="ISession::machine"/> and on new machines
4600 created by <link to="IVirtualBox::createMachine"/> or
4601 opened by <link to="IVirtualBox::openMachine"/> but not
4602 yet registered, or on unregistered machines after calling
4603 <link to="IVirtualBox::unregisterMachine"/>.
4604 </note>
4605
4606 <result name="VBOX_E_INVALID_VM_STATE">
4607 Virtual machine is not mutable.
4608 </result>
4609
4610 </desc>
4611 </method>
4612
4613 <method name="deleteSettings">
4614 <desc>
4615 Deletes the settings file of this machine from disk.
4616 The machine must not be registered in order for this operation
4617 to succeed.
4618 <note>
4619 <link to="#settingsModified"/> will return TRUE after this
4620 method successfully returns.
4621 </note>
4622 <note>
4623 Calling this method is only valid on instances returned
4624 by <link to="ISession::machine"/> and on new machines
4625 created by <link to="IVirtualBox::createMachine"/> or
4626 opened by <link to="IVirtualBox::openMachine"/> but not
4627 yet registered, or on unregistered machines after calling
4628 <link to="IVirtualBox::unregisterMachine"/>.
4629 </note>
4630 <note>
4631 The deleted machine settings file can be restored (saved again)
4632 by calling <link to="#saveSettings()"/>.
4633 </note>
4634
4635 <result name="VBOX_E_INVALID_VM_STATE">
4636 Cannot delete settings of a registered machine or
4637 machine not mutable.
4638 </result>
4639 <result name="VBOX_E_IPRT_ERROR">
4640 Could not delete the settings file.
4641 </result>
4642
4643 </desc>
4644 </method>
4645
4646 <method name="getSnapshot">
4647 <desc>
4648 Returns a snapshot of this machine with the given UUID.
4649 A <tt>null</tt> UUID can be used to obtain the first snapshot
4650 taken on this machine. This is useful if you want to traverse
4651 the whole tree of snapshots starting from the root.
4652
4653 <result name="VBOX_E_OBJECT_NOT_FOUND">
4654 Virtual machine has no snapshots or snapshot not found.
4655 </result>
4656
4657 </desc>
4658 <param name="id" type="uuid" dir="in">
4659 <desc>UUID of the snapshot to get</desc>
4660 </param>
4661 <param name="snapshot" type="ISnapshot" dir="return">
4662 <desc>Snapshot object with the given UUID.</desc>
4663 </param>
4664 </method>
4665
4666 <method name="findSnapshot">
4667 <desc>
4668 Returns a snapshot of this machine with the given name.
4669
4670 <result name="VBOX_E_OBJECT_NOT_FOUND">
4671 Virtual machine has no snapshots or snapshot not found.
4672 </result>
4673
4674 </desc>
4675 <param name="name" type="wstring" dir="in">
4676 <desc>Name of the snapshot to find</desc>
4677 </param>
4678 <param name="snapshot" type="ISnapshot" dir="return">
4679 <desc>Snapshot object with the given name.</desc>
4680 </param>
4681 </method>
4682
4683 <method name="setCurrentSnapshot">
4684 <desc>
4685 Sets the current snapshot of this machine.
4686 <note>
4687 In the current implementation, this operation is not
4688 implemented.
4689 </note>
4690 </desc>
4691 <param name="id" type="uuid" dir="in">
4692 <desc>UUID of the snapshot to set as the current snapshot.</desc>
4693 </param>
4694 </method>
4695
4696 <method name="createSharedFolder">
4697 <desc>
4698 Creates a new permanent shared folder by associating the given logical
4699 name with the given host path, adds it to the collection of shared
4700 folders and starts sharing it. Refer to the description of
4701 <link to="ISharedFolder"/> to read more about logical names.
4702
4703 <result name="VBOX_E_OBJECT_IN_USE">
4704 Shared folder already exists.
4705 </result>
4706 <result name="VBOX_E_FILE_ERROR">
4707 Shared folder @a hostPath not accessible.
4708 </result>
4709
4710 </desc>
4711 <param name="name" type="wstring" dir="in">
4712 <desc>Unique logical name of the shared folder.</desc>
4713 </param>
4714 <param name="hostPath" type="wstring" dir="in">
4715 <desc>Full path to the shared folder in the host file system.</desc>
4716 </param>
4717 <param name="writable" type="boolean" dir="in">
4718 <desc>Whether the share is writable or readonly</desc>
4719 </param>
4720 </method>
4721
4722 <method name="removeSharedFolder">
4723 <desc>
4724 Removes the permanent shared folder with the given name previously
4725 created by <link to="#createSharedFolder"/> from the collection of
4726 shared folders and stops sharing it.
4727
4728 <result name="VBOX_E_INVALID_VM_STATE">
4729 Virtual machine is not mutable.
4730 </result>
4731 <result name="VBOX_E_OBJECT_NOT_FOUND">
4732 Shared folder @a name does not exist.
4733 </result>
4734
4735 </desc>
4736 <param name="name" type="wstring" dir="in">
4737 <desc>Logical name of the shared folder to remove.</desc>
4738 </param>
4739 </method>
4740
4741 <method name="canShowConsoleWindow">
4742 <desc>
4743 Returns @c true if the VM console process can activate the
4744 console window and bring it to foreground on the desktop of
4745 the host PC.
4746 <note>
4747 This method will fail if a session for this machine is not
4748 currently open.
4749 </note>
4750
4751 <result name="VBOX_E_INVALID_VM_STATE">
4752 Machine session is not open.
4753 </result>
4754
4755 </desc>
4756 <param name="canShow" type="boolean" dir="return">
4757 <desc>
4758 @c true if the console window can be shown and @c
4759 false otherwise.
4760 </desc>
4761 </param>
4762 </method>
4763
4764 <method name="showConsoleWindow">
4765 <desc>
4766 Activates the console window and brings it to foreground on
4767 the desktop of the host PC. Many modern window managers on
4768 many platforms implement some sort of focus stealing
4769 prevention logic, so that it may be impossible to activate
4770 a window without the help of the currently active
4771 application. In this case, this method will return a non-zero
4772 identifier that represents the top-level window of the VM
4773 console process. The caller, if it represents a currently
4774 active process, is responsible to use this identifier (in a
4775 platform-dependent manner) to perform actual window
4776 activation.
4777 <note>
4778 This method will fail if a session for this machine is not
4779 currently open.
4780 </note>
4781
4782 <result name="VBOX_E_INVALID_VM_STATE">
4783 Machine session is not open.
4784 </result>
4785
4786 </desc>
4787 <param name="winId" type="unsigned long long" dir="return">
4788 <desc>
4789 Platform-dependent identifier of the top-level VM console
4790 window, or zero if this method has performed all actions
4791 necessary to implement the <i>show window</i> semantics for
4792 the given platform and/or VirtualBox front-end.
4793 </desc>
4794 </param>
4795 </method>
4796
4797 <method name="getGuestProperty">
4798 <desc>
4799 Reads an entry from the machine's guest property store.
4800
4801 <result name="VBOX_E_INVALID_VM_STATE">
4802 Machine session is not open.
4803 </result>
4804
4805 </desc>
4806 <param name="name" type="wstring" dir="in">
4807 <desc>
4808 The name of the property to read.
4809 </desc>
4810 </param>
4811 <param name="value" type="wstring" dir="out">
4812 <desc>
4813 The value of the property. If the property does not exist then this
4814 will be empty.
4815 </desc>
4816 </param>
4817 <param name="timestamp" type="unsigned long long" dir="out">
4818 <desc>
4819 The time at which the property was last modified, as seen by the
4820 server process.
4821 </desc>
4822 </param>
4823 <param name="flags" type="wstring" dir="out">
4824 <desc>
4825 Additional property parameters, passed as a comma-separated list of
4826 "name=value" type entries.
4827 </desc>
4828 </param>
4829 </method>
4830
4831 <method name="getGuestPropertyValue">
4832 <desc>
4833 Reads a value from the machine's guest property store.
4834
4835 <result name="VBOX_E_INVALID_VM_STATE">
4836 Machine session is not open.
4837 </result>
4838
4839 </desc>
4840 <param name="property" type="wstring" dir="in">
4841 <desc>
4842 The name of the property to read.
4843 </desc>
4844 </param>
4845 <param name="value" type="wstring" dir="return">
4846 <desc>
4847 The value of the property. If the property does not exist then this
4848 will be empty.
4849 </desc>
4850 </param>
4851 </method>
4852
4853 <method name="getGuestPropertyTimestamp">
4854 <desc>
4855 Reads a property timestamp from the machine's guest property store.
4856
4857 <result name="VBOX_E_INVALID_VM_STATE">
4858 Machine session is not open.
4859 </result>
4860
4861 </desc>
4862 <param name="property" type="wstring" dir="in">
4863 <desc>
4864 The name of the property to read.
4865 </desc>
4866 </param>
4867 <param name="value" type="unsigned long long" dir="return">
4868 <desc>
4869 The timestamp. If the property does not exist then this will be
4870 empty.
4871 </desc>
4872 </param>
4873 </method>
4874
4875 <method name="setGuestProperty">
4876 <desc>
4877 Sets, changes or deletes an entry in the machine's guest property
4878 store.
4879
4880 <result name="E_ACCESSDENIED">
4881 Property cannot be changed.
4882 </result>
4883 <result name="E_INVALIDARG">
4884 Invalid @a flags.
4885 </result>
4886 <result name="VBOX_E_INVALID_VM_STATE">
4887 Virtual machine is not mutable or session not open.
4888 </result>
4889 <result name="VBOX_E_INVALID_OBJECT_STATE">
4890 Cannot set transient property when machine not running.
4891 </result>
4892
4893 </desc>
4894 <param name="property" type="wstring" dir="in">
4895 <desc>
4896 The name of the property to set, change or delete.
4897 </desc>
4898 </param>
4899 <param name="value" type="wstring" dir="in">
4900 <desc>
4901 The new value of the property to set, change or delete. If the
4902 property does not yet exist and value is non-empty, it will be
4903 created. If the value is empty, the key will be deleted if it
4904 exists.
4905 </desc>
4906 </param>
4907 <param name="flags" type="wstring" dir="in">
4908 <desc>
4909 Additional property parameters, passed as a comma-separated list of
4910 "name=value" type entries.
4911 </desc>
4912 </param>
4913 </method>
4914
4915 <method name="setGuestPropertyValue">
4916 <desc>
4917 Sets, changes or deletes a value in the machine's guest property
4918 store. The flags field will be left unchanged or created empty for a
4919 new property.
4920
4921 <result name="E_ACCESSDENIED">
4922 Property cannot be changed.
4923 </result>
4924 <result name="VBOX_E_INVALID_VM_STATE">
4925 Virtual machine is not mutable or session not open.
4926 </result>
4927 <result name="VBOX_E_INVALID_OBJECT_STATE">
4928 Cannot set transient property when machine not running.
4929 </result>
4930 </desc>
4931
4932 <param name="property" type="wstring" dir="in">
4933 <desc>
4934 The name of the property to set, change or delete.
4935 </desc>
4936 </param>
4937 <param name="value" type="wstring" dir="in">
4938 <desc>
4939 The new value of the property to set, change or delete. If the
4940 property does not yet exist and value is non-empty, it will be
4941 created. If value is empty, the property will be deleted if it
4942 exists.
4943 </desc>
4944 </param>
4945 </method>
4946
4947 <method name="enumerateGuestProperties">
4948 <desc>
4949 Return a list of the guest properties matching a set of patterns along
4950 with their values, time stamps and flags.
4951 </desc>
4952 <param name="patterns" type="wstring" dir="in">
4953 <desc>
4954 The patterns to match the properties against, separated by '|'
4955 characters. If this is empty or NULL, all properties will match.
4956 </desc>
4957 </param>
4958 <param name="name" type="wstring" dir="out" safearray="yes">
4959 <desc>
4960 The names of the properties returned.
4961 </desc>
4962 </param>
4963 <param name="value" type="wstring" dir="out" safearray="yes">
4964 <desc>
4965 The values of the properties returned. The array entries match the
4966 corresponding entries in the @a name array.
4967 </desc>
4968 </param>
4969 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
4970 <desc>
4971 The time stamps of the properties returned. The array entries match
4972 the corresponding entries in the @a name array.
4973 </desc>
4974 </param>
4975 <param name="flags" type="wstring" dir="out" safearray="yes">
4976 <desc>
4977 The flags of the properties returned. The array entries match the
4978 corresponding entries in the @a name array.
4979 </desc>
4980 </param>
4981 </method>
4982</interface>
4983
4984 <!--
4985 // IConsole
4986 /////////////////////////////////////////////////////////////////////////
4987 -->
4988
4989 <interface
4990 name="IConsoleCallback" extends="$unknown"
4991 uuid="13dfbef3-b74d-487d-bada-2304529aefa6"
4992 wsmap="suppress"
4993 >
4994
4995 <method name="onMousePointerShapeChange">
4996 <desc>
4997 Notification when the guest mouse pointer shape has
4998 changed. The new shape data is given.
4999 </desc>
5000 <param name="visible" type="boolean" dir="in">
5001 <desc>
5002 Flag whether the pointer is visible.
5003 </desc>
5004 </param>
5005 <param name="alpha" type="boolean" dir="in">
5006 <desc>
5007 Flag whether the pointer has an alpha channel.
5008 </desc>
5009 </param>
5010 <param name="xHot" type="unsigned long" dir="in">
5011 <desc>
5012 The pointer hot spot x coordinate.
5013 </desc>
5014 </param>
5015 <param name="yHot" type="unsigned long" dir="in">
5016 <desc>
5017 The pointer hot spot y coordinate.
5018 </desc>
5019 </param>
5020 <param name="width" type="unsigned long" dir="in">
5021 <desc>
5022 Width of the pointer shape in pixels.
5023 </desc>
5024 </param>
5025 <param name="height" type="unsigned long" dir="in">
5026 <desc>
5027 Height of the pointer shape in pixels.
5028 </desc>
5029 </param>
5030 <param name="shape" type="octet" mod="ptr" dir="in">
5031 <desc>
5032 Address of the shape buffer.
5033
5034 The @a shape buffer contains a 1-bpp (bits per pixel) AND mask
5035 followed by a 32-bpp XOR (color) mask.
5036
5037 For pointers without alpha channel the XOR mask pixels are 32
5038 bit values: (lsb)BGR0(msb). For pointers with alpha channel
5039 the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
5040
5041 An AND mask is used for pointers with alpha channel, so if the
5042 callback does not support alpha, the pointer could be
5043 displayed as a normal color pointer.
5044
5045 The AND mask is a 1-bpp bitmap with byte aligned scanlines. The
5046 size of the AND mask therefore is <tt>cbAnd = (width + 7) / 8 *
5047 height</tt>. The padding bits at the end of each scanline are
5048 undefined.
5049
5050 The XOR mask follows the AND mask on the next 4-byte aligned
5051 offset: <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>.
5052 Bytes in the gap between the AND and the XOR mask are undefined.
5053 The XOR mask scanlines have no gap between them and the size of
5054 the XOR mask is: <tt>cXor = width * 4 * height</tt>.
5055
5056 <note>
5057 If @a shape is 0, only the pointer visibility is changed.
5058 </note>
5059 </desc>
5060 </param>
5061 </method>
5062
5063 <method name="onMouseCapabilityChange">
5064 <desc>
5065 Notification when the mouse capabilities reported by the
5066 guest have changed. The new capabilities are passed.
5067 </desc>
5068 <param name="supportsAbsolute" type="boolean" dir="in"/>
5069 <param name="needsHostCursor" type="boolean" dir="in"/>
5070 </method>
5071
5072 <method name="onKeyboardLedsChange">
5073 <desc>
5074 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
5075 to alter the state of the keyboard LEDs.
5076 </desc>
5077 <param name="numLock" type="boolean" dir="in"/>
5078 <param name="capsLock" type="boolean" dir="in"/>
5079 <param name="scrollLock" type="boolean" dir="in"/>
5080 </method>
5081
5082 <method name="onStateChange">
5083 <desc>
5084 Notification when the execution state of the machine has changed.
5085 The new state will be given.
5086 </desc>
5087 <param name="state" type="MachineState" dir="in"/>
5088 </method>
5089
5090 <method name="onAdditionsStateChange">
5091 <desc>
5092 Notification when a Guest Additions property changes.
5093 Interested callees should query IGuest attributes to
5094 find out what has changed.
5095 </desc>
5096 </method>
5097
5098 <method name="onDVDDriveChange">
5099 <desc>
5100 Notification when a property of the
5101 virtual <link to="IMachine::DVDDrive">DVD drive</link> changes.
5102 Interested callees should use IDVDDrive methods to find out what has
5103 changed.
5104 </desc>
5105 </method>
5106
5107 <method name="onFloppyDriveChange">
5108 <desc>
5109 Notification when a property of the
5110 virtual <link to="IMachine::floppyDrive">floppy drive</link> changes.
5111 Interested callees should use IFloppyDrive methods to find out what
5112 has changed.
5113 </desc>
5114 </method>
5115
5116 <method name="onNetworkAdapterChange">
5117 <desc>
5118 Notification when a property of one of the
5119 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
5120 changes. Interested callees should use INetworkAdapter methods and
5121 attributes to find out what has changed.
5122 </desc>
5123 <param name="networkAdapter" type="INetworkAdapter" dir="in">
5124 <desc>Network adapter that is subject to change.</desc>
5125 </param>
5126 </method>
5127
5128 <method name="onSerialPortChange">
5129 <desc>
5130 Notification when a property of one of the
5131 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
5132 Interested callees should use ISerialPort methods and attributes
5133 to find out what has changed.
5134 </desc>
5135 <param name="serialPort" type="ISerialPort" dir="in">
5136 <desc>Serial port that is subject to change.</desc>
5137 </param>
5138 </method>
5139
5140 <method name="onParallelPortChange">
5141 <desc>
5142 Notification when a property of one of the
5143 virtual <link to="IMachine::getParallelPort">parallel ports</link>
5144 changes. Interested callees should use ISerialPort methods and
5145 attributes to find out what has changed.
5146 </desc>
5147 <param name="parallelPort" type="IParallelPort" dir="in">
5148 <desc>Parallel port that is subject to change.</desc>
5149 </param>
5150 </method>
5151
5152 <method name="onVRDPServerChange">
5153 <desc>
5154 Notification when a property of the
5155 <link to="IMachine::VRDPServer">VRDP server</link> changes.
5156 Interested callees should use IVRDPServer methods and attributes to
5157 find out what has changed.
5158 </desc>
5159 </method>
5160
5161 <method name="onUSBControllerChange">
5162 <desc>
5163 Notification when a property of the virtual
5164 <link to="IMachine::USBController">USB controller</link> changes.
5165 Interested callees should use IUSBController methods and attributes to
5166 find out what has changed.
5167 </desc>
5168 </method>
5169
5170 <method name="onUSBDeviceStateChange">
5171 <desc>
5172 Notification when a USB device is attached to or detached from
5173 the virtual USB controller.
5174
5175 This notification is sent as a result of the indirect
5176 request to attach the device because it matches one of the
5177 machine USB filters, or as a result of the direct request
5178 issued by <link to="IConsole::attachUSBDevice"/> or
5179 <link to="IConsole::detachUSBDevice"/>.
5180
5181 This notification is sent in case of both a succeeded and a
5182 failed request completion. When the request succeeds, the @a
5183 error parameter is @c null, and the given device has been
5184 already added to (when @a attached is @c true) or removed from
5185 (when @a attached is @c false) the collection represented by
5186 <link to="IConsole::USBDevices"/>. On failure, the collection
5187 doesn't change and the @a error parameter represents the error
5188 message describing the failure.
5189
5190 </desc>
5191 <param name="device" type="IUSBDevice" dir="in">
5192 <desc>Device that is subject to state change.</desc>
5193 </param>
5194 <param name="attached" type="boolean" dir="in">
5195 <desc>
5196 <tt>true</tt> if the device was attached
5197 and <tt>false</tt> otherwise.
5198 </desc>
5199 </param>
5200 <param name="error" type="IVirtualBoxErrorInfo" dir="in">
5201 <desc>
5202 <tt>null</tt> on success or an error message object on
5203 failure.
5204 </desc>
5205 </param>
5206 </method>
5207
5208 <method name="onSharedFolderChange">
5209 <desc>
5210 Notification when a shared folder is added or removed.
5211 The @a scope argument defines one of three scopes:
5212 <link to="IVirtualBox::sharedFolders">global shared folders</link>
5213 (<link to="Scope_Global">Global</link>),
5214 <link to="IMachine::sharedFolders">permanent shared folders</link> of
5215 the machine (<link to="Scope_Machine">Machine</link>) or <link
5216 to="IConsole::sharedFolders">transient shared folders</link> of the
5217 machine (<link to="Scope_Session">Session</link>). Interested callees
5218 should use query the corresponding collections to find out what has
5219 changed.
5220 </desc>
5221 <param name="scope" type="Scope" dir="in">
5222 <desc>Scope of the notification.</desc>
5223 </param>
5224 </method>
5225
5226 <method name="onRuntimeError">
5227 <desc>
5228 Notification when an error happens during the virtual
5229 machine execution.
5230
5231 There are three kinds of runtime errors:
5232 <ul>
5233 <li><i>fatal</i></li>
5234 <li><i>non-fatal with retry</i></li>
5235 <li><i>non-fatal warnings</i></li>
5236 </ul>
5237
5238 <b>Fatal</b> errors are indicated by the @a fatal parameter set
5239 to <tt>true</tt>. In case of fatal errors, the virtual machine
5240 execution is always paused before calling this notification, and
5241 the notification handler is supposed either to immediately save
5242 the virtual machine state using <link to="IConsole::saveState()"/>
5243 or power it off using <link to="IConsole::powerDown()"/>.
5244 Resuming the execution can lead to unpredictable results.
5245
5246 <b>Non-fatal</b> errors and warnings are indicated by the
5247 @a fatal parameter set to <tt>false</tt>. If the virtual machine
5248 is in the Paused state by the time the error notification is
5249 received, it means that the user can <i>try to resume</i> the machine
5250 execution after attempting to solve the problem that caused the
5251 error. In this case, the notification handler is supposed
5252 to show an appropriate message to the user (depending on the
5253 value of the @a id parameter) that offers several actions such
5254 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
5255 wants to retry, the notification handler should continue
5256 the machine execution using the <link to="IConsole::resume()"/>
5257 call. If the machine execution is not Paused during this
5258 notification, then it means this notification is a <i>warning</i>
5259 (for example, about a fatal condition that can happen very soon);
5260 no immediate action is required from the user, the machine
5261 continues its normal execution.
5262
5263 Note that in either case the notification handler
5264 <b>must not</b> perform any action directly on a thread
5265 where this notification is called. Everything it is allowed to
5266 do is to post a message to another thread that will then talk
5267 to the user and take the corresponding action.
5268
5269 Currently, the following error identifiers are known:
5270 <ul>
5271 <li><tt>"HostMemoryLow"</tt></li>
5272 <li><tt>"HostAudioNotResponding"</tt></li>
5273 <li><tt>"VDIStorageFull"</tt></li>
5274 </ul>
5275
5276 <note>
5277 This notification is not designed to be implemented by
5278 more than one callback at a time. If you have multiple
5279 IConsoleCallback instances registered on the given
5280 IConsole object, make sure you simply do nothing but
5281 return @c S_OK from all but one of them that does actual
5282 user notification and performs necessary actions.
5283 </note>
5284
5285 </desc>
5286 <param name="fatal" type="boolean" dir="in">
5287 <desc>Whether the error is fatal or not</desc>
5288 </param>
5289 <param name="id" type="wstring" dir="in">
5290 <desc>Error identifier</desc>
5291 </param>
5292 <param name="message" type="wstring" dir="in">
5293 <desc>Optional error message</desc>
5294 </param>
5295 </method>
5296
5297 <method name="onCanShowWindow">
5298 <desc>
5299 Notification when a call to
5300 <link to="IMachine::canShowConsoleWindow()"/> is made by a
5301 front-end to check if a subsequent call to
5302 <link to="IMachine::showConsoleWindow()"/> can succeed.
5303
5304 The callee should give an answer appropriate to the current
5305 machine state in the @a canShow argument. This answer must
5306 remain valid at least until the next
5307 <link to="IConsole::state">machine state</link> change.
5308
5309 <note>
5310 This notification is not designed to be implemented by
5311 more than one callback at a time. If you have multiple
5312 IConsoleCallback instances registered on the given
5313 IConsole object, make sure you simply do nothing but
5314 return @c true and @c S_OK from all but one of them that
5315 actually manages console window activation.
5316 </note>
5317 </desc>
5318 <param name="canShow" type="boolean" dir="return">
5319 <desc>
5320 @c true if the console window can be shown and @c
5321 false otherwise.
5322 </desc>
5323 </param>
5324 </method>
5325
5326 <method name="onShowWindow">
5327 <desc>
5328 Notification when a call to
5329 <link to="IMachine::showConsoleWindow()"/>
5330 requests the console window to be activated and brought to
5331 foreground on the desktop of the host PC.
5332
5333 This notification should cause the VM console process to
5334 perform the requested action as described above. If it is
5335 impossible to do it at a time of this notification, this
5336 method should return a failure.
5337
5338 Note that many modern window managers on many platforms
5339 implement some sort of focus stealing prevention logic, so
5340 that it may be impossible to activate a window without the
5341 help of the currently active application (which is supposedly
5342 an initiator of this notification). In this case, this method
5343 must return a non-zero identifier that represents the
5344 top-level window of the VM console process. The caller, if it
5345 represents a currently active process, is responsible to use
5346 this identifier (in a platform-dependent manner) to perform
5347 actual window activation.
5348
5349 This method must set @a winId to zero if it has performed all
5350 actions necessary to complete the request and the console
5351 window is now active and in foreground, to indicate that no
5352 further action is required on the caller's side.
5353
5354 <note>
5355 This notification is not designed to be implemented by
5356 more than one callback at a time. If you have multiple
5357 IConsoleCallback instances registered on the given
5358 IConsole object, make sure you simply do nothing but
5359 return @c S_OK from all but one of them that actually
5360 manages console window activation.
5361 </note>
5362 </desc>
5363 <param name="winId" type="unsigned long long" dir="return">
5364 <desc>
5365 Platform-dependent identifier of the top-level VM console
5366 window, or zero if this method has performed all actions
5367 necessary to implement the <i>show window</i> semantics for
5368 the given platform and/or this VirtualBox front-end.
5369 </desc>
5370 </param>
5371 </method>
5372
5373 </interface>
5374
5375 <interface
5376 name="IRemoteDisplayInfo" extends="$unknown"
5377 uuid="550104cd-2dfd-4a6c-857d-f6f8e088e62c"
5378 wsmap="struct"
5379 >
5380 <desc>
5381 Contains information about the remote display (VRDP) capabilities and status.
5382 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
5383 </desc>
5384
5385 <attribute name="active" type="boolean" readonly="yes">
5386 <desc>
5387 Whether the remote display connection is active.
5388 </desc>
5389 </attribute>
5390
5391 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
5392 <desc>
5393 How many times a client connected.
5394 </desc>
5395 </attribute>
5396
5397 <attribute name="beginTime" type="long long" readonly="yes">
5398 <desc>
5399 When the last connection was established, in milliseconds since 1970-01-01 UTC.
5400 </desc>
5401 </attribute>
5402
5403 <attribute name="endTime" type="long long" readonly="yes">
5404 <desc>
5405 When the last connection was terminated or the current time, if
5406 connection is still active, in milliseconds since 1970-01-01 UTC.
5407 </desc>
5408 </attribute>
5409
5410 <attribute name="bytesSent" type="unsigned long long" readonly="yes">
5411 <desc>
5412 How many bytes were sent in last or current, if still active, connection.
5413 </desc>
5414 </attribute>
5415
5416 <attribute name="bytesSentTotal" type="unsigned long long" readonly="yes">
5417 <desc>
5418 How many bytes were sent in all connections.
5419 </desc>
5420 </attribute>
5421
5422 <attribute name="bytesReceived" type="unsigned long long" readonly="yes">
5423 <desc>
5424 How many bytes were received in last or current, if still active, connection.
5425 </desc>
5426 </attribute>
5427
5428 <attribute name="bytesReceivedTotal" type="unsigned long long" readonly="yes">
5429 <desc>
5430 How many bytes were received in all connections.
5431 </desc>
5432 </attribute>
5433
5434 <attribute name="user" type="wstring" readonly="yes">
5435 <desc>
5436 Login user name supplied by the client.
5437 </desc>
5438 </attribute>
5439
5440 <attribute name="domain" type="wstring" readonly="yes">
5441 <desc>
5442 Login domain name supplied by the client.
5443 </desc>
5444 </attribute>
5445
5446 <attribute name="clientName" type="wstring" readonly="yes">
5447 <desc>
5448 The client name supplied by the client.
5449 </desc>
5450 </attribute>
5451
5452 <attribute name="clientIP" type="wstring" readonly="yes">
5453 <desc>
5454 The IP address of the client.
5455 </desc>
5456 </attribute>
5457
5458 <attribute name="clientVersion" type="unsigned long" readonly="yes">
5459 <desc>
5460 The client software version number.
5461 </desc>
5462 </attribute>
5463
5464 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
5465 <desc>
5466 Public key exchange method used when connection was established.
5467 Values: 0 - RDP4 public key exchange scheme.
5468 1 - X509 certificates were sent to client.
5469 </desc>
5470 </attribute>
5471
5472 </interface>
5473
5474 <interface
5475 name="IConsole" extends="$unknown"
5476 uuid="e3c6d4a1-a935-47ca-b16d-f9e9c496e53e"
5477 wsmap="managed"
5478 >
5479 <desc>
5480 The IConsole interface represents an interface to control virtual
5481 machine execution.
5482
5483 The console object that implements the IConsole interface is obtained
5484 from a session object after the session for the given machine has been
5485 opened using one of <link to="IVirtualBox::openSession"/>,
5486 <link to="IVirtualBox::openRemoteSession"/> or
5487 <link to="IVirtualBox::openExistingSession"/> methods.
5488
5489 Methods of the IConsole interface allow the caller to query the current
5490 virtual machine execution state, pause the machine or power it down, save
5491 the machine state or take a snapshot, attach and detach removable media
5492 and so on.
5493
5494 <see>ISession</see>
5495 </desc>
5496
5497 <attribute name="machine" type="IMachine" readonly="yes">
5498 <desc>
5499 Machine object this console is sessioned with.
5500 <note>
5501 This is a convenience property, it has the same value as
5502 <link to="ISession::machine"/> of the corresponding session
5503 object.
5504 </note>
5505 </desc>
5506 </attribute>
5507
5508 <attribute name="state" type="MachineState" readonly="yes">
5509 <desc>
5510 Current execution state of the machine.
5511 <note>
5512 This property always returns the same value as the corresponding
5513 property of the IMachine object this console is sessioned with.
5514 For the process that owns (executes) the VM, this is the
5515 preferable way of querying the VM state, because no IPC
5516 calls are made.
5517 </note>
5518 </desc>
5519 </attribute>
5520
5521 <attribute name="guest" type="IGuest" readonly="yes">
5522 <desc>Guest object.</desc>
5523 </attribute>
5524
5525 <attribute name="keyboard" type="IKeyboard" readonly="yes">
5526 <desc>
5527 Virtual keyboard object.
5528 <note>
5529 If the machine is not running, any attempt to use
5530 the returned object will result in an error.
5531 </note>
5532 </desc>
5533 </attribute>
5534
5535 <attribute name="mouse" type="IMouse" readonly="yes">
5536 <desc>
5537 Virtual mouse object.
5538 <note>
5539 If the machine is not running, any attempt to use
5540 the returned object will result in an error.
5541 </note>
5542 </desc>
5543 </attribute>
5544
5545 <attribute name="display" type="IDisplay" readonly="yes">
5546 <desc>Virtual display object.
5547 <note>
5548 If the machine is not running, any attempt to use
5549 the returned object will result in an error.
5550 </note>
5551 </desc>
5552 </attribute>
5553
5554 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
5555 <desc>Debugging interface.</desc>
5556 </attribute>
5557
5558 <attribute name="USBDevices" type="IUSBDeviceCollection" readonly="yes">
5559 <desc>
5560 Collection of USB devices currently attached to the virtual
5561 USB controller.
5562 <note>
5563 The collection is empty if the machine is not running.
5564 </note>
5565 </desc>
5566 </attribute>
5567
5568 <attribute name="remoteUSBDevices" type="IHostUSBDeviceCollection" readonly="yes">
5569 <desc>
5570 List of USB devices currently attached to the remote VRDP client.
5571 Once a new device is physically attached to the remote host computer,
5572 it appears in this list and remains there until detached.
5573 </desc>
5574 </attribute>
5575
5576 <attribute name="sharedFolders" type="ISharedFolderCollection" readonly="yes">
5577 <desc>
5578 Collection of shared folders for the current session. These folders
5579 are called transient shared folders because they are available to the
5580 guest OS running inside the associated virtual machine only for the
5581 duration of the session (as opposed to
5582 <link to="IMachine::sharedFolders"/> which represent permanent shared
5583 folders). When the session is closed (e.g. the machine is powered down),
5584 these folders are automatically discarded.
5585
5586 New shared folders are added to the collection using
5587 <link to="#createSharedFolder"/>. Existing shared folders can be
5588 removed using <link to="#removeSharedFolder"/>.
5589 </desc>
5590 </attribute>
5591
5592 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
5593 <desc>
5594 Interface that provides information on Remote Display (VRDP) connection.
5595 </desc>
5596 </attribute>
5597
5598 <method name="powerUp">
5599 <desc>
5600 Starts the virtual machine execution using the current machine
5601 state (that is, its current execution state, current settings and
5602 current hard disks).
5603
5604 If the machine is powered off or aborted, the execution will
5605 start from the beginning (as if the real hardware were just
5606 powered on).
5607
5608 If the machine is in the <link to="MachineState_Saved"/> state,
5609 it will continue its execution the point where the state has
5610 been saved.
5611
5612 <note>
5613 Unless you are trying to write a new VirtualBox front-end that
5614 performs direct machine execution (like the VirtualBox or VBoxSDL
5615 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
5616 session opened by <link to="IVirtualBox::openSession"/> and use this
5617 session only to change virtual machine settings. If you simply want to
5618 start virtual machine execution using one of the existing front-ends
5619 (for example the VirtualBox GUI or headless server), simply use
5620 <link to="IVirtualBox::openRemoteSession"/>; these front-ends will
5621 power up the machine automatically for you.
5622 </note>
5623
5624 <see>#saveState</see>
5625 <result name="VBOX_E_INVALID_VM_STATE">
5626 Virtual machine already running.
5627 </result>
5628 <result name="VBOX_E_HOST_ERROR">
5629 Host interface does not exist or name not set.
5630 </result>
5631 <result name="VBOX_E_FILE_ERROR">
5632 Invalid saved state file.
5633 </result>
5634 </desc>
5635 <param name="progress" type="IProgress" dir="return">
5636 <desc>Progress object to track the operation completion.</desc>
5637 </param>
5638 </method>
5639
5640 <method name="powerUpPaused">
5641 <desc>
5642 Identical to powerUp except that the VM will enter the
5643 <link to="MachineState_Paused"/> state, instead of
5644 <link to="MachineState_Running"/>.
5645
5646 <see>#powerUp</see>
5647 <result name="VBOX_E_INVALID_VM_STATE">
5648 Virtual machine already running.
5649 </result>
5650 <result name="VBOX_E_HOST_ERROR">
5651 Host interface does not exist or name not set.
5652 </result>
5653 <result name="VBOX_E_FILE_ERROR">
5654 Invalid saved state file.
5655 </result>
5656 </desc>
5657 <param name="progress" type="IProgress" dir="return">
5658 <desc>Progress object to track the operation completion.</desc>
5659 </param>
5660 </method>
5661
5662 <method name="powerDown">
5663 <desc>
5664 Stops the virtual machine execution.
5665 After this operation completes, the machine will go to the
5666 PoweredOff state.
5667
5668 @deprecated This method will be removed in VirtualBox 2.1 where the
5669 powerDownAsync() method will take its name. Do not use this method in
5670 the code.
5671 <result name="VBOX_E_INVALID_VM_STATE">
5672 Virtual machine must be Running, Paused or Stuck to be powered down.
5673 </result>
5674 <result name="VBOX_E_VM_ERROR">
5675 Unable to power off or destroy virtual machine.
5676 </result>
5677 </desc>
5678 </method>
5679
5680 <method name="powerDownAsync">
5681 <desc>
5682 Initiates the power down procedure to stop the virtual machine
5683 execution.
5684
5685 The completion of the power down procedure is tracked using the returned
5686 IProgress object. After the operation is complete, the machine will go
5687 to the PoweredOff state.
5688
5689 @warning This method will be renamed to "powerDown" in VirtualBox 2.1
5690 where the original powerDown() method will be removed. You will need to
5691 rename "powerDownAsync" to "powerDown" in your sources to make them
5692 build with version 2.1.
5693 <result name="VBOX_E_INVALID_VM_STATE">
5694 Virtual machine must be Running, Paused or Stuck to be powered down.
5695 </result>
5696 </desc>
5697 <param name="progress" type="IProgress" dir="return">
5698 <desc>Progress object to track the operation completion.</desc>
5699 </param>
5700 </method>
5701
5702 <method name="reset">
5703 <desc>Resets the virtual machine.
5704 <result name="VBOX_E_INVALID_VM_STATE">
5705 Virtual machine not in Running state.
5706 </result>
5707 <result name="VBOX_E_VM_ERROR">
5708 Virtual machine error in reset operation.
5709 </result>
5710 </desc>
5711 </method>
5712
5713 <method name="pause">
5714 <desc>Pauses the virtual machine execution.
5715 <result name="VBOX_E_INVALID_VM_STATE">
5716 Virtual machine not in Running state.
5717 </result>
5718 <result name="VBOX_E_VM_ERROR">
5719 Virtual machine error in suspend operation.
5720 </result>
5721 </desc>
5722 </method>
5723
5724 <method name="resume">
5725 <desc>Resumes the virtual machine execution.
5726 <result name="VBOX_E_INVALID_VM_STATE">
5727 Virtual machine not in Paused state.
5728 </result>
5729 <result name="VBOX_E_VM_ERROR">
5730 Virtual machine error in resume operation.
5731 </result>
5732 </desc>
5733 </method>
5734
5735 <method name="powerButton">
5736 <desc>Sends the ACPI power button event to the guest.
5737 <result name="VBOX_E_INVALID_VM_STATE">
5738 Virtual machine not in Running state.
5739 </result>
5740 <result name="VBOX_E_PDM_ERROR">
5741 Controlled power off failed.
5742 </result>
5743 </desc>
5744 </method>
5745
5746 <method name="sleepButton">
5747 <desc>Sends the ACPI sleep button event to the guest.
5748 <result name="VBOX_E_INVALID_VM_STATE">
5749 Virtual machine not in Running state.
5750 </result>
5751 <result name="VBOX_E_PDM_ERROR">
5752 Sending sleep button event failed.
5753 </result>
5754 </desc>
5755 </method>
5756
5757 <method name="getPowerButtonHandled">
5758 <desc>Checks if the last power button event was handled by guest.
5759 <result name="VBOX_E_PDM_ERROR">
5760 Checking if the event was handled by the guest OS failed.
5761 </result>
5762 </desc>
5763 <param name="handled" type="boolean" dir="return"/>
5764 </method>
5765
5766 <method name="getGuestEnteredACPIMode">
5767 <desc>Checks if the guest entered the ACPI mode G0 (working) or
5768 G1 (sleeping). If this method returns false, the guest will
5769 most likely not respond to external ACPI events.
5770 <result name="VBOX_E_INVALID_VM_STATE">
5771 Virtual machine not in Running state.
5772 </result>
5773 </desc>
5774 <param name="entered" type="boolean" dir="return"/>
5775 </method>
5776
5777 <method name="saveState">
5778 <desc>
5779 Saves the current execution state of a running virtual machine
5780 and stops its execution.
5781
5782 After this operation completes, the machine will go to the
5783 Saved state. Next time it is powered up, this state will
5784 be restored and the machine will continue its execution from
5785 the place where it was saved.
5786
5787 This operation differs from taking a snapshot to the effect
5788 that it doesn't create new differencing hard disks. Also, once
5789 the machine is powered up from the state saved using this method,
5790 the saved state is deleted, so it will be impossible to return
5791 to this state later.
5792
5793 <note>
5794 On success, this method implicitly calls
5795 <link to="IMachine::saveSettings()"/> to save all current machine
5796 settings (including runtime changes to the DVD drive, etc.).
5797 Together with the impossibility to change any VM settings when it is
5798 in the Saved state, this guarantees adequate hardware
5799 configuration of the machine when it is restored from the saved
5800 state file.
5801 </note>
5802
5803 <note>
5804 The machine must be in the Running or Paused state, otherwise
5805 the operation will fail.
5806 </note>
5807 <result name="VBOX_E_INVALID_VM_STATE">
5808 Virtual machine state neither Running nor Paused.
5809 </result>
5810 <result name="VBOX_E_FILE_ERROR">
5811 Failed to create directory for saved state file.
5812 </result>
5813
5814 <see><link to="#takeSnapshot"/></see>
5815 </desc>
5816 <param name="progress" type="IProgress" dir="return">
5817 <desc>Progress object to track the operation completion.</desc>
5818 </param>
5819 </method>
5820
5821 <method name="adoptSavedState">
5822 <desc>
5823 Associates the given saved state file to the virtual machine.
5824
5825 On success, the machine will go to the Saved state. Next time it is
5826 powered up, it will be restored from the adopted saved state and
5827 continue execution from the place where the saved state file was
5828 created.
5829
5830 The specified saved state file path may be absolute or relative to the
5831 folder the VM normally saves the state to (usually,
5832 <link to="IMachine::snapshotFolder"/>).
5833
5834 <note>
5835 It's a caller's responsibility to make sure the given saved state
5836 file is compatible with the settings of this virtual machine that
5837 represent its virtual hardware (memory size, hard disk configuration
5838 etc.). If there is a mismatch, the behavior of the virtual machine
5839 is undefined.
5840 </note>
5841 <result name="VBOX_E_INVALID_VM_STATE">
5842 Virtual machine state neither PoweredOff nor Aborted.
5843 </result>
5844 </desc>
5845 <param name="savedStateFile" type="wstring" dir="in">
5846 <desc>Path to the saved state file to adopt.</desc>
5847 </param>
5848 </method>
5849
5850 <method name="discardSavedState">
5851 <desc>
5852 Discards (deletes) the saved state of the virtual machine
5853 previously created by <link to="#saveState"/>. Next time the
5854 machine is powered up, a clean boot will occur.
5855 <note>
5856 This operation is equivalent to resetting or powering off
5857 the machine without doing a proper shutdown in the guest OS.
5858 </note>
5859 <result name="VBOX_E_INVALID_VM_STATE">
5860 Virtual machine not in state Saved.
5861 </result>
5862 </desc>
5863 </method>
5864
5865 <method name="getDeviceActivity">
5866 <desc>
5867 Gets the current activity type of a given device or device group.
5868 <result name="E_INVALIDARG">
5869 Invalid device type.
5870 </result>
5871 </desc>
5872 <param name="type" type="DeviceType" dir="in"/>
5873 <param name="activity" type="DeviceActivity" dir="return"/>
5874 </method>
5875
5876 <method name="attachUSBDevice">
5877 <desc>
5878 Attaches a host USB device with the given UUID to the
5879 USB controller of the virtual machine.
5880
5881 The device needs to be in one of the following states:
5882 <link to="USBDeviceState_Busy"/>,
5883 <link to="USBDeviceState_Available"/> or
5884 <link to="USBDeviceState_Held"/>,
5885 otherwise an error is immediately returned.
5886
5887 When the device state is
5888 <link to="USBDeviceState_Busy">Busy</link>, an error may also
5889 be returned if the host computer refuses to release it for some reason.
5890
5891 <see>IUSBController::deviceFilters, USBDeviceState</see>
5892 <result name="VBOX_E_INVALID_VM_STATE">
5893 Virtual machine state neither Running nor Paused.
5894 </result>
5895 <result name="VBOX_E_PDM_ERROR">
5896 Virtual machine does not have a USB controller.
5897 </result>
5898 </desc>
5899 <param name="id" type="uuid" dir="in">
5900 <desc>UUID of the host USB device to attach.</desc>
5901 </param>
5902 </method>
5903
5904 <method name="detachUSBDevice">
5905 <desc>
5906 Detaches an USB device with the given UUID from the USB controller
5907 of the virtual machine.
5908
5909 After this method succeeds, the VirtualBox server re-initiates
5910 all USB filters as if the device were just physically attached
5911 to the host, but filters of this machine are ignored to avoid
5912 a possible automatic re-attachment.
5913
5914 <see>IUSBController::deviceFilters, USBDeviceState</see>
5915
5916 <result name="VBOX_E_PDM_ERROR">
5917 Virtual machine does not have a USB controller.
5918 </result>
5919 <result name="E_INVALIDARG">
5920 USB device not attached to this virtual machine.
5921 </result>
5922 </desc>
5923 <param name="id" type="uuid" dir="in">
5924 <desc>UUID of the USB device to detach.</desc>
5925 </param>
5926 <param name="device" type="IUSBDevice" dir="return">
5927 <desc>Detached USB device.</desc>
5928 </param>
5929 </method>
5930
5931 <method name="createSharedFolder">
5932 <desc>
5933 Creates a transient new shared folder by associating the given logical
5934 name with the given host path, adds it to the collection of shared
5935 folders and starts sharing it. Refer to the description of
5936 <link to="ISharedFolder"/> to read more about logical names.
5937
5938 <result name="VBOX_E_INVALID_VM_STATE">
5939 Virtual machine in Saved state or currently changing state.
5940 </result>
5941 <result name="VBOX_E_FILE_ERROR">
5942 Shared folder already exists or not accessible.
5943 </result>
5944 </desc>
5945 <param name="name" type="wstring" dir="in">
5946 <desc>Unique logical name of the shared folder.</desc>
5947 </param>
5948 <param name="hostPath" type="wstring" dir="in">
5949 <desc>Full path to the shared folder in the host file system.</desc>
5950 </param>
5951 <param name="writable" type="boolean" dir="in">
5952 <desc>Whether the share is writable or readonly</desc>
5953 </param>
5954 </method>
5955
5956 <method name="removeSharedFolder">
5957 <desc>
5958 Removes a transient shared folder with the given name previously
5959 created by <link to="#createSharedFolder"/> from the collection of
5960 shared folders and stops sharing it.
5961 <result name="VBOX_E_INVALID_VM_STATE">
5962 Virtual machine in Saved state or currently changing state.
5963 </result>
5964 <result name="VBOX_E_FILE_ERROR">
5965 Shared folder does not exists.
5966 </result>
5967 </desc>
5968 <param name="name" type="wstring" dir="in">
5969 <desc>Logical name of the shared folder to remove.</desc>
5970 </param>
5971 </method>
5972
5973 <method name="takeSnapshot">
5974 <desc>
5975 Saves the current execution state and all settings of the
5976 machine and creates differencing images for all
5977 normal (non-independent) hard disks.
5978
5979 This method can be called for a PoweredOff, Saved, Running or
5980 Paused virtual machine. When the machine is PoweredOff, an
5981 offline <link to="ISnapshot">snapshot</link> is created,
5982 in all other cases -- an online snapshot.
5983
5984 The taken snapshot is always based on the
5985 <link to="IMachine::currentSnapshot">current
5986 snapshot</link> of the associated virtual machine and becomes
5987 a new current snapshot.
5988
5989 <note>
5990 This method implicitly calls <link to="IMachine::saveSettings()"/> to
5991 save all current machine settings before taking an offline snapshot.
5992 </note>
5993
5994 <see>ISnapshot, <link to="#saveState"/></see>
5995 <result name="VBOX_E_INVALID_VM_STATE">
5996 Virtual machine currently changing state.
5997 </result>
5998 </desc>
5999 <param name="name" type="wstring" dir="in">
6000 <desc>Short name for the snapshot.</desc>
6001 </param>
6002 <param name="description" type="wstring" dir="in">
6003 <desc>Optional description of the snapshot.</desc>
6004 </param>
6005 <param name="progress" type="IProgress" dir="return">
6006 <desc>Progress object to track the operation completion.</desc>
6007 </param>
6008 </method>
6009
6010 <method name="discardSnapshot">
6011 <desc>
6012
6013 Starts discarding the specified snapshot. The execution state
6014 and settings of the associated machine stored in the snapshot
6015 will be deleted. The contents of all differencing hard disks of
6016 this snapshot will be merged with the contents of their
6017 dependent child hard disks to keep the, disks valid (in other
6018 words, all changes represented by hard disks being discarded
6019 will be propagated to their child hard disks). After that, this
6020 snapshot's differencing hard disks will be deleted. The parent
6021 of this snapshot will become a new parent for all its child
6022 snapshots.
6023
6024 If the discarded snapshot is the current one, its parent
6025 snapshot will become a new current snapshot. The current machine
6026 state is not directly affected in this case, except that
6027 currently attached differencing hard disks based on hard disks
6028 of the discarded snapshot will be also merged as described
6029 above.
6030
6031 If the discarded snapshot is the first one (the root snapshot)
6032 and it has exactly one child snapshot, this child snapshot will
6033 become the first snapshot after discarding. If there are no
6034 children at all (i.e. the first snapshot is the only snapshot of
6035 the machine), both the current and the first snapshot of the
6036 machine will be set to null. In all other cases, the first
6037 snapshot cannot be discarded.
6038
6039 You cannot discard the snapshot if it
6040 stores <link to="HardDiskType_Normal">normal</link> (non-differencing)
6041 hard disks that have differencing hard disks based on them. Snapshots of
6042 such kind can be discarded only when every normal hard disk has either
6043 no children at all or exactly one child. In the former case, the normal
6044 hard disk simply becomes unused (i.e. not attached to any VM). In the
6045 latter case, it receives all the changes stored in the child hard disk,
6046 and then it replaces the child hard disk in the configuration of the
6047 corresponding snapshot or machine.
6048
6049 Also, you cannot discard the snapshot if it stores hard disks
6050 (of any type) having differencing child hard disks that belong
6051 to other machines. Such snapshots can be only discarded after
6052 you discard all snapshots of other machines containing "foreign"
6053 child disks, or detach these "foreign" child disks from machines
6054 they are attached to.
6055
6056 One particular example of the snapshot storing normal hard disks
6057 is the first snapshot of a virtual machine that had normal hard
6058 disks attached when taking the snapshot. Be careful when
6059 discarding such snapshots because this implicitly commits
6060 changes (made since the snapshot being discarded has been taken)
6061 to normal hard disks (as described above), which may be not what
6062 you want.
6063
6064 The virtual machine is put to
6065 the <link to="MachineState_Discarding">Discarding</link> state until
6066 the discard operation is completed.
6067
6068 <note>
6069 The machine must not be running, otherwise the operation
6070 will fail.
6071 </note>
6072
6073 <note>
6074 Child hard disks of all normal hard disks of the discarded snapshot
6075 must be accessible (see <link to="IMedium::state"/>) for this
6076 operation to succeed. In particular, this means that all virtual
6077 machines, whose hard disks are directly or indirectly based on the
6078 hard disks of discarded snapshot, must be powered off.
6079 </note>
6080 <note>
6081 Merging hard disk contents can be very time and disk space
6082 consuming, if these disks are big in size and have many
6083 children. However, if the snapshot being discarded is the last
6084 (head) snapshot on the branch, the operation will be rather
6085 quick.
6086 </note>
6087 <note>
6088 Note that discarding the current snapshot
6089 will implicitly call <link to="IMachine::saveSettings()"/> to
6090 make all current machine settings permanent.
6091 </note>
6092 <result name="VBOX_E_INVALID_VM_STATE">
6093 Virtual machine is running.
6094 </result>
6095 </desc>
6096 <param name="id" type="uuid" dir="in">
6097 <desc>UUID of the snapshot to discard.</desc>
6098 </param>
6099 <param name="progress" type="IProgress" dir="return">
6100 <desc>Progress object to track the operation completion.</desc>
6101 </param>
6102 </method>
6103
6104 <method name="discardCurrentState">
6105 <desc>
6106 This operation is similar to <link to="#discardSnapshot()"/> but
6107 affects the current machine state. This means that the state stored in
6108 the current snapshot will become a new current state, and all current
6109 settings of the machine and changes stored in differencing hard disks
6110 will be lost.
6111
6112 After this operation is successfully completed, new empty differencing
6113 hard disks are created for all normal hard disks of the machine.
6114
6115 If the current snapshot of the machine is an online snapshot, the
6116 machine will go to the <link to="MachineState_Saved"> saved
6117 state</link>, so that the next time it is powered on, the execution
6118 state will be restored from the current snapshot.
6119
6120 <note>
6121 The machine must not be running, otherwise the operation will fail.
6122 </note>
6123
6124 <note>
6125 If the machine state is <link to="MachineState_Saved">Saved</link>
6126 prior to this operation, the saved state file will be implicitly
6127 discarded (as if <link to="IConsole::discardSavedState()"/> were
6128 called).
6129 </note>
6130
6131 <result name="VBOX_E_INVALID_VM_STATE">
6132 Virtual machine is running.
6133 </result>
6134 </desc>
6135 <param name="progress" type="IProgress" dir="return">
6136 <desc>Progress object to track the operation completion.</desc>
6137 </param>
6138 </method>
6139
6140 <method name="discardCurrentSnapshotAndState">
6141 <desc>
6142
6143 This method is equivalent to
6144 doing <link to="IConsole::discardSnapshot">discardSnapshot</link>
6145 (currentSnapshot.id(), progress) followed by
6146 <link to="#discardCurrentState()"/>.
6147
6148 As a result, the machine will be fully restored from the
6149 snapshot preceding the current snapshot, while both the current
6150 snapshot and the current machine state will be discarded.
6151
6152 If the current snapshot is the first snapshot of the machine (i.e. it
6153 has the only snapshot), the current machine state will be
6154 discarded <b>before</b> discarding the snapshot. In other words, the
6155 machine will be restored from its last snapshot, before discarding
6156 it. This differs from performing a single
6157 <link to="#discardSnapshot()"/> call (note that no
6158 <link to="#discardCurrentState()"/> will be possible after it)
6159 to the effect that the latter will preserve the current state instead of
6160 discarding it.
6161
6162 Unless explicitly mentioned otherwise, all remarks and
6163 limitations of the above two methods also apply to this method.
6164
6165 <note>
6166 The machine must not be running, otherwise the operation
6167 will fail.
6168 </note>
6169
6170 <note>
6171 If the machine state is <link to="MachineState_Saved">Saved</link>
6172 prior to this operation, the saved state file will be implicitly
6173 discarded (as if <link to="#discardSavedState()"/> were
6174 called).
6175 </note>
6176
6177 <note>
6178 This method is more efficient than calling both of the above
6179 methods separately: it requires less IPC calls and provides
6180 a single progress object.
6181 </note>
6182
6183 <result name="VBOX_E_INVALID_VM_STATE">
6184 Virtual machine is running.
6185 </result>
6186 </desc>
6187 <param name="progress" type="IProgress" dir="return">
6188 <desc>Progress object to track the operation completion.</desc>
6189 </param>
6190 </method>
6191
6192 <method name="registerCallback">
6193 <desc>
6194 Registers a new console callback on this instance. The methods of the
6195 callback interface will be called by this instance when the appropriate
6196 event occurs.
6197 </desc>
6198 <param name="callback" type="IConsoleCallback" dir="in"/>
6199 </method>
6200
6201 <method name="unregisterCallback">
6202 <desc>
6203 Unregisters the console callback previously registered using
6204 <link to="#registerCallback"/>.
6205 <result name="E_INVALIDARG">
6206 Given @a callback handler is not registered.
6207 </result>
6208 </desc>
6209 <param name="callback" type="IConsoleCallback" dir="in"/>
6210 </method>
6211 </interface>
6212
6213 <!--
6214 // IHost
6215 /////////////////////////////////////////////////////////////////////////
6216 -->
6217
6218 <interface
6219 name="IHostDVDDrive" extends="$unknown"
6220 uuid="21f86694-202d-4ce4-8b05-a63ff82dbf4c"
6221 wsmap="managed"
6222 >
6223 <desc>
6224 The IHostDVDDrive interface represents the physical CD/DVD drive
6225 hardware on the host. Used indirectly in <link to="IHost::DVDDrives"/>.
6226 </desc>
6227
6228 <attribute name="name" type="wstring" readonly="yes">
6229 <desc>
6230 Returns the platform-specific device identifier.
6231 On DOS-like platforms, it is a drive name (e.g. R:).
6232 On Unix-like platforms, it is a device name (e.g. /dev/hdc).
6233 </desc>
6234 </attribute>
6235 <attribute name="description" type="wstring" readonly="yes">
6236 <desc>
6237 Returns a human readable description for the drive. This
6238 description usually contains the product and vendor name. A
6239 @c null string is returned if the description is not available.
6240 </desc>
6241 </attribute>
6242 <attribute name="udi" type="wstring" readonly="yes">
6243 <desc>
6244 Returns the unique device identifier for the drive. This
6245 attribute is reserved for future use instead of
6246 <link to="#name"/>. Currently it is not used and may return
6247 @c null on some platforms.
6248 </desc>
6249 </attribute>
6250
6251 </interface>
6252
6253 <enumerator
6254 name="IHostDVDDriveEnumerator" type="IHostDVDDrive"
6255 uuid="1ed7cfaf-c363-40df-aa4e-89c1afb7d96b"
6256 />
6257
6258 <collection
6259 name="IHostDVDDriveCollection" type="IHostDVDDrive"
6260 enumerator="IHostDVDDriveEnumerator"
6261 uuid="1909c533-1a1e-445f-a4e1-a267cffc30ed"
6262 readonly="yes"
6263 >
6264 <method name="findByName">
6265 <desc>
6266 Searches this collection for a host drive with the given name.
6267 <note>
6268 The method returns an error if the given name does not
6269 correspond to any host drive in the collection.
6270 </note>
6271 </desc>
6272 <param name="name" type="wstring" dir="in">
6273 <desc>Name of the host drive to search for</desc>
6274 </param>
6275 <param name="drive" type="IHostDVDDrive" dir="return">
6276 <desc>Found host drive object</desc>
6277 </param>
6278 </method>
6279 </collection>
6280
6281 <interface
6282 name="IHostFloppyDrive" extends="$unknown"
6283 uuid="b6a4d1a9-4221-43c3-bd52-021a5daa9ed2"
6284 wsmap="managed"
6285 >
6286 <desc>
6287 The IHostFloppyDrive interface represents the physical floppy drive
6288 hardware on the host. Used indirectly in <link to="IHost::floppyDrives"/>.
6289 </desc>
6290 <attribute name="name" type="wstring" readonly="yes">
6291 <desc>
6292 Returns the platform-specific device identifier.
6293 On DOS-like platforms, it is a drive name (e.g. A:).
6294 On Unix-like platforms, it is a device name (e.g. /dev/fd0).
6295 </desc>
6296 </attribute>
6297 <attribute name="description" type="wstring" readonly="yes">
6298 <desc>
6299 Returns a human readable description for the drive. This
6300 description usually contains the product and vendor name. A
6301 @c null string is returned if the description is not available.
6302 </desc>
6303 </attribute>
6304 <attribute name="udi" type="wstring" readonly="yes">
6305 <desc>
6306 Returns the unique device identifier for the drive. This
6307 attribute is reserved for future use instead of
6308 <link to="#name"/>. Currently it is not used and may return
6309 @c null on some platforms.
6310 </desc>
6311 </attribute>
6312 </interface>
6313
6314 <enumerator
6315 name="IHostFloppyDriveEnumerator" type="IHostFloppyDrive"
6316 uuid="ce04c924-4f54-432a-9dec-11fddc3ea875"
6317 />
6318
6319 <collection
6320 name="IHostFloppyDriveCollection" type="IHostFloppyDrive"
6321 enumerator="IHostFloppyDriveEnumerator"
6322 uuid="fd84bb86-c59a-4037-a557-755ff263a460"
6323 readonly="yes"
6324 >
6325 <method name="findByName">
6326 <desc>
6327 Searches this collection for a host drive with the given name.
6328 <note>
6329 The method returns an error if the given name does not
6330 correspond to any host drive in the collection.
6331 </note>
6332 </desc>
6333 <param name="name" type="wstring" dir="in">
6334 <desc>Name of the host drive to search for</desc>
6335 </param>
6336 <param name="drive" type="IHostFloppyDrive" dir="return">
6337 <desc>Found host drive object</desc>
6338 </param>
6339 </method>
6340 </collection>
6341
6342 <enum
6343 name="HostNetworkInterfaceType"
6344 uuid="763754FA-3246-4539-9590-9E603EDBF706"
6345 >
6346 <desc>
6347 Type of encapsulation. Ethernet encapsulation includes both wired and
6348 wireless Ethernet connections.
6349 <see>IHostNetworkInterface</see>
6350 </desc>
6351
6352 <const name="Unknown" value="0">
6353 <desc>
6354 The type of interface cannot be determined.
6355 </desc>
6356 </const>
6357 <const name="Ethernet" value="1">
6358 <desc>
6359 Ethernet frame encapsulation.
6360 </desc>
6361 </const>
6362 <const name="PPP" value="2">
6363 <desc>
6364 Point-to-point protocol encapsulation.
6365 </desc>
6366 </const>
6367 <const name="SLIP" value="3">
6368 <desc>
6369 Serial line IP encapsulation.
6370 </desc>
6371 </const>
6372 </enum>
6373
6374 <enum
6375 name="HostNetworkInterfaceStatus"
6376 uuid="CC474A69-2710-434B-8D99-C38E5D5A6F41"
6377 >
6378 <desc>
6379 Current status of the interface.
6380 <see>IHostNetworkInterface</see>
6381 </desc>
6382
6383 <const name="Unknown" value="0">
6384 <desc>
6385 The state of interface cannot be determined.
6386 </desc>
6387 </const>
6388 <const name="Up" value="1">
6389 <desc>
6390 The interface is fully operational.
6391 </desc>
6392 </const>
6393 <const name="Down" value="2">
6394 <desc>
6395 The interface is not functioning.
6396 </desc>
6397 </const>
6398 </enum>
6399
6400 <interface
6401 name="IHostNetworkInterface" extends="$unknown"
6402 uuid="832720ac-2df6-41d4-a867-a0b40df14c7f"
6403 wsmap="managed"
6404 >
6405 <desc>
6406 Reprents one of host's network interfaces. IP V6 address and network
6407 mask are strings of 32 hexdecimal digits grouped by four. Groups are
6408 separated by colons.
6409 For example, fe80:0000:0000:0000:021e:c2ff:fed2:b030.
6410 </desc>
6411 <attribute name="name" type="wstring" readonly="yes">
6412 <desc>Returns the host network interface name.</desc>
6413 </attribute>
6414
6415 <attribute name="id" type="uuid" readonly="yes">
6416 <desc>Returns the interface UUID.</desc>
6417 </attribute>
6418
6419 <attribute name="IPAddress" type="unsigned long" readonly="yes">
6420 <desc>Returns the IP V4 address of the interface.</desc>
6421 </attribute>
6422
6423 <attribute name="networkMask" type="unsigned long" readonly="yes">
6424 <desc>Returns the network mask of the interface.</desc>
6425 </attribute>
6426
6427 <attribute name="IPV6Address" type="wstring" readonly="yes">
6428 <desc>Returns the IP V6 address of the interface.</desc>
6429 </attribute>
6430
6431 <attribute name="IPV6NetworkMask" type="wstring" readonly="yes">
6432 <desc>Returns the IP V6 network mask of the interface.</desc>
6433 </attribute>
6434
6435 <attribute name="hardwareAddress" type="wstring" readonly="yes">
6436 <desc>Returns the hardware address. For Ethernet it is MAC address.</desc>
6437 </attribute>
6438
6439 <attribute name="type" type="HostNetworkInterfaceType" readonly="yes">
6440 <desc>Type of protocol encapsulation used.</desc>
6441 </attribute>
6442
6443 <attribute name="status" type="HostNetworkInterfaceStatus" readonly="yes">
6444 <desc>Status of the interface.</desc>
6445 </attribute>
6446 </interface>
6447
6448 <interface
6449 name="IHost" extends="$unknown"
6450 uuid="7c172c42-b209-4bdc-9ddf-a84f222bd59a"
6451 wsmap="managed"
6452 >
6453 <desc>
6454 The IHost interface represents the physical machine that this VirtualBox
6455 installation runs on.
6456
6457 An object implementing this interface is returned by the
6458 <link to="IVirtualBox::host" /> attribute. This interface contains
6459 read-only information about the host's physical hardware (such as what
6460 processors and disks are available, what the host operating system is,
6461 and so on) and also allows for manipulating some of the host's hardware,
6462 such as global USB device filters and host interface networking.
6463
6464 </desc>
6465 <attribute name="DVDDrives" type="IHostDVDDriveCollection" readonly="yes">
6466 <desc>List of DVD drives available on the host.</desc>
6467 </attribute>
6468
6469 <attribute name="floppyDrives" type="IHostFloppyDriveCollection" readonly="yes">
6470 <desc>List of floppy drives available on the host.</desc>
6471 </attribute>
6472
6473 <attribute name="USBDevices" type="IHostUSBDeviceCollection" readonly="yes">
6474 <desc>
6475 List of USB devices currently attached to the host.
6476 Once a new device is physically attached to the host computer,
6477 it appears in this list and remains there until detached.
6478
6479 <note>
6480 This method may set a @ref com_warnings "warning result code".
6481 </note>
6482 <note>
6483 If USB functionality is not available in the given edition of
6484 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6485 </note>
6486 </desc>
6487 </attribute>
6488
6489 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilterCollection" readonly="yes">
6490 <desc>
6491 List of USB device filters in action.
6492 When a new device is physically attached to the host computer,
6493 filters from this list are applied to it (in order they are stored
6494 in the list). The first matched filter will determine the
6495 <link to="IHostUSBDeviceFilter::action">action</link>
6496 performed on the device.
6497
6498 Unless the device is ignored by these filters, filters of all
6499 currently running virtual machines
6500 (<link to="IUSBController::deviceFilters"/>) are applied to it.
6501
6502 <note>
6503 This method may set a @ref com_warnings "warning result code".
6504 </note>
6505 <note>
6506 If USB functionality is not available in the given edition of
6507 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6508 </note>
6509
6510 <see>IHostUSBDeviceFilter, USBDeviceState</see>
6511 </desc>
6512 </attribute>
6513
6514 <attribute name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" readonly="yes">
6515 <desc>List of host network interfaces currently defined on the host.</desc>
6516 </attribute>
6517
6518 <attribute name="processorCount" type="unsigned long" readonly="yes">
6519 <desc>Number of (logical) CPUs installed in the host system.</desc>
6520 </attribute>
6521
6522 <attribute name="processorOnlineCount" type="unsigned long" readonly="yes">
6523 <desc>Number of (logical) CPUs online in the host system.</desc>
6524 </attribute>
6525
6526 <method name="getProcessorSpeed">
6527 <desc>Query the (approximate) maximum speed of a specified host CPU in
6528 Megahertz.
6529 </desc>
6530 <param name="cpuId" type="unsigned long" dir="in">
6531 <desc>
6532 Identifier of the CPU.
6533 </desc>
6534 </param>
6535 <param name="speed" type="unsigned long" dir="return">
6536 <desc>
6537 Speed value. 0 is returned if value is not known or @a cpuId is
6538 invalid.
6539 </desc>
6540 </param>
6541 </method>
6542
6543 <method name="getProcessorFeature">
6544 <desc>Query whether a CPU feature is supported or not.</desc>
6545 <param name="feature" type="ProcessorFeature" dir="in">
6546 <desc>
6547 CPU Feature identifier.
6548 </desc>
6549 </param>
6550 <param name="supported" type="boolean" dir="return">
6551 <desc>
6552 Feature is supported or not.
6553 </desc>
6554 </param>
6555 </method>
6556
6557 <method name="getProcessorDescription">
6558 <desc>Query the model string of a specified host CPU.
6559 <note>
6560 This function is not implemented in the current version of the
6561 product.
6562 </note>
6563 </desc>
6564 <param name="cpuId" type="unsigned long" dir="in">
6565 <desc>
6566 Identifier of the CPU.
6567 </desc>
6568 </param>
6569 <param name="description" type="wstring" dir="return">
6570 <desc>
6571 Model string. A NULL string is returned if value is not known or
6572 @a cpuId is invalid.
6573 </desc>
6574 </param>
6575 </method>
6576
6577 <attribute name="memorySize" type="unsigned long" readonly="yes">
6578 <desc>Amount of system memory in megabytes installed in the host system.</desc>
6579 </attribute>
6580
6581 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
6582 <desc>Available system memory in the host system.</desc>
6583 </attribute>
6584
6585 <attribute name="operatingSystem" type="wstring" readonly="yes">
6586 <desc>Name of the host system's operating system.</desc>
6587 </attribute>
6588
6589 <attribute name="OSVersion" type="wstring" readonly="yes">
6590 <desc>Host operating system's version string.</desc>
6591 </attribute>
6592
6593 <attribute name="UTCTime" type="long long" readonly="yes">
6594 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
6595 </attribute>
6596
6597<if target="midl">
6598 <method name="createHostNetworkInterface">
6599 <desc>
6600 Creates a new adapter for Host Interface Networking.
6601 <result name="E_INVALIDARG">
6602 Host network interface @a name already exists.
6603 </result>
6604 </desc>
6605 <param name="name" type="wstring" dir="in">
6606 <desc>
6607 Adapter name.
6608 </desc>
6609 </param>
6610 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
6611 <desc>
6612 Created host interface object.
6613 </desc>
6614 </param>
6615 <param name="progress" type="IProgress" dir="return">
6616 <desc>
6617 Progress object to track the operation completion.
6618 </desc>
6619 </param>
6620 </method>
6621 <method name="removeHostNetworkInterface">
6622 <desc>
6623 Removes the given host network interface.
6624 <result name="VBOX_E_OBJECT_NOT_FOUND">
6625 No host network interface matching @a id found.
6626 </result>
6627 </desc>
6628 <param name="id" type="uuid" dir="in">
6629 <desc>
6630 Adapter GUID.
6631 </desc>
6632 </param>
6633 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
6634 <desc>
6635 Removed host interface object.
6636 </desc>
6637 </param>
6638 <param name="progress" type="IProgress" dir="return">
6639 <desc>
6640 Progress object to track the operation completion.
6641 </desc>
6642 </param>
6643 </method>
6644</if>
6645
6646 <method name="createUSBDeviceFilter">
6647 <desc>
6648 Creates a new USB device filter. All attributes except
6649 the filter name are set to <tt>null</tt> (any match),
6650 <i>active</i> is <tt>false</tt> (the filter is not active).
6651
6652 The created filter can be added to the list of filters using
6653 <link to="#insertUSBDeviceFilter()"/>.
6654
6655 <see>#USBDeviceFilters</see>
6656 </desc>
6657 <param name="name" type="wstring" dir="in">
6658 <desc>
6659 Filter name. See <link to="IHostUSBDeviceFilter::name"/>
6660 for more info.
6661 </desc>
6662 </param>
6663 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
6664 <desc>Created filter object.</desc>
6665 </param>
6666 </method>
6667
6668 <method name="insertUSBDeviceFilter">
6669 <desc>
6670 Inserts the given USB device to the specified position
6671 in the list of filters.
6672
6673 Positions are numbered starting from <tt>0</tt>. If the specified
6674 position is equal to or greater than the number of elements in
6675 the list, the filter is added at the end of the collection.
6676
6677 <note>
6678 Duplicates are not allowed, so an attempt to insert a
6679 filter that is already in the list, will return an
6680 error.
6681 </note>
6682 <note>
6683 This method may set a @ref com_warnings "warning result code".
6684 </note>
6685 <note>
6686 If USB functionality is not available in the given edition of
6687 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6688 </note>
6689
6690 <see>#USBDeviceFilters</see>
6691
6692 <result name="VBOX_E_INVALID_OBJECT_STATE">
6693 USB device filter is not created within this VirtualBox instance.
6694 </result>
6695 <result name="E_INVALIDARG">
6696 USB device filter already in list.
6697 </result>
6698
6699 </desc>
6700 <param name="position" type="unsigned long" dir="in">
6701 <desc>Position to insert the filter to.</desc>
6702 </param>
6703 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
6704 <desc>USB device filter to insert.</desc>
6705 </param>
6706 </method>
6707
6708 <method name="removeUSBDeviceFilter">
6709 <desc>
6710 Removes a USB device filter from the specified position in the
6711 list of filters.
6712
6713 Positions are numbered starting from <tt>0</tt>. Specifying a
6714 position equal to or greater than the number of elements in
6715 the list will produce an error.
6716
6717 <note>
6718 This method may set a @ref com_warnings "warning result code".
6719 </note>
6720 <note>
6721 If USB functionality is not available in the given edition of
6722 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6723 </note>
6724
6725 <see>#USBDeviceFilters</see>
6726
6727 <result name="E_INVALIDARG">
6728 USB device filter list empty or invalid @a position.
6729 </result>
6730
6731 </desc>
6732 <param name="position" type="unsigned long" dir="in">
6733 <desc>Position to remove the filter from.</desc>
6734 </param>
6735 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
6736 <desc>Removed USB device filter.</desc>
6737 </param>
6738 </method>
6739
6740 <method name="findHostNetworkInterfaceByName">
6741 <desc>
6742 Searches through all host network interfaces for an interface with
6743 the given name.
6744 <note>
6745 The method returns an error if the given name does not
6746 correspond to any host network interface.
6747 </note>
6748 </desc>
6749 <param name="name" type="wstring" dir="in">
6750 <desc>Name of the host network interface to search for.</desc>
6751 </param>
6752 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
6753 <desc>Found host network interface object.</desc>
6754 </param>
6755 </method>
6756 <method name="findHostNetworkInterfaceById">
6757 <desc>
6758 Searches through all host network interfaces for an interface with
6759 the given GUID.
6760 <note>
6761 The method returns an error if the given GUID does not
6762 correspond to any host network interface.
6763 </note>
6764 </desc>
6765 <param name="id" type="uuid" dir="in">
6766 <desc>GUID of the host network interface to search for.</desc>
6767 </param>
6768 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
6769 <desc>Found host network interface object.</desc>
6770 </param>
6771 </method>
6772 </interface>
6773
6774 <!--
6775 // ISystemProperties
6776 /////////////////////////////////////////////////////////////////////////
6777 -->
6778
6779 <interface
6780 name="ISystemProperties"
6781 extends="$unknown"
6782 uuid="0760e03f-06d0-481e-9f81-be43fef092ba"
6783 wsmap="managed"
6784 >
6785 <desc>
6786 The ISystemProperties interface represents global properties of the given
6787 VirtualBox installation.
6788
6789 These properties define limits and default values for various attributes
6790 and parameters. Most of the properties are read-only, but some can be
6791 changed by a user.
6792 </desc>
6793
6794 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
6795 <desc>Minimum guest system memory in Megabytes.</desc>
6796 </attribute>
6797
6798 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
6799 <desc>Maximum guest system memory in Megabytes.</desc>
6800 </attribute>
6801
6802 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
6803 <desc>Minimum guest video memory in Megabytes.</desc>
6804 </attribute>
6805
6806 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
6807 <desc>Maximum guest video memory in Megabytes.</desc>
6808 </attribute>
6809
6810 <attribute name="minGuestCPUCount" type="unsigned long" readonly="yes">
6811 <desc>Minimum CPU count.</desc>
6812 </attribute>
6813
6814 <attribute name="maxGuestCPUCount" type="unsigned long" readonly="yes">
6815 <desc>Maximum CPU count.</desc>
6816 </attribute>
6817
6818 <attribute name="maxVDISize" type="unsigned long long" readonly="yes">
6819 <desc>Maximum size of a virtual disk image in Megabytes.</desc>
6820 </attribute>
6821
6822 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
6823 <desc>
6824 Number of network adapters associated with every
6825 <link to="IMachine"/> instance.
6826 </desc>
6827 </attribute>
6828
6829 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
6830 <desc>
6831 Number of serial ports associated with every
6832 <link to="IMachine"/> instance.
6833 </desc>
6834 </attribute>
6835
6836 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
6837 <desc>
6838 Number of parallel ports associated with every
6839 <link to="IMachine"/> instance.
6840 </desc>
6841 </attribute>
6842
6843 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
6844 <desc>
6845 Maximum device position in the boot order. This value corresponds
6846 to the total number of devices a machine can boot from, to make it
6847 possible to include all possible devices to the boot list.
6848 <see><link to="IMachine::setBootOrder()"/></see>
6849 </desc>
6850 </attribute>
6851
6852 <attribute name="defaultMachineFolder" type="wstring">
6853 <desc>
6854 Full path to the default directory used to create new or open
6855 existing machines when a settings file name contains no
6856 path.
6857
6858 The initial value of this property is
6859 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
6860 VirtualBox_home</link><tt>&gt;/Machines</tt>.
6861
6862 <note>
6863 Setting this property to <tt>null</tt> will restore the
6864 initial value.
6865 </note>
6866 <note>
6867 When settings this property, the specified path can be
6868 absolute (full path) or relative
6869 to the <link to="IVirtualBox::homeFolder">
6870 VirtualBox home directory</link>.
6871 When reading this property, a full path is
6872 always returned.
6873 </note>
6874 <note>
6875 The specified path may not exist, it will be created
6876 when necessary.
6877 </note>
6878
6879 <see>
6880 <link to="IVirtualBox::createMachine()"/>,
6881 <link to="IVirtualBox::openMachine()"/>
6882 </see>
6883 </desc>
6884 </attribute>
6885
6886 <attribute name="defaultHardDiskFolder" type="wstring">
6887 <desc>
6888 Full path to the default directory used to create new or open existing
6889 virtual disks.
6890
6891 This path is used when the storage unit of a hard disk is a regular file
6892 in the host's file system and only a file name that contains no path is
6893 given.
6894
6895 The initial value of this property is
6896 <tt>&lt;</tt>
6897 <link to="IVirtualBox::homeFolder">VirtualBox_home</link>
6898 <tt>&gt;/HardDisks</tt>.
6899
6900 <note>
6901 Setting this property to <tt>null</tt> will restore the
6902 initial value.
6903 </note>
6904 <note>
6905 When settings this property, the specified path can be relative
6906 to the
6907 <link to="IVirtualBox::homeFolder">VirtualBox home directory</link> or
6908 absolute. When reading this property, a full path is
6909 always returned.
6910 </note>
6911 <note>
6912 The specified path may not exist, it will be created
6913 when necessary.
6914 </note>
6915
6916 <see>
6917 IHardDisk2,
6918 <link to="IVirtualBox::createHardDisk2()"/>,
6919 <link to="IVirtualBox::openHardDisk2()"/>,
6920 <link to="IMedium::location"/>
6921 </see>
6922 </desc>
6923 </attribute>
6924
6925 <attribute name="hardDiskFormats" type="IHardDiskFormat" safearray="yes" readonly="yes">
6926 <desc>
6927 List of all hard disk storage formats supported by this VirtualBox
6928 installation.
6929
6930 Keep in mind that the hard disk format identifier
6931 (<link to="IHardDiskFormat::id"/>) used in other API calls like
6932 <link to="IVirtualBox::createHardDisk2()"/> to refer to a particular
6933 hard disk format is a case-insensitive string. This means that, for
6934 example, all of the following strings:
6935 <pre>
6936 "VDI"
6937 "vdi"
6938 "VdI"</pre>
6939 refer to the same hard disk format.
6940
6941 Note that the virtual hard disk framework is backend-based, therefore
6942 the list of supported formats depends on what backends are currently
6943 installed.
6944
6945 <see>
6946 <link to="IHardDiskFormat"/>,
6947 </see>
6948 </desc>
6949 </attribute>
6950
6951 <attribute name="defaultHardDiskFormat" type="wstring">
6952 <desc>
6953 Identifier of the default hard disk format used by VirtualBox.
6954
6955 The hard disk format set by this attribute is used by VirtualBox
6956 when the hard disk format was not specified explicitly. One example is
6957 <link to="IVirtualBox::createHardDisk2()"/> with the <tt>null</tt>
6958 format argument. A more complex example is implicit creation of
6959 differencing hard disks when taking a snapshot of a virtual machine:
6960 this operation will try to use a format of the parent hard disk first
6961 and if this format does not support differencing hard disks the default
6962 format specified by this argument will be used.
6963
6964 The list of supported hard disk formats may be obtained by the
6965 <link to="#hardDiskFormats"/> call. Note that the default hard disk
6966 format must have a capability to create differencing hard disks;
6967 otherwise opeartions that create hard disks implicitly may fail
6968 unexpectedly.
6969
6970 The initial value of this property is <tt>VDI</tt> in the current
6971 version of the VirtualBox product, but may change in the future.
6972
6973 <note>
6974 Setting this property to <tt>null</tt> will restore the
6975 initial value.
6976 </note>
6977
6978 <see>
6979 <link to="#hardDiskFormats"/>,
6980 <link to="IHardDiskFormat::id"/>,
6981 <link to="IVirtualBox::createHardDisk2()"/>
6982 </see>
6983 </desc>
6984 </attribute>
6985
6986 <attribute name="remoteDisplayAuthLibrary" type="wstring">
6987 <desc>
6988 Library that provides authentication for VRDP clients. The library
6989 is used if a virtual machine's authentication type is set to "external"
6990 in the VM RemoteDisplay configuration.
6991
6992 The system library extension (".DLL" or ".so") must be omitted.
6993 A full path can be specified; if not, then the library must reside on the
6994 system's default library path.
6995
6996 The default value of this property is <tt>VRDPAuth</tt>. There is a library
6997 of that name in one of the default VirtualBox library directories.
6998
6999 For details about VirtualBox authentication libraries and how to implement
7000 them, please refer to the VirtualBox manual.
7001
7002 <note>
7003 Setting this property to <tt>null</tt> will restore the
7004 initial value.
7005 </note>
7006 </desc>
7007 </attribute>
7008
7009 <attribute name="webServiceAuthLibrary" type="wstring">
7010 <desc>
7011 Library that provides authentication for webservice clients. The library
7012 is used if a virtual machine's authentication type is set to "external"
7013 in the VM RemoteDisplay configuration and will be called from
7014 within the <link to="IWebsessionManager::logon" /> implementation.
7015
7016 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
7017 there is no per-VM setting for this, as the webservice is a global
7018 resource (if it is running). Only for this setting (for the webservice),
7019 setting this value to a literal "null" string disables authentication,
7020 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
7021 no matter what user name and password are supplied.
7022
7023 The initial value of this property is <tt>VRDPAuth</tt>,
7024 meaning that the webservice will use the same authentication
7025 library that is used by default for VBoxVRDP (again, see
7026 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
7027 The format and calling convention of authentication libraries
7028 is the same for the webservice as it is for VBoxVRDP.
7029
7030 </desc>
7031 </attribute>
7032
7033 <attribute name="HWVirtExEnabled" type="boolean">
7034 <desc>
7035 This specifies the default value for hardware virtualization
7036 extensions. If enabled, virtual machines will make use of
7037 hardware virtualization extensions such as Intel VT-x and
7038 AMD-V by default. This value can be overridden by each VM
7039 using their <link to="IMachine::HWVirtExEnabled" /> property.
7040 </desc>
7041 </attribute>
7042
7043 <attribute name="LogHistoryCount" type="unsigned long">
7044 <desc>
7045 This value specifies how many old release log files are kept.
7046 </desc>
7047 </attribute>
7048 </interface>
7049
7050 <!--
7051 // IGuest
7052 /////////////////////////////////////////////////////////////////////////
7053 -->
7054
7055 <interface
7056 name="IGuestOSType" extends="$unknown"
7057 uuid="bc415228-eed0-402c-92f5-96fc4e2dd7e4"
7058 wsmap="struct"
7059 >
7060 <desc>
7061 </desc>
7062
7063 <attribute name="familyId" type="wstring" readonly="yes">
7064 <desc>Guest OS family identifier string.</desc>
7065 </attribute>
7066
7067 <attribute name="familyDescription" type="wstring" readonly="yes">
7068 <desc>Human readable description of the guest OS family.</desc>
7069 </attribute>
7070
7071 <attribute name="id" type="wstring" readonly="yes">
7072 <desc>Guest OS identifier string.</desc>
7073 </attribute>
7074
7075 <attribute name="description" type="wstring" readonly="yes">
7076 <desc>Human readable description of the guest OS.</desc>
7077 </attribute>
7078
7079 <attribute name="is64Bit" type="boolean" readonly="yes">
7080 <desc>Returns @c true if the given OS is 64-bit</desc>
7081 </attribute>
7082
7083 <attribute name="recommendedIOAPIC" type="boolean" readonly="yes">
7084 <desc>Returns @c true if IO APIC recommended for this OS type.</desc>
7085 </attribute>
7086
7087 <attribute name="recommendedVirtEx" type="boolean" readonly="yes">
7088 <desc>Returns @c true if VT-x or AMD-V recommended for this OS type.</desc>
7089 </attribute>
7090
7091 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
7092 <desc>Recommended RAM size in Megabytes.</desc>
7093 </attribute>
7094
7095 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
7096 <desc>Recommended video RAM size in Megabytes.</desc>
7097 </attribute>
7098
7099 <attribute name="recommendedHDD" type="unsigned long" readonly="yes">
7100 <desc>Recommended hard disk size in Megabytes.</desc>
7101 </attribute>
7102
7103 <attribute name="adapterType" type="NetworkAdapterType" readonly="yes">
7104 <desc>Returns recommended network adapter for this OS type.</desc>
7105 </attribute>
7106 </interface>
7107
7108
7109 <enumerator
7110 name="IGuestOSTypeEnumerator" type="IGuestOSType"
7111 uuid="a3335e02-4669-4e3c-80c7-c4dc7056a07c"
7112 />
7113
7114 <collection
7115 name="IGuestOSTypeCollection" type="IGuestOSType" enumerator="IGuestOSTypeEnumerator"
7116 uuid="a5e36749-a610-498b-9f29-2e36c1042d65"
7117 readonly="yes"
7118 />
7119
7120 <interface
7121 name="IGuest" extends="$unknown"
7122 uuid="d8556fca-81bc-12af-fca3-365528fa38ca"
7123
7124 wsmap="suppress"
7125 >
7126 <desc>
7127 The IGuest interface represents information about the operating system
7128 running inside the virtual machine. Used in
7129 <link to="IConsole::guest"/>.
7130
7131 IGuest provides information about the guest operating system, whether
7132 Guest Additions are installed and other OS-specific virtual machine
7133 properties.
7134 </desc>
7135
7136 <attribute name="OSTypeId" type="wstring" readonly="yes">
7137 <desc>
7138 Identifier of the Guest OS type as reported by the Guest
7139 Additions.
7140 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
7141 an IGuestOSType object representing details about the given
7142 Guest OS type.
7143 <note>
7144 If Guest Additions are not installed, this value will be
7145 the same as <link to="IMachine::OSTypeId"/>.
7146 </note>
7147 </desc>
7148 </attribute>
7149
7150 <attribute name="additionsActive" type="boolean" readonly="yes">
7151 <desc>
7152 Flag whether the Guest Additions are installed and active
7153 in which case their version will be returned by the
7154 <link to="#additionsVersion"/> property.
7155 </desc>
7156 </attribute>
7157
7158 <attribute name="additionsVersion" type="wstring" readonly="yes">
7159 <desc>
7160 Version of the Guest Additions (3 decimal numbers separated
7161 by dots) or empty when the Additions are not installed. The
7162 Additions may also report a version but yet not be active as
7163 the version might be refused by VirtualBox (incompatible) or
7164 other failures occurred.
7165 </desc>
7166 </attribute>
7167
7168 <attribute name="supportsSeamless" type="boolean" readonly="yes">
7169 <desc>
7170 Flag whether seamless guest display rendering (seamless desktop
7171 integration) is supported.
7172 </desc>
7173 </attribute>
7174
7175 <attribute name="supportsGraphics" type="boolean" readonly="yes">
7176 <desc>
7177 Flag whether the guest is in graphics mode. If it is not, then
7178 seamless rendering will not work, resize hints are not immediately
7179 acted on and guest display resizes are probably not initiated by
7180 the guest additions.
7181 </desc>
7182 </attribute>
7183
7184 <attribute name="memoryBalloonSize" type="unsigned long">
7185 <desc>Guest system memory balloon size in megabytes.</desc>
7186 </attribute>
7187
7188 <attribute name="statisticsUpdateInterval" type="unsigned long">
7189 <desc>Interval to update guest statistics in seconds.</desc>
7190 </attribute>
7191
7192 <method name="setCredentials">
7193 <desc>
7194 Store login credentials that can be queried by guest operating
7195 systems with Additions installed. The credentials are transient
7196 to the session and the guest may also choose to erase them. Note
7197 that the caller cannot determine whether the guest operating system
7198 has queried or made use of the credentials.
7199
7200 <result name="VBOX_E_VM_ERROR">
7201 VMM device is not available.
7202 </result>
7203
7204 </desc>
7205 <param name="userName" type="wstring" dir="in">
7206 <desc>User name string, can be empty</desc>
7207 </param>
7208 <param name="password" type="wstring" dir="in">
7209 <desc>Password string, can be empty</desc>
7210 </param>
7211 <param name="domain" type="wstring" dir="in">
7212 <desc>Domain name (guest logon scheme specific), can be empty</desc>
7213 </param>
7214 <param name="allowInteractiveLogon" type="boolean" dir="in">
7215 <desc>
7216 Flag whether the guest should alternatively allow the user to
7217 interactively specify different credentials. This flag might
7218 not be supported by all versions of the Additions.
7219 </desc>
7220 </param>
7221 </method>
7222
7223 <method name="getStatistic">
7224 <desc>
7225 Query specified guest statistics as reported by the VirtualBox Additions.
7226 </desc>
7227 <param name="cpuId" type="unsigned long" dir="in">
7228 <desc>Virtual CPU id; not relevant for all statistic types</desc>
7229 </param>
7230 <param name="statistic" type="GuestStatisticType" dir="in">
7231 <desc>Statistic type.</desc>
7232 </param>
7233 <param name="statVal" type="unsigned long" dir="out">
7234 <desc>Statistics value</desc>
7235 </param>
7236 </method>
7237
7238 </interface>
7239
7240
7241 <!--
7242 // IProgress
7243 /////////////////////////////////////////////////////////////////////////
7244 -->
7245
7246 <enumerator
7247 name="IProgressEnumerator" type="IProgress"
7248 uuid="e0380522-4ef1-48f4-856c-e455177ccb2d"
7249 />
7250
7251 <collection
7252 name="IProgressCollection" type="IProgress" enumerator="IProgressEnumerator"
7253 uuid="78B76A7C-F0F2-467c-9F0E-F089A54EE957"
7254 readonly="yes"
7255 />
7256
7257 <interface
7258 name="IProgress" extends="$unknown"
7259 uuid="10CC03A1-717E-429b-992D-C67B56175A51"
7260 wsmap="managed"
7261 >
7262 <desc>
7263 The IProgress interface represents a task progress object that allows
7264 to wait for the completion of some asynchronous task.
7265
7266 The task consists of one or more operations that run sequentially,
7267 one after one. There is an individual percent of completion of the
7268 current operation and the percent of completion of the task as a
7269 whole. Similarly, you can wait for the completion of a particular
7270 operation or for the completion of the whole task.
7271
7272 Every operation is identified by a number (starting from 0)
7273 and has a separate description.
7274 </desc>
7275
7276 <attribute name="id" type="uuid" readonly="yes">
7277 <desc>ID of the task.</desc>
7278 </attribute>
7279
7280 <attribute name="description" type="wstring" readonly="yes">
7281 <desc>Description of the task.</desc>
7282 </attribute>
7283
7284 <attribute name="initiator" type="$unknown" readonly="yes">
7285 <desc>Initiator of the task.</desc>
7286 </attribute>
7287
7288 <attribute name="cancelable" type="boolean" readonly="yes">
7289 <desc>Whether the task can be interrupted.</desc>
7290 </attribute>
7291
7292 <attribute name="percent" type="long" readonly="yes">
7293 <desc>
7294 Current task progress value in percent.
7295 This value depends on how many operations are already complete.
7296 </desc>
7297 </attribute>
7298
7299 <attribute name="completed" type="boolean" readonly="yes">
7300 <desc>Whether the task has been completed.</desc>
7301 </attribute>
7302
7303 <attribute name="canceled" type="boolean" readonly="yes">
7304 <desc>Whether the task has been canceled.</desc>
7305 </attribute>
7306
7307 <attribute name="resultCode" type="result" readonly="yes">
7308 <desc>
7309 Result code of the progress task.
7310 Valid only if <link to="#completed"/> is true.
7311 </desc>
7312 </attribute>
7313
7314 <attribute name="errorInfo" type="IVirtualBoxErrorInfo" readonly="yes">
7315 <desc>
7316 Extended information about the unsuccessful result of the
7317 progress operation. May be NULL when no extended information
7318 is available.
7319 Valid only if <link to="#completed"/> is true and
7320 <link to="#resultCode"/> indicates a failure.
7321 </desc>
7322 </attribute>
7323
7324 <attribute name="operationCount" type="unsigned long" readonly="yes">
7325 <desc>
7326 Number of operations this task is divided into.
7327 Every task consists of at least one operation.
7328 </desc>
7329 </attribute>
7330
7331 <attribute name="operation" type="unsigned long" readonly="yes">
7332 <desc>Number of the operation being currently executed.</desc>
7333 </attribute>
7334
7335 <attribute name="operationDescription" type="wstring" readonly="yes">
7336 <desc>
7337 Description of the operation being currently executed.
7338 </desc>
7339 </attribute>
7340
7341 <attribute name="operationPercent" type="long" readonly="yes">
7342 <desc>Current operation progress value in percent.</desc>
7343 </attribute>
7344
7345 <method name="waitForCompletion">
7346 <desc>
7347 Waits until the task is done (including all operations) with a
7348 given timeout.
7349
7350 <result name="VBOX_E_IPRT_ERROR">
7351 Failed to wait for task completion.
7352 </result>
7353
7354 </desc>
7355 <param name="timeout" type="long" dir="in">
7356 <desc>
7357 Timeout value in milliseconds.
7358 Specify -1 for an indefinite wait.
7359 </desc>
7360 </param>
7361 </method>
7362
7363 <method name="waitForOperationCompletion">
7364 <desc>
7365 Waits until the given operation is done with a given timeout.
7366
7367 <result name="VBOX_E_IPRT_ERROR">
7368 Failed to wait for operation completion.
7369 </result>
7370
7371 </desc>
7372 <param name="operation" type="unsigned long" dir="in">
7373 <desc>
7374 Number of the operation to wait for.
7375 Must be less than <link to="#operationCount"/>.
7376 </desc>
7377 </param>
7378 <param name="timeout" type="long" dir="in">
7379 <desc>
7380 Timeout value in milliseconds.
7381 Specify -1 for an indefinite wait.
7382 </desc>
7383 </param>
7384 </method>
7385
7386 <method name="cancel">
7387 <desc>
7388 Cancels the task.
7389 <note>
7390 If <link to="#cancelable"/> is <tt>false</tt>, then
7391 this method will fail.
7392 </note>
7393
7394 <result name="VBOX_E_INVALID_OBJECT_STATE">
7395 Operation cannot be canceled.
7396 </result>
7397
7398 </desc>
7399 </method>
7400
7401 </interface>
7402
7403
7404 <!--
7405 // ISnapshot
7406 /////////////////////////////////////////////////////////////////////////
7407 -->
7408
7409 <enumerator
7410 name="ISnapshotEnumerator" type="ISnapshot"
7411 uuid="25cfa2a4-1f1d-4f05-9658-b7a5894ef1a3"
7412 />
7413
7414 <collection
7415 name="ISnapshotCollection" type="ISnapshot"
7416 enumerator="ISnapshotEnumerator"
7417 uuid="23852e3c-94cd-4801-ab05-ed35675b3894"
7418 readonly="yes"
7419 />
7420
7421 <interface
7422 name="ISnapshot" extends="$unknown"
7423 uuid="9f1bbf79-13b0-4da2-abba-4a992c65c083"
7424 wsmap="managed"
7425 >
7426 <desc>
7427 The ISnapshot interface represents a snapshot of the virtual
7428 machine.
7429
7430 The <i>snapshot</i> stores all the information about a virtual
7431 machine necessary to bring it to exactly the same state as it was at
7432 the time of taking the snapshot. The snapshot includes:
7433
7434 <ul>
7435 <li>all settings of the virtual machine (i.e. its hardware
7436 configuration: RAM size, attached hard disks, etc.)
7437 </li>
7438 <li>the execution state of the virtual machine (memory contents,
7439 CPU state, etc.).
7440 </li>
7441 </ul>
7442
7443 Snapshots can be <i>offline</i> (taken when the VM is powered off)
7444 or <i>online</i> (taken when the VM is running). The execution
7445 state of the offline snapshot is called a <i>zero execution state</i>
7446 (it doesn't actually contain any information about memory contents
7447 or the CPU state, assuming that all hardware is just powered off).
7448
7449 <h3>Snapshot branches</h3>
7450
7451 Snapshots can be chained. Chained snapshots form a branch where
7452 every next snapshot is based on the previous one. This chaining is
7453 mostly related to hard disk branching (see <link to="IHardDisk2"/>
7454 description). This means that every time a new snapshot is created,
7455 a new differencing hard disk is implicitly created for all normal
7456 hard disks attached to the given virtual machine. This allows to
7457 fully restore hard disk contents when the machine is later reverted
7458 to a particular snapshot.
7459
7460 In the current implementation, multiple snapshot branches within one
7461 virtual machine are not allowed. Every machine has a single branch,
7462 and <link to="IConsole::takeSnapshot()"/> operation adds a new
7463 snapshot to the top of that branch.
7464
7465 Existing snapshots can be discarded using
7466 <link to="IConsole::discardSnapshot()"/>.
7467
7468 <h3>Current snapshot</h3>
7469
7470 Every virtual machine has a current snapshot, identified by
7471 <link to="IMachine::currentSnapshot"/>. This snapshot is used as
7472 a base for the <i>current machine state</i> (see below), to the effect
7473 that all normal hard disks of the machine and its execution
7474 state are based on this snapshot.
7475
7476 In the current implementation, the current snapshot is always the
7477 last taken snapshot (i.e. the head snapshot on the branch) and it
7478 cannot be changed.
7479
7480 The current snapshot is <tt>null</tt> if the machine doesn't have
7481 snapshots at all; in this case the current machine state is just
7482 current settings of this machine plus its current execution state.
7483
7484 <h3>Current machine state</h3>
7485
7486 The current machine state is what represented by IMachine instances got
7487 directly from IVirtualBox
7488 using <link
7489 to="IVirtualBox::getMachine()">getMachine()</link>, <link
7490 to="IVirtualBox::findMachine()">findMachine()</link>, etc. (as opposed
7491 to instances returned by <link to="ISnapshot::machine"/>). This state
7492 is always used when the machine is <link to="IConsole::powerUp"> powered
7493 on</link>.
7494
7495 The current machine state also includes the current execution state.
7496 If the machine is being currently executed
7497 (<link to="IMachine::state"/> is <link to="MachineState_Running"/>
7498 and above), its execution state is just what's happening now.
7499 If it is powered off (<link to="MachineState_PoweredOff"/> or
7500 <link to="MachineState_Aborted"/>), it has a zero execution state.
7501 If the machine is saved (<link to="MachineState_Saved"/>), its
7502 execution state is what saved in the execution state file
7503 (<link to="IMachine::stateFilePath"/>).
7504
7505 If the machine is in the saved state, then, next time it is powered
7506 on, its execution state will be fully restored from the saved state
7507 file and the execution will continue from the point where the state
7508 was saved.
7509
7510 Similarly to snapshots, the current machine state can be discarded
7511 using <link to="IConsole::discardCurrentState()"/>.
7512
7513 <h3>Taking and discarding snapshots</h3>
7514
7515 The table below briefly explains the meaning of every snapshot
7516 operation:
7517
7518 <table>
7519 <tr><th>Operation</th><th>Meaning</th><th>Remarks</th></tr>
7520
7521 <tr><td><link to="IConsole::takeSnapshot()"/></td>
7522
7523 <td>Save the current state of the virtual machine, including all
7524 settings, contents of normal hard disks and the current modifications
7525 to immutable hard disks (for online snapshots)</td>
7526
7527 <td>The current state is not changed (the machine will continue
7528 execution if it is being executed when the snapshot is
7529 taken)</td></tr>
7530
7531 <tr><td><link to="IConsole::discardSnapshot()"/></td>
7532
7533 <td>Forget the state of the virtual machine stored in the snapshot:
7534 dismiss all saved settings and delete the saved execution state (for
7535 online snapshots)</td>
7536
7537 <td>Other snapshots (including child snapshots, if any) and the
7538 current state are not directly affected</td></tr>
7539
7540 <tr><td><link to="IConsole::discardCurrentState()"/></td>
7541
7542 <td>Restore the current state of the virtual machine from the state
7543 stored in the current snapshot, including all settings and hard disk
7544 contents</td>
7545
7546 <td>The current state of the machine existed prior to this operation
7547 is lost</td></tr>
7548
7549 <tr><td><link to="IConsole::discardCurrentSnapshotAndState()"/></td>
7550
7551 <td>Completely revert the virtual machine to the state it was in
7552 before the current snapshot has been taken</td>
7553
7554 <td>The current state, as well as the current snapshot, are
7555 lost</td></tr>
7556
7557 </table>
7558
7559 </desc>
7560
7561 <attribute name="id" type="uuid" readonly="yes">
7562 <desc>UUID of the snapshot.</desc>
7563 </attribute>
7564
7565 <attribute name="name" type="wstring">
7566 <desc>Short name of the snapshot.</desc>
7567 </attribute>
7568
7569 <attribute name="description" type="wstring">
7570 <desc>Optional description of the snapshot.</desc>
7571 </attribute>
7572
7573 <attribute name="timeStamp" type="long long" readonly="yes">
7574 <desc>
7575 Time stamp of the snapshot, in milliseconds since 1970-01-01 UTC.
7576 </desc>
7577 </attribute>
7578
7579 <attribute name="online" type="boolean" readonly="yes">
7580 <desc>
7581 <tt>true</tt> if this snapshot is an online snapshot and
7582 <tt>false</tt> otherwise.
7583
7584 <note>
7585 When this attribute is <tt>true</tt>, the
7586 <link to="IMachine::stateFilePath"/> attribute of the
7587 <link to="#machine"/> object associated with this snapshot
7588 will point to the saved state file. Otherwise, it will be
7589 <tt>null</tt>.
7590 </note>
7591 </desc>
7592 </attribute>
7593
7594 <attribute name="machine" type="IMachine" readonly="yes">
7595 <desc>
7596 Virtual machine this snapshot is taken on. This object
7597 stores all settings the machine had when taking this snapshot.
7598 <note>
7599 The returned machine object is immutable, i.e. no
7600 any settings can be changed.
7601 </note>
7602 </desc>
7603 </attribute>
7604
7605 <attribute name="parent" type="ISnapshot" readonly="yes">
7606 <desc>
7607 Parent snapshot (a snapshot this one is based on).
7608 <note>
7609 It's not an error to read this attribute on a snapshot
7610 that doesn't have a parent -- a null object will be
7611 returned to indicate this.
7612 </note>
7613 </desc>
7614 </attribute>
7615
7616 <attribute name="children" type="ISnapshotCollection" readonly="yes">
7617 <desc>
7618 Child snapshots (all snapshots having this one as a parent).
7619 <note>
7620 In the current implementation, there can be only one
7621 child snapshot, or no children at all, meaning this is the
7622 last (head) snapshot.
7623 </note>
7624 </desc>
7625 </attribute>
7626
7627 </interface>
7628
7629
7630 <!--
7631 // IMedia
7632 /////////////////////////////////////////////////////////////////////////
7633 -->
7634
7635 <enum
7636 name="MediaState"
7637 uuid="8b86e03c-2f1c-412a-8fbd-326f62701200"
7638 >
7639 <desc>
7640 Virtual media state.
7641 <see>IMedia</see>
7642 </desc>
7643
7644 <const name="NotCreated" value="0">
7645 <desc>
7646 Associated media storage does not exist (either was not created yet or
7647 was deleted).
7648 </desc>
7649 </const>
7650 <const name="Created" value="1">
7651 <desc>
7652 Associated storage exists and accessible.
7653 </desc>
7654 </const>
7655 <const name="LockedRead" value="2">
7656 <desc>
7657 Media is locked for reading, no data modification is possible.
7658 </desc>
7659 </const>
7660 <const name="LockedWrite" value="3">
7661 <desc>
7662 Media is locked for writing, no concurrent data reading or modification
7663 is possible.
7664 </desc>
7665 </const>
7666 <const name="Inaccessible" value="4">
7667 <desc>
7668 Associated media storage is not accessible.
7669 </desc>
7670 </const>
7671 <const name="Creating" value="5">
7672 <desc>
7673 Associated media storage is being created.
7674 </desc>
7675 </const>
7676 <const name="Deleting" value="6">
7677 <desc>
7678 Associated media storage is being deleted.
7679 </desc>
7680 </const>
7681 </enum>
7682
7683 <interface
7684 name="IMedium" extends="$unknown"
7685 uuid="a7fb3bfb-c180-4274-bae4-7fbc89046e13"
7686 wsmap="managed"
7687 >
7688 <desc>
7689 The IMedium interface is a common interface for all objects representing
7690 virtual media such as hard disks, DVD images.
7691
7692 Each medium is associated with a storage unit (such as a file on the host
7693 computer or a network resource) that holds actual data. The location of
7694 the storage unit is represented by the #location attribute. The value of
7695 this attribute is media type dependent.
7696
7697 The exact media type may be determined by querying the appropriate
7698 interface such as:
7699 <ul>
7700 <li>IHardDisk2 (virtual hard disks)</li>
7701 <li>IDVDImage2 (standard CD/DVD ISO image files)</li>
7702 <li>IFloppyImage2 (raw floppy image files)</li>
7703 </ul>
7704
7705 Existing media are opened using the following methods, depending on the
7706 media type:
7707 <ul>
7708 <li><link to="IVirtualBox::openHardDisk2()"/></li>
7709 <li><link to="IVirtualBox::openDVDImage()"/></li>
7710 <li><link to="IVirtualBox::openFloppyImage()"/></li>
7711 </ul>
7712
7713 New hard disk media are created using the
7714 <link to="IVirtualBox::createHardDisk2()"/> method. CD/DVD and floppy
7715 images are created outside VirtualBox, usually by storing a copy
7716 of the real medium of the corresponding type in a regular file.
7717
7718 <h3>Known Media</h3>
7719
7720 When an existing medium gets opened for the first time, it gets
7721 automatically remembered by the given VirtualBox installation or, in other
7722 words, becomes a <i>known medium</i>. Known media are stored in the media
7723 registry transparently maintained by VirtualBox and stored in settings
7724 files so that this registry is preserved when VirtualBox is not running.
7725
7726 Newly created virtual hard disks get remembered only when the associated
7727 storage unit is actually created (see IHardDisk2 for more details).
7728
7729 All known media can be enumerated using
7730 <link to="IVirtualBox::hardDisks2"/>,
7731 <link to="IVirtualBox::DVDImages"/> and
7732 <link to="IVirtualBox::floppyImages"/> attributes. Individual media can be
7733 quickly found by UUID using <link to="IVirtualBox::getHardDisk2()"/>
7734 and similar methods or by location using
7735 <link to="IVirtualBox::findHardDisk2()"/> and similar methods.
7736
7737 Only known media can be attached to virtual machines.
7738
7739 Removing known media from the media registry is performed when the given
7740 medium is closed using the <link to="#close()"/> method or when its
7741 associated storage unit is deleted (only for hard disks).
7742
7743 <h3>Accessibility Checks</h3>
7744
7745 The given medium (with the created storage unit) is considered to be
7746 <i>accessible</i> when its storage unit can be successfully read from.
7747 Accessible media are indicated by the <link to="MediaState_Created"/>
7748 value of the <link to="#state"/> attribute. When the storage unit cannot
7749 be read (for example, because it is located on a disconnected network
7750 resource, or was accidentally deleted outside VirtualBox), the medium is
7751 considered to be <i>inaccessible</i> which is indicated by the
7752 <link to="MediaState_Inaccessible"/> state. The details about the reason
7753 of being inaccessible can be obtained using the
7754 <link to="#lastAccessError"/> attribute.
7755
7756 A new accessibility check is performed each time the <link to="#state"/>
7757 attribute is read. Please note that this check may take long time (several
7758 seconds or even minutes, depending on the storage unit location and
7759 format), and will block the calling thread until finished. For this
7760 reason, it is recommended to never read this attribute on the main UI
7761 thread to avoid making the UI unresponsive.
7762
7763 Note that when VirtualBox starts up (e.g. the VirtualBox object gets
7764 created for the first time), all known media are in the
7765 <link to="MediaState_Inaccessible"/> state but the value of the <link
7766 to="#lastAccessError"/> attribute is <tt>null</tt> because no actual
7767 accessibility check is made on startup. This is done to make the
7768 VirtualBox object ready for serving requests as
7769 fast as possible and let the end-user application decide if it needs to
7770 check media accessibility right away or not.
7771 </desc>
7772
7773 <attribute name="id" type="uuid" readonly="yes">
7774 <desc>
7775 UUID of the medium. For a newly created medium, this value is a randomly
7776 generated UUID.
7777
7778 <note>
7779 For media in one of MediaState_NotCreated, MediaState_Creating or
7780 MediaState_Deleting states, the value of this property is undefined
7781 and will most likely be an empty UUID.
7782 </note>
7783 </desc>
7784 </attribute>
7785
7786 <attribute name="description" type="wstring">
7787 <desc>
7788 Optional description of the medium. For newly created media, the value
7789 of this attribute value is <tt>null</tt>.
7790
7791 Media types that don't support this attribute will return E_NOTIMPL in
7792 attempt to get or set this attribute's value.
7793
7794 <note>
7795 For some storage types, reading this attribute may return an outdated
7796 (last known) value when <link to="#state"/> is <link
7797 to="MediaState_Inaccessible"/> or <link
7798 to="MediaState_LockedWrite"/> because the value of this attribute is
7799 stored within the storage unit itself. Also note that changing the
7800 attribute value is not possible in such case, as well as when the
7801 medium is the <link to="MediaState_LockedRead"/> state.
7802 </note>
7803 </desc>
7804 </attribute>
7805
7806 <attribute name="state" type="MediaState" readonly="yes">
7807 <desc>
7808 Current media state. Inspect <link to="MediaState"/> values for details.
7809
7810 Reading this attribute may take long time because a new accessibility
7811 check of the storage unit is performed every time the attribute is read.
7812 This check may cause a significant delay if the storage unit of the
7813 given medium is, for example, a file located on a network share which is
7814 not currently accessible due to connectivity problems -- the call will
7815 not return until a timeout interval defined by the host OS for this
7816 operation expires.
7817
7818 If the last known state of the medium is <link to="MediaState_Created"/>
7819 and the accessibility check fails then the state would be set to
7820 <link to="MediaState_Inaccessible"/> and <link to="#lastAccessError"/>
7821 may be used to get more details about the failure. If the state of the
7822 medium is <link to="MediaState_LockedRead"/> or
7823 <link to="MediaState_LockedWrite"/> then it remains the same, and a
7824 non-null value of <link to="#lastAccessError"/> will indicate a failed
7825 accessibility check in this case.
7826
7827 Note that not all media states are applicable to certain media types.
7828 For example, states <link to="MediaState_NotCreated"/>,
7829 <link to="MediaState_LockedWrite"/>, <link to="MediaState_Creating"/>,
7830 <link to="MediaState_Deleting"/> are meaningless for IDVDImage2 and
7831 IFloppyImage2 media.
7832 </desc>
7833 </attribute>
7834
7835 <attribute name="location" type="wstring">
7836 <desc>
7837 Location of the storage unit holding media data.
7838
7839 The format of the location string is media type specific. For media
7840 types that use regular files in a host's file system, the location
7841 string is just a full file name.
7842
7843 Some media types may support changing the storage unit location by
7844 simply changing the value of this property. If this operation is not
7845 supported, the implementation will return E_NOTIMPL in attempt to set
7846 this attribute's value.
7847
7848 When setting a value of the location attribute which is a regular file
7849 in the host's file system, the given file name may be either relative to
7850 the <link to="IVirtualBox::homeFolder">VirtualBox home folder</link> or
7851 absolute. Note that if the given location specification does not contain
7852 the file extension part then a proper default extension will be
7853 automatically appended by the implementation depending on the media type.
7854 </desc>
7855 </attribute>
7856
7857 <attribute name="name" type="wstring" readonly="yes">
7858 <desc>
7859 Name of the storage unit holding media data.
7860
7861 The returned string is a short version of the <link to="#location"/>
7862 attribute that is suitable for representing the medium in situations
7863 where the full location specification is too long (such as lists
7864 and comboboxes in GUI frontends). This string is also used by frontends
7865 to sort the media list alphabetically when needed.
7866
7867 For example, for locations that are regular files in the host's file
7868 system, the value of this attribute is just a file name (+ extension),
7869 without the path specification.
7870
7871 Note that as opposed to the <link to="#location"/> attribute, the name
7872 attribute will not necessary be unique for a list of media of the
7873 given type and format.
7874 </desc>
7875 </attribute>
7876
7877 <attribute name="size" type="unsigned long long" readonly="yes">
7878 <desc>
7879 Physical size of the storage unit used to hold media data (in bytes).
7880
7881 <note>
7882 For media whose <link to="#state"/> is <link
7883 to="MediaState_Inaccessible"/>, the value of this property is the
7884 last known size. For <link to="MediaState_NotCreated"/> media,
7885 the returned value is zero.
7886 </note>
7887 </desc>
7888 </attribute>
7889
7890 <attribute name="lastAccessError" type="wstring" readonly="yes">
7891 <desc>
7892 Text message that represents the result of the last accessibility
7893 check.
7894
7895 Accessibility checks are performed each time the <link to="#state"/>
7896 attribute is read. A @c null string is returned if the last
7897 accessibility check was successful. A non-null string indicates a
7898 failure and should normally describe a reason of the failure (for
7899 example, a file read error).
7900 </desc>
7901 </attribute>
7902
7903 <attribute name="machineIds" type="uuid" safearray="yes" readonly="yes">
7904 <desc>
7905 Array of UUIDs of all machines this medium is attached to.
7906
7907 A <tt>null</tt> array is returned if this medium is not attached to any
7908 machine or to any machine's snapshot.
7909
7910 <note>
7911 The returned array will include a machine even if this medium is not
7912 attached to that machine in the current state but attached to it in
7913 one of the machine's snapshots. See <link to="#getSnapshotIds()"/> for
7914 details.
7915 </note>
7916 </desc>
7917 </attribute>
7918
7919 <method name="getSnapshotIds">
7920 <desc>
7921 Returns an array of UUIDs of all snapshots of the given machine where
7922 this medium is attached to it.
7923
7924 If the medium is attached to the machine in the current state, then the
7925 first element in the array will always be the ID of the queried machine
7926 (i.e. the value equal to the @c machineId argument), followed by
7927 snapshot IDs (if any).
7928
7929 If the medium is not attached to the machine in the current state, then
7930 the array will contain only snapshot IDs.
7931
7932 The returned array may be <tt>null</tt> if this medium is not attached
7933 to the given machine at all, neither in the current state nor in one of
7934 snapshots.
7935 </desc>
7936 <param name="machineId" type="uuid" dir="in">
7937 <desc>
7938 UUID of the machine to query.
7939 </desc>
7940 </param>
7941 <param name="snapshotIds" type="uuid" safearray="yes" dir="return">
7942 <desc>
7943 Array of snapshot UUIDs of the given machine using this medium.
7944 </desc>
7945 </param>
7946 </method>
7947
7948 <method name="lockRead">
7949 <desc>
7950 Locks this medium for reading.
7951
7952 The read lock is shared: many clients can simultaneously lock the
7953 same media for reading unless it is already locked for writing (see
7954 <link to="#lockWrite()"/>) in which case an error is returned.
7955
7956 When the medium is locked for reading, it cannot be modified
7957 from within VirtualBox. This means that any method that changes
7958 the properties of this medium or contents of the storage unit
7959 will return an error (unless explicitly stated otherwise) and
7960 that an attempt to start a virtual machine that wants to modify
7961 the medium will also fail.
7962
7963 When the virtual machine is started up, it locks for reading all
7964 media it uses in read-only mode. If some media cannot be locked
7965 for reading, the startup procedure will fail.
7966
7967 The medium locked for reading must be unlocked using the <link
7968 to="#unlockRead()"/> method. Calls to <link to="#lockRead()"/>
7969 can be nested and must be followed by the same number of paired
7970 <link to="#unlockRead()"/> calls.
7971
7972 This method sets the media state to <link
7973 to="MediaState_LockedRead"/> on success. The state prior to
7974 this call must be <link to="MediaState_Created"/>, <link
7975 to="MediaState_Inaccessible"/> or <link
7976 to="MediaState_LockedRead"/>. As you can see, inaccessible
7977 media can be locked too. This is not an error; this method
7978 performs a logical lock that prevents modifications of this
7979 media through the VirtualBox API, not a physical lock of the
7980 underlying storage unit.
7981
7982 This method returns the current state of the medium
7983 <b>before</b> the operation.
7984
7985 <result name="VBOX_E_INVALID_OBJECT_STATE">
7986 Invalid media state (e.g. not created, locked, inaccessible,
7987 creating, deleting).
7988 </result>
7989
7990 </desc>
7991 <param name="state" type="MediaState" dir="return">
7992 <desc>
7993 State of the medium after the operation.
7994 </desc>
7995 </param>
7996 </method>
7997
7998 <method name="unlockRead">
7999 <desc>
8000 Cancels the read lock previously set by <link to="#lockRead()"/>.
8001
8002 Either on success or on failure, this method returns the current state
8003 of the medium <b>after</b> the operation.
8004
8005 See <link to="#lockRead()"/> for more details.
8006
8007 <result name="VBOX_E_INVALID_OBJECT_STATE">
8008 Medium not locked for reading.
8009 </result>
8010
8011 </desc>
8012 <param name="state" type="MediaState" dir="return">
8013 <desc>
8014 State of the medium after the operation.
8015 </desc>
8016 </param>
8017 </method>
8018
8019 <method name="lockWrite">
8020 <desc>
8021 Locks this medium for writing.
8022
8023 The write lock, as opposed to <link to="#lockRead()"/>, is
8024 exclusive: there may be only one client that holds a write lock
8025 and there may be no read locks while the write lock is held.
8026
8027 When the medium is locked for writing, it cannot be modified
8028 from within VirtualBox and it is not guaranteed that the values
8029 of its properties are up-to-date. Any method that changes the
8030 properties of this medium or contents of the storage unit will
8031 return an error ((unless explicitly stated otherwise) and an
8032 attempt to start a virtual machine that wants to modify or to
8033 read the medium will also fail.
8034
8035 When the virtual machine is started up, it locks for writing all
8036 media it uses to write data to. If some media cannot be locked
8037 for writing, the startup procedure will fail.
8038
8039 The medium locked for writing must be unlocked using the <link
8040 to="#unlockWrite()"/> method. Calls to <link to="#lockWrite()"/>
8041 can <b>not</b> be nested and must be followed by a paired <link
8042 to="#unlockWrite()"/> call.
8043
8044 This method sets the media state to <link
8045 to="MediaState_LockedWrite"/> on success. The state prior to
8046 this call must be <link to="MediaState_Created"/> or <link
8047 to="MediaState_Inaccessible"/>. As you can see, inaccessible
8048 media can be locked too. This is not an error; this method
8049 performs a logical lock that prevents modifications of this
8050 media through the VirtualBox API, not a physical lock of the
8051 underlying storage unit.
8052
8053 Either on success or on failure, this method returns the current
8054 state of the medium <b>before</b> the operation.
8055
8056 <result name="VBOX_E_INVALID_OBJECT_STATE">
8057 Invalid media state (e.g. not created, locked, inaccessible,
8058 creating, deleting).
8059 </result>
8060
8061 </desc>
8062 <param name="state" type="MediaState" dir="return">
8063 <desc>
8064 State of the medium after the operation.
8065 </desc>
8066 </param>
8067 </method>
8068
8069 <method name="unlockWrite">
8070 <desc>
8071 Cancels the write lock previously set by <link to="#lockWrite()"/>.
8072
8073 Either on success or on failure, this method returns the current
8074 state of the medium <b>after</b> the operation.
8075
8076 See <link to="#lockWrite()"/> for more details.
8077
8078 <result name="VBOX_E_INVALID_OBJECT_STATE">
8079 Medium not locked for writing.
8080 </result>
8081
8082 </desc>
8083 <param name="state" type="MediaState" dir="return">
8084 <desc>
8085 State of the medium after the operation.
8086 </desc>
8087 </param>
8088 </method>
8089
8090 <method name="close">
8091 <desc>
8092 Closes this medium.
8093
8094 The hard disk must not be attached to any known virtual machine
8095 and must not have any known child hard disks, otherwise the
8096 operation will fail.
8097
8098 When the hard disk is successfully closed, it gets removed from
8099 the list of remembered hard disks, but its storage unit is not
8100 deleted. In particular, this means that this hard disk can be
8101 later opened again using the <link
8102 to="IVirtualBox::openHardDisk2"/> call.
8103
8104 Note that after this method successfully returns, the given hard
8105 disk object becomes uninitialized. This means that any attempt
8106 to call any of its methods or attributes will fail with the
8107 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error.
8108
8109 <result name="VBOX_E_INVALID_OBJECT_STATE">
8110 Invalid media state (other than not created, created or
8111 inaccessible).
8112 </result>
8113 <result name="VBOX_E_OBJECT_IN_USE">
8114 Medium attached to virtual machine.
8115 </result>
8116 <result name="VBOX_E_FILE_ERROR">
8117 Settings file not accessible.
8118 </result>
8119 <result name="VBOX_E_XML_ERROR">
8120 Could not parse the settings file.
8121 </result>
8122
8123 </desc>
8124 </method>
8125
8126 </interface>
8127
8128
8129 <!--
8130 // IHardDisk2
8131 /////////////////////////////////////////////////////////////////////////
8132 -->
8133
8134 <enum
8135 name="HardDiskType"
8136 uuid="a348fafd-a64e-4643-ba65-eb3896bd7e0a"
8137 >
8138 <desc>
8139 Virtual hard disk type.
8140 <see>IHardDisk</see>
8141 </desc>
8142
8143 <const name="Normal" value="0">
8144 <desc>
8145 Normal hard disk (attached directly or indirectly, preserved
8146 when taking snapshots).
8147 </desc>
8148 </const>
8149 <const name="Immutable" value="1">
8150 <desc>
8151 Immutable hard disk (attached indirectly, changes are wiped out
8152 after powering off the virtual machine).
8153 </desc>
8154 </const>
8155 <const name="Writethrough" value="2">
8156 <desc>
8157 Write through hard disk (attached directly, ignored when
8158 taking snapshots).
8159 </desc>
8160 </const>
8161 </enum>
8162
8163 <interface
8164 name="IHardDisk2Attachment" extends="$unknown"
8165 uuid="fa2f4619-2c14-4090-869e-73b45419b7b5"
8166 wsmap="struct"
8167 >
8168 <desc>
8169 The IHardDisk2Attachment interface represents a hard disk attachment of a
8170 virtual machine.
8171
8172 Every hard disk attachment specifies a slot of the virtual hard disk
8173 controller and a virtual hard disk attached to this slot.
8174
8175 The array of hard disk attachments is returned by
8176 <link to="IMachine::hardDisk2Attachments"/>.
8177
8178 <note>
8179 With the COM API, this is an interface like all the others. With the
8180 webservice, this is mapped to a structure, so querying the attribute
8181 will not return an object, but a complete structure.
8182 </note>
8183 </desc>
8184 <attribute name="hardDisk" type="IHardDisk2" readonly="yes">
8185 <desc>Hard disk object associated with this attachment.</desc>
8186 </attribute>
8187
8188 <attribute name="bus" type="StorageBus" readonly="yes">
8189 <desc>Interface bus of this attachment.</desc>
8190 </attribute>
8191
8192 <attribute name="channel" type="long" readonly="yes">
8193 <desc>Channel number of this attachment.</desc>
8194 </attribute>
8195
8196 <attribute name="device" type="long" readonly="yes">
8197 <desc>Device slot number of this attachment.</desc>
8198 </attribute>
8199
8200 </interface>
8201
8202 <interface
8203 name="IHardDisk2" extends="IMedium"
8204 uuid="ed6e2525-c2fd-42a4-917a-7a9045ac9e15"
8205 wsmap="managed"
8206 >
8207 <desc>
8208 The IHardDisk2 interface represents a virtual hard disk drive
8209 used by a virtual machine.
8210
8211 Virtual hard disk objects virtualize the hard disk hardware and look like
8212 regular hard disks for the guest OS running inside the virtual machine.
8213
8214 <h3>Hard Disk Types</h3>
8215
8216 There are three types of hard disks:
8217 <link to="HardDiskType_Normal">Normal</link>,
8218 <link to="HardDiskType_Immutable">Immutable</link> and
8219 <link to="HardDiskType_Writethrough">Writethrough</link>. The type of the
8220 hard disk defines how the hard disk is attached to a virtual machine and
8221 what happens when a <link to="ISnapshot">snapshot</link> of the virtual
8222 machine with the attached hard disk is taken. The type of the hard disk is
8223 defined by the <link to="#type"/> attribute.
8224
8225 All hard disks can be also divided in two big groups: <i>base</i> hard
8226 disks and <i>differencing</i> hard disks. A base hard disk contains all
8227 sectors of the hard disk data in its storage unit and therefore can be
8228 used independently. On the contrary, a differencing hard disk contains
8229 only some part of the hard disk data (a subset of sectors) and needs
8230 another hard disk to get access to the missing sectors of data. This
8231 another hard disk is called a <i>parent</i> hard disk and defines a hard
8232 disk to which this differencing hard disk is known to be <i>linked to</i>.
8233 The parent hard disk may be itself a differencing hard disk. This
8234 way, differencing hard disks form a linked hard disk chain. This chain
8235 always ends with the base hard disk which is sometimes referred to as the
8236 root hard disk of this chain. Note that several differencing hard disks
8237 may be linked to the same parent hard disk. This way, all known hard disks
8238 form a hard disk tree which is based on their parent-child relationship.
8239
8240 Differencing hard disks can be distinguished from base hard disks by
8241 querying the <link to="#parent"/> attribute: base hard disks do not have
8242 parents they would depend on, so the value of this attribute is always
8243 <tt>null</tt> for them. Using this attribute, it is possible to walk up
8244 the hard disk tree (from the child hard disk to its parent). It is also
8245 possible to walk down the tree using the <link to="#children"/>
8246 attribute.
8247
8248 Note that the type of all differencing hard disks is
8249 <link to="HardDiskType_Normal">Normal</link>; all other values are
8250 meaningless for them. Base hard disks may be of any type.
8251
8252 <h3>Creating Hard Disks</h3>
8253
8254 New base hard disks are created using
8255 <link to="IVirtualBox::createHardDisk2()"/>. Existing hard disks are
8256 opened using <link to="IVirtualBox::openHardDisk2()"/>. Differencing hard
8257 disks are usually implicitly created by VirtualBox when needed but may
8258 also be created explicitly using <link to="#createDiffStorage()"/>.
8259
8260 After the hard disk is successfully created (including the storage unit)
8261 or opened, it becomes a known hard disk (remembered in the internal media
8262 registry). Known hard disks can be attached to a virtual machine, accessed
8263 through <link to="IVirtualBox::getHardDisk2()"/> and
8264 <link to="IVirtualBox::findHardDisk2()"/> methods or enumerated using the
8265 <link to="IVirtualBox::hardDisks2"/> array (only for base hard disks).
8266
8267 The following methods, besides <link to="IMedium::close()"/>,
8268 automatically remove the hard disk from the media registry:
8269 <ul>
8270 <li><link to="#deleteStorage()"/></li>
8271 <li><link to="#mergeTo()"/></li>
8272 </ul>
8273
8274 If the storage unit of the hard disk is a regular file in the host's
8275 file system then the rules stated in the description of the
8276 <link to="IMedium::location"/> attribute apply when setting its value. In
8277 addition, a plain file name without any path may be given, in which case
8278 the <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
8279 folder</link> will be prepended to it.
8280
8281 <h4>Automatic composition of the file name part</h4>
8282
8283 Another extension to the <link to="IMedium::location"/> attribute is that
8284 there is a possibility to cause VirtualBox to compose a unique value for
8285 the file name part of the location using the UUID of the hard disk. This
8286 applies only to hard disks in <link to="MediaState_NotCreated"/> state,
8287 e.g. before the storage unit is created, and works as follows. You set the
8288 value of the <link to="IMedium::location"/> attribute to a location
8289 specification which only contains the path specification but not the file
8290 name part and ends with either a forward slash or a backslash character.
8291 In response, VirtualBox will generate a new UUID for the hard disk and
8292 compose the file name using the following pattern:
8293 <pre>
8294 &lt;path&gt;/{&lt;uuid&gt;}.&lt;ext&gt;
8295 </pre>
8296 where <tt>&lt;path&gt;</tt> is the supplied path specification,
8297 <tt>&lt;uuid&gt;</tt> is the newly generated UUID and <tt>&lt;ext&gt;</tt>
8298 is the default extension for the storage format of this hard disk. After
8299 that, you may call any of the methods that create a new hard disk storage
8300 unit and they will use the generated UUID and file name.
8301
8302 <h3>Attaching Hard Disks</h3>
8303
8304 Hard disks are attached to virtual machines using the
8305 <link to="IMachine::attachHardDisk2()"/> method and detached using the
8306 <link to="IMachine::detachHardDisk2()"/> method. Depending on their
8307 <link to="#type"/>, hard disks are attached either
8308 <i>directly</i> or <i>indirectly</i>.
8309
8310 When a hard disk is being attached directly, it is associated with the
8311 virtual machine and used for hard disk operations when the machine is
8312 running. When a hard disk is being attached indirectly, a new differencing
8313 hard disk linked to it is implicitly created and this differencing hard
8314 disk is associated with the machine and used for hard disk operations.
8315 This also means that if <link to="IMachine::attachHardDisk2()"/> performs
8316 a direct attachment then the same hard disk will be returned in response
8317 to the subsequent <link to="IMachine::getHardDisk2()"/> call; however if
8318 an indirect attachment is performed then
8319 <link to="IMachine::getHardDisk2()"/> will return the implicitly created
8320 differencing hard disk, not the original one passed to <link
8321 to="IMachine::attachHardDisk2()"/>. The following table shows the
8322 dependency of the attachment type on the hard disk type:
8323
8324 <table>
8325 <tr>
8326 <th>Hard Disk Type</th>
8327 <th>Direct or Indirect?</th>
8328 </tr>
8329 <tr>
8330 <td>Normal (Base)</td>
8331 <td>
8332 Normal base hard disks that do not have children (i.e. differencing
8333 hard disks linked to them) and that are not already attached to
8334 virtual machines in snapshots are attached <b>directly</b>.
8335 Otherwise, they are attached <b>indirectly</b> because having
8336 dependent children or being part of the snapshot makes it impossible
8337 to modify hard disk contents without breaking the integrity of the
8338 dependent party. The <link to="#readOnly"/> attribute allows to
8339 quickly determine the kind of the attachment for the given hard
8340 disk. Note that if a normal base hard disk is to be indirectly
8341 attached to a virtual machine with snapshots then a special
8342 procedure called <i>smart attachment</i> is performed (see below).
8343 </td>
8344 </tr>
8345 <tr>
8346 <td>Normal (Differencing)</td>
8347 <td>
8348 Differencing hard disks are like normal base hard disks: attached
8349 <b>directly</b> if they do not have children and are not attached to
8350 virtual machines in snapshots, and <b>indirectly</b> otherwise. Note
8351 that the smart attachment procedure is never performed for
8352 differencing hard disks.
8353 </td>
8354 </tr>
8355 <tr>
8356 <td>Immutable</td>
8357 <td>
8358 Immutable hard disks are always attached <b>indirectly</b> because
8359 they are designed to be non-writable. If an immutable hard disk is
8360 attached to a virtual machine with snapshots then a special
8361 procedure called smart attachment is performed (see below).
8362 </td>
8363 </tr>
8364 <tr>
8365 <td>Writethrough</td>
8366 <td>
8367 Writethrough hard disks are always attached <b>directly</b>, also as
8368 designed. This also means that writethrough hard disks cannot have
8369 other hard disks linked to them at all.
8370 </td>
8371 </tr>
8372 </table>
8373
8374 Note that the same hard disk, regardless of its type, may be attached to
8375 more than one virtual machine at a time. In this case, the machine that is
8376 started first gains exclusive access to the hard disk and attempts to
8377 start other machines having this hard disk attached will fail until the
8378 first machine is powered down.
8379
8380 Detaching hard disks is performed in a <i>deferred</i> fashion. This means
8381 that the given hard disk remains associated with the given machine after a
8382 successful <link to="IMachine::detachHardDisk2()"/> call until
8383 <link to="IMachine::saveSettings()"/> is called to save all changes to
8384 machine settings to disk. This deferring is necessary to guarantee that
8385 the hard disk configuration may be restored at any time by a call to
8386 <link to="IMachine::discardSettings()"/> before the settings
8387 are saved (committed).
8388
8389 Note that if <link to="IMachine::discardSettings()"/> is called after
8390 indirectly attaching some hard disks to the machine but before a call to
8391 <link to="IMachine::saveSettings()"/> is made, it will implicitly delete
8392 all differencing hard disks implicitly created by
8393 <link to="IMachine::attachHardDisk2()"/> for these indirect attachments.
8394 Such implicitly created hard disks will also be immediately deleted when
8395 detached explicitly using the <link to="IMachine::detachHardDisk2()"/>
8396 call if it is made before <link to="IMachine::saveSettings()"/>. This
8397 implicit deletion is safe because newly created differencing hard
8398 disks do not contain any user data.
8399
8400 However, keep in mind that detaching differencing hard disks that were
8401 implicitly created by <link to="IMachine::attachHardDisk2()"/>
8402 before the last <link to="IMachine::saveSettings()"/> call will
8403 <b>not</b> implicitly delete them as they may already contain some data
8404 (for example, as a result of virtual machine execution). If these hard
8405 disks are no more necessary, the caller can always delete them explicitly
8406 using <link to="#deleteStorage()"/> after they are actually de-associated
8407 from this machine by the <link to="IMachine::saveSettings()"/> call.
8408
8409 <h3>Smart Attachment</h3>
8410
8411 When normal base or immutable hard disks are indirectly attached to a
8412 virtual machine then some additional steps are performed to make sure the
8413 virtual machine will have the most recent "view" of the hard disk being
8414 attached. These steps include walking through the machine's snapshots
8415 starting from the current one and going through ancestors up to the first
8416 snapshot. Hard disks attached to the virtual machine in all
8417 of the encountered snapshots are checked whether they are descendants of
8418 the given normal base or immutable hard disk. The first found child (which
8419 is the differencing hard disk) will be used instead of the normal base or
8420 immutable hard disk as a parent for creating a new differencing hard disk
8421 that will be actually attached to the machine. And only if no descendants
8422 are found or if the virtual machine does not have any snapshots then the
8423 normal base or immutable hard disk will be used itself as a parent for
8424 this differencing hard disk.
8425
8426 It is easier to explain what smart attachment does using the
8427 following example:
8428 <pre>
8429BEFORE attaching B.vdi: AFTER attaching B.vdi:
8430
8431Snapshot 1 (B.vdi) Snapshot 1 (B.vdi)
8432 Snapshot 2 (D1->B.vdi) Snapshot 2 (D1->B.vdi)
8433 Snapshot 3 (D2->D1.vdi) Snapshot 3 (D2->D1.vdi)
8434 Snapshot 4 (none) Snapshot 4 (none)
8435 CurState (none) CurState (D3->D2.vdi)
8436
8437 NOT
8438 ...
8439 CurState (D3->B.vdi)
8440 </pre>
8441 The first column is the virtual machine configuration before the base hard
8442 disk <tt>B.vdi</tt> is attached, the second column shows the machine after
8443 this hard disk is attached. Constructs like <tt>D1->B.vdi</tt> and similar
8444 mean that the hard disk that is actually attached to the machine is a
8445 differencing hard disk, <tt>D1.vdi</tt>, which is linked to (based on)
8446 another hard disk, <tt>B.vdi</tt>.
8447
8448 As we can see from the example, the hard disk <tt>B.vdi</tt> was detached
8449 from the machine before taking Snapshot 4. Later, after Snapshot 4 was
8450 taken, the user decides to attach <tt>B.vdi</tt> again. <tt>B.vdi</tt> has
8451 dependent child hard disks (<tt>D1.vdi</tt>, <tt>D2.vdi</tt>), therefore
8452 it cannot be attached directly and needs an indirect attachment (i.e.
8453 implicit creation of a new differencing hard disk). Due to the smart
8454 attachment procedure, the new differencing hard disk
8455 (<tt>D3.vdi</tt>) will be based on <tt>D2.vdi</tt>, not on
8456 <tt>B.vdi</tt> itself, since <tt>D2.vdi</tt> is the most recent view of
8457 <tt>B.vdi</tt> existing for this snapshot branch of the given virtual
8458 machine.
8459
8460 Note that if there is more than one descendant hard disk of the given base
8461 hard disk found in a snapshot, and there is an exact device, channel and
8462 bus match, then this exact match will be used. Otherwise, the youngest
8463 descendant will be picked up.
8464
8465 There is one more important aspect of the smart attachment procedure which
8466 is not related to snapshots at all. Before walking through the snapshots
8467 as described above, the backup copy of the current list of hard disk
8468 attachment is searched for descendants. This backup copy is created when
8469 the hard disk configuration is changed for the first time after the last
8470 <link to="IMachine::saveSettings()"/> call and used by
8471 <link to="IMachine::discardSettings()"/> to undo the recent hard disk
8472 changes. When such a descendant is found in this backup copy, it will be
8473 simply re-attached back, without creating a new differencing hard disk for
8474 it. This optimization is necessary to make it possible to re-attach the
8475 base or immutable hard disk to a different bus, channel or device slot
8476 without losing the contents of the differencing hard disk actually
8477 attached to the machine in place of it.
8478 </desc>
8479
8480 <attribute name="format" type="wstring" readonly="yes">
8481 <desc>
8482 Storage format of this hard disk.
8483
8484 The value of this attribute is a string that specifies a backend used to
8485 store hard disk data. The storage format is defined when you create a
8486 new hard disk or automatically detected when you open an existing hard
8487 disk medium, and cannot be changed later.
8488
8489 The list of all storage formats supported by this VirtualBox
8490 installation can be obtained using
8491 <link to="ISystemProperties::hardDiskFormats"/>.
8492 </desc>
8493 </attribute>
8494
8495 <attribute name="type" type="HardDiskType">
8496 <desc>
8497 Type (role) of this hard disk.
8498
8499 The following constraints apply when changing the value of this
8500 attribute:
8501 <ul>
8502 <li>If a hard disk is attached to a virtual machine (either in the
8503 current state or in one of the snapshots), its type cannot be
8504 changed.
8505 </li>
8506 <li>As long as the hard disk has children, its type cannot be set
8507 to <link to="HardDiskType_Writethrough"/>.
8508 </li>
8509 <li>The type of all differencing hard disks is
8510 <link to="HardDiskType_Normal"/> and cannot be changed.
8511 </li>
8512 </ul>
8513
8514 The type of a newly created or opened hard disk is set to
8515 <link to="HardDiskType_Normal"/>.
8516 </desc>
8517 </attribute>
8518
8519 <attribute name="parent" type="IHardDisk2" readonly="yes">
8520 <desc>
8521 Parent of this hard disk (a hard disk this hard disk is directly based
8522 on).
8523
8524 Only differencing hard disks have parents. For base (non-differencing)
8525 hard disks, <tt>null</tt> is returned.
8526 </desc>
8527 </attribute>
8528
8529 <attribute name="children" type="IHardDisk2" safearray="yes" readonly="yes">
8530 <desc>
8531 Children of this hard disk (all differencing hard disks directly based
8532 on this hard disk). A <tt>null</tt> array is returned if this hard disk
8533 does not have any children.
8534 </desc>
8535 </attribute>
8536
8537 <attribute name="root" type="IHardDisk2" readonly="yes">
8538 <desc>
8539 Root hard disk of this hard disk.
8540
8541 If this is a differencing hard disk, its root hard disk is the base hard
8542 disk the given hard disk branch starts from. For all other types of hard
8543 disks, this property returns the hard disk object itself (i.e. the same
8544 object this property is read on).
8545 </desc>
8546 </attribute>
8547
8548 <attribute name="readOnly" type="boolean" readonly="yes">
8549 <desc>
8550 Returns <tt>true</tt> if this hard disk is read-only and <tt>false</tt>
8551 otherwise.
8552
8553 A hard disk is considered to be read-only when its contents cannot be
8554 modified without breaking the integrity of other parties that depend on
8555 this hard disk such as its child hard disks or snapshots of virtual
8556 machines where this hard disk is attached to these machines. If there
8557 are no children and no such snapshots then there is no dependency and
8558 the hard disk is not read-only.
8559
8560 The value of this attribute can be used to determine the kind of the
8561 attachment that will take place when attaching this hard disk to a
8562 virtual machine. If the value is <tt>false</tt> then the hard disk will
8563 be attached directly. If the value is <tt>true</tt> then the hard disk
8564 will be attached indirectly by creating a new differencing child hard
8565 disk for that. See the interface description for more information.
8566
8567 Note that all <link to="HardDiskType_Immutable">Immutable</link> hard
8568 disks are always read-only while all
8569 <link to="HardDiskType_Writethrough">Writethrough</link> hard disks are
8570 always not.
8571
8572 <note>
8573 The read-only condition represented by this attribute is related to
8574 the hard disk type and usage, not to the current
8575 <link to="IMedium::state">media state</link> and not to the read-only
8576 state of the storage unit.
8577 </note>
8578 </desc>
8579 </attribute>
8580
8581 <attribute name="logicalSize" type="unsigned long long" readonly="yes">
8582 <desc>
8583 Logical size of this hard disk (in megabytes), as reported to the
8584 guest OS running inside the virtual machine this disk is
8585 attached to. The logical size is defined when the hard disk is created
8586 and cannot be changed later.
8587
8588 <note>
8589 Reading this property on a differencing hard disk will return the size
8590 of its <link to="#root"/> hard disk.
8591 </note>
8592 <note>
8593 For hard disks whose state is <link to="#state"/> is <link
8594 to="MediaState_Inaccessible"/>, the value of this property is the
8595 last known logical size. For <link to="MediaState_NotCreated"/> hard
8596 disks, the returned value is zero.
8597 </note>
8598 </desc>
8599 </attribute>
8600
8601 <!-- storage methods -->
8602
8603 <method name="getProperty">
8604 <desc>
8605 Returns the value of the custom hard disk property with the given name.
8606
8607 The list of all properties supported by the given hard disk format can
8608 be obtained with <link to="IHardDiskFormat::describeProperties()"/>.
8609
8610 Note that if this method returns a <tt>null</tt> @a value, the requested
8611 property is supported but currently not assigned any value.
8612
8613 <result name="VBOX_E_OBJECT_NOT_FOUND">
8614 Requested property does not exist (not supported by the format).
8615 </result>
8616 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
8617 </desc>
8618 <param name="name" type="wstring" dir="in">
8619 <desc>Name of the property to get.</desc>
8620 </param>
8621 <param name="value" type="wstring" dir="return">
8622 <desc>Current property value.</desc>
8623 </param>
8624 </method>
8625
8626 <method name="setProperty">
8627 <desc>
8628 Sets the value of the custom hard disk property with the given name.
8629
8630 The list of all properties supported by the given hard disk format can
8631 be obtained with <link to="IHardDiskFormat::describeProperties()"/>.
8632
8633 Note that setting the property value to <tt>null</tt> is equivalent to
8634 deleting the existing value. A default value (if it is defined for this
8635 property) will be used by the format backend in this case.
8636
8637 <result name="VBOX_E_OBJECT_NOT_FOUND">
8638 Requested property does not exist (not supported by the format).
8639 </result>
8640 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
8641 </desc>
8642 <param name="name" type="wstring" dir="in">
8643 <desc>Name of the property to set.</desc>
8644 </param>
8645 <param name="value" type="wstring" dir="in">
8646 <desc>Property value to set.</desc>
8647 </param>
8648 </method>
8649
8650 <method name="getProperties">
8651 <desc>
8652 Returns values for a group of properties in one call.
8653
8654 The names of the properties to get are specified using the @a names
8655 argument which is a list of comma-separated property names or
8656 <tt>null</tt> if all properties are to be returned. Note that currently
8657 the value of this argument is ignored and the method always returns all
8658 existing properties.
8659
8660 The list of all properties supported by the given hard disk format can
8661 be obtained with <link to="IHardDiskFormat::describeProperties()"/>.
8662
8663 The method returns two arrays, the array of property names corresponding
8664 to the @a names argument and the current values of these properties.
8665 Both arrays have the same number of elements with each elemend at the
8666 given index in the first array corresponds to an element at the same
8667 index in the second array.
8668
8669 Note that for properties that do not have assigned values,
8670 <tt>null</tt> is returned at the appropriate index in the @a
8671 returnValues array.
8672
8673 </desc>
8674 <param name="names" type="wstring" dir="in">
8675 <desc>
8676 Names of properties to get.
8677 </desc>
8678 </param>
8679 <param name="returnNames" type="wstring" safearray="yes" dir="out">
8680 <desc>Names of returned properties.</desc>
8681 </param>
8682 <param name="returnValues" type="wstring" safearray="yes" dir="return">
8683 <desc>Values of returned properties.</desc>
8684 </param>
8685 </method>
8686
8687 <method name="setProperties">
8688 <desc>
8689 Sets values for a group of properties in one call.
8690
8691 The names of the properties to set are passed in the @a names
8692 array along with the new values for them in the @a values array. Both
8693 arrays have the same number of elements with each elemend at the given
8694 index in the first array corresponding to an element at the same index
8695 in the second array.
8696
8697 If there is at least one property name in @a names that is not valid,
8698 the method will fail before changing the values of any other properties
8699 from the @a names array.
8700
8701 Using this method over <link to="#setProperty()"/> is preferred if you
8702 need to set several properties at once since it will result into less
8703 IPC calls.
8704
8705 The list of all properties supported by the given hard disk format can
8706 be obtained with <link to="IHardDiskFormat::describeProperties()"/>.
8707
8708 Note that setting the property value to <tt>null</tt> is equivalent to
8709 deleting the existing value. A default value (if it is defined for this
8710 property) will be used by the format backend in this case.
8711 </desc>
8712 <param name="names" type="wstring" safearray="yes" dir="in">
8713 <desc>Names of properties to set.</desc>
8714 </param>
8715 <param name="values" type="wstring" safearray="yes" dir="in">
8716 <desc>Values of properties to set.</desc>
8717 </param>
8718 </method>
8719
8720 <!-- storage methods -->
8721
8722 <method name="createDynamicStorage">
8723 <desc>
8724 Starts creating a dynamically expanding hard disk storage unit in the
8725 background. The previous storage unit created for this object, if
8726 any, must first be deleted using <link to="#deleteStorage"/>, otherwise
8727 the operation will fail.
8728
8729 Before the operation starts, the hard disk is placed in
8730 <link to="MediaState_Creating"/> state. If the create operation
8731 fails, the media will be placed back in <link to="MediaState_NotCreated"/>
8732 state.
8733
8734 After the returned progress object reports that the operation has
8735 successfully completed, the media state will be set to <link
8736 to="MediaState_Created"/>, the hard disk will be remembered by this
8737 VirtualBox installation and may be attached to virtual machines.
8738
8739 <result name="VBOX_E_NOT_SUPPORTED">
8740 Dynamic storage creation operation is not supported. See <link
8741 to="IHardDiskFormat::capabilities"/>.
8742 </result>
8743 </desc>
8744 <param name="logicalSize" type="unsigned long long" dir="in">
8745 <desc>Maximum logical size of the hard disk in megabytes.</desc>
8746 </param>
8747 <param name="progress" type="IProgress" dir="return">
8748 <desc>Progress object to track the operation completion.</desc>
8749 </param>
8750 </method>
8751
8752 <method name="createFixedStorage">
8753 <desc>
8754 Starts creating a fixed-size hard disk storage unit in the background.
8755 The previous storage unit created for this object, if
8756 any, must be first deleted using <link to="#deleteStorage"/>, otherwise
8757 the operation will fail.
8758
8759 Before the operation starts, the hard disk is placed to
8760 <link to="MediaState_Creating"/> state. If the create operation
8761 fails, the media will placed back to <link to="MediaState_NotCreated"/>
8762 state.
8763
8764 After the returned progress object reports that the operation is
8765 successfully complete, the media state will be set to <link
8766 to="MediaState_Created"/>, the hard disk will be remembered by this
8767 VirtualBox installation and may be attached to virtual machines.
8768
8769 <result name="VBOX_E_NOT_SUPPORTED">
8770 Fixed storage creation operation is not supported. See
8771 <link to="IHardDiskFormat::capabilities"/>.
8772 </result>
8773 </desc>
8774 <param name="logicalSize" type="unsigned long long" dir="in">
8775 <desc>Logical size of the hard disk in megabytes.</desc>
8776 </param>
8777 <param name="progress" type="IProgress" dir="return">
8778 <desc>Progress object to track the operation completion.</desc>
8779 </param>
8780 </method>
8781
8782 <method name="deleteStorage">
8783 <desc>
8784 Starts deleting the storage unit of this hard disk.
8785
8786 The hard disk must not be attached to any known virtual machine and must
8787 not have any known child hard disks, otherwise the operation will fail.
8788 It will also fail if there is no storage unit to delete or if deletion
8789 is already in progress, or if the hard disk is being in use (locked for
8790 read or for write) or inaccessible. Therefore, the only valid state for
8791 this operation to succeed is <link to="MediaState_Created"/>.
8792
8793 Before the operation starts, the hard disk is placed to
8794 <link to="MediaState_Deleting"/> state and gets removed from the list
8795 of remembered hard disks (media registry). If the delete operation
8796 fails, the media will be remembered again and placed back to
8797 <link to="MediaState_Created"/> state.
8798
8799 After the returned progress object reports that the operation is
8800 complete, the media state will be set to
8801 <link to="MediaState_NotCreated"/> and you will be able to use one of
8802 the storage creation methods to create it again.
8803
8804 <see>#close()</see>
8805
8806 <result name="VBOX_E_OBJECT_IN_USE">
8807 Hard disk is attached to a virtual machine.
8808 </result>
8809 <result name="VBOX_E_NOT_SUPPORTED">
8810 Storage deletion is not allowed because neither of storage creation
8811 operations are supported. See
8812 <link to="IHardDiskFormat::capabilities"/>.
8813 </result>
8814
8815 <note>
8816 If the deletion operation fails, it is not guaranteed that the storage
8817 unit still exists. You may check the <link to="IMedium::state"/> value
8818 to answer this question.
8819 </note>
8820 </desc>
8821 <param name="progress" type="IProgress" dir="return">
8822 <desc>Progress object to track the operation completion.</desc>
8823 </param>
8824 </method>
8825
8826 <!-- diff methods -->
8827
8828 <method name="createDiffStorage">
8829 <desc>
8830 Starts creating an empty differencing storage unit based on this hard
8831 disk in the format and at the location defined by the @a target
8832 argument.
8833
8834 The target hard disk must be in <link to="MediaState_NotCreated"/>
8835 state (i.e. must not have an existing storage unit). Upon successful
8836 completion, this operation will set the type of the target hard disk to
8837 <link to="HardDiskType_Normal"/> and create a storage unit necessary to
8838 represent the differencing hard disk data in the given format (according
8839 to the storage format of the target object).
8840
8841 After the returned progress object reports that the operation is
8842 successfully complete, the target hard disk gets remembered by this
8843 VirtualBox installation and may be attached to virtual machines.
8844
8845 <note>
8846 The hard disk will be set to <link to="MediaState_LockedRead"/>
8847 state for the duration of this operation.
8848 </note>
8849 <result name="VBOX_E_OBJECT_IN_USE">
8850 Hard disk not in NotCreated state.
8851 </result>
8852 </desc>
8853 <param name="target" type="IHardDisk2" dir="in">
8854 <desc>Target hard disk.</desc>
8855 </param>
8856 <param name="progress" type="IProgress" dir="return">
8857 <desc>Progress object to track the operation completion.</desc>
8858 </param>
8859 </method>
8860
8861 <method name="mergeTo">
8862 <desc>
8863 Starts merging the contents of this hard disk and all intermediate
8864 differencing hard disks in the chain to the given target hard disk.
8865
8866 The target hard disk must be either a descendant of this hard disk or
8867 its ancestor (otherwise this method will immediately return a failure).
8868 It follows that there are two logical directions of the merge operation:
8869 from ancestor to descendant (<i>forward merge</i>) and from descendant to
8870 ancestor (<i>backward merge</i>). Let us consider the following hard disk
8871 chain:
8872
8873 <pre>Base &lt;- Diff_1 &lt;- Diff_2</pre>
8874
8875 Here, calling this method on the <tt>Base</tt> hard disk object with
8876 <tt>Diff_2</tt> as an argument will be a forward merge; calling it on
8877 <tt>Diff_2</tt> with <tt>Base</tt> as an argument will be a backward
8878 merge. Note that in both cases the contents of the resulting hard disk
8879 will be the same, the only difference is the hard disk object that takes
8880 the result of the merge operation. In case of the forward merge in the
8881 above example, the result will be written to <tt>Diff_2</tt>; in case of
8882 the backward merge, the result will be written to <tt>Base</tt>. In
8883 other words, the result of the operation is always stored in the target
8884 hard disk.
8885
8886 Upon successful operation completion, the storage units of all hard
8887 disks in the chain between this (source) hard disk and the target hard
8888 disk, including the source hard disk itself, will be automatically
8889 deleted and the relevant hard disk objects (including this hard disk)
8890 will become uninitialized. This means that any attempt to call any of
8891 their methods or attributes will fail with the
8892 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error. Applied to the above
8893 example, the forward merge of <tt>Base</tt> to <tt>Diff_2</tt> will
8894 delete and uninitialize both <tt>Base</tt> and <tt>Diff_1</tt> hard
8895 disks. Note that <tt>Diff_2</tt> in this case will become a base hard
8896 disk itself since it will no longer be based on any other hard disk.
8897
8898 Considering the above, all of the following conditions must be met in
8899 order for the merge operation to succeed:
8900 <ul>
8901 <li>
8902 Neither this (source) hard disk nor any intermediate
8903 differencing hard disk in the chain between it and the target
8904 hard disk is attached to any virtual machine.
8905 </li>
8906 <li>
8907 Neither the source hard disk nor the target hard disk is an
8908 <link to="HardDiskType_Immutable"/> hard disk.
8909 </li>
8910 <li>
8911 The part of the hard disk tree from the source hard disk to the
8912 target hard disk is a linear chain, i.e. all hard disks in this
8913 chain have exactly one child which is the next hard disk in this
8914 chain. The only exception from this rule is the target hard disk in
8915 the forward merge operation; it is allowed to have any number of
8916 child hard disks because the merge operation will hot change its
8917 logical contents (as it is seen by the guest OS or by children).
8918 </li>
8919 <li>
8920 None of the involved hard disks are in
8921 <link to="MediaState_LockedRead"/> or
8922 <link to="MediaState_LockedWrite"/> state.
8923 </li>
8924 </ul>
8925
8926 <note>
8927 This (source) hard disk and all intermediates will be placed to <link
8928 to="MediaState_Deleting"/> state and the target hard disk will be
8929 placed to <link to="MediaState_LockedWrite"/> state and for the
8930 duration of this operation.
8931 </note>
8932 </desc>
8933 <param name="targetId" type="uuid" dir="in">
8934 <desc>UUID of the target ancestor or descendant hard disk.</desc>
8935 </param>
8936 <param name="progress" type="IProgress" dir="return">
8937 <desc>Progress object to track the operation completion.</desc>
8938 </param>
8939 </method>
8940
8941 <!-- clone methods -->
8942
8943 <method name="cloneTo">
8944 <desc>
8945 Starts creating a clone of this hard disk in the format and at the
8946 location defined by the @a target argument.
8947
8948 The target hard disk must be in <link to="MediaState_NotCreated"/>
8949 state (i.e. must not have an existing storage unit). Upon successful
8950 completion, the cloned hard disk will contain exactly the same sector
8951 data as the hard disk being cloned, except that a new UUID for the clone
8952 will be randomly generated.
8953
8954 After the returned progress object reports that the operation is
8955 successfully complete, the target hard disk gets remembered by this
8956 VirtualBox installation and may be attached to virtual machines.
8957
8958 <note>
8959 If the cloned hard disk is a differencing hard disk, it will inherit
8960 parent dependency of the original hard disk.
8961 </note>
8962 <note>
8963 This hard disk will be placed to <link to="MediaState_LockedRead"/>
8964 state for the duration of this operation.
8965 </note>
8966 </desc>
8967 <param name="target" type="IHardDisk2" dir="in">
8968 <desc>Target hard disk.</desc>
8969 </param>
8970 <param name="progress" type="IProgress" dir="return">
8971 <desc>Progress object to track the operation completion.</desc>
8972 </param>
8973 </method>
8974
8975 <method name="flattenTo">
8976 <desc>
8977 Starts creating a deep (independent) clone of this hard disk in the
8978 format and at the location defined by the @a target argument.
8979
8980 This operation is similar to <link to="#cloneTo()"/> except that when
8981 applied to a differencing hard disk, it will also copy missing hard disk
8982 data from all parent hard disks it is linked to. This will make the
8983 created clone an independent base hard disk that contains all hard disk
8984 data and does not need any other hard disks to operate.
8985
8986 After the returned progress object reports that the operation is
8987 successfully complete, the target hard disk gets remembered by this
8988 VirtualBox installation and may be attached to virtual machines.
8989
8990 <note>
8991 For base hard disks, this operation is identical to
8992 <link to="#cloneTo()"/>.
8993 </note>
8994 <note>
8995 This hard disk and all its parent hard disks will be placed to <link
8996 to="MediaState_LockedRead"/> state for the duration of this
8997 operation.
8998 </note>
8999 </desc>
9000 <param name="target" type="IHardDisk2" dir="in">
9001 <desc>Target hard disk.</desc>
9002 </param>
9003 <param name="progress" type="IProgress" dir="return">
9004 <desc>Progress object to track the operation completion.</desc>
9005 </param>
9006 </method>
9007
9008 <method name="compact">
9009 <desc>
9010 Starts compacting of this hard disk. This means that the disk is
9011 transformed into a possibly more compact storage representation.
9012 This potentially creates temporary images, which can require a
9013 substantial amount of additional disk space.
9014
9015 After the returned progress object reports that the operation is
9016 successfully complete, the media state will be set back to the
9017 current state.
9018
9019 <note>
9020 This hard disk and all its parent hard disks will be placed to <link
9021 to="MediaState_LockedRead"/> state for the duration of this
9022 operation.
9023 </note>
9024 </desc>
9025 <param name="progress" type="IProgress" dir="return">
9026 <desc>Progress object to track the operation completion.</desc>
9027 </param>
9028 </method>
9029
9030 </interface>
9031
9032
9033 <!--
9034 // IHardDiskFormat
9035 /////////////////////////////////////////////////////////////////////////
9036 -->
9037
9038 <enum
9039 name="DataType"
9040 uuid="d90ea51e-a3f1-4a01-beb1-c1723c0d3ba7"
9041 >
9042 <const name="Int32" value="0"/>
9043 <const name="Int8" value="1"/>
9044 <const name="String" value="2"/>
9045 </enum>
9046
9047 <enum
9048 name="DataFlags"
9049 uuid="86884dcf-1d6b-4f1b-b4bf-f5aa44959d60"
9050 >
9051 <const name="None" value="0x00"/>
9052 <const name="Mandatory" value="0x01"/>
9053 <const name="Expert" value="0x02"/>
9054 <const name="Array" value="0x04"/>
9055 <const name="FlagMask" value="0x07"/>
9056 </enum>
9057
9058 <enum
9059 name="HardDiskFormatCapabilities"
9060 uuid="1df1e4aa-d25a-4ba6-b2a2-02f60eb5903b"
9061 >
9062 <desc>
9063 Hard disk format capability flags.
9064 </desc>
9065
9066 <const name="Uuid" value="0x01">
9067 <desc>
9068 Supports UUIDs as expected by VirtualBox code.
9069 </desc>
9070 </const>
9071
9072 <const name="CreateFixed" value="0x02">
9073 <desc>
9074 Supports creating fixed size images, allocating all space instantly.
9075 </desc>
9076 </const>
9077
9078 <const name="CreateDynamic" value="0x04">
9079 <desc>
9080 Supports creating dynamically growing images, allocating space on
9081 demand.
9082 </desc>
9083 </const>
9084
9085 <const name="CreateSplit2G" value="0x08">
9086 <desc>
9087 Supports creating images split in chunks of a bit less than 2 GBytes.
9088 </desc>
9089 </const>
9090
9091 <const name="Differencing" value="0x10">
9092 <desc>
9093 Supports being used as a format for differencing hard disks (see <link
9094 to="IHardDisk2::createDiffStorage"/>).
9095 </desc>
9096 </const>
9097
9098 <const name="Asynchronous" value="0x20">
9099 <desc>
9100 Supports asynchronous I/O operations for at least some configurations.
9101 </desc>
9102 </const>
9103
9104 <const name="File" value="0x40">
9105 <desc>
9106 The format backend operates on files (the <link to="IMedium::location"/>
9107 attribute of the hard disk specifies a file used to store hard disk
9108 data; for a list of supported file extensions see
9109 <link to="IHardDiskFormat::fileExtensions"/>).
9110 </desc>
9111 </const>
9112
9113 <const name="Properties" value="0x80">
9114 <desc>
9115 The format backend uses the property interface to configure the storage
9116 location and properties (the <link to="IHardDiskFormat::describeProperties"/>
9117 method is used to get access to properties supported by the given hard
9118 disk format).
9119 </desc>
9120 </const>
9121
9122 <const name="CapabilityMask" value="0xFF"/>
9123 </enum>
9124
9125 <interface
9126 name="IHardDiskFormat" extends="$unknown"
9127 uuid="7f3ba790-3a0b-4a8a-bac2-bb50150123c5"
9128 wsmap="managed"
9129 >
9130 <desc>
9131 The IHardDiskFormat interface represents a virtual hard disk format.
9132
9133 Each hard disk format has an associated backend which is used to handle
9134 hard disks stored in this format. This interface provides information
9135 about the properties of the associated backend.
9136
9137 Each hard disk format is identified by a string represented by the
9138 <link to="#id"/> attribute. This string is used in calls like
9139 <link to="IVirtualBox::createHardDisk2()"/> to specify the desired
9140 format.
9141
9142 The list of all supported hard disk formats can be obtained using
9143 <link to="ISystemProperties::hardDiskFormats"/>.
9144
9145 <see>IHardDisk2</see>
9146 </desc>
9147
9148 <attribute name="id" type="wstring" readonly="yes">
9149 <desc>
9150 Identifier of this format.
9151
9152 The format identifier is a non-null non-empty ASCII string. Note that
9153 this string is case-insensitive. This means that, for example, all of
9154 the following strings:
9155 <pre>
9156 "VDI"
9157 "vdi"
9158 "VdI"</pre>
9159 refer to the same hard disk format.
9160
9161 This string is used in methods of other interfaces where it is necessary
9162 to specify a hard disk format, such as
9163 <link to="IVirtualBox::createHardDisk2()"/>.
9164 </desc>
9165 </attribute>
9166
9167 <attribute name="name" type="wstring" readonly="yes">
9168 <desc>
9169 Human readable description of this format.
9170
9171 Mainly for use in file open dialogs.
9172 </desc>
9173 </attribute>
9174
9175 <attribute name="fileExtensions" type="wstring" safearray="yes" readonly="yes">
9176 <desc>
9177 Array of strings containing the supported file extensions.
9178
9179 The first extension in the array is the extension preferred by the
9180 backend. It is recommended to use this extension when specifying a
9181 location of the storage unit for a new hard disk.
9182
9183 Note that some backends do not work on files, so this array may be
9184 empty.
9185
9186 <see>IHardDiskFormat::capabilities</see>
9187 </desc>
9188 </attribute>
9189
9190 <attribute name="capabilities" type="unsigned long" readonly="yes">
9191 <desc>
9192 Capabilities of the format as a set of bit flags.
9193
9194 For the meaning of individual capability flags see
9195 <link to="HardDiskFormatCapabilities"/>.
9196 </desc>
9197 </attribute>
9198
9199 <method name="describeProperties">
9200 <desc>
9201 Returns several arrays describing the properties supported by this
9202 format.
9203
9204 An element with the given index in each array describes one
9205 property. Thus, the number of elements in each returned array is the
9206 same and corresponds to the number of supported properties.
9207
9208 The returned arrays are filled in only if the
9209 <link to="HardDiskFormatCapabilities_Properties"/> flag is set.
9210 All arguments must be non-NULL.
9211
9212 <see>DataType</see>
9213 <see>DataFlags</see>
9214 </desc>
9215
9216 <param name="names" type="wstring" safearray="yes" dir="out">
9217 <desc>Array of property names.</desc>
9218 </param>
9219 <param name="description" type="wstring" safearray="yes" dir="out">
9220 <desc>Array of property descriptions.</desc>
9221 </param>
9222 <param name="types" type="DataType" safearray="yes" dir="out">
9223 <desc>Array of property types.</desc>
9224 </param>
9225 <param name="flags" type="unsigned long" safearray="yes" dir="out">
9226 <desc>Array of property flags.</desc>
9227 </param>
9228 <param name="defaults" type="wstring" safearray="yes" dir="out">
9229 <desc>Array of default property values.</desc>
9230 </param>
9231 </method>
9232
9233 </interface>
9234
9235
9236 <!--
9237 // IFloppyImage2
9238 /////////////////////////////////////////////////////////////////////////
9239 -->
9240
9241 <interface
9242 name="IFloppyImage2" extends="IMedium"
9243 uuid="fcdee8f0-03f9-11dd-95ff-0800200c9a66"
9244 wsmap="managed"
9245 >
9246 <desc>
9247 The IFloppyImage2 interface represents a medium containing the image
9248 of a floppy disk.
9249 </desc>
9250
9251 </interface>
9252
9253
9254 <!--
9255 // IDVDImage2
9256 /////////////////////////////////////////////////////////////////////////
9257 -->
9258
9259 <interface
9260 name="IDVDImage2" extends="IMedium"
9261 uuid="1c5165f1-9543-478d-a117-84a1d2317068"
9262 wsmap="managed"
9263 >
9264 <desc>
9265 The IDVDImage2 interface represents a medium containing the image
9266 of a CD or DVD disk in the ISO format.
9267 </desc>
9268
9269 </interface>
9270
9271
9272 <!--
9273 // IDVDDrive
9274 /////////////////////////////////////////////////////////////////////////
9275 -->
9276
9277 <interface
9278 name="IDVDDrive" extends="$unknown"
9279 uuid="d650ef30-be9b-4dae-b463-11d5824681a5"
9280 wsmap="managed"
9281 >
9282 <desc>
9283 The IDVDDrive interface represents the virtual CD/DVD drive of the
9284 virtual machine. An object of this type is returned by
9285 <link to="IMachine::DVDDrive"/>.
9286 </desc>
9287
9288 <attribute name="state" type="DriveState" readonly="yes">
9289 <desc>Current drive state.</desc>
9290 </attribute>
9291
9292 <attribute name="passthrough" type="boolean">
9293 <desc>
9294 When a host drive is mounted and passthrough is enabled
9295 the guest OS will be able to directly send SCSI commands to
9296 the host drive. This enables the guest OS to use CD/DVD writers
9297 but is potentially dangerous.
9298 </desc>
9299 </attribute>
9300
9301 <method name="mountImage">
9302 <desc>Mounts a CD/DVD image with the specified UUID.
9303
9304 <result name="VBOX_E_FILE_ERROR">
9305 Invalid image file location.
9306 </result>
9307 <result name="VBOX_E_OBJECT_NOT_FOUND">
9308 Could not find a CD/DVD image matching @a imageID.
9309 </result>
9310 <result name="VBOX_E_INVALID_OBJECT_STATE">
9311 Invalid media state.
9312 </result>
9313
9314 </desc>
9315 <param name="imageId" type="uuid" dir="in"/>
9316 </method>
9317
9318 <method name="captureHostDrive">
9319 <desc>Captures the specified host CD/DVD drive.</desc>
9320 <param name="drive" type="IHostDVDDrive" dir="in"/>
9321 </method>
9322
9323 <method name="unmount">
9324 <desc>Unmounts the currently mounted image or host drive.</desc>
9325 </method>
9326
9327 <method name="getImage">
9328 <desc>Returns the currently mounted CD/DVD image.</desc>
9329 <param name="image" type="IDVDImage2" dir="return"/>
9330 </method>
9331
9332 <method name="getHostDrive">
9333 <desc>Returns the currently mounted host CD/DVD drive.</desc>
9334 <param name="drive" type="IHostDVDDrive" dir="return"/>
9335 </method>
9336
9337 </interface>
9338
9339
9340 <!--
9341 // IFloppyDrive
9342 /////////////////////////////////////////////////////////////////////////
9343 -->
9344
9345 <interface
9346 name="IFloppyDrive" extends="$unknown"
9347 uuid="159412cd-bab8-452e-8097-218a020825a6"
9348 wsmap="managed"
9349 >
9350 <desc>
9351 The IFloppyDrive interface represents the virtual floppy drive of the
9352 virtual machine. An object of this type is returned by
9353 <link to="IMachine::floppyDrive" />.
9354 </desc>
9355
9356 <attribute name="enabled" type="boolean">
9357 <desc>
9358 Flag whether the floppy drive is enabled. If it is disabled,
9359 the floppy drive will not be reported to the guest OS.
9360 </desc>
9361 </attribute>
9362
9363 <attribute name="state" type="DriveState" readonly="yes">
9364 <desc>Current drive state.</desc>
9365 </attribute>
9366
9367 <method name="mountImage">
9368 <desc>Mounts a floppy image with the specified UUID.
9369
9370 <result name="VBOX_E_FILE_ERROR">
9371 Invalid image file location.
9372 </result>
9373 <result name="VBOX_E_OBJECT_NOT_FOUND">
9374 Could not find a floppy image matching @a imageID.
9375 </result>
9376 <result name="VBOX_E_INVALID_OBJECT_STATE">
9377 Invalid media state.
9378 </result>
9379
9380 </desc>
9381 <param name="imageId" type="uuid" dir="in"/>
9382 </method>
9383
9384 <method name="captureHostDrive">
9385 <desc>Captures the specified host floppy drive.</desc>
9386 <param name="drive" type="IHostFloppyDrive" dir="in"/>
9387 </method>
9388
9389 <method name="unmount">
9390 <desc>Unmounts the currently mounted image or host drive.</desc>
9391 </method>
9392
9393 <method name="getImage">
9394 <desc>Returns the currently mounted floppy image.</desc>
9395 <param name="image" type="IFloppyImage2" dir="return"/>
9396 </method>
9397
9398 <method name="getHostDrive">
9399 <desc>Returns the currently mounted host floppy drive.</desc>
9400 <param name="drive" type="IHostFloppyDrive" dir="return"/>
9401 </method>
9402
9403 </interface>
9404
9405
9406 <!--
9407 // IKeyboard
9408 /////////////////////////////////////////////////////////////////////////
9409 -->
9410
9411 <interface
9412 name="IKeyboard" extends="$unknown"
9413 uuid="2d1a531b-4c6e-49cc-8af6-5c857b78b5d7"
9414 wsmap="managed"
9415 >
9416 <desc>
9417 The IKeyboard interface represents the virtual machine's keyboard. Used
9418 in <link to="IConsole::keyboard"/>.
9419
9420 Use this interface to send keystrokes or the Ctrl-Alt-Del sequence
9421 to the virtual machine.
9422
9423 </desc>
9424 <method name="putScancode">
9425 <desc>Sends a scancode to the keyboard.
9426
9427 <result name="VBOX_E_IPRT_ERROR">
9428 Could not send scan code to virtual keyboard.
9429 </result>
9430
9431 </desc>
9432 <param name="scancode" type="long" dir="in"/>
9433 </method>
9434
9435 <method name="putScancodes">
9436 <desc>Sends an array of scancodes to the keyboard.
9437
9438 <result name="VBOX_E_IPRT_ERROR">
9439 Could not send all scan codes to virtual keyboard.
9440 </result>
9441
9442 </desc>
9443 <param name="scancodes" type="long" dir="in" safearray="yes"/>
9444 <param name="codesStored" type="unsigned long" dir="return"/>
9445 </method>
9446
9447 <method name="putCAD">
9448 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard. This
9449 function is nothing special, it is just a convenience function
9450 calling <link to="IKeyboard::putScancodes"/> with the proper scancodes.
9451
9452 <result name="VBOX_E_IPRT_ERROR">
9453 Could not send all scan codes to virtual keyboard.
9454 </result>
9455
9456 </desc>
9457 </method>
9458
9459 </interface>
9460
9461
9462 <!--
9463 // IMouse
9464 /////////////////////////////////////////////////////////////////////////
9465 -->
9466
9467 <enum
9468 name="MouseButtonState"
9469 uuid="03131722-2EC5-4173-9794-0DACA46673EF"
9470 >
9471 <desc>
9472 Mouse button state.
9473 </desc>
9474
9475 <const name="LeftButton" value="0x01"/>
9476 <const name="RightButton" value="0x02"/>
9477 <const name="MiddleButton" value="0x04"/>
9478 <const name="WheelUp" value="0x08"/>
9479 <const name="WheelDown" value="0x10"/>
9480 <const name="MouseStateMask" value="0x1F"/>
9481 </enum>
9482
9483 <interface
9484 name="IMouse" extends="$unknown"
9485 uuid="FD443EC1-0006-4F5B-9282-D72760A66916"
9486 wsmap="managed"
9487 >
9488 <desc>
9489 The IMouse interface represents the virtual machine's mouse. Used in
9490 <link to="IConsole::mouse"/>.
9491
9492 Through this interface, the virtual machine's virtual mouse can be
9493 controlled.
9494 </desc>
9495
9496 <attribute name="absoluteSupported" type="boolean" readonly="yes">
9497 <desc>
9498 Whether the guest OS supports absolute mouse pointer positioning
9499 or not.
9500 <note>
9501 VirtualBox Guest Tools need to be installed to the guest OS
9502 in order to enable absolute mouse positioning support.
9503 You can use the <link to="IConsoleCallback::onMouseCapabilityChange"/>
9504 callback to be instantly informed about changes of this attribute
9505 during virtual machine execution.
9506 </note>
9507 <see><link to="#putMouseEventAbsolute"/></see>
9508 </desc>
9509 </attribute>
9510
9511 <method name="putMouseEvent">
9512 <desc>
9513 Initiates a mouse event using relative pointer movements
9514 along x and y axis.
9515
9516 <result name="E_ACCESSDENIED">
9517 Console not powered up.
9518 </result>
9519 <result name="VBOX_E_IPRT_ERROR">
9520 Could not send mouse event to virtual mouse.
9521 </result>
9522
9523 </desc>
9524
9525 <param name="dx" type="long" dir="in">
9526 <desc>
9527 Amount of pixels the mouse should move to the right.
9528 Negative values move the mouse to the left.
9529 </desc>
9530 </param>
9531 <param name="dy" type="long" dir="in">
9532 <desc>
9533 Amount of pixels the mouse should move downwards.
9534 Negative values move the mouse upwards.
9535 </desc>
9536 </param>
9537 <param name="dz" type="long" dir="in">
9538 <desc>
9539 Amount of mouse wheel moves.
9540 Positive values describe clockwise wheel rotations,
9541 negative values describe counterclockwise rotations.
9542 </desc>
9543 </param>
9544 <param name="buttonState" type="long" dir="in">
9545 <desc>
9546 The current state of mouse buttons. Every bit represents
9547 a mouse button as follows:
9548 <table>
9549 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
9550 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
9551 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
9552 </table>
9553 A value of <tt>1</tt> means the corresponding button is pressed.
9554 otherwise it is released.
9555 </desc>
9556 </param>
9557 </method>
9558
9559 <method name="putMouseEventAbsolute">
9560 <desc>
9561 Positions the mouse pointer using absolute x and y coordinates.
9562 These coordinates are expressed in pixels and
9563 start from <tt>[1,1]</tt> which corresponds to the top left
9564 corner of the virtual display.
9565
9566 <result name="E_ACCESSDENIED">
9567 Console not powered up.
9568 </result>
9569 <result name="VBOX_E_IPRT_ERROR">
9570 Could not send mouse event to virtual mouse.
9571 </result>
9572
9573 <note>
9574 This method will have effect only if absolute mouse
9575 positioning is supported by the guest OS.
9576 </note>
9577
9578 <see><link to="#absoluteSupported"/></see>
9579 </desc>
9580
9581 <param name="x" type="long" dir="in">
9582 <desc>
9583 X coordinate of the pointer in pixels, starting from <tt>1</tt>.
9584 </desc>
9585 </param>
9586 <param name="y" type="long" dir="in">
9587 <desc>
9588 Y coordinate of the pointer in pixels, starting from <tt>1</tt>.
9589 </desc>
9590 </param>
9591 <param name="dz" type="long" dir="in">
9592 <desc>
9593 Amount of mouse wheel moves.
9594 Positive values describe clockwise wheel rotations,
9595 negative values describe counterclockwise rotations.
9596 </desc>
9597 </param>
9598 <param name="buttonState" type="long" dir="in">
9599 <desc>
9600 The current state of mouse buttons. Every bit represents
9601 a mouse button as follows:
9602 <table>
9603 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
9604 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
9605 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
9606 </table>
9607 A value of <tt>1</tt> means the corresponding button is pressed.
9608 otherwise it is released.
9609 </desc>
9610 </param>
9611 </method>
9612
9613 </interface>
9614
9615 <!--
9616 // IDisplay
9617 /////////////////////////////////////////////////////////////////////////
9618 -->
9619
9620 <enum
9621 name="FramebufferAccelerationOperation"
9622 uuid="f0e5ebbe-dc8e-4e2d-916e-53baa3844df8"
9623 >
9624 <desc>
9625 Frame buffer acceleration operation.
9626 </desc>
9627
9628 <const name="SolidFillAcceleration" value="1"/>
9629 <const name="ScreenCopyAcceleration" value="2"/>
9630 </enum>
9631
9632 <enum
9633 name="FramebufferPixelFormat"
9634 uuid="7acfd5ed-29e3-45e3-8136-73c9224f3d2d"
9635 >
9636 <desc>
9637 Format of the video memory buffer. Constants represented by this enum can
9638 be used to test for particular values of <link
9639 to="IFramebuffer::pixelFormat"/>. See also <link
9640 to="IFramebuffer::requestResize()"/>.
9641
9642 See also www.fourcc.org for more information about FOURCC pixel formats.
9643 </desc>
9644
9645 <const name="Opaque" value="0">
9646 <desc>
9647 Unknown buffer format (the user may not assume any particular format of
9648 the buffer).
9649 </desc>
9650 </const>
9651 <const name="FOURCC_RGB" value="0x32424752">
9652 <desc>
9653 Basic RGB format (<link to="IFramebuffer::bitsPerPixel"/> determines the
9654 bit layout).
9655 </desc>
9656 </const>
9657 </enum>
9658
9659 <interface
9660 name="IFramebuffer" extends="$unknown"
9661 uuid="af431304-5b09-40e2-94da-3c3cb03822c1"
9662 wsmap="suppress"
9663 >
9664 <attribute name="address" type="octet" mod="ptr" readonly="yes">
9665 <desc>Address of the start byte of the frame buffer.</desc>
9666 </attribute>
9667
9668 <attribute name="width" type="unsigned long" readonly="yes">
9669 <desc>Frame buffer width, in pixels.</desc>
9670 </attribute>
9671
9672 <attribute name="height" type="unsigned long" readonly="yes">
9673 <desc>Frame buffer height, in pixels.</desc>
9674 </attribute>
9675
9676 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
9677 <desc>
9678 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
9679 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, valid values
9680 are: 8, 15, 16, 24 and 32.
9681 </desc>
9682 </attribute>
9683
9684 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
9685 <desc>
9686 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
9687 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, the
9688 size of the scan line must be aligned to 32 bits.
9689 </desc>
9690 </attribute>
9691
9692 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
9693 <desc>
9694 Frame buffer pixel format. It's either one of the values defined by <link
9695 to="FramebufferPixelFormat"/> or a raw FOURCC code.
9696 <note>
9697 This attribute must never return <link
9698 to="FramebufferPixelFormat_Opaque"/> -- the format of the buffer
9699 <link to="#address"/> points to must be always known.
9700 </note>
9701 </desc>
9702 </attribute>
9703
9704 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
9705 <desc>
9706 Defines whether this frame buffer uses the virtual video card's memory
9707 buffer (guest VRAM) directly or not. See <link
9708 to="IFramebuffer::requestResize()"/> for more information.
9709 </desc>
9710 </attribute>
9711
9712 <attribute name="heightReduction" type="unsigned long" readonly="yes">
9713 <desc>
9714 Hint from the frame buffer about how much of the standard
9715 screen height it wants to use for itself. This information is
9716 exposed to the guest through the VESA BIOS and VMMDev interface
9717 so that it can use it for determining its video mode table. It
9718 is not guaranteed that the guest respects the value.
9719 </desc>
9720 </attribute>
9721
9722 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
9723 <desc>
9724 An alpha-blended overlay which is superposed over the frame buffer.
9725 The initial purpose is to allow the display of icons providing
9726 information about the VM state, including disk activity, in front
9727 ends which do not have other means of doing that. The overlay is
9728 designed to controlled exclusively by IDisplay. It has no locking
9729 of its own, and any changes made to it are not guaranteed to be
9730 visible until the affected portion of IFramebuffer is updated. The
9731 overlay can be created lazily the first time it is requested. This
9732 attribute can also return NULL to signal that the overlay is not
9733 implemented.
9734 </desc>
9735 </attribute>
9736
9737 <attribute name="winId" type="unsigned long long" readonly="yes">
9738 <desc>
9739 Platform-dependent identifier of the window where context of this
9740 frame buffer is drawn, or zero if there's no such window.
9741 </desc>
9742 </attribute>
9743
9744 <method name="lock">
9745 <desc>
9746 Locks the frame buffer.
9747 Gets called by the IDisplay object where this frame buffer is
9748 bound to.
9749 </desc>
9750 </method>
9751
9752 <method name="unlock">
9753 <desc>
9754 Unlocks the frame buffer.
9755 Gets called by the IDisplay object where this frame buffer is
9756 bound to.
9757 </desc>
9758 </method>
9759
9760 <method name="notifyUpdate">
9761 <desc>
9762 Informs about an update.
9763 Gets called by the display object where this buffer is
9764 registered.
9765 </desc>
9766 <param name="x" type="unsigned long" dir="in"/>
9767 <param name="y" type="unsigned long" dir="in"/>
9768 <param name="width" type="unsigned long" dir="in"/>
9769 <param name="height" type="unsigned long" dir="in"/>
9770 <param name="finished" type="boolean" dir="return"/>
9771 </method>
9772
9773 <method name="requestResize">
9774 <desc>
9775 Requests a size and pixel format change.
9776
9777 There are two modes of working with the video buffer of the virtual
9778 machine. The <i>indirect</i> mode implies that the IFramebuffer
9779 implementation allocates a memory buffer for the requested display mode
9780 and provides it to the virtual machine. In <i>direct</i> mode, the
9781 IFramebuffer implementation uses the memory buffer allocated and owned
9782 by the virtual machine. This buffer represents the video memory of the
9783 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
9784 usually faster because the implementation gets a raw pointer to the
9785 guest VRAM buffer which it can directly use for visualizing the contents
9786 of the virtual display, as opposed to the indirect mode where the
9787 contents of guest VRAM are copied to the memory buffer provided by
9788 the implementation every time a display update occurs.
9789
9790 It is important to note that the direct mode is really fast only when
9791 the implementation uses the given guest VRAM buffer directly, for
9792 example, by blitting it to the window representing the virtual machine's
9793 display, which saves at least one copy operation comparing to the
9794 indirect mode. However, using the guest VRAM buffer directly is not
9795 always possible: the format and the color depth of this buffer may be
9796 not supported by the target window, or it may be unknown (opaque) as in
9797 case of text or non-linear multi-plane VGA video modes. In this case,
9798 the indirect mode (that is always available) should be used as a
9799 fallback: when the guest VRAM contents are copied to the
9800 implementation-provided memory buffer, color and format conversion is
9801 done automatically by the underlying code.
9802
9803 The @a pixelFormat parameter defines whether the direct mode is
9804 available or not. If @a pixelFormat is <link
9805 to="FramebufferPixelFormat_Opaque"/> then direct access to the guest
9806 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and @a
9807 bytesPerLine parameters must be ignored and the implementation must use
9808 the indirect mode (where it provides its own buffer in one of the
9809 supported formats). In all other cases, @a pixelFormat together with @a
9810 bitsPerPixel and @a bytesPerLine define the format of the video memory
9811 buffer pointed to by the @a VRAM parameter and the implementation is
9812 free to choose which mode to use. To indicate that this frame buffer uses
9813 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
9814 attribute must return <tt>true</tt> and <link to="#address"/> must
9815 return exactly the same address that is passed in the @a VRAM parameter
9816 of this method; otherwise it is assumed that the indirect strategy is
9817 chosen.
9818
9819 The @a width and @a height parameters represent the size of the
9820 requested display mode in both modes. In case of indirect mode, the
9821 provided memory buffer should be big enough to store data of the given
9822 display mode. In case of direct mode, it is guaranteed that the given @a
9823 VRAM buffer contains enough space to represent the display mode of the
9824 given size. Note that this frame buffer's <link to="#width"/> and <link
9825 to="#height"/> attributes must return exactly the same values as
9826 passed to this method after the resize is completed (see below).
9827
9828 The @a finished output parameter determines if the implementation has
9829 finished resizing the frame buffer or not. If, for some reason, the
9830 resize cannot be finished immediately during this call, @a finished
9831 must be set to @c false, and the implementation must call
9832 <link to="IDisplay::resizeCompleted()"/> after it has returned from
9833 this method as soon as possible. If @a finished is @c false, the
9834 machine will not call any frame buffer methods until
9835 <link to="IDisplay::resizeCompleted()"/> is called.
9836
9837 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
9838 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
9839 this frame buffer must return exactly the same values as specified in the
9840 parameters of this method, after the resize is completed. If the
9841 indirect mode is chosen, these attributes must return values describing
9842 the format of the implementation's own memory buffer <link
9843 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
9844 value must always correlate with <link to="#pixelFormat"/>. Note that
9845 the <link to="#pixelFormat"/> attribute must never return <link
9846 to="FramebufferPixelFormat_Opaque"/> regardless of the selected mode.
9847
9848 <note>
9849 This method is called by the IDisplay object under the
9850 <link to="#lock()"/> provided by this IFramebuffer
9851 implementation. If this method returns @c false in @a finished, then
9852 this lock is not released until
9853 <link to="IDisplay::resizeCompleted()"/> is called.
9854 </note>
9855 </desc>
9856 <param name="screenId" type="unsigned long" dir="in">
9857 <desc>
9858 Logical screen number. Must be used in the corresponding call to
9859 <link to="IDisplay::resizeCompleted()"/> if this call is made.
9860 </desc>
9861 </param>
9862 <param name="pixelFormat" type="unsigned long" dir="in">
9863 <desc>
9864 Pixel format of the memory buffer pointed to by @a VRAM.
9865 See also <link to="FramebufferPixelFormat"/>.
9866 </desc>
9867 </param>
9868 <param name="VRAM" type="octet" mod="ptr" dir="in">
9869 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
9870 </param>
9871 <param name="bitsPerPixel" type="unsigned long" dir="in">
9872 <desc>Color depth, bits per pixel.</desc>
9873 </param>
9874 <param name="bytesPerLine" type="unsigned long" dir="in">
9875 <desc>Size of one scan line, in bytes.</desc>
9876 </param>
9877 <param name="width" type="unsigned long" dir="in">
9878 <desc>Width of the guest display, in pixels.</desc>
9879 </param>
9880 <param name="height" type="unsigned long" dir="in">
9881 <desc>Height of the guest display, in pixels.</desc>
9882 </param>
9883 <param name="finished" type="boolean" dir="return">
9884 <desc>
9885 Can the VM start using the new frame buffer immediately
9886 after this method returns or it should wait for
9887 <link to="IDisplay::resizeCompleted()"/>.
9888 </desc>
9889 </param>
9890 </method>
9891
9892 <method name="operationSupported">
9893 <desc>
9894 Returns whether the given acceleration operation is supported
9895 by the IFramebuffer implementation. If not, the display object
9896 will not attempt to call the corresponding IFramebuffer entry
9897 point. Even if an operation is indicated as supported, the
9898 IFramebuffer implementation always has the option to return non
9899 supported from the corresponding acceleration method in which
9900 case the operation will be performed by the display engine. This
9901 allows for reduced IFramebuffer implementation complexity where
9902 only common cases are handled.
9903 </desc>
9904 <param name="operation" type="FramebufferAccelerationOperation" dir="in"/>
9905 <param name="supported" type="boolean" dir="return"/>
9906 </method>
9907
9908 <method name="videoModeSupported">
9909 <desc>
9910 Returns whether the frame buffer implementation is willing to
9911 support a given video mode. In case it is not able to render
9912 the video mode (or for some reason not willing), it should
9913 return false. Usually this method is called when the guest
9914 asks the VMM device whether a given video mode is supported
9915 so the information returned is directly exposed to the guest.
9916 It is important that this method returns very quickly.
9917 </desc>
9918 <param name="width" type="unsigned long" dir="in"/>
9919 <param name="height" type="unsigned long" dir="in"/>
9920 <param name="bpp" type="unsigned long" dir="in"/>
9921 <param name="supported" type="boolean" dir="return"/>
9922 </method>
9923
9924 <method name="solidFill">
9925 <desc>
9926 Fills the specified rectangle on screen with a solid color.
9927 </desc>
9928 <param name="x" type="unsigned long" dir="in"/>
9929 <param name="y" type="unsigned long" dir="in"/>
9930 <param name="width" type="unsigned long" dir="in"/>
9931 <param name="height" type="unsigned long" dir="in"/>
9932 <param name="color" type="unsigned long" dir="in"/>
9933 <param name="handled" type="boolean" dir="return"/>
9934 </method>
9935
9936 <method name="copyScreenBits">
9937 <desc>
9938 Copies specified rectangle on the screen.
9939 </desc>
9940 <param name="xDst" type="unsigned long" dir="in"/>
9941 <param name="yDst" type="unsigned long" dir="in"/>
9942 <param name="xSrc" type="unsigned long" dir="in"/>
9943 <param name="ySrc" type="unsigned long" dir="in"/>
9944 <param name="width" type="unsigned long" dir="in"/>
9945 <param name="height" type="unsigned long" dir="in"/>
9946 <param name="handled" type="boolean" dir="return"/>
9947 </method>
9948
9949 <method name="getVisibleRegion">
9950 <desc>
9951 Returns the visible region of this frame buffer.
9952
9953 If the @a rectangles parameter is <tt>NULL</tt> then the value of the
9954 @a count parameter is ignored and the number of elements necessary to
9955 describe the current visible region is returned in @a countCopied.
9956
9957 If @a rectangles is not <tt>NULL</tt> but @a count is less
9958 than the required number of elements to store region data, the method
9959 will report a failure. If @a count is equal or greater than the
9960 required number of elements, then the actual number of elements copied
9961 to the provided array will be returned in @a countCopied.
9962
9963 <note>
9964 The address of the provided array must be in the process space of
9965 this IFramebuffer object.
9966 </note>
9967 <note>
9968 Method not yet implemented.
9969 </note>
9970 </desc>
9971 <param name="rectangles" type="octet" mod="ptr" dir="in">
9972 <desc>Pointer to the <tt>RTRECT</tt> array to receive region data.</desc>
9973 </param>
9974 <param name="count" type="unsigned long" dir="in">
9975 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
9976 </param>
9977 <param name="countCopied" type="unsigned long" dir="return">
9978 <desc>Number of elements copied to the @a rectangles array.</desc>
9979 </param>
9980 </method>
9981
9982 <method name="setVisibleRegion">
9983 <desc>
9984 Suggests a new visible region to this frame buffer. This region
9985 represents the area of the VM display which is a union of regions of
9986 all top-level windows of the guest operating system running inside the
9987 VM (if the Guest Additions for this system support this
9988 functionality). This information may be used by the frontends to
9989 implement the seamless desktop integration feature.
9990
9991 <note>
9992 The address of the provided array must be in the process space of
9993 this IFramebuffer object.
9994 </note>
9995 <note>
9996 The IFramebuffer implementation must make a copy of the provided
9997 array of rectangles.
9998 </note>
9999 <note>
10000 Method not yet implemented.
10001 </note>
10002 </desc>
10003 <param name="rectangles" type="octet" mod="ptr" dir="in">
10004 <desc>Pointer to the <tt>RTRECT</tt> array.</desc>
10005 </param>
10006 <param name="count" type="unsigned long" dir="in">
10007 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10008 </param>
10009 </method>
10010
10011 </interface>
10012
10013 <interface
10014 name="IFramebufferOverlay" extends="IFramebuffer"
10015 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
10016 wsmap="suppress"
10017 >
10018 <desc>
10019 The IFramebufferOverlay interface represents an alpha blended overlay
10020 for displaying status icons above an IFramebuffer. It is always created
10021 not visible, so that it must be explicitly shown. It only covers a
10022 portion of the IFramebuffer, determined by its width, height and
10023 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
10024 that order) format, and may be written to directly. Do re-read the
10025 width though, after setting it, as it may be adjusted (increased) to
10026 make it more suitable for the front end.
10027 </desc>
10028 <attribute name="x" type="unsigned long" readonly="yes">
10029 <desc>X position of the overlay, relative to the frame buffer.</desc>
10030 </attribute>
10031
10032 <attribute name="y" type="unsigned long" readonly="yes">
10033 <desc>Y position of the overlay, relative to the frame buffer.</desc>
10034 </attribute>
10035
10036 <attribute name="visible" type="boolean" readonly="no">
10037 <desc>
10038 Whether the overlay is currently visible.
10039 </desc>
10040 </attribute>
10041
10042 <attribute name="alpha" type="unsigned long" readonly="no">
10043 <desc>
10044 The global alpha value for the overlay. This may or may not be
10045 supported by a given front end.
10046 </desc>
10047 </attribute>
10048
10049 <method name="move">
10050 <desc>
10051 Changes the overlay's position relative to the IFramebuffer.
10052 </desc>
10053 <param name="x" type="unsigned long" dir="in"/>
10054 <param name="y" type="unsigned long" dir="in"/>
10055 </method>
10056
10057 </interface>
10058
10059 <interface
10060 name="IDisplay" extends="$unknown"
10061 uuid="09789f63-4525-48e5-a5e4-1080453b0eab"
10062 wsmap="suppress"
10063 >
10064 <desc>
10065 The IDisplay interface represents the virtual machine's display.
10066
10067 The object implementing this interface is contained in each
10068 <link to="IConsole::display"/> attribute and represents the visual
10069 output of the virtual machine.
10070
10071 The virtual display supports pluggable output targets represented by the
10072 IFramebuffer interface. Examples of the output target are a window on
10073 the host computer or an RDP session's display on a remote computer.
10074 </desc>
10075 <attribute name="width" type="unsigned long" readonly="yes">
10076 <desc>Current display width.</desc>
10077 </attribute>
10078
10079 <attribute name="height" type="unsigned long" readonly="yes">
10080 <desc>Current display height.</desc>
10081 </attribute>
10082
10083 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10084 <desc>
10085 Current guest display color depth. Note that this may differ
10086 from <link to="IFramebuffer::bitsPerPixel"/>.
10087 </desc>
10088 </attribute>
10089
10090 <method name="setupInternalFramebuffer">
10091 <desc>
10092 Prepares an internally managed frame buffer.
10093 </desc>
10094 <param name="depth" type="unsigned long" dir="in"/>
10095 </method>
10096
10097 <method name="lockFramebuffer">
10098 <desc>
10099 Requests access to the internal frame buffer.
10100
10101 <result name="VBOX_E_NOT_SUPPORTED">
10102 Attempt to lock a non-internal frame buffer.
10103 </result>
10104
10105 </desc>
10106 <param name="address" type="octet" mod="ptr" dir="return"/>
10107 </method>
10108
10109 <method name="unlockFramebuffer">
10110 <desc>
10111 Releases access to the internal frame buffer.
10112
10113 <result name="VBOX_E_NOT_SUPPORTED">
10114 Attempt to unlock a non-internal frame buffer.
10115 </result>
10116
10117 </desc>
10118 </method>
10119
10120 <method name="registerExternalFramebuffer">
10121 <desc>
10122 Registers an external frame buffer.
10123 </desc>
10124 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10125 </method>
10126
10127 <method name="setFramebuffer">
10128 <desc>
10129 Sets the framebuffer for given screen.
10130 </desc>
10131 <param name="screenId" type="unsigned long" dir="in"/>
10132 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10133 </method>
10134
10135 <method name="getFramebuffer">
10136 <desc>
10137 Queries the framebuffer for given screen.
10138 </desc>
10139 <param name="screenId" type="unsigned long" dir="in"/>
10140 <param name="framebuffer" type="IFramebuffer" dir="out"/>
10141 <param name="xOrigin" type="long" dir="out"/>
10142 <param name="yOrigin" type="long" dir="out"/>
10143 </method>
10144
10145 <method name="setVideoModeHint">
10146 <desc>
10147 Asks VirtualBox to request the given video mode from
10148 the guest. This is just a hint and it cannot be guaranteed
10149 that the requested resolution will be used. Guest Additions
10150 are required for the request to be seen by guests. The caller
10151 should issue the request and wait for a resolution change and
10152 after a timeout retry.
10153
10154 Specifying <tt>0</tt> for either @a width, @a height or @a bitsPerPixel
10155 parameters means that the corresponding values should be taken from the
10156 current video mode (i.e. left unchanged).
10157
10158 If the guest OS supports multi-monitor configuration then the @a display
10159 parameter specifies the number of the guest display to send the hint to:
10160 <tt>0</tt> is the primary display, <tt>1</tt> is the first secondary and
10161 so on. If the multi-monitor configuration is not supported, @a display
10162 must be <tt>0</tt>.
10163
10164 <result name="E_INVALIDARG">
10165 The @a display is not associated with any monitor.
10166 </result>
10167
10168 </desc>
10169 <param name="width" type="unsigned long" dir="in"/>
10170 <param name="height" type="unsigned long" dir="in"/>
10171 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
10172 <param name="display" type="unsigned long" dir="in"/>
10173 </method>
10174
10175 <method name="setSeamlessMode">
10176 <desc>
10177 Enables or disables seamless guest display rendering (seamless desktop
10178 integration) mode.
10179 <note>
10180 Calling this method has no effect if <link
10181 to="IGuest::supportsSeamless"/> returns <tt>false</tt>.
10182 </note>
10183 </desc>
10184 <param name="enabled" type="boolean" dir="in"/>
10185 </method>
10186
10187 <method name="takeScreenShot">
10188 <desc>
10189 Takes a screen shot of the requested size and copies it to the
10190 32-bpp buffer allocated by the caller.
10191
10192 <result name="E_NOTIMPL">
10193 Feature not implemented.
10194 </result>
10195 <result name="VBOX_E_IPRT_ERROR">
10196 Could not take a screenshot.
10197 </result>
10198
10199 </desc>
10200 <param name="address" type="octet" mod="ptr" dir="in"/>
10201 <param name="width" type="unsigned long" dir="in"/>
10202 <param name="height" type="unsigned long" dir="in"/>
10203 </method>
10204
10205 <method name="drawToScreen">
10206 <desc>
10207 Draws a 32-bpp image of the specified size from the given buffer
10208 to the given point on the VM display.
10209
10210 <result name="E_NOTIMPL">
10211 Feature not implemented.
10212 </result>
10213 <result name="VBOX_E_IPRT_ERROR">
10214 Could not draw to screen.
10215 </result>
10216
10217 </desc>
10218 <param name="address" type="octet" mod="ptr" dir="in"/>
10219 <param name="x" type="unsigned long" dir="in"/>
10220 <param name="y" type="unsigned long" dir="in"/>
10221 <param name="width" type="unsigned long" dir="in"/>
10222 <param name="height" type="unsigned long" dir="in"/>
10223 </method>
10224
10225 <method name="invalidateAndUpdate">
10226 <desc>
10227 Does a full invalidation of the VM display and instructs the VM
10228 to update it.
10229
10230 <result name="VBOX_E_IPRT_ERROR">
10231 Could not invalidate and update screen.
10232 </result>
10233
10234 </desc>
10235 </method>
10236
10237 <method name="resizeCompleted">
10238 <desc>
10239 Signals that a framebuffer has completed the resize operation.
10240
10241 <result name="VBOX_E_NOT_SUPPORTED">
10242 Operation only valid for external frame buffers.
10243 </result>
10244
10245 </desc>
10246 <param name="screenId" type="unsigned long" dir="in"/>
10247 </method>
10248
10249 <method name="updateCompleted">
10250 <desc>
10251 Signals that a framebuffer has completed the update operation.
10252
10253 <result name="VBOX_E_NOT_SUPPORTED">
10254 Operation only valid for external frame buffers.
10255 </result>
10256
10257 </desc>
10258 </method>
10259
10260 </interface>
10261
10262 <!--
10263 // INetworkAdapter
10264 /////////////////////////////////////////////////////////////////////////
10265 -->
10266
10267 <enum
10268 name="NetworkAttachmentType"
10269 uuid="64e770dc-dd1d-4879-9f12-5bd6bc879b78"
10270 >
10271 <desc>
10272 Network attachment type.
10273 </desc>
10274
10275 <const name="Null" value="0">
10276 <desc>Null value, also means "not attached".</desc>
10277 </const>
10278 <const name="NAT" value="1"/>
10279 <const name="HostInterface" value="2"/>
10280 <const name="Internal" value="3"/>
10281 <const name="HostOnly" value="4"/>
10282 </enum>
10283
10284 <enum
10285 name="NetworkAdapterType"
10286 uuid="156b17b9-5d61-4d54-be90-62e37dda848d"
10287 >
10288 <desc>
10289 Network adapter type.
10290 </desc>
10291
10292 <const name="Null" value="0">
10293 <desc>Null value (never used by the API).</desc>
10294 </const>
10295 <const name="Am79C970A" value="1"/>
10296 <const name="Am79C973" value="2"/>
10297 <const name="I82540EM" value="3"/>
10298 <const name="I82543GC" value="4"/>
10299 </enum>
10300
10301 <interface
10302 name="INetworkAdapter" extends="$unknown"
10303 uuid="4a1ee64e-6c5f-47dd-acfa-f834d7cb74fb"
10304 wsmap="managed"
10305 >
10306 <attribute name="adapterType" type="NetworkAdapterType">
10307 <desc>
10308 Type of the virtual network adapter. Depending on this value,
10309 VirtualBox will provide a different virtual network hardware
10310 to the guest.
10311 </desc>
10312 </attribute>
10313
10314 <attribute name="slot" type="unsigned long" readonly="yes">
10315 <desc>
10316 Slot number this adapter is plugged into. Corresponds to
10317 the value you pass to <link to="IMachine::getNetworkAdapter"/>
10318 to obtain this instance.
10319 </desc>
10320 </attribute>
10321
10322 <attribute name="enabled" type="boolean">
10323 <desc>
10324 Flag whether the network adapter is present in the
10325 guest system. If disabled, the virtual guest hardware will
10326 not contain this network adapter. Can only be changed when
10327 the VM is not running.
10328 </desc>
10329 </attribute>
10330
10331 <attribute name="MACAddress" type="wstring">
10332 <desc>
10333 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
10334 it to NULL, VirtualBox will generate a unique MAC address.
10335 </desc>
10336 </attribute>
10337
10338 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
10339
10340 <attribute name="hostInterface" type="wstring">
10341 <desc>
10342 Name of the host network interface the VM is attached to.
10343 </desc>
10344 </attribute>
10345
10346 <attribute name="internalNetwork" type="wstring">
10347 <desc>
10348 Name of the internal network the VM is attached to.
10349 </desc>
10350 </attribute>
10351
10352 <attribute name="NATNetwork" type="wstring">
10353 <desc>
10354 Name of the NAT network the VM is attached to.
10355 </desc>
10356 </attribute>
10357
10358 <attribute name="cableConnected" type="boolean">
10359 <desc>
10360 Flag whether the adapter reports the cable as connected or not.
10361 It can be used to report offline situations to a VM.
10362 </desc>
10363 </attribute>
10364
10365 <attribute name="lineSpeed" type="unsigned long">
10366 <desc>
10367 Line speed reported by custom drivers, in units of 1 kbps.
10368 </desc>
10369 </attribute>
10370
10371 <attribute name="traceEnabled" type="boolean">
10372 <desc>
10373 Flag whether network traffic from/to the network card should be traced.
10374 Can only be toggled when the VM is turned off.
10375 </desc>
10376 </attribute>
10377
10378 <attribute name="traceFile" type="wstring">
10379 <desc>
10380 Filename where a network trace will be stored. If not set, VBox-pid.pcap
10381 will be used.
10382 </desc>
10383 </attribute>
10384
10385 <method name="attachToNAT">
10386 <desc>
10387 Attach the network adapter to the Network Address Translation (NAT) interface.
10388 </desc>
10389 </method>
10390
10391 <method name="attachToHostInterface">
10392 <desc>
10393 Attach the network adapter to a host interface.
10394 </desc>
10395 </method>
10396
10397 <method name="attachToInternalNetwork">
10398 <desc>
10399 Attach the network adapter to an internal network.
10400 </desc>
10401 </method>
10402
10403 <method name="attachToHostOnlyNetwork">
10404 <desc>
10405 Attach the network adapter to the host-only network.
10406 </desc>
10407 </method>
10408
10409 <method name="detach">
10410 <desc>
10411 Detach the network adapter
10412 </desc>
10413 </method>
10414 </interface>
10415
10416
10417 <!--
10418 // ISerialPort
10419 /////////////////////////////////////////////////////////////////////////
10420 -->
10421
10422 <enum
10423 name="PortMode"
10424 uuid="b266f43c-2e93-46b3-812b-c20e600e867b"
10425 >
10426 <desc>
10427 The PortMode enumeration represents possible communication modes for
10428 the virtual serial port device.
10429 </desc>
10430
10431 <const name="Disconnected" value="0">
10432 <desc>Virtual device is not attached to any real host device.</desc>
10433 </const>
10434 <const name="HostPipe" value="1">
10435 <desc>Virtual device is attached to a host pipe.</desc>
10436 </const>
10437 <const name="HostDevice" value="2">
10438 <desc>Virtual device is attached to a host device.</desc>
10439 </const>
10440 </enum>
10441
10442 <interface
10443 name="ISerialPort" extends="$unknown"
10444 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
10445 wsmap="managed"
10446 >
10447
10448 <desc>
10449 The ISerialPort interface represents the virtual serial port device.
10450
10451 The virtual serial port device acts like an ordinary serial port
10452 inside the virtual machine. This device communicates to the real
10453 serial port hardware in one of two modes: host pipe or host device.
10454
10455 In host pipe mode, the #path attribute specifies the path to the pipe on
10456 the host computer that represents a serial port. The #server attribute
10457 determines if this pipe is created by the virtual machine process at
10458 machine startup or it must already exist before starting machine
10459 execution.
10460
10461 In host device mode, the #path attribute specifies the name of the
10462 serial port device on the host computer.
10463
10464 There is also a third communication mode: the disconnected mode. In this
10465 mode, the guest OS running inside the virtual machine will be able to
10466 detect the serial port, but all port write operations will be discarded
10467 and all port read operations will return no data.
10468
10469 <see>IMachine::getSerialPort</see>
10470 </desc>
10471
10472 <attribute name="slot" type="unsigned long" readonly="yes">
10473 <desc>
10474 Slot number this serial port is plugged into. Corresponds to
10475 the value you pass to <link to="IMachine::getSerialPort"/>
10476 to obtain this instance.
10477 </desc>
10478 </attribute>
10479
10480 <attribute name="enabled" type="boolean">
10481 <desc>
10482 Flag whether the serial port is enabled. If disabled,
10483 the serial port will not be reported to the guest OS.
10484 </desc>
10485 </attribute>
10486
10487 <attribute name="IOBase" type="unsigned long">
10488 <desc>Base I/O address of the serial port.</desc>
10489 </attribute>
10490
10491 <attribute name="IRQ" type="unsigned long">
10492 <desc>IRQ number of the serial port.</desc>
10493 </attribute>
10494
10495 <attribute name="hostMode" type="PortMode">
10496 <desc>
10497 How is this port connected to the host.
10498 <note>
10499 Changing this attribute may fail if the conditions for
10500 <link to="#path"/> are not met.
10501 </note>
10502 </desc>
10503 </attribute>
10504
10505 <attribute name="server" type="boolean">
10506 <desc>
10507 Flag whether this serial port acts as a server (creates a new pipe on
10508 the host) or as a client (uses the existing pipe). This attribute is
10509 used only when <link to="#hostMode"/> is PortMode_HostPipe.
10510 </desc>
10511 </attribute>
10512
10513 <attribute name="path" type="wstring">
10514 <desc>
10515 Path to the serial port's pipe on the host when <link to="#hostMode"/> is
10516 PortMode_HostPipe, or the host serial device name when
10517 <link to="#hostMode"/> is PortMode_HostDevice. In either of the above
10518 cases, setting a @c null or an empty string as the attribute's value
10519 will result into an error. Otherwise, the value of this property is
10520 ignored.
10521 </desc>
10522 </attribute>
10523
10524 </interface>
10525
10526 <!--
10527 // IParallelPort
10528 /////////////////////////////////////////////////////////////////////////
10529 -->
10530
10531 <interface
10532 name="IParallelPort" extends="$unknown"
10533 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
10534 wsmap="managed"
10535 >
10536
10537 <desc>
10538 The IParallelPort interface represents the virtual parallel port device.
10539
10540 The virtual parallel port device acts like an ordinary parallel port
10541 inside the virtual machine. This device communicates to the real
10542 parallel port hardware using the name of the parallel device on the host
10543 computer specified in the #path attribute.
10544
10545 Each virtual parallel port device is assigned a base I/O address and an
10546 IRQ number that will be reported to the guest operating system and used
10547 to operate the given parallel port from within the virtual machine.
10548
10549 <see>IMachine::getParallelPort</see>
10550 </desc>
10551
10552 <attribute name="slot" type="unsigned long" readonly="yes">
10553 <desc>
10554 Slot number this parallel port is plugged into. Corresponds to
10555 the value you pass to <link to="IMachine::getParallelPort"/>
10556 to obtain this instance.
10557 </desc>
10558 </attribute>
10559
10560 <attribute name="enabled" type="boolean">
10561 <desc>
10562 Flag whether the parallel port is enabled. If disabled,
10563 the parallel port will not be reported to the guest OS.
10564 </desc>
10565 </attribute>
10566
10567 <attribute name="IOBase" type="unsigned long">
10568 <desc>Base I/O address of the parallel port.</desc>
10569 </attribute>
10570
10571 <attribute name="IRQ" type="unsigned long">
10572 <desc>IRQ number of the parallel port.</desc>
10573 </attribute>
10574
10575 <attribute name="path" type="wstring">
10576 <desc>
10577 Host parallel device name. If this parallel port is enabled, setting a
10578 @c null or an empty string as this attribute's value will result into
10579 an error.
10580 </desc>
10581 </attribute>
10582
10583 </interface>
10584
10585
10586 <!--
10587 // IMachineDebugger
10588 /////////////////////////////////////////////////////////////////////////
10589 -->
10590
10591 <interface
10592 name="IMachineDebugger" extends="$unknown"
10593 uuid="b0b2a2dd-0627-4502-91c2-ddc5e77609e0"
10594 wsmap="suppress"
10595 >
10596 <method name="resetStats">
10597 <desc>
10598 Reset VM statistics.
10599 </desc>
10600 <param name="pattern" type="wstring" dir="in">
10601 <desc>The selection pattern. A bit similar to filename globbing.</desc>
10602 </param>
10603 </method>
10604
10605 <method name="dumpStats">
10606 <desc>
10607 Dumps VM statistics.
10608 </desc>
10609 <param name="pattern" type="wstring" dir="in">
10610 <desc>The selection pattern. A bit similar to filename globbing.</desc>
10611 </param>
10612 </method>
10613
10614 <method name="getStats">
10615 <desc>
10616 Get the VM statistics in a XMLish format.
10617 </desc>
10618 <param name="pattern" type="wstring" dir="in">
10619 <desc>The selection pattern. A bit similar to filename globbing.</desc>
10620 </param>
10621 <param name="withDescriptions" type="boolean" dir="in">
10622 <desc>Whether to include the descriptions.</desc>
10623 </param>
10624 <param name="stats" type="wstring" dir="out">
10625 <desc>The XML document containing the statistics.</desc>
10626 </param>
10627 </method>
10628
10629 <method name="injectNMI">
10630 <desc>
10631 Inject an NMI into a running VT-x/AMD-V VM.
10632 </desc>
10633 </method>
10634
10635 <attribute name="singlestep" type="boolean">
10636 <desc>Switch for enabling singlestepping.</desc>
10637 </attribute>
10638
10639 <attribute name="recompileUser" type="boolean">
10640 <desc>Switch for forcing code recompilation for user mode code.</desc>
10641 </attribute>
10642
10643 <attribute name="recompileSupervisor" type="boolean">
10644 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
10645 </attribute>
10646
10647 <attribute name="PATMEnabled" type="boolean">
10648 <desc>Switch for enabling and disabling the PATM component.</desc>
10649 </attribute>
10650
10651 <attribute name="CSAMEnabled" type="boolean">
10652 <desc>Switch for enabling and disabling the CSAM component.</desc>
10653 </attribute>
10654
10655 <attribute name="logEnabled" type="boolean">
10656 <desc>Switch for enabling and disabling logging.</desc>
10657 </attribute>
10658
10659 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
10660 <desc>
10661 Flag indicating whether the VM is currently making use of CPU hardware
10662 virtualization extensions.
10663 </desc>
10664 </attribute>
10665
10666 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" readonly="yes">
10667 <desc>
10668 Flag indicating whether the VM is currently making use of the nested paging
10669 CPU hardware virtualization extension.
10670 </desc>
10671 </attribute>
10672
10673 <attribute name="HWVirtExVPIDEnabled" type="boolean" readonly="yes">
10674 <desc>
10675 Flag indicating whether the VM is currently making use of the VPID
10676 VT-x extension.
10677 </desc>
10678 </attribute>
10679
10680 <attribute name="PAEEnabled" type="boolean" readonly="yes">
10681 <desc>
10682 Flag indicating whether the VM is currently making use of the Physical
10683 Address Extension CPU feature.
10684 </desc>
10685 </attribute>
10686
10687 <attribute name="virtualTimeRate" type="unsigned long">
10688 <desc>
10689 The rate at which the virtual time runs expressed as a percentage.
10690 The accepted range is 2% to 20000%.
10691 </desc>
10692 </attribute>
10693
10694 <!-- @todo method for setting log flags, groups and destination! -->
10695
10696 <attribute name="VM" type="unsigned long long" readonly="yes">
10697 <desc>
10698 Gets the VM handle. This is only for internal use while
10699 we carve the details of this interface.
10700 </desc>
10701 </attribute>
10702
10703 </interface>
10704
10705 <!--
10706 // IUSBController
10707 /////////////////////////////////////////////////////////////////////////
10708 -->
10709
10710 <interface
10711 name="IUSBController" extends="$unknown"
10712 uuid="f4c2d3dc-f109-4da7-93b1-ec28973ac89f"
10713 wsmap="managed"
10714 >
10715 <attribute name="enabled" type="boolean">
10716 <desc>
10717 Flag whether the USB controller is present in the
10718 guest system. If disabled, the virtual guest hardware will
10719 not contain any USB controller. Can only be changed when
10720 the VM is powered off.
10721 </desc>
10722 </attribute>
10723
10724 <attribute name="enabledEhci" type="boolean">
10725 <desc>
10726 Flag whether the USB EHCI controller is present in the
10727 guest system. If disabled, the virtual guest hardware will
10728 not contain a USB EHCI controller. Can only be changed when
10729 the VM is powered off.
10730 </desc>
10731 </attribute>
10732
10733 <attribute name="USBStandard" type="unsigned short" readonly="yes">
10734 <desc>
10735 USB standard version which the controller implements.
10736 This is a BCD which means that the major version is in the
10737 high byte and minor version is in the low byte.
10738 </desc>
10739 </attribute>
10740
10741 <attribute name="deviceFilters" type="IUSBDeviceFilterCollection" readonly="yes">
10742 <desc>
10743 List of USB device filters associated with the machine.
10744
10745 If the machine is currently running, these filters are activated
10746 every time a new (supported) USB device is attached to the host
10747 computer that was not ignored by global filters
10748 (<link to="IHost::USBDeviceFilters"/>).
10749
10750 These filters are also activated when the machine is powered up.
10751 They are run against a list of all currently available USB
10752 devices (in states
10753 <link to="USBDeviceState_Available"/>,
10754 <link to="USBDeviceState_Busy"/>,
10755 <link to="USBDeviceState_Held"/>) that were not previously
10756 ignored by global filters.
10757
10758 If at least one filter matches the USB device in question, this
10759 device is automatically captured (attached to) the virtual USB
10760 controller of this machine.
10761
10762 <see>IUSBDeviceFilter, ::IUSBController</see>
10763 </desc>
10764 </attribute>
10765
10766 <method name="createDeviceFilter">
10767 <desc>
10768 Creates a new USB device filter. All attributes except
10769 the filter name are set to <tt>null</tt> (any match),
10770 <i>active</i> is <tt>false</tt> (the filter is not active).
10771
10772 The created filter can then be added to the list of filters using
10773 <link to="#insertDeviceFilter()"/>.
10774
10775 <result name="VBOX_E_INVALID_VM_STATE">
10776 The virtual machine is not mutable.
10777 </result>
10778
10779 <see>#deviceFilters</see>
10780 </desc>
10781 <param name="name" type="wstring" dir="in">
10782 <desc>
10783 Filter name. See <link to="IUSBDeviceFilter::name"/>
10784 for more info.
10785 </desc>
10786 </param>
10787 <param name="filter" type="IUSBDeviceFilter" dir="return">
10788 <desc>Created filter object.</desc>
10789 </param>
10790 </method>
10791
10792 <method name="insertDeviceFilter">
10793 <desc>
10794 Inserts the given USB device to the specified position
10795 in the list of filters.
10796
10797 Positions are numbered starting from <tt>0</tt>. If the specified
10798 position is equal to or greater than the number of elements in
10799 the list, the filter is added to the end of the collection.
10800
10801 <note>
10802 Duplicates are not allowed, so an attempt to insert a
10803 filter that is already in the collection, will return an
10804 error.
10805 </note>
10806
10807 <result name="VBOX_E_INVALID_VM_STATE">
10808 Virtual machine is not mutable.
10809 </result>
10810 <result name="E_INVALIDARG">
10811 USB device filter not created within this VirtualBox instance.
10812 </result>
10813 <result name="VBOX_E_INVALID_OBJECT_STATE">
10814 USB device filter already in list.
10815 </result>
10816
10817 <see>#deviceFilters</see>
10818 </desc>
10819 <param name="position" type="unsigned long" dir="in">
10820 <desc>Position to insert the filter to.</desc>
10821 </param>
10822 <param name="filter" type="IUSBDeviceFilter" dir="in">
10823 <desc>USB device filter to insert.</desc>
10824 </param>
10825 </method>
10826
10827 <method name="removeDeviceFilter">
10828 <desc>
10829 Removes a USB device filter from the specified position in the
10830 list of filters.
10831
10832 Positions are numbered starting from <tt>0</tt>. Specifying a
10833 position equal to or greater than the number of elements in
10834 the list will produce an error.
10835
10836 <see>#deviceFilters</see>
10837
10838 <result name="VBOX_E_INVALID_VM_STATE">
10839 Virtual machine is not mutable.
10840 </result>
10841 <result name="E_INVALIDARG">
10842 USB device filter list empty or invalid @a position.
10843 </result>
10844
10845 </desc>
10846 <param name="position" type="unsigned long" dir="in">
10847 <desc>Position to remove the filter from.</desc>
10848 </param>
10849 <param name="filter" type="IUSBDeviceFilter" dir="return">
10850 <desc>Removed USB device filter.</desc>
10851 </param>
10852 </method>
10853
10854 </interface>
10855
10856
10857 <!--
10858 // IUSBDevice
10859 /////////////////////////////////////////////////////////////////////////
10860 -->
10861
10862 <enumerator
10863 name="IUSBDeviceEnumerator" type="IUSBDevice"
10864 uuid="aefe00f7-eb8a-454b-9ea4-fd5ad93c0e99"
10865 />
10866
10867 <collection
10868 name="IUSBDeviceCollection" type="IUSBDevice"
10869 enumerator="IUSBDeviceEnumerator"
10870 uuid="e31f3248-90dd-4ca2-95f0-6b36042d96a2"
10871 readonly="yes"
10872 >
10873 <method name="findById">
10874 <desc>
10875 Searches this collection for a USB device with the given UUID.
10876 <note>
10877 The method returns an error if the given UUID does not
10878 correspond to any USB device in the collection.
10879 </note>
10880 <see>IUSBDevice::id</see>
10881 </desc>
10882 <param name="id" type="uuid" dir="in">
10883 <desc>UUID of the USB device to search for.</desc>
10884 </param>
10885 <param name="device" type="IUSBDevice" dir="return">
10886 <desc>Found USB device object.</desc>
10887 </param>
10888 </method>
10889
10890 <method name="findByAddress">
10891 <desc>
10892 Searches this collection for a USB device with the given
10893 host address.
10894 <note>
10895 The method returns an error if the given address does not
10896 correspond to any USB device in the collection.
10897 </note>
10898 <see>IUSBDevice::address</see>
10899 </desc>
10900 <param name="name" type="wstring" dir="in">
10901 <desc>
10902 Address of the USB device (as assigned by the host) to
10903 search for.
10904 </desc>
10905 </param>
10906 <param name="device" type="IUSBDevice" dir="return">
10907 <desc>Found USB device object.</desc>
10908 </param>
10909 </method>
10910
10911 </collection>
10912
10913 <interface
10914 name="IUSBDevice" extends="$unknown"
10915 uuid="850af07b-9ee8-48c2-b6b0-f6d0acbf63c3"
10916 wsmap="managed"
10917 >
10918 <desc>
10919 The IUSBDevice interface represents a virtual USB device attached to the
10920 virtual machine.
10921
10922 A collection of objects implementing this interface is stored in the
10923 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
10924 attached to a running virtual machine's USB controller.
10925 </desc>
10926
10927 <attribute name="id" type="uuid" readonly="yes">
10928 <desc>
10929 Unique USB device ID. This ID is built from #vendorId,
10930 #productId, #revision and #serialNumber.
10931 </desc>
10932 </attribute>
10933
10934 <attribute name="vendorId" type="unsigned short" readonly="yes">
10935 <desc>Vendor ID.</desc>
10936 </attribute>
10937
10938 <attribute name="productId" type="unsigned short" readonly="yes">
10939 <desc>Product ID.</desc>
10940 </attribute>
10941
10942 <attribute name="revision" type="unsigned short" readonly="yes">
10943 <desc>
10944 Product revision number. This is a packed BCD represented as
10945 unsigned short. The high byte is the integer part and the low
10946 byte is the decimal.
10947 </desc>
10948 </attribute>
10949
10950 <attribute name="manufacturer" type="wstring" readonly="yes">
10951 <desc>Manufacturer string.</desc>
10952 </attribute>
10953
10954 <attribute name="product" type="wstring" readonly="yes">
10955 <desc>Product string.</desc>
10956 </attribute>
10957
10958 <attribute name="serialNumber" type="wstring" readonly="yes">
10959 <desc>Serial number string.</desc>
10960 </attribute>
10961
10962 <attribute name="address" type="wstring" readonly="yes">
10963 <desc>Host specific address of the device.</desc>
10964 </attribute>
10965
10966 <attribute name="port" type="unsigned short" readonly="yes">
10967 <desc>
10968 Host USB port number the device is physically
10969 connected to.
10970 </desc>
10971 </attribute>
10972
10973 <attribute name="version" type="unsigned short" readonly="yes">
10974 <desc>
10975 The major USB version of the device - 1 or 2.
10976 </desc>
10977 </attribute>
10978
10979 <attribute name="portVersion" type="unsigned short" readonly="yes">
10980 <desc>
10981 The major USB version of the host USB port the device is
10982 physically connected to - 1 or 2. For devices not connected to
10983 anything this will have the same value as the version attribute.
10984 </desc>
10985 </attribute>
10986
10987 <attribute name="remote" type="boolean" readonly="yes">
10988 <desc>
10989 Whether the device is physically connected to a remote VRDP
10990 client or to a local host machine.
10991 </desc>
10992 </attribute>
10993
10994 </interface>
10995
10996
10997 <!--
10998 // IUSBDeviceFilter
10999 /////////////////////////////////////////////////////////////////////////
11000 -->
11001
11002 <enumerator
11003 name="IUSBDeviceFilterEnumerator" type="IUSBDeviceFilter"
11004 uuid="d5109c61-93e7-4726-926b-0dee1020da56"
11005 />
11006
11007 <collection
11008 name="IUSBDeviceFilterCollection" type="IUSBDeviceFilter"
11009 enumerator="IUSBDeviceFilterEnumerator"
11010 uuid="4fa3fc99-ceb1-4bf5-a9cb-e962d825c1ef"
11011 readonly="yes"
11012 />
11013
11014 <interface
11015 name="IUSBDeviceFilter" extends="$unknown"
11016 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
11017 wsmap="managed"
11018 >
11019 <desc>
11020 The IUSBDeviceFilter interface represents an USB device filter used
11021 to perform actions on a group of USB devices.
11022
11023 This type of filters is used by running virtual machines to
11024 automatically capture selected USB devices once they are physically
11025 attached to the host computer.
11026
11027 A USB device is matched to the given device filter if and only if all
11028 attributes of the device match the corresponding attributes of the
11029 filter (that is, attributes are joined together using the logical AND
11030 operation). On the other hand, all together, filters in the list of
11031 filters carry the semantics of the logical OR operation. So if it is
11032 desirable to create a match like "this vendor id OR this product id",
11033 one needs to create two filters and specify "any match" (see below)
11034 for unused attributes.
11035
11036 All filter attributes used for matching are strings. Each string
11037 is an expression representing a set of values of the corresponding
11038 device attribute, that will match the given filter. Currently, the
11039 following filtering expressions are supported:
11040
11041 <ul>
11042 <li><i>Interval filters</i>. Used to specify valid intervals for
11043 integer device attributes (Vendor ID, Product ID and Revision).
11044 The format of the string is:
11045
11046 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
11047
11048 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
11049 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
11050 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
11051 is omitted before a dash (<tt>-</tt>), the minimum possible integer
11052 is assumed; if <tt>n</tt> is omitted after a dash, the maximum
11053 possible integer is assumed.
11054 </li>
11055 <li><i>Boolean filters</i>. Used to specify acceptable values for
11056 boolean device attributes. The format of the string is:
11057
11058 <tt>true|false|yes|no|0|1</tt>
11059
11060 </li>
11061 <li><i>Exact match</i>. Used to specify a single value for the given
11062 device attribute. Any string that doesn't start with <tt>int:</tt>
11063 represents the exact match. String device attributes are compared to
11064 this string including case of symbols. Integer attributes are first
11065 converted to a string (see individual filter attributes) and then
11066 compared ignoring case.
11067
11068 </li>
11069 <li><i>Any match</i>. Any value of the corresponding device attribute
11070 will match the given filter. An empty or <tt>null</tt> string is
11071 used to construct this type of filtering expressions.
11072
11073 </li>
11074 </ul>
11075
11076 <note>
11077 On the Windows host platform, interval filters are not currently
11078 available. Also all string filter attributes
11079 (<link to="#manufacturer"/>, <link to="#product"/>,
11080 <link to="#serialNumber"/>) are ignored, so they behave as
11081 <i>any match</i> no matter what string expression is specified.
11082 </note>
11083
11084 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
11085 </desc>
11086
11087 <attribute name="name" type="wstring">
11088 <desc>
11089 Visible name for this filter.
11090 This name is used to visually distinguish one filter from another,
11091 so it can neither be <tt>null</tt> nor an empty string.
11092 </desc>
11093 </attribute>
11094
11095 <attribute name="active" type="boolean">
11096 <desc>Whether this filter active or has been temporarily disabled.</desc>
11097 </attribute>
11098
11099 <attribute name="vendorId" type="wstring">
11100 <desc>
11101 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
11102 The string representation for the <i>exact matching</i>
11103 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11104 (including leading zeroes).
11105 </desc>
11106 </attribute>
11107
11108 <attribute name="productId" type="wstring">
11109 <desc>
11110 <link to="IUSBDevice::productId">Product ID</link> filter.
11111 The string representation for the <i>exact matching</i>
11112 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11113 (including leading zeroes).
11114 </desc>
11115 </attribute>
11116
11117 <attribute name="revision" type="wstring">
11118 <desc>
11119 <link to="IUSBDevice::productId">Product revision number</link>
11120 filter. The string representation for the <i>exact matching</i>
11121 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
11122 of the integer part of the revision, and <tt>F</tt> is the
11123 decimal digit of its fractional part (including leading and
11124 trailing zeros).
11125 Note that for interval filters, it's best to use the hexadecimal
11126 form, because the revision is stored as a 16 bit packed BCD value;
11127 so the expression <tt>int:0x0100-0x0199</tt> will match any
11128 revision from <tt>1.0</tt> to <tt>1.99</tt>.
11129 </desc>
11130 </attribute>
11131
11132 <attribute name="manufacturer" type="wstring">
11133 <desc>
11134 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
11135 </desc>
11136 </attribute>
11137
11138 <attribute name="product" type="wstring">
11139 <desc>
11140 <link to="IUSBDevice::product">Product</link> filter.
11141 </desc>
11142 </attribute>
11143
11144 <attribute name="serialNumber" type="wstring">
11145 <desc>
11146 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
11147 </desc>
11148 </attribute>
11149
11150 <attribute name="port" type="wstring">
11151 <desc>
11152 <link to="IUSBDevice::port">Host USB port</link> filter.
11153 </desc>
11154 </attribute>
11155
11156 <attribute name="remote" type="wstring">
11157 <desc>
11158 <link to="IUSBDevice::remote">Remote state</link> filter.
11159 <note>
11160 This filter makes sense only for machine USB filters,
11161 i.e. it is ignored by IHostUSBDeviceFilter objects.
11162 </note>
11163 </desc>
11164 </attribute>
11165
11166 <attribute name="maskedInterfaces" type="unsigned long">
11167 <desc>
11168 This is an advanced option for hiding one or more USB interfaces
11169 from the guest. The value is a bit mask where the bits that are set
11170 means the corresponding USB interface should be hidden, masked off
11171 if you like.
11172 This feature only works on Linux hosts.
11173 </desc>
11174 </attribute>
11175
11176 </interface>
11177
11178
11179 <!--
11180 // IHostUSBDevice
11181 /////////////////////////////////////////////////////////////////////////
11182 -->
11183
11184 <enum
11185 name="USBDeviceState"
11186 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
11187 >
11188 <desc>
11189 USB device state. This enumeration represents all possible states
11190 of the USB device physically attached to the host computer regarding
11191 its state on the host computer and availability to guest computers
11192 (all currently running virtual machines).
11193
11194 Once a supported USB device is attached to the host, global USB
11195 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
11196 either ignore the device, or put it to USBDeviceState_Held state, or do
11197 nothing. Unless the device is ignored by global filters, filters of all
11198 currently running guests (<link to="IUSBController::deviceFilters"/>) are
11199 activated that can put it to USBDeviceState_Captured state.
11200
11201 If the device was ignored by global filters, or didn't match
11202 any filters at all (including guest ones), it is handled by the host
11203 in a normal way. In this case, the device state is determined by
11204 the host and can be one of USBDeviceState_Unavailable, USBDeviceState_Busy
11205 or USBDeviceState_Available, depending on the current device usage.
11206
11207 Besides auto-capturing based on filters, the device can be manually
11208 captured by guests (<link to="IConsole::attachUSBDevice()"/>) if its
11209 state is USBDeviceState_Busy, USBDeviceState_Available or
11210 USBDeviceState_Held.
11211
11212 <note>
11213 Due to differences in USB stack implementations in Linux and Win32,
11214 states USBDeviceState_Busy and USBDeviceState_vailable are applicable
11215 only to the Linux version of the product. This also means that (<link
11216 to="IConsole::attachUSBDevice()"/>) can only succeed on Win32 if the
11217 device state is USBDeviceState_Held.
11218 </note>
11219
11220 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
11221 </desc>
11222
11223 <const name="NotSupported" value="0">
11224 <desc>
11225 Not supported by the VirtualBox server, not available to guests.
11226 </desc>
11227 </const>
11228 <const name="Unavailable" value="1">
11229 <desc>
11230 Being used by the host computer exclusively,
11231 not available to guests.
11232 </desc>
11233 </const>
11234 <const name="Busy" value="2">
11235 <desc>
11236 Being used by the host computer, potentially available to guests.
11237 </desc>
11238 </const>
11239 <const name="Available" value="3">
11240 <desc>
11241 Not used by the host computer, available to guests (the host computer
11242 can also start using the device at any time).
11243 </desc>
11244 </const>
11245 <const name="Held" value="4">
11246 <desc>
11247 Held by the VirtualBox server (ignored by the host computer),
11248 available to guests.
11249 </desc>
11250 </const>
11251 <const name="Captured" value="5">
11252 <desc>
11253 Captured by one of the guest computers, not available
11254 to anybody else.
11255 </desc>
11256 </const>
11257 </enum>
11258
11259 <enumerator
11260 name="IHostUSBDeviceEnumerator" type="IHostUSBDevice"
11261 uuid="a0c55136-939f-4d20-b9d3-4d406f08bfa5"
11262 />
11263
11264 <collection
11265 name="IHostUSBDeviceCollection" type="IHostUSBDevice"
11266 enumerator="IHostUSBDeviceEnumerator"
11267 uuid="f9d3f96d-b027-4994-b589-70bb9ee0d364"
11268 readonly="yes"
11269 >
11270 <method name="findById">
11271 <desc>
11272 Searches this collection for a USB device with the given UUID.
11273 <note>
11274 The method returns an error if the given UUID does not
11275 correspond to any USB device in the collection.
11276 </note>
11277 <see>IHostUSBDevice::id</see>
11278 </desc>
11279 <param name="id" type="uuid" dir="in">
11280 <desc>UUID of the USB device to search for.</desc>
11281 </param>
11282 <param name="device" type="IHostUSBDevice" dir="return">
11283 <desc>Found USB device object.</desc>
11284 </param>
11285 </method>
11286
11287 <method name="findByAddress">
11288 <desc>
11289 Searches this collection for a USB device with the given
11290 host address.
11291 <note>
11292 The method returns an error if the given address does not
11293 correspond to any USB device in the collection.
11294 </note>
11295 <see>IHostUSBDevice::address</see>
11296 </desc>
11297 <param name="name" type="wstring" dir="in">
11298 <desc>
11299 Address of the USB device (as assigned by the host) to
11300 search for.
11301 </desc>
11302 </param>
11303 <param name="device" type="IHostUSBDevice" dir="return">
11304 <desc>Found USB device object.</desc>
11305 </param>
11306 </method>
11307
11308 </collection>
11309
11310 <interface
11311 name="IHostUSBDevice" extends="IUSBDevice"
11312 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
11313 wsmap="managed"
11314 >
11315 <desc>
11316 The IHostUSBDevice interface represents a physical USB device attached
11317 to the host computer.
11318
11319 Besides properties inherited from IUSBDevice, this interface adds the
11320 <link to="#state"/> property that holds the current state of the USB
11321 device.
11322
11323 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
11324 </desc>
11325
11326 <attribute name="state" type="USBDeviceState" readonly="yes">
11327 <desc>
11328 Current state of the device.
11329 </desc>
11330 </attribute>
11331
11332 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
11333
11334 </interface>
11335
11336
11337 <!--
11338 // IHostUSBDeviceFilter
11339 /////////////////////////////////////////////////////////////////////////
11340 -->
11341
11342 <enum
11343 name="USBDeviceFilterAction"
11344 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
11345 >
11346 <desc>
11347 Actions for host USB device filters.
11348 <see>IHostUSBDeviceFilter, USBDeviceState</see>
11349 </desc>
11350
11351 <const name="Null" value="0">
11352 <desc>Null value (never used by the API).</desc>
11353 </const>
11354 <const name="Ignore" value="1">
11355 <desc>Ignore the matched USB device.</desc>
11356 </const>
11357 <const name="Hold" value="2">
11358 <desc>Hold the matched USB device.</desc>
11359 </const>
11360 </enum>
11361
11362 <enumerator
11363 name="IHostUSBDeviceFilterEnumerator" type="IHostUSBDeviceFilter"
11364 uuid="ff735211-903e-4642-9c37-189eb44579fe"
11365 />
11366
11367 <collection
11368 name="IHostUSBDeviceFilterCollection" type="IHostUSBDeviceFilter"
11369 enumerator="IHostUSBDeviceFilterEnumerator"
11370 uuid="1a80458b-87f1-4a74-995d-04e2330119e0"
11371 readonly="yes"
11372 />
11373
11374 <interface
11375 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
11376 uuid="4cc70246-d74a-400f-8222-3900489c0374"
11377 wsmap="managed"
11378 >
11379 <desc>
11380 The IHostUSBDeviceFilter interface represents a global filter for a
11381 physical USB device used by the host computer. Used indirectly in
11382 <link to="IHost::USBDeviceFilters"/>.
11383
11384 Using filters of this type, the host computer determines the initial
11385 state of the USB device after it is physically attached to the
11386 host's USB controller.
11387
11388 <note>
11389 The <link to="#remote"/> attribute is ignored by this type of
11390 filters, because it makes sense only for
11391 <link to="IUSBController::deviceFilters">machine USB filters</link>.
11392 </note>
11393
11394 <see>IHost::USBDeviceFilters</see>
11395 </desc>
11396
11397 <attribute name="action" type="USBDeviceFilterAction">
11398 <desc>
11399 Action performed by the host when an attached USB device
11400 matches this filter.
11401 </desc>
11402 </attribute>
11403
11404 </interface>
11405
11406 <!--
11407 // IAudioAdapter
11408 /////////////////////////////////////////////////////////////////////////
11409 -->
11410
11411 <enum
11412 name="AudioDriverType"
11413 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
11414 >
11415 <desc>
11416 Host audio driver type.
11417 </desc>
11418
11419 <const name="Null" value="0">
11420 <desc>Null value, also means "dummy audio driver".</desc>
11421 </const>
11422 <const name="WinMM" value="1"/>
11423 <const name="OSS" value="2"/>
11424 <const name="ALSA" value="3"/>
11425 <const name="DirectSound" value="4"/>
11426 <const name="CoreAudio" value="5"/>
11427 <const name="MMPM" value="6"/>
11428 <const name="Pulse" value="7"/>
11429 <const name="SolAudio" value="8"/>
11430 </enum>
11431
11432 <enum
11433 name="AudioControllerType"
11434 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
11435 >
11436 <desc>
11437 Virtual audio controller type.
11438 </desc>
11439
11440 <const name="AC97" value="0"/>
11441 <const name="SB16" value="1"/>
11442 </enum>
11443
11444 <interface
11445 name="IAudioAdapter" extends="$unknown"
11446 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
11447 wsmap="managed"
11448 >
11449 <desc>
11450 The IAudioAdapter interface represents the virtual audio adapter of
11451 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
11452 </desc>
11453 <attribute name="enabled" type="boolean">
11454 <desc>
11455 Flag whether the audio adapter is present in the
11456 guest system. If disabled, the virtual guest hardware will
11457 not contain any audio adapter. Can only be changed when
11458 the VM is not running.
11459 </desc>
11460 </attribute>
11461 <attribute name="audioController" type="AudioControllerType">
11462 <desc>
11463 The audio hardware we emulate.
11464 </desc>
11465 </attribute>
11466 <attribute name="audioDriver" type="AudioDriverType">
11467 <desc>
11468 Audio driver the adapter is connected to. This setting
11469 can only be changed when the VM is not running.
11470 </desc>
11471 </attribute>
11472 </interface>
11473
11474 <!--
11475 // IVRDPServer
11476 /////////////////////////////////////////////////////////////////////////
11477 -->
11478
11479 <enum
11480 name="VRDPAuthType"
11481 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
11482 >
11483 <desc>
11484 VRDP authentication type.
11485 </desc>
11486
11487 <const name="Null" value="0">
11488 <desc>Null value, also means "no authentication".</desc>
11489 </const>
11490 <const name="External" value="1"/>
11491 <const name="Guest" value="2"/>
11492 </enum>
11493
11494 <interface
11495 name="IVRDPServer" extends="$unknown"
11496 uuid="f4584ae7-6bce-474b-83d6-17d235e6aa89"
11497 wsmap="managed"
11498 >
11499 <attribute name="enabled" type="boolean">
11500 <desc>VRDP server status.</desc>
11501 </attribute>
11502
11503 <attribute name="port" type="unsigned long">
11504 <desc>
11505 VRDP server port number.
11506 <note>
11507 Setting the value of this property to <tt>0</tt> will reset the port
11508 number to the default value which is
11509 currently <tt>3389</tt>. Reading this property will always return a
11510 real port number, even after it has been set to <tt>0</tt> (in which
11511 case the default port is returned).
11512 </note>
11513 </desc>
11514 </attribute>
11515
11516 <attribute name="netAddress" type="wstring">
11517 <desc>VRDP server address.</desc>
11518 </attribute>
11519
11520 <attribute name="authType" type="VRDPAuthType">
11521 <desc>VRDP authentication method.</desc>
11522 </attribute>
11523
11524 <attribute name="authTimeout" type="unsigned long">
11525 <desc>Timeout for guest authentication. Milliseconds.</desc>
11526 </attribute>
11527
11528 <attribute name="allowMultiConnection" type="boolean">
11529 <desc>
11530 Flag whether multiple simultaneous connections to the VM are permitted.
11531 Note that this will be replaced by a more powerful mechanism in the future.
11532 </desc>
11533 </attribute>
11534
11535 <attribute name="reuseSingleConnection" type="boolean">
11536 <desc>
11537 Flag whether the existing connection must be dropped and a new connection
11538 must be established by the VRDP server, when a new client connects in single
11539 connection mode.
11540 </desc>
11541 </attribute>
11542
11543 </interface>
11544
11545
11546 <!--
11547 // ISharedFolder
11548 /////////////////////////////////////////////////////////////////////////
11549 -->
11550
11551 <enumerator
11552 name="ISharedFolderEnumerator" type="ISharedFolder"
11553 uuid="1d420fd8-e7c1-4511-abf4-a504dc6d0cbf"
11554 />
11555
11556 <collection
11557 name="ISharedFolderCollection" type="ISharedFolder"
11558 enumerator="ISharedFolderEnumerator"
11559 uuid="9c7e2282-bb16-4fa7-9138-f383c5e02353"
11560 readonly="yes">
11561
11562 <method name="findByName">
11563 <desc>
11564 Searches this collection for a shared folder with the given logical
11565 name.
11566 <note>
11567 The method returns an error if the given name does not correspond to
11568 any shared folder in the collection.
11569 </note>
11570 </desc>
11571 <param name="name" type="wstring" dir="in">
11572 <desc>Logical name of the shared folder to search for</desc>
11573 </param>
11574 <param name="sharedFolder" type="ISharedFolder" dir="return">
11575 <desc>Found shared folder object</desc>
11576 </param>
11577 </method>
11578
11579 </collection>
11580
11581 <interface
11582 name="ISharedFolder" extends="$unknown"
11583 uuid="ef41869b-ef31-4b30-8e8f-95af35c0e378"
11584 wsmap="struct"
11585 >
11586 <desc>
11587 The ISharedFolder interface represents a folder in the host computer's
11588 file system accessible from the guest OS running inside a virtual
11589 machine using an associated logical name.
11590
11591 There are three types of shared folders:
11592 <ul>
11593 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
11594 folders available to all virtual machines.</li>
11595 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
11596 VM-specific shared folders available to the given virtual machine at
11597 startup.</li>
11598 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
11599 VM-specific shared folders created in the session context (for
11600 example, when the virtual machine is running) and automatically
11601 discarded when the session is closed (the VM is powered off).</li>
11602 </ul>
11603
11604 Logical names of shared folders must be unique within the given scope
11605 (global, permanent or transient). However, they do not need to be unique
11606 across scopes. In this case, the definition of the shared folder in a
11607 more specific scope takes precedence over definitions in all other
11608 scopes. The order of precedence is (more specific to more general):
11609 <ol>
11610 <li>Transient definitions</li>
11611 <li>Permanent definitions</li>
11612 <li>Global definitions</li>
11613 </ol>
11614
11615 For example, if MyMachine has a shared folder named
11616 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then creating a
11617 transient shared folder named <tt>C_DRIVE</tt> (that points
11618 to <tt>C:\\\\WINDOWS</tt>) will change the definition
11619 of <tt>C_DRIVE</tt> in the guest OS so
11620 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
11621 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
11622 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
11623 the previous (permanent) definition of <tt>C_DRIVE</tt> that points
11624 to <tt>C:\\</tt> if it still exists.
11625
11626 Note that permanent and transient shared folders of different machines
11627 are in different name spaces, so they don't overlap and don't need to
11628 have unique logical names.
11629
11630 <note>
11631 Global shared folders are not implemented in the current version of the
11632 product.
11633 </note>
11634 </desc>
11635
11636 <attribute name="name" type="wstring" readonly="yes">
11637 <desc>Logical name of the shared folder.</desc>
11638 </attribute>
11639
11640 <attribute name="hostPath" type="wstring" readonly="yes">
11641 <desc>Full path to the shared folder in the host file system.</desc>
11642 </attribute>
11643
11644 <attribute name="accessible" type="boolean" readonly="yes">
11645 <desc>
11646 Whether the folder defined by the host path is currently
11647 accessible or not.
11648 For example, the folder can be unaccessible if it is placed
11649 on the network share that is not available by the time
11650 this property is read.
11651 </desc>
11652 </attribute>
11653
11654 <attribute name="writable" type="boolean" readonly="yes">
11655 <desc>
11656 Whether the folder defined by the host path is writable or
11657 not.
11658 </desc>
11659 </attribute>
11660
11661 <attribute name="lastAccessError" type="wstring" readonly="yes">
11662 <desc>
11663 Text message that represents the result of the last accessibility
11664 check.
11665
11666 Accessibility checks are performed each time the <link to="#accessible"/>
11667 attribute is read. A @c null string is returned if the last
11668 accessibility check was successful. A non-null string indicates a
11669 failure and should normally describe a reason of the failure (for
11670 example, a file read error).
11671 </desc>
11672 </attribute>
11673
11674 </interface>
11675
11676 <!--
11677 // ISession
11678 /////////////////////////////////////////////////////////////////////////
11679 -->
11680
11681 <interface
11682 name="IInternalSessionControl" extends="$unknown"
11683 uuid="2581845a-5a9d-45fb-bc3b-2476552dd970"
11684 internal="yes"
11685 wsmap="suppress"
11686 >
11687 <method name="getPID">
11688 <desc>PID of the process that has created this Session object.
11689 </desc>
11690 <param name="pid" type="unsigned long" dir="return"/>
11691 </method>
11692
11693 <method name="getRemoteConsole">
11694 <desc>
11695 Returns the console object suitable for remote control.
11696
11697 <result name="VBOX_E_INVALID_VM_STATE">
11698 Session state prevents operation.
11699 </result>
11700 <result name="VBOX_E_INVALID_OBJECT_STATE">
11701 Session type prevents operation.
11702 </result>
11703
11704 </desc>
11705 <param name="console" type="IConsole" dir="return"/>
11706 </method>
11707
11708 <method name="assignMachine">
11709 <desc>
11710 Assigns the machine object associated with this direct-type
11711 session or informs the session that it will be a remote one
11712 (if @a machine == NULL).
11713
11714 <result name="VBOX_E_INVALID_VM_STATE">
11715 Session state prevents operation.
11716 </result>
11717 <result name="VBOX_E_INVALID_OBJECT_STATE">
11718 Session type prevents operation.
11719 </result>
11720
11721 </desc>
11722 <param name="machine" type="IMachine" dir="in"/>
11723 </method>
11724
11725 <method name="assignRemoteMachine">
11726 <desc>
11727 Assigns the machine and the (remote) console object associated with
11728 this remote-type session.
11729
11730 <result name="VBOX_E_INVALID_VM_STATE">
11731 Session state prevents operation.
11732 </result>
11733
11734 </desc>
11735 <param name="machine" type="IMachine" dir="in"/>
11736 <param name="console" type="IConsole" dir="in"/>
11737 </method>
11738
11739 <method name="updateMachineState">
11740 <desc>
11741 Updates the machine state in the VM process.
11742 Must be called only in certain cases
11743 (see the method implementation).
11744
11745 <result name="VBOX_E_INVALID_VM_STATE">
11746 Session state prevents operation.
11747 </result>
11748 <result name="VBOX_E_INVALID_OBJECT_STATE">
11749 Session type prevents operation.
11750 </result>
11751
11752 </desc>
11753 <param name="aMachineState" type="MachineState" dir="in"/>
11754 </method>
11755
11756 <method name="uninitialize">
11757 <desc>
11758 Uninitializes (closes) this session. Used by VirtualBox to close
11759 the corresponding remote session when the direct session dies
11760 or gets closed.
11761
11762 <result name="VBOX_E_INVALID_VM_STATE">
11763 Session state prevents operation.
11764 </result>
11765
11766 </desc>
11767 </method>
11768
11769 <method name="onDVDDriveChange">
11770 <desc>
11771 Triggered when settings of the DVD drive object of the
11772 associated virtual machine have changed.
11773
11774 <result name="VBOX_E_INVALID_VM_STATE">
11775 Session state prevents operation.
11776 </result>
11777 <result name="VBOX_E_INVALID_OBJECT_STATE">
11778 Session type prevents operation.
11779 </result>
11780
11781 </desc>
11782 </method>
11783
11784 <method name="onFloppyDriveChange">
11785 <desc>
11786 Triggered when settings of the floppy drive object of the
11787 associated virtual machine have changed.
11788
11789 <result name="VBOX_E_INVALID_VM_STATE">
11790 Session state prevents operation.
11791 </result>
11792 <result name="VBOX_E_INVALID_OBJECT_STATE">
11793 Session type prevents operation.
11794 </result>
11795
11796 </desc>
11797 </method>
11798
11799 <method name="onNetworkAdapterChange">
11800 <desc>
11801 Triggered when settings of a network adapter of the
11802 associated virtual machine have changed.
11803
11804 <result name="VBOX_E_INVALID_VM_STATE">
11805 Session state prevents operation.
11806 </result>
11807 <result name="VBOX_E_INVALID_OBJECT_STATE">
11808 Session type prevents operation.
11809 </result>
11810
11811 </desc>
11812 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
11813 </method>
11814
11815 <method name="onSerialPortChange">
11816 <desc>
11817 Triggered when settings of a serial port of the
11818 associated virtual machine have changed.
11819
11820 <result name="VBOX_E_INVALID_VM_STATE">
11821 Session state prevents operation.
11822 </result>
11823 <result name="VBOX_E_INVALID_OBJECT_STATE">
11824 Session type prevents operation.
11825 </result>
11826
11827 </desc>
11828 <param name="serialPort" type="ISerialPort" dir="in"/>
11829 </method>
11830
11831 <method name="onParallelPortChange">
11832 <desc>
11833 Triggered when settings of a parallel port of the
11834 associated virtual machine have changed.
11835
11836 <result name="VBOX_E_INVALID_VM_STATE">
11837 Session state prevents operation.
11838 </result>
11839 <result name="VBOX_E_INVALID_OBJECT_STATE">
11840 Session type prevents operation.
11841 </result>
11842
11843 </desc>
11844 <param name="parallelPort" type="IParallelPort" dir="in"/>
11845 </method>
11846
11847 <method name="onVRDPServerChange">
11848 <desc>
11849 Triggered when settings of the VRDP server object of the
11850 associated virtual machine have changed.
11851
11852 <result name="VBOX_E_INVALID_VM_STATE">
11853 Session state prevents operation.
11854 </result>
11855 <result name="VBOX_E_INVALID_OBJECT_STATE">
11856 Session type prevents operation.
11857 </result>
11858
11859 </desc>
11860 </method>
11861
11862 <method name="onUSBControllerChange">
11863 <desc>
11864 Triggered when settings of the USB controller object of the
11865 associated virtual machine have changed.
11866
11867 <result name="VBOX_E_INVALID_VM_STATE">
11868 Session state prevents operation.
11869 </result>
11870 <result name="VBOX_E_INVALID_OBJECT_STATE">
11871 Session type prevents operation.
11872 </result>
11873
11874 </desc>
11875 </method>
11876
11877 <method name="onSharedFolderChange">
11878 <desc>
11879 Triggered when a permanent (global or machine) shared folder has been
11880 created or removed.
11881 <note>
11882 We don't pass shared folder parameters in this notification because
11883 the order in which parallel notifications are delivered is not defined,
11884 therefore it could happen that these parameters were outdated by the
11885 time of processing this notification.
11886 </note>
11887
11888 <result name="VBOX_E_INVALID_VM_STATE">
11889 Session state prevents operation.
11890 </result>
11891 <result name="VBOX_E_INVALID_OBJECT_STATE">
11892 Session type prevents operation.
11893 </result>
11894
11895 </desc>
11896 <param name="global" type="boolean" dir="in"/>
11897 </method>
11898
11899 <method name="onUSBDeviceAttach">
11900 <desc>
11901 Triggered when a request to capture a USB device (as a result
11902 of matched USB filters or direct call to
11903 <link to="IConsole::attachUSBDevice"/>) has completed.
11904 A @c null @a error object means success, otherwise it
11905 describes a failure.
11906
11907 <result name="VBOX_E_INVALID_VM_STATE">
11908 Session state prevents operation.
11909 </result>
11910 <result name="VBOX_E_INVALID_OBJECT_STATE">
11911 Session type prevents operation.
11912 </result>
11913
11914 </desc>
11915 <param name="device" type="IUSBDevice" dir="in"/>
11916 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
11917 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
11918 </method>
11919
11920 <method name="onUSBDeviceDetach">
11921 <desc>
11922 Triggered when a request to release the USB device (as a result
11923 of machine termination or direct call to
11924 <link to="IConsole::detachUSBDevice"/>) has completed.
11925 A @c null @a error object means success, otherwise it
11926
11927 <result name="VBOX_E_INVALID_VM_STATE">
11928 Session state prevents operation.
11929 </result>
11930 <result name="VBOX_E_INVALID_OBJECT_STATE">
11931 Session type prevents operation.
11932 </result>
11933
11934 </desc>
11935 <param name="id" type="uuid" dir="in"/>
11936 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
11937 </method>
11938
11939 <method name="onShowWindow">
11940 <desc>
11941 Called by <link to="IMachine::canShowConsoleWindow()"/> and by
11942 <link to="IMachine::showConsoleWindow()"/> in order to notify
11943 console callbacks
11944 <link to="IConsoleCallback::onCanShowWindow()"/>
11945 and <link to="IConsoleCallback::onShowWindow()"/>.
11946
11947 <result name="VBOX_E_INVALID_OBJECT_STATE">
11948 Session type prevents operation.
11949 </result>
11950
11951 </desc>
11952 <param name="check" type="boolean" dir="in"/>
11953 <param name="canShow" type="boolean" dir="out"/>
11954 <param name="winId" type="unsigned long long" dir="out"/>
11955 </method>
11956
11957 <method name="accessGuestProperty">
11958 <desc>
11959 Called by <link to="IMachine::getGuestProperty()"/> and by
11960 <link to="IMachine::setGuestProperty()"/> in order to read and
11961 modify guest properties.
11962
11963 <result name="VBOX_E_INVALID_VM_STATE">
11964 Machine session is not open.
11965 </result>
11966 <result name="VBOX_E_INVALID_OBJECT_STATE">
11967 Session type is not direct.
11968 </result>
11969
11970 </desc>
11971 <param name="name" type="wstring" dir="in"/>
11972 <param name="value" type="wstring" dir="in"/>
11973 <param name="flags" type="wstring" dir="in"/>
11974 <param name="isSetter" type="boolean" dir="in"/>
11975 <param name="retValue" type="wstring" dir="out"/>
11976 <param name="retTimestamp" type="unsigned long long" dir="out"/>
11977 <param name="retFlags" type="wstring" dir="out"/>
11978 </method>
11979
11980 <method name="enumerateGuestProperties">
11981 <desc>
11982 Return a list of the guest properties matching a set of patterns along
11983 with their values, time stamps and flags.
11984
11985 <result name="VBOX_E_INVALID_VM_STATE">
11986 Machine session is not open.
11987 </result>
11988 <result name="VBOX_E_INVALID_OBJECT_STATE">
11989 Session type is not direct.
11990 </result>
11991
11992 </desc>
11993 <param name="patterns" type="wstring" dir="in">
11994 <desc>
11995 The patterns to match the properties against as a comma-separated
11996 string. If this is empty, all properties currently set will be
11997 returned.
11998 </desc>
11999 </param>
12000 <param name="key" type="wstring" dir="out" safearray="yes">
12001 <desc>
12002 The key names of the properties returned.
12003 </desc>
12004 </param>
12005 <param name="value" type="wstring" dir="out" safearray="yes">
12006 <desc>
12007 The values of the properties returned. The array entries match the
12008 corresponding entries in the @a key array.
12009 </desc>
12010 </param>
12011 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
12012 <desc>
12013 The time stamps of the properties returned. The array entries match
12014 the corresponding entries in the @a key array.
12015 </desc>
12016 </param>
12017 <param name="flags" type="wstring" dir="out" safearray="yes">
12018 <desc>
12019 The flags of the properties returned. The array entries match the
12020 corresponding entries in the @a key array.
12021 </desc>
12022 </param>
12023 </method>
12024
12025 </interface>
12026
12027 <interface
12028 name="ISession" extends="$dispatched"
12029 uuid="12F4DCDB-12B2-4ec1-B7CD-DDD9F6C5BF4D"
12030 wsmap="managed"
12031 >
12032 <desc>
12033 The ISession interface represents a serialization primitive for virtual
12034 machines.
12035
12036 With VirtualBox, every time one wishes to manipulate a virtual machine
12037 (e.g. change its settings or start execution), a session object is
12038 required. Such an object must be passed to one of the session methods
12039 that open the given session, which then initiates the machine manipulation.
12040
12041 A session serves several purposes: it identifies to the inter-process VirtualBox
12042 code which process is currently working with the virtual machine, and it ensures
12043 that there are no incompatible requests from several processes for the
12044 same virtual machine. Session objects can therefore be thought of as mutex
12045 semaphores that lock virtual machines to prevent conflicting accesses from
12046 several processes.
12047
12048 How sessions objects are used depends on whether you use the Main API
12049 via COM or via the webservice:
12050
12051 <ul>
12052 <li>When using the COM API directly, an object of the Session class from the
12053 VirtualBox type library needs to be created. In regular COM C++ client code,
12054 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
12055 This object will then act as a local session object in further calls to open
12056 a session.
12057 </li>
12058
12059 <li>In the webservice, the session manager (IWebsessionManager) instead creates
12060 one session object automatically when <link to="IWebsessionManager::logon" />
12061 is called. A managed object reference to that session object can be retrieved by
12062 calling <link to="IWebsessionManager::getSessionObject" />. This session object
12063 reference can then be used to open sessions.
12064 </li>
12065 </ul>
12066
12067 Sessions are mainly used in two variations:
12068
12069 <ul>
12070 <li>
12071 To start a virtual machine in a separate process, one would call
12072 <link to="IVirtualBox::openRemoteSession"/>, which requires a session
12073 object as its first parameter. This session then identifies the caller
12074 and lets him control the started machine (for example, pause machine
12075 execution or power it down) as well as be notified about machine
12076 execution state changes.
12077 </li>
12078
12079 <li>To alter machine settings, or to start machine execution within the
12080 current process, one needs to open a direct session for the machine first by
12081 calling <link to="IVirtualBox::openSession"/>. While a direct session
12082 is open within one process, no any other process may open another direct
12083 session for the same machine. This prevents the machine from being changed
12084 by other processes while it is running or while the machine is being configured.
12085 </li>
12086 </ul>
12087
12088 One also can attach to an existing direct session already opened by
12089 another process (for example, in order to send a control request to the
12090 virtual machine such as the pause or the reset request). This is done by
12091 calling <link to="IVirtualBox::openExistingSession"/>.
12092
12093 <note>
12094 Unless you are trying to write a new VirtualBox front-end that
12095 performs direct machine execution (like the VirtualBox or VBoxSDL
12096 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
12097 session opened by <link to="IVirtualBox::openSession"/> and use this
12098 session only to change virtual machine settings. If you simply want to
12099 start virtual machine execution using one of the existing front-ends
12100 (for example the VirtualBox GUI or headless server), simply use
12101 <link to="IVirtualBox::openRemoteSession"/>; these front-ends
12102 will power up the machine automatically for you.
12103 </note>
12104 </desc>
12105
12106 <attribute name="state" type="SessionState" readonly="yes">
12107 <desc>Current state of this session.</desc>
12108 </attribute>
12109
12110 <attribute name="type" type="SessionType" readonly="yes">
12111 <desc>
12112 Type of this session. The value of this attribute is valid only
12113 if the session is currently open (i.e. its #state is
12114 SessionType_SessionOpen), otherwise an error will be returned.
12115 </desc>
12116 </attribute>
12117
12118 <attribute name="machine" type="IMachine" readonly="yes">
12119 <desc>Machine object associated with this session.</desc>
12120 </attribute>
12121
12122 <attribute name="console" type="IConsole" readonly="yes">
12123 <desc>Console object associated with this session.</desc>
12124 </attribute>
12125
12126 <method name="close">
12127 <desc>
12128 Closes a session that was previously opened.
12129
12130 It is recommended that every time an "open session" method (such as
12131 <link to="IVirtualBox::openRemoteSession" /> or
12132 <link to="IVirtualBox::openSession" />) has been called to
12133 manipulate a virtual machine, the caller invoke
12134 ISession::close() when it's done doing so. Since sessions are
12135 serialization primitives much like ordinary mutexes, they are
12136 best used the same way: for each "open" call, there should be
12137 a matching "close" call, even when errors occur.
12138
12139 Otherwise, if a direct session for a machine opened with
12140 <link to="IVirtualBox::openSession()"/> is not explicitly closed
12141 when the application terminates, the state of the machine will
12142 be set to <link to="MachineState_Aborted" /> on the server.
12143
12144 Generally, it is recommended to close all open sessions explicitly
12145 before terminating the application (regardless of the reason for
12146 the termination).
12147
12148 <note>
12149 Do not expect the session state (<link to="ISession::state" />
12150 to return to "Closed" immediately after you invoke
12151 ISession::close(), particularly if you have started a remote
12152 session to execute the VM in a new process. The session state will
12153 automatically return to "Closed" once the VM is no longer executing,
12154 which can of course take a very long time.
12155 </note>
12156
12157 <result name="E_UNEXPECTED">
12158 Session is not open.
12159 </result>
12160
12161 </desc>
12162 </method>
12163
12164 </interface>
12165
12166 <!--
12167 // ISATAController
12168 /////////////////////////////////////////////////////////////////////////
12169 -->
12170
12171 <interface
12172 name="ISATAController" extends="$unknown"
12173 uuid="9a4b868b-1376-4533-8ef5-065b8e8cedff"
12174 wsmap="managed"
12175 >
12176 <attribute name="enabled" type="boolean">
12177 <desc>
12178 Flag whether the SATA controller is present in the
12179 guest system. If disabled, the virtual guest hardware will
12180 not contain any SATA controller. Can only be changed when
12181 the VM is powered off.
12182 </desc>
12183 </attribute>
12184
12185 <attribute name="portCount" type="unsigned long">
12186 <desc>
12187 The number of usable ports on the SATA controller.
12188 It ranges from 1 to 30.
12189 </desc>
12190 </attribute>
12191
12192 <method name="GetIDEEmulationPort">
12193 <desc>
12194 Gets the corresponding port number which is emulated as an IDE device.
12195
12196 <result name="E_INVALIDARG">
12197 The @a devicePosition is not in the range 0 to 3.
12198 </result>
12199
12200 </desc>
12201 <param name="devicePosition" type="long" dir="in"/>
12202 <param name="portNumber" type="long" dir="return"/>
12203 </method>
12204
12205 <method name="SetIDEEmulationPort">
12206 <desc>
12207 Sets the port number which is emulated as an IDE device.
12208
12209 <result name="E_INVALIDARG">
12210 The @a devicePosition is not in the range 0 to 3 or the
12211 @a portNumber is not in the range 0 to 29.
12212 </result>
12213
12214 </desc>
12215 <param name="devicePosition" type="long" dir="in"/>
12216 <param name="portNumber" type="long" dir="in"/>
12217 </method>
12218
12219 </interface>
12220
12221<if target="wsdl">
12222
12223 <!--
12224 // IManagedObjectRef
12225 /////////////////////////////////////////////////////////////////////////
12226 -->
12227
12228 <interface
12229 name="IManagedObjectRef" extends="$unknown"
12230 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
12231 internal="yes"
12232 wsmap="managed"
12233 wscpp="hardcoded"
12234 >
12235 <desc>
12236 Managed object reference.
12237
12238 Only within the webservice, a managed object reference (which is really
12239 an opaque number) allows a webservice client to address an object
12240 that lives in the address space of the webservice server.
12241
12242 Behind each managed object reference, there is a COM object that lives
12243 in the webservice server's address space. The COM object is not freed
12244 until the managed object reference is released, either by an explicit
12245 call to <link to="IManagedObjectRef::release" /> or by logging off from
12246 the webservice (<link to="IWebsessionManager::logoff" />), which releases
12247 all objects created during the webservice session.
12248
12249 Whenever a method call of the VirtualBox API returns a COM object, the
12250 webservice representation of that method will instead return a
12251 managed object reference, which can then be used to invoke methods
12252 on that object.
12253 </desc>
12254
12255 <method name="getInterfaceName">
12256 <desc>
12257 Returns the name of the interface that this managed object represents,
12258 for example, "IMachine", as a string.
12259 </desc>
12260 <param name="return" type="wstring" dir="return"/>
12261 </method>
12262
12263 <method name="release">
12264 <desc>
12265 Releases this managed object reference and frees the resources that
12266 were allocated for it in the webservice server process. After calling
12267 this method, the identifier of the reference can no longer be used.
12268 </desc>
12269 </method>
12270
12271 </interface>
12272
12273 <!--
12274 // IWebsessionManager
12275 /////////////////////////////////////////////////////////////////////////
12276 -->
12277
12278 <interface
12279 name="IWebsessionManager" extends="$unknown"
12280 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
12281 internal="yes"
12282 wsmap="global"
12283 wscpp="hardcoded"
12284 >
12285 <desc>
12286 Websession manager. This provides essential services
12287 to webservice clients.
12288 </desc>
12289 <method name="logon">
12290 <desc>
12291 Logs a new client onto the webservice and returns a managed object reference to
12292 the IVirtualBox instance, which the client can then use as a basis to further
12293 queries, since all calls to the VirtualBox API are based on the IVirtualBox
12294 interface, in one way or the other.
12295 </desc>
12296 <param name="username" type="wstring" dir="in"/>
12297 <param name="password" type="wstring" dir="in"/>
12298 <param name="return" type="IVirtualBox" dir="return"/>
12299 </method>
12300
12301 <method name="getSessionObject">
12302 <desc>
12303 Returns a managed object reference to the internal ISession object that was created
12304 for this web service session when the client logged on.
12305
12306 <see>ISession</see>
12307 </desc>
12308 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
12309 <param name="return" type="ISession" dir="return"/>
12310 </method>
12311
12312 <method name="logoff">
12313 <desc>
12314 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
12315 and destroys all resources associated with the session (most importantly, all
12316 managed objects created in the server while the session was active).
12317 </desc>
12318 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
12319 </method>
12320
12321 </interface>
12322
12323</if>
12324
12325 <!--
12326 // IPerformanceCollector & friends
12327 /////////////////////////////////////////////////////////////////////////
12328 -->
12329
12330 <interface
12331 name="IPerformanceMetric" extends="$unknown"
12332 uuid="2a1a60ae-9345-4019-ad53-d34ba41cbfe9" wsmap="managed"
12333 >
12334 <desc>
12335 The IPerformanceMetric interface represents parameters of the given
12336 performance metric.
12337 </desc>
12338
12339 <attribute name="metricName" type="wstring" readonly="yes">
12340 <desc>
12341 Name of the metric.
12342 </desc>
12343 </attribute>
12344
12345 <attribute name="object" type="$unknown" readonly="yes">
12346 <desc>
12347 Object this metric belongs to.
12348 </desc>
12349 </attribute>
12350
12351 <attribute name="description" type="wstring" readonly="yes">
12352 <desc>
12353 Textual description of the metric.
12354 </desc>
12355 </attribute>
12356
12357 <attribute name="period" type="unsigned long" readonly="yes">
12358 <desc>
12359 Time interval between samples, measured in seconds.
12360 </desc>
12361 </attribute>
12362
12363 <attribute name="count" type="unsigned long" readonly="yes">
12364 <desc>
12365 Number of recent samples retained by the performance collector for this
12366 metric.
12367
12368 When the collected sample count exceeds this number, older samples
12369 are discarded.
12370 </desc>
12371 </attribute>
12372
12373 <attribute name="unit" type="wstring" readonly="yes">
12374 <desc>
12375 Unit of measurement.
12376 </desc>
12377 </attribute>
12378
12379 <attribute name="minimumValue" type="long" readonly="yes">
12380 <desc>
12381 Minimum possible value of this metric.
12382 </desc>
12383 </attribute>
12384
12385 <attribute name="maximumValue" type="long" readonly="yes">
12386 <desc>
12387 Maximum possible value of this metric.
12388 </desc>
12389 </attribute>
12390 </interface>
12391
12392 <interface
12393 name="IPerformanceCollector" extends="$unknown"
12394 uuid="e22e1acb-ac4a-43bb-a31c-17321659b0c6"
12395 wsmap="managed"
12396 >
12397 <desc>
12398 The IPerformanceCollector interface represents a service that collects and
12399 stores performance metrics data.
12400
12401 Performance metrics are associated with objects like IHost and
12402 IMachine. Each object has a distinct set of performance metrics.
12403 The set can be obtained with <link to="IPerformanceCollector::getMetrics"/>.
12404
12405 Metric data are collected at the specified intervals and are retained
12406 internally. The interval and the number of samples retained can be set
12407 with <link to="IPerformanceCollector::setupMetrics" />.
12408
12409 Metrics are organized hierarchically, each level separated by slash (/).
12410 General scheme for metric name is
12411 "Category/Metric[/SubMetric][:aggregation]". For example CPU/Load/User:avg
12412 metric name stands for: CPU category, Load metric, User submetric, average
12413 aggregate. An aggregate function is computed over all retained data. Valid
12414 aggregate functions are:
12415
12416 <ul>
12417 <li>avg -- average</li>
12418 <li>min -- minimum</li>
12419 <li>max -- maximum</li>
12420 </ul>
12421
12422 "Category/Metric" together form base metric name. A base metric is the
12423 smallest unit for which a sampling interval and the number of retained
12424 samples can be set. Only base metrics can be enabled and disabled. All
12425 sub-metrics are collected when their base metric is collected.
12426 Collected values for any set of sub-metrics can be queried with
12427 <link to="IPerformanceCollector::queryMetricsData" />. When setting up
12428 metric parameters, querying metric data, enabling or disabling metrics
12429 wildcards can be used in metric names to specify a subset of metrics. For
12430 example, to select all CPU-related metrics use <tt>CPU/*</tt>, all
12431 averages can be queried using <tt>*:avg</tt> and so on. To query metric
12432 values without aggregates <tt>*:</tt> can be used.
12433
12434 The valid names for base metrics are:
12435
12436 <ul>
12437 <li>CPU/Load</li>
12438 <li>CPU/MHz</li>
12439 <li>RAM/Usage</li>
12440 </ul>
12441
12442 The general sequence for collecting and retrieving the metrics is:
12443 <ul>
12444 <li>
12445 Obtain an instance of IPerformanceCollector with
12446 <link to="IVirtualBox::performanceCollector" />
12447 </li>
12448 <li>
12449 Allocate and populate an array with references to objects the metrics
12450 will be collected for. Use references to IHost and IMachine objects.
12451 </li>
12452 <li>
12453 Allocate and populate an array with base metric names the data will be
12454 collected for.
12455 </li>
12456 <li>
12457 Call <link to="IPerformanceCollector::setupMetrics" />. From now on the
12458 metric data will be collected and stored.
12459 </li>
12460 <li>
12461 Wait for the data to get collected.
12462 </li>
12463 <li>
12464 Allocate and populate an array with references to objects the metric
12465 values will be queried for. You can re-use the object array used for
12466 setting base metrics.
12467 </li>
12468 <li>
12469 Allocate and populate an array with metric names the data will be
12470 collected for. Note that metric names differ from base metric names.
12471 </li>
12472 <li>
12473 Call <link to="IPerformanceCollector::queryMetricsData" />. The data that
12474 have been collected so far are returned. Note that the values are still
12475 retained internally and data collection continues.
12476 </li>
12477 </ul>
12478
12479 For an example of usage refer to the following files in VirtualBox SDK:
12480 <ul>
12481 <li>
12482 Java: <tt>bindings/webservice/java/jax-ws/samples/metrictest.java</tt>
12483 </li>
12484 <li>
12485 Python: <tt>bindings/xpcom/python/sample/shellcommon.py</tt>
12486 </li>
12487 </ul>
12488 </desc>
12489
12490 <attribute name="metricNames" type="wstring" readonly="yes" safearray="yes">
12491 <desc>
12492 Array of unique names of metrics.
12493
12494 This array represents all metrics supported by the performance
12495 collector. Individual objects do not necessarily support all of them.
12496 <link to="IPerformanceCollector::getMetrics"/> can be used to get the
12497 list of supported metrics for a particular object.
12498 </desc>
12499 </attribute>
12500
12501 <method name="getMetrics">
12502 <desc>
12503 Returns parameters of specified metrics for a set of objects.
12504 <note>
12505 @c Null metrics array means all metrics. @c Null object array means
12506 all existing objects.
12507 </note>
12508 </desc>
12509 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12510 <desc>
12511 Metric name filter. Currently, only a comma-separated list of metrics
12512 is supported.
12513 </desc>
12514 </param>
12515 <param name="objects" type="$unknown" dir="in" safearray="yes">
12516 <desc>
12517 Set of objects to return metric parameters for.
12518 </desc>
12519 </param>
12520 <param name="metrics" type="IPerformanceMetric" dir="return" safearray="yes">
12521 <desc>
12522 Array of returned metric parameters.
12523 </desc>
12524 </param>
12525 </method>
12526
12527 <method name="setupMetrics">
12528 <desc>
12529 Sets parameters of specified base metrics for a set of objects. Returns
12530 an array of <link to="IPerformanceMetric" /> describing the metrics have
12531 been affected.
12532 <note>
12533 @c Null or empty metric name array means all metrics. @c Null or empty
12534 object array means all existing objects. If metric name array contains
12535 a single element and object array contains many, the single metric
12536 name array element is applied to each object array element to form
12537 metric/object pairs.
12538 </note>
12539 </desc>
12540 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12541 <desc>
12542 Metric name filter. Comma-separated list of metrics with wildcard
12543 support.
12544 </desc>
12545 </param>
12546 <param name="objects" type="$unknown" dir="in" safearray="yes">
12547 <desc>
12548 Set of objects to setup metric parameters for.
12549 </desc>
12550 </param>
12551 <param name="period" type="unsigned long" dir="in">
12552 <desc>
12553 Time interval in seconds between two consecutive samples of performance
12554 data.
12555 </desc>
12556 </param>
12557 <param name="count" type="unsigned long" dir="in">
12558 <desc>
12559 Number of samples to retain in performance data history. Older samples
12560 get discarded.
12561 </desc>
12562 </param>
12563 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
12564 <desc>
12565 Array of metrics that have been modified by the call to this method.
12566 </desc>
12567 </param>
12568 </method>
12569
12570 <method name="enableMetrics">
12571 <desc>
12572 Turns on collecting specified base metrics. Returns an array of
12573 <link to="IPerformanceMetric" /> describing the metrics have been
12574 affected.
12575 <note>
12576 @c Null or empty metric name array means all metrics. @c Null or empty
12577 object array means all existing objects. If metric name array contains
12578 a single element and object array contains many, the single metric
12579 name array element is applied to each object array element to form
12580 metric/object pairs.
12581 </note>
12582 </desc>
12583 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12584 <desc>
12585 Metric name filter. Comma-separated list of metrics with wildcard
12586 support.
12587 </desc>
12588 </param>
12589 <param name="objects" type="$unknown" dir="in" safearray="yes">
12590 <desc>
12591 Set of objects to enable metrics for.
12592 </desc>
12593 </param>
12594 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
12595 <desc>
12596 Array of metrics that have been modified by the call to this method.
12597 </desc>
12598 </param>
12599 </method>
12600
12601 <method name="disableMetrics">
12602 <desc>
12603 Turns off collecting specified base metrics. Returns an array of
12604 <link to="IPerformanceMetric" /> describing the metrics have been
12605 affected.
12606 <note>
12607 @c Null or empty metric name array means all metrics. @c Null or empty
12608 object array means all existing objects. If metric name array contains
12609 a single element and object array contains many, the single metric
12610 name array element is applied to each object array element to form
12611 metric/object pairs.
12612 </note>
12613 </desc>
12614 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12615 <desc>
12616 Metric name filter. Comma-separated list of metrics with wildcard
12617 support.
12618 </desc>
12619 </param>
12620 <param name="objects" type="$unknown" dir="in" safearray="yes">
12621 <desc>
12622 Set of objects to disable metrics for.
12623 </desc>
12624 </param>
12625 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
12626 <desc>
12627 Array of metrics that have been modified by the call to this method.
12628 </desc>
12629 </param>
12630 </method>
12631
12632 <method name="queryMetricsData">
12633 <desc>
12634 Queries collected metrics data for a set of objects.
12635
12636 The data itself and related metric information are returned in seven
12637 parallel and one flattened array of arrays. Elements of
12638 <tt>returnMetricNames, returnObjects, returnUnits, returnScales,
12639 returnSequenceNumbers, returnDataIndices and returnDataLengths</tt> with
12640 the same index describe one set of values corresponding to a single
12641 metric.
12642
12643 The <tt>returnData</tt> parameter is a flattened array of arrays. Each
12644 start and length of a sub-array is indicated by
12645 <tt>returnDataIndices</tt> and <tt>returnDataLengths</tt>. The first
12646 value for metric <tt>metricNames[i]</tt> is at
12647 <tt>returnData[returnIndices[i]]</tt>.
12648
12649 <note>
12650 @c Null or empty metric name array means all metrics. @c Null or empty
12651 object array means all existing objects. If metric name array contains
12652 a single element and object array contains many, the single metric
12653 name array element is applied to each object array element to form
12654 metric/object pairs.
12655 </note>
12656 <note>
12657 Data collection continues behind the scenes after call to @c
12658 queryMetricsData. The return data can be seen as the snapshot of
12659 the current state at the time of @c queryMetricsData call. The
12660 internally kept metric values are not cleared by the call. This makes
12661 possible querying different subsets of metrics or aggregates with
12662 subsequent calls. If periodic querying is needed it is highly
12663 suggested to query the values with @c interval*count period to avoid
12664 confusion. This way a completely new set of data values will be
12665 provided by each query.
12666 </note>
12667 </desc>
12668 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12669 <desc>
12670 Metric name filter. Comma-separated list of metrics with wildcard
12671 support.
12672 </desc>
12673 </param>
12674 <param name="objects" type="$unknown" dir="in" safearray="yes">
12675 <desc>
12676 Set of objects to query metrics for.
12677 </desc>
12678 </param>
12679 <param name="returnMetricNames" type="wstring" dir="out" safearray="yes">
12680 <desc>
12681 Names of metrics returned in @c returnData.
12682 </desc>
12683 </param>
12684 <param name="returnObjects" type="$unknown" dir="out" safearray="yes">
12685 <desc>
12686 Objects associated with metrics returned in @c returnData.
12687 </desc>
12688 </param>
12689 <param name="returnUnits" type="wstring" dir="out" safearray="yes">
12690 <desc>
12691 Units of measurement for each returned metric.
12692 </desc>
12693 </param>
12694 <param name="returnScales" type="unsigned long" dir="out" safearray="yes">
12695 <desc>
12696 Divisor that should be applied to return values in order to get
12697 floating point values. For example:
12698 <tt>(double)returnData[returnDataIndices[0]+i] / returnScales[0]</tt>
12699 will retrieve the floating point value of i-th sample of the first
12700 metric.
12701 </desc>
12702 </param>
12703 <param name="returnSequenceNumbers" type="unsigned long" dir="out" safearray="yes">
12704 <desc>
12705 Sequence numbers of the first elements of value sequences of particular metrics
12706 returned in @c returnData. For aggregate metrics it is the sequence number of
12707 the sample the aggregate started calculation from.
12708 </desc>
12709 </param>
12710 <param name="returnDataIndices" type="unsigned long" dir="out" safearray="yes">
12711 <desc>
12712 Indices of the first elements of value sequences of particular metrics
12713 returned in @c returnData.
12714 </desc>
12715 </param>
12716 <param name="returnDataLengths" type="unsigned long" dir="out" safearray="yes">
12717 <desc>
12718 Lengths of value sequences of particular metrics.
12719 </desc>
12720 </param>
12721 <param name="returnData" type="long" dir="return" safearray="yes">
12722 <desc>
12723 Flattened array of all metric data containing sequences of values for
12724 each metric.
12725 </desc>
12726 </param>
12727 </method>
12728
12729 </interface>
12730
12731 <module name="VBoxSVC" context="LocalServer">
12732 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
12733 namespace="virtualbox.org">
12734 <interface name="IVirtualBox" default="yes"/>
12735 </class>
12736 </module>
12737
12738 <module name="VBoxC" context="InprocServer" threadingModel="Free">
12739 <class name="Session" uuid="3C02F46D-C9D2-4f11-A384-53F0CF917214"
12740 namespace="virtualbox.org">
12741 <interface name="ISession" default="yes"/>
12742 </class>
12743 </module>
12744
12745</library>
12746
12747</idl>
12748
12749<!-- vim: set shiftwidth=2 tabstop=2 expandtab: -->
Note: See TracBrowser for help on using the repository browser.

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