VirtualBox

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

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

Main/NetIf: IPv4 properties changed from ULONG to wstring, VBoxManage fixes

  • Property svn:eol-style set to native
File size: 478.8 KB
Line 
1<?xml version="1.0" ?>
2
3<!--
4 * :tabSize=2:indentSize=2:noTabs=true:
5 * :folding=explicit:collapseFolds=1:
6 *
7 * Master declaration for VirtualBox's Main API, represented
8 * by COM/XPCOM and web service interfaces.
9 *
10 * From this document, the build system generates several files
11 * via XSLT that are then used during the build process.
12 *
13 * Below is the list of XSL templates that operate on this file and
14 * output files they generate. These XSL templates must be updated
15 * whenever the schema of this file changes:
16 *
17 * 1. src/VBox/Main/idl/midl.xsl =>
18 * out/<platform>/bin/sdk/idl/VirtualBox.idl
19 * (MS COM interface definition file for Main API)
20 *
21 * 2. src/VBox/Main/idl/xpidl.xsl =>
22 * out/<platform>/bin/sdk/idl/VirtualBox_XPCOM.idl
23 * (XPCOM interface definition file for Main API)
24 *
25 * 3. src/VBox/Main/idl/doxygen.xsl =>
26 * out/<platform>/obj/src/VBox/Main/VirtualBox.idl
27 * (pseudo-IDL for Doxygen to generate the official Main API
28 * documentation)
29 *
30 * 4. src/VBox/Main/webservice/*.xsl =>
31 * a bunch of WSDL and C++ files
32 * (VirtualBox web service sources and SOAP mappers;
33 * see src/VBox/Main/webservice/Makefile.kmk for details)
34 *
35 * 5. src/VBox/Frontends/VirtualBox/include/COMWrappers.xsl =>
36 * out/<platform>/obj/src/VBox/Frontends/VirtualBox/VirtualBox/include/COMWrappers.h
37 * (smart Qt-based C++ wrapper classes for COM interfaces
38 * of the Main API)
39 *
40 * 6. src/VBox/Installer/win32/VirtualBox_TypeLib.xsl =>
41 * out/<platform>/obj/src/VBox/Installer/win32/VirtualBox_TypeLib.wxi
42 * (Main API TypeLib block for the WiX installer)
43 *
44 * 7. src/VBox/Runtime/common/err/errmsgvboxcom.xsl =>
45 * out/<platform>/obj/Runtime/errmsgvboxcomdata.h
46 * (<result> extraction for the %Rhrc format specifier)
47 *
48 Copyright (C) 2006-2009 Sun Microsystems, Inc.
49
50 This file is part of VirtualBox Open Source Edition (OSE), as
51 available from http://www.virtualbox.org. This file is free software;
52 you can redistribute it and/or modify it under the terms of the GNU
53 General Public License (GPL) as published by the Free Software
54 Foundation, in version 2 as it comes in the "COPYING" file of the
55 VirtualBox OSE distribution. VirtualBox OSE is distributed in the
56 hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
57
58 Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
59 Clara, CA 95054 USA or visit http://www.sun.com if you need
60 additional information or have any questions.
61-->
62
63<idl>
64
65<desc>
66 Welcome to the <b>VirtualBox Main API documentation</b>. This documentation
67 describes the so-called <i>VirtualBox Main API</i> which comprises all public
68 COM interfaces and components provided by the VirtualBox server and by the
69 VirtualBox client library.
70
71 VirtualBox employs a client-server design, meaning that whenever any part of
72 VirtualBox is running -- be it the Qt GUI, the VBoxManage command-line
73 interface or any virtual machine --, a dedicated server process named
74 VBoxSVC runs in the background. This allows multiple processes working with
75 VirtualBox to cooperate without conflicts. These processes communicate to each
76 other using inter-process communication facilities provided by the COM
77 implementation of the host computer.
78
79 On Windows platforms, the VirtualBox Main API uses Microsoft COM, a native COM
80 implementation. On all other platforms, Mozilla XPCOM, an open-source COM
81 implementation, is used.
82
83 All the parts that a typical VirtualBox user interacts with (the Qt GUI,
84 the VBoxManage command-line interface and the VBoxVRDP server) are technically
85 front-ends to the Main API and only use the interfaces that are documented
86 in this Main API documentation. This ensures that, with any given release
87 version of VirtualBox, all capabilities of the product that could be useful
88 to an external client program are always exposed by way of this API.
89
90 The VirtualBox Main API (also called the <i>VirtualBox COM library</i>)
91 contains two public component classes:
92 <tt>%VirtualBox.VirtualBox</tt> and <tt>%VirtualBox.Session</tt>, which
93 implement IVirtualBox and ISession interfaces respectively. These two classes
94 are of supreme importance and will be needed in order for any front-end
95 program to do anything useful. It is recommended to read the documentation of
96 the mentioned interfaces first.
97
98 The <tt>%VirtualBox.VirtualBox</tt> class is a singleton. This means that
99 there can be only one object of this class on the local machine at any given
100 time. This object is a parent of many other objects in the VirtualBox COM
101 library and lives in the VBoxSVC process. In fact, when you create an instance
102 of the <tt>VirtualBox.VirtualBox</tt>, the COM subsystem checks if the VBoxSVC
103 process is already running, starts it if not, and returns you a reference to
104 the <tt>VirtualBox</tt> object created in this process. When the last reference
105 to this object is released, the VBoxSVC process ends (with a 5 second delay to
106 protect from too frequent restarts).
107
108 The <tt>%VirtualBox.Session</tt> class is a regular component. You can create
109 as many <tt>Session</tt> objects as you need but all of them will live in a
110 process which issues the object instantiation call. <tt>Session</tt> objects
111 represent virtual machine sessions which are used to configure virtual
112 machines and control their execution.
113</desc>
114
115<if target="midl">
116 <cpp line="enum {"/>
117 <cpp line=" kTypeLibraryMajorVersion = 1,"/>
118 <cpp line=" kTypeLibraryMinorVersion = 0"/>
119 <cpp line="};"/>
120</if>
121
122<if target="xpidl">
123 <!-- NS_IMPL_THREADSAFE_ISUPPORTSxx_CI macros are placed here, for convenience -->
124 <cpp>
125/* currently, nsISupportsImpl.h lacks the below-like macros */
126
127#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1_CI NS_IMPL_QUERY_INTERFACE1_CI
128#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2_CI NS_IMPL_QUERY_INTERFACE2_CI
129
130#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_CI
131# define NS_IMPL_THREADSAFE_ISUPPORTS1_CI(_class, _interface) \
132 NS_IMPL_THREADSAFE_ADDREF(_class) \
133 NS_IMPL_THREADSAFE_RELEASE(_class) \
134 NS_IMPL_THREADSAFE_QUERY_INTERFACE1_CI(_class, _interface) \
135 NS_IMPL_CI_INTERFACE_GETTER1(_class, _interface)
136#endif
137
138#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_CI
139# define NS_IMPL_THREADSAFE_ISUPPORTS2_CI(_class, _i1, _i2) \
140 NS_IMPL_THREADSAFE_ADDREF(_class) \
141 NS_IMPL_THREADSAFE_RELEASE(_class) \
142 NS_IMPL_THREADSAFE_QUERY_INTERFACE2_CI(_class, _i1, _i2) \
143 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
144#endif
145
146#ifndef NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI
147# define NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI(_class, _i1, _ic1) \
148 NS_INTERFACE_MAP_BEGIN(_class) \
149 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
150 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
151 NS_IMPL_QUERY_CLASSINFO(_class) \
152 NS_INTERFACE_MAP_END
153#endif
154
155#ifndef NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI
156# define NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI(_class, _i1, _ic1, \
157 _i2, _ic2) \
158 NS_INTERFACE_MAP_BEGIN(_class) \
159 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i1, _ic1) \
160 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_i2, _ic2) \
161 NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _ic1) \
162 NS_IMPL_QUERY_CLASSINFO(_class) \
163 NS_INTERFACE_MAP_END
164#endif
165
166#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE1_AMBIGUOUS_CI
167#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2_AMBIGUOUS_CI NS_IMPL_QUERY_INTERFACE2_AMBIGUOUS_CI
168
169#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_AMBIGUOUS_CI
170# define NS_IMPL_THREADSAFE_ISUPPORTS1_AMBIGUOUS_CI(_class, _i1, _ic1) \
171 NS_IMPL_THREADSAFE_ADDREF(_class) \
172 NS_IMPL_THREADSAFE_RELEASE(_class) \
173 NS_IMPL_THREADSAFE_QUERY_INTERFACE1_AMBIGUOUS_CI(_class, _i1, _ic1) \
174 NS_IMPL_CI_INTERFACE_GETTER1(_class, _i1)
175#endif
176
177#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_AMBIGUOUS_CI
178# define NS_IMPL_THREADSAFE_ISUPPORTS2_AMBIGUOUS_CI(_class, _i1, _ic1, \
179 _i2, _ic2) \
180 NS_IMPL_THREADSAFE_ADDREF(_class) \
181 NS_IMPL_THREADSAFE_RELEASE(_class) \
182 NS_IMPL_THREADSAFE_QUERY_INTERFACE2_AMBIGUOUS_CI(_class, _i1, _ic1, \
183 _i2, _ic2) \
184 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
185#endif
186 </cpp>
187</if>
188
189<library
190 name="VirtualBox"
191 uuid="46137EEC-703B-4fe5-AFD4-7C9BBBBA0259"
192 version="1.3"
193 desc="VirtualBox Type Library"
194 appUuid="819B4D85-9CEE-493C-B6FC-64FFE759B3C9"
195 supportsErrorInfo="yes"
196>
197
198
199 <!--
200 // COM result codes for VirtualBox
201 /////////////////////////////////////////////////////////////////////////
202 -->
203
204 <descGroup id="VirtualBox_COM_result_codes" title="VirtualBox COM result codes">
205 <desc>
206 This section describes all VirtualBox-specific COM result codes that may
207 be returned by methods of VirtualBox COM interfaces in addition to
208 standard COM result codes.
209
210 Note that along with the result code, every VirtualBox method returns
211 extended error information through the IVirtualBoxErrorInfo interface on
212 failure. This interface is a preferred way to present the error to the end
213 user because it contains a human readable description of the error. Raw
214 result codes, both standard and described in this section, are intended to
215 be used by programs to analyze the reason of a failure and select an
216 appropriate course of action without involving the end user (for example,
217 retry the operation later or make a different call).
218
219 The standard COM result codes that may originate from our methods include:
220
221 <table>
222 <tr><td>E_INVALIDARG</td>
223 <td>
224 Returned when the value of the method's argument is not within the range
225 of valid values. This should not be confused with situations when the
226 value is within the range but simply doesn't suit the current object
227 state and there is a possibility that it will be accepted later (in such
228 cases VirtualBox-specific codes are returned, for example,
229 <link to="VBOX_E_OBJECT_NOT_FOUND"/>).
230 </td>
231 </tr>
232 <tr><td>E_POINTER</td>
233 <td>
234 Returned if a memory pointer for the output argument is invalid (for
235 example, <tt>NULL</tt>). Note that when pointers representing input
236 arguments (such as strings) are invalid, E_INVALIDARG is returned.
237 </td>
238 </tr>
239 <tr><td>E_ACCESSDENIED</td>
240 <td>
241 Returned when the called object is not ready. Since the lifetime of a
242 public COM object cannot be fully controlled by the implementation,
243 VirtualBox maintains the readiness state for all objects it creates and
244 returns this code in response to any method call on the object that was
245 deactivated by VirtualBox and is not functioning any more.
246 </td>
247 </tr>
248 <tr><td>E_OUTOFMEMORY</td>
249 <td>
250 Returned when a memory allocation operation fails.
251 </td>
252 </tr>
253 </table>
254 </desc>
255 </descGroup>
256
257 <!--
258 Note that src/VBox/Runtime/common/err/errmsgvboxcom.xsl will ignore
259 everything in <result>/<desc> after (and including) the first dot, so express
260 the matter of the error code in the first sentence and keep it short.
261 -->
262
263 <result name="VBOX_E_OBJECT_NOT_FOUND" value="0x80BB0001">
264 <desc>
265 Object corresponding to the supplied arguments does not exist.
266 </desc>
267 </result>
268
269 <result name="VBOX_E_INVALID_VM_STATE" value="0x80BB0002">
270 <desc>
271 Current virtual machine state prevents the operation.
272 </desc>
273 </result>
274
275 <result name="VBOX_E_VM_ERROR" value="0x80BB0003">
276 <desc>
277 Virtual machine error occurred attempting the operation.
278 </desc>
279 </result>
280
281 <result name="VBOX_E_FILE_ERROR" value="0x80BB0004">
282 <desc>
283 File not accessible or erroneous file contents.
284 </desc>
285 </result>
286
287 <result name="VBOX_E_IPRT_ERROR" value="0x80BB0005">
288 <desc>
289 Runtime subsystem error.
290 </desc>
291 </result>
292
293 <result name="VBOX_E_PDM_ERROR" value="0x80BB0006">
294 <desc>
295 Pluggable Device Manager error.
296 </desc>
297 </result>
298
299 <result name="VBOX_E_INVALID_OBJECT_STATE" value="0x80BB0007">
300 <desc>
301 Current object state prohibits operation.
302 </desc>
303 </result>
304
305 <result name="VBOX_E_HOST_ERROR" value="0x80BB0008">
306 <desc>
307 Host operating system related error.
308 </desc>
309 </result>
310
311 <result name="VBOX_E_NOT_SUPPORTED" value="0x80BB0009">
312 <desc>
313 Requested operation is not supported.
314 </desc>
315 </result>
316
317 <result name="VBOX_E_XML_ERROR" value="0x80BB000A">
318 <desc>
319 Invalid XML found.
320 </desc>
321 </result>
322
323 <result name="VBOX_E_INVALID_SESSION_STATE" value="0x80BB000B">
324 <desc>
325 Current session state prohibits operation.
326 </desc>
327 </result>
328
329 <result name="VBOX_E_OBJECT_IN_USE" value="0x80BB000C">
330 <desc>
331 Object being in use prohibits operation.
332 </desc>
333 </result>
334
335 <!--
336 Note that src/VBox/Runtime/common/err/errmsgvboxcom.xsl will ignore
337 everything in <result>/<desc> after (and including) the first dot, so express
338 the matter of the error code in the first sentence and keep it short.
339 -->
340
341 <descGroup/>
342
343 <!--
344 // all common enums
345 /////////////////////////////////////////////////////////////////////////
346 -->
347
348 <enum
349 name="TSBool"
350 uuid="523ff64d-842a-4b1a-80e7-c311b028cb3a"
351 >
352 <desc>
353 Boolean variable having a third state, default.
354 </desc>
355
356 <const name="False" value="0"/>
357 <const name="True" value="1"/>
358 <const name="Default" value="2"/>
359 </enum>
360
361 <enum
362 name="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::attachHardDisk"/>).
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="ClipboardMode"
719 uuid="33364716-4008-4701-8f14-be0fa3d62950"
720 >
721 <desc>
722 Host-Guest clipboard interchange mode.
723 </desc>
724
725 <const name="Disabled" value="0"/>
726 <const name="HostToGuest" value="1"/>
727 <const name="GuestToHost" value="2"/>
728 <const name="Bidirectional" value="3"/>
729 </enum>
730
731 <enum
732 name="Scope"
733 uuid="7c91096e-499e-4eca-9f9b-9001438d7855"
734 >
735 <desc>
736 Scope of the operation.
737
738 A generic enumeration used in various methods to define the action or
739 argument scope.
740 </desc>
741
742 <const name="Global" value="0"/>
743 <const name="Machine" value="1"/>
744 <const name="Session" value="2"/>
745 </enum>
746
747 <enum
748 name="GuestStatisticType"
749 uuid="aa7c1d71-aafe-47a8-9608-27d2d337cf55"
750 >
751 <desc>
752 Statistics type for <link to="IGuest::getStatistic"/>.
753 </desc>
754
755 <const name="CPULoad_Idle" value="0">
756 <desc>
757 Idle CPU load (0-100%) for last interval.
758 </desc>
759 </const>
760 <const name="CPULoad_Kernel" value="1">
761 <desc>
762 Kernel CPU load (0-100%) for last interval.
763 </desc>
764 </const>
765 <const name="CPULoad_User" value="2">
766 <desc>
767 User CPU load (0-100%) for last interval.
768 </desc>
769 </const>
770 <const name="Threads" value="3">
771 <desc>
772 Total number of threads in the system.
773 </desc>
774 </const>
775 <const name="Processes" value="4">
776 <desc>
777 Total number of processes in the system.
778 </desc>
779 </const>
780 <const name="Handles" value="5">
781 <desc>
782 Total number of handles in the system.
783 </desc>
784 </const>
785 <const name="MemoryLoad" value="6">
786 <desc>
787 Memory load (0-100%).
788 </desc>
789 </const>
790 <const name="PhysMemTotal" value="7">
791 <desc>
792 Total physical memory in megabytes.
793 </desc>
794 </const>
795 <const name="PhysMemAvailable" value="8">
796 <desc>
797 Free physical memory in megabytes.
798 </desc>
799 </const>
800 <const name="PhysMemBalloon" value="9">
801 <desc>
802 Ballooned physical memory in megabytes.
803 </desc>
804 </const>
805 <const name="MemCommitTotal" value="10">
806 <desc>
807 Total amount of memory in the committed state in megabytes.
808 </desc>
809 </const>
810 <const name="MemKernelTotal" value="11">
811 <desc>
812 Total amount of memory used by the guest OS's kernel in megabytes.
813 </desc>
814 </const>
815 <const name="MemKernelPaged" value="12">
816 <desc>
817 Total amount of paged memory used by the guest OS's kernel in megabytes.
818 </desc>
819 </const>
820 <const name="MemKernelNonpaged" value="13">
821 <desc>
822 Total amount of non-paged memory used by the guest OS's kernel in megabytes.
823 </desc>
824 </const>
825 <const name="MemSystemCache" value="14">
826 <desc>
827 Total amount of memory used by the guest OS's system cache in megabytes.
828 </desc>
829 </const>
830 <const name="PageFileSize" value="15">
831 <desc>
832 Pagefile size in megabytes.
833 </desc>
834 </const>
835 <const name="SampleNumber" value="16">
836 <desc>
837 Statistics sample number
838 </desc>
839 </const>
840 <const name="MaxVal" value="17"/>
841 </enum>
842
843 <enum
844 name="BIOSBootMenuMode"
845 uuid="ae4fb9f7-29d2-45b4-b2c7-d579603135d5"
846 >
847 <desc>
848 BIOS boot menu mode.
849 </desc>
850
851 <const name="Disabled" value="0"/>
852 <const name="MenuOnly" value="1"/>
853 <const name="MessageAndMenu" value="2"/>
854 </enum>
855
856 <enum
857 name="DriveState"
858 uuid="cb7233b7-c519-42a5-8310-1830953cacbc"
859 >
860 <const name="Null" value="0">
861 <desc>Null value (never used by the API).</desc>
862 </const>
863 <const name="NotMounted" value="1"/>
864 <const name="ImageMounted" value="2"/>
865 <const name="HostDriveCaptured" value="3"/>
866 </enum>
867
868 <enum
869 name="ProcessorFeature"
870 uuid="b8353b35-705d-4796-9967-ebfb7ba54af4"
871 >
872 <desc>
873 CPU features.
874 </desc>
875
876 <const name="HWVirtEx" value="0"/>
877 <const name="PAE" value="1"/>
878 <const name="LongMode" value="2"/>
879 </enum>
880
881
882 <!--
883 // IVirtualBoxErrorInfo
884 /////////////////////////////////////////////////////////////////////////
885 -->
886
887 <interface
888 name="IVirtualBoxErrorInfo" extends="$errorinfo"
889 uuid="e98b5376-8eb4-4eea-812a-3964bf3bb26f"
890 supportsErrorInfo="no"
891 wsmap="suppress"
892 >
893 <desc>
894 The IVirtualBoxErrorInfo interface represents extended error information.
895
896 Extended error information can be set by VirtualBox components after
897 unsuccessful or partially successful method invocation. This information
898 can be retrieved by the calling party as an IVirtualBoxErrorInfo object
899 and then shown to the client in addition to the plain 32-bit result code.
900
901 In MS COM, this interface extends the IErrorInfo interface,
902 in XPCOM, it extends the nsIException interface. In both cases,
903 it provides a set of common attributes to retrieve error
904 information.
905
906 Sometimes invocation of some component's method may involve methods of
907 other components that may also fail (independently of this method's
908 failure), or a series of non-fatal errors may precede a fatal error that
909 causes method failure. In cases like that, it may be desirable to preserve
910 information about all errors happened during method invocation and deliver
911 it to the caller. The <link to="#next"/> attribute is intended
912 specifically for this purpose and allows to represent a chain of errors
913 through a single IVirtualBoxErrorInfo object set after method invocation.
914
915 Note that errors are stored to a chain in the reverse order, i.e. the
916 initial error object you query right after method invocation is the last
917 error set by the callee, the object it points to in the @a next attribute
918 is the previous error and so on, up to the first error (which is the last
919 in the chain).
920 </desc>
921
922 <attribute name="resultCode" type="result" readonly="yes">
923 <desc>
924 Result code of the error.
925 Usually, it will be the same as the result code returned
926 by the method that provided this error information, but not
927 always. For example, on Win32, CoCreateInstance() will most
928 likely return E_NOINTERFACE upon unsuccessful component
929 instantiation attempt, but not the value the component factory
930 returned.
931 <note>
932 In MS COM, there is no equivalent.
933 In XPCOM, it is the same as nsIException::result.
934 </note>
935 </desc>
936 </attribute>
937
938 <attribute name="interfaceID" type="uuid" readonly="yes">
939 <desc>
940 UUID of the interface that defined the error.
941 <note>
942 In MS COM, it is the same as IErrorInfo::GetGUID.
943 In XPCOM, there is no equivalent.
944 </note>
945 </desc>
946 </attribute>
947
948 <attribute name="component" type="wstring" readonly="yes">
949 <desc>
950 Name of the component that generated the error.
951 <note>
952 In MS COM, it is the same as IErrorInfo::GetSource.
953 In XPCOM, there is no equivalent.
954 </note>
955 </desc>
956 </attribute>
957
958 <attribute name="text" type="wstring" readonly="yes">
959 <desc>
960 Text description of the error.
961 <note>
962 In MS COM, it is the same as IErrorInfo::GetDescription.
963 In XPCOM, it is the same as nsIException::message.
964 </note>
965 </desc>
966 </attribute>
967
968 <attribute name="next" type="IVirtualBoxErrorInfo" readonly="yes">
969 <desc>
970 Next error object if there is any, or @c null otherwise.
971 <note>
972 In MS COM, there is no equivalent.
973 In XPCOM, it is the same as nsIException::inner.
974 </note>
975 </desc>
976 </attribute>
977
978 </interface>
979
980
981 <!--
982 // IVirtualBox
983 /////////////////////////////////////////////////////////////////////////
984 -->
985
986 <interface
987 name="IVirtualBoxCallback" extends="$unknown"
988 uuid="5516cc08-fb81-47a6-b184-031e7bbd2997"
989 wsmap="suppress"
990 >
991 <method name="onMachineStateChange">
992 <desc>
993 The execution state of the given machine has changed.
994 <see>IMachine::state</see>
995 </desc>
996 <param name="machineId" type="uuid" dir="in">
997 <desc>ID of the machine this event relates to.</desc>
998 </param>
999 <param name="state" type="MachineState" dir="in">
1000 <desc>New execution state.</desc>
1001 </param>
1002 </method>
1003
1004 <method name="onMachineDataChange">
1005 <desc>
1006 Any of the settings of the given machine has changed.
1007 </desc>
1008 <param name="machineId" type="uuid" dir="in">
1009 <desc>ID of the machine this event relates to.</desc>
1010 </param>
1011 </method>
1012
1013 <method name="onExtraDataCanChange">
1014 <desc>
1015 Notification when someone tries to change extra data for
1016 either the given machine or (if null) global extra data.
1017 This gives the chance to veto against changes.
1018 </desc>
1019 <param name="machineId" type="uuid" dir="in">
1020 <desc>
1021 ID of the machine this event relates to
1022 (null ID for global extra data change requests).
1023 </desc>
1024 </param>
1025 <param name="key" type="wstring" dir="in">
1026 <desc>
1027 Extra data key for the attempted write.
1028 </desc>
1029 </param>
1030 <param name="value" type="wstring" dir="in">
1031 <desc>
1032 Extra data value for the given key.
1033 </desc>
1034 </param>
1035 <param name="error" type="wstring" dir="out">
1036 <desc>
1037 Optional error message describing the reason of the
1038 veto (ignored if this notification returns @c true).
1039 </desc>
1040 </param>
1041 <param name="allowChange" type="boolean" dir="return">
1042 <desc>
1043 Flag to indicate whether the callee agrees (@c true)
1044 or vetoes against the change (@c false).
1045 </desc>
1046 </param>
1047 </method>
1048
1049 <method name="onExtraDataChange">
1050 <desc>
1051 Notification when machine specific or global extra data
1052 has changed.
1053 </desc>
1054 <param name="machineId" type="uuid" dir="in">
1055 <desc>
1056 ID of the machine this event relates to.
1057 Null for global extra data changes.
1058 </desc>
1059 </param>
1060 <param name="key" type="wstring" dir="in">
1061 <desc>
1062 Extra data key that has changed.
1063 </desc>
1064 </param>
1065 <param name="value" type="wstring" dir="in">
1066 <desc>
1067 Extra data value for the given key.
1068 </desc>
1069 </param>
1070 </method>
1071
1072 <method name="onMediaRegistered">
1073 <desc>
1074 The given media was registered or unregistered
1075 within this VirtualBox installation.
1076
1077 The @a mediaType parameter describes what type of
1078 media the specified @a mediaId refers to. Possible
1079 values are:
1080
1081 <ul>
1082 <li><link to="DeviceType_HardDisk"/>: the media is a hard disk
1083 that, if registered, can be obtained using the
1084 <link to="IVirtualBox::getHardDisk"/> call.</li>
1085 <li><link to="DeviceType_DVD"/>: the media is a CD/DVD image
1086 that, if registered, can be obtained using the
1087 <link to="IVirtualBox::getDVDImage"/> call.</li>
1088 <li><link to="DeviceType_Floppy"/>: the media is a Floppy image
1089 that, if registered, can be obtained using the
1090 <link to="IVirtualBox::getFloppyImage"/> call.</li>
1091 </ul>
1092
1093 Note that if this is a deregistration notification,
1094 there is no way to access the object representing the
1095 unregistered media. It is supposed that the
1096 application will do required cleanup based on the
1097 @a mediaId value.
1098 </desc>
1099 <param name="mediaId" type="uuid" dir="in">
1100 <desc>ID of the media this event relates to.</desc>
1101 </param>
1102 <param name="mediaType" type="DeviceType" dir="in">
1103 <desc>Type of the media this event relates to.</desc>
1104 </param>
1105 <param name="registered" type="boolean" dir="in">
1106 <desc>
1107 If true, the media was registered, otherwise it was
1108 unregistered.
1109 </desc>
1110 </param>
1111 </method>
1112
1113 <method name="onMachineRegistered">
1114 <desc>
1115 The given machine was registered or unregistered
1116 within this VirtualBox installation.
1117 </desc>
1118 <param name="machineId" type="uuid" dir="in">
1119 <desc>ID of the machine this event relates to.</desc>
1120 </param>
1121 <param name="registered" type="boolean" dir="in">
1122 <desc>
1123 If true, the machine was registered, otherwise it was
1124 unregistered.
1125 </desc>
1126 </param>
1127 </method>
1128
1129 <method name="onSessionStateChange">
1130 <desc>
1131 The state of the session for the given machine was changed.
1132 <see>IMachine::sessionState</see>
1133 </desc>
1134 <param name="machineId" type="uuid" dir="in">
1135 <desc>ID of the machine this event relates to.</desc>
1136 </param>
1137 <param name="state" type="SessionState" dir="in">
1138 <desc>New session state.</desc>
1139 </param>
1140 </method>
1141
1142 <method name="onSnapshotTaken">
1143 <desc>
1144 A new snapshot of the machine has been taken.
1145 <see>ISnapshot</see>
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="snapshotId" type="uuid" dir="in">
1151 <desc>ID of the new snapshot.</desc>
1152 </param>
1153 </method>
1154
1155 <method name="onSnapshotDiscarded">
1156 <desc>
1157 Snapshot of the given machine has been discarded.
1158
1159 <note>
1160 This notification is delivered <b>after</b> the snapshot
1161 object has been uninitialized on the server (so that any
1162 attempt to call its methods will return an error).
1163 </note>
1164
1165 <see>ISnapshot</see>
1166 </desc>
1167 <param name="machineId" type="uuid" dir="in">
1168 <desc>ID of the machine this event relates to.</desc>
1169 </param>
1170 <param name="snapshotId" type="uuid" dir="in">
1171 <desc>
1172 ID of the discarded snapshot. <tt>null</tt> means the
1173 current machine state has been discarded (restored from
1174 the current snapshot).
1175 </desc>
1176 </param>
1177 </method>
1178
1179 <method name="onSnapshotChange">
1180 <desc>
1181 Snapshot properties (name and/or description) have been changed.
1182 <see>ISnapshot</see>
1183 </desc>
1184 <param name="machineId" type="uuid" dir="in">
1185 <desc>ID of the machine this event relates to.</desc>
1186 </param>
1187 <param name="snapshotId" type="uuid" dir="in">
1188 <desc>ID of the changed snapshot.</desc>
1189 </param>
1190 </method>
1191
1192 <method name="onGuestPropertyChange">
1193 <desc>
1194 Notification when a guest property has changed.
1195 </desc>
1196 <param name="machineId" type="uuid" dir="in">
1197 <desc>
1198 ID of the machine this event relates to.
1199 </desc>
1200 </param>
1201 <param name="name" type="wstring" dir="in">
1202 <desc>
1203 The name of the property that has changed.
1204 </desc>
1205 </param>
1206 <param name="value" type="wstring" dir="in">
1207 <desc>
1208 The new property value.
1209 </desc>
1210 </param>
1211 <param name="flags" type="wstring" dir="in">
1212 <desc>
1213 The new property flags.
1214 </desc>
1215 </param>
1216 </method>
1217
1218 </interface>
1219
1220 <interface
1221 name="IVirtualBox" extends="$dispatched"
1222 uuid="18c00639-2bc0-4d5f-93a0-5f20372f9914"
1223 wsmap="managed"
1224 >
1225 <desc>
1226 The IVirtualBox interface represents the main interface exposed by the
1227 product that provides virtual machine management.
1228
1229 An instance of IVirtualBox is required for the product to do anything
1230 useful. Even though the interface does not expose this, internally,
1231 IVirtualBox is implemented as a singleton and actually lives in the
1232 process of the VirtualBox server (VBoxSVC.exe). This makes sure that
1233 IVirtualBox can track the state of all virtual machines on a particular
1234 host, regardless of which frontend started them.
1235
1236 To enumerate all the virtual machines on the host, use the
1237 <link to="IVirtualBox::machines"/> attribute.
1238 </desc>
1239
1240 <attribute name="version" type="wstring" readonly="yes">
1241 <desc>
1242 A string representing the version number of the product. The
1243 format is 3 integer numbers divided by dots (e.g. 1.0.1). The
1244 last number represents the build number and will frequently change.
1245 </desc>
1246 </attribute>
1247
1248 <attribute name="revision" type="unsigned long" readonly="yes">
1249 <desc>
1250 The internal build revision number of the product.
1251 </desc>
1252 </attribute>
1253
1254 <attribute name="packageType" type="wstring" readonly="yes">
1255 <desc>
1256 A string representing the package type of this product. The
1257 format is OS_ARCH_DIST where OS is either WINDOWS, LINUX,
1258 SOLARIS, DARWIN. ARCH is either 32BITS or 64BITS. DIST
1259 is either GENERIC, UBUNTU_606, UBUNTU_710, or something like
1260 this.
1261 </desc>
1262 </attribute>
1263
1264 <attribute name="homeFolder" type="wstring" readonly="yes">
1265 <desc>
1266 Full path to the directory where the global settings file,
1267 <tt>VirtualBox.xml</tt>, is stored.
1268
1269 In this version of VirtualBox, the value of this property is
1270 always <tt>&lt;user_dir&gt;/.VirtualBox</tt> (where
1271 <tt>&lt;user_dir&gt;</tt> is the path to the user directory,
1272 as determined by the host OS), and cannot be changed.
1273
1274 This path is also used as the base to resolve relative paths in
1275 places where relative paths are allowed (unless otherwise
1276 expressly indicated).
1277 </desc>
1278 </attribute>
1279
1280 <attribute name="settingsFilePath" type="wstring" readonly="yes">
1281 <desc>
1282 Full name of the global settings file.
1283 The value of this property corresponds to the value of
1284 <link to="#homeFolder"/> plus <tt>/VirtualBox.xml</tt>.
1285 </desc>
1286 </attribute>
1287
1288 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
1289 <desc>
1290 Current version of the format of the global VirtualBox settings file
1291 (<tt>VirtualBox.xml</tt>).
1292
1293 The version string has the following format:
1294 <pre>
1295 x.y-platform
1296 </pre>
1297 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
1298 versions, and <tt>platform</tt> is the platform identifier.
1299
1300 The current version usually matches the value of the
1301 <link to="#settingsFormatVersion"/> attribute unless the
1302 settings file was created by an older version of VirtualBox and there
1303 was a change of the settings file format since then.
1304
1305 Note that VirtualBox automatically converts settings files from older
1306 versions to the most recent version when reading them (usually at
1307 VirtualBox startup) but it doesn't save the changes back until
1308 you call a method that implicitly saves settings (such as
1309 <link to="#setExtraData"/>) or call <link to="#saveSettings"/>
1310 explicitly. Therefore, if the value of this attribute differs from the
1311 value of <link to="#settingsFormatVersion"/>, then it
1312 means that the settings file was converted but the result of the
1313 conversion is not yet saved to disk.
1314
1315 The above feature may be used by interactive front-ends to inform users
1316 about the settings file format change and offer them to explicitly save
1317 all converted settings files (the global and VM-specific ones),
1318 optionally create backup copies of the old settings files before saving,
1319 etc.
1320
1321 <see>settingsFormatVersion, saveSettingsWithBackup()</see>
1322 </desc>
1323 </attribute>
1324
1325 <attribute name="settingsFormatVersion" type="wstring" readonly="yes">
1326 <desc>
1327 Most recent version of the settings file format.
1328
1329 The version string has the following format:
1330 <pre>
1331 x.y-platform
1332 </pre>
1333 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
1334 versions, and <tt>platform</tt> is the platform identifier.
1335
1336 VirtualBox uses this version of the format when saving settings files
1337 (either as a result of method calls that require to save settings or as
1338 a result of an explicit call to <link to="#saveSettings"/>).
1339
1340 <see>settingsFileVersion</see>
1341 </desc>
1342 </attribute>
1343
1344 <attribute name="host" type="IHost" readonly="yes">
1345 <desc>Associated host object.</desc>
1346 </attribute>
1347
1348 <attribute name="systemProperties" type="ISystemProperties" readonly="yes">
1349 <desc>Associated system information object.</desc>
1350 </attribute>
1351
1352 <attribute name="machines" type="IMachine" readonly="yes" safearray="yes">
1353 <desc>
1354 Array of machine objects registered within this VirtualBox instance.
1355 </desc>
1356 </attribute>
1357
1358 <attribute name="hardDisks" type="IHardDisk" readonly="yes" safearray="yes">
1359 <desc>
1360 Array of hard disk objects known to this VirtualBox installation.
1361
1362 This array contains only base (root) hard disks. All differencing
1363 hard disks of the given base hard disk can be enumerated using
1364 <link to="IHardDisk::children"/>.
1365 </desc>
1366 </attribute>
1367
1368 <attribute name="DVDImages" type="IDVDImage" readonly="yes" safearray="yes">
1369 <desc>
1370 Array of CD/DVD image objects registered with this VirtualBox instance.
1371 </desc>
1372 </attribute>
1373
1374 <attribute name="floppyImages" type="IFloppyImage" readonly="yes" safearray="yes">
1375 <desc>
1376 Array of floppy image objects registered with this VirtualBox instance.
1377 </desc>
1378 </attribute>
1379
1380 <attribute name="progressOperations" type="IProgress" readonly="yes" safearray="yes"/>
1381
1382 <attribute name="guestOSTypes" type="IGuestOSType" readonly="yes" safearray="yes"/>
1383
1384 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
1385 <desc>
1386 Collection of global shared folders. Global shared folders are
1387 available to all virtual machines.
1388
1389 New shared folders are added to the collection using
1390 <link to="#createSharedFolder"/>. Existing shared folders can be
1391 removed using <link to="#removeSharedFolder"/>.
1392
1393 <note>
1394 In the current version of the product, global shared folders are not
1395 implemented and therefore this collection is always empty.
1396 </note>
1397 </desc>
1398 </attribute>
1399
1400 <attribute name="performanceCollector" type="IPerformanceCollector" readonly="yes">
1401 <desc>
1402 Associated performance collector object.
1403 </desc>
1404 </attribute>
1405
1406 <method name="createMachine">
1407 <desc>
1408 Creates a new virtual machine.
1409
1410 The new machine is created unregistered, with the initial configuration
1411 set according to the specified guest OS type. A typical sequence of
1412 actions to create a new virtual machine is as follows:
1413
1414 <ol>
1415 <li>
1416 Call this method to have a new machine created. The returned machine
1417 object will be "mutable" allowing to change any machine property.
1418 </li>
1419
1420 <li>
1421 Configure the machine using the appropriate attributes and methods.
1422 </li>
1423
1424 <li>
1425 Call <link to="IMachine::saveSettings" /> to write the settings
1426 to the machine's XML settings file. The configuration of the newly
1427 created machine will not be saved to disk until this method is
1428 called.
1429 </li>
1430
1431 <li>
1432 Call <link to="#registerMachine" /> to add the machine to the list
1433 of machines known to VirtualBox.
1434 </li>
1435 </ol>
1436
1437 You should specify valid name for the newly created machine when calling
1438 this method. See the <link to="IMachine::name"/> attribute description
1439 for more details about the machine name.
1440
1441 The specified guest OS type identifier must match an ID of one of known
1442 guest OS types listed in the <link to="IVirtualBox::guestOSTypes"/>
1443 array.
1444
1445 Every machine has a <i>settings file</i> that is used to store
1446 the machine configuration. This file is stored in a directory called the
1447 <i>machine settings subfolder</i>. Both the settings subfolder and file
1448 will have a name that corresponds to the name of the virtual machine.
1449 You can specify where to create the machine setting subfolder using the
1450 @a baseFolder argument. The base folder can be absolute (full path) or
1451 relative to the <link to="IVirtualBox::homeFolder">VirtualBox home
1452 directory</link>.
1453
1454 If @a baseFolder is a null or empty string (which is recommended), the
1455 <link to="ISystemProperties::defaultMachineFolder">default machine
1456 settings folder</link> will be used as a base folder for the created
1457 machine. Otherwise the given base folder will be used. In either case,
1458 the full path to the resulting settings file has the following
1459 structure:
1460 <pre>
1461 &lt;base_folder&gt;/&lt;machine_name&gt;/&lt;machine_name&gt;.xml
1462 </pre>
1463
1464 Note that if the resulting settings file already exists, this method
1465 will fail with <link to="VBOX_E_FILE_ERROR"/>.
1466
1467 Optionally, you may specify an UUID of to assign to the created machine.
1468 However, this is not recommended and you should normally pass an empty
1469 (null) UUID to this method so that a new UUID will be automatically
1470 generated for every created machine. You can use UUID
1471 00000000-0000-0000-0000-000000000000 as null value.
1472
1473 <note>
1474 There is no way to change the name of the settings file or
1475 subfolder of the created machine directly.
1476 </note>
1477
1478 <result name="VBOX_E_OBJECT_NOT_FOUND">
1479 @a osTypeId is invalid.
1480 </result>
1481 <result name="VBOX_E_FILE_ERROR">
1482 Resulting settings file name is invalid or the settings file already
1483 exists or could not be created due to an I/O error.
1484 </result>
1485 <result name="E_INVALIDARG">
1486 @a name is empty or null.
1487 </result>
1488 </desc>
1489
1490 <param name="name" type="wstring" dir="in">
1491 <desc>Machine name.</desc>
1492 </param>
1493 <param name="osTypeId" type="wstring" dir="in">
1494 <desc>Guest OS Type ID.</desc>
1495 </param>
1496 <param name="baseFolder" type="wstring" dir="in">
1497 <desc>Base machine folder (optional).</desc>
1498 </param>
1499 <param name="id" type="uuid" dir="in">
1500 <desc>Machine UUID (optional).</desc>
1501 </param>
1502 <param name="machine" type="IMachine" dir="return">
1503 <desc>Created machine object.</desc>
1504 </param>
1505 </method>
1506
1507 <method name="createLegacyMachine">
1508 <desc>
1509 Creates a new virtual machine in "legacy" mode, using the specified
1510 settings file to store machine settings.
1511
1512 As opposed to machines created by <link to="#createMachine"/>,
1513 the settings file of the machine created in "legacy" mode is not
1514 automatically renamed when the machine name is changed -- it will always
1515 remain the same as specified in this method call.
1516
1517 The specified settings file name can be absolute (full path) or relative
1518 to the <link to="IVirtualBox::homeFolder">VirtualBox home
1519 directory</link>. If the file name doesn't contain an extension, the
1520 default extension (.xml) will be appended.
1521
1522 Note that the configuration of the newly created machine is not
1523 saved to disk (and therefore no settings file is created)
1524 until <link to="IMachine::saveSettings"/> is called. If the
1525 specified settings file already exists, this method
1526 will fail with <link to="VBOX_E_FILE_ERROR"/>..
1527
1528 See <link to="#createMachine"/> for more information.
1529
1530 @deprecated This method may be removed later. Use <link
1531 to="IVirtualBox::createMachine"/> instead.
1532
1533 <note>
1534 There is no way to change the name of the settings file
1535 of the machine created in "legacy" mode.
1536 </note>
1537
1538 <result name="VBOX_E_OBJECT_NOT_FOUND">
1539 @a osTypeId is invalid.
1540 </result>
1541 <result name="VBOX_E_FILE_ERROR">
1542 @a settingsFile is invalid or the settings file already exists or
1543 could not be created due to an I/O error.
1544 </result>
1545 <result name="E_INVALIDARG">
1546 @a name or @a settingsFile is empty or null.
1547 </result>
1548 </desc>
1549
1550 <param name="name" type="wstring" dir="in">
1551 <desc>Machine name.</desc>
1552 </param>
1553 <param name="osTypeId" type="wstring" dir="in">
1554 <desc>Machine OS Type ID.</desc>
1555 </param>
1556 <param name="settingsFile" type="wstring" dir="in">
1557 <desc>Name of the machine settings file.</desc>
1558 </param>
1559 <param name="id" type="uuid" dir="in">
1560 <desc>Machine UUID (optional).</desc>
1561 </param>
1562 <param name="machine" type="IMachine" dir="return">
1563 <desc>Created machine object.</desc>
1564 </param>
1565 </method>
1566
1567 <method name="openMachine">
1568 <desc>
1569 Opens a virtual machine from the existing settings file.
1570 The opened machine remains unregistered until you call
1571 <link to="#registerMachine"/>.
1572
1573 The specified settings file name can be absolute
1574 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1575 VirtualBox home directory</link>. This file must exist
1576 and must be a valid machine settings file whose contents
1577 will be used to construct the machine object.
1578
1579 @deprecated Will be removed soon.
1580 <result name="VBOX_E_FILE_ERROR">
1581 Settings file name invalid, not found or sharing violation.
1582 </result>
1583 </desc>
1584 <param name="settingsFile" type="wstring" dir="in">
1585 <desc>
1586 Name of the machine settings file.
1587 </desc>
1588 </param>
1589 <param name="machine" type="IMachine" dir="return">
1590 <desc>Opened machine object.</desc>
1591 </param>
1592 <note>
1593 <link to="IMachine::settingsModified"/> will return
1594 false for the created machine, until any of machine settings
1595 are changed.
1596 </note>
1597 </method>
1598
1599 <method name="registerMachine">
1600 <desc>
1601
1602 Registers the machine previously created using
1603 <link to="#createMachine"/> or opened using
1604 <link to="#openMachine"/> within this VirtualBox installation. After
1605 successful method invocation, the
1606 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1607 to all registered callbacks.
1608
1609 <note>
1610 This method implicitly calls <link to="IMachine::saveSettings"/>
1611 to save all current machine settings before registering it.
1612 </note>
1613
1614 <result name="VBOX_E_OBJECT_NOT_FOUND">
1615 No matching virtual machine found.
1616 </result>
1617 <result name="VBOX_E_INVALID_OBJECT_STATE">
1618 Virtual machine was not created within this VirtualBox instance.
1619 </result>
1620
1621 </desc>
1622 <param name="machine" type="IMachine" dir="in"/>
1623 </method>
1624
1625 <method name="getMachine">
1626 <desc>
1627 Attempts to find a virtual machine given its UUID.
1628 To look up a machine by name, use <link to="IVirtualBox::findMachine" />
1629 instead.
1630
1631 <result name="VBOX_E_OBJECT_NOT_FOUND">
1632 Could not find registered machine matching @a id.
1633 </result>
1634
1635 </desc>
1636 <param name="id" type="uuid" dir="in"/>
1637 <param name="machine" type="IMachine" dir="return"/>
1638 </method>
1639
1640 <method name="findMachine">
1641 <desc>
1642 Attempts to find a virtual machine given its name.
1643 To look up a machine by UUID, use <link to="IVirtualBox::getMachine" />
1644 instead.
1645
1646 <result name="VBOX_E_OBJECT_NOT_FOUND">
1647 Could not find registered machine matching @a name.
1648 </result>
1649
1650 </desc>
1651 <param name="name" type="wstring" dir="in"/>
1652 <param name="machine" type="IMachine" dir="return"/>
1653 </method>
1654
1655 <method name="unregisterMachine">
1656 <desc>
1657
1658 Unregisters the machine previously registered using
1659 <link to="#registerMachine"/>. After successful method invocation, the
1660 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1661 to all registered callbacks.
1662
1663 <note>
1664 The specified machine must not be in the Saved state, have an open
1665 (or a spawning) direct session associated with it, have snapshots or
1666 have hard disks attached.
1667 </note>
1668
1669 <note>
1670 This method implicitly calls <link to="IMachine::saveSettings"/> to
1671 save all current machine settings before unregistering it.
1672 </note>
1673
1674 <note>
1675 If the given machine is inaccessible (see
1676 <link to="IMachine::accessible"/>), it will be unregistered and
1677 fully uninitialized right afterwards. As a result, the returned
1678 machine object will be unusable and an attempt to call
1679 <b>any</b> method will return the "Object not ready" error.
1680 </note>
1681
1682 <result name="VBOX_E_OBJECT_NOT_FOUND">
1683 Could not find registered machine matching @a id.
1684 </result>
1685 <result name="VBOX_E_INVALID_VM_STATE">
1686 Machine is in Saved state.
1687 </result>
1688 <result name="VBOX_E_INVALID_OBJECT_STATE">
1689 Machine has snapshot or open session or hard disk attached.
1690 </result>
1691
1692 </desc>
1693 <param name="id" type="uuid" dir="in">
1694 <desc>UUID of the machine to unregister.</desc>
1695 </param>
1696 <param name="machine" type="IMachine" dir="return">
1697 <desc>Unregistered machine object.</desc>
1698 </param>
1699 </method>
1700
1701 <method name="createAppliance">
1702 <desc>
1703 Creates a new appliance object, which represents an appliance in the Open Virtual Machine
1704 Format (OVF). This can then be used to import an OVF appliance into VirtualBox or to export
1705 machines as an OVF appliance; see the documentation for <link to="IAppliance" /> for details.
1706 </desc>
1707 <param name="appliance" type="IAppliance" dir="return">
1708 <desc>New appliance.</desc>
1709 </param>
1710 </method>
1711
1712 <method name="createHardDisk">
1713 <desc>
1714 Creates a new base hard disk object that will use the given storage
1715 format and location for hard disk data.
1716
1717 Note that the actual storage unit is not created by this method. In
1718 order to do it, and before you are able to attach the created hard disk
1719 to virtual machines, you must call one of the following methods to
1720 allocate a format-specific storage unit at the specified location:
1721 <ul>
1722 <li><link to="IHardDisk::createDynamicStorage"/></li>
1723 <li><link to="IHardDisk::createFixedStorage"/></li>
1724 <li><link to="IHardDisk::createDiffStorage"/></li>
1725 </ul>
1726
1727 Some hard disk attributes, such as <link to="IHardDisk::id"/>, may
1728 remain uninitialized until the hard disk storage unit is successfully
1729 created by one of the above methods.
1730
1731 After the storage unit is successfully created, the hard disk gets
1732 remembered by this VirtualBox installation and will be accessible
1733 through <link to="#getHardDisk"/> and <link to="#findHardDisk"/>
1734 methods. Remembered root (base) hard disks are also returned as part of
1735 the <link to="#hardDisks"/> array. See IHardDisk for more details.
1736
1737 The list of all storage formats supported by this VirtualBox
1738 installation can be obtained using
1739 <link to="ISystemProperties::hardDiskFormats"/>. If the @a format
1740 attribute is empty or <tt>null</tt> then the default storage format
1741 specified by <link to="ISystemProperties::defaultHardDiskFormat"/> will
1742 be used for creating a storage unit of the hard disk.
1743
1744 Note that the format of the location string is storage format specific.
1745 See <link to="IMedium::location"/>, IHardDisk and
1746 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1747
1748 <result name="VBOX_E_OBJECT_NOT_FOUND">
1749 @a format identifier is invalid. See
1750 <link to="ISystemProperties::hardDiskFormats"/>.
1751 </result>
1752 <result name="VBOX_E_FILE_ERROR">
1753 @a location is a not valid file name (for file-based formats only).
1754 </result>
1755 <result name="E_INVALIDARG">
1756 @a format is a null or empty string.
1757 </result>
1758 </desc>
1759 <param name="format" type="wstring" dir="in">
1760 <desc>
1761 Identifier of the storage format to use for the new hard disk.
1762 </desc>
1763 </param>
1764 <param name="location" type="wstring" dir="in">
1765 <desc>
1766 Location of the storage unit for the new hard disk.
1767 </desc>
1768 </param>
1769 <param name="hardDisk" type="IHardDisk" dir="return">
1770 <desc>Created hard disk object.</desc>
1771 </param>
1772 </method>
1773
1774 <method name="openHardDisk">
1775 <desc>
1776 Opens a hard disk from an existing location.
1777
1778 After the hard disk is successfully opened by this method, it gets
1779 remembered by (known to) this VirtualBox installation and will be
1780 accessible through <link to="#getHardDisk"/> and
1781 <link to="#findHardDisk"/> methods. Remembered root (base) hard disks
1782 are also returned as part of the <link to="#hardDisks"/> array and can
1783 be attached to virtual machines. See IHardDisk for more details.
1784
1785 If a differencing hard disk is to be opened by this method, the
1786 operation will succeed only if its parent hard disk and all ancestors,
1787 if any, are already known to this VirtualBox installation (for example,
1788 were opened by this method before).
1789
1790 This method tries to guess the storage format of the specified hard disk
1791 by reading hard disk data at the specified location.
1792
1793 Note that the format of the location string is storage format specific.
1794 See <link to="IMedium::location"/>, IHardDisk and
1795 <link to="ISystemProperties::defaultHardDiskFolder"/> for more details.
1796
1797
1798 <result name="VBOX_E_FILE_ERROR">
1799 Invalid hard disk storage file location.
1800 </result>
1801 <result name="VBOX_E_IPRT_ERROR">
1802 Could not get hard disk storage format.
1803 </result>
1804 <result name="E_INVALIDARG">
1805 Invalid hard disk storage format.
1806 </result>
1807
1808 </desc>
1809 <param name="location" type="wstring" dir="in">
1810 <desc>
1811 Location of the storage unit that contains hard disk data in one of
1812 the supported storage formats.
1813 </desc>
1814 </param>
1815 <param name="hardDisk" type="IHardDisk" dir="return">
1816 <desc>Opened hard disk object.</desc>
1817 </param>
1818 </method>
1819
1820 <method name="getHardDisk" const="yes">
1821 <desc>
1822 Returns a hard disk with the given UUID.
1823
1824 The hard disk with the given UUID must be known to this VirtualBox
1825 installation, i.e. it must be previously created by
1826 <link to="#createHardDisk"/> or opened by <link
1827 to="#openHardDisk"/>, or attached to some known virtual machine.
1828
1829 <result name="VBOX_E_OBJECT_NOT_FOUND">
1830 No hard disk object matching @a id found.
1831 </result>
1832
1833 </desc>
1834 <param name="id" type="uuid" dir="in">
1835 <desc>UUID of the hard disk to look for.</desc>
1836 </param>
1837 <param name="hardDisk" type="IHardDisk" dir="return">
1838 <desc>Found hard disk object.</desc>
1839 </param>
1840 </method>
1841
1842 <method name="findHardDisk">
1843 <desc>
1844 Returns a hard disk that uses the given location to store hard
1845 disk data.
1846
1847 The given hard disk must be known to this VirtualBox installation, i.e.
1848 it must be previously created by
1849 <link to="#createHardDisk"/> or opened by <link
1850 to="#openHardDisk"/>, or attached to some known virtual machine.
1851
1852 The search is done by comparing the value of the @a location argument to
1853 the <link to="IHardDisk::location"/> attribute of each known hard
1854 disk.
1855
1856 For locations represented by file names in the host's file system, the
1857 requested location can be a path relative to the
1858 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
1859 only a file name without any path is given, the
1860 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
1861 folder</link> will be prepended to the file name before searching. Note
1862 that on case sensitive file systems, a case sensitive comparison is
1863 performed, otherwise the case of symbols in the file path is ignored.
1864
1865 <result name="VBOX_E_OBJECT_NOT_FOUND">
1866 No hard disk object matching @a location found.
1867 </result>
1868
1869 </desc>
1870 <param name="location" type="wstring" dir="in">
1871 <desc>Location string to search for.</desc>
1872 </param>
1873 <param name="hardDisk" type="IHardDisk" dir="return">
1874 <desc>Found hard disk object.</desc>
1875 </param>
1876 </method>
1877
1878 <method name="openDVDImage">
1879 <desc>
1880 Opens a CD/DVD image contained in the specified file of the supported
1881 format and assigns it the given UUID.
1882
1883 After the image is successfully opened by this method, it gets
1884 remembered by (known to) this VirtualBox installation and will be
1885 accessible through <link to="#getDVDImage"/> and
1886 <link to="#findDVDImage"/> methods. Remembered images are also
1887 returned as part of the <link to="#DVDImages"/> array and can be mounted
1888 to virtual machines. See IMedium for more details.
1889
1890 See <link to="IMedium::location"/> to get more details about the format
1891 of the location string.
1892
1893 <note>
1894 Currently only ISO 9960 CD/DVD images are supported by VirtualBox.
1895 </note>
1896
1897 <result name="VBOX_E_INVALID_OBJECT_STATE">
1898 CD/DVD image already exists in the media registry.
1899 </result>
1900
1901 </desc>
1902 <param name="location" type="wstring" dir="in">
1903 <desc>
1904 Full path to the file that contains a valid CD/DVD image.
1905 </desc>
1906 </param>
1907 <param name="id" type="uuid" dir="in">
1908 <desc>
1909 UUID to assign to the given image within this VirtualBox installation.
1910 If an empty (null) UUID is specified, the system will randomly
1911 generate a new UUID.
1912 </desc>
1913 </param>
1914 <param name="image" type="IDVDImage" dir="return">
1915 <desc>Opened CD/DVD image object.</desc>
1916 </param>
1917 </method>
1918
1919 <method name="getDVDImage">
1920 <desc>
1921 Returns a CD/DVD image with the given UUID.
1922
1923 The image with the given UUID must be known to this VirtualBox
1924 installation, i.e. it must be previously opened by <link
1925 to="#openDVDImage"/>, or mounted to some known virtual machine.
1926
1927 <result name="VBOX_E_OBJECT_NOT_FOUND">
1928 No matching DVD image found in the media registry.
1929 </result>
1930
1931 </desc>
1932 <param name="id" type="uuid" dir="in">
1933 <desc>UUID of the image to look for.</desc>
1934 </param>
1935 <param name="image" type="IDVDImage" dir="return">
1936 <desc>Found CD/DVD image object.</desc>
1937 </param>
1938 </method>
1939
1940 <method name="findDVDImage">
1941 <desc>
1942 Returns a CD/DVD image with the given image location.
1943
1944 The image with the given UUID must be known to this VirtualBox
1945 installation, i.e. it must be previously opened by <link
1946 to="#openDVDImage"/>, or mounted to some known virtual machine.
1947
1948 The search is done by comparing the value of the @a location argument to
1949 the <link to="IMedium::location"/> attribute of each known CD/DVD image.
1950
1951 The requested location can be a path relative to the
1952 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
1953 only a file name without any path is given, the
1954 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
1955 folder</link> will be prepended to the file name before searching. Note
1956 that on case sensitive file systems, a case sensitive comparison is
1957 performed, otherwise the case in the file path is ignored.
1958
1959 <result name="VBOX_E_FILE_ERROR">
1960 Invalid image file location.
1961 </result>
1962 <result name="VBOX_E_OBJECT_NOT_FOUND">
1963 No matching DVD image found in the media registry.
1964 </result>
1965
1966 </desc>
1967 <param name="location" type="wstring" dir="in">
1968 <desc>CD/DVD image file path to look for.</desc>
1969 </param>
1970 <param name="image" type="IDVDImage" dir="return">
1971 <desc>Found CD/DVD image object.</desc>
1972 </param>
1973 </method>
1974
1975 <method name="openFloppyImage">
1976 <desc>
1977 Opens a floppy image contained in the specified file of the supported
1978 format and assigns it the given UUID.
1979
1980 After the image is successfully opened by this method, it gets
1981 remembered by (known to) this VirtualBox installation and will be
1982 accessible through <link to="#getFloppyImage"/> and
1983 <link to="#findFloppyImage"/> methods. Remembered images are also
1984 returned as part of the <link to="#floppyImages"/> array and can be
1985 mounted to virtual machines. See IMedium for more details.
1986
1987 See <link to="IMedium::location"/> to get more details about the format
1988 of the location string.
1989
1990 <result name="VBOX_E_FILE_ERROR">
1991 Floppy image specified by @a location not accessible.
1992 </result>
1993 <result name="VBOX_E_INVALID_OBJECT_STATE">
1994 Floppy image already exists in the media registry.
1995 </result>
1996
1997 <note>
1998 Currently, only raw floppy images are supported by VirtualBox.
1999 </note>
2000 </desc>
2001 <param name="location" type="wstring" dir="in">
2002 <desc>
2003 Full path to the file that contains a valid floppy image.
2004 </desc>
2005 </param>
2006 <param name="id" type="uuid" dir="in">
2007 <desc>
2008 UUID to assign to the given image file within this VirtualBox
2009 installation. If an empty (null) UUID is specified, the system will
2010 randomly generate a new UUID.
2011 </desc>
2012 </param>
2013 <param name="image" type="IFloppyImage" dir="return">
2014 <desc>Opened floppy image object.</desc>
2015 </param>
2016 </method>
2017
2018 <method name="getFloppyImage">
2019 <desc>
2020 Returns a floppy image with the given UUID.
2021
2022 The image with the given UUID must be known to this VirtualBox
2023 installation, i.e. it must be previously opened by <link
2024 to="#openFloppyImage"/>, or mounted to some known virtual machine.
2025
2026 <result name="VBOX_E_OBJECT_NOT_FOUND">
2027 No matching floppy image found in the media registry.
2028 </result>
2029
2030 </desc>
2031 <param name="id" type="uuid" dir="in">
2032 <desc>UUID of the image to look for.</desc>
2033 </param>
2034 <param name="image" type="IFloppyImage" dir="return">
2035 <desc>Found floppy image object.</desc>
2036 </param>
2037 </method>
2038
2039 <method name="findFloppyImage">
2040 <desc>
2041 Returns a floppy image with the given image location.
2042
2043 The image with the given UUID must be known to this VirtualBox
2044 installation, i.e. it must be previously opened by <link
2045 to="#openFloppyImage"/>, or mounted to some known virtual machine.
2046
2047 The search is done by comparing the value of the @a location argument to
2048 the <link to="IMedium::location"/> attribute of each known floppy image.
2049
2050 The requested location can be a path relative to the
2051 <link to="IVirtualBox::homeFolder">VirtualBox home folder</link>. If
2052 only a file name without any path is given, the
2053 <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
2054 folder</link> will be prepended to the file name before searching. Note
2055 that on case sensitive file systems, a case sensitive comparison is
2056 performed, otherwise the case of symbols in the file path is ignored.
2057
2058 <result name="VBOX_E_FILE_ERROR">
2059 Invalid image file location.
2060 </result>
2061 <result name="VBOX_E_OBJECT_NOT_FOUND">
2062 No matching floppy image found in the media registry.
2063 </result>
2064
2065 </desc>
2066 <param name="location" type="wstring" dir="in">
2067 <desc>Floppy image file path to look for.</desc>
2068 </param>
2069 <param name="image" type="IFloppyImage" dir="return">
2070 <desc>Found floppy image object.</desc>
2071 </param>
2072 </method>
2073
2074 <method name="getGuestOSType">
2075 <desc>
2076 Returns an object describing the specified guest OS type.
2077
2078 The requested guest OS type is specified using a string which is a
2079 mnemonic identifier of the guest operating system, such as
2080 <tt>"win31"</tt> or <tt>"ubuntu"</tt>. The guest OS type ID of a
2081 particular virtual machine can be read or set using the
2082 <link to="IMachine::OSTypeId"/> attribute.
2083
2084 The <link to="IVirtualBox::guestOSTypes"/> collection contains all
2085 available guest OS type objects. Each object has an
2086 <link to="IGuestOSType::id"/> attribute which contains an identifier of
2087 the guest OS this object describes.
2088
2089 <result name="E_INVALIDARG">
2090 @a id is not a valid Guest OS type.
2091 </result>
2092
2093 </desc>
2094 <param name="id" type="wstring" dir="in">
2095 <desc>Guest OS type ID string.</desc>
2096 </param>
2097 <param name="type" type="IGuestOSType" dir="return">
2098 <desc>Guest OS type object.</desc>
2099 </param>
2100 </method>
2101
2102 <method name="createSharedFolder">
2103 <desc>
2104 Creates a new global shared folder by associating the given logical
2105 name with the given host path, adds it to the collection of shared
2106 folders and starts sharing it. Refer to the description of
2107 <link to="ISharedFolder"/> to read more about logical names.
2108 <note>
2109 In the current implementation, this operation is not
2110 implemented.
2111 </note>
2112 </desc>
2113 <param name="name" type="wstring" dir="in">
2114 <desc>Unique logical name of the shared folder.</desc>
2115 </param>
2116 <param name="hostPath" type="wstring" dir="in">
2117 <desc>Full path to the shared folder in the host file system.</desc>
2118 </param>
2119 <param name="writable" type="boolean" dir="in">
2120 <desc>Whether the share is writable or readonly</desc>
2121 </param>
2122 </method>
2123
2124 <method name="removeSharedFolder">
2125 <desc>
2126 Removes the global shared folder with the given name previously
2127 created by <link to="#createSharedFolder"/> from the collection of
2128 shared folders and stops sharing it.
2129 <note>
2130 In the current implementation, this operation is not
2131 implemented.
2132 </note>
2133 </desc>
2134 <param name="name" type="wstring" dir="in">
2135 <desc>Logical name of the shared folder to remove.</desc>
2136 </param>
2137 </method>
2138
2139 <method name="getNextExtraDataKey">
2140 <desc>
2141 Returns the global extra data key name following the supplied key.
2142
2143 An error is returned if the supplied @a key does not exist. @c NULL is
2144 returned in @a nextKey if the supplied key is the last key. When
2145 supplying @c NULL for the @a key, the first key item is returned in
2146 @a nextKey (if there is any). @a nextValue is an optional parameter and
2147 if supplied, the next key's value is returned in it.
2148
2149 <result name="VBOX_E_OBJECT_NOT_FOUND">
2150 Extra data @a key not found.
2151 </result>
2152
2153 </desc>
2154 <param name="key" type="wstring" dir="in">
2155 <desc>Name of the data key to follow.</desc>
2156 </param>
2157 <param name="nextKey" type="wstring" dir="out">
2158 <desc>Name of the next data key.</desc>
2159 </param>
2160 <param name="nextValue" type="wstring" dir="out">
2161 <desc>Value of the next data key.</desc>
2162 </param>
2163 </method>
2164
2165 <method name="getExtraData">
2166 <desc>
2167 Returns associated global extra data.
2168
2169 If the requested data @a key does not exist, this function will
2170 succeed and return @c NULL in the @a value argument.
2171
2172 <result name="VBOX_E_FILE_ERROR">
2173 Settings file not accessible.
2174 </result>
2175 <result name="VBOX_E_XML_ERROR">
2176 Could not parse the settings file.
2177 </result>
2178
2179 </desc>
2180 <param name="key" type="wstring" dir="in">
2181 <desc>Name of the data key to get.</desc>
2182 </param>
2183 <param name="value" type="wstring" dir="return">
2184 <desc>Value of the requested data key.</desc>
2185 </param>
2186 </method>
2187
2188 <method name="setExtraData">
2189 <desc>
2190 Sets associated global extra data.
2191
2192 If you pass @c NULL as a key @a value, the given @a key will be
2193 deleted.
2194
2195 <note>
2196 Before performing the actual data change, this method will ask all
2197 registered callbacks using the
2198 <link to="IVirtualBoxCallback::onExtraDataCanChange"/>
2199 notification for a permission. If one of the callbacks refuses the
2200 new value, the change will not be performed.
2201 </note>
2202 <note>
2203 On success, the
2204 <link to="IVirtualBoxCallback::onExtraDataChange"/> notification
2205 is called to inform all registered callbacks about a successful data
2206 change.
2207 </note>
2208
2209 <result name="VBOX_E_FILE_ERROR">
2210 Settings file not accessible.
2211 </result>
2212 <result name="VBOX_E_XML_ERROR">
2213 Could not parse the settings file.
2214 </result>
2215 <result name="E_ACCESSDENIED">
2216 Modification request refused.
2217 </result>
2218
2219 </desc>
2220 <param name="key" type="wstring" dir="in">
2221 <desc>Name of the data key to set.</desc>
2222 </param>
2223 <param name="value" type="wstring" dir="in">
2224 <desc>Value to assign to the key.</desc>
2225 </param>
2226 </method>
2227
2228 <method name="openSession">
2229 <desc>
2230 Opens a new direct session with the given virtual machine.
2231
2232 A direct session acts as a local lock on the given VM.
2233 There can be only one direct session open at a time for every
2234 virtual machine, protecting the VM from being manipulated by
2235 conflicting actions from different processes. Only after a
2236 direct session has been opened, one can change all VM settings
2237 and execute the VM in the process space of the session object.
2238
2239 Sessions therefore can be compared to mutex semaphores that
2240 lock a given VM for modification and execution.
2241 See <link to="ISession">ISession</link> for details.
2242
2243 <note>Unless you are writing a new VM frontend, you will not
2244 want to execute a VM in the current process. To spawn a new
2245 process that executes a VM, use
2246 <link to="IVirtualBox::openRemoteSession" />
2247 instead.</note>
2248
2249 Upon successful return, the session object can be used to
2250 get access to the machine and to the VM console.
2251
2252 In VirtualBox terminology, the machine becomes "mutable" after
2253 a session has been opened. Note that the "mutable" machine
2254 object, on which you may invoke IMachine methods to change its
2255 settings, will be a different object from the immutable IMachine
2256 objects returned by various IVirtualBox methods. To obtain a
2257 mutable IMachine object (upon which you can invoke settings methods),
2258 use the <link to="ISession::machine" /> attribute.
2259
2260 One must always call <link to="ISession::close" /> to release the
2261 lock on the machine, or the machine's state will eventually be
2262 set to "Aborted".
2263
2264 In other words, to change settings on a machine, the following
2265 sequence is typically performed:
2266
2267 <ol>
2268 <li>Call this method (openSession) to have a machine locked for
2269 the current session.</li>
2270
2271 <li>Obtain a mutable IMachine object from <link to="ISession::machine" />.</li>
2272
2273 <li>Change the settings of the machine.</li>
2274
2275 <li>Call <link to="IMachine::saveSettings" />.</li>
2276
2277 <li>Close the session by calling <link to="ISession::close"/>.</li>
2278 </ol>
2279
2280 <result name="E_UNEXPECTED">
2281 Virtual machine not registered.
2282 </result>
2283 <result name="E_ACCESSDENIED">
2284 Process not started by OpenRemoteSession.
2285 </result>
2286 <result name="VBOX_E_OBJECT_NOT_FOUND">
2287 No matching virtual machine found.
2288 </result>
2289 <result name="VBOX_E_INVALID_OBJECT_STATE">
2290 Session already open or being opened.
2291 </result>
2292 <result name="VBOX_E_VM_ERROR">
2293 Failed to assign machine to session.
2294 </result>
2295
2296 </desc>
2297 <param name="session" type="ISession" dir="in">
2298 <desc>
2299 Session object that will represent the opened session after
2300 successful method invocation. This object must not represent
2301 the already open session.
2302 <note>
2303 This session will be automatically closed if the
2304 VirtualBox server is terminated for some reason.
2305 </note>
2306 </desc>
2307 </param>
2308 <param name="machineId" type="uuid" dir="in">
2309 <desc>ID of the virtual machine to open a session with.</desc>
2310 </param>
2311 </method>
2312
2313 <method name="openRemoteSession">
2314 <desc>
2315 Spawns a new process that executes a virtual machine (called a
2316 "remote session").
2317
2318 Opening a remote session causes the VirtualBox server to start a new
2319 process that opens a direct session with the given VM. As a result, the
2320 VM is locked by that direct session in the new process, preventing
2321 conflicting changes from other processes. Since sessions act as locks
2322 that prevent conflicting changes, one cannot open a remote session
2323 for a VM that already has another open session (direct or remote), or
2324 is currently in the process of opening one (see <link
2325 to="IMachine::sessionState"/>).
2326
2327 While the remote session still provides some level of control over the
2328 VM execution to the caller (using the <link to="IConsole" /> interface),
2329 not all VM settings are available for modification within the remote
2330 session context.
2331
2332 This operation can take some time (a new VM is started in a new process,
2333 for which memory and other resources need to be set up). Because of this,
2334 an <link to="IProgress" /> is returned to allow the caller to wait for this
2335 asynchronous operation to be completed. Until then, the remote session
2336 object remains in the closed state, and accessing the machine or its
2337 console through it is invalid. It is recommended to use
2338 <link to="IProgress::waitForCompletion" /> or similar calls to wait for
2339 completion.
2340
2341 As with all <link to="ISession" /> objects, it is recommended to call
2342 <link to="ISession::close" /> on the local session object once openRemoteSession()
2343 has been called. However, the session's state (see <link to="ISession::state" />)
2344 will not return to "Closed" until the remote session has also closed (i.e.
2345 until the VM is no longer running). In that case, however, the state of
2346 the session will automatically change back to "Closed".
2347
2348 Currently supported session types (values of the @a type
2349 argument) are:
2350 <ul>
2351 <li><tt>gui</tt>: VirtualBox Qt GUI session</li>
2352 <li><tt>vrdp</tt>: VirtualBox VRDP Server session</li>
2353 </ul>
2354
2355 The @a environment argument is a string containing definitions of
2356 environment variables in the following format:
2357 @code
2358 NAME[=VALUE]\n
2359 NAME[=VALUE]\n
2360 ...
2361 @endcode
2362 where <tt>\\n</tt> is the new line character. These environment
2363 variables will be appended to the environment of the VirtualBox server
2364 process. If an environment variable exists both in the server process
2365 and in this list, the value from this list takes precedence over the
2366 server's variable. If the value of the environment variable is
2367 omitted, this variable will be removed from the resulting environment.
2368 If the environment string is @c null, the server environment is
2369 inherited by the started process as is.
2370
2371 <see>openExistingSession</see>
2372
2373 <result name="E_UNEXPECTED">
2374 Virtual machine not registered.
2375 </result>
2376 <result name="E_INVALIDARG">
2377 Invalid session type @a type.
2378 </result>
2379 <result name="VBOX_E_OBJECT_NOT_FOUND">
2380 No machine matching @a machineId found.
2381 </result>
2382 <result name="VBOX_E_INVALID_OBJECT_STATE">
2383 Session already open or being opened.
2384 </result>
2385 <result name="VBOX_E_IPRT_ERROR">
2386 Launching process for machine failed.
2387 </result>
2388 <result name="VBOX_E_VM_ERROR">
2389 Failed to assign machine to session.
2390 </result>
2391
2392 </desc>
2393 <param name="session" type="ISession" dir="in">
2394 <desc>
2395 Session object that will represent the opened remote session
2396 after successful method invocation (this object must not
2397 represent an already open session).
2398 </desc>
2399 </param>
2400 <param name="machineId" type="uuid" dir="in">
2401 <desc>ID of the virtual machine to open a session with.</desc>
2402 </param>
2403 <param name="type" type="wstring" dir="in">
2404 <desc>
2405 Type of the remote session (case sensitive).
2406 </desc>
2407 </param>
2408 <param name="environment" type="wstring" dir="in">
2409 <desc>
2410 Environment to pass to the opened session (may be @c null).
2411 </desc>
2412 </param>
2413 <param name="progress" type="IProgress" dir="return">
2414 <desc>Progress object to track the operation completion.</desc>
2415 </param>
2416 </method>
2417
2418 <method name="openExistingSession">
2419 <desc>
2420 Opens a new remote session with the virtual machine for
2421 which a direct session is already open.
2422
2423 The remote session provides some level of control over the VM
2424 execution (using the IConsole interface) to the caller; however,
2425 within the remote session context, not all VM settings are available
2426 for modification.
2427
2428 As opposed to <link to="#openRemoteSession"/>, the number of
2429 remote sessions opened this way is not limited by the API
2430
2431 <note>
2432 It is an error to open a remote session with the machine that
2433 doesn't have an open direct session.
2434 </note>
2435
2436 <result name="E_UNEXPECTED">
2437 Virtual machine not registered.
2438 </result>
2439 <result name="VBOX_E_OBJECT_NOT_FOUND">
2440 No machine matching @a machineId found.
2441 </result>
2442 <result name="VBOX_E_INVALID_OBJECT_STATE">
2443 Session already open or being opened.
2444 </result>
2445 <result name="VBOX_E_INVALID_SESSION_STATE">
2446 Direct session state not Open.
2447 </result>
2448 <result name="VBOX_E_VM_ERROR">
2449 Failed to get console object from direct session or assign
2450 machine to session.
2451 </result>
2452
2453 <see>openRemoteSession</see>
2454 </desc>
2455 <param name="session" type="ISession" dir="in">
2456 <desc>
2457 Session object that will represent the open remote session
2458 after successful method invocation. This object must not
2459 represent an already open session.
2460 <note>
2461 This session will be automatically closed when the peer
2462 (direct) session dies or gets closed.
2463 </note>
2464 </desc>
2465 </param>
2466 <param name="machineId" type="uuid" dir="in">
2467 <desc>ID of the virtual machine to open a session with.</desc>
2468 </param>
2469 </method>
2470
2471 <method name="registerCallback">
2472 <desc>
2473 Registers a new global VirtualBox callback. The methods of the given
2474 callback object will be called by VirtualBox when an appropriate
2475 event occurs.
2476
2477 <result name="E_INVALIDARG">
2478 A @c NULL callback cannot be registered.
2479 </result>
2480
2481 </desc>
2482 <param name="callback" type="IVirtualBoxCallback" dir="in">
2483 <desc>Callback object to register.</desc>
2484 </param>
2485 </method>
2486
2487 <method name="unregisterCallback">
2488 <desc>
2489 Unregisters the previously registered global VirtualBox callback.
2490
2491 <result name="E_INVALIDARG">
2492 Specified @a callback not registered.
2493 </result>
2494
2495 </desc>
2496 <param name="callback" type="IVirtualBoxCallback" dir="in">
2497 <desc>Callback object to unregister.</desc>
2498 </param>
2499 </method>
2500
2501 <method name="waitForPropertyChange">
2502 <desc>
2503 Blocks the caller until any of the properties represented by the
2504 @a what argument changes the value or until the given timeout interval
2505 expires.
2506
2507 The @a what argument is a comma separated list of property masks that
2508 describe properties the caller is interested in. The property mask is
2509 a string in the following format:
2510
2511 <pre>
2512 [[group.]subgroup.]name
2513 </pre>
2514
2515 where @c name is the property name and @c group, @c subgroup are zero
2516 or more property group specifiers. Each element (group or name) in
2517 the property mask may be either a Latin string or an asterisk symbol
2518 (@c "*") which is used to match any string for the given element. A
2519 property mask that doesn't contain asterisk symbols represents a
2520 single fully qualified property name.
2521
2522 Groups in the fully qualified property name go from more generic (the
2523 left-most part) to more specific (the right-most part). The first
2524 element is usually a name of the object the property belongs to. The
2525 second element may be either a property name, or a child object name,
2526 or an index if the preceding element names an object which is one of
2527 many objects of the same type. This way, property names form a
2528 hierarchy of properties. Here are some examples of property names:
2529
2530 <table>
2531 <tr>
2532 <td><tt>VirtualBox.version</tt></td>
2533 <td><link to="IVirtualBox::version"/> property</td>
2534 </tr>
2535 <tr>
2536 <td><tt>Machine.&lt;UUID&gt;.name</tt></td>
2537 <td><link to="IMachine::name"/> property of the machine with the
2538 given UUID</td>
2539 </tr>
2540 </table>
2541
2542 Most property names directly correspond to the properties of objects
2543 (components) provided by the VirtualBox library and may be used to
2544 track changes to these properties. However, there may be
2545 pseudo-property names that don't correspond to any existing object's
2546 property directly, as well as there may be object properties that
2547 don't have a corresponding property name that is understood by this
2548 method, and therefore changes to such properties cannot be
2549 tracked. See individual object's property descriptions to get a
2550 fully qualified property name that can be used with this method (if
2551 any).
2552
2553 There is a special property mask @c "*" (i.e. a string consisting of a
2554 single asterisk symbol) that can be used to match all properties.
2555 Below are more examples of property masks:
2556
2557 <table>
2558 <tr>
2559 <td><tt>VirtualBox.*</tt></td>
2560 <td>Track all properties of the VirtualBox object</td>
2561 </tr>
2562 <tr>
2563 <td><tt>Machine.*.name</tt></td>
2564 <td>Track changes to the <link to="IMachine::name"/> property of
2565 all registered virtual machines</td>
2566 </tr>
2567 </table>
2568
2569 <note>
2570 This function is not implemented in the current version of the
2571 product.
2572 </note>
2573 </desc>
2574 <param name="what" type="wstring" dir="in">
2575 <desc>Comma separated list of property masks.</desc>
2576 </param>
2577 <param name="timeout" type="unsigned long" dir="in">
2578 <desc>
2579 Wait timeout in milliseconds.
2580 Specify -1 for an indefinite wait.
2581 </desc>
2582 </param>
2583 <param name="changed" type="wstring" dir="out">
2584 <desc>
2585 Comma separated list of properties that have been changed and caused
2586 this method to return to the caller.
2587 </desc>
2588 </param>
2589 <param name="values" type="wstring" dir="out">
2590 <desc>Reserved, not currently used.</desc>
2591 </param>
2592 </method>
2593
2594 <method name="saveSettings">
2595 <desc>
2596 Saves the global settings to the global settings file
2597 (<link to="#settingsFilePath"/>).
2598
2599 This method is only useful for explicitly saving the global settings
2600 file after it has been auto-converted from the old format to the most
2601 recent format (see <link to="#settingsFileVersion"/> for details).
2602 Normally, the global settings file is implicitly saved when a global
2603 setting is changed.
2604
2605 <result name="VBOX_E_FILE_ERROR">
2606 Settings file not accessible.
2607 </result>
2608 <result name="VBOX_E_XML_ERROR">
2609 Could not parse the settings file.
2610 </result>
2611
2612 </desc>
2613 </method>
2614
2615 <method name="saveSettingsWithBackup">
2616 <desc>
2617 Creates a backup copy of the global settings file
2618 (<link to="#settingsFilePath"/>) in case of auto-conversion, and then
2619 calls <link to="#saveSettings"/>.
2620
2621 Note that the backup copy is created <b>only</b> if the settings file
2622 auto-conversion took place (see <link to="#settingsFileVersion"/> for
2623 details). Otherwise, this call is fully equivalent to
2624 <link to="#saveSettings"/> and no backup copying is done.
2625
2626 The backup copy is created in the same directory where the original
2627 settings file is located. It is given the following file name:
2628 <pre>
2629 original.xml.x.y-platform.bak
2630 </pre>
2631 where <tt>original.xml</tt> is the original settings file name
2632 (excluding path), and <tt>x.y-platform</tt> is the version of the old
2633 format of the settings file (before auto-conversion).
2634
2635 If the given backup file already exists, this method will try to add the
2636 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
2637 0 to 9) and copy it again until it succeeds. If all suffixes are
2638 occupied, or if any other copy error occurs, this method will return a
2639 failure.
2640
2641 If the copy operation succeeds, the @a bakFileName return argument will
2642 receive a full path to the created backup file (for informational
2643 purposes). Note that this will happen even if the subsequent
2644 <link to="#saveSettings"/> call performed by this method after the
2645 copy operation, fails.
2646
2647 <note>
2648 The VirtualBox API never calls this method. It is intended purely for
2649 the purposes of creating backup copies of the settings files by
2650 front-ends before saving the results of the automatically performed
2651 settings conversion to disk.
2652 </note>
2653
2654 <see>settingsFileVersion</see>
2655
2656 <result name="VBOX_E_FILE_ERROR">
2657 Settings file not accessible.
2658 </result>
2659 <result name="VBOX_E_XML_ERROR">
2660 Could not parse the settings file.
2661 </result>
2662 <result name="VBOX_E_IPRT_ERROR">
2663 Could not copy the settings file.
2664 </result>
2665
2666 </desc>
2667 <param name="bakFileName" type="wstring" dir="return">
2668 <desc>Full path to the created backup copy.</desc>
2669 </param>
2670 </method>
2671
2672 </interface>
2673
2674 <!--
2675 // IAppliance
2676 /////////////////////////////////////////////////////////////////////////
2677 -->
2678
2679 <enum
2680 name="CIMOSType"
2681 uuid="86ef5f8c-18b2-4db8-a314-33721b59f89b"
2682 >
2683 <desc>
2684 OVF operating system values according to CIM V2.20 (as of Nov 2008); http://www.dmtf.org/standards/cim/cim_schema_v220
2685 </desc>
2686
2687 <const name="CIMOS_Unknown" value="0" /> <!-- "Unknown" -->
2688 <const name="CIMOS_Other" value="1" /> <!-- "Other" -->
2689 <const name="CIMOS_MACOS" value="2" /> <!-- "MACOS" -->
2690 <const name="CIMOS_ATTUNIX" value="3" /> <!-- "ATTUNIX" -->
2691 <const name="CIMOS_DGUX" value="4" /> <!-- "DGUX" -->
2692 <const name="CIMOS_DECNT" value="5" /> <!-- "DECNT" -->
2693 <const name="CIMOS_Tru64UNIX" value="6" /> <!-- "Tru64 UNIX" -->
2694 <const name="CIMOS_OpenVMS" value="7" /> <!-- "OpenVMS" -->
2695 <const name="CIMOS_HPUX" value="8" /> <!-- "HPUX" -->
2696 <const name="CIMOS_AIX" value="9" /> <!-- "AIX" -->
2697 <const name="CIMOS_MVS" value="10" /> <!-- "MVS" -->
2698 <const name="CIMOS_OS400" value="11" /> <!-- "OS400" -->
2699 <const name="CIMOS_OS2" value="12" /> <!-- "OS/2" -->
2700 <const name="CIMOS_JavaVM" value="13" /> <!-- "JavaVM" -->
2701 <const name="CIMOS_MSDOS" value="14" /> <!-- "MSDOS" -->
2702 <const name="CIMOS_WIN3x" value="15" /> <!-- "WIN3x" -->
2703 <const name="CIMOS_WIN95" value="16" /> <!-- "WIN95" -->
2704 <const name="CIMOS_WIN98" value="17" /> <!-- "WIN98" -->
2705 <const name="CIMOS_WINNT" value="18" /> <!-- "WINNT" -->
2706 <const name="CIMOS_WINCE" value="19" /> <!-- "WINCE" -->
2707 <const name="CIMOS_NCR3000" value="20" /> <!-- "NCR3000" -->
2708 <const name="CIMOS_NetWare" value="21" /> <!-- "NetWare" -->
2709 <const name="CIMOS_OSF" value="22" /> <!-- "OSF" -->
2710 <const name="CIMOS_DCOS" value="23" /> <!-- "DC/OS" -->
2711 <const name="CIMOS_ReliantUNIX" value="24" /> <!-- "Reliant UNIX" -->
2712 <const name="CIMOS_SCOUnixWare" value="25" /> <!-- "SCO UnixWare" -->
2713 <const name="CIMOS_SCOOpenServer" value="26" /> <!-- "SCO OpenServer" -->
2714 <const name="CIMOS_Sequent" value="27" /> <!-- "Sequent" -->
2715 <const name="CIMOS_IRIX" value="28" /> <!-- "IRIX" -->
2716 <const name="CIMOS_Solaris" value="29" /> <!-- "Solaris" -->
2717 <const name="CIMOS_SunOS" value="30" /> <!-- "SunOS" -->
2718 <const name="CIMOS_U6000" value="31" /> <!-- "U6000" -->
2719 <const name="CIMOS_ASERIES" value="32" /> <!-- "ASERIES" -->
2720 <const name="CIMOS_HPNonStopOS" value="33" /> <!-- "HP NonStop OS" -->
2721 <const name="CIMOS_HPNonStopOSS" value="34" /> <!-- "HP NonStop OSS" -->
2722 <const name="CIMOS_BS2000" value="35" /> <!-- "BS2000" -->
2723 <const name="CIMOS_LINUX" value="36" /> <!-- "LINUX" -->
2724 <const name="CIMOS_Lynx" value="37" /> <!-- "Lynx" -->
2725 <const name="CIMOS_XENIX" value="38" /> <!-- "XENIX" -->
2726 <const name="CIMOS_VM" value="39" /> <!-- "VM" -->
2727 <const name="CIMOS_InteractiveUNIX" value="40" /> <!-- "Interactive UNIX" -->
2728 <const name="CIMOS_BSDUNIX" value="41" /> <!-- "BSDUNIX" -->
2729 <const name="CIMOS_FreeBSD" value="42" /> <!-- "FreeBSD" -->
2730 <const name="CIMOS_NetBSD" value="43" /> <!-- "NetBSD" -->
2731 <const name="CIMOS_GNUHurd" value="44" /> <!-- "GNU Hurd" -->
2732 <const name="CIMOS_OS9" value="45" /> <!-- "OS9" -->
2733 <const name="CIMOS_MACHKernel" value="46" /> <!-- "MACH Kernel" -->
2734 <const name="CIMOS_Inferno" value="47" /> <!-- "Inferno" -->
2735 <const name="CIMOS_QNX" value="48" /> <!-- "QNX" -->
2736 <const name="CIMOS_EPOC" value="49" /> <!-- "EPOC" -->
2737 <const name="CIMOS_IxWorks" value="50" /> <!-- "IxWorks" -->
2738 <const name="CIMOS_VxWorks" value="51" /> <!-- "VxWorks" -->
2739 <const name="CIMOS_MiNT" value="52" /> <!-- "MiNT" -->
2740 <const name="CIMOS_BeOS" value="53" /> <!-- "BeOS" -->
2741 <const name="CIMOS_HPMPE" value="54" /> <!-- "HP MPE" -->
2742 <const name="CIMOS_NextStep" value="55" /> <!-- "NextStep" -->
2743 <const name="CIMOS_PalmPilot" value="56" /> <!-- "PalmPilot" -->
2744 <const name="CIMOS_Rhapsody" value="57" /> <!-- "Rhapsody" -->
2745 <const name="CIMOS_Windows2000" value="58" /> <!-- "Windows 2000" -->
2746 <const name="CIMOS_Dedicated" value="59" /> <!-- "Dedicated" -->
2747 <const name="CIMOS_OS390" value="60" /> <!-- "OS/390" -->
2748 <const name="CIMOS_VSE" value="61" /> <!-- "VSE" -->
2749 <const name="CIMOS_TPF" value="62" /> <!-- "TPF" -->
2750 <const name="CIMOS_WindowsMe" value="63" /> <!-- "Windows (R) Me" -->
2751 <const name="CIMOS_CalderaOpenUNIX" value="64" /> <!-- "Caldera Open UNIX" -->
2752 <const name="CIMOS_OpenBSD" value="65" /> <!-- "OpenBSD" -->
2753 <const name="CIMOS_NotApplicable" value="66" /> <!-- "Not Applicable" -->
2754 <const name="CIMOS_WindowsXP" value="67" /> <!-- "Windows XP" -->
2755 <const name="CIMOS_zOS" value="68" /> <!-- "z/OS" -->
2756 <const name="CIMOS_MicrosoftWindowsServer2003" value="69" /> <!-- "Microsoft Windows Server 2003" -->
2757 <const name="CIMOS_MicrosoftWindowsServer2003_64" value="70" /> <!-- "Microsoft Windows Server 2003 64-Bit" -->
2758 <const name="CIMOS_WindowsXP_64" value="71" /> <!-- "Windows XP 64-Bit" -->
2759 <const name="CIMOS_WindowsXPEmbedded" value="72" /> <!-- "Windows XP Embedded" -->
2760 <const name="CIMOS_WindowsVista" value="73" /> <!-- "Windows Vista" -->
2761 <const name="CIMOS_WindowsVista_64" value="74" /> <!-- "Windows Vista 64-Bit" -->
2762 <const name="CIMOS_WindowsEmbeddedforPointofService" value="75" /> <!-- "Windows Embedded for Point of Service" -->
2763 <const name="CIMOS_MicrosoftWindowsServer2008" value="76" /> <!-- "Microsoft Windows Server 2008" -->
2764 <const name="CIMOS_MicrosoftWindowsServer2008_64" value="77" /> <!-- "Microsoft Windows Server 2008 64-Bit" -->
2765 <const name="CIMOS_FreeBSD_64" value="78" /> <!-- "FreeBSD 64-Bit" -->
2766 <const name="CIMOS_RedHatEnterpriseLinux" value="79" /> <!-- "RedHat Enterprise Linux" -->
2767 <const name="CIMOS_RedHatEnterpriseLinux_64" value="80" /> <!-- "RedHat Enterprise Linux 64-Bit" -->
2768 <const name="CIMOS_Solaris_64" value="81" /> <!-- "Solaris 64-Bit" -->
2769 <const name="CIMOS_SUSE" value="82" /> <!-- "SUSE" -->
2770 <const name="CIMOS_SUSE_64" value="83" /> <!-- "SUSE 64-Bit" -->
2771 <const name="CIMOS_SLES" value="84" /> <!-- "SLES" -->
2772 <const name="CIMOS_SLES_64" value="85" /> <!-- "SLES 64-Bit" -->
2773 <const name="CIMOS_NovellOES" value="86" /> <!-- "Novell OES" -->
2774 <const name="CIMOS_NovellLinuxDesktop" value="87" /> <!-- "Novell Linux Desktop" -->
2775 <const name="CIMOS_SunJavaDesktopSystem" value="88" /> <!-- "Sun Java Desktop System" -->
2776 <const name="CIMOS_Mandriva" value="89" /> <!-- "Mandriva" -->
2777 <const name="CIMOS_Mandriva_64" value="90" /> <!-- "Mandriva 64-Bit" -->
2778 <const name="CIMOS_TurboLinux" value="91" /> <!-- "TurboLinux" -->
2779 <const name="CIMOS_TurboLinux_64" value="92" /> <!-- "TurboLinux 64-Bit" -->
2780 <const name="CIMOS_Ubuntu" value="93" /> <!-- "Ubuntu" -->
2781 <const name="CIMOS_Ubuntu_64" value="94" /> <!-- "Ubuntu 64-Bit" -->
2782 <const name="CIMOS_Debian" value="95" /> <!-- "Debian" -->
2783 <const name="CIMOS_Debian_64" value="96" /> <!-- "Debian 64-Bit" -->
2784 <const name="CIMOS_Linux_2_4_x" value="97" /> <!-- "Linux 2.4.x" -->
2785 <const name="CIMOS_Linux_2_4_x_64" value="98" /> <!-- "Linux 2.4.x 64-Bit" -->
2786 <const name="CIMOS_Linux_2_6_x" value="99" /> <!-- "Linux 2.6.x" -->
2787 <const name="CIMOS_Linux_2_6_x_64" value="100" /> <!-- "Linux 2.6.x 64-Bit" -->
2788 <const name="CIMOS_Linux_64" value="101" /> <!-- "Linux 64-Bit" -->
2789 <const name="CIMOS_Other_64" value="102" /> <!-- "Other 64-Bit" -->
2790 </enum>
2791
2792 <enum
2793 name="OVFResourceType"
2794 uuid="646a78d7-6f04-49f4-82c4-75c28a75a4cd"
2795 >
2796 <desc>
2797 OVF resource type.
2798 </desc>
2799
2800 <const name="Other" value="1" />
2801 <const name="ComputerSystem" value="2" />
2802 <const name="Processor" value="3" />
2803 <const name="Memory" value="4" />
2804 <const name="IdeController" value="5" />
2805 <const name="ParallelScsiHba" value="6" />
2806 <const name="FcHba" value="7" />
2807 <const name="iScsiHba" value="8" />
2808 <const name="IbHca" value="9" />
2809 <const name="EthernetAdapter" value="10" />
2810 <const name="OtherNetworkAdapter" value="11" />
2811 <const name="IoSlot" value="12" />
2812 <const name="IoDevice" value="13" />
2813 <const name="FloppyDrive" value="14" />
2814 <const name="CdDrive" value="15" />
2815 <const name="DvdDrive" value="16" />
2816 <const name="HardDisk" value="17" />
2817 <const name="UsbController" value="23" />
2818 <const name="SoundCard" value="35" />
2819 </enum>
2820
2821 <interface
2822 name="IAppliance" extends="$unknown"
2823 uuid="a7a71c1f-20d3-4483-95c0-7357dda77f50"
2824 wsmap="managed"
2825 >
2826 <desc>
2827 Represents a platform-independent appliance in OVF format. An instance of this is returned
2828 by <link to="IVirtualBox::createAppliance" />, which can then be used to import and export
2829 appliances with VirtualBox.
2830
2831 The OVF standard suggests two different physical file formats:
2832
2833 <ol>
2834 <li>If the OVF is distributed as a set of files, then @a file must be a fully qualified
2835 path name to an existing OVF descriptor file with an <tt>.ovf</tt> file extension. If
2836 this descriptor file references other files, as OVF appliances distributed as a set of
2837 files most likely do, those files must be in the same directory as the descriptor file.</li>
2838
2839 <li>If the OVF is distributed as a single file, it must be in TAR format and have the
2840 <tt>.ova</tt> file extension. This TAR file must then contain at least the OVF descriptor
2841 files and optionally other files.
2842
2843 At this time, VirtualBox does not not yet support the packed (TAR) variant; support will
2844 be added with a later version.</li>
2845 </ol>
2846
2847 <b>Importing</b> an OVF appliance into VirtualBox as instances of
2848 <link to="IMachine" /> involves the following sequence of API calls:
2849
2850 <ol>
2851 <li>Call <link to="IVirtualBox::createAppliance" />. This will create an empty IAppliance object.
2852 </li>
2853
2854 <li>On the new object, call <link to="#read" /> with the full path of the OVF file you
2855 would like to import. So long as this file is syntactically valid, this will succeed
2856 and return an instance of IAppliance that contains the parsed data from the OVF file.
2857 </li>
2858
2859 <li>Next, call <link to="#interpret" />, which analyzes the OVF data and sets up the
2860 contents of the IAppliance attributes accordingly. These can be inspected by a
2861 VirtualBox front-end such as the GUI, and the suggestions can be displayed to the
2862 user. In particular, the <link to="#virtualSystemDescriptions" /> array contains
2863 instances of <link to="IVirtualSystemDescription" /> which represent the virtual
2864 systems in the OVF, which in turn describe the virtual hardware prescribed by the
2865 OVF (network and hardware adapters, virtual disk images, memory size and so on).
2866 The GUI can then give the user the option to confirm and/or change these suggestions.
2867 </li>
2868
2869 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
2870 virtual system to override the suggestions made by the interpret() routine.
2871 </li>
2872
2873 <li>Finally, call <link to="#importMachines" /> to create virtual machines in
2874 VirtualBox as instances of <link to="IMachine" /> that match the information in the
2875 virtual system descriptions.
2876 </li>
2877 </ol>
2878
2879 <b>Exporting</b> VirtualBox machines into an OVF appliance involves the following steps:
2880
2881 <ol>
2882 <li>As with importing, first call <link to="IVirtualBox::createAppliance" /> to create
2883 an empty IAppliance object.
2884 </li>
2885
2886 <li>For each machine you would like to export, call <link to="IMachine::export" />
2887 with the IAppliance object you just created. This creates an instance of
2888 <link to="IVirtualSystemDescription" /> inside the appliance.
2889 </li>
2890
2891 <li>If desired, call <link to="IVirtualSystemDescription::setFinalValues" /> for each
2892 virtual system to override the suggestions made by the export() routine.
2893 </li>
2894
2895 <li>Finally, call <link to="#write" /> with a path specification to have the OVF
2896 file written.</li>
2897 </ol>
2898
2899 </desc>
2900
2901 <attribute name="path" type="wstring" readonly="yes">
2902 <desc>Path to the main file of the OVF appliance, which is either the <tt>.ovf</tt> or
2903 the <tt>.ova</tt> file passed to <link to="#read" /> (for import) or
2904 <link to="#write" /> (for export).
2905 This attribute is empty until one of these methods has been called.
2906 </desc>
2907 </attribute>
2908
2909 <attribute name="disks" type="wstring" readonly="yes" safearray="yes">
2910 <desc>
2911 Array of virtual disk definitions. One such description exists for each
2912 disk definition in the OVF; each string array item represents one such piece of
2913 disk information, with the information fields separated by tab (\t) characters.
2914
2915 The caller should be prepared for additional fields being appended to
2916 this string in future versions of VirtualBox and therefore check for
2917 the number of tabs in the strings returned.
2918
2919 In the current version, the following eight fields are returned per string
2920 in the array:
2921
2922 <ol>
2923 <li>Disk ID (unique string identifier given to disk)</li>
2924
2925 <li>Capacity (unsigned integer indicating the maximum capacity of the disk)</li>
2926
2927 <li>Populated size (optional unsigned integer indicating the current size of the
2928 disk; can be approximate; -1 if unspecified)</li>
2929
2930 <li>Format (string identifying the disk format, typically
2931 "http://www.vmware.com/specifications/vmdk.html#sparse")</li>
2932
2933 <li>Reference (where to find the disk image, typically a file name; if empty,
2934 then the disk should be created on import)</li>
2935
2936 <li>Image size (optional unsigned integer indicating the size of the image,
2937 which need not necessarily be the same as the values specified above, since
2938 the image may be compressed or sparse; -1 if not specified)</li>
2939
2940 <li>Chunk size (optional unsigned integer if the image is split into chunks;
2941 presently unsupported and always -1)</li>
2942
2943 <li>Compression (optional string equalling "gzip" if the image is gzip-compressed)</li>
2944 </ol>
2945 </desc>
2946 </attribute>
2947
2948 <attribute name="virtualSystemDescriptions" type="IVirtualSystemDescription" readonly="yes" safearray="yes">
2949 <desc> Array of virtual system descriptions. One such description is created
2950 for each virtual system found in the OVF.
2951 This array is empty until either <link to="#interpret" /> (for import) or <link to="IMachine::export" />
2952 (for export) has been called.
2953 </desc>
2954 </attribute>
2955
2956 <method name="read">
2957 <desc>
2958 Reads an OVF file into the appliance object.
2959
2960 This method succeeds if the OVF is syntactically valid and, by itself, without errors. The
2961 mere fact that this method returns successfully does not mean that VirtualBox supports all
2962 features requested by the appliance; this can only be examined after a call to <link to="#interpret" />.
2963 </desc>
2964 <param name="file" type="wstring" dir="in">
2965 <desc>
2966 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
2967 on whether the appliance is distributed as a set of files or as a single file, respectively).
2968 </desc>
2969 </param>
2970 </method>
2971
2972 <method name="interpret">
2973 <desc>
2974 Interprets the OVF data that was read when the appliance was constructed. After
2975 calling this method, one can inspect the
2976 <link to="#virtualSystemDescriptions" /> array attribute, which will then contain
2977 one <link to="IVirtualSystemDescription" /> for each virtual machine found in
2978 the appliance.
2979
2980 Calling this method is the second step of importing an appliance into VirtualBox;
2981 see <link to="IAppliance" /> for an overview.
2982 </desc>
2983 </method>
2984
2985 <method name="importMachines">
2986 <desc>
2987 Imports the appliance into VirtualBox by creating instances of <link to="IMachine" />
2988 and other interfaces that match the information contained in the appliance as
2989 closely as possible, as represented by the import instructions in the
2990 <link to="#virtualSystemDescriptions" /> array.
2991
2992 Calling this method is the final step of importing an appliance into VirtualBox;
2993 see <link to="IAppliance" /> for an overview.
2994
2995 Since importing the appliance will most probably involve copying and converting
2996 disk images, which can take a long time, this method operates asynchronously and
2997 returns an IProgress object to allow the caller to monitor the progress.
2998 </desc>
2999
3000 <param name="aProgress" type="IProgress" dir="return">
3001 <desc></desc>
3002 </param>
3003 </method>
3004
3005 <method name="write">
3006 <desc>
3007 Writes the contents of the appliance exports into a new OVF file.
3008
3009 Calling this method is the final step of exporting an appliance from VirtualBox;
3010 see <link to="IAppliance" /> for an overview.
3011
3012 Since importing the appliance will most probably involve copying and converting
3013 disk images, which can take a long time, this method operates asynchronously and
3014 returns an IProgress object to allow the caller to monitor the progress.
3015 </desc>
3016 <param name="path" type="wstring" dir="in">
3017 <desc>
3018 Name of appliance file to open (either with an <tt>.ovf</tt> or <tt>.ova</tt> extension, depending
3019 on whether the appliance is distributed as a set of files or as a single file, respectively).
3020 </desc>
3021 </param>
3022 <param name="aProgress" type="IProgress" dir="return">
3023 <desc></desc>
3024 </param>
3025 </method>
3026
3027 </interface>
3028
3029 <enum
3030 name="VirtualSystemDescriptionType"
3031 uuid="8ac36d00-bb7c-4a35-a835-3f004b27427b"
3032 >
3033 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of
3034 a configuration value.</desc>
3035
3036 <const name="Ignore" value="1" />
3037 <const name="OS" value="2" />
3038 <const name="Name" value="3" />
3039 <const name="CPU" value="4" />
3040 <const name="Memory" value="5" />
3041 <const name="HardDiskControllerIDE" value="6" />
3042 <const name="HardDiskControllerSATA" value="7" />
3043 <const name="HardDiskControllerSCSI" value="8" />
3044 <const name="HardDiskImage" value="9" />
3045 <const name="Floppy" value="10" />
3046 <const name="CDROM" value="11" />
3047 <const name="NetworkAdapter" value="12" />
3048 <const name="USBController" value="13" />
3049 <const name="SoundCard" value="14" />
3050
3051 </enum>
3052
3053 <interface
3054 name="IVirtualSystemDescription" extends="$unknown"
3055 uuid="8606c2ae-c06f-487f-9573-1465b44f9524"
3056 wsmap="managed"
3057 >
3058
3059 <desc>This interface is used in the <link to="IAppliance::virtualSystemDescriptions" /> array.
3060 After <link to="IAppliance::interpret" /> has been called, that array contains
3061 information about how the virtual systems described in the OVF should best be imported into VirtualBox
3062 virtual machines. See <link to="IAppliance" /> for the steps required to import an OVF
3063 into VirtualBox.
3064 </desc>
3065
3066 <attribute name="count" type="unsigned long" readonly="yes">
3067 <desc>Return the number of virtual system description entries.</desc>
3068 </attribute>
3069
3070 <method name="getDescription">
3071 <desc>Returns information about the virtual system as arrays of instruction items. In each array, the
3072 items with the same indices correspond and jointly represent an import instruction for VirtualBox.
3073
3074 The list below identifies the value sets that are possible depending on the
3075 <link to="VirtualSystemDescriptionType" /> enum value in the array item in aTypes[]. In each case,
3076 the array item with the same index in aOvfValues[] will contain the original value as contained
3077 in the OVF file (just for informational purposes), and the corresponding item in aVboxValues[]
3078 will contain a suggested value to be used for VirtualBox. Depending on the description type,
3079 the aExtraConfigValues[] array item may also be used.
3080
3081 <ul>
3082 <li>
3083 "OS": the guest operating system type. There must be exactly one such array item on import. The
3084 corresponding item in aVboxValues[] contains the suggested guest operating system for VirtualBox.
3085 This will be one of the values listed in <link to="IVirtualBox::guestOSTypes" />. The corresponding
3086 item in aOvfValues[] will contain a numerical value that described the operating system in the OVF
3087 (see <link to="CIMOSType" />).
3088 </li>
3089 <li>
3090 "Name": the name to give to the new virtual machine. There can be at most one such array item;
3091 if none is present on import, then an automatic name will be created from the operating system
3092 type. The correponding item im aOvfValues[] will contain the suggested virtual machine name
3093 from the OVF file, and aVboxValues[] will contain a suggestion for a unique VirtualBox
3094 <link to="IMachine" /> name that does not exist yet.
3095 </li>
3096 <li>
3097 "CPU": the number of CPUs. There can be at most one such item, which will presently be ignored.
3098 </li>
3099 <li>
3100 "Memory": the amount of guest RAM, in bytes. There can be at most one such array item; if none
3101 is present on import, then VirtualBox will set a meaningful default based on the operating system
3102 type.
3103 </li>
3104 <li>
3105 "HarddiskControllerIDE": an IDE hard disk controller. There can be at most one such item. This
3106 has no value in aOvfValues[] or aVboxValues[].
3107 The matching item in the aRefs[] array will contain an integer that items of the "Harddisk"
3108 type can use to specify which hard disk controller a virtual disk should be connected to.
3109 </li>
3110 <li>
3111 "HarddiskControllerSATA": an SATA hard disk controller. There can be at most one such item. This
3112 has no value in aOvfValues[] or aVboxValues[].
3113 The matching item in the aRefs[] array will be used as with IDE controllers (see above).
3114 </li>
3115 <li>
3116 "HarddiskControllerSCSI": a SCSI hard disk controller. There can be at most one such item.
3117 The items in aOvfValues[] and aVboxValues[] will either be "LsiLogic" or "BusLogic".
3118 The matching item in the aRefs[] array will be used as with IDE controllers (see above).
3119 </li>
3120 <li>
3121 "HardDiskImage": a virtual hard disk, most probably as a reference to an image file. There can be an
3122 arbitrary number of these items, one for each virtual disk image that accompanies the OVF.
3123
3124 The array item in aOvfValues[] will contain the file specification from the OVF file (without
3125 a path since the image file should be in the same location as the OVF file itself), whereas the
3126 item in aVboxValues[] will contain a qualified path specification to where VirtualBox uses the
3127 hard disk image. This means that on import the image will be copied and converted from the
3128 "ovf" location to the "vbox" location; on export, this will be handled the other way round.
3129 On import, the target image will also be registered with VirtualBox.
3130
3131 The matching item in the aExtraConfigValues[] array must contain a string of the following
3132 format: "controller=&lt;index&gt;;channel=&lt;c&gt;"
3133 In this string, &lt;index&gt; must be an integer specifying the hard disk controller to connect
3134 the image to. That number must be the index of an array item with one of the hard disk controller
3135 types (HarddiskControllerSCSI, HarddiskControllerSATA, HarddiskControllerIDE).
3136 In addition, &lt;c&gt; must specify the channel to use on that controller. For IDE controllers,
3137 this can range from 0-2 (which VirtualBox will interpret as primary master, primary slave,
3138 secondary slave; VirtualBox reserves the secondary master for the CD-ROM drive). For SATA and
3139 SCSI conrollers, the channel can range from 0-29.
3140 </li>
3141 <li>
3142 "NetworkAdapter": a network adapter. The array item in aVboxValues[] will specify the hardware
3143 for the network adapter, whereas the array item in aExtraConfigValues[] will have a string
3144 of the "type=&lt;X&gt;" format, where &lt;X&gt; must be either "NAT" or "Bridged".
3145 </li>
3146 <li>
3147 "USBController": a USB controller. There can be at most one such item. If and only if such an
3148 item ispresent, USB support will be enabled for the new virtual machine.
3149 </li>
3150 <li>
3151 "SoundCard": a sound card. There can be at most one such item. If and only if such an item is
3152 present, sound support will be enabled for the new virtual machine. Note that the virtual
3153 machine in VirtualBox will always be presented with the standard VirtualBox soundcard, which
3154 may be different from the virtual soundcard expected by the appliance.
3155 </li>
3156 </ul>
3157
3158 </desc>
3159
3160 <param name="aTypes" type="VirtualSystemDescriptionType" dir="out" safearray="yes">
3161 <desc></desc>
3162 </param>
3163
3164 <param name="aRefs" type="wstring" dir="out" safearray="yes">
3165 <desc></desc>
3166 </param>
3167
3168 <param name="aOvfValues" type="wstring" dir="out" safearray="yes">
3169 <desc></desc>
3170 </param>
3171
3172 <param name="aVboxValues" type="wstring" dir="out" safearray="yes">
3173 <desc></desc>
3174 </param>
3175
3176 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes">
3177 <desc></desc>
3178 </param>
3179
3180 </method>
3181
3182 <method name="setFinalValues">
3183 <desc>
3184 This method allows the appliance's user to change the configuration for the virtual
3185 system descriptions. For each array item returned from <link to="getDescription" />,
3186 you must pass in one boolean value and one configuration value.
3187
3188 Each item in the boolean array determines whether the particular configuration item
3189 should be enabled.
3190 You can only disable items of the types HardDiskControllerIDE, HardDiskControllerSATA,
3191 HardDiskControllerSCSI, HardDiskImage, CDROM, Floppy, NetworkAdapter, USBController
3192 and SoundCard.
3193
3194 For the "vbox" and "extra configuration" values, if you pass in the same arrays
3195 as returned in the aVboxValues and aExtraConfigValues arrays from getDescription(),
3196 the configuration remains unchanged. Please see the documentation for getDescription()
3197 for valid configuration values for the individual array item types. If the
3198 corresponding item in the aEnabled array is false, the configuration value is ignored.
3199 </desc>
3200
3201 <param name="aEnabled" type="boolean" dir="in" safearray="yes">
3202 <desc></desc>
3203 </param>
3204
3205 <param name="aVboxValues" type="wstring" dir="in" safearray="yes">
3206 <desc></desc>
3207 </param>
3208
3209 <param name="aExtraConfigValues" type="wstring" dir="in" safearray="yes">
3210 <desc></desc>
3211 </param>
3212 </method>
3213
3214 <method name="getWarnings">
3215 <desc>Returns textual warnings which occured during the virtual system
3216 interpretion.</desc>
3217
3218 <param name="aWarnings" type="wstring" dir="return" safearray="yes">
3219 <desc></desc>
3220 </param>
3221 </method>
3222
3223 </interface>
3224
3225
3226 <!--
3227 // IMachine
3228 /////////////////////////////////////////////////////////////////////////
3229 -->
3230
3231 <interface
3232 name="IInternalMachineControl" extends="$unknown"
3233 uuid="2c88b969-7a74-4ef3-b95f-8a209a1535f3"
3234 internal="yes"
3235 wsmap="suppress"
3236 >
3237 <method name="updateState">
3238 <desc>
3239 Updates the VM state.
3240 <note>
3241 This operation will also update the settings file with
3242 the correct information about the saved state file
3243 and delete this file from disk when appropriate.
3244 </note>
3245 </desc>
3246 <param name="state" type="MachineState" dir="in"/>
3247 </method>
3248
3249 <method name="getIPCId">
3250 <param name="id" type="wstring" dir="return"/>
3251 </method>
3252
3253 <method name="runUSBDeviceFilters">
3254 <desc>
3255 Asks the server to run USB devices filters of the associated
3256 machine against the given USB device and tell if there is
3257 a match.
3258 <note>
3259 Intended to be used only for remote USB devices. Local
3260 ones don't require to call this method (this is done
3261 implicitly by the Host and USBProxyService).
3262 </note>
3263 </desc>
3264 <param name="device" type="IUSBDevice" dir="in"/>
3265 <param name="matched" type="boolean" dir="out"/>
3266 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
3267 </method>
3268
3269 <method name="captureUSBDevice">
3270 <desc>
3271 Requests a capture of the given host USB device.
3272 When the request is completed, the VM process will
3273 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3274 notification.
3275 </desc>
3276 <param name="id" type="uuid" dir="in"/>
3277 </method>
3278
3279 <method name="detachUSBDevice">
3280 <desc>
3281 Notification that a VM is going to detach (done = false) or has
3282 already detached (done = true) the given USB device.
3283 When the done = true request is completed, the VM process will
3284 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
3285 notification.
3286 <note>
3287 In the done = true case, the server must run its own filters
3288 and filters of all VMs but this one on the detached device
3289 as if it were just attached to the host computer.
3290 </note>
3291 </desc>
3292 <param name="id" type="uuid" dir="in"/>
3293 <param name="done" type="boolean" dir="in"/>
3294 </method>
3295
3296 <method name="autoCaptureUSBDevices">
3297 <desc>
3298 Requests a capture all matching USB devices attached to the host.
3299 When the request is completed, the VM process will
3300 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
3301 notification per every captured device.
3302 </desc>
3303 </method>
3304
3305 <method name="detachAllUSBDevices">
3306 <desc>
3307 Notification that a VM that is being powered down. The done
3308 parameter indicates whether which stage of the power down
3309 we're at. When done = false the VM is announcing its
3310 intentions, while when done = true the VM is reporting
3311 what it has done.
3312 <note>
3313 In the done = true case, the server must run its own filters
3314 and filters of all VMs but this one on all detach devices as
3315 if they were just attached to the host computer.
3316 </note>
3317 </desc>
3318 <param name="done" type="boolean" dir="in"/>
3319 </method>
3320
3321 <method name="onSessionEnd">
3322 <desc>
3323 Triggered by the given session object when the session is about
3324 to close normally.
3325 </desc>
3326 <param name="session" type="ISession" dir="in">
3327 <desc>Session that is being closed</desc>
3328 </param>
3329 <param name="progress" type="IProgress" dir="return">
3330 <desc>
3331 Used to wait until the corresponding machine is actually
3332 dissociated from the given session on the server.
3333 Returned only when this session is a direct one.
3334 </desc>
3335 </param>
3336 </method>
3337
3338 <method name="beginSavingState">
3339 <desc>
3340 Called by the VM process to inform the server it wants to
3341 save the current state and stop the VM execution.
3342 </desc>
3343 <param name="progress" type="IProgress" dir="in">
3344 <desc>
3345 Progress object created by the VM process to wait until
3346 the state is saved.
3347 </desc>
3348 </param>
3349 <param name="stateFilePath" type="wstring" dir="out">
3350 <desc>
3351 File path the VM process must save the execution state to.
3352 </desc>
3353 </param>
3354 </method>
3355
3356 <method name="endSavingState">
3357 <desc>
3358 Called by the VM process to inform the server that saving
3359 the state previously requested by #beginSavingState is either
3360 successfully finished or there was a failure.
3361
3362 <result name="VBOX_E_FILE_ERROR">
3363 Settings file not accessible.
3364 </result>
3365 <result name="VBOX_E_XML_ERROR">
3366 Could not parse the settings file.
3367 </result>
3368
3369 </desc>
3370
3371 <param name="success" type="boolean" dir="in">
3372 <desc><tt>true</tt> to indicate success and <tt>false</tt>
3373 otherwise.
3374 </desc>
3375 </param>
3376 </method>
3377
3378 <method name="adoptSavedState">
3379 <desc>
3380 Gets called by IConsole::adoptSavedState.
3381 <result name="VBOX_E_FILE_ERROR">
3382 Invalid saved state file path.
3383 </result>
3384 </desc>
3385 <param name="savedStateFile" type="wstring" dir="in">
3386 <desc>Path to the saved state file to adopt.</desc>
3387 </param>
3388 </method>
3389
3390 <method name="beginTakingSnapshot">
3391 <desc>
3392 Called by the VM process to inform the server it wants to
3393 take a snapshot.
3394
3395 <result name="VBOX_E_FILE_ERROR">
3396 Settings file not accessible.
3397 </result>
3398 <result name="VBOX_E_XML_ERROR">
3399 Could not parse the settings file.
3400 </result>
3401 </desc>
3402 <param name="initiator" type="IConsole" dir="in">
3403 <desc>The console object that initiated this call.</desc>
3404 </param>
3405 <param name="name" type="wstring" dir="in">
3406 <desc>Snapshot name.</desc>
3407 </param>
3408 <param name="description" type="wstring" dir="in">
3409 <desc>Snapshot description.</desc>
3410 </param>
3411 <param name="progress" type="IProgress" dir="in">
3412 <desc>
3413 Progress object created by the VM process to wait until
3414 the state is saved (only for online snapshots).
3415 </desc>
3416 </param>
3417 <param name="stateFilePath" type="wstring" dir="out">
3418 <desc>
3419 File path the VM process must save the execution state to.
3420 </desc>
3421 </param>
3422 <param name="serverProgress" type="IProgress" dir="out">
3423 <desc>
3424 Progress object created by the server process to wait until
3425 the snapshot is taken (VDI diff creation, etc.).
3426 </desc>
3427 </param>
3428 </method>
3429
3430 <method name="endTakingSnapshot">
3431 <desc>
3432 Called by the VM process to inform the server that the snapshot
3433 previously requested by #beginTakingSnapshot is either
3434 successfully taken or there was a failure.
3435 </desc>
3436
3437 <param name="success" type="boolean" dir="in">
3438 <desc><tt>true</tt> to indicate success and <tt>false</tt> otherwise</desc>
3439 </param>
3440 </method>
3441
3442 <method name="discardSnapshot">
3443 <desc>
3444 Gets called by IConsole::discardSnapshot.
3445 <result name="VBOX_E_INVALID_OBJECT_STATE">
3446 Snapshot has more than one child snapshot.
3447 </result>
3448 </desc>
3449 <param name="initiator" type="IConsole" dir="in">
3450 <desc>The console object that initiated this call.</desc>
3451 </param>
3452 <param name="id" type="uuid" dir="in">
3453 <desc>UUID of the snapshot to discard.</desc>
3454 </param>
3455 <param name="machineState" type="MachineState" dir="out">
3456 <desc>New machine state after this operation is started.</desc>
3457 </param>
3458 <param name="progress" type="IProgress" dir="return">
3459 <desc>Progress object to track the operation completion.</desc>
3460 </param>
3461 </method>
3462
3463 <method name="discardCurrentState">
3464 <desc>
3465 Gets called by IConsole::discardCurrentState.
3466 <result name="VBOX_E_INVALID_OBJECT_STATE">
3467 Virtual machine does not have any snapshot.
3468 </result>
3469 </desc>
3470 <param name="initiator" type="IConsole" dir="in">
3471 <desc>The console object that initiated this call.</desc>
3472 </param>
3473 <param name="machineState" type="MachineState" dir="out">
3474 <desc>New machine state after this operation is started.</desc>
3475 </param>
3476 <param name="progress" type="IProgress" dir="return">
3477 <desc>Progress object to track the operation completion.</desc>
3478 </param>
3479 </method>
3480
3481 <method name="discardCurrentSnapshotAndState">
3482 <desc>
3483 Gets called by IConsole::discardCurrentSnapshotAndState.
3484 <result name="VBOX_E_INVALID_OBJECT_STATE">
3485 Virtual machine does not have any snapshot.
3486 </result>
3487 </desc>
3488 <param name="initiator" type="IConsole" dir="in">
3489 <desc>The console object that initiated this call.</desc>
3490 </param>
3491 <param name="machineState" type="MachineState" dir="out">
3492 <desc>New machine state after this operation is started.</desc>
3493 </param>
3494 <param name="progress" type="IProgress" dir="return">
3495 <desc>Progress object to track the operation completion.</desc>
3496 </param>
3497 </method>
3498
3499 <method name="pullGuestProperties">
3500 <desc>
3501 Get the list of the guest properties matching a set of patterns along
3502 with their values, time stamps and flags and give responsibility for
3503 managing properties to the console.
3504 </desc>
3505 <param name="name" type="wstring" dir="out" safearray="yes">
3506 <desc>
3507 The names of the properties returned.
3508 </desc>
3509 </param>
3510 <param name="value" type="wstring" dir="out" safearray="yes">
3511 <desc>
3512 The values of the properties returned. The array entries match the
3513 corresponding entries in the @a name array.
3514 </desc>
3515 </param>
3516 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
3517 <desc>
3518 The time stamps of the properties returned. The array entries match
3519 the corresponding entries in the @a name array.
3520 </desc>
3521 </param>
3522 <param name="flags" type="wstring" dir="out" safearray="yes">
3523 <desc>
3524 The flags of the properties returned. The array entries match the
3525 corresponding entries in the @a name array.
3526 </desc>
3527 </param>
3528 </method>
3529
3530 <method name="pushGuestProperties">
3531 <desc>
3532 Set the list of the guest properties matching a set of patterns along
3533 with their values, time stamps and flags and return responsibility for
3534 managing properties to IMachine.
3535 </desc>
3536 <param name="name" type="wstring" dir="in" safearray="yes">
3537 <desc>
3538 The names of the properties.
3539 </desc>
3540 </param>
3541 <param name="value" type="wstring" dir="in" safearray="yes">
3542 <desc>
3543 The values of the properties. The array entries match the
3544 corresponding entries in the @a name array.
3545 </desc>
3546 </param>
3547 <param name="timestamp" type="unsigned long long" dir="in" safearray="yes">
3548 <desc>
3549 The time stamps of the properties. The array entries match
3550 the corresponding entries in the @a name array.
3551 </desc>
3552 </param>
3553 <param name="flags" type="wstring" dir="in" safearray="yes">
3554 <desc>
3555 The flags of the properties. The array entries match the
3556 corresponding entries in the @a name array.
3557 </desc>
3558 </param>
3559 </method>
3560 <method name="pushGuestProperty">
3561 <desc>
3562 Update a single guest property in IMachine.
3563 </desc>
3564 <param name="name" type="wstring" dir="in">
3565 <desc>
3566 The name of the property to be updated.
3567 </desc>
3568 </param>
3569 <param name="value" type="wstring" dir="in">
3570 <desc>
3571 The value of the property.
3572 </desc>
3573 </param>
3574 <param name="timestamp" type="unsigned long long" dir="in">
3575 <desc>
3576 The timestamp of the property.
3577 </desc>
3578 </param>
3579 <param name="flags" type="wstring" dir="in">
3580 <desc>
3581 The flags of the property.
3582 </desc>
3583 </param>
3584 </method>
3585
3586 <method name="lockMedia">
3587 <desc>
3588 Locks all media attached to the machine for writing and parents of
3589 attahced different hard disks (if any) for reading. This operation is
3590 atomic so that if it fails no media is actually locked.
3591
3592 This method is intended to be called when the machine is in Starting or
3593 Restoring state. The locked media will be automatically unlocked when
3594 the machine is powered off or crashed.
3595 </desc>
3596 </method>
3597 </interface>
3598
3599 <interface
3600 name="IBIOSSettings" extends="$unknown"
3601 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
3602 wsmap="managed"
3603 >
3604 <desc>
3605 The IBIOSSettings interface represents BIOS settings of the virtual
3606 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
3607 </desc>
3608 <attribute name="logoFadeIn" type="boolean">
3609 <desc>Fade in flag for BIOS logo animation.</desc>
3610 </attribute>
3611
3612 <attribute name="logoFadeOut" type="boolean">
3613 <desc>Fade out flag for BIOS logo animation.</desc>
3614 </attribute>
3615
3616 <attribute name="logoDisplayTime" type="unsigned long">
3617 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
3618 </attribute>
3619
3620 <attribute name="logoImagePath" type="wstring">
3621 <desc>Local file system path for external BIOS image.</desc>
3622 </attribute>
3623
3624 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
3625 <desc>Mode of the BIOS boot device menu.</desc>
3626 </attribute>
3627
3628 <attribute name="ACPIEnabled" type="boolean">
3629 <desc>ACPI support flag.</desc>
3630 </attribute>
3631
3632 <attribute name="IOAPICEnabled" type="boolean">
3633 <desc>
3634 IO APIC support flag. If set, VirtualBox will provide an IO APIC
3635 and support IRQs above 15.
3636 </desc>
3637 </attribute>
3638
3639 <attribute name="timeOffset" type="long long">
3640 <desc>
3641 Offset in milliseconds from the host system time. This allows for
3642 guests running with a different system date/time than the host.
3643 It is equivalent to setting the system date/time in the BIOS except
3644 it is not an absolute value but a relative one. Guest Additions
3645 time synchronization honors this offset.
3646 </desc>
3647 </attribute>
3648
3649 <attribute name="PXEDebugEnabled" type="boolean">
3650 <desc>
3651 PXE debug logging flag. If set, VirtualBox will write extensive
3652 PXE trace information to the release log.
3653 </desc>
3654 </attribute>
3655
3656 </interface>
3657
3658 <interface
3659 name="IMachine" extends="$unknown"
3660 uuid="dcf6a64c-1466-4b5a-b822-9db04133dc74"
3661 wsmap="managed"
3662 >
3663 <desc>
3664 The IMachine interface represents a virtual machine, or guest, created
3665 in VirtualBox.
3666
3667 This interface is used in two contexts. First of all, a collection of
3668 objects implementing this interface is stored in the
3669 <link to="IVirtualBox::machines"/> attribute which lists all the virtual
3670 machines that are currently registered with this VirtualBox
3671 installation. Also, once a session has been opened for the given virtual
3672 machine (e.g. the virtual machine is running), the machine object
3673 associated with the open session can be queried from the session object;
3674 see <link to="ISession"/> for details.
3675
3676 The main role of this interface is to expose the settings of the virtual
3677 machine and provide methods to change various aspects of the virtual
3678 machine's configuration. For machine objects stored in the
3679 <link to="IVirtualBox::machines"/> collection, all attributes are
3680 read-only unless explicitly stated otherwise in individual attribute
3681 and method descriptions. In order to change a machine setting, a session
3682 for this machine must be opened using one of
3683 <link to="IVirtualBox::openSession"/>,
3684 <link to="IVirtualBox::openRemoteSession"/> or
3685 <link to="IVirtualBox::openExistingSession"/> methods. After the
3686 session has been successfully opened, a mutable machine object needs to
3687 be queried from the session object and then the desired settings changes
3688 can be applied to the returned object using IMachine attributes and
3689 methods. See the ISession interface description for more information
3690 about sessions.
3691
3692 Note that the IMachine interface does not provide methods to control
3693 virtual machine execution (such as start the machine, or power it
3694 down) -- these methods are grouped in a separate IConsole
3695 interface. Refer to the IConsole interface description to get more
3696 information about this topic.
3697
3698 <see>ISession, IConsole</see>
3699 </desc>
3700
3701 <attribute name="parent" type="IVirtualBox" readonly="yes">
3702 <desc>Associated parent object.</desc>
3703 </attribute>
3704
3705 <attribute name="accessible" type="boolean" readonly="yes">
3706 <desc>
3707 Whether this virtual machine is currently accessible or not.
3708
3709 The machine is considered to be inaccessible when:
3710 <ul>
3711 <li>It is a registered virtual machine, and
3712 </li>
3713 <li>Its settings file is inaccessible (for example, it is
3714 located on a network share that is not accessible during
3715 VirtualBox startup, or becomes inaccessible later, or if
3716 the settings file can be read but is invalid).
3717 </li>
3718 </ul>
3719
3720 Otherwise, the value of this property is always <tt>true</tt>.
3721
3722 Every time this property is read, the accessibility state of
3723 this machine is re-evaluated. If the returned value is |false|,
3724 the <link to="#accessError"/> property may be used to get the
3725 detailed error information describing the reason of
3726 inaccessibility.
3727
3728 When the machine is inaccessible, only the following properties
3729 can be used on it:
3730 <ul>
3731 <li><link to="#parent"/></li>
3732 <li><link to="#id"/></li>
3733 <li><link to="#settingsFilePath"/></li>
3734 <li><link to="#accessible"/></li>
3735 <li><link to="#accessError"/></li>
3736 </ul>
3737
3738 An attempt to access any other property or method will return
3739 an error.
3740
3741 The only possible action you can perform on an inaccessible
3742 machine is to unregister it using the
3743 <link to="IVirtualBox::unregisterMachine"/> call (or, to check
3744 for the accessibility state once more by querying this
3745 property).
3746
3747 <note>
3748 In the current implementation, once this property returns
3749 <tt>true</tt>, the machine will never become inaccessible
3750 later, even if its settings file cannot be successfully
3751 read/written any more (at least, until the VirtualBox
3752 server is restarted). This limitation may be removed in
3753 future releases.
3754 </note>
3755 </desc>
3756 </attribute>
3757
3758 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
3759 <desc>
3760 Error information describing the reason of machine
3761 inaccessibility.
3762
3763 Reading this property is only valid after the last call to
3764 <link to="#accessible"/> returned <tt>false</tt> (i.e. the
3765 machine is currently unaccessible). Otherwise, a null
3766 IVirtualBoxErrorInfo object will be returned.
3767 </desc>
3768 </attribute>
3769
3770 <attribute name="name" type="wstring">
3771 <desc>
3772 Name of the virtual machine.
3773
3774 Besides being used for human-readable identification purposes
3775 everywhere in VirtualBox, the virtual machine name is also used
3776 as a name of the machine's settings file and as a name of the
3777 subdirectory this settings file resides in. Thus, every time you
3778 change the value of this property, the settings file will be
3779 renamed once you call <link to="#saveSettings"/> to confirm the
3780 change. The containing subdirectory will be also renamed, but
3781 only if it has exactly the same name as the settings file
3782 itself prior to changing this property (for backward compatibility
3783 with previous API releases). The above implies the following
3784 limitations:
3785 <ul>
3786 <li>The machine name cannot be empty.</li>
3787 <li>The machine name can contain only characters that are valid
3788 file name characters according to the rules of the file
3789 system used to store VirtualBox configuration.</li>
3790 <li>You cannot have two or more machines with the same name
3791 if they use the same subdirectory for storing the machine
3792 settings files.</li>
3793 <li>You cannot change the name of the machine if it is running,
3794 or if any file in the directory containing the settings file
3795 is being used by another running machine or by any other
3796 process in the host operating system at a time when
3797 <link to="#saveSettings"/> is called.
3798 </li>
3799 </ul>
3800 If any of the above limitations are hit, <link to="#saveSettings"/>
3801 will return an appropriate error message explaining the exact
3802 reason and the changes you made to this machine will not be
3803 saved.
3804 <note>
3805 For "legacy" machines created using the
3806 <link to="IVirtualBox::createLegacyMachine"/> call,
3807 the above naming limitations do not apply because the
3808 machine name does not affect the settings file name.
3809 The settings file name remains the same as it was specified
3810 during machine creation and never changes.
3811 </note>
3812 </desc>
3813 </attribute>
3814
3815 <attribute name="description" type="wstring">
3816 <desc>
3817 Description of the virtual machine.
3818
3819 The description attribute can contain any text and is
3820 typically used to describe the hardware and software
3821 configuration of the virtual machine in detail (i.e. network
3822 settings, versions of the installed software and so on).
3823 </desc>
3824 </attribute>
3825
3826 <attribute name="id" type="uuid" readonly="yes">
3827 <desc>UUID of the virtual machine.</desc>
3828 </attribute>
3829
3830 <attribute name="OSTypeId" type="wstring">
3831 <desc>
3832 User-defined identifier of the Guest OS type.
3833 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
3834 an IGuestOSType object representing details about the given
3835 Guest OS type.
3836 <note>
3837 This value may differ from the value returned by
3838 <link to="IGuest::OSTypeId"/> if Guest Additions are
3839 installed to the guest OS.
3840 </note>
3841 </desc>
3842 </attribute>
3843
3844 <attribute name="HardwareVersion" type="wstring">
3845 <desc>Hardware version identifier. Internal use only for now.</desc>
3846 </attribute>
3847
3848 <attribute name="CPUCount" type="unsigned long">
3849 <desc>Number of virtual CPUs in the VM. In the current version of the product, this is always 1.</desc>
3850 </attribute>
3851
3852 <attribute name="memorySize" type="unsigned long">
3853 <desc>System memory size in megabytes.</desc>
3854 </attribute>
3855
3856 <attribute name="memoryBalloonSize" type="unsigned long">
3857 <desc>Initial memory balloon size in megabytes.</desc>
3858 </attribute>
3859
3860 <attribute name="statisticsUpdateInterval" type="unsigned long">
3861 <desc>Initial interval to update guest statistics in seconds.</desc>
3862 </attribute>
3863
3864 <attribute name="VRAMSize" type="unsigned long">
3865 <desc>Video memory size in megabytes.</desc>
3866 </attribute>
3867
3868 <attribute name="accelerate3DEnabled" type="boolean" default="false">
3869 <desc>
3870 This setting determines whether VirtualBox allows guests to make use
3871 of the 3D graphics support available on the host. Currently limited
3872 to OpenGL only. </desc>
3873 </attribute>
3874
3875 <attribute name="monitorCount" type="unsigned long">
3876 <desc>
3877 Number of virtual monitors.
3878 <note>
3879 Only effective on Windows XP and later guests with
3880 Guest Additions installed.
3881 </note>
3882 </desc>
3883 </attribute>
3884
3885 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
3886 <desc>Object containing all BIOS settings.</desc>
3887 </attribute>
3888
3889 <attribute name="HWVirtExEnabled" type="TSBool">
3890 <desc>
3891 This setting determines whether VirtualBox will try to make use of
3892 the host CPU's hardware virtualization extensions such as Intel VT-x
3893 and AMD-V. Note that in case such extensions are not available,
3894 they will not be used.
3895 </desc>
3896 </attribute>
3897
3898 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" default="false">
3899 <desc>
3900 This setting determines whether VirtualBox will try to make use of
3901 the nested paging extension of Intel VT-x and AMD-V. Note that in case
3902 such extensions are not available, they will not be used.
3903 </desc>
3904 </attribute>
3905
3906 <attribute name="HWVirtExVPIDEnabled" type="boolean" default="false">
3907 <desc>
3908 This setting determines whether VirtualBox will try to make use of
3909 the VPID extension of Intel VT-x. Note that in case such extensions are
3910 not available, they will not be used.
3911 </desc>
3912 </attribute>
3913
3914 <attribute name="PAEEnabled" type="boolean" default="false">
3915 <desc>
3916 This setting determines whether VirtualBox will expose the Physical Address
3917 Extension (PAE) feature of the host CPU to the guest. Note that in case PAE
3918 is not available, it will not be reported.
3919 </desc>
3920 </attribute>
3921
3922 <attribute name="snapshotFolder" type="wstring">
3923 <desc>
3924 Full path to the directory used to store snapshot data
3925 (differencing hard disks and saved state files) of this machine.
3926
3927 The initial value of this property is
3928 <tt>&lt;</tt><link to="#settingsFilePath">
3929 path_to_settings_file</link><tt>&gt;/&lt;</tt>
3930 <link to="#id">machine_uuid</link>
3931 <tt>&gt;</tt>.
3932
3933 Currently, it is an error to try to change this property on
3934 a machine that has snapshots (because this would require to
3935 move possibly large files to a different location).
3936 A separate method will be available for this purpose later.
3937
3938 <note>
3939 Setting this property to <tt>null</tt> will restore the
3940 initial value.
3941 </note>
3942 <note>
3943 When setting this property, the specified path can be
3944 absolute (full path) or relative to the directory where the
3945 <link to="#settingsFilePath">machine settings file</link>
3946 is located. When reading this property, a full path is
3947 always returned.
3948 </note>
3949 <note>
3950 The specified path may not exist, it will be created
3951 when necessary.
3952 </note>
3953 </desc>
3954 </attribute>
3955
3956 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
3957 <desc>VRDP server object.</desc>
3958 </attribute>
3959
3960 <attribute name="hardDiskAttachments" type="IHardDiskAttachment" readonly="yes" safearray="yes">
3961 <desc>Array of hard disks attached to this machine.</desc>
3962 </attribute>
3963
3964 <attribute name="DVDDrive" type="IDVDDrive" readonly="yes">
3965 <desc>Associated DVD drive object.</desc>
3966 </attribute>
3967
3968 <attribute name="floppyDrive" type="IFloppyDrive" readonly="yes">
3969 <desc>Associated floppy drive object.</desc>
3970 </attribute>
3971
3972 <attribute name="USBController" type="IUSBController" readonly="yes">
3973 <desc>
3974 Associated USB controller object.
3975
3976 <note>
3977 This method may set a @ref com_warnings "warning result code".
3978 </note>
3979 <note>
3980 If USB functionality is not available in the given edition of
3981 VirtualBox, this method will set the result code to @c E_NOTIMPL.
3982 </note>
3983 </desc>
3984 </attribute>
3985
3986 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
3987 <desc>Associated audio adapter, always present.</desc>
3988 </attribute>
3989
3990 <attribute name="storageControllers" type="IStorageController" readonly="yes" safearray="yes">
3991 <desc>Array of storage controllers attached to this machine.</desc>
3992 </attribute>
3993
3994 <attribute name="settingsFilePath" type="wstring" readonly="yes">
3995 <desc>
3996 Full name of the file containing machine settings data.
3997 </desc>
3998 </attribute>
3999
4000 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
4001 <desc>
4002 Current version of the format of the settings file of this machine
4003 (<link to="#settingsFilePath"/>).
4004
4005 The version string has the following format:
4006 <pre>
4007 x.y-platform
4008 </pre>
4009 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
4010 versions, and <tt>platform</tt> is the platform identifier.
4011
4012 The current version usually matches the value of the
4013 <link to="IVirtualBox::settingsFormatVersion"/> attribute unless the
4014 settings file was created by an older version of VirtualBox and there
4015 was a change of the settings file format since then.
4016
4017 Note that VirtualBox automatically converts settings files from older
4018 versions to the most recent version when reading them (usually at
4019 VirtualBox startup) but it doesn't save the changes back until
4020 you call a method that implicitly saves settings (such as
4021 <link to="#setExtraData"/>) or call <link to="#saveSettings"/>
4022 explicitly. Therefore, if the value of this attribute differs from the
4023 value of <link to="IVirtualBox::settingsFormatVersion"/>, then it
4024 means that the settings file was converted but the result of the
4025 conversion is not yet saved to disk.
4026
4027 The above feature may be used by interactive front-ends to inform users
4028 about the settings file format change and offer them to explicitly save
4029 all converted settings files (the global and VM-specific ones),
4030 optionally create backup copies of the old settings files before saving,
4031 etc.
4032
4033 <see>IVirtualBox::settingsFormatVersion, saveSettingsWithBackup()</see>
4034 </desc>
4035 </attribute>
4036
4037 <attribute name="settingsModified" type="boolean" readonly="yes">
4038 <desc>
4039 Whether the settings of this machine have been modified
4040 (but neither yet saved nor discarded).
4041 <note>
4042 Reading this property is only valid on instances returned
4043 by <link to="ISession::machine"/> and on new machines
4044 created by <link to="IVirtualBox::createMachine"/> or opened
4045 by <link to="IVirtualBox::openMachine"/> but not
4046 yet registered, or on unregistered machines after calling
4047 <link to="IVirtualBox::unregisterMachine"/>. For all other
4048 cases, the settings can never be modified.
4049 </note>
4050 <note>
4051 For newly created unregistered machines, the value of this
4052 property is always TRUE until <link to="#saveSettings"/>
4053 is called (no matter if any machine settings have been
4054 changed after the creation or not). For opened machines
4055 the value is set to FALSE (and then follows to normal rules).
4056 </note>
4057 </desc>
4058 </attribute>
4059
4060 <attribute name="sessionState" type="SessionState" readonly="yes">
4061 <desc>Current session state for this machine.</desc>
4062 </attribute>
4063
4064 <attribute name="sessionType" type="wstring" readonly="yes">
4065 <desc>
4066 Type of the session. If <link to="#sessionState"/> is
4067 SessionSpawning or SessionOpen, this attribute contains the
4068 same value as passed to the
4069 <link to="IVirtualBox::openRemoteSession"/> method in the
4070 @a type parameter. If the session was opened directly using
4071 <link to="IVirtualBox::openSession"/>, or if
4072 <link to="#sessionState"/> is SessionClosed, the value of this
4073 attribute is @c null.
4074 </desc>
4075 </attribute>
4076
4077 <attribute name="sessionPid" type="unsigned long" readonly="yes">
4078 <desc>
4079 Identifier of the session process. This attribute contains the
4080 platform-dependent identifier of the process that has opened a
4081 direct session for this machine using the
4082 <link to="IVirtualBox::openSession"/> call. The returned value
4083 is only valid if <link to="#sessionState"/> is SessionOpen or
4084 SessionClosing (i.e. a session is currently open or being
4085 closed) by the time this property is read.
4086 </desc>
4087 </attribute>
4088
4089 <attribute name="state" type="MachineState" readonly="yes">
4090 <desc>Current execution state of this machine.</desc>
4091 </attribute>
4092
4093 <attribute name="lastStateChange" type="long long" readonly="yes">
4094 <desc>
4095 Time stamp of the last execution state change,
4096 in milliseconds since 1970-01-01 UTC.
4097 </desc>
4098 </attribute>
4099
4100 <attribute name="stateFilePath" type="wstring" readonly="yes">
4101 <desc>
4102 Full path to the file that stores the execution state of
4103 the machine when it is in the <link to="MachineState_Saved"/> state.
4104 <note>
4105 When the machine is not in the Saved state, this attribute
4106 <tt>null</tt>.
4107 </note>
4108 </desc>
4109 </attribute>
4110
4111 <attribute name="logFolder" type="wstring" readonly="yes">
4112 <desc>
4113 Full path to the folder that stores a set of rotated log files
4114 recorded during machine execution. The most recent log file is
4115 named <tt>VBox.log</tt>, the previous log file is
4116 named <tt>VBox.log.1</tt> and so on (up to <tt>VBox.log.3</tt>
4117 in the current version).
4118 </desc>
4119 </attribute>
4120
4121 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
4122 <desc>
4123 Current snapshot of this machine.
4124 <note>
4125 A <tt>null</tt> object is returned if the machine doesn't
4126 have snapshots.
4127 </note>
4128 <see><link to="ISnapshot"/></see>
4129 </desc>
4130 </attribute>
4131
4132 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
4133 <desc>
4134 Number of snapshots taken on this machine. Zero means the
4135 machine doesn't have any snapshots.
4136 </desc>
4137 </attribute>
4138
4139 <attribute name="currentStateModified" type="boolean" readonly="yes">
4140 <desc>
4141 Returns <tt>true</tt> if the current state of the machine is not
4142 identical to the state stored in the current snapshot.
4143
4144 The current state is identical to the current snapshot right
4145 after one of the following calls are made:
4146 <ul>
4147 <li><link to="IConsole::discardCurrentState"/> or
4148 <link to="IConsole::discardCurrentSnapshotAndState"/>
4149 </li>
4150 <li><link to="IConsole::takeSnapshot"/> (issued on a
4151 powered off or saved machine, for which
4152 <link to="#settingsModified"/> returns <tt>false</tt>)
4153 </li>
4154 <li><link to="IMachine::setCurrentSnapshot"/>
4155 </li>
4156 </ul>
4157
4158 The current state remains identical until one of the following
4159 happens:
4160 <ul>
4161 <li>settings of the machine are changed</li>
4162 <li>the saved state is discarded</li>
4163 <li>the current snapshot is discarded</li>
4164 <li>an attempt to execute the machine is made</li>
4165 </ul>
4166
4167 <note>
4168 For machines that don't have snapshots, this property is
4169 always <tt>false</tt>.
4170 </note>
4171 </desc>
4172 </attribute>
4173
4174 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
4175 <desc>
4176 Collection of shared folders for this machine (permanent shared
4177 folders). These folders are shared automatically at machine startup
4178 and available only to the guest OS installed within this machine.
4179
4180 New shared folders are added to the collection using
4181 <link to="#createSharedFolder"/>. Existing shared folders can be
4182 removed using <link to="#removeSharedFolder"/>.
4183 </desc>
4184 </attribute>
4185
4186 <attribute name="clipboardMode" type="ClipboardMode">
4187 <desc>
4188 Synchronization mode between the host OS clipboard
4189 and the guest OS clipboard.
4190 </desc>
4191 </attribute>
4192
4193 <attribute name="guestPropertyNotificationPatterns" type="wstring">
4194 <desc>
4195 A comma-separated list of simple glob patterns. Changes to guest
4196 properties whose name matches one of the patterns will generate an
4197 <link to="IVirtualBoxCallback::onGuestPropertyChange"/> signal.
4198 </desc>
4199 </attribute>
4200
4201 <method name="setBootOrder">
4202 <desc>
4203 Puts the given device to the specified position in
4204 the boot order.
4205
4206 To indicate that no device is associated with the given position,
4207 <link to="DeviceType_Null"/> should be used.
4208
4209 @todo setHardDiskBootOrder(), setNetworkBootOrder()
4210
4211 <result name="E_INVALIDARG">
4212 Boot @a position out of range.
4213 </result>
4214 <result name="E_NOTIMPL">
4215 Booting from USB @a device currently not supported.
4216 </result>
4217
4218 </desc>
4219 <param name="position" type="unsigned long" dir="in">
4220 <desc>
4221 Position in the boot order (<tt>1</tt> to the total number of
4222 devices the machine can boot from, as returned by
4223 <link to="ISystemProperties::maxBootPosition"/>).
4224 </desc>
4225 </param>
4226 <param name="device" type="DeviceType" dir="in">
4227 <desc>
4228 The type of the device used to boot at the given position.
4229 </desc>
4230 </param>
4231 </method>
4232
4233 <method name="getBootOrder" const="yes">
4234 <desc>
4235 Returns the device type that occupies the specified
4236 position in the boot order.
4237
4238 @todo [remove?]
4239 If the machine can have more than one device of the returned type
4240 (such as hard disks), then a separate method should be used to
4241 retrieve the individual device that occupies the given position.
4242
4243 If here are no devices at the given position, then
4244 <link to="DeviceType_Null"/> is returned.
4245
4246 @todo getHardDiskBootOrder(), getNetworkBootOrder()
4247
4248 <result name="E_INVALIDARG">
4249 Boot @a position out of range.
4250 </result>
4251
4252 </desc>
4253 <param name="position" type="unsigned long" dir="in">
4254 <desc>
4255 Position in the boot order (<tt>1</tt> to the total number of
4256 devices the machine can boot from, as returned by
4257 <link to="ISystemProperties::maxBootPosition"/>).
4258 </desc>
4259 </param>
4260 <param name="device" type="DeviceType" dir="return">
4261 <desc>
4262 Device at the given position.
4263 </desc>
4264 </param>
4265 </method>
4266
4267 <method name="attachHardDisk">
4268 <desc>
4269 Attaches a virtual hard disk (identified by the given UUID @a id)
4270 to the given hard disk controller (identified by @a name),
4271 at the indicated port and device.
4272
4273 For the IDE bus, the @a controllerPort parameter can be either
4274 @c 0 or @c 1, to specify the primary or secondary IDE controller,
4275 respectively. For the primary controller of the IDE bus,
4276 @a device can be either @c 0 or @c 1, to specify the master or the
4277 slave device, respectively. For the secondary IDE controller, the
4278 device number must be @c 1 because VirtualBox reserves the
4279 secondary master for the CD-ROM drive.
4280
4281 For an SATA controller, @a controllerPort must be a number ranging
4282 from @c 0 to @c 29. For a SCSI controller, @a controllerPort must
4283 be a number ranging from @c 0 to @c 15.
4284
4285 For both SCSI and SATA, the @a device parameter is unused and must
4286 be @c 0.
4287
4288 The specified device slot must not have another disk attached to it, or
4289 this method will fail.
4290
4291 See <link to="IHardDisk"/> for more detailed information about
4292 attaching hard disks.
4293
4294 <note>
4295 You cannot attach a hard disk to a running machine. Also, you cannot
4296 attach a hard disk to a newly created machine until this machine's
4297 settings are saved to disk using <link to="#saveSettings"/>.
4298 </note>
4299 <note>
4300 If the hard disk is being attached indirectly, a new differencing hard
4301 disk will implicitly be created for it and attached instead. If the
4302 changes made to the machine settings (including this indirect
4303 attachment) are later cancelled using <link to="#discardSettings"/>,
4304 this implicitly created differencing hard disk will implicitly
4305 be deleted.
4306 </note>
4307
4308 <result name="E_INVALIDARG">
4309 SATA device, SATA port, IDE port or IDE slot out of range.
4310 </result>
4311 <result name="VBOX_E_INVALID_OBJECT_STATE">
4312 Attempt to attach hard disk to an unregistered virtual machine.
4313 </result>
4314 <result name="VBOX_E_INVALID_VM_STATE">
4315 Invalid machine state.
4316 </result>
4317 <result name="VBOX_E_OBJECT_IN_USE">
4318 Hard disk already attached to this or another virtual machine.
4319 </result>
4320
4321 </desc>
4322 <param name="id" type="uuid" dir="in">
4323 <desc>UUID of the hard disk to attach.</desc>
4324 </param>
4325 <param name="name" type="wstring" dir="in">
4326 <desc>Name of the storage controller to attach the hard disk to.</desc>
4327 </param>
4328 <param name="controllerPort" type="long" dir="in">
4329 <desc>Port to attach the hard disk to.</desc>
4330 </param>
4331 <param name="device" type="long" dir="in">
4332 <desc>
4333 Device slot in the given port to attach the hard disk to.
4334 </desc>
4335 </param>
4336 </method>
4337
4338 <method name="getHardDisk" const="yes">
4339 <desc>
4340 Returns the virtual hard disk attached to a device slot of the specified
4341 bus.
4342
4343 Note that if the hard disk was indirectly attached by
4344 <link to="#attachHardDisk"/> to the given device slot then this
4345 method will return not the same object as passed to the
4346 <link to="#attachHardDisk"/> call. See <link to="IHardDisk"/> for
4347 more detailed information about attaching hard disks.
4348
4349 <result name="VBOX_E_OBJECT_NOT_FOUND">
4350 No hard disk attached to given slot/bus.
4351 </result>
4352
4353 </desc>
4354 <param name="name" type="wstring" dir="in">
4355 <desc>Name of the storage controller the hard disk is attached to.</desc>
4356 </param>
4357 <param name="controllerPort" type="long" dir="in">
4358 <desc>Port to query.</desc>
4359 </param>
4360 <param name="device" type="long" dir="in">
4361 <desc>Device slot in the given port to query.</desc>
4362 </param>
4363 <param name="hardDisk" type="IHardDisk" dir="return">
4364 <desc>Attached hard disk object.</desc>
4365 </param>
4366 </method>
4367
4368 <method name="detachHardDisk">
4369 <desc>
4370 Detaches the virtual hard disk attached to a device slot of the
4371 specified bus.
4372
4373 Detaching the hard disk from the virtual machine is deferred. This means
4374 that the hard disk remains associated with the machine when this method
4375 returns and gets actually de-associated only after a successful
4376 <link to="#saveSettings"/> call. See <link to="IHardDisk"/>
4377 for more detailed information about attaching hard disks.
4378
4379 <note>
4380 You cannot detach the hard disk from a running machine.
4381 </note>
4382 <note>
4383 Detaching differencing hard disks implicitly created by <link
4384 to="#attachHardDisk"/> for the indirect attachment using this
4385 method will <b>not</b> implicitly delete them. The
4386 <link to="IHardDisk::deleteStorage"/> operation should be
4387 explicitly performed by the caller after the hard disk is successfully
4388 detached and the settings are saved with
4389 <link to="#saveSettings"/>, if it is the desired action.
4390 </note>
4391
4392 <result name="VBOX_E_INVALID_VM_STATE">
4393 Attempt to detach hard disk from a running virtual machine.
4394 </result>
4395 <result name="VBOX_E_OBJECT_NOT_FOUND">
4396 No hard disk attached to given slot/bus.
4397 </result>
4398 <result name="VBOX_E_NOT_SUPPORTED">
4399 Hard disk format does not support storage deletion.
4400 </result>
4401
4402 </desc>
4403 <param name="name" type="wstring" dir="in">
4404 <desc>name of the storage controller to detach the hard disk from.</desc>
4405 </param>
4406 <param name="controllerPort" type="long" dir="in">
4407 <desc>Port number to detach the hard disk from.</desc>
4408 </param>
4409 <param name="device" type="long" dir="in">
4410 <desc>Device slot number to detach the hard disk from.</desc>
4411 </param>
4412 </method>
4413
4414 <method name="getHardDiskAttachmentsOfController" const="yes">
4415 <desc>
4416 Returns an array of hard disk attachments which are attached to the
4417 the controller with the given name.
4418
4419 <result name="VBOX_E_OBJECT_NOT_FOUND">
4420 A storage controller with given name doesn't exist.
4421 </result>
4422 </desc>
4423 <param name="name" type="wstring" dir="in"/>
4424 <param name="hardDiskAttachments" type="IHardDiskAttachment" safearray="yes" dir="return"/>
4425 </method>
4426
4427 <method name="getNetworkAdapter" const="yes">
4428 <desc>
4429 Returns the network adapter associated with the given slot.
4430 Slots are numbered sequentially, starting with zero. The total
4431 number of adapters per machine is defined by the
4432 <link to="ISystemProperties::networkAdapterCount"/> property,
4433 so the maximum slot number is one less than that property's value.
4434
4435 <result name="E_INVALIDARG">
4436 Invalid @a slot number.
4437 </result>
4438
4439 </desc>
4440 <param name="slot" type="unsigned long" dir="in"/>
4441 <param name="adapter" type="INetworkAdapter" dir="return"/>
4442 </method>
4443
4444 <method name="addStorageController">
4445 <desc>
4446 Adds a new storage controller (SCSI or SATA controller) to the
4447 machine and returns it as an instance of
4448 <link to="IStorageController" />.
4449
4450 @a name identifies the controller with subsequent calls such as
4451 <link to="#getStorageControllerByName" /> or
4452 <link to="#removeStorageController" /> or
4453 <link to="#attachHardDisk" />.
4454
4455 After the controller has been added, you can set its exact
4456 type by setting the <link to="IStorageController::controllerType" />.
4457
4458 <result name="VBOX_E_OBJECT_IN_USE">
4459 A storage controller with given name exists already.
4460 </result>
4461 <result name="E_INVALIDARG">
4462 Invalid @a controllerType.
4463 </result>
4464 </desc>
4465 <param name="name" type="wstring" dir="in"/>
4466 <param name="connectionType" type="StorageBus" dir="in"/>
4467 <param name="controller" type="IStorageController" dir="return"/>
4468 </method>
4469
4470 <method name="getStorageControllerByName" const="yes">
4471 <desc>
4472 Returns a storage controller with the given name.
4473
4474 <result name="VBOX_E_OBJECT_NOT_FOUND">
4475 A storage controller with given name doesn't exist.
4476 </result>
4477 </desc>
4478 <param name="name" type="wstring" dir="in"/>
4479 <param name="storageController" type="IStorageController" dir="return"/>
4480 </method>
4481
4482 <method name="removeStorageController">
4483 <desc>
4484 Removes a storage controller from the machine.
4485
4486 <result name="VBOX_E_OBJECT_NOT_FOUND">
4487 A storage controller with given name doesn't exist.
4488 </result>
4489 </desc>
4490 <param name="name" type="wstring" dir="in"/>
4491 </method>
4492
4493 <method name="getSerialPort" const="yes">
4494 <desc>
4495 Returns the serial port associated with the given slot.
4496 Slots are numbered sequentially, starting with zero. The total
4497 number of serial ports per machine is defined by the
4498 <link to="ISystemProperties::serialPortCount"/> property,
4499 so the maximum slot number is one less than that property's value.
4500
4501 <result name="E_INVALIDARG">
4502 Invalid @a slot number.
4503 </result>
4504
4505 </desc>
4506 <param name="slot" type="unsigned long" dir="in"/>
4507 <param name="port" type="ISerialPort" dir="return"/>
4508 </method>
4509
4510 <method name="getParallelPort" const="yes">
4511 <desc>
4512 Returns the parallel port associated with the given slot.
4513 Slots are numbered sequentially, starting with zero. The total
4514 number of parallel ports per machine is defined by the
4515 <link to="ISystemProperties::parallelPortCount"/> property,
4516 so the maximum slot number is one less than that property's value.
4517
4518 <result name="E_INVALIDARG">
4519 Invalid @a slot number.
4520 </result>
4521
4522 </desc>
4523 <param name="slot" type="unsigned long" dir="in"/>
4524 <param name="port" type="IParallelPort" dir="return"/>
4525 </method>
4526
4527 <method name="getNextExtraDataKey">
4528 <desc>
4529 Returns the machine-specific extra data key name following the
4530 supplied key.
4531
4532 An error is returned if the supplied @a key does not exist. @c NULL is
4533 returned in @a nextKey if the supplied key is the last key. When
4534 supplying @c NULL for the @a key, the first key item is returned in
4535 @a nextKey (if there is any). @a nextValue is an optional parameter and
4536 if supplied, the next key's value is returned in it.
4537
4538 <result name="VBOX_E_OBJECT_NOT_FOUND">
4539 Extra data @a key not found.
4540 </result>
4541
4542 </desc>
4543 <param name="key" type="wstring" dir="in">
4544 <desc>Name of the data key to follow.</desc>
4545 </param>
4546 <param name="nextKey" type="wstring" dir="out">
4547 <desc>Name of the next data key.</desc>
4548 </param>
4549 <param name="nextValue" type="wstring" dir="out">
4550 <desc>Value of the next data key.</desc>
4551 </param>
4552 </method>
4553
4554 <method name="getExtraData">
4555 <desc>
4556 Returns associated machine-specific extra data.
4557
4558 If the requested data @a key does not exist, this function will
4559 succeed and return @c NULL in the @a value argument.
4560
4561 <result name="VBOX_E_FILE_ERROR">
4562 Settings file not accessible.
4563 </result>
4564 <result name="VBOX_E_XML_ERROR">
4565 Could not parse the settings file.
4566 </result>
4567
4568 </desc>
4569 <param name="key" type="wstring" dir="in">
4570 <desc>Name of the data key to get.</desc>
4571 </param>
4572 <param name="value" type="wstring" dir="return">
4573 <desc>Value of the requested data key.</desc>
4574 </param>
4575 </method>
4576
4577 <method name="setExtraData">
4578 <desc>
4579 Sets associated machine-specific extra data.
4580
4581 If you pass @c NULL as a key @a value, the given @a key will be
4582 deleted.
4583
4584 <note>
4585 Before performing the actual data change, this method will ask all
4586 registered callbacks using the
4587 <link to="IVirtualBoxCallback::onExtraDataCanChange"/>
4588 notification for a permission. If one of the callbacks refuses the
4589 new value, the change will not be performed.
4590 </note>
4591 <note>
4592 On success, the
4593 <link to="IVirtualBoxCallback::onExtraDataChange"/> notification
4594 is called to inform all registered callbacks about a successful data
4595 change.
4596 </note>
4597 <note>
4598 This method can be called outside the machine session and therefore
4599 it's a caller's responsibility to handle possible race conditions
4600 when several clients change the same key at the same time.
4601 </note>
4602
4603 <result name="VBOX_E_FILE_ERROR">
4604 Settings file not accessible.
4605 </result>
4606 <result name="VBOX_E_XML_ERROR">
4607 Could not parse the settings file.
4608 </result>
4609
4610 </desc>
4611 <param name="key" type="wstring" dir="in">
4612 <desc>Name of the data key to set.</desc>
4613 </param>
4614 <param name="value" type="wstring" dir="in">
4615 <desc>Value to assign to the key.</desc>
4616 </param>
4617 </method>
4618
4619 <method name="saveSettings">
4620 <desc>
4621 Saves any changes to machine settings made since the session
4622 has been opened or a new machine has been created, or since the
4623 last call to <link to="#saveSettings"/> or <link to="#discardSettings"/>.
4624 For registered machines, new settings become visible to all
4625 other VirtualBox clients after successful invocation of this
4626 method.
4627 <note>
4628 The method sends <link to="IVirtualBoxCallback::onMachineDataChange"/>
4629 notification event after the configuration has been successfully
4630 saved (only for registered machines).
4631 </note>
4632 <note>
4633 Calling this method is only valid on instances returned
4634 by <link to="ISession::machine"/> and on new machines
4635 created by <link to="IVirtualBox::createMachine"/> but not
4636 yet registered, or on unregistered machines after calling
4637 <link to="IVirtualBox::unregisterMachine"/>.
4638 </note>
4639
4640 <result name="VBOX_E_FILE_ERROR">
4641 Settings file not accessible.
4642 </result>
4643 <result name="VBOX_E_XML_ERROR">
4644 Could not parse the settings file.
4645 </result>
4646 <result name="E_ACCESSDENIED">
4647 Modification request refused.
4648 </result>
4649
4650 </desc>
4651 </method>
4652
4653 <method name="saveSettingsWithBackup">
4654 <desc>
4655 Creates a backup copy of the machine settings file (<link
4656 to="#settingsFilePath"/>) in case of auto-conversion, and then calls
4657 <link to="#saveSettings"/>.
4658
4659 Note that the backup copy is created <b>only</b> if the settings file
4660 auto-conversion took place (see <link to="#settingsFileVersion"/> for
4661 details). Otherwise, this call is fully equivalent to
4662 <link to="#saveSettings"/> and no backup copying is done.
4663
4664 The backup copy is created in the same directory where the original
4665 settings file is located. It is given the following file name:
4666 <pre>
4667 original.xml.x.y-platform.bak
4668 </pre>
4669 where <tt>original.xml</tt> is the original settings file name
4670 (excluding path), and <tt>x.y-platform</tt> is the version of the old
4671 format of the settings file (before auto-conversion).
4672
4673 If the given backup file already exists, this method will try to add the
4674 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
4675 0 to 9) and copy it again until it succeeds. If all suffixes are
4676 occupied, or if any other copy error occurs, this method will return a
4677 failure.
4678
4679 If the copy operation succeeds, the @a bakFileName return argument will
4680 receive a full path to the created backup file (for informational
4681 purposes). Note that this will happen even if the subsequent
4682 <link to="#saveSettings"/> call performed by this method after the
4683 copy operation, fails.
4684
4685 <note>
4686 The VirtualBox API never calls this method. It is intended purely for
4687 the purposes of creating backup copies of the settings files by
4688 front-ends before saving the results of the automatically performed
4689 settings conversion to disk.
4690 </note>
4691
4692 <see>settingsFileVersion</see>
4693
4694 <result name="VBOX_E_FILE_ERROR">
4695 Settings file not accessible.
4696 </result>
4697 <result name="VBOX_E_XML_ERROR">
4698 Could not parse the settings file.
4699 </result>
4700 <result name="VBOX_E_INVALID_VM_STATE">
4701 Virtual machine is not mutable.
4702 </result>
4703 <result name="E_ACCESSDENIED">
4704 Modification request refused.
4705 </result>
4706
4707 </desc>
4708 <param name="bakFileName" type="wstring" dir="return">
4709 <desc>Full path to the created backup copy.</desc>
4710 </param>
4711 </method>
4712
4713 <method name="discardSettings">
4714 <desc>
4715 Discards any changes to the machine settings made since the session
4716 has been opened or since the last call to <link to="#saveSettings"/>
4717 or <link to="#discardSettings"/>.
4718 <note>
4719 Calling this method is only valid on instances returned
4720 by <link to="ISession::machine"/> and on new machines
4721 created by <link to="IVirtualBox::createMachine"/> or
4722 opened by <link to="IVirtualBox::openMachine"/> but not
4723 yet registered, or on unregistered machines after calling
4724 <link to="IVirtualBox::unregisterMachine"/>.
4725 </note>
4726
4727 <result name="VBOX_E_INVALID_VM_STATE">
4728 Virtual machine is not mutable.
4729 </result>
4730
4731 </desc>
4732 </method>
4733
4734 <method name="deleteSettings">
4735 <desc>
4736 Deletes the settings file of this machine from disk.
4737 The machine must not be registered in order for this operation
4738 to succeed.
4739 <note>
4740 <link to="#settingsModified"/> will return TRUE after this
4741 method successfully returns.
4742 </note>
4743 <note>
4744 Calling this method is only valid on instances returned
4745 by <link to="ISession::machine"/> and on new machines
4746 created by <link to="IVirtualBox::createMachine"/> or
4747 opened by <link to="IVirtualBox::openMachine"/> but not
4748 yet registered, or on unregistered machines after calling
4749 <link to="IVirtualBox::unregisterMachine"/>.
4750 </note>
4751 <note>
4752 The deleted machine settings file can be restored (saved again)
4753 by calling <link to="#saveSettings"/>.
4754 </note>
4755
4756 <result name="VBOX_E_INVALID_VM_STATE">
4757 Cannot delete settings of a registered machine or
4758 machine not mutable.
4759 </result>
4760 <result name="VBOX_E_IPRT_ERROR">
4761 Could not delete the settings file.
4762 </result>
4763
4764 </desc>
4765 </method>
4766
4767 <method name="export">
4768 <desc>Exports the machine to an OVF appliance. See <link to="IAppliance" /> for the
4769 steps required to export VirtualBox machines to OVF.
4770 </desc>
4771
4772 <param name="appliance" type="IAppliance" dir="in">
4773 <desc>Appliance to export this machine to.</desc>
4774 </param>
4775 </method >
4776
4777 <method name="getSnapshot">
4778 <desc>
4779 Returns a snapshot of this machine with the given UUID.
4780 A <tt>null</tt> UUID can be used to obtain the first snapshot
4781 taken on this machine. This is useful if you want to traverse
4782 the whole tree of snapshots starting from the root.
4783
4784 <result name="VBOX_E_OBJECT_NOT_FOUND">
4785 Virtual machine has no snapshots or snapshot not found.
4786 </result>
4787
4788 </desc>
4789 <param name="id" type="uuid" dir="in">
4790 <desc>UUID of the snapshot to get</desc>
4791 </param>
4792 <param name="snapshot" type="ISnapshot" dir="return">
4793 <desc>Snapshot object with the given UUID.</desc>
4794 </param>
4795 </method>
4796
4797 <method name="findSnapshot">
4798 <desc>
4799 Returns a snapshot of this machine with the given name.
4800
4801 <result name="VBOX_E_OBJECT_NOT_FOUND">
4802 Virtual machine has no snapshots or snapshot not found.
4803 </result>
4804
4805 </desc>
4806 <param name="name" type="wstring" dir="in">
4807 <desc>Name of the snapshot to find</desc>
4808 </param>
4809 <param name="snapshot" type="ISnapshot" dir="return">
4810 <desc>Snapshot object with the given name.</desc>
4811 </param>
4812 </method>
4813
4814 <method name="setCurrentSnapshot">
4815 <desc>
4816 Sets the current snapshot of this machine.
4817 <note>
4818 In the current implementation, this operation is not
4819 implemented.
4820 </note>
4821 </desc>
4822 <param name="id" type="uuid" dir="in">
4823 <desc>UUID of the snapshot to set as the current snapshot.</desc>
4824 </param>
4825 </method>
4826
4827 <method name="createSharedFolder">
4828 <desc>
4829 Creates a new permanent shared folder by associating the given logical
4830 name with the given host path, adds it to the collection of shared
4831 folders and starts sharing it. Refer to the description of
4832 <link to="ISharedFolder"/> to read more about logical names.
4833
4834 <result name="VBOX_E_OBJECT_IN_USE">
4835 Shared folder already exists.
4836 </result>
4837 <result name="VBOX_E_FILE_ERROR">
4838 Shared folder @a hostPath not accessible.
4839 </result>
4840
4841 </desc>
4842 <param name="name" type="wstring" dir="in">
4843 <desc>Unique logical name of the shared folder.</desc>
4844 </param>
4845 <param name="hostPath" type="wstring" dir="in">
4846 <desc>Full path to the shared folder in the host file system.</desc>
4847 </param>
4848 <param name="writable" type="boolean" dir="in">
4849 <desc>Whether the share is writable or readonly</desc>
4850 </param>
4851 </method>
4852
4853 <method name="removeSharedFolder">
4854 <desc>
4855 Removes the permanent shared folder with the given name previously
4856 created by <link to="#createSharedFolder"/> from the collection of
4857 shared folders and stops sharing it.
4858
4859 <result name="VBOX_E_INVALID_VM_STATE">
4860 Virtual machine is not mutable.
4861 </result>
4862 <result name="VBOX_E_OBJECT_NOT_FOUND">
4863 Shared folder @a name does not exist.
4864 </result>
4865
4866 </desc>
4867 <param name="name" type="wstring" dir="in">
4868 <desc>Logical name of the shared folder to remove.</desc>
4869 </param>
4870 </method>
4871
4872 <method name="canShowConsoleWindow">
4873 <desc>
4874 Returns @c true if the VM console process can activate the
4875 console window and bring it to foreground on the desktop of
4876 the host PC.
4877 <note>
4878 This method will fail if a session for this machine is not
4879 currently open.
4880 </note>
4881
4882 <result name="VBOX_E_INVALID_VM_STATE">
4883 Machine session is not open.
4884 </result>
4885
4886 </desc>
4887 <param name="canShow" type="boolean" dir="return">
4888 <desc>
4889 @c true if the console window can be shown and @c
4890 false otherwise.
4891 </desc>
4892 </param>
4893 </method>
4894
4895 <method name="showConsoleWindow">
4896 <desc>
4897 Activates the console window and brings it to foreground on
4898 the desktop of the host PC. Many modern window managers on
4899 many platforms implement some sort of focus stealing
4900 prevention logic, so that it may be impossible to activate
4901 a window without the help of the currently active
4902 application. In this case, this method will return a non-zero
4903 identifier that represents the top-level window of the VM
4904 console process. The caller, if it represents a currently
4905 active process, is responsible to use this identifier (in a
4906 platform-dependent manner) to perform actual window
4907 activation.
4908 <note>
4909 This method will fail if a session for this machine is not
4910 currently open.
4911 </note>
4912
4913 <result name="VBOX_E_INVALID_VM_STATE">
4914 Machine session is not open.
4915 </result>
4916
4917 </desc>
4918 <param name="winId" type="unsigned long long" dir="return">
4919 <desc>
4920 Platform-dependent identifier of the top-level VM console
4921 window, or zero if this method has performed all actions
4922 necessary to implement the <i>show window</i> semantics for
4923 the given platform and/or VirtualBox front-end.
4924 </desc>
4925 </param>
4926 </method>
4927
4928 <method name="getGuestProperty">
4929 <desc>
4930 Reads an entry from the machine's guest property store.
4931
4932 <result name="VBOX_E_INVALID_VM_STATE">
4933 Machine session is not open.
4934 </result>
4935
4936 </desc>
4937 <param name="name" type="wstring" dir="in">
4938 <desc>
4939 The name of the property to read.
4940 </desc>
4941 </param>
4942 <param name="value" type="wstring" dir="out">
4943 <desc>
4944 The value of the property. If the property does not exist then this
4945 will be empty.
4946 </desc>
4947 </param>
4948 <param name="timestamp" type="unsigned long long" dir="out">
4949 <desc>
4950 The time at which the property was last modified, as seen by the
4951 server process.
4952 </desc>
4953 </param>
4954 <param name="flags" type="wstring" dir="out">
4955 <desc>
4956 Additional property parameters, passed as a comma-separated list of
4957 "name=value" type entries.
4958 </desc>
4959 </param>
4960 </method>
4961
4962 <method name="getGuestPropertyValue">
4963 <desc>
4964 Reads a value from the machine's guest property store.
4965
4966 <result name="VBOX_E_INVALID_VM_STATE">
4967 Machine session is not open.
4968 </result>
4969
4970 </desc>
4971 <param name="property" type="wstring" dir="in">
4972 <desc>
4973 The name of the property to read.
4974 </desc>
4975 </param>
4976 <param name="value" type="wstring" dir="return">
4977 <desc>
4978 The value of the property. If the property does not exist then this
4979 will be empty.
4980 </desc>
4981 </param>
4982 </method>
4983
4984 <method name="getGuestPropertyTimestamp">
4985 <desc>
4986 Reads a property timestamp from the machine's guest property store.
4987
4988 <result name="VBOX_E_INVALID_VM_STATE">
4989 Machine session is not open.
4990 </result>
4991
4992 </desc>
4993 <param name="property" type="wstring" dir="in">
4994 <desc>
4995 The name of the property to read.
4996 </desc>
4997 </param>
4998 <param name="value" type="unsigned long long" dir="return">
4999 <desc>
5000 The timestamp. If the property does not exist then this will be
5001 empty.
5002 </desc>
5003 </param>
5004 </method>
5005
5006 <method name="setGuestProperty">
5007 <desc>
5008 Sets, changes or deletes an entry in the machine's guest property
5009 store.
5010
5011 <result name="E_ACCESSDENIED">
5012 Property cannot be changed.
5013 </result>
5014 <result name="E_INVALIDARG">
5015 Invalid @a flags.
5016 </result>
5017 <result name="VBOX_E_INVALID_VM_STATE">
5018 Virtual machine is not mutable or session not open.
5019 </result>
5020 <result name="VBOX_E_INVALID_OBJECT_STATE">
5021 Cannot set transient property when machine not running.
5022 </result>
5023
5024 </desc>
5025 <param name="property" type="wstring" dir="in">
5026 <desc>
5027 The name of the property to set, change or delete.
5028 </desc>
5029 </param>
5030 <param name="value" type="wstring" dir="in">
5031 <desc>
5032 The new value of the property to set, change or delete. If the
5033 property does not yet exist and value is non-empty, it will be
5034 created. If the value is empty, the key will be deleted if it
5035 exists.
5036 </desc>
5037 </param>
5038 <param name="flags" type="wstring" dir="in">
5039 <desc>
5040 Additional property parameters, passed as a comma-separated list of
5041 "name=value" type entries.
5042 </desc>
5043 </param>
5044 </method>
5045
5046 <method name="setGuestPropertyValue">
5047 <desc>
5048 Sets, changes or deletes a value in the machine's guest property
5049 store. The flags field will be left unchanged or created empty for a
5050 new property.
5051
5052 <result name="E_ACCESSDENIED">
5053 Property cannot be changed.
5054 </result>
5055 <result name="VBOX_E_INVALID_VM_STATE">
5056 Virtual machine is not mutable or session not open.
5057 </result>
5058 <result name="VBOX_E_INVALID_OBJECT_STATE">
5059 Cannot set transient property when machine not running.
5060 </result>
5061 </desc>
5062
5063 <param name="property" type="wstring" dir="in">
5064 <desc>
5065 The name of the property to set, change or delete.
5066 </desc>
5067 </param>
5068 <param name="value" type="wstring" dir="in">
5069 <desc>
5070 The new value of the property to set, change or delete. If the
5071 property does not yet exist and value is non-empty, it will be
5072 created. If value is empty, the property will be deleted if it
5073 exists.
5074 </desc>
5075 </param>
5076 </method>
5077
5078 <method name="enumerateGuestProperties">
5079 <desc>
5080 Return a list of the guest properties matching a set of patterns along
5081 with their values, time stamps and flags.
5082 </desc>
5083 <param name="patterns" type="wstring" dir="in">
5084 <desc>
5085 The patterns to match the properties against, separated by '|'
5086 characters. If this is empty or NULL, all properties will match.
5087 </desc>
5088 </param>
5089 <param name="name" type="wstring" dir="out" safearray="yes">
5090 <desc>
5091 The names of the properties returned.
5092 </desc>
5093 </param>
5094 <param name="value" type="wstring" dir="out" safearray="yes">
5095 <desc>
5096 The values of the properties returned. The array entries match the
5097 corresponding entries in the @a name array.
5098 </desc>
5099 </param>
5100 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
5101 <desc>
5102 The time stamps of the properties returned. The array entries match
5103 the corresponding entries in the @a name array.
5104 </desc>
5105 </param>
5106 <param name="flags" type="wstring" dir="out" safearray="yes">
5107 <desc>
5108 The flags of the properties returned. The array entries match the
5109 corresponding entries in the @a name array.
5110 </desc>
5111 </param>
5112 </method>
5113</interface>
5114
5115 <!--
5116 // IConsole
5117 /////////////////////////////////////////////////////////////////////////
5118 -->
5119
5120 <interface
5121 name="IConsoleCallback" extends="$unknown"
5122 uuid="13dfbef3-b74d-487d-bada-2304529aefa6"
5123 wsmap="suppress"
5124 >
5125
5126 <method name="onMousePointerShapeChange">
5127 <desc>
5128 Notification when the guest mouse pointer shape has
5129 changed. The new shape data is given.
5130 </desc>
5131 <param name="visible" type="boolean" dir="in">
5132 <desc>
5133 Flag whether the pointer is visible.
5134 </desc>
5135 </param>
5136 <param name="alpha" type="boolean" dir="in">
5137 <desc>
5138 Flag whether the pointer has an alpha channel.
5139 </desc>
5140 </param>
5141 <param name="xHot" type="unsigned long" dir="in">
5142 <desc>
5143 The pointer hot spot x coordinate.
5144 </desc>
5145 </param>
5146 <param name="yHot" type="unsigned long" dir="in">
5147 <desc>
5148 The pointer hot spot y coordinate.
5149 </desc>
5150 </param>
5151 <param name="width" type="unsigned long" dir="in">
5152 <desc>
5153 Width of the pointer shape in pixels.
5154 </desc>
5155 </param>
5156 <param name="height" type="unsigned long" dir="in">
5157 <desc>
5158 Height of the pointer shape in pixels.
5159 </desc>
5160 </param>
5161 <param name="shape" type="octet" mod="ptr" dir="in">
5162 <desc>
5163 Address of the shape buffer.
5164
5165 The @a shape buffer contains a 1-bpp (bits per pixel) AND mask
5166 followed by a 32-bpp XOR (color) mask.
5167
5168 For pointers without alpha channel the XOR mask pixels are 32
5169 bit values: (lsb)BGR0(msb). For pointers with alpha channel
5170 the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
5171
5172 An AND mask is used for pointers with alpha channel, so if the
5173 callback does not support alpha, the pointer could be
5174 displayed as a normal color pointer.
5175
5176 The AND mask is a 1-bpp bitmap with byte aligned scanlines. The
5177 size of the AND mask therefore is <tt>cbAnd = (width + 7) / 8 *
5178 height</tt>. The padding bits at the end of each scanline are
5179 undefined.
5180
5181 The XOR mask follows the AND mask on the next 4-byte aligned
5182 offset: <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>.
5183 Bytes in the gap between the AND and the XOR mask are undefined.
5184 The XOR mask scanlines have no gap between them and the size of
5185 the XOR mask is: <tt>cXor = width * 4 * height</tt>.
5186
5187 <note>
5188 If @a shape is 0, only the pointer visibility is changed.
5189 </note>
5190 </desc>
5191 </param>
5192 </method>
5193
5194 <method name="onMouseCapabilityChange">
5195 <desc>
5196 Notification when the mouse capabilities reported by the
5197 guest have changed. The new capabilities are passed.
5198 </desc>
5199 <param name="supportsAbsolute" type="boolean" dir="in"/>
5200 <param name="needsHostCursor" type="boolean" dir="in"/>
5201 </method>
5202
5203 <method name="onKeyboardLedsChange">
5204 <desc>
5205 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
5206 to alter the state of the keyboard LEDs.
5207 </desc>
5208 <param name="numLock" type="boolean" dir="in"/>
5209 <param name="capsLock" type="boolean" dir="in"/>
5210 <param name="scrollLock" type="boolean" dir="in"/>
5211 </method>
5212
5213 <method name="onStateChange">
5214 <desc>
5215 Notification when the execution state of the machine has changed.
5216 The new state will be given.
5217 </desc>
5218 <param name="state" type="MachineState" dir="in"/>
5219 </method>
5220
5221 <method name="onAdditionsStateChange">
5222 <desc>
5223 Notification when a Guest Additions property changes.
5224 Interested callees should query IGuest attributes to
5225 find out what has changed.
5226 </desc>
5227 </method>
5228
5229 <method name="onDVDDriveChange">
5230 <desc>
5231 Notification when a property of the
5232 virtual <link to="IMachine::DVDDrive">DVD drive</link> changes.
5233 Interested callees should use IDVDDrive methods to find out what has
5234 changed.
5235 </desc>
5236 </method>
5237
5238 <method name="onFloppyDriveChange">
5239 <desc>
5240 Notification when a property of the
5241 virtual <link to="IMachine::floppyDrive">floppy drive</link> changes.
5242 Interested callees should use IFloppyDrive methods to find out what
5243 has changed.
5244 </desc>
5245 </method>
5246
5247 <method name="onNetworkAdapterChange">
5248 <desc>
5249 Notification when a property of one of the
5250 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
5251 changes. Interested callees should use INetworkAdapter methods and
5252 attributes to find out what has changed.
5253 </desc>
5254 <param name="networkAdapter" type="INetworkAdapter" dir="in">
5255 <desc>Network adapter that is subject to change.</desc>
5256 </param>
5257 </method>
5258
5259 <method name="onSerialPortChange">
5260 <desc>
5261 Notification when a property of one of the
5262 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
5263 Interested callees should use ISerialPort methods and attributes
5264 to find out what has changed.
5265 </desc>
5266 <param name="serialPort" type="ISerialPort" dir="in">
5267 <desc>Serial port that is subject to change.</desc>
5268 </param>
5269 </method>
5270
5271 <method name="onParallelPortChange">
5272 <desc>
5273 Notification when a property of one of the
5274 virtual <link to="IMachine::getParallelPort">parallel ports</link>
5275 changes. Interested callees should use ISerialPort methods and
5276 attributes to find out what has changed.
5277 </desc>
5278 <param name="parallelPort" type="IParallelPort" dir="in">
5279 <desc>Parallel port that is subject to change.</desc>
5280 </param>
5281 </method>
5282
5283 <method name="onStorageControllerChange">
5284 <desc>
5285 Notification when a property of one of the
5286 virtual <link to="IMachine::getStorageControllers">storage controllers</link>
5287 changes. Interested callees should use query the corresponding collections
5288 to find out what has changed.
5289 </desc>
5290 </method>
5291
5292 <method name="onVRDPServerChange">
5293 <desc>
5294 Notification when a property of the
5295 <link to="IMachine::VRDPServer">VRDP server</link> changes.
5296 Interested callees should use IVRDPServer methods and attributes to
5297 find out what has changed.
5298 </desc>
5299 </method>
5300
5301 <method name="onUSBControllerChange">
5302 <desc>
5303 Notification when a property of the virtual
5304 <link to="IMachine::USBController">USB controller</link> changes.
5305 Interested callees should use IUSBController methods and attributes to
5306 find out what has changed.
5307 </desc>
5308 </method>
5309
5310 <method name="onUSBDeviceStateChange">
5311 <desc>
5312 Notification when a USB device is attached to or detached from
5313 the virtual USB controller.
5314
5315 This notification is sent as a result of the indirect
5316 request to attach the device because it matches one of the
5317 machine USB filters, or as a result of the direct request
5318 issued by <link to="IConsole::attachUSBDevice"/> or
5319 <link to="IConsole::detachUSBDevice"/>.
5320
5321 This notification is sent in case of both a succeeded and a
5322 failed request completion. When the request succeeds, the
5323 @a error parameter is @c null, and the given device has been
5324 already added to (when @a attached is @c true) or removed from
5325 (when @a attached is @c false) the collection represented by
5326 <link to="IConsole::USBDevices"/>. On failure, the collection
5327 doesn't change and the @a error parameter represents the error
5328 message describing the failure.
5329
5330 </desc>
5331 <param name="device" type="IUSBDevice" dir="in">
5332 <desc>Device that is subject to state change.</desc>
5333 </param>
5334 <param name="attached" type="boolean" dir="in">
5335 <desc>
5336 <tt>true</tt> if the device was attached
5337 and <tt>false</tt> otherwise.
5338 </desc>
5339 </param>
5340 <param name="error" type="IVirtualBoxErrorInfo" dir="in">
5341 <desc>
5342 <tt>null</tt> on success or an error message object on
5343 failure.
5344 </desc>
5345 </param>
5346 </method>
5347
5348 <method name="onSharedFolderChange">
5349 <desc>
5350 Notification when a shared folder is added or removed.
5351 The @a scope argument defines one of three scopes:
5352 <link to="IVirtualBox::sharedFolders">global shared folders</link>
5353 (<link to="Scope_Global">Global</link>),
5354 <link to="IMachine::sharedFolders">permanent shared folders</link> of
5355 the machine (<link to="Scope_Machine">Machine</link>) or <link
5356 to="IConsole::sharedFolders">transient shared folders</link> of the
5357 machine (<link to="Scope_Session">Session</link>). Interested callees
5358 should use query the corresponding collections to find out what has
5359 changed.
5360 </desc>
5361 <param name="scope" type="Scope" dir="in">
5362 <desc>Scope of the notification.</desc>
5363 </param>
5364 </method>
5365
5366 <method name="onRuntimeError">
5367 <desc>
5368 Notification when an error happens during the virtual
5369 machine execution.
5370
5371 There are three kinds of runtime errors:
5372 <ul>
5373 <li><i>fatal</i></li>
5374 <li><i>non-fatal with retry</i></li>
5375 <li><i>non-fatal warnings</i></li>
5376 </ul>
5377
5378 <b>Fatal</b> errors are indicated by the @a fatal parameter set
5379 to <tt>true</tt>. In case of fatal errors, the virtual machine
5380 execution is always paused before calling this notification, and
5381 the notification handler is supposed either to immediately save
5382 the virtual machine state using <link to="IConsole::saveState"/>
5383 or power it off using <link to="IConsole::powerDown"/>.
5384 Resuming the execution can lead to unpredictable results.
5385
5386 <b>Non-fatal</b> errors and warnings are indicated by the
5387 @a fatal parameter set to <tt>false</tt>. If the virtual machine
5388 is in the Paused state by the time the error notification is
5389 received, it means that the user can <i>try to resume</i> the machine
5390 execution after attempting to solve the problem that caused the
5391 error. In this case, the notification handler is supposed
5392 to show an appropriate message to the user (depending on the
5393 value of the @a id parameter) that offers several actions such
5394 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
5395 wants to retry, the notification handler should continue
5396 the machine execution using the <link to="IConsole::resume"/>
5397 call. If the machine execution is not Paused during this
5398 notification, then it means this notification is a <i>warning</i>
5399 (for example, about a fatal condition that can happen very soon);
5400 no immediate action is required from the user, the machine
5401 continues its normal execution.
5402
5403 Note that in either case the notification handler
5404 <b>must not</b> perform any action directly on a thread
5405 where this notification is called. Everything it is allowed to
5406 do is to post a message to another thread that will then talk
5407 to the user and take the corresponding action.
5408
5409 Currently, the following error identifiers are known:
5410 <ul>
5411 <li><tt>"HostMemoryLow"</tt></li>
5412 <li><tt>"HostAudioNotResponding"</tt></li>
5413 <li><tt>"VDIStorageFull"</tt></li>
5414 </ul>
5415
5416 <note>
5417 This notification is not designed to be implemented by
5418 more than one callback at a time. If you have multiple
5419 IConsoleCallback instances registered on the given
5420 IConsole object, make sure you simply do nothing but
5421 return @c S_OK from all but one of them that does actual
5422 user notification and performs necessary actions.
5423 </note>
5424
5425 </desc>
5426 <param name="fatal" type="boolean" dir="in">
5427 <desc>Whether the error is fatal or not</desc>
5428 </param>
5429 <param name="id" type="wstring" dir="in">
5430 <desc>Error identifier</desc>
5431 </param>
5432 <param name="message" type="wstring" dir="in">
5433 <desc>Optional error message</desc>
5434 </param>
5435 </method>
5436
5437 <method name="onCanShowWindow">
5438 <desc>
5439 Notification when a call to
5440 <link to="IMachine::canShowConsoleWindow"/> is made by a
5441 front-end to check if a subsequent call to
5442 <link to="IMachine::showConsoleWindow"/> can succeed.
5443
5444 The callee should give an answer appropriate to the current
5445 machine state in the @a canShow argument. This answer must
5446 remain valid at least until the next
5447 <link to="IConsole::state">machine state</link> change.
5448
5449 <note>
5450 This notification is not designed to be implemented by
5451 more than one callback at a time. If you have multiple
5452 IConsoleCallback instances registered on the given
5453 IConsole object, make sure you simply do nothing but
5454 return @c true and @c S_OK from all but one of them that
5455 actually manages console window activation.
5456 </note>
5457 </desc>
5458 <param name="canShow" type="boolean" dir="return">
5459 <desc>
5460 @c true if the console window can be shown and @c
5461 false otherwise.
5462 </desc>
5463 </param>
5464 </method>
5465
5466 <method name="onShowWindow">
5467 <desc>
5468 Notification when a call to
5469 <link to="IMachine::showConsoleWindow"/>
5470 requests the console window to be activated and brought to
5471 foreground on the desktop of the host PC.
5472
5473 This notification should cause the VM console process to
5474 perform the requested action as described above. If it is
5475 impossible to do it at a time of this notification, this
5476 method should return a failure.
5477
5478 Note that many modern window managers on many platforms
5479 implement some sort of focus stealing prevention logic, so
5480 that it may be impossible to activate a window without the
5481 help of the currently active application (which is supposedly
5482 an initiator of this notification). In this case, this method
5483 must return a non-zero identifier that represents the
5484 top-level window of the VM console process. The caller, if it
5485 represents a currently active process, is responsible to use
5486 this identifier (in a platform-dependent manner) to perform
5487 actual window activation.
5488
5489 This method must set @a winId to zero if it has performed all
5490 actions necessary to complete the request and the console
5491 window is now active and in foreground, to indicate that no
5492 further action is required on the caller's side.
5493
5494 <note>
5495 This notification is not designed to be implemented by
5496 more than one callback at a time. If you have multiple
5497 IConsoleCallback instances registered on the given
5498 IConsole object, make sure you simply do nothing but
5499 return @c S_OK from all but one of them that actually
5500 manages console window activation.
5501 </note>
5502 </desc>
5503 <param name="winId" type="unsigned long long" dir="return">
5504 <desc>
5505 Platform-dependent identifier of the top-level VM console
5506 window, or zero if this method has performed all actions
5507 necessary to implement the <i>show window</i> semantics for
5508 the given platform and/or this VirtualBox front-end.
5509 </desc>
5510 </param>
5511 </method>
5512
5513 </interface>
5514
5515 <interface
5516 name="IRemoteDisplayInfo" extends="$unknown"
5517 uuid="550104cd-2dfd-4a6c-857d-f6f8e088e62c"
5518 wsmap="struct"
5519 >
5520 <desc>
5521 Contains information about the remote display (VRDP) capabilities and status.
5522 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
5523 </desc>
5524
5525 <attribute name="active" type="boolean" readonly="yes">
5526 <desc>
5527 Whether the remote display connection is active.
5528 </desc>
5529 </attribute>
5530
5531 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
5532 <desc>
5533 How many times a client connected.
5534 </desc>
5535 </attribute>
5536
5537 <attribute name="beginTime" type="long long" readonly="yes">
5538 <desc>
5539 When the last connection was established, in milliseconds since 1970-01-01 UTC.
5540 </desc>
5541 </attribute>
5542
5543 <attribute name="endTime" type="long long" readonly="yes">
5544 <desc>
5545 When the last connection was terminated or the current time, if
5546 connection is still active, in milliseconds since 1970-01-01 UTC.
5547 </desc>
5548 </attribute>
5549
5550 <attribute name="bytesSent" type="unsigned long long" readonly="yes">
5551 <desc>
5552 How many bytes were sent in last or current, if still active, connection.
5553 </desc>
5554 </attribute>
5555
5556 <attribute name="bytesSentTotal" type="unsigned long long" readonly="yes">
5557 <desc>
5558 How many bytes were sent in all connections.
5559 </desc>
5560 </attribute>
5561
5562 <attribute name="bytesReceived" type="unsigned long long" readonly="yes">
5563 <desc>
5564 How many bytes were received in last or current, if still active, connection.
5565 </desc>
5566 </attribute>
5567
5568 <attribute name="bytesReceivedTotal" type="unsigned long long" readonly="yes">
5569 <desc>
5570 How many bytes were received in all connections.
5571 </desc>
5572 </attribute>
5573
5574 <attribute name="user" type="wstring" readonly="yes">
5575 <desc>
5576 Login user name supplied by the client.
5577 </desc>
5578 </attribute>
5579
5580 <attribute name="domain" type="wstring" readonly="yes">
5581 <desc>
5582 Login domain name supplied by the client.
5583 </desc>
5584 </attribute>
5585
5586 <attribute name="clientName" type="wstring" readonly="yes">
5587 <desc>
5588 The client name supplied by the client.
5589 </desc>
5590 </attribute>
5591
5592 <attribute name="clientIP" type="wstring" readonly="yes">
5593 <desc>
5594 The IP address of the client.
5595 </desc>
5596 </attribute>
5597
5598 <attribute name="clientVersion" type="unsigned long" readonly="yes">
5599 <desc>
5600 The client software version number.
5601 </desc>
5602 </attribute>
5603
5604 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
5605 <desc>
5606 Public key exchange method used when connection was established.
5607 Values: 0 - RDP4 public key exchange scheme.
5608 1 - X509 certificates were sent to client.
5609 </desc>
5610 </attribute>
5611
5612 </interface>
5613
5614 <interface
5615 name="IConsole" extends="$unknown"
5616 uuid="9511bc54-15ee-4ddf-808e-472aba03809c"
5617 wsmap="managed"
5618 >
5619 <desc>
5620 The IConsole interface represents an interface to control virtual
5621 machine execution.
5622
5623 The console object that implements the IConsole interface is obtained
5624 from a session object after the session for the given machine has been
5625 opened using one of <link to="IVirtualBox::openSession"/>,
5626 <link to="IVirtualBox::openRemoteSession"/> or
5627 <link to="IVirtualBox::openExistingSession"/> methods.
5628
5629 Methods of the IConsole interface allow the caller to query the current
5630 virtual machine execution state, pause the machine or power it down, save
5631 the machine state or take a snapshot, attach and detach removable media
5632 and so on.
5633
5634 <see>ISession</see>
5635 </desc>
5636
5637 <attribute name="machine" type="IMachine" readonly="yes">
5638 <desc>
5639 Machine object this console is sessioned with.
5640 <note>
5641 This is a convenience property, it has the same value as
5642 <link to="ISession::machine"/> of the corresponding session
5643 object.
5644 </note>
5645 </desc>
5646 </attribute>
5647
5648 <attribute name="state" type="MachineState" readonly="yes">
5649 <desc>
5650 Current execution state of the machine.
5651 <note>
5652 This property always returns the same value as the corresponding
5653 property of the IMachine object this console is sessioned with.
5654 For the process that owns (executes) the VM, this is the
5655 preferable way of querying the VM state, because no IPC
5656 calls are made.
5657 </note>
5658 </desc>
5659 </attribute>
5660
5661 <attribute name="guest" type="IGuest" readonly="yes">
5662 <desc>Guest object.</desc>
5663 </attribute>
5664
5665 <attribute name="keyboard" type="IKeyboard" readonly="yes">
5666 <desc>
5667 Virtual keyboard object.
5668 <note>
5669 If the machine is not running, any attempt to use
5670 the returned object will result in an error.
5671 </note>
5672 </desc>
5673 </attribute>
5674
5675 <attribute name="mouse" type="IMouse" readonly="yes">
5676 <desc>
5677 Virtual mouse object.
5678 <note>
5679 If the machine is not running, any attempt to use
5680 the returned object will result in an error.
5681 </note>
5682 </desc>
5683 </attribute>
5684
5685 <attribute name="display" type="IDisplay" readonly="yes">
5686 <desc>Virtual display object.
5687 <note>
5688 If the machine is not running, any attempt to use
5689 the returned object will result in an error.
5690 </note>
5691 </desc>
5692 </attribute>
5693
5694 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
5695 <desc>Debugging interface.</desc>
5696 </attribute>
5697
5698 <attribute name="USBDevices" type="IUSBDevice" readonly="yes" safearray="yes">
5699 <desc>
5700 Collection of USB devices currently attached to the virtual
5701 USB controller.
5702 <note>
5703 The collection is empty if the machine is not running.
5704 </note>
5705 </desc>
5706 </attribute>
5707
5708 <attribute name="remoteUSBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
5709 <desc>
5710 List of USB devices currently attached to the remote VRDP client.
5711 Once a new device is physically attached to the remote host computer,
5712 it appears in this list and remains there until detached.
5713 </desc>
5714 </attribute>
5715
5716 <attribute name="sharedFolders" type="ISharedFolder" readonly="yes" safearray="yes">
5717 <desc>
5718 Collection of shared folders for the current session. These folders
5719 are called transient shared folders because they are available to the
5720 guest OS running inside the associated virtual machine only for the
5721 duration of the session (as opposed to
5722 <link to="IMachine::sharedFolders"/> which represent permanent shared
5723 folders). When the session is closed (e.g. the machine is powered down),
5724 these folders are automatically discarded.
5725
5726 New shared folders are added to the collection using
5727 <link to="#createSharedFolder"/>. Existing shared folders can be
5728 removed using <link to="#removeSharedFolder"/>.
5729 </desc>
5730 </attribute>
5731
5732 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
5733 <desc>
5734 Interface that provides information on Remote Display (VRDP) connection.
5735 </desc>
5736 </attribute>
5737
5738 <method name="powerUp">
5739 <desc>
5740 Starts the virtual machine execution using the current machine
5741 state (that is, its current execution state, current settings and
5742 current hard disks).
5743
5744 If the machine is powered off or aborted, the execution will
5745 start from the beginning (as if the real hardware were just
5746 powered on).
5747
5748 If the machine is in the <link to="MachineState_Saved"/> state,
5749 it will continue its execution the point where the state has
5750 been saved.
5751
5752 <note>
5753 Unless you are trying to write a new VirtualBox front-end that
5754 performs direct machine execution (like the VirtualBox or VBoxSDL
5755 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
5756 session opened by <link to="IVirtualBox::openSession"/> and use this
5757 session only to change virtual machine settings. If you simply want to
5758 start virtual machine execution using one of the existing front-ends
5759 (for example the VirtualBox GUI or headless server), simply use
5760 <link to="IVirtualBox::openRemoteSession"/>; these front-ends will
5761 power up the machine automatically for you.
5762 </note>
5763
5764 <see>#saveState</see>
5765 <result name="VBOX_E_INVALID_VM_STATE">
5766 Virtual machine already running.
5767 </result>
5768 <result name="VBOX_E_HOST_ERROR">
5769 Host interface does not exist or name not set.
5770 </result>
5771 <result name="VBOX_E_FILE_ERROR">
5772 Invalid saved state file.
5773 </result>
5774 </desc>
5775 <param name="progress" type="IProgress" dir="return">
5776 <desc>Progress object to track the operation completion.</desc>
5777 </param>
5778 </method>
5779
5780 <method name="powerUpPaused">
5781 <desc>
5782 Identical to powerUp except that the VM will enter the
5783 <link to="MachineState_Paused"/> state, instead of
5784 <link to="MachineState_Running"/>.
5785
5786 <see>#powerUp</see>
5787 <result name="VBOX_E_INVALID_VM_STATE">
5788 Virtual machine already running.
5789 </result>
5790 <result name="VBOX_E_HOST_ERROR">
5791 Host interface does not exist or name not set.
5792 </result>
5793 <result name="VBOX_E_FILE_ERROR">
5794 Invalid saved state file.
5795 </result>
5796 </desc>
5797 <param name="progress" type="IProgress" dir="return">
5798 <desc>Progress object to track the operation completion.</desc>
5799 </param>
5800 </method>
5801
5802 <method name="powerDown">
5803 <desc>
5804 Stops the virtual machine execution.
5805 After this operation completes, the machine will go to the
5806 PoweredOff state.
5807
5808 @deprecated This method will be removed in VirtualBox 2.1 where the
5809 powerDownAsync() method will take its name. Do not use this method in
5810 the code.
5811 <result name="VBOX_E_INVALID_VM_STATE">
5812 Virtual machine must be Running, Paused or Stuck to be powered down.
5813 </result>
5814 <result name="VBOX_E_VM_ERROR">
5815 Unable to power off or destroy virtual machine.
5816 </result>
5817 </desc>
5818 </method>
5819
5820 <method name="powerDownAsync">
5821 <desc>
5822 Initiates the power down procedure to stop the virtual machine
5823 execution.
5824
5825 The completion of the power down procedure is tracked using the returned
5826 IProgress object. After the operation is complete, the machine will go
5827 to the PoweredOff state.
5828
5829 @warning This method will be renamed to "powerDown" in VirtualBox 2.1
5830 where the original powerDown() method will be removed. You will need to
5831 rename "powerDownAsync" to "powerDown" in your sources to make them
5832 build with version 2.1.
5833 <result name="VBOX_E_INVALID_VM_STATE">
5834 Virtual machine must be Running, Paused or Stuck to be powered down.
5835 </result>
5836 </desc>
5837 <param name="progress" type="IProgress" dir="return">
5838 <desc>Progress object to track the operation completion.</desc>
5839 </param>
5840 </method>
5841
5842 <method name="reset">
5843 <desc>Resets the virtual machine.
5844 <result name="VBOX_E_INVALID_VM_STATE">
5845 Virtual machine not in Running state.
5846 </result>
5847 <result name="VBOX_E_VM_ERROR">
5848 Virtual machine error in reset operation.
5849 </result>
5850 </desc>
5851 </method>
5852
5853 <method name="pause">
5854 <desc>Pauses the virtual machine execution.
5855 <result name="VBOX_E_INVALID_VM_STATE">
5856 Virtual machine not in Running state.
5857 </result>
5858 <result name="VBOX_E_VM_ERROR">
5859 Virtual machine error in suspend operation.
5860 </result>
5861 </desc>
5862 </method>
5863
5864 <method name="resume">
5865 <desc>Resumes the virtual machine execution.
5866 <result name="VBOX_E_INVALID_VM_STATE">
5867 Virtual machine not in Paused state.
5868 </result>
5869 <result name="VBOX_E_VM_ERROR">
5870 Virtual machine error in resume operation.
5871 </result>
5872 </desc>
5873 </method>
5874
5875 <method name="powerButton">
5876 <desc>Sends the ACPI power button event to the guest.
5877 <result name="VBOX_E_INVALID_VM_STATE">
5878 Virtual machine not in Running state.
5879 </result>
5880 <result name="VBOX_E_PDM_ERROR">
5881 Controlled power off failed.
5882 </result>
5883 </desc>
5884 </method>
5885
5886 <method name="sleepButton">
5887 <desc>Sends the ACPI sleep button event to the guest.
5888 <result name="VBOX_E_INVALID_VM_STATE">
5889 Virtual machine not in Running state.
5890 </result>
5891 <result name="VBOX_E_PDM_ERROR">
5892 Sending sleep button event failed.
5893 </result>
5894 </desc>
5895 </method>
5896
5897 <method name="getPowerButtonHandled">
5898 <desc>Checks if the last power button event was handled by guest.
5899 <result name="VBOX_E_PDM_ERROR">
5900 Checking if the event was handled by the guest OS failed.
5901 </result>
5902 </desc>
5903 <param name="handled" type="boolean" dir="return"/>
5904 </method>
5905
5906 <method name="getGuestEnteredACPIMode">
5907 <desc>Checks if the guest entered the ACPI mode G0 (working) or
5908 G1 (sleeping). If this method returns false, the guest will
5909 most likely not respond to external ACPI events.
5910 <result name="VBOX_E_INVALID_VM_STATE">
5911 Virtual machine not in Running state.
5912 </result>
5913 </desc>
5914 <param name="entered" type="boolean" dir="return"/>
5915 </method>
5916
5917 <method name="saveState">
5918 <desc>
5919 Saves the current execution state of a running virtual machine
5920 and stops its execution.
5921
5922 After this operation completes, the machine will go to the
5923 Saved state. Next time it is powered up, this state will
5924 be restored and the machine will continue its execution from
5925 the place where it was saved.
5926
5927 This operation differs from taking a snapshot to the effect
5928 that it doesn't create new differencing hard disks. Also, once
5929 the machine is powered up from the state saved using this method,
5930 the saved state is deleted, so it will be impossible to return
5931 to this state later.
5932
5933 <note>
5934 On success, this method implicitly calls
5935 <link to="IMachine::saveSettings"/> to save all current machine
5936 settings (including runtime changes to the DVD drive, etc.).
5937 Together with the impossibility to change any VM settings when it is
5938 in the Saved state, this guarantees adequate hardware
5939 configuration of the machine when it is restored from the saved
5940 state file.
5941 </note>
5942
5943 <note>
5944 The machine must be in the Running or Paused state, otherwise
5945 the operation will fail.
5946 </note>
5947 <result name="VBOX_E_INVALID_VM_STATE">
5948 Virtual machine state neither Running nor Paused.
5949 </result>
5950 <result name="VBOX_E_FILE_ERROR">
5951 Failed to create directory for saved state file.
5952 </result>
5953
5954 <see><link to="#takeSnapshot"/></see>
5955 </desc>
5956 <param name="progress" type="IProgress" dir="return">
5957 <desc>Progress object to track the operation completion.</desc>
5958 </param>
5959 </method>
5960
5961 <method name="adoptSavedState">
5962 <desc>
5963 Associates the given saved state file to the virtual machine.
5964
5965 On success, the machine will go to the Saved state. Next time it is
5966 powered up, it will be restored from the adopted saved state and
5967 continue execution from the place where the saved state file was
5968 created.
5969
5970 The specified saved state file path may be absolute or relative to the
5971 folder the VM normally saves the state to (usually,
5972 <link to="IMachine::snapshotFolder"/>).
5973
5974 <note>
5975 It's a caller's responsibility to make sure the given saved state
5976 file is compatible with the settings of this virtual machine that
5977 represent its virtual hardware (memory size, hard disk configuration
5978 etc.). If there is a mismatch, the behavior of the virtual machine
5979 is undefined.
5980 </note>
5981 <result name="VBOX_E_INVALID_VM_STATE">
5982 Virtual machine state neither PoweredOff nor Aborted.
5983 </result>
5984 </desc>
5985 <param name="savedStateFile" type="wstring" dir="in">
5986 <desc>Path to the saved state file to adopt.</desc>
5987 </param>
5988 </method>
5989
5990 <method name="discardSavedState">
5991 <desc>
5992 Discards (deletes) the saved state of the virtual machine
5993 previously created by <link to="#saveState"/>. Next time the
5994 machine is powered up, a clean boot will occur.
5995 <note>
5996 This operation is equivalent to resetting or powering off
5997 the machine without doing a proper shutdown in the guest OS.
5998 </note>
5999 <result name="VBOX_E_INVALID_VM_STATE">
6000 Virtual machine not in state Saved.
6001 </result>
6002 </desc>
6003 </method>
6004
6005 <method name="getDeviceActivity">
6006 <desc>
6007 Gets the current activity type of a given device or device group.
6008 <result name="E_INVALIDARG">
6009 Invalid device type.
6010 </result>
6011 </desc>
6012 <param name="type" type="DeviceType" dir="in"/>
6013 <param name="activity" type="DeviceActivity" dir="return"/>
6014 </method>
6015
6016 <method name="attachUSBDevice">
6017 <desc>
6018 Attaches a host USB device with the given UUID to the
6019 USB controller of the virtual machine.
6020
6021 The device needs to be in one of the following states:
6022 <link to="USBDeviceState_Busy"/>,
6023 <link to="USBDeviceState_Available"/> or
6024 <link to="USBDeviceState_Held"/>,
6025 otherwise an error is immediately returned.
6026
6027 When the device state is
6028 <link to="USBDeviceState_Busy">Busy</link>, an error may also
6029 be returned if the host computer refuses to release it for some reason.
6030
6031 <see>IUSBController::deviceFilters, USBDeviceState</see>
6032 <result name="VBOX_E_INVALID_VM_STATE">
6033 Virtual machine state neither Running nor Paused.
6034 </result>
6035 <result name="VBOX_E_PDM_ERROR">
6036 Virtual machine does not have a USB controller.
6037 </result>
6038 </desc>
6039 <param name="id" type="uuid" dir="in">
6040 <desc>UUID of the host USB device to attach.</desc>
6041 </param>
6042 </method>
6043
6044 <method name="detachUSBDevice">
6045 <desc>
6046 Detaches an USB device with the given UUID from the USB controller
6047 of the virtual machine.
6048
6049 After this method succeeds, the VirtualBox server re-initiates
6050 all USB filters as if the device were just physically attached
6051 to the host, but filters of this machine are ignored to avoid
6052 a possible automatic re-attachment.
6053
6054 <see>IUSBController::deviceFilters, USBDeviceState</see>
6055
6056 <result name="VBOX_E_PDM_ERROR">
6057 Virtual machine does not have a USB controller.
6058 </result>
6059 <result name="E_INVALIDARG">
6060 USB device not attached to this virtual machine.
6061 </result>
6062 </desc>
6063 <param name="id" type="uuid" dir="in">
6064 <desc>UUID of the USB device to detach.</desc>
6065 </param>
6066 <param name="device" type="IUSBDevice" dir="return">
6067 <desc>Detached USB device.</desc>
6068 </param>
6069 </method>
6070
6071 <method name="findUSBDeviceByAddress">
6072 <desc>
6073 Searches for a USB device with the given host address.
6074
6075 <result name="VBOX_E_OBJECT_NOT_FOUND">
6076 Given @c name does not correspond to any USB device.
6077 </result>
6078
6079 <see>IUSBDevice::address</see>
6080 </desc>
6081 <param name="name" type="wstring" dir="in">
6082 <desc>
6083 Address of the USB device (as assigned by the host) to
6084 search for.
6085 </desc>
6086 </param>
6087 <param name="device" type="IUSBDevice" dir="return">
6088 <desc>Found USB device object.</desc>
6089 </param>
6090 </method>
6091
6092 <method name="findUSBDeviceById">
6093 <desc>
6094 Searches for a USB device with the given UUID.
6095
6096 <result name="VBOX_E_OBJECT_NOT_FOUND">
6097 Given @c id does not correspond to any USB device.
6098 </result>
6099
6100 <see>IUSBDevice::id</see>
6101 </desc>
6102 <param name="id" type="uuid" dir="in">
6103 <desc>UUID of the USB device to search for.</desc>
6104 </param>
6105 <param name="device" type="IUSBDevice" dir="return">
6106 <desc>Found USB device object.</desc>
6107 </param>
6108 </method>
6109
6110 <method name="createSharedFolder">
6111 <desc>
6112 Creates a transient new shared folder by associating the given logical
6113 name with the given host path, adds it to the collection of shared
6114 folders and starts sharing it. Refer to the description of
6115 <link to="ISharedFolder"/> to read more about logical names.
6116
6117 <result name="VBOX_E_INVALID_VM_STATE">
6118 Virtual machine in Saved state or currently changing state.
6119 </result>
6120 <result name="VBOX_E_FILE_ERROR">
6121 Shared folder already exists or not accessible.
6122 </result>
6123 </desc>
6124 <param name="name" type="wstring" dir="in">
6125 <desc>Unique logical name of the shared folder.</desc>
6126 </param>
6127 <param name="hostPath" type="wstring" dir="in">
6128 <desc>Full path to the shared folder in the host file system.</desc>
6129 </param>
6130 <param name="writable" type="boolean" dir="in">
6131 <desc>Whether the share is writable or readonly</desc>
6132 </param>
6133 </method>
6134
6135 <method name="removeSharedFolder">
6136 <desc>
6137 Removes a transient shared folder with the given name previously
6138 created by <link to="#createSharedFolder"/> from the collection of
6139 shared folders and stops sharing it.
6140 <result name="VBOX_E_INVALID_VM_STATE">
6141 Virtual machine in Saved state or currently changing state.
6142 </result>
6143 <result name="VBOX_E_FILE_ERROR">
6144 Shared folder does not exists.
6145 </result>
6146 </desc>
6147 <param name="name" type="wstring" dir="in">
6148 <desc>Logical name of the shared folder to remove.</desc>
6149 </param>
6150 </method>
6151
6152 <method name="takeSnapshot">
6153 <desc>
6154 Saves the current execution state and all settings of the
6155 machine and creates differencing images for all
6156 normal (non-independent) hard disks.
6157
6158 This method can be called for a PoweredOff, Saved, Running or
6159 Paused virtual machine. When the machine is PoweredOff, an
6160 offline <link to="ISnapshot">snapshot</link> is created,
6161 in all other cases -- an online snapshot.
6162
6163 The taken snapshot is always based on the
6164 <link to="IMachine::currentSnapshot">current
6165 snapshot</link> of the associated virtual machine and becomes
6166 a new current snapshot.
6167
6168 <note>
6169 This method implicitly calls <link to="IMachine::saveSettings"/> to
6170 save all current machine settings before taking an offline snapshot.
6171 </note>
6172
6173 <see>ISnapshot, <link to="#saveState"/></see>
6174 <result name="VBOX_E_INVALID_VM_STATE">
6175 Virtual machine currently changing state.
6176 </result>
6177 </desc>
6178 <param name="name" type="wstring" dir="in">
6179 <desc>Short name for the snapshot.</desc>
6180 </param>
6181 <param name="description" type="wstring" dir="in">
6182 <desc>Optional description of the snapshot.</desc>
6183 </param>
6184 <param name="progress" type="IProgress" dir="return">
6185 <desc>Progress object to track the operation completion.</desc>
6186 </param>
6187 </method>
6188
6189 <method name="discardSnapshot">
6190 <desc>
6191
6192 Starts discarding the specified snapshot. The execution state
6193 and settings of the associated machine stored in the snapshot
6194 will be deleted. The contents of all differencing hard disks of
6195 this snapshot will be merged with the contents of their
6196 dependent child hard disks to keep the, disks valid (in other
6197 words, all changes represented by hard disks being discarded
6198 will be propagated to their child hard disks). After that, this
6199 snapshot's differencing hard disks will be deleted. The parent
6200 of this snapshot will become a new parent for all its child
6201 snapshots.
6202
6203 If the discarded snapshot is the current one, its parent
6204 snapshot will become a new current snapshot. The current machine
6205 state is not directly affected in this case, except that
6206 currently attached differencing hard disks based on hard disks
6207 of the discarded snapshot will be also merged as described
6208 above.
6209
6210 If the discarded snapshot is the first one (the root snapshot)
6211 and it has exactly one child snapshot, this child snapshot will
6212 become the first snapshot after discarding. If there are no
6213 children at all (i.e. the first snapshot is the only snapshot of
6214 the machine), both the current and the first snapshot of the
6215 machine will be set to null. In all other cases, the first
6216 snapshot cannot be discarded.
6217
6218 You cannot discard the snapshot if it
6219 stores <link to="HardDiskType_Normal">normal</link> (non-differencing)
6220 hard disks that have differencing hard disks based on them. Snapshots of
6221 such kind can be discarded only when every normal hard disk has either
6222 no children at all or exactly one child. In the former case, the normal
6223 hard disk simply becomes unused (i.e. not attached to any VM). In the
6224 latter case, it receives all the changes stored in the child hard disk,
6225 and then it replaces the child hard disk in the configuration of the
6226 corresponding snapshot or machine.
6227
6228 Also, you cannot discard the snapshot if it stores hard disks
6229 (of any type) having differencing child hard disks that belong
6230 to other machines. Such snapshots can be only discarded after
6231 you discard all snapshots of other machines containing "foreign"
6232 child disks, or detach these "foreign" child disks from machines
6233 they are attached to.
6234
6235 One particular example of the snapshot storing normal hard disks
6236 is the first snapshot of a virtual machine that had normal hard
6237 disks attached when taking the snapshot. Be careful when
6238 discarding such snapshots because this implicitly commits
6239 changes (made since the snapshot being discarded has been taken)
6240 to normal hard disks (as described above), which may be not what
6241 you want.
6242
6243 The virtual machine is put to
6244 the <link to="MachineState_Discarding">Discarding</link> state until
6245 the discard operation is completed.
6246
6247 <note>
6248 The machine must not be running, otherwise the operation
6249 will fail.
6250 </note>
6251
6252 <note>
6253 Child hard disks of all normal hard disks of the discarded snapshot
6254 must be accessible (see <link to="IMedium::state"/>) for this
6255 operation to succeed. In particular, this means that all virtual
6256 machines, whose hard disks are directly or indirectly based on the
6257 hard disks of discarded snapshot, must be powered off.
6258 </note>
6259 <note>
6260 Merging hard disk contents can be very time and disk space
6261 consuming, if these disks are big in size and have many
6262 children. However, if the snapshot being discarded is the last
6263 (head) snapshot on the branch, the operation will be rather
6264 quick.
6265 </note>
6266 <note>
6267 Note that discarding the current snapshot
6268 will implicitly call <link to="IMachine::saveSettings"/> to
6269 make all current machine settings permanent.
6270 </note>
6271 <result name="VBOX_E_INVALID_VM_STATE">
6272 Virtual machine is running.
6273 </result>
6274 </desc>
6275 <param name="id" type="uuid" dir="in">
6276 <desc>UUID of the snapshot to discard.</desc>
6277 </param>
6278 <param name="progress" type="IProgress" dir="return">
6279 <desc>Progress object to track the operation completion.</desc>
6280 </param>
6281 </method>
6282
6283 <method name="discardCurrentState">
6284 <desc>
6285 This operation is similar to <link to="#discardSnapshot"/> but
6286 affects the current machine state. This means that the state stored in
6287 the current snapshot will become a new current state, and all current
6288 settings of the machine and changes stored in differencing hard disks
6289 will be lost.
6290
6291 After this operation is successfully completed, new empty differencing
6292 hard disks are created for all normal hard disks of the machine.
6293
6294 If the current snapshot of the machine is an online snapshot, the
6295 machine will go to the <link to="MachineState_Saved"> saved
6296 state</link>, so that the next time it is powered on, the execution
6297 state will be restored from the current snapshot.
6298
6299 <note>
6300 The machine must not be running, otherwise the operation will fail.
6301 </note>
6302
6303 <note>
6304 If the machine state is <link to="MachineState_Saved">Saved</link>
6305 prior to this operation, the saved state file will be implicitly
6306 discarded (as if <link to="IConsole::discardSavedState"/> were
6307 called).
6308 </note>
6309
6310 <result name="VBOX_E_INVALID_VM_STATE">
6311 Virtual machine is running.
6312 </result>
6313 </desc>
6314 <param name="progress" type="IProgress" dir="return">
6315 <desc>Progress object to track the operation completion.</desc>
6316 </param>
6317 </method>
6318
6319 <method name="discardCurrentSnapshotAndState">
6320 <desc>
6321
6322 This method is equivalent to
6323 doing <link to="IConsole::discardSnapshot">discardSnapshot</link>
6324 (currentSnapshot.id(), progress) followed by
6325 <link to="#discardCurrentState"/>.
6326
6327 As a result, the machine will be fully restored from the
6328 snapshot preceding the current snapshot, while both the current
6329 snapshot and the current machine state will be discarded.
6330
6331 If the current snapshot is the first snapshot of the machine (i.e. it
6332 has the only snapshot), the current machine state will be
6333 discarded <b>before</b> discarding the snapshot. In other words, the
6334 machine will be restored from its last snapshot, before discarding
6335 it. This differs from performing a single
6336 <link to="#discardSnapshot"/> call (note that no
6337 <link to="#discardCurrentState"/> will be possible after it)
6338 to the effect that the latter will preserve the current state instead of
6339 discarding it.
6340
6341 Unless explicitly mentioned otherwise, all remarks and
6342 limitations of the above two methods also apply to this method.
6343
6344 <note>
6345 The machine must not be running, otherwise the operation
6346 will fail.
6347 </note>
6348
6349 <note>
6350 If the machine state is <link to="MachineState_Saved">Saved</link>
6351 prior to this operation, the saved state file will be implicitly
6352 discarded (as if <link to="#discardSavedState"/> were
6353 called).
6354 </note>
6355
6356 <note>
6357 This method is more efficient than calling both of the above
6358 methods separately: it requires less IPC calls and provides
6359 a single progress object.
6360 </note>
6361
6362 <result name="VBOX_E_INVALID_VM_STATE">
6363 Virtual machine is running.
6364 </result>
6365 </desc>
6366 <param name="progress" type="IProgress" dir="return">
6367 <desc>Progress object to track the operation completion.</desc>
6368 </param>
6369 </method>
6370
6371 <method name="registerCallback">
6372 <desc>
6373 Registers a new console callback on this instance. The methods of the
6374 callback interface will be called by this instance when the appropriate
6375 event occurs.
6376 </desc>
6377 <param name="callback" type="IConsoleCallback" dir="in"/>
6378 </method>
6379
6380 <method name="unregisterCallback">
6381 <desc>
6382 Unregisters the console callback previously registered using
6383 <link to="#registerCallback"/>.
6384 <result name="E_INVALIDARG">
6385 Given @a callback handler is not registered.
6386 </result>
6387 </desc>
6388 <param name="callback" type="IConsoleCallback" dir="in"/>
6389 </method>
6390 </interface>
6391
6392 <!--
6393 // IHost
6394 /////////////////////////////////////////////////////////////////////////
6395 -->
6396
6397 <interface
6398 name="IHostDVDDrive" extends="$unknown"
6399 uuid="21f86694-202d-4ce4-8b05-a63ff82dbf4c"
6400 wsmap="managed"
6401 >
6402 <desc>
6403 The IHostDVDDrive interface represents the physical CD/DVD drive
6404 hardware on the host. Used indirectly in <link to="IHost::DVDDrives"/>.
6405 </desc>
6406
6407 <attribute name="name" type="wstring" readonly="yes">
6408 <desc>
6409 Returns the platform-specific device identifier.
6410 On DOS-like platforms, it is a drive name (e.g. R:).
6411 On Unix-like platforms, it is a device name (e.g. /dev/hdc).
6412 </desc>
6413 </attribute>
6414 <attribute name="description" type="wstring" readonly="yes">
6415 <desc>
6416 Returns a human readable description for the drive. This
6417 description usually contains the product and vendor name. A
6418 @c null string is returned if the description is not available.
6419 </desc>
6420 </attribute>
6421 <attribute name="udi" type="wstring" readonly="yes">
6422 <desc>
6423 Returns the unique device identifier for the drive. This
6424 attribute is reserved for future use instead of
6425 <link to="#name"/>. Currently it is not used and may return
6426 @c null on some platforms.
6427 </desc>
6428 </attribute>
6429
6430 </interface>
6431
6432 <interface
6433 name="IHostFloppyDrive" extends="$unknown"
6434 uuid="3f02d604-e908-4919-9fd1-8a4afd68fc63"
6435 wsmap="managed"
6436 >
6437 <desc>
6438 The IHostFloppyDrive interface represents the physical floppy drive
6439 hardware on the host. Used indirectly in <link to="IHost::floppyDrives"/>.
6440 </desc>
6441 <attribute name="name" type="wstring" readonly="yes">
6442 <desc>
6443 Returns the platform-specific device identifier.
6444 On DOS-like platforms, it is a drive name (e.g. A:).
6445 On Unix-like platforms, it is a device name (e.g. /dev/fd0).
6446 </desc>
6447 </attribute>
6448 <attribute name="description" type="wstring" readonly="yes">
6449 <desc>
6450 Returns a human readable description for the drive. This
6451 description usually contains the product and vendor name. A
6452 @c null string is returned if the description is not available.
6453 </desc>
6454 </attribute>
6455 <attribute name="udi" type="wstring" readonly="yes">
6456 <desc>
6457 Returns the unique device identifier for the drive. This
6458 attribute is reserved for future use instead of
6459 <link to="#name"/>. Currently it is not used and may return
6460 @c null on some platforms.
6461 </desc>
6462 </attribute>
6463 </interface>
6464
6465 <enum
6466 name="HostNetworkInterfaceMediumType"
6467 uuid="1aa54aaf-2497-45a2-bfb1-8eb225e93d5b"
6468 >
6469 <desc>
6470 Type of encapsulation. Ethernet encapsulation includes both wired and
6471 wireless Ethernet connections.
6472 <see>IHostNetworkInterface</see>
6473 </desc>
6474
6475 <const name="Unknown" value="0">
6476 <desc>
6477 The type of interface cannot be determined.
6478 </desc>
6479 </const>
6480 <const name="Ethernet" value="1">
6481 <desc>
6482 Ethernet frame encapsulation.
6483 </desc>
6484 </const>
6485 <const name="PPP" value="2">
6486 <desc>
6487 Point-to-point protocol encapsulation.
6488 </desc>
6489 </const>
6490 <const name="SLIP" value="3">
6491 <desc>
6492 Serial line IP encapsulation.
6493 </desc>
6494 </const>
6495 </enum>
6496
6497 <enum
6498 name="HostNetworkInterfaceStatus"
6499 uuid="CC474A69-2710-434B-8D99-C38E5D5A6F41"
6500 >
6501 <desc>
6502 Current status of the interface.
6503 <see>IHostNetworkInterface</see>
6504 </desc>
6505
6506 <const name="Unknown" value="0">
6507 <desc>
6508 The state of interface cannot be determined.
6509 </desc>
6510 </const>
6511 <const name="Up" value="1">
6512 <desc>
6513 The interface is fully operational.
6514 </desc>
6515 </const>
6516 <const name="Down" value="2">
6517 <desc>
6518 The interface is not functioning.
6519 </desc>
6520 </const>
6521 </enum>
6522
6523 <enum
6524 name="HostNetworkInterfaceType"
6525 uuid="67431b00-9946-48a2-bc02-b25c5919f4f3"
6526 >
6527 <desc>
6528 Network interface type.
6529 </desc>
6530 <const name="Bridged" value="1"/>
6531 <const name="HostOnly" value="2"/>
6532 </enum>
6533
6534 <interface
6535 name="IHostNetworkInterface" extends="$unknown"
6536 uuid="09de36e8-2588-4050-a791-655240b556e0"
6537 wsmap="managed"
6538 >
6539 <desc>
6540 Reprents one of host's network interfaces. IP V6 address and network
6541 mask are strings of 32 hexdecimal digits grouped by four. Groups are
6542 separated by colons.
6543 For example, fe80:0000:0000:0000:021e:c2ff:fed2:b030.
6544 </desc>
6545 <attribute name="name" type="wstring" readonly="yes">
6546 <desc>Returns the host network interface name.</desc>
6547 </attribute>
6548
6549 <attribute name="id" type="uuid" readonly="yes">
6550 <desc>Returns the interface UUID.</desc>
6551 </attribute>
6552
6553 <attribute name="dhcpEnabled" type="boolean" readonly="yes">
6554 <desc>Specifies whether the DHCP is enabled for the interface.</desc>
6555 </attribute>
6556
6557 <attribute name="IPAddress" type="wstring" readonly="yes">
6558 <desc>Returns the IP V4 address of the interface.</desc>
6559 </attribute>
6560
6561 <attribute name="networkMask" type="wstring" readonly="yes">
6562 <desc>Returns the network mask of the interface.</desc>
6563 </attribute>
6564
6565 <attribute name="IPV6Supported" type="boolean" readonly="yes">
6566 <desc>Specifies whether the IP V6 is supported/enabled for the interface.</desc>
6567 </attribute>
6568
6569 <attribute name="IPV6Address" type="wstring" readonly="yes">
6570 <desc>Returns the IP V6 address of the interface.</desc>
6571 </attribute>
6572
6573 <attribute name="IPV6NetworkMaskPrefixLength" type="unsigned long" readonly="yes">
6574 <desc>Returns the length IP V6 network mask prefix of the interface.</desc>
6575 </attribute>
6576
6577 <attribute name="hardwareAddress" type="wstring" readonly="yes">
6578 <desc>Returns the hardware address. For Ethernet it is MAC address.</desc>
6579 </attribute>
6580
6581 <attribute name="mediumType" type="HostNetworkInterfaceMediumType" readonly="yes">
6582 <desc>Type of protocol encapsulation used.</desc>
6583 </attribute>
6584
6585 <attribute name="status" type="HostNetworkInterfaceStatus" readonly="yes">
6586 <desc>Status of the interface.</desc>
6587 </attribute>
6588
6589 <attribute name="interfaceType" type="HostNetworkInterfaceType" readonly="yes">
6590 <desc>specifies the host interface type.</desc>
6591 </attribute>
6592
6593 <method name="enableStaticIpConfig">
6594 <desc>sets and enables the static IP V4 configuration for the given interface.</desc>
6595 <param name="IPAddress" type="wstring" dir="in">
6596 <desc>
6597 IP address.
6598 </desc>
6599 </param>
6600 <param name="networkMask" type="wstring" dir="in">
6601 <desc>
6602 network mask.
6603 </desc>
6604 </param>
6605 </method>
6606
6607 <method name="enableStaticIpConfigV6">
6608 <desc>sets and enables the static IP V6 configuration for the given interface.</desc>
6609 <param name="IPV6Address" type="wstring" dir="in">
6610 <desc>
6611 IP address.
6612 </desc>
6613 </param>
6614 <param name="IPV6NetworkMaskPrefixLength" type="unsigned long" dir="in">
6615 <desc>
6616 network mask.
6617 </desc>
6618 </param>
6619 </method>
6620
6621 <method name="enableDynamicIpConfig">
6622 <desc>enables the dynamic IP configuration.</desc>
6623 </method>
6624
6625 </interface>
6626
6627 <interface
6628 name="IHost" extends="$unknown"
6629 uuid="926469ca-9091-42ef-928e-582d78b66c70"
6630 wsmap="managed"
6631 >
6632 <desc>
6633 The IHost interface represents the physical machine that this VirtualBox
6634 installation runs on.
6635
6636 An object implementing this interface is returned by the
6637 <link to="IVirtualBox::host" /> attribute. This interface contains
6638 read-only information about the host's physical hardware (such as what
6639 processors and disks are available, what the host operating system is,
6640 and so on) and also allows for manipulating some of the host's hardware,
6641 such as global USB device filters and host interface networking.
6642
6643 </desc>
6644 <attribute name="DVDDrives" type="IHostDVDDrive" readonly="yes" safearray="yes">
6645 <desc>List of DVD drives available on the host.</desc>
6646 </attribute>
6647
6648 <attribute name="floppyDrives" type="IHostFloppyDrive" readonly="yes" safearray="yes">
6649 <desc>List of floppy drives available on the host.</desc>
6650 </attribute>
6651
6652 <attribute name="USBDevices" type="IHostUSBDevice" readonly="yes" safearray="yes">
6653 <desc>
6654 List of USB devices currently attached to the host.
6655 Once a new device is physically attached to the host computer,
6656 it appears in this list and remains there until detached.
6657
6658 <note>
6659 This method may set a @ref com_warnings "warning result code".
6660 </note>
6661 <note>
6662 If USB functionality is not available in the given edition of
6663 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6664 </note>
6665 </desc>
6666 </attribute>
6667
6668 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilter" readonly="yes" safearray="yes">
6669 <desc>
6670 List of USB device filters in action.
6671 When a new device is physically attached to the host computer,
6672 filters from this list are applied to it (in order they are stored
6673 in the list). The first matched filter will determine the
6674 <link to="IHostUSBDeviceFilter::action">action</link>
6675 performed on the device.
6676
6677 Unless the device is ignored by these filters, filters of all
6678 currently running virtual machines
6679 (<link to="IUSBController::deviceFilters"/>) are applied to it.
6680
6681 <note>
6682 This method may set a @ref com_warnings "warning result code".
6683 </note>
6684 <note>
6685 If USB functionality is not available in the given edition of
6686 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6687 </note>
6688
6689 <see>IHostUSBDeviceFilter, USBDeviceState</see>
6690 </desc>
6691 </attribute>
6692
6693 <attribute name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" readonly="yes">
6694 <desc>List of host network interfaces currently defined on the host.</desc>
6695 </attribute>
6696
6697 <attribute name="processorCount" type="unsigned long" readonly="yes">
6698 <desc>Number of (logical) CPUs installed in the host system.</desc>
6699 </attribute>
6700
6701 <attribute name="processorOnlineCount" type="unsigned long" readonly="yes">
6702 <desc>Number of (logical) CPUs online in the host system.</desc>
6703 </attribute>
6704
6705 <method name="getProcessorSpeed">
6706 <desc>Query the (approximate) maximum speed of a specified host CPU in
6707 Megahertz.
6708 </desc>
6709 <param name="cpuId" type="unsigned long" dir="in">
6710 <desc>
6711 Identifier of the CPU.
6712 </desc>
6713 </param>
6714 <param name="speed" type="unsigned long" dir="return">
6715 <desc>
6716 Speed value. 0 is returned if value is not known or @a cpuId is
6717 invalid.
6718 </desc>
6719 </param>
6720 </method>
6721
6722 <method name="getProcessorFeature">
6723 <desc>Query whether a CPU feature is supported or not.</desc>
6724 <param name="feature" type="ProcessorFeature" dir="in">
6725 <desc>
6726 CPU Feature identifier.
6727 </desc>
6728 </param>
6729 <param name="supported" type="boolean" dir="return">
6730 <desc>
6731 Feature is supported or not.
6732 </desc>
6733 </param>
6734 </method>
6735
6736 <method name="getProcessorDescription">
6737 <desc>Query the model string of a specified host CPU.
6738 <note>
6739 This function is not implemented in the current version of the
6740 product.
6741 </note>
6742 </desc>
6743 <param name="cpuId" type="unsigned long" dir="in">
6744 <desc>
6745 Identifier of the CPU.
6746 </desc>
6747 </param>
6748 <param name="description" type="wstring" dir="return">
6749 <desc>
6750 Model string. A NULL string is returned if value is not known or
6751 @a cpuId is invalid.
6752 </desc>
6753 </param>
6754 </method>
6755
6756 <attribute name="memorySize" type="unsigned long" readonly="yes">
6757 <desc>Amount of system memory in megabytes installed in the host system.</desc>
6758 </attribute>
6759
6760 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
6761 <desc>Available system memory in the host system.</desc>
6762 </attribute>
6763
6764 <attribute name="operatingSystem" type="wstring" readonly="yes">
6765 <desc>Name of the host system's operating system.</desc>
6766 </attribute>
6767
6768 <attribute name="OSVersion" type="wstring" readonly="yes">
6769 <desc>Host operating system's version string.</desc>
6770 </attribute>
6771
6772 <attribute name="UTCTime" type="long long" readonly="yes">
6773 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
6774 </attribute>
6775
6776<if target="midl">
6777 <method name="createHostOnlyNetworkInterface">
6778 <desc>
6779 Creates a new adapter for Host Only Networking.
6780 <result name="E_INVALIDARG">
6781 Host network interface @a name already exists.
6782 </result>
6783 </desc>
6784 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
6785 <desc>
6786 Created host interface object.
6787 </desc>
6788 </param>
6789 <param name="progress" type="IProgress" dir="return">
6790 <desc>
6791 Progress object to track the operation completion.
6792 </desc>
6793 </param>
6794 </method>
6795 <method name="removeHostOnlyNetworkInterface">
6796 <desc>
6797 Removes the given Host Only Networking interface.
6798 <result name="VBOX_E_OBJECT_NOT_FOUND">
6799 No host network interface matching @a id found.
6800 </result>
6801 </desc>
6802 <param name="id" type="uuid" dir="in">
6803 <desc>
6804 Adapter GUID.
6805 </desc>
6806 </param>
6807 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
6808 <desc>
6809 Removed host interface object.
6810 </desc>
6811 </param>
6812 <param name="progress" type="IProgress" dir="return">
6813 <desc>
6814 Progress object to track the operation completion.
6815 </desc>
6816 </param>
6817 </method>
6818</if>
6819
6820 <method name="createUSBDeviceFilter">
6821 <desc>
6822 Creates a new USB device filter. All attributes except
6823 the filter name are set to <tt>null</tt> (any match),
6824 <i>active</i> is <tt>false</tt> (the filter is not active).
6825
6826 The created filter can be added to the list of filters using
6827 <link to="#insertUSBDeviceFilter"/>.
6828
6829 <see>#USBDeviceFilters</see>
6830 </desc>
6831 <param name="name" type="wstring" dir="in">
6832 <desc>
6833 Filter name. See <link to="IHostUSBDeviceFilter::name"/>
6834 for more info.
6835 </desc>
6836 </param>
6837 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
6838 <desc>Created filter object.</desc>
6839 </param>
6840 </method>
6841
6842 <method name="insertUSBDeviceFilter">
6843 <desc>
6844 Inserts the given USB device to the specified position
6845 in the list of filters.
6846
6847 Positions are numbered starting from <tt>0</tt>. If the specified
6848 position is equal to or greater than the number of elements in
6849 the list, the filter is added at the end of the collection.
6850
6851 <note>
6852 Duplicates are not allowed, so an attempt to insert a
6853 filter that is already in the list, will return an
6854 error.
6855 </note>
6856 <note>
6857 This method may set a @ref com_warnings "warning result code".
6858 </note>
6859 <note>
6860 If USB functionality is not available in the given edition of
6861 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6862 </note>
6863
6864 <see>#USBDeviceFilters</see>
6865
6866 <result name="VBOX_E_INVALID_OBJECT_STATE">
6867 USB device filter is not created within this VirtualBox instance.
6868 </result>
6869 <result name="E_INVALIDARG">
6870 USB device filter already in list.
6871 </result>
6872
6873 </desc>
6874 <param name="position" type="unsigned long" dir="in">
6875 <desc>Position to insert the filter to.</desc>
6876 </param>
6877 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
6878 <desc>USB device filter to insert.</desc>
6879 </param>
6880 </method>
6881
6882 <method name="removeUSBDeviceFilter">
6883 <desc>
6884 Removes a USB device filter from the specified position in the
6885 list of filters.
6886
6887 Positions are numbered starting from <tt>0</tt>. Specifying a
6888 position equal to or greater than the number of elements in
6889 the list will produce an error.
6890
6891 <note>
6892 This method may set a @ref com_warnings "warning result code".
6893 </note>
6894 <note>
6895 If USB functionality is not available in the given edition of
6896 VirtualBox, this method will set the result code to @c E_NOTIMPL.
6897 </note>
6898
6899 <see>#USBDeviceFilters</see>
6900
6901 <result name="E_INVALIDARG">
6902 USB device filter list empty or invalid @a position.
6903 </result>
6904
6905 </desc>
6906 <param name="position" type="unsigned long" dir="in">
6907 <desc>Position to remove the filter from.</desc>
6908 </param>
6909 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
6910 <desc>Removed USB device filter.</desc>
6911 </param>
6912 </method>
6913
6914 <method name="findHostDVDDrive">
6915 <desc>
6916 Searches for a host DVD drive with the given @c name.
6917
6918 <result name="VBOX_E_OBJECT_NOT_FOUND">
6919 Given @c name does not correspond to any host drive.
6920 </result>
6921
6922 </desc>
6923 <param name="name" type="wstring" dir="in">
6924 <desc>Name of the host drive to search for</desc>
6925 </param>
6926 <param name="drive" type="IHostDVDDrive" dir="return">
6927 <desc>Found host drive object</desc>
6928 </param>
6929 </method>
6930
6931 <method name="findHostFloppyDrive">
6932 <desc>
6933 Searches for a host floppy drive with the given @c name.
6934
6935 <result name="VBOX_E_OBJECT_NOT_FOUND">
6936 Given @c name does not correspond to any host floppy drive.
6937 </result>
6938
6939 </desc>
6940 <param name="name" type="wstring" dir="in">
6941 <desc>Name of the host floppy drive to search for</desc>
6942 </param>
6943 <param name="drive" type="IHostFloppyDrive" dir="return">
6944 <desc>Found host floppy drive object</desc>
6945 </param>
6946 </method>
6947
6948 <method name="findHostNetworkInterfaceByName">
6949 <desc>
6950 Searches through all host network interfaces for an interface with
6951 the given @c name.
6952 <note>
6953 The method returns an error if the given @c name does not
6954 correspond to any host network interface.
6955 </note>
6956 </desc>
6957 <param name="name" type="wstring" dir="in">
6958 <desc>Name of the host network interface to search for.</desc>
6959 </param>
6960 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
6961 <desc>Found host network interface object.</desc>
6962 </param>
6963 </method>
6964 <method name="findHostNetworkInterfaceById">
6965 <desc>
6966 Searches through all host network interfaces for an interface with
6967 the given GUID.
6968 <note>
6969 The method returns an error if the given GUID does not
6970 correspond to any host network interface.
6971 </note>
6972 </desc>
6973 <param name="id" type="uuid" dir="in">
6974 <desc>GUID of the host network interface to search for.</desc>
6975 </param>
6976 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
6977 <desc>Found host network interface object.</desc>
6978 </param>
6979 </method>
6980 <method name="findHostNetworkInterfacesOfType">
6981 <desc>
6982 Searches through all host network interfaces and returns a list of interfaces of the specified type
6983 </desc>
6984 <param name="type" type="HostNetworkInterfaceType" dir="in">
6985 <desc>type of the host network interfaces to search for.</desc>
6986 </param>
6987 <param name="networkInterfaces" type="IHostNetworkInterface" safearray="yes" dir="return">
6988 <desc>Found host network interface objects.</desc>
6989 </param>
6990 </method>
6991
6992 <method name="findUSBDeviceById">
6993 <desc>
6994 Searches for a USB device with the given UUID.
6995
6996 <result name="VBOX_E_OBJECT_NOT_FOUND">
6997 Given @id does not correspond to any USB device.
6998 </result>
6999
7000 <see>IHostUSBDevice::id</see>
7001 </desc>
7002 <param name="id" type="uuid" dir="in">
7003 <desc>UUID of the USB device to search for.</desc>
7004 </param>
7005 <param name="device" type="IHostUSBDevice" dir="return">
7006 <desc>Found USB device object.</desc>
7007 </param>
7008 </method>
7009
7010 <method name="findUSBDeviceByAddress">
7011 <desc>
7012 Searches for a USB device with the given host address.
7013
7014 <result name="VBOX_E_OBJECT_NOT_FOUND">
7015 Given @c name does not correspond to any USB device.
7016 </result>
7017
7018 <see>IHostUSBDevice::address</see>
7019 </desc>
7020 <param name="name" type="wstring" dir="in">
7021 <desc>
7022 Address of the USB device (as assigned by the host) to
7023 search for.
7024 </desc>
7025 </param>
7026 <param name="device" type="IHostUSBDevice" dir="return">
7027 <desc>Found USB device object.</desc>
7028 </param>
7029 </method>
7030
7031 </interface>
7032
7033 <!--
7034 // ISystemProperties
7035 /////////////////////////////////////////////////////////////////////////
7036 -->
7037
7038 <interface
7039 name="ISystemProperties"
7040 extends="$unknown"
7041 uuid="0760e03f-06d0-481e-9f81-be43fef092ba"
7042 wsmap="managed"
7043 >
7044 <desc>
7045 The ISystemProperties interface represents global properties of the given
7046 VirtualBox installation.
7047
7048 These properties define limits and default values for various attributes
7049 and parameters. Most of the properties are read-only, but some can be
7050 changed by a user.
7051 </desc>
7052
7053 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
7054 <desc>Minimum guest system memory in Megabytes.</desc>
7055 </attribute>
7056
7057 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
7058 <desc>Maximum guest system memory in Megabytes.</desc>
7059 </attribute>
7060
7061 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
7062 <desc>Minimum guest video memory in Megabytes.</desc>
7063 </attribute>
7064
7065 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
7066 <desc>Maximum guest video memory in Megabytes.</desc>
7067 </attribute>
7068
7069 <attribute name="minGuestCPUCount" type="unsigned long" readonly="yes">
7070 <desc>Minimum CPU count.</desc>
7071 </attribute>
7072
7073 <attribute name="maxGuestCPUCount" type="unsigned long" readonly="yes">
7074 <desc>Maximum CPU count.</desc>
7075 </attribute>
7076
7077 <attribute name="maxVDISize" type="unsigned long long" readonly="yes">
7078 <desc>Maximum size of a virtual disk image in Megabytes.</desc>
7079 </attribute>
7080
7081 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
7082 <desc>
7083 Number of network adapters associated with every
7084 <link to="IMachine"/> instance.
7085 </desc>
7086 </attribute>
7087
7088 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
7089 <desc>
7090 Number of serial ports associated with every
7091 <link to="IMachine"/> instance.
7092 </desc>
7093 </attribute>
7094
7095 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
7096 <desc>
7097 Number of parallel ports associated with every
7098 <link to="IMachine"/> instance.
7099 </desc>
7100 </attribute>
7101
7102 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
7103 <desc>
7104 Maximum device position in the boot order. This value corresponds
7105 to the total number of devices a machine can boot from, to make it
7106 possible to include all possible devices to the boot list.
7107 <see><link to="IMachine::setBootOrder"/></see>
7108 </desc>
7109 </attribute>
7110
7111 <attribute name="defaultMachineFolder" type="wstring">
7112 <desc>
7113 Full path to the default directory used to create new or open
7114 existing machines when a settings file name contains no
7115 path.
7116
7117 The initial value of this property is
7118 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
7119 VirtualBox_home</link><tt>&gt;/Machines</tt>.
7120
7121 <note>
7122 Setting this property to <tt>null</tt> will restore the
7123 initial value.
7124 </note>
7125 <note>
7126 When settings this property, the specified path can be
7127 absolute (full path) or relative
7128 to the <link to="IVirtualBox::homeFolder">
7129 VirtualBox home directory</link>.
7130 When reading this property, a full path is
7131 always returned.
7132 </note>
7133 <note>
7134 The specified path may not exist, it will be created
7135 when necessary.
7136 </note>
7137
7138 <see>
7139 <link to="IVirtualBox::createMachine"/>,
7140 <link to="IVirtualBox::openMachine"/>
7141 </see>
7142 </desc>
7143 </attribute>
7144
7145 <attribute name="defaultHardDiskFolder" type="wstring">
7146 <desc>
7147 Full path to the default directory used to create new or open existing
7148 virtual disks.
7149
7150 This path is used when the storage unit of a hard disk is a regular file
7151 in the host's file system and only a file name that contains no path is
7152 given.
7153
7154 The initial value of this property is
7155 <tt>&lt;</tt>
7156 <link to="IVirtualBox::homeFolder">VirtualBox_home</link>
7157 <tt>&gt;/HardDisks</tt>.
7158
7159 <note>
7160 Setting this property to <tt>null</tt> will restore the
7161 initial value.
7162 </note>
7163 <note>
7164 When settings this property, the specified path can be relative
7165 to the
7166 <link to="IVirtualBox::homeFolder">VirtualBox home directory</link> or
7167 absolute. When reading this property, a full path is
7168 always returned.
7169 </note>
7170 <note>
7171 The specified path may not exist, it will be created
7172 when necessary.
7173 </note>
7174
7175 <see>
7176 IHardDisk,
7177 <link to="IVirtualBox::createHardDisk"/>,
7178 <link to="IVirtualBox::openHardDisk"/>,
7179 <link to="IMedium::location"/>
7180 </see>
7181 </desc>
7182 </attribute>
7183
7184 <attribute name="hardDiskFormats" type="IHardDiskFormat" safearray="yes" readonly="yes">
7185 <desc>
7186 List of all hard disk storage formats supported by this VirtualBox
7187 installation.
7188
7189 Keep in mind that the hard disk format identifier
7190 (<link to="IHardDiskFormat::id"/>) used in other API calls like
7191 <link to="IVirtualBox::createHardDisk"/> to refer to a particular
7192 hard disk format is a case-insensitive string. This means that, for
7193 example, all of the following strings:
7194 <pre>
7195 "VDI"
7196 "vdi"
7197 "VdI"</pre>
7198 refer to the same hard disk format.
7199
7200 Note that the virtual hard disk framework is backend-based, therefore
7201 the list of supported formats depends on what backends are currently
7202 installed.
7203
7204 <see>
7205 <link to="IHardDiskFormat"/>,
7206 </see>
7207 </desc>
7208 </attribute>
7209
7210 <attribute name="defaultHardDiskFormat" type="wstring">
7211 <desc>
7212 Identifier of the default hard disk format used by VirtualBox.
7213
7214 The hard disk format set by this attribute is used by VirtualBox
7215 when the hard disk format was not specified explicitly. One example is
7216 <link to="IVirtualBox::createHardDisk"/> with the <tt>null</tt>
7217 format argument. A more complex example is implicit creation of
7218 differencing hard disks when taking a snapshot of a virtual machine:
7219 this operation will try to use a format of the parent hard disk first
7220 and if this format does not support differencing hard disks the default
7221 format specified by this argument will be used.
7222
7223 The list of supported hard disk formats may be obtained by the
7224 <link to="#hardDiskFormats"/> call. Note that the default hard disk
7225 format must have a capability to create differencing hard disks;
7226 otherwise opeartions that create hard disks implicitly may fail
7227 unexpectedly.
7228
7229 The initial value of this property is <tt>VDI</tt> in the current
7230 version of the VirtualBox product, but may change in the future.
7231
7232 <note>
7233 Setting this property to <tt>null</tt> will restore the
7234 initial value.
7235 </note>
7236
7237 <see>
7238 <link to="#hardDiskFormats"/>,
7239 <link to="IHardDiskFormat::id"/>,
7240 <link to="IVirtualBox::createHardDisk"/>
7241 </see>
7242 </desc>
7243 </attribute>
7244
7245 <attribute name="remoteDisplayAuthLibrary" type="wstring">
7246 <desc>
7247 Library that provides authentication for VRDP clients. The library
7248 is used if a virtual machine's authentication type is set to "external"
7249 in the VM RemoteDisplay configuration.
7250
7251 The system library extension (".DLL" or ".so") must be omitted.
7252 A full path can be specified; if not, then the library must reside on the
7253 system's default library path.
7254
7255 The default value of this property is <tt>VRDPAuth</tt>. There is a library
7256 of that name in one of the default VirtualBox library directories.
7257
7258 For details about VirtualBox authentication libraries and how to implement
7259 them, please refer to the VirtualBox manual.
7260
7261 <note>
7262 Setting this property to <tt>null</tt> will restore the
7263 initial value.
7264 </note>
7265 </desc>
7266 </attribute>
7267
7268 <attribute name="webServiceAuthLibrary" type="wstring">
7269 <desc>
7270 Library that provides authentication for webservice clients. The library
7271 is used if a virtual machine's authentication type is set to "external"
7272 in the VM RemoteDisplay configuration and will be called from
7273 within the <link to="IWebsessionManager::logon" /> implementation.
7274
7275 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
7276 there is no per-VM setting for this, as the webservice is a global
7277 resource (if it is running). Only for this setting (for the webservice),
7278 setting this value to a literal "null" string disables authentication,
7279 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
7280 no matter what user name and password are supplied.
7281
7282 The initial value of this property is <tt>VRDPAuth</tt>,
7283 meaning that the webservice will use the same authentication
7284 library that is used by default for VBoxVRDP (again, see
7285 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
7286 The format and calling convention of authentication libraries
7287 is the same for the webservice as it is for VBoxVRDP.
7288
7289 </desc>
7290 </attribute>
7291
7292 <attribute name="HWVirtExEnabled" type="boolean">
7293 <desc>
7294 This specifies the default value for hardware virtualization
7295 extensions. If enabled, virtual machines will make use of
7296 hardware virtualization extensions such as Intel VT-x and
7297 AMD-V by default. This value can be overridden by each VM
7298 using their <link to="IMachine::HWVirtExEnabled" /> property.
7299 </desc>
7300 </attribute>
7301
7302 <attribute name="LogHistoryCount" type="unsigned long">
7303 <desc>
7304 This value specifies how many old release log files are kept.
7305 </desc>
7306 </attribute>
7307 </interface>
7308
7309 <!--
7310 // IGuest
7311 /////////////////////////////////////////////////////////////////////////
7312 -->
7313
7314 <interface
7315 name="IGuestOSType" extends="$unknown"
7316 uuid="cfe9e64c-4430-435b-9e7c-e3d8e417bd58"
7317 wsmap="struct"
7318 >
7319 <desc>
7320 </desc>
7321
7322 <attribute name="familyId" type="wstring" readonly="yes">
7323 <desc>Guest OS family identifier string.</desc>
7324 </attribute>
7325
7326 <attribute name="familyDescription" type="wstring" readonly="yes">
7327 <desc>Human readable description of the guest OS family.</desc>
7328 </attribute>
7329
7330 <attribute name="id" type="wstring" readonly="yes">
7331 <desc>Guest OS identifier string.</desc>
7332 </attribute>
7333
7334 <attribute name="description" type="wstring" readonly="yes">
7335 <desc>Human readable description of the guest OS.</desc>
7336 </attribute>
7337
7338 <attribute name="is64Bit" type="boolean" readonly="yes">
7339 <desc>Returns @c true if the given OS is 64-bit</desc>
7340 </attribute>
7341
7342 <attribute name="recommendedIOAPIC" type="boolean" readonly="yes">
7343 <desc>Returns @c true if IO APIC recommended for this OS type.</desc>
7344 </attribute>
7345
7346 <attribute name="recommendedVirtEx" type="boolean" readonly="yes">
7347 <desc>Returns @c true if VT-x or AMD-V recommended for this OS type.</desc>
7348 </attribute>
7349
7350 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
7351 <desc>Recommended RAM size in Megabytes.</desc>
7352 </attribute>
7353
7354 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
7355 <desc>Recommended video RAM size in Megabytes.</desc>
7356 </attribute>
7357
7358 <attribute name="recommendedHDD" type="unsigned long" readonly="yes">
7359 <desc>Recommended hard disk size in Megabytes.</desc>
7360 </attribute>
7361
7362 <attribute name="adapterType" type="NetworkAdapterType" readonly="yes">
7363 <desc>Returns recommended network adapter for this OS type.</desc>
7364 </attribute>
7365 </interface>
7366
7367 <interface
7368 name="IGuest" extends="$unknown"
7369 uuid="d8556fca-81bc-12af-fca3-365528fa38ca"
7370
7371 wsmap="suppress"
7372 >
7373 <desc>
7374 The IGuest interface represents information about the operating system
7375 running inside the virtual machine. Used in
7376 <link to="IConsole::guest"/>.
7377
7378 IGuest provides information about the guest operating system, whether
7379 Guest Additions are installed and other OS-specific virtual machine
7380 properties.
7381 </desc>
7382
7383 <attribute name="OSTypeId" type="wstring" readonly="yes">
7384 <desc>
7385 Identifier of the Guest OS type as reported by the Guest
7386 Additions.
7387 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
7388 an IGuestOSType object representing details about the given
7389 Guest OS type.
7390 <note>
7391 If Guest Additions are not installed, this value will be
7392 the same as <link to="IMachine::OSTypeId"/>.
7393 </note>
7394 </desc>
7395 </attribute>
7396
7397 <attribute name="additionsActive" type="boolean" readonly="yes">
7398 <desc>
7399 Flag whether the Guest Additions are installed and active
7400 in which case their version will be returned by the
7401 <link to="#additionsVersion"/> property.
7402 </desc>
7403 </attribute>
7404
7405 <attribute name="additionsVersion" type="wstring" readonly="yes">
7406 <desc>
7407 Version of the Guest Additions (3 decimal numbers separated
7408 by dots) or empty when the Additions are not installed. The
7409 Additions may also report a version but yet not be active as
7410 the version might be refused by VirtualBox (incompatible) or
7411 other failures occurred.
7412 </desc>
7413 </attribute>
7414
7415 <attribute name="supportsSeamless" type="boolean" readonly="yes">
7416 <desc>
7417 Flag whether seamless guest display rendering (seamless desktop
7418 integration) is supported.
7419 </desc>
7420 </attribute>
7421
7422 <attribute name="supportsGraphics" type="boolean" readonly="yes">
7423 <desc>
7424 Flag whether the guest is in graphics mode. If it is not, then
7425 seamless rendering will not work, resize hints are not immediately
7426 acted on and guest display resizes are probably not initiated by
7427 the guest additions.
7428 </desc>
7429 </attribute>
7430
7431 <attribute name="memoryBalloonSize" type="unsigned long">
7432 <desc>Guest system memory balloon size in megabytes.</desc>
7433 </attribute>
7434
7435 <attribute name="statisticsUpdateInterval" type="unsigned long">
7436 <desc>Interval to update guest statistics in seconds.</desc>
7437 </attribute>
7438
7439 <method name="setCredentials">
7440 <desc>
7441 Store login credentials that can be queried by guest operating
7442 systems with Additions installed. The credentials are transient
7443 to the session and the guest may also choose to erase them. Note
7444 that the caller cannot determine whether the guest operating system
7445 has queried or made use of the credentials.
7446
7447 <result name="VBOX_E_VM_ERROR">
7448 VMM device is not available.
7449 </result>
7450
7451 </desc>
7452 <param name="userName" type="wstring" dir="in">
7453 <desc>User name string, can be empty</desc>
7454 </param>
7455 <param name="password" type="wstring" dir="in">
7456 <desc>Password string, can be empty</desc>
7457 </param>
7458 <param name="domain" type="wstring" dir="in">
7459 <desc>Domain name (guest logon scheme specific), can be empty</desc>
7460 </param>
7461 <param name="allowInteractiveLogon" type="boolean" dir="in">
7462 <desc>
7463 Flag whether the guest should alternatively allow the user to
7464 interactively specify different credentials. This flag might
7465 not be supported by all versions of the Additions.
7466 </desc>
7467 </param>
7468 </method>
7469
7470 <method name="getStatistic">
7471 <desc>
7472 Query specified guest statistics as reported by the VirtualBox Additions.
7473 </desc>
7474 <param name="cpuId" type="unsigned long" dir="in">
7475 <desc>Virtual CPU id; not relevant for all statistic types</desc>
7476 </param>
7477 <param name="statistic" type="GuestStatisticType" dir="in">
7478 <desc>Statistic type.</desc>
7479 </param>
7480 <param name="statVal" type="unsigned long" dir="out">
7481 <desc>Statistics value</desc>
7482 </param>
7483 </method>
7484
7485 </interface>
7486
7487
7488 <!--
7489 // IProgress
7490 /////////////////////////////////////////////////////////////////////////
7491 -->
7492
7493 <interface
7494 name="IProgress" extends="$unknown"
7495 uuid="d3aa5417-6103-41fc-9e54-01ee1d08f42f"
7496 wsmap="managed"
7497 >
7498 <desc>
7499 The IProgress interface represents a task progress object that allows
7500 to wait for the completion of some asynchronous task.
7501
7502 The task consists of one or more operations that run sequentially,
7503 one by one. There is an individual percentage of completion of the
7504 current operation and the percentage of completion of the task as a
7505 whole. Similarly, you can wait for the completion of a particular
7506 operation or for the completion of the whole task.
7507
7508 Every operation is identified by a number (starting from 0)
7509 and has a separate description.
7510 </desc>
7511
7512 <attribute name="id" type="uuid" readonly="yes">
7513 <desc>ID of the task.</desc>
7514 </attribute>
7515
7516 <attribute name="description" type="wstring" readonly="yes">
7517 <desc>Description of the task.</desc>
7518 </attribute>
7519
7520 <attribute name="initiator" type="$unknown" readonly="yes">
7521 <desc>Initiator of the task.</desc>
7522 </attribute>
7523
7524 <attribute name="cancelable" type="boolean" readonly="yes">
7525 <desc>Whether the task can be interrupted.</desc>
7526 </attribute>
7527
7528 <attribute name="percent" type="long" readonly="yes">
7529 <desc>
7530 Current task progress value in percent.
7531 This value depends on how many operations are already complete.
7532 </desc>
7533 </attribute>
7534
7535 <attribute name="completed" type="boolean" readonly="yes">
7536 <desc>Whether the task has been completed.</desc>
7537 </attribute>
7538
7539 <attribute name="canceled" type="boolean" readonly="yes">
7540 <desc>Whether the task has been canceled.</desc>
7541 </attribute>
7542
7543 <attribute name="resultCode" type="result" readonly="yes">
7544 <desc>
7545 Result code of the progress task.
7546 Valid only if <link to="#completed"/> is true.
7547 </desc>
7548 </attribute>
7549
7550 <attribute name="errorInfo" type="IVirtualBoxErrorInfo" readonly="yes">
7551 <desc>
7552 Extended information about the unsuccessful result of the
7553 progress operation. May be NULL when no extended information
7554 is available.
7555 Valid only if <link to="#completed"/> is true and
7556 <link to="#resultCode"/> indicates a failure.
7557 </desc>
7558 </attribute>
7559
7560 <attribute name="operationCount" type="unsigned long" readonly="yes">
7561 <desc>
7562 Number of operations this task is divided into.
7563 Every task consists of at least one operation.
7564 </desc>
7565 </attribute>
7566
7567 <attribute name="operation" type="unsigned long" readonly="yes">
7568 <desc>Number of the operation being currently executed.</desc>
7569 </attribute>
7570
7571 <attribute name="operationDescription" type="wstring" readonly="yes">
7572 <desc>
7573 Description of the operation being currently executed.
7574 </desc>
7575 </attribute>
7576
7577 <attribute name="operationPercent" type="long" readonly="yes">
7578 <desc>Current operation progress value in percent.</desc>
7579 </attribute>
7580
7581 <method name="waitForCompletion">
7582 <desc>
7583 Waits until the task is done (including all operations) with a
7584 given timeout.
7585
7586 <result name="VBOX_E_IPRT_ERROR">
7587 Failed to wait for task completion.
7588 </result>
7589
7590 </desc>
7591 <param name="timeout" type="long" dir="in">
7592 <desc>
7593 Timeout value in milliseconds.
7594 Specify -1 for an indefinite wait.
7595 </desc>
7596 </param>
7597 </method>
7598
7599 <method name="waitForOperationCompletion">
7600 <desc>
7601 Waits until the given operation is done with a given timeout.
7602
7603 <result name="VBOX_E_IPRT_ERROR">
7604 Failed to wait for operation completion.
7605 </result>
7606
7607 </desc>
7608 <param name="operation" type="unsigned long" dir="in">
7609 <desc>
7610 Number of the operation to wait for.
7611 Must be less than <link to="#operationCount"/>.
7612 </desc>
7613 </param>
7614 <param name="timeout" type="long" dir="in">
7615 <desc>
7616 Timeout value in milliseconds.
7617 Specify -1 for an indefinite wait.
7618 </desc>
7619 </param>
7620 </method>
7621
7622 <method name="cancel">
7623 <desc>
7624 Cancels the task.
7625 <note>
7626 If <link to="#cancelable"/> is <tt>false</tt>, then
7627 this method will fail.
7628 </note>
7629
7630 <result name="VBOX_E_INVALID_OBJECT_STATE">
7631 Operation cannot be canceled.
7632 </result>
7633
7634 </desc>
7635 </method>
7636
7637 </interface>
7638
7639
7640 <!--
7641 // ISnapshot
7642 /////////////////////////////////////////////////////////////////////////
7643 -->
7644
7645 <interface
7646 name="ISnapshot" extends="$unknown"
7647 uuid="5db6b1d9-c76b-4424-a6f4-8257f642d6ea"
7648 wsmap="managed"
7649 >
7650 <desc>
7651 The ISnapshot interface represents a snapshot of the virtual
7652 machine.
7653
7654 The <i>snapshot</i> stores all the information about a virtual
7655 machine necessary to bring it to exactly the same state as it was at
7656 the time of taking the snapshot. The snapshot includes:
7657
7658 <ul>
7659 <li>all settings of the virtual machine (i.e. its hardware
7660 configuration: RAM size, attached hard disks, etc.)
7661 </li>
7662 <li>the execution state of the virtual machine (memory contents,
7663 CPU state, etc.).
7664 </li>
7665 </ul>
7666
7667 Snapshots can be <i>offline</i> (taken when the VM is powered off)
7668 or <i>online</i> (taken when the VM is running). The execution
7669 state of the offline snapshot is called a <i>zero execution state</i>
7670 (it doesn't actually contain any information about memory contents
7671 or the CPU state, assuming that all hardware is just powered off).
7672
7673 <h3>Snapshot branches</h3>
7674
7675 Snapshots can be chained. Chained snapshots form a branch where
7676 every next snapshot is based on the previous one. This chaining is
7677 mostly related to hard disk branching (see <link to="IHardDisk"/>
7678 description). This means that every time a new snapshot is created,
7679 a new differencing hard disk is implicitly created for all normal
7680 hard disks attached to the given virtual machine. This allows to
7681 fully restore hard disk contents when the machine is later reverted
7682 to a particular snapshot.
7683
7684 In the current implementation, multiple snapshot branches within one
7685 virtual machine are not allowed. Every machine has a single branch,
7686 and <link to="IConsole::takeSnapshot"/> operation adds a new
7687 snapshot to the top of that branch.
7688
7689 Existing snapshots can be discarded using
7690 <link to="IConsole::discardSnapshot"/>.
7691
7692 <h3>Current snapshot</h3>
7693
7694 Every virtual machine has a current snapshot, identified by
7695 <link to="IMachine::currentSnapshot"/>. This snapshot is used as
7696 a base for the <i>current machine state</i> (see below), to the effect
7697 that all normal hard disks of the machine and its execution
7698 state are based on this snapshot.
7699
7700 In the current implementation, the current snapshot is always the
7701 last taken snapshot (i.e. the head snapshot on the branch) and it
7702 cannot be changed.
7703
7704 The current snapshot is <tt>null</tt> if the machine doesn't have
7705 snapshots at all; in this case the current machine state is just
7706 current settings of this machine plus its current execution state.
7707
7708 <h3>Current machine state</h3>
7709
7710 The current machine state is what represented by IMachine instances got
7711 directly from IVirtualBox
7712 using <link
7713 to="IVirtualBox::getMachine">getMachine()</link>, <link
7714 to="IVirtualBox::findMachine">findMachine()</link>, etc. (as opposed
7715 to instances returned by <link to="ISnapshot::machine"/>). This state
7716 is always used when the machine is <link to="IConsole::powerUp"> powered
7717 on</link>.
7718
7719 The current machine state also includes the current execution state.
7720 If the machine is being currently executed
7721 (<link to="IMachine::state"/> is <link to="MachineState_Running"/>
7722 and above), its execution state is just what's happening now.
7723 If it is powered off (<link to="MachineState_PoweredOff"/> or
7724 <link to="MachineState_Aborted"/>), it has a zero execution state.
7725 If the machine is saved (<link to="MachineState_Saved"/>), its
7726 execution state is what saved in the execution state file
7727 (<link to="IMachine::stateFilePath"/>).
7728
7729 If the machine is in the saved state, then, next time it is powered
7730 on, its execution state will be fully restored from the saved state
7731 file and the execution will continue from the point where the state
7732 was saved.
7733
7734 Similarly to snapshots, the current machine state can be discarded
7735 using <link to="IConsole::discardCurrentState"/>.
7736
7737 <h3>Taking and discarding snapshots</h3>
7738
7739 The table below briefly explains the meaning of every snapshot
7740 operation:
7741
7742 <table>
7743 <tr><th>Operation</th><th>Meaning</th><th>Remarks</th></tr>
7744
7745 <tr><td><link to="IConsole::takeSnapshot"/></td>
7746
7747 <td>Save the current state of the virtual machine, including all
7748 settings, contents of normal hard disks and the current modifications
7749 to immutable hard disks (for online snapshots)</td>
7750
7751 <td>The current state is not changed (the machine will continue
7752 execution if it is being executed when the snapshot is
7753 taken)</td></tr>
7754
7755 <tr><td><link to="IConsole::discardSnapshot"/></td>
7756
7757 <td>Forget the state of the virtual machine stored in the snapshot:
7758 dismiss all saved settings and delete the saved execution state (for
7759 online snapshots)</td>
7760
7761 <td>Other snapshots (including child snapshots, if any) and the
7762 current state are not directly affected</td></tr>
7763
7764 <tr><td><link to="IConsole::discardCurrentState"/></td>
7765
7766 <td>Restore the current state of the virtual machine from the state
7767 stored in the current snapshot, including all settings and hard disk
7768 contents</td>
7769
7770 <td>The current state of the machine existed prior to this operation
7771 is lost</td></tr>
7772
7773 <tr><td><link to="IConsole::discardCurrentSnapshotAndState"/></td>
7774
7775 <td>Completely revert the virtual machine to the state it was in
7776 before the current snapshot has been taken</td>
7777
7778 <td>The current state, as well as the current snapshot, are
7779 lost</td></tr>
7780
7781 </table>
7782
7783 </desc>
7784
7785 <attribute name="id" type="uuid" readonly="yes">
7786 <desc>UUID of the snapshot.</desc>
7787 </attribute>
7788
7789 <attribute name="name" type="wstring">
7790 <desc>Short name of the snapshot.</desc>
7791 </attribute>
7792
7793 <attribute name="description" type="wstring">
7794 <desc>Optional description of the snapshot.</desc>
7795 </attribute>
7796
7797 <attribute name="timeStamp" type="long long" readonly="yes">
7798 <desc>
7799 Time stamp of the snapshot, in milliseconds since 1970-01-01 UTC.
7800 </desc>
7801 </attribute>
7802
7803 <attribute name="online" type="boolean" readonly="yes">
7804 <desc>
7805 <tt>true</tt> if this snapshot is an online snapshot and
7806 <tt>false</tt> otherwise.
7807
7808 <note>
7809 When this attribute is <tt>true</tt>, the
7810 <link to="IMachine::stateFilePath"/> attribute of the
7811 <link to="#machine"/> object associated with this snapshot
7812 will point to the saved state file. Otherwise, it will be
7813 <tt>null</tt>.
7814 </note>
7815 </desc>
7816 </attribute>
7817
7818 <attribute name="machine" type="IMachine" readonly="yes">
7819 <desc>
7820 Virtual machine this snapshot is taken on. This object
7821 stores all settings the machine had when taking this snapshot.
7822 <note>
7823 The returned machine object is immutable, i.e. no
7824 any settings can be changed.
7825 </note>
7826 </desc>
7827 </attribute>
7828
7829 <attribute name="parent" type="ISnapshot" readonly="yes">
7830 <desc>
7831 Parent snapshot (a snapshot this one is based on).
7832 <note>
7833 It's not an error to read this attribute on a snapshot
7834 that doesn't have a parent -- a null object will be
7835 returned to indicate this.
7836 </note>
7837 </desc>
7838 </attribute>
7839
7840 <attribute name="children" type="ISnapshot" readonly="yes" safearray="yes">
7841 <desc>
7842 Child snapshots (all snapshots having this one as a parent).
7843 <note>
7844 In the current implementation, there can be only one
7845 child snapshot, or no children at all, meaning this is the
7846 last (head) snapshot.
7847 </note>
7848 </desc>
7849 </attribute>
7850
7851 </interface>
7852
7853
7854 <!--
7855 // IMedia
7856 /////////////////////////////////////////////////////////////////////////
7857 -->
7858
7859 <enum
7860 name="MediaState"
7861 uuid="8b86e03c-2f1c-412a-8fbd-326f62701200"
7862 >
7863 <desc>
7864 Virtual media state.
7865 <see>IMedia</see>
7866 </desc>
7867
7868 <const name="NotCreated" value="0">
7869 <desc>
7870 Associated media storage does not exist (either was not created yet or
7871 was deleted).
7872 </desc>
7873 </const>
7874 <const name="Created" value="1">
7875 <desc>
7876 Associated storage exists and accessible.
7877 </desc>
7878 </const>
7879 <const name="LockedRead" value="2">
7880 <desc>
7881 Media is locked for reading, no data modification is possible.
7882 </desc>
7883 </const>
7884 <const name="LockedWrite" value="3">
7885 <desc>
7886 Media is locked for writing, no concurrent data reading or modification
7887 is possible.
7888 </desc>
7889 </const>
7890 <const name="Inaccessible" value="4">
7891 <desc>
7892 Associated media storage is not accessible.
7893 </desc>
7894 </const>
7895 <const name="Creating" value="5">
7896 <desc>
7897 Associated media storage is being created.
7898 </desc>
7899 </const>
7900 <const name="Deleting" value="6">
7901 <desc>
7902 Associated media storage is being deleted.
7903 </desc>
7904 </const>
7905 </enum>
7906
7907 <interface
7908 name="IMedium" extends="$unknown"
7909 uuid="a7fb3bfb-c180-4274-bae4-7fbc89046e13"
7910 wsmap="managed"
7911 >
7912 <desc>
7913 The IMedium interface is a common interface for all objects representing
7914 virtual media such as hard disks, DVD images.
7915
7916 Each medium is associated with a storage unit (such as a file on the host
7917 computer or a network resource) that holds actual data. The location of
7918 the storage unit is represented by the #location attribute. The value of
7919 this attribute is media type dependent.
7920
7921 The exact media type may be determined by querying the appropriate
7922 interface such as:
7923 <ul>
7924 <li>IHardDisk (virtual hard disks)</li>
7925 <li>IDVDImage (standard CD/DVD ISO image files)</li>
7926 <li>IFloppyImage (raw floppy image files)</li>
7927 </ul>
7928
7929 Existing media are opened using the following methods, depending on the
7930 media type:
7931 <ul>
7932 <li><link to="IVirtualBox::openHardDisk"/></li>
7933 <li><link to="IVirtualBox::openDVDImage"/></li>
7934 <li><link to="IVirtualBox::openFloppyImage"/></li>
7935 </ul>
7936
7937 New hard disk media are created using the
7938 <link to="IVirtualBox::createHardDisk"/> method. CD/DVD and floppy
7939 images are created outside VirtualBox, usually by storing a copy
7940 of the real medium of the corresponding type in a regular file.
7941
7942 <h3>Known Media</h3>
7943
7944 When an existing medium gets opened for the first time, it gets
7945 automatically remembered by the given VirtualBox installation or, in other
7946 words, becomes a <i>known medium</i>. Known media are stored in the media
7947 registry transparently maintained by VirtualBox and stored in settings
7948 files so that this registry is preserved when VirtualBox is not running.
7949
7950 Newly created virtual hard disks get remembered only when the associated
7951 storage unit is actually created (see IHardDisk for more details).
7952
7953 All known media can be enumerated using
7954 <link to="IVirtualBox::hardDisks"/>,
7955 <link to="IVirtualBox::DVDImages"/> and
7956 <link to="IVirtualBox::floppyImages"/> attributes. Individual media can be
7957 quickly found by UUID using <link to="IVirtualBox::getHardDisk"/>
7958 and similar methods or by location using
7959 <link to="IVirtualBox::findHardDisk"/> and similar methods.
7960
7961 Only known media can be attached to virtual machines.
7962
7963 Removing known media from the media registry is performed when the given
7964 medium is closed using the <link to="#close"/> method or when its
7965 associated storage unit is deleted (only for hard disks).
7966
7967 <h3>Accessibility Checks</h3>
7968
7969 The given medium (with the created storage unit) is considered to be
7970 <i>accessible</i> when its storage unit can be successfully read from.
7971 Accessible media are indicated by the <link to="MediaState_Created"/>
7972 value of the <link to="#state"/> attribute. When the storage unit cannot
7973 be read (for example, because it is located on a disconnected network
7974 resource, or was accidentally deleted outside VirtualBox), the medium is
7975 considered to be <i>inaccessible</i> which is indicated by the
7976 <link to="MediaState_Inaccessible"/> state. The details about the reason
7977 of being inaccessible can be obtained using the
7978 <link to="#lastAccessError"/> attribute.
7979
7980 A new accessibility check is performed each time the <link to="#state"/>
7981 attribute is read. Please note that this check may take long time (several
7982 seconds or even minutes, depending on the storage unit location and
7983 format), and will block the calling thread until finished. For this
7984 reason, it is recommended to never read this attribute on the main UI
7985 thread to avoid making the UI unresponsive.
7986
7987 Note that when VirtualBox starts up (e.g. the VirtualBox object gets
7988 created for the first time), all known media are in the
7989 <link to="MediaState_Inaccessible"/> state but the value of the <link
7990 to="#lastAccessError"/> attribute is <tt>null</tt> because no actual
7991 accessibility check is made on startup. This is done to make the
7992 VirtualBox object ready for serving requests as
7993 fast as possible and let the end-user application decide if it needs to
7994 check media accessibility right away or not.
7995 </desc>
7996
7997 <attribute name="id" type="uuid" readonly="yes">
7998 <desc>
7999 UUID of the medium. For a newly created medium, this value is a randomly
8000 generated UUID.
8001
8002 <note>
8003 For media in one of MediaState_NotCreated, MediaState_Creating or
8004 MediaState_Deleting states, the value of this property is undefined
8005 and will most likely be an empty UUID.
8006 </note>
8007 </desc>
8008 </attribute>
8009
8010 <attribute name="description" type="wstring">
8011 <desc>
8012 Optional description of the medium. For newly created media, the value
8013 of this attribute value is <tt>null</tt>.
8014
8015 Media types that don't support this attribute will return E_NOTIMPL in
8016 attempt to get or set this attribute's value.
8017
8018 <note>
8019 For some storage types, reading this attribute may return an outdated
8020 (last known) value when <link to="#state"/> is <link
8021 to="MediaState_Inaccessible"/> or <link
8022 to="MediaState_LockedWrite"/> because the value of this attribute is
8023 stored within the storage unit itself. Also note that changing the
8024 attribute value is not possible in such case, as well as when the
8025 medium is the <link to="MediaState_LockedRead"/> state.
8026 </note>
8027 </desc>
8028 </attribute>
8029
8030 <attribute name="state" type="MediaState" readonly="yes">
8031 <desc>
8032 Current media state. Inspect <link to="MediaState"/> values for details.
8033
8034 Reading this attribute may take long time because a new accessibility
8035 check of the storage unit is performed every time the attribute is read.
8036 This check may cause a significant delay if the storage unit of the
8037 given medium is, for example, a file located on a network share which is
8038 not currently accessible due to connectivity problems -- the call will
8039 not return until a timeout interval defined by the host OS for this
8040 operation expires.
8041
8042 If the last known state of the medium is <link to="MediaState_Created"/>
8043 and the accessibility check fails then the state would be set to
8044 <link to="MediaState_Inaccessible"/> and <link to="#lastAccessError"/>
8045 may be used to get more details about the failure. If the state of the
8046 medium is <link to="MediaState_LockedRead"/> or
8047 <link to="MediaState_LockedWrite"/> then it remains the same, and a
8048 non-null value of <link to="#lastAccessError"/> will indicate a failed
8049 accessibility check in this case.
8050
8051 Note that not all media states are applicable to certain media types.
8052 For example, states <link to="MediaState_NotCreated"/>,
8053 <link to="MediaState_LockedWrite"/>, <link to="MediaState_Creating"/>,
8054 <link to="MediaState_Deleting"/> are meaningless for IDVDImage and
8055 IFloppyImage media.
8056 </desc>
8057 </attribute>
8058
8059 <attribute name="location" type="wstring">
8060 <desc>
8061 Location of the storage unit holding media data.
8062
8063 The format of the location string is media type specific. For media
8064 types that use regular files in a host's file system, the location
8065 string is just a full file name.
8066
8067 Some media types may support changing the storage unit location by
8068 simply changing the value of this property. If this operation is not
8069 supported, the implementation will return E_NOTIMPL in attempt to set
8070 this attribute's value.
8071
8072 When setting a value of the location attribute which is a regular file
8073 in the host's file system, the given file name may be either relative to
8074 the <link to="IVirtualBox::homeFolder">VirtualBox home folder</link> or
8075 absolute. Note that if the given location specification does not contain
8076 the file extension part then a proper default extension will be
8077 automatically appended by the implementation depending on the media type.
8078 </desc>
8079 </attribute>
8080
8081 <attribute name="name" type="wstring" readonly="yes">
8082 <desc>
8083 Name of the storage unit holding media data.
8084
8085 The returned string is a short version of the <link to="#location"/>
8086 attribute that is suitable for representing the medium in situations
8087 where the full location specification is too long (such as lists
8088 and comboboxes in GUI frontends). This string is also used by frontends
8089 to sort the media list alphabetically when needed.
8090
8091 For example, for locations that are regular files in the host's file
8092 system, the value of this attribute is just a file name (+ extension),
8093 without the path specification.
8094
8095 Note that as opposed to the <link to="#location"/> attribute, the name
8096 attribute will not necessary be unique for a list of media of the
8097 given type and format.
8098 </desc>
8099 </attribute>
8100
8101 <attribute name="size" type="unsigned long long" readonly="yes">
8102 <desc>
8103 Physical size of the storage unit used to hold media data (in bytes).
8104
8105 <note>
8106 For media whose <link to="#state"/> is <link
8107 to="MediaState_Inaccessible"/>, the value of this property is the
8108 last known size. For <link to="MediaState_NotCreated"/> media,
8109 the returned value is zero.
8110 </note>
8111 </desc>
8112 </attribute>
8113
8114 <attribute name="lastAccessError" type="wstring" readonly="yes">
8115 <desc>
8116 Text message that represents the result of the last accessibility
8117 check.
8118
8119 Accessibility checks are performed each time the <link to="#state"/>
8120 attribute is read. A @c null string is returned if the last
8121 accessibility check was successful. A non-null string indicates a
8122 failure and should normally describe a reason of the failure (for
8123 example, a file read error).
8124 </desc>
8125 </attribute>
8126
8127 <attribute name="machineIds" type="uuid" safearray="yes" readonly="yes">
8128 <desc>
8129 Array of UUIDs of all machines this medium is attached to.
8130
8131 A <tt>null</tt> array is returned if this medium is not attached to any
8132 machine or to any machine's snapshot.
8133
8134 <note>
8135 The returned array will include a machine even if this medium is not
8136 attached to that machine in the current state but attached to it in
8137 one of the machine's snapshots. See <link to="#getSnapshotIds"/> for
8138 details.
8139 </note>
8140 </desc>
8141 </attribute>
8142
8143 <method name="getSnapshotIds">
8144 <desc>
8145 Returns an array of UUIDs of all snapshots of the given machine where
8146 this medium is attached to it.
8147
8148 If the medium is attached to the machine in the current state, then the
8149 first element in the array will always be the ID of the queried machine
8150 (i.e. the value equal to the @c machineId argument), followed by
8151 snapshot IDs (if any).
8152
8153 If the medium is not attached to the machine in the current state, then
8154 the array will contain only snapshot IDs.
8155
8156 The returned array may be <tt>null</tt> if this medium is not attached
8157 to the given machine at all, neither in the current state nor in one of
8158 snapshots.
8159 </desc>
8160 <param name="machineId" type="uuid" dir="in">
8161 <desc>
8162 UUID of the machine to query.
8163 </desc>
8164 </param>
8165 <param name="snapshotIds" type="uuid" safearray="yes" dir="return">
8166 <desc>
8167 Array of snapshot UUIDs of the given machine using this medium.
8168 </desc>
8169 </param>
8170 </method>
8171
8172 <method name="lockRead">
8173 <desc>
8174 Locks this medium for reading.
8175
8176 The read lock is shared: many clients can simultaneously lock the
8177 same media for reading unless it is already locked for writing (see
8178 <link to="#lockWrite"/>) in which case an error is returned.
8179
8180 When the medium is locked for reading, it cannot be modified
8181 from within VirtualBox. This means that any method that changes
8182 the properties of this medium or contents of the storage unit
8183 will return an error (unless explicitly stated otherwise) and
8184 that an attempt to start a virtual machine that wants to modify
8185 the medium will also fail.
8186
8187 When the virtual machine is started up, it locks for reading all
8188 media it uses in read-only mode. If some media cannot be locked
8189 for reading, the startup procedure will fail.
8190
8191 The medium locked for reading must be unlocked using the <link
8192 to="#unlockRead"/> method. Calls to <link to="#lockRead"/>
8193 can be nested and must be followed by the same number of paired
8194 <link to="#unlockRead"/> calls.
8195
8196 This method sets the media state to <link
8197 to="MediaState_LockedRead"/> on success. The state prior to
8198 this call must be <link to="MediaState_Created"/>, <link
8199 to="MediaState_Inaccessible"/> or <link
8200 to="MediaState_LockedRead"/>. As you can see, inaccessible
8201 media can be locked too. This is not an error; this method
8202 performs a logical lock that prevents modifications of this
8203 media through the VirtualBox API, not a physical lock of the
8204 underlying storage unit.
8205
8206 This method returns the current state of the medium
8207 <b>before</b> the operation.
8208
8209 <result name="VBOX_E_INVALID_OBJECT_STATE">
8210 Invalid media state (e.g. not created, locked, inaccessible,
8211 creating, deleting).
8212 </result>
8213
8214 </desc>
8215 <param name="state" type="MediaState" dir="return">
8216 <desc>
8217 State of the medium after the operation.
8218 </desc>
8219 </param>
8220 </method>
8221
8222 <method name="unlockRead">
8223 <desc>
8224 Cancels the read lock previously set by <link to="#lockRead"/>.
8225
8226 Either on success or on failure, this method returns the current state
8227 of the medium <b>after</b> the operation.
8228
8229 See <link to="#lockRead"/> for more details.
8230
8231 <result name="VBOX_E_INVALID_OBJECT_STATE">
8232 Medium not locked for reading.
8233 </result>
8234
8235 </desc>
8236 <param name="state" type="MediaState" dir="return">
8237 <desc>
8238 State of the medium after the operation.
8239 </desc>
8240 </param>
8241 </method>
8242
8243 <method name="lockWrite">
8244 <desc>
8245 Locks this medium for writing.
8246
8247 The write lock, as opposed to <link to="#lockRead"/>, is
8248 exclusive: there may be only one client that holds a write lock
8249 and there may be no read locks while the write lock is held.
8250
8251 When the medium is locked for writing, it cannot be modified
8252 from within VirtualBox and it is not guaranteed that the values
8253 of its properties are up-to-date. Any method that changes the
8254 properties of this medium or contents of the storage unit will
8255 return an error ((unless explicitly stated otherwise) and an
8256 attempt to start a virtual machine that wants to modify or to
8257 read the medium will also fail.
8258
8259 When the virtual machine is started up, it locks for writing all
8260 media it uses to write data to. If some media cannot be locked
8261 for writing, the startup procedure will fail.
8262
8263 The medium locked for writing must be unlocked using the <link
8264 to="#unlockWrite"/> method. Calls to <link to="#lockWrite"/>
8265 can <b>not</b> be nested and must be followed by a paired <link
8266 to="#unlockWrite"/> call.
8267
8268 This method sets the media state to <link
8269 to="MediaState_LockedWrite"/> on success. The state prior to
8270 this call must be <link to="MediaState_Created"/> or <link
8271 to="MediaState_Inaccessible"/>. As you can see, inaccessible
8272 media can be locked too. This is not an error; this method
8273 performs a logical lock that prevents modifications of this
8274 media through the VirtualBox API, not a physical lock of the
8275 underlying storage unit.
8276
8277 Either on success or on failure, this method returns the current
8278 state of the medium <b>before</b> the operation.
8279
8280 <result name="VBOX_E_INVALID_OBJECT_STATE">
8281 Invalid media state (e.g. not created, locked, inaccessible,
8282 creating, deleting).
8283 </result>
8284
8285 </desc>
8286 <param name="state" type="MediaState" dir="return">
8287 <desc>
8288 State of the medium after the operation.
8289 </desc>
8290 </param>
8291 </method>
8292
8293 <method name="unlockWrite">
8294 <desc>
8295 Cancels the write lock previously set by <link to="#lockWrite"/>.
8296
8297 Either on success or on failure, this method returns the current
8298 state of the medium <b>after</b> the operation.
8299
8300 See <link to="#lockWrite"/> for more details.
8301
8302 <result name="VBOX_E_INVALID_OBJECT_STATE">
8303 Medium not locked for writing.
8304 </result>
8305
8306 </desc>
8307 <param name="state" type="MediaState" dir="return">
8308 <desc>
8309 State of the medium after the operation.
8310 </desc>
8311 </param>
8312 </method>
8313
8314 <method name="close">
8315 <desc>
8316 Closes this medium.
8317
8318 The hard disk must not be attached to any known virtual machine
8319 and must not have any known child hard disks, otherwise the
8320 operation will fail.
8321
8322 When the hard disk is successfully closed, it gets removed from
8323 the list of remembered hard disks, but its storage unit is not
8324 deleted. In particular, this means that this hard disk can be
8325 later opened again using the <link
8326 to="IVirtualBox::openHardDisk"/> call.
8327
8328 Note that after this method successfully returns, the given hard
8329 disk object becomes uninitialized. This means that any attempt
8330 to call any of its methods or attributes will fail with the
8331 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error.
8332
8333 <result name="VBOX_E_INVALID_OBJECT_STATE">
8334 Invalid media state (other than not created, created or
8335 inaccessible).
8336 </result>
8337 <result name="VBOX_E_OBJECT_IN_USE">
8338 Medium attached to virtual machine.
8339 </result>
8340 <result name="VBOX_E_FILE_ERROR">
8341 Settings file not accessible.
8342 </result>
8343 <result name="VBOX_E_XML_ERROR">
8344 Could not parse the settings file.
8345 </result>
8346
8347 </desc>
8348 </method>
8349
8350 </interface>
8351
8352
8353 <!--
8354 // IHardDisk
8355 /////////////////////////////////////////////////////////////////////////
8356 -->
8357
8358 <enum
8359 name="HardDiskType"
8360 uuid="a348fafd-a64e-4643-ba65-eb3896bd7e0a"
8361 >
8362 <desc>
8363 Virtual hard disk type.
8364 <see>IHardDisk</see>
8365 </desc>
8366
8367 <const name="Normal" value="0">
8368 <desc>
8369 Normal hard disk (attached directly or indirectly, preserved
8370 when taking snapshots).
8371 </desc>
8372 </const>
8373 <const name="Immutable" value="1">
8374 <desc>
8375 Immutable hard disk (attached indirectly, changes are wiped out
8376 after powering off the virtual machine).
8377 </desc>
8378 </const>
8379 <const name="Writethrough" value="2">
8380 <desc>
8381 Write through hard disk (attached directly, ignored when
8382 taking snapshots).
8383 </desc>
8384 </const>
8385 </enum>
8386
8387 <interface
8388 name="IHardDiskAttachment" extends="$unknown"
8389 uuid="b1dd04bb-93c0-4ad3-a9cf-82316e595836"
8390 wsmap="struct"
8391 >
8392 <desc>
8393 The IHardDiskAttachment interface represents a hard disk attachment of a
8394 virtual machine.
8395
8396 Every hard disk attachment specifies a slot of the virtual hard disk
8397 controller and a virtual hard disk attached to this slot.
8398
8399 The array of hard disk attachments is returned by
8400 <link to="IMachine::hardDiskAttachments"/>.
8401 </desc>
8402 <attribute name="hardDisk" type="IHardDisk" readonly="yes">
8403 <desc>Hard disk object associated with this attachment.</desc>
8404 </attribute>
8405
8406 <attribute name="controller" type="wstring" readonly="yes">
8407 <desc>Interface bus of this attachment.</desc>
8408 </attribute>
8409
8410 <attribute name="port" type="long" readonly="yes">
8411 <desc>Port number of this attachment.</desc>
8412 </attribute>
8413
8414 <attribute name="device" type="long" readonly="yes">
8415 <desc>Device slot number of this attachment.</desc>
8416 </attribute>
8417
8418 </interface>
8419
8420 <interface
8421 name="IHardDisk" extends="IMedium"
8422 uuid="a4d391a5-e2b1-474d-824e-2ff668a92d58"
8423 wsmap="managed"
8424 >
8425 <desc>
8426 The IHardDisk interface represents a virtual hard disk drive
8427 used by a virtual machine. This is a subclass of <link to="IMedium" />; see remarks there.
8428
8429 Virtual hard disk objects virtualize the hard disk hardware and look like
8430 regular hard disks for the guest OS running inside the virtual machine.
8431
8432 <h3>Hard Disk Types</h3>
8433
8434 There are three types of hard disks:
8435 <link to="HardDiskType_Normal">Normal</link>,
8436 <link to="HardDiskType_Immutable">Immutable</link> and
8437 <link to="HardDiskType_Writethrough">Writethrough</link>. The type of the
8438 hard disk defines how the hard disk is attached to a virtual machine and
8439 what happens when a <link to="ISnapshot">snapshot</link> of the virtual
8440 machine with the attached hard disk is taken. The type of the hard disk is
8441 defined by the <link to="#type"/> attribute.
8442
8443 All hard disks can be also divided in two big groups: <i>base</i> hard
8444 disks and <i>differencing</i> hard disks. A base hard disk contains all
8445 sectors of the hard disk data in its storage unit and therefore can be
8446 used independently. On the contrary, a differencing hard disk contains
8447 only some part of the hard disk data (a subset of sectors) and needs
8448 another hard disk to get access to the missing sectors of data. This
8449 another hard disk is called a <i>parent</i> hard disk and defines a hard
8450 disk to which this differencing hard disk is known to be <i>linked to</i>.
8451 The parent hard disk may be itself a differencing hard disk. This
8452 way, differencing hard disks form a linked hard disk chain. This chain
8453 always ends with the base hard disk which is sometimes referred to as the
8454 root hard disk of this chain. Note that several differencing hard disks
8455 may be linked to the same parent hard disk. This way, all known hard disks
8456 form a hard disk tree which is based on their parent-child relationship.
8457
8458 Differencing hard disks can be distinguished from base hard disks by
8459 querying the <link to="#parent"/> attribute: base hard disks do not have
8460 parents they would depend on, so the value of this attribute is always
8461 <tt>null</tt> for them. Using this attribute, it is possible to walk up
8462 the hard disk tree (from the child hard disk to its parent). It is also
8463 possible to walk down the tree using the <link to="#children"/>
8464 attribute.
8465
8466 Note that the type of all differencing hard disks is
8467 <link to="HardDiskType_Normal">Normal</link>; all other values are
8468 meaningless for them. Base hard disks may be of any type.
8469
8470 <h3>Creating Hard Disks</h3>
8471
8472 New base hard disks are created using
8473 <link to="IVirtualBox::createHardDisk"/>. Existing hard disks are
8474 opened using <link to="IVirtualBox::openHardDisk"/>. Differencing hard
8475 disks are usually implicitly created by VirtualBox when needed but may
8476 also be created explicitly using <link to="#createDiffStorage"/>.
8477
8478 After the hard disk is successfully created (including the storage unit)
8479 or opened, it becomes a known hard disk (remembered in the internal media
8480 registry). Known hard disks can be attached to a virtual machine, accessed
8481 through <link to="IVirtualBox::getHardDisk"/> and
8482 <link to="IVirtualBox::findHardDisk"/> methods or enumerated using the
8483 <link to="IVirtualBox::hardDisks"/> array (only for base hard disks).
8484
8485 The following methods, besides <link to="IMedium::close"/>,
8486 automatically remove the hard disk from the media registry:
8487 <ul>
8488 <li><link to="#deleteStorage"/></li>
8489 <li><link to="#mergeTo"/></li>
8490 </ul>
8491
8492 If the storage unit of the hard disk is a regular file in the host's
8493 file system then the rules stated in the description of the
8494 <link to="IMedium::location"/> attribute apply when setting its value. In
8495 addition, a plain file name without any path may be given, in which case
8496 the <link to="ISystemProperties::defaultHardDiskFolder"> default hard disk
8497 folder</link> will be prepended to it.
8498
8499 <h4>Automatic composition of the file name part</h4>
8500
8501 Another extension to the <link to="IMedium::location"/> attribute is that
8502 there is a possibility to cause VirtualBox to compose a unique value for
8503 the file name part of the location using the UUID of the hard disk. This
8504 applies only to hard disks in <link to="MediaState_NotCreated"/> state,
8505 e.g. before the storage unit is created, and works as follows. You set the
8506 value of the <link to="IMedium::location"/> attribute to a location
8507 specification which only contains the path specification but not the file
8508 name part and ends with either a forward slash or a backslash character.
8509 In response, VirtualBox will generate a new UUID for the hard disk and
8510 compose the file name using the following pattern:
8511 <pre>
8512 &lt;path&gt;/{&lt;uuid&gt;}.&lt;ext&gt;
8513 </pre>
8514 where <tt>&lt;path&gt;</tt> is the supplied path specification,
8515 <tt>&lt;uuid&gt;</tt> is the newly generated UUID and <tt>&lt;ext&gt;</tt>
8516 is the default extension for the storage format of this hard disk. After
8517 that, you may call any of the methods that create a new hard disk storage
8518 unit and they will use the generated UUID and file name.
8519
8520 <h3>Attaching Hard Disks</h3>
8521
8522 Hard disks are attached to virtual machines using the
8523 <link to="IMachine::attachHardDisk"/> method and detached using the
8524 <link to="IMachine::detachHardDisk"/> method. Depending on their
8525 <link to="#type"/>, hard disks are attached either
8526 <i>directly</i> or <i>indirectly</i>.
8527
8528 When a hard disk is being attached directly, it is associated with the
8529 virtual machine and used for hard disk operations when the machine is
8530 running. When a hard disk is being attached indirectly, a new differencing
8531 hard disk linked to it is implicitly created and this differencing hard
8532 disk is associated with the machine and used for hard disk operations.
8533 This also means that if <link to="IMachine::attachHardDisk"/> performs
8534 a direct attachment then the same hard disk will be returned in response
8535 to the subsequent <link to="IMachine::getHardDisk"/> call; however if
8536 an indirect attachment is performed then
8537 <link to="IMachine::getHardDisk"/> will return the implicitly created
8538 differencing hard disk, not the original one passed to <link
8539 to="IMachine::attachHardDisk"/>. The following table shows the
8540 dependency of the attachment type on the hard disk type:
8541
8542 <table>
8543 <tr>
8544 <th>Hard Disk Type</th>
8545 <th>Direct or Indirect?</th>
8546 </tr>
8547 <tr>
8548 <td>Normal (Base)</td>
8549 <td>
8550 Normal base hard disks that do not have children (i.e. differencing
8551 hard disks linked to them) and that are not already attached to
8552 virtual machines in snapshots are attached <b>directly</b>.
8553 Otherwise, they are attached <b>indirectly</b> because having
8554 dependent children or being part of the snapshot makes it impossible
8555 to modify hard disk contents without breaking the integrity of the
8556 dependent party. The <link to="#readOnly"/> attribute allows to
8557 quickly determine the kind of the attachment for the given hard
8558 disk. Note that if a normal base hard disk is to be indirectly
8559 attached to a virtual machine with snapshots then a special
8560 procedure called <i>smart attachment</i> is performed (see below).
8561 </td>
8562 </tr>
8563 <tr>
8564 <td>Normal (Differencing)</td>
8565 <td>
8566 Differencing hard disks are like normal base hard disks: attached
8567 <b>directly</b> if they do not have children and are not attached to
8568 virtual machines in snapshots, and <b>indirectly</b> otherwise. Note
8569 that the smart attachment procedure is never performed for
8570 differencing hard disks.
8571 </td>
8572 </tr>
8573 <tr>
8574 <td>Immutable</td>
8575 <td>
8576 Immutable hard disks are always attached <b>indirectly</b> because
8577 they are designed to be non-writable. If an immutable hard disk is
8578 attached to a virtual machine with snapshots then a special
8579 procedure called smart attachment is performed (see below).
8580 </td>
8581 </tr>
8582 <tr>
8583 <td>Writethrough</td>
8584 <td>
8585 Writethrough hard disks are always attached <b>directly</b>, also as
8586 designed. This also means that writethrough hard disks cannot have
8587 other hard disks linked to them at all.
8588 </td>
8589 </tr>
8590 </table>
8591
8592 Note that the same hard disk, regardless of its type, may be attached to
8593 more than one virtual machine at a time. In this case, the machine that is
8594 started first gains exclusive access to the hard disk and attempts to
8595 start other machines having this hard disk attached will fail until the
8596 first machine is powered down.
8597
8598 Detaching hard disks is performed in a <i>deferred</i> fashion. This means
8599 that the given hard disk remains associated with the given machine after a
8600 successful <link to="IMachine::detachHardDisk"/> call until
8601 <link to="IMachine::saveSettings"/> is called to save all changes to
8602 machine settings to disk. This deferring is necessary to guarantee that
8603 the hard disk configuration may be restored at any time by a call to
8604 <link to="IMachine::discardSettings"/> before the settings
8605 are saved (committed).
8606
8607 Note that if <link to="IMachine::discardSettings"/> is called after
8608 indirectly attaching some hard disks to the machine but before a call to
8609 <link to="IMachine::saveSettings"/> is made, it will implicitly delete
8610 all differencing hard disks implicitly created by
8611 <link to="IMachine::attachHardDisk"/> for these indirect attachments.
8612 Such implicitly created hard disks will also be immediately deleted when
8613 detached explicitly using the <link to="IMachine::detachHardDisk"/>
8614 call if it is made before <link to="IMachine::saveSettings"/>. This
8615 implicit deletion is safe because newly created differencing hard
8616 disks do not contain any user data.
8617
8618 However, keep in mind that detaching differencing hard disks that were
8619 implicitly created by <link to="IMachine::attachHardDisk"/>
8620 before the last <link to="IMachine::saveSettings"/> call will
8621 <b>not</b> implicitly delete them as they may already contain some data
8622 (for example, as a result of virtual machine execution). If these hard
8623 disks are no more necessary, the caller can always delete them explicitly
8624 using <link to="#deleteStorage"/> after they are actually de-associated
8625 from this machine by the <link to="IMachine::saveSettings"/> call.
8626
8627 <h3>Smart Attachment</h3>
8628
8629 When normal base or immutable hard disks are indirectly attached to a
8630 virtual machine then some additional steps are performed to make sure the
8631 virtual machine will have the most recent "view" of the hard disk being
8632 attached. These steps include walking through the machine's snapshots
8633 starting from the current one and going through ancestors up to the first
8634 snapshot. Hard disks attached to the virtual machine in all
8635 of the encountered snapshots are checked whether they are descendants of
8636 the given normal base or immutable hard disk. The first found child (which
8637 is the differencing hard disk) will be used instead of the normal base or
8638 immutable hard disk as a parent for creating a new differencing hard disk
8639 that will be actually attached to the machine. And only if no descendants
8640 are found or if the virtual machine does not have any snapshots then the
8641 normal base or immutable hard disk will be used itself as a parent for
8642 this differencing hard disk.
8643
8644 It is easier to explain what smart attachment does using the
8645 following example:
8646 <pre>
8647BEFORE attaching B.vdi: AFTER attaching B.vdi:
8648
8649Snapshot 1 (B.vdi) Snapshot 1 (B.vdi)
8650 Snapshot 2 (D1->B.vdi) Snapshot 2 (D1->B.vdi)
8651 Snapshot 3 (D2->D1.vdi) Snapshot 3 (D2->D1.vdi)
8652 Snapshot 4 (none) Snapshot 4 (none)
8653 CurState (none) CurState (D3->D2.vdi)
8654
8655 NOT
8656 ...
8657 CurState (D3->B.vdi)
8658 </pre>
8659 The first column is the virtual machine configuration before the base hard
8660 disk <tt>B.vdi</tt> is attached, the second column shows the machine after
8661 this hard disk is attached. Constructs like <tt>D1->B.vdi</tt> and similar
8662 mean that the hard disk that is actually attached to the machine is a
8663 differencing hard disk, <tt>D1.vdi</tt>, which is linked to (based on)
8664 another hard disk, <tt>B.vdi</tt>.
8665
8666 As we can see from the example, the hard disk <tt>B.vdi</tt> was detached
8667 from the machine before taking Snapshot 4. Later, after Snapshot 4 was
8668 taken, the user decides to attach <tt>B.vdi</tt> again. <tt>B.vdi</tt> has
8669 dependent child hard disks (<tt>D1.vdi</tt>, <tt>D2.vdi</tt>), therefore
8670 it cannot be attached directly and needs an indirect attachment (i.e.
8671 implicit creation of a new differencing hard disk). Due to the smart
8672 attachment procedure, the new differencing hard disk
8673 (<tt>D3.vdi</tt>) will be based on <tt>D2.vdi</tt>, not on
8674 <tt>B.vdi</tt> itself, since <tt>D2.vdi</tt> is the most recent view of
8675 <tt>B.vdi</tt> existing for this snapshot branch of the given virtual
8676 machine.
8677
8678 Note that if there is more than one descendant hard disk of the given base
8679 hard disk found in a snapshot, and there is an exact device, channel and
8680 bus match, then this exact match will be used. Otherwise, the youngest
8681 descendant will be picked up.
8682
8683 There is one more important aspect of the smart attachment procedure which
8684 is not related to snapshots at all. Before walking through the snapshots
8685 as described above, the backup copy of the current list of hard disk
8686 attachment is searched for descendants. This backup copy is created when
8687 the hard disk configuration is changed for the first time after the last
8688 <link to="IMachine::saveSettings"/> call and used by
8689 <link to="IMachine::discardSettings"/> to undo the recent hard disk
8690 changes. When such a descendant is found in this backup copy, it will be
8691 simply re-attached back, without creating a new differencing hard disk for
8692 it. This optimization is necessary to make it possible to re-attach the
8693 base or immutable hard disk to a different bus, channel or device slot
8694 without losing the contents of the differencing hard disk actually
8695 attached to the machine in place of it.
8696 </desc>
8697
8698 <attribute name="format" type="wstring" readonly="yes">
8699 <desc>
8700 Storage format of this hard disk.
8701
8702 The value of this attribute is a string that specifies a backend used to
8703 store hard disk data. The storage format is defined when you create a
8704 new hard disk or automatically detected when you open an existing hard
8705 disk medium, and cannot be changed later.
8706
8707 The list of all storage formats supported by this VirtualBox
8708 installation can be obtained using
8709 <link to="ISystemProperties::hardDiskFormats"/>.
8710 </desc>
8711 </attribute>
8712
8713 <attribute name="type" type="HardDiskType">
8714 <desc>
8715 Type (role) of this hard disk.
8716
8717 The following constraints apply when changing the value of this
8718 attribute:
8719 <ul>
8720 <li>If a hard disk is attached to a virtual machine (either in the
8721 current state or in one of the snapshots), its type cannot be
8722 changed.
8723 </li>
8724 <li>As long as the hard disk has children, its type cannot be set
8725 to <link to="HardDiskType_Writethrough"/>.
8726 </li>
8727 <li>The type of all differencing hard disks is
8728 <link to="HardDiskType_Normal"/> and cannot be changed.
8729 </li>
8730 </ul>
8731
8732 The type of a newly created or opened hard disk is set to
8733 <link to="HardDiskType_Normal"/>.
8734 </desc>
8735 </attribute>
8736
8737 <attribute name="parent" type="IHardDisk" readonly="yes">
8738 <desc>
8739 Parent of this hard disk (a hard disk this hard disk is directly based
8740 on).
8741
8742 Only differencing hard disks have parents. For base (non-differencing)
8743 hard disks, <tt>null</tt> is returned.
8744 </desc>
8745 </attribute>
8746
8747 <attribute name="children" type="IHardDisk" safearray="yes" readonly="yes">
8748 <desc>
8749 Children of this hard disk (all differencing hard disks directly based
8750 on this hard disk). A <tt>null</tt> array is returned if this hard disk
8751 does not have any children.
8752 </desc>
8753 </attribute>
8754
8755 <attribute name="root" type="IHardDisk" readonly="yes">
8756 <desc>
8757 Root hard disk of this hard disk.
8758
8759 If this is a differencing hard disk, its root hard disk is the base hard
8760 disk the given hard disk branch starts from. For all other types of hard
8761 disks, this property returns the hard disk object itself (i.e. the same
8762 object this property is read on).
8763 </desc>
8764 </attribute>
8765
8766 <attribute name="readOnly" type="boolean" readonly="yes">
8767 <desc>
8768 Returns <tt>true</tt> if this hard disk is read-only and <tt>false</tt>
8769 otherwise.
8770
8771 A hard disk is considered to be read-only when its contents cannot be
8772 modified without breaking the integrity of other parties that depend on
8773 this hard disk such as its child hard disks or snapshots of virtual
8774 machines where this hard disk is attached to these machines. If there
8775 are no children and no such snapshots then there is no dependency and
8776 the hard disk is not read-only.
8777
8778 The value of this attribute can be used to determine the kind of the
8779 attachment that will take place when attaching this hard disk to a
8780 virtual machine. If the value is <tt>false</tt> then the hard disk will
8781 be attached directly. If the value is <tt>true</tt> then the hard disk
8782 will be attached indirectly by creating a new differencing child hard
8783 disk for that. See the interface description for more information.
8784
8785 Note that all <link to="HardDiskType_Immutable">Immutable</link> hard
8786 disks are always read-only while all
8787 <link to="HardDiskType_Writethrough">Writethrough</link> hard disks are
8788 always not.
8789
8790 <note>
8791 The read-only condition represented by this attribute is related to
8792 the hard disk type and usage, not to the current
8793 <link to="IMedium::state">media state</link> and not to the read-only
8794 state of the storage unit.
8795 </note>
8796 </desc>
8797 </attribute>
8798
8799 <attribute name="logicalSize" type="unsigned long long" readonly="yes">
8800 <desc>
8801 Logical size of this hard disk (in megabytes), as reported to the
8802 guest OS running inside the virtual machine this disk is
8803 attached to. The logical size is defined when the hard disk is created
8804 and cannot be changed later.
8805
8806 <note>
8807 Reading this property on a differencing hard disk will return the size
8808 of its <link to="#root"/> hard disk.
8809 </note>
8810 <note>
8811 For hard disks whose state is <link to="#state"/> is <link
8812 to="MediaState_Inaccessible"/>, the value of this property is the
8813 last known logical size. For <link to="MediaState_NotCreated"/> hard
8814 disks, the returned value is zero.
8815 </note>
8816 </desc>
8817 </attribute>
8818
8819 <attribute name="autoReset" type="boolean">
8820 <desc>
8821 Whether this differencing hard disk will be automatically reset each
8822 time a virtual machine it is attached to is powered up.
8823
8824 See <link to="#reset()"/> for more information about resetting
8825 differencing hard disks.
8826
8827 <note>
8828 Reading this property on a base (non-differencing) hard disk will
8829 always <tt>false</tt>. Changing the value of this property in this
8830 case is not supported.
8831 </note>
8832
8833 <result name="VBOX_E_NOT_SUPPORTED">
8834 This is not a differencing hard disk (when changing the attribute
8835 value).
8836 </result>
8837 </desc>
8838 </attribute>
8839
8840 <!-- storage methods -->
8841
8842 <method name="getProperty">
8843 <desc>
8844 Returns the value of the custom hard disk property with the given name.
8845
8846 The list of all properties supported by the given hard disk format can
8847 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
8848
8849 Note that if this method returns a <tt>null</tt> @a value, the requested
8850 property is supported but currently not assigned any value.
8851
8852 <result name="VBOX_E_OBJECT_NOT_FOUND">
8853 Requested property does not exist (not supported by the format).
8854 </result>
8855 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
8856 </desc>
8857 <param name="name" type="wstring" dir="in">
8858 <desc>Name of the property to get.</desc>
8859 </param>
8860 <param name="value" type="wstring" dir="return">
8861 <desc>Current property value.</desc>
8862 </param>
8863 </method>
8864
8865 <method name="setProperty">
8866 <desc>
8867 Sets the value of the custom hard disk property with the given name.
8868
8869 The list of all properties supported by the given hard disk format can
8870 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
8871
8872 Note that setting the property value to <tt>null</tt> is equivalent to
8873 deleting the existing value. A default value (if it is defined for this
8874 property) will be used by the format backend in this case.
8875
8876 <result name="VBOX_E_OBJECT_NOT_FOUND">
8877 Requested property does not exist (not supported by the format).
8878 </result>
8879 <result name="E_INVALIDARG">@a name is NULL or empty.</result>
8880 </desc>
8881 <param name="name" type="wstring" dir="in">
8882 <desc>Name of the property to set.</desc>
8883 </param>
8884 <param name="value" type="wstring" dir="in">
8885 <desc>Property value to set.</desc>
8886 </param>
8887 </method>
8888
8889 <method name="getProperties">
8890 <desc>
8891 Returns values for a group of properties in one call.
8892
8893 The names of the properties to get are specified using the @a names
8894 argument which is a list of comma-separated property names or
8895 <tt>null</tt> if all properties are to be returned. Note that currently
8896 the value of this argument is ignored and the method always returns all
8897 existing properties.
8898
8899 The list of all properties supported by the given hard disk format can
8900 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
8901
8902 The method returns two arrays, the array of property names corresponding
8903 to the @a names argument and the current values of these properties.
8904 Both arrays have the same number of elements with each elemend at the
8905 given index in the first array corresponds to an element at the same
8906 index in the second array.
8907
8908 Note that for properties that do not have assigned values,
8909 <tt>null</tt> is returned at the appropriate index in the
8910 @a returnValues array.
8911
8912 </desc>
8913 <param name="names" type="wstring" dir="in">
8914 <desc>
8915 Names of properties to get.
8916 </desc>
8917 </param>
8918 <param name="returnNames" type="wstring" safearray="yes" dir="out">
8919 <desc>Names of returned properties.</desc>
8920 </param>
8921 <param name="returnValues" type="wstring" safearray="yes" dir="return">
8922 <desc>Values of returned properties.</desc>
8923 </param>
8924 </method>
8925
8926 <method name="setProperties">
8927 <desc>
8928 Sets values for a group of properties in one call.
8929
8930 The names of the properties to set are passed in the @a names
8931 array along with the new values for them in the @a values array. Both
8932 arrays have the same number of elements with each elemend at the given
8933 index in the first array corresponding to an element at the same index
8934 in the second array.
8935
8936 If there is at least one property name in @a names that is not valid,
8937 the method will fail before changing the values of any other properties
8938 from the @a names array.
8939
8940 Using this method over <link to="#setProperty"/> is preferred if you
8941 need to set several properties at once since it will result into less
8942 IPC calls.
8943
8944 The list of all properties supported by the given hard disk format can
8945 be obtained with <link to="IHardDiskFormat::describeProperties"/>.
8946
8947 Note that setting the property value to <tt>null</tt> is equivalent to
8948 deleting the existing value. A default value (if it is defined for this
8949 property) will be used by the format backend in this case.
8950 </desc>
8951 <param name="names" type="wstring" safearray="yes" dir="in">
8952 <desc>Names of properties to set.</desc>
8953 </param>
8954 <param name="values" type="wstring" safearray="yes" dir="in">
8955 <desc>Values of properties to set.</desc>
8956 </param>
8957 </method>
8958
8959 <!-- storage methods -->
8960
8961 <method name="createDynamicStorage">
8962 <desc>
8963 Starts creating a dynamically expanding hard disk storage unit in the
8964 background. The previous storage unit created for this object, if
8965 any, must first be deleted using <link to="#deleteStorage"/>, otherwise
8966 the operation will fail.
8967
8968 Before the operation starts, the hard disk is placed in
8969 <link to="MediaState_Creating"/> state. If the create operation
8970 fails, the media will be placed back in <link to="MediaState_NotCreated"/>
8971 state.
8972
8973 After the returned progress object reports that the operation has
8974 successfully completed, the media state will be set to <link
8975 to="MediaState_Created"/>, the hard disk will be remembered by this
8976 VirtualBox installation and may be attached to virtual machines.
8977
8978 <result name="VBOX_E_NOT_SUPPORTED">
8979 Dynamic storage creation operation is not supported. See <link
8980 to="IHardDiskFormat::capabilities"/>.
8981 </result>
8982 </desc>
8983 <param name="logicalSize" type="unsigned long long" dir="in">
8984 <desc>Maximum logical size of the hard disk in megabytes.</desc>
8985 </param>
8986 <param name="progress" type="IProgress" dir="return">
8987 <desc>Progress object to track the operation completion.</desc>
8988 </param>
8989 </method>
8990
8991 <method name="createFixedStorage">
8992 <desc>
8993 Starts creating a fixed-size hard disk storage unit in the background.
8994 The previous storage unit created for this object, if
8995 any, must be first deleted using <link to="#deleteStorage"/>, otherwise
8996 the operation will fail.
8997
8998 Before the operation starts, the hard disk is placed to
8999 <link to="MediaState_Creating"/> state. If the create operation
9000 fails, the media will placed back to <link to="MediaState_NotCreated"/>
9001 state.
9002
9003 After the returned progress object reports that the operation is
9004 successfully complete, the media state will be set to <link
9005 to="MediaState_Created"/>, the hard disk will be remembered by this
9006 VirtualBox installation and may be attached to virtual machines.
9007
9008 <result name="VBOX_E_NOT_SUPPORTED">
9009 Fixed storage creation operation is not supported. See
9010 <link to="IHardDiskFormat::capabilities"/>.
9011 </result>
9012 </desc>
9013 <param name="logicalSize" type="unsigned long long" dir="in">
9014 <desc>Logical size of the hard disk in megabytes.</desc>
9015 </param>
9016 <param name="progress" type="IProgress" dir="return">
9017 <desc>Progress object to track the operation completion.</desc>
9018 </param>
9019 </method>
9020
9021 <method name="deleteStorage">
9022 <desc>
9023 Starts deleting the storage unit of this hard disk.
9024
9025 The hard disk must not be attached to any known virtual machine and must
9026 not have any known child hard disks, otherwise the operation will fail.
9027 It will also fail if there is no storage unit to delete or if deletion
9028 is already in progress, or if the hard disk is being in use (locked for
9029 read or for write) or inaccessible. Therefore, the only valid state for
9030 this operation to succeed is <link to="MediaState_Created"/>.
9031
9032 Before the operation starts, the hard disk is placed to
9033 <link to="MediaState_Deleting"/> state and gets removed from the list
9034 of remembered hard disks (media registry). If the delete operation
9035 fails, the media will be remembered again and placed back to
9036 <link to="MediaState_Created"/> state.
9037
9038 After the returned progress object reports that the operation is
9039 complete, the media state will be set to
9040 <link to="MediaState_NotCreated"/> and you will be able to use one of
9041 the storage creation methods to create it again.
9042
9043 <see>#close()</see>
9044
9045 <result name="VBOX_E_OBJECT_IN_USE">
9046 Hard disk is attached to a virtual machine.
9047 </result>
9048 <result name="VBOX_E_NOT_SUPPORTED">
9049 Storage deletion is not allowed because neither of storage creation
9050 operations are supported. See
9051 <link to="IHardDiskFormat::capabilities"/>.
9052 </result>
9053
9054 <note>
9055 If the deletion operation fails, it is not guaranteed that the storage
9056 unit still exists. You may check the <link to="IMedium::state"/> value
9057 to answer this question.
9058 </note>
9059 </desc>
9060 <param name="progress" type="IProgress" dir="return">
9061 <desc>Progress object to track the operation completion.</desc>
9062 </param>
9063 </method>
9064
9065 <!-- diff methods -->
9066
9067 <method name="createDiffStorage">
9068 <desc>
9069 Starts creating an empty differencing storage unit based on this hard
9070 disk in the format and at the location defined by the @a target
9071 argument.
9072
9073 The target hard disk must be in <link to="MediaState_NotCreated"/>
9074 state (i.e. must not have an existing storage unit). Upon successful
9075 completion, this operation will set the type of the target hard disk to
9076 <link to="HardDiskType_Normal"/> and create a storage unit necessary to
9077 represent the differencing hard disk data in the given format (according
9078 to the storage format of the target object).
9079
9080 After the returned progress object reports that the operation is
9081 successfully complete, the target hard disk gets remembered by this
9082 VirtualBox installation and may be attached to virtual machines.
9083
9084 <note>
9085 The hard disk will be set to <link to="MediaState_LockedRead"/>
9086 state for the duration of this operation.
9087 </note>
9088 <result name="VBOX_E_OBJECT_IN_USE">
9089 Hard disk not in NotCreated state.
9090 </result>
9091 </desc>
9092 <param name="target" type="IHardDisk" dir="in">
9093 <desc>Target hard disk.</desc>
9094 </param>
9095 <param name="progress" type="IProgress" dir="return">
9096 <desc>Progress object to track the operation completion.</desc>
9097 </param>
9098 </method>
9099
9100 <method name="mergeTo">
9101 <desc>
9102 Starts merging the contents of this hard disk and all intermediate
9103 differencing hard disks in the chain to the given target hard disk.
9104
9105 The target hard disk must be either a descendant of this hard disk or
9106 its ancestor (otherwise this method will immediately return a failure).
9107 It follows that there are two logical directions of the merge operation:
9108 from ancestor to descendant (<i>forward merge</i>) and from descendant to
9109 ancestor (<i>backward merge</i>). Let us consider the following hard disk
9110 chain:
9111
9112 <pre>Base &lt;- Diff_1 &lt;- Diff_2</pre>
9113
9114 Here, calling this method on the <tt>Base</tt> hard disk object with
9115 <tt>Diff_2</tt> as an argument will be a forward merge; calling it on
9116 <tt>Diff_2</tt> with <tt>Base</tt> as an argument will be a backward
9117 merge. Note that in both cases the contents of the resulting hard disk
9118 will be the same, the only difference is the hard disk object that takes
9119 the result of the merge operation. In case of the forward merge in the
9120 above example, the result will be written to <tt>Diff_2</tt>; in case of
9121 the backward merge, the result will be written to <tt>Base</tt>. In
9122 other words, the result of the operation is always stored in the target
9123 hard disk.
9124
9125 Upon successful operation completion, the storage units of all hard
9126 disks in the chain between this (source) hard disk and the target hard
9127 disk, including the source hard disk itself, will be automatically
9128 deleted and the relevant hard disk objects (including this hard disk)
9129 will become uninitialized. This means that any attempt to call any of
9130 their methods or attributes will fail with the
9131 <tt>"Object not ready" (E_ACCESSDENIED)</tt> error. Applied to the above
9132 example, the forward merge of <tt>Base</tt> to <tt>Diff_2</tt> will
9133 delete and uninitialize both <tt>Base</tt> and <tt>Diff_1</tt> hard
9134 disks. Note that <tt>Diff_2</tt> in this case will become a base hard
9135 disk itself since it will no longer be based on any other hard disk.
9136
9137 Considering the above, all of the following conditions must be met in
9138 order for the merge operation to succeed:
9139 <ul>
9140 <li>
9141 Neither this (source) hard disk nor any intermediate
9142 differencing hard disk in the chain between it and the target
9143 hard disk is attached to any virtual machine.
9144 </li>
9145 <li>
9146 Neither the source hard disk nor the target hard disk is an
9147 <link to="HardDiskType_Immutable"/> hard disk.
9148 </li>
9149 <li>
9150 The part of the hard disk tree from the source hard disk to the
9151 target hard disk is a linear chain, i.e. all hard disks in this
9152 chain have exactly one child which is the next hard disk in this
9153 chain. The only exception from this rule is the target hard disk in
9154 the forward merge operation; it is allowed to have any number of
9155 child hard disks because the merge operation will hot change its
9156 logical contents (as it is seen by the guest OS or by children).
9157 </li>
9158 <li>
9159 None of the involved hard disks are in
9160 <link to="MediaState_LockedRead"/> or
9161 <link to="MediaState_LockedWrite"/> state.
9162 </li>
9163 </ul>
9164
9165 <note>
9166 This (source) hard disk and all intermediates will be placed to <link
9167 to="MediaState_Deleting"/> state and the target hard disk will be
9168 placed to <link to="MediaState_LockedWrite"/> state and for the
9169 duration of this operation.
9170 </note>
9171 </desc>
9172 <param name="targetId" type="uuid" dir="in">
9173 <desc>UUID of the target ancestor or descendant hard disk.</desc>
9174 </param>
9175 <param name="progress" type="IProgress" dir="return">
9176 <desc>Progress object to track the operation completion.</desc>
9177 </param>
9178 </method>
9179
9180 <!-- clone methods -->
9181
9182 <method name="cloneTo">
9183 <desc>
9184 Starts creating a clone of this hard disk in the format and at the
9185 location defined by the @a target argument.
9186
9187 The target hard disk must be in <link to="MediaState_NotCreated"/>
9188 state (i.e. must not have an existing storage unit). Upon successful
9189 completion, the cloned hard disk will contain exactly the same sector
9190 data as the hard disk being cloned, except that a new UUID for the clone
9191 will be randomly generated.
9192
9193 After the returned progress object reports that the operation is
9194 successfully complete, the target hard disk gets remembered by this
9195 VirtualBox installation and may be attached to virtual machines.
9196
9197 <note>
9198 If the cloned hard disk is a differencing hard disk, it will inherit
9199 parent dependency of the original hard disk.
9200 </note>
9201 <note>
9202 This hard disk will be placed to <link to="MediaState_LockedRead"/>
9203 state for the duration of this operation.
9204 </note>
9205 </desc>
9206 <param name="target" type="IHardDisk" dir="in">
9207 <desc>Target hard disk.</desc>
9208 </param>
9209 <param name="progress" type="IProgress" dir="return">
9210 <desc>Progress object to track the operation completion.</desc>
9211 </param>
9212 </method>
9213
9214 <method name="flattenTo">
9215 <desc>
9216 Starts creating a deep (independent) clone of this hard disk in the
9217 format and at the location defined by the @a target argument.
9218
9219 This operation is similar to <link to="#cloneTo"/> except that when
9220 applied to a differencing hard disk, it will also copy missing hard disk
9221 data from all parent hard disks it is linked to. This will make the
9222 created clone an independent base hard disk that contains all hard disk
9223 data and does not need any other hard disks to operate.
9224
9225 After the returned progress object reports that the operation is
9226 successfully complete, the target hard disk gets remembered by this
9227 VirtualBox installation and may be attached to virtual machines.
9228
9229 <note>
9230 For base hard disks, this operation is identical to
9231 <link to="#cloneTo"/>.
9232 </note>
9233 <note>
9234 This hard disk and all its parent hard disks will be placed to <link
9235 to="MediaState_LockedRead"/> state for the duration of this
9236 operation.
9237 </note>
9238 </desc>
9239 <param name="target" type="IHardDisk" dir="in">
9240 <desc>Target hard disk.</desc>
9241 </param>
9242 <param name="progress" type="IProgress" dir="return">
9243 <desc>Progress object to track the operation completion.</desc>
9244 </param>
9245 </method>
9246
9247 <!-- other methods -->
9248
9249 <method name="compact">
9250 <desc>
9251 Starts compacting of this hard disk. This means that the disk is
9252 transformed into a possibly more compact storage representation.
9253 This potentially creates temporary images, which can require a
9254 substantial amount of additional disk space.
9255
9256 This hard disk will be placed to <link to="MediaState_LockedWrite"/>
9257 state and all its parent hard disks (if any) will be placed to
9258 <link to="MediaState_LockedRead"/> state for the duration of this
9259 operation.
9260 </desc>
9261 <param name="progress" type="IProgress" dir="return">
9262 <desc>Progress object to track the operation completion.</desc>
9263 </param>
9264 </method>
9265
9266 <method name="reset">
9267 <desc>
9268 Starts erasing the contents of this differencing hard disk.
9269
9270 This operation will reset the differencing hard disk to its initial
9271 state when it does not contain any sector data and any read operation is
9272 redirected to its parent hard disk.
9273
9274 This hard disk will be placed to <link to="MediaState_LockedWrite"/>
9275 for the duration of this operation.
9276
9277 <result name="VBOX_E_NOT_SUPPORTED">
9278 This is not a differencing hard disk.
9279 </result>
9280 <result name="VBOX_E_INVALID_OBJECT_STATE">
9281 Hard disk is not in <link to="MediaState_Created"/> or
9282 <link to="MediaState_Inaccessible"/> state.
9283 </result>
9284 </desc>
9285 <param name="progress" type="IProgress" dir="return">
9286 <desc>Progress object to track the operation completion.</desc>
9287 </param>
9288 </method>
9289
9290 </interface>
9291
9292
9293 <!--
9294 // IHardDiskFormat
9295 /////////////////////////////////////////////////////////////////////////
9296 -->
9297
9298 <enum
9299 name="DataType"
9300 uuid="d90ea51e-a3f1-4a01-beb1-c1723c0d3ba7"
9301 >
9302 <const name="Int32" value="0"/>
9303 <const name="Int8" value="1"/>
9304 <const name="String" value="2"/>
9305 </enum>
9306
9307 <enum
9308 name="DataFlags"
9309 uuid="86884dcf-1d6b-4f1b-b4bf-f5aa44959d60"
9310 >
9311 <const name="None" value="0x00"/>
9312 <const name="Mandatory" value="0x01"/>
9313 <const name="Expert" value="0x02"/>
9314 <const name="Array" value="0x04"/>
9315 <const name="FlagMask" value="0x07"/>
9316 </enum>
9317
9318 <enum
9319 name="HardDiskFormatCapabilities"
9320 uuid="1df1e4aa-d25a-4ba6-b2a2-02f60eb5903b"
9321 >
9322 <desc>
9323 Hard disk format capability flags.
9324 </desc>
9325
9326 <const name="Uuid" value="0x01">
9327 <desc>
9328 Supports UUIDs as expected by VirtualBox code.
9329 </desc>
9330 </const>
9331
9332 <const name="CreateFixed" value="0x02">
9333 <desc>
9334 Supports creating fixed size images, allocating all space instantly.
9335 </desc>
9336 </const>
9337
9338 <const name="CreateDynamic" value="0x04">
9339 <desc>
9340 Supports creating dynamically growing images, allocating space on
9341 demand.
9342 </desc>
9343 </const>
9344
9345 <const name="CreateSplit2G" value="0x08">
9346 <desc>
9347 Supports creating images split in chunks of a bit less than 2 GBytes.
9348 </desc>
9349 </const>
9350
9351 <const name="Differencing" value="0x10">
9352 <desc>
9353 Supports being used as a format for differencing hard disks (see <link
9354 to="IHardDisk::createDiffStorage"/>).
9355 </desc>
9356 </const>
9357
9358 <const name="Asynchronous" value="0x20">
9359 <desc>
9360 Supports asynchronous I/O operations for at least some configurations.
9361 </desc>
9362 </const>
9363
9364 <const name="File" value="0x40">
9365 <desc>
9366 The format backend operates on files (the <link to="IMedium::location"/>
9367 attribute of the hard disk specifies a file used to store hard disk
9368 data; for a list of supported file extensions see
9369 <link to="IHardDiskFormat::fileExtensions"/>).
9370 </desc>
9371 </const>
9372
9373 <const name="Properties" value="0x80">
9374 <desc>
9375 The format backend uses the property interface to configure the storage
9376 location and properties (the <link to="IHardDiskFormat::describeProperties"/>
9377 method is used to get access to properties supported by the given hard
9378 disk format).
9379 </desc>
9380 </const>
9381
9382 <const name="CapabilityMask" value="0xFF"/>
9383 </enum>
9384
9385 <interface
9386 name="IHardDiskFormat" extends="$unknown"
9387 uuid="7f3ba790-3a0b-4a8a-bac2-bb50150123c5"
9388 wsmap="managed"
9389 >
9390 <desc>
9391 The IHardDiskFormat interface represents a virtual hard disk format.
9392
9393 Each hard disk format has an associated backend which is used to handle
9394 hard disks stored in this format. This interface provides information
9395 about the properties of the associated backend.
9396
9397 Each hard disk format is identified by a string represented by the
9398 <link to="#id"/> attribute. This string is used in calls like
9399 <link to="IVirtualBox::createHardDisk"/> to specify the desired
9400 format.
9401
9402 The list of all supported hard disk formats can be obtained using
9403 <link to="ISystemProperties::hardDiskFormats"/>.
9404
9405 <see>IHardDisk</see>
9406 </desc>
9407
9408 <attribute name="id" type="wstring" readonly="yes">
9409 <desc>
9410 Identifier of this format.
9411
9412 The format identifier is a non-null non-empty ASCII string. Note that
9413 this string is case-insensitive. This means that, for example, all of
9414 the following strings:
9415 <pre>
9416 "VDI"
9417 "vdi"
9418 "VdI"</pre>
9419 refer to the same hard disk format.
9420
9421 This string is used in methods of other interfaces where it is necessary
9422 to specify a hard disk format, such as
9423 <link to="IVirtualBox::createHardDisk"/>.
9424 </desc>
9425 </attribute>
9426
9427 <attribute name="name" type="wstring" readonly="yes">
9428 <desc>
9429 Human readable description of this format.
9430
9431 Mainly for use in file open dialogs.
9432 </desc>
9433 </attribute>
9434
9435 <attribute name="fileExtensions" type="wstring" safearray="yes" readonly="yes">
9436 <desc>
9437 Array of strings containing the supported file extensions.
9438
9439 The first extension in the array is the extension preferred by the
9440 backend. It is recommended to use this extension when specifying a
9441 location of the storage unit for a new hard disk.
9442
9443 Note that some backends do not work on files, so this array may be
9444 empty.
9445
9446 <see>IHardDiskFormat::capabilities</see>
9447 </desc>
9448 </attribute>
9449
9450 <attribute name="capabilities" type="unsigned long" readonly="yes">
9451 <desc>
9452 Capabilities of the format as a set of bit flags.
9453
9454 For the meaning of individual capability flags see
9455 <link to="HardDiskFormatCapabilities"/>.
9456 </desc>
9457 </attribute>
9458
9459 <method name="describeProperties">
9460 <desc>
9461 Returns several arrays describing the properties supported by this
9462 format.
9463
9464 An element with the given index in each array describes one
9465 property. Thus, the number of elements in each returned array is the
9466 same and corresponds to the number of supported properties.
9467
9468 The returned arrays are filled in only if the
9469 <link to="HardDiskFormatCapabilities_Properties"/> flag is set.
9470 All arguments must be non-NULL.
9471
9472 <see>DataType</see>
9473 <see>DataFlags</see>
9474 </desc>
9475
9476 <param name="names" type="wstring" safearray="yes" dir="out">
9477 <desc>Array of property names.</desc>
9478 </param>
9479 <param name="description" type="wstring" safearray="yes" dir="out">
9480 <desc>Array of property descriptions.</desc>
9481 </param>
9482 <param name="types" type="DataType" safearray="yes" dir="out">
9483 <desc>Array of property types.</desc>
9484 </param>
9485 <param name="flags" type="unsigned long" safearray="yes" dir="out">
9486 <desc>Array of property flags.</desc>
9487 </param>
9488 <param name="defaults" type="wstring" safearray="yes" dir="out">
9489 <desc>Array of default property values.</desc>
9490 </param>
9491 </method>
9492
9493 </interface>
9494
9495
9496 <!--
9497 // IFloppyImage
9498 /////////////////////////////////////////////////////////////////////////
9499 -->
9500
9501 <interface
9502 name="IFloppyImage" extends="IMedium"
9503 uuid="faa6101f-078c-4b3a-ab75-75670c8170b3"
9504 wsmap="managed"
9505 >
9506 <desc>
9507 The IFloppyImage interface represents a medium containing the image
9508 of a floppy disk. This is a subclass of <link to="IMedium" />; see remarks there.
9509 </desc>
9510
9511 </interface>
9512
9513
9514 <!--
9515 // IDVDImage
9516 /////////////////////////////////////////////////////////////////////////
9517 -->
9518
9519 <interface
9520 name="IDVDImage" extends="IMedium"
9521 uuid="b1f90bbb-e8a9-4484-9af1-3638e943f763"
9522 wsmap="managed"
9523 >
9524 <desc>
9525 The IDVDImage interface represents a medium containing the image
9526 of a CD or DVD disk in the ISO format.
9527
9528 This is a subclass of <link to="IMedium" />; see remarks there.
9529 </desc>
9530
9531 </interface>
9532
9533
9534 <!--
9535 // IDVDDrive
9536 /////////////////////////////////////////////////////////////////////////
9537 -->
9538
9539 <interface
9540 name="IDVDDrive" extends="$unknown"
9541 uuid="d650ef30-be9b-4dae-b463-11d5824681a5"
9542 wsmap="managed"
9543 >
9544 <desc>
9545 The IDVDDrive interface represents the virtual CD/DVD drive of the
9546 virtual machine. An object of this type is returned by
9547 <link to="IMachine::DVDDrive"/>.
9548 </desc>
9549
9550 <attribute name="state" type="DriveState" readonly="yes">
9551 <desc>Current drive state.</desc>
9552 </attribute>
9553
9554 <attribute name="passthrough" type="boolean">
9555 <desc>
9556 When a host drive is mounted and passthrough is enabled
9557 the guest OS will be able to directly send SCSI commands to
9558 the host drive. This enables the guest OS to use CD/DVD writers
9559 but is potentially dangerous.
9560 </desc>
9561 </attribute>
9562
9563 <method name="mountImage">
9564 <desc>Mounts a CD/DVD image with the specified UUID.
9565
9566 <result name="VBOX_E_FILE_ERROR">
9567 Invalid image file location.
9568 </result>
9569 <result name="VBOX_E_OBJECT_NOT_FOUND">
9570 Could not find a CD/DVD image matching @a imageID.
9571 </result>
9572 <result name="VBOX_E_INVALID_OBJECT_STATE">
9573 Invalid media state.
9574 </result>
9575
9576 </desc>
9577 <param name="imageId" type="uuid" dir="in"/>
9578 </method>
9579
9580 <method name="captureHostDrive">
9581 <desc>Captures the specified host CD/DVD drive.</desc>
9582 <param name="drive" type="IHostDVDDrive" dir="in"/>
9583 </method>
9584
9585 <method name="unmount">
9586 <desc>Unmounts the currently mounted image or host drive.</desc>
9587 </method>
9588
9589 <method name="getImage">
9590 <desc>Returns the currently mounted CD/DVD image.</desc>
9591 <param name="image" type="IDVDImage" dir="return"/>
9592 </method>
9593
9594 <method name="getHostDrive">
9595 <desc>Returns the currently mounted host CD/DVD drive.</desc>
9596 <param name="drive" type="IHostDVDDrive" dir="return"/>
9597 </method>
9598
9599 </interface>
9600
9601
9602 <!--
9603 // IFloppyDrive
9604 /////////////////////////////////////////////////////////////////////////
9605 -->
9606
9607 <interface
9608 name="IFloppyDrive" extends="$unknown"
9609 uuid="159412cd-bab8-452e-8097-218a020825a6"
9610 wsmap="managed"
9611 >
9612 <desc>
9613 The IFloppyDrive interface represents the virtual floppy drive of the
9614 virtual machine. An object of this type is returned by
9615 <link to="IMachine::floppyDrive" />.
9616 </desc>
9617
9618 <attribute name="enabled" type="boolean">
9619 <desc>
9620 Flag whether the floppy drive is enabled. If it is disabled,
9621 the floppy drive will not be reported to the guest OS.
9622 </desc>
9623 </attribute>
9624
9625 <attribute name="state" type="DriveState" readonly="yes">
9626 <desc>Current drive state.</desc>
9627 </attribute>
9628
9629 <method name="mountImage">
9630 <desc>Mounts a floppy image with the specified UUID.
9631
9632 <result name="VBOX_E_FILE_ERROR">
9633 Invalid image file location.
9634 </result>
9635 <result name="VBOX_E_OBJECT_NOT_FOUND">
9636 Could not find a floppy image matching @a imageID.
9637 </result>
9638 <result name="VBOX_E_INVALID_OBJECT_STATE">
9639 Invalid media state.
9640 </result>
9641
9642 </desc>
9643 <param name="imageId" type="uuid" dir="in"/>
9644 </method>
9645
9646 <method name="captureHostDrive">
9647 <desc>Captures the specified host floppy drive.</desc>
9648 <param name="drive" type="IHostFloppyDrive" dir="in"/>
9649 </method>
9650
9651 <method name="unmount">
9652 <desc>Unmounts the currently mounted image or host drive.</desc>
9653 </method>
9654
9655 <method name="getImage">
9656 <desc>Returns the currently mounted floppy image.</desc>
9657 <param name="image" type="IFloppyImage" dir="return"/>
9658 </method>
9659
9660 <method name="getHostDrive">
9661 <desc>Returns the currently mounted host floppy drive.</desc>
9662 <param name="drive" type="IHostFloppyDrive" dir="return"/>
9663 </method>
9664
9665 </interface>
9666
9667
9668 <!--
9669 // IKeyboard
9670 /////////////////////////////////////////////////////////////////////////
9671 -->
9672
9673 <interface
9674 name="IKeyboard" extends="$unknown"
9675 uuid="2d1a531b-4c6e-49cc-8af6-5c857b78b5d7"
9676 wsmap="managed"
9677 >
9678 <desc>
9679 The IKeyboard interface represents the virtual machine's keyboard. Used
9680 in <link to="IConsole::keyboard"/>.
9681
9682 Use this interface to send keystrokes or the Ctrl-Alt-Del sequence
9683 to the virtual machine.
9684
9685 </desc>
9686 <method name="putScancode">
9687 <desc>Sends a scancode to the keyboard.
9688
9689 <result name="VBOX_E_IPRT_ERROR">
9690 Could not send scan code to virtual keyboard.
9691 </result>
9692
9693 </desc>
9694 <param name="scancode" type="long" dir="in"/>
9695 </method>
9696
9697 <method name="putScancodes">
9698 <desc>Sends an array of scancodes to the keyboard.
9699
9700 <result name="VBOX_E_IPRT_ERROR">
9701 Could not send all scan codes to virtual keyboard.
9702 </result>
9703
9704 </desc>
9705 <param name="scancodes" type="long" dir="in" safearray="yes"/>
9706 <param name="codesStored" type="unsigned long" dir="return"/>
9707 </method>
9708
9709 <method name="putCAD">
9710 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard. This
9711 function is nothing special, it is just a convenience function
9712 calling <link to="IKeyboard::putScancodes"/> with the proper scancodes.
9713
9714 <result name="VBOX_E_IPRT_ERROR">
9715 Could not send all scan codes to virtual keyboard.
9716 </result>
9717
9718 </desc>
9719 </method>
9720
9721 </interface>
9722
9723
9724 <!--
9725 // IMouse
9726 /////////////////////////////////////////////////////////////////////////
9727 -->
9728
9729 <enum
9730 name="MouseButtonState"
9731 uuid="03131722-2EC5-4173-9794-0DACA46673EF"
9732 >
9733 <desc>
9734 Mouse button state.
9735 </desc>
9736
9737 <const name="LeftButton" value="0x01"/>
9738 <const name="RightButton" value="0x02"/>
9739 <const name="MiddleButton" value="0x04"/>
9740 <const name="WheelUp" value="0x08"/>
9741 <const name="WheelDown" value="0x10"/>
9742 <const name="MouseStateMask" value="0x1F"/>
9743 </enum>
9744
9745 <interface
9746 name="IMouse" extends="$unknown"
9747 uuid="FD443EC1-0006-4F5B-9282-D72760A66916"
9748 wsmap="managed"
9749 >
9750 <desc>
9751 The IMouse interface represents the virtual machine's mouse. Used in
9752 <link to="IConsole::mouse"/>.
9753
9754 Through this interface, the virtual machine's virtual mouse can be
9755 controlled.
9756 </desc>
9757
9758 <attribute name="absoluteSupported" type="boolean" readonly="yes">
9759 <desc>
9760 Whether the guest OS supports absolute mouse pointer positioning
9761 or not.
9762 <note>
9763 VirtualBox Guest Tools need to be installed to the guest OS
9764 in order to enable absolute mouse positioning support.
9765 You can use the <link to="IConsoleCallback::onMouseCapabilityChange"/>
9766 callback to be instantly informed about changes of this attribute
9767 during virtual machine execution.
9768 </note>
9769 <see><link to="#putMouseEventAbsolute"/></see>
9770 </desc>
9771 </attribute>
9772
9773 <method name="putMouseEvent">
9774 <desc>
9775 Initiates a mouse event using relative pointer movements
9776 along x and y axis.
9777
9778 <result name="E_ACCESSDENIED">
9779 Console not powered up.
9780 </result>
9781 <result name="VBOX_E_IPRT_ERROR">
9782 Could not send mouse event to virtual mouse.
9783 </result>
9784
9785 </desc>
9786
9787 <param name="dx" type="long" dir="in">
9788 <desc>
9789 Amount of pixels the mouse should move to the right.
9790 Negative values move the mouse to the left.
9791 </desc>
9792 </param>
9793 <param name="dy" type="long" dir="in">
9794 <desc>
9795 Amount of pixels the mouse should move downwards.
9796 Negative values move the mouse upwards.
9797 </desc>
9798 </param>
9799 <param name="dz" type="long" dir="in">
9800 <desc>
9801 Amount of mouse wheel moves.
9802 Positive values describe clockwise wheel rotations,
9803 negative values describe counterclockwise rotations.
9804 </desc>
9805 </param>
9806 <param name="buttonState" type="long" dir="in">
9807 <desc>
9808 The current state of mouse buttons. Every bit represents
9809 a mouse button as follows:
9810 <table>
9811 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
9812 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
9813 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
9814 </table>
9815 A value of <tt>1</tt> means the corresponding button is pressed.
9816 otherwise it is released.
9817 </desc>
9818 </param>
9819 </method>
9820
9821 <method name="putMouseEventAbsolute">
9822 <desc>
9823 Positions the mouse pointer using absolute x and y coordinates.
9824 These coordinates are expressed in pixels and
9825 start from <tt>[1,1]</tt> which corresponds to the top left
9826 corner of the virtual display.
9827
9828 <result name="E_ACCESSDENIED">
9829 Console not powered up.
9830 </result>
9831 <result name="VBOX_E_IPRT_ERROR">
9832 Could not send mouse event to virtual mouse.
9833 </result>
9834
9835 <note>
9836 This method will have effect only if absolute mouse
9837 positioning is supported by the guest OS.
9838 </note>
9839
9840 <see><link to="#absoluteSupported"/></see>
9841 </desc>
9842
9843 <param name="x" type="long" dir="in">
9844 <desc>
9845 X coordinate of the pointer in pixels, starting from <tt>1</tt>.
9846 </desc>
9847 </param>
9848 <param name="y" type="long" dir="in">
9849 <desc>
9850 Y coordinate of the pointer in pixels, starting from <tt>1</tt>.
9851 </desc>
9852 </param>
9853 <param name="dz" type="long" dir="in">
9854 <desc>
9855 Amount of mouse wheel moves.
9856 Positive values describe clockwise wheel rotations,
9857 negative values describe counterclockwise rotations.
9858 </desc>
9859 </param>
9860 <param name="buttonState" type="long" dir="in">
9861 <desc>
9862 The current state of mouse buttons. Every bit represents
9863 a mouse button as follows:
9864 <table>
9865 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
9866 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
9867 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
9868 </table>
9869 A value of <tt>1</tt> means the corresponding button is pressed.
9870 otherwise it is released.
9871 </desc>
9872 </param>
9873 </method>
9874
9875 </interface>
9876
9877 <!--
9878 // IDisplay
9879 /////////////////////////////////////////////////////////////////////////
9880 -->
9881
9882 <enum
9883 name="FramebufferAccelerationOperation"
9884 uuid="f0e5ebbe-dc8e-4e2d-916e-53baa3844df8"
9885 >
9886 <desc>
9887 Frame buffer acceleration operation.
9888 </desc>
9889
9890 <const name="SolidFillAcceleration" value="1"/>
9891 <const name="ScreenCopyAcceleration" value="2"/>
9892 </enum>
9893
9894 <enum
9895 name="FramebufferPixelFormat"
9896 uuid="7acfd5ed-29e3-45e3-8136-73c9224f3d2d"
9897 >
9898 <desc>
9899 Format of the video memory buffer. Constants represented by this enum can
9900 be used to test for particular values of <link
9901 to="IFramebuffer::pixelFormat"/>. See also <link
9902 to="IFramebuffer::requestResize"/>.
9903
9904 See also www.fourcc.org for more information about FOURCC pixel formats.
9905 </desc>
9906
9907 <const name="Opaque" value="0">
9908 <desc>
9909 Unknown buffer format (the user may not assume any particular format of
9910 the buffer).
9911 </desc>
9912 </const>
9913 <const name="FOURCC_RGB" value="0x32424752">
9914 <desc>
9915 Basic RGB format (<link to="IFramebuffer::bitsPerPixel"/> determines the
9916 bit layout).
9917 </desc>
9918 </const>
9919 </enum>
9920
9921 <interface
9922 name="IFramebuffer" extends="$unknown"
9923 uuid="af431304-5b09-40e2-94da-3c3cb03822c1"
9924 wsmap="suppress"
9925 >
9926 <attribute name="address" type="octet" mod="ptr" readonly="yes">
9927 <desc>Address of the start byte of the frame buffer.</desc>
9928 </attribute>
9929
9930 <attribute name="width" type="unsigned long" readonly="yes">
9931 <desc>Frame buffer width, in pixels.</desc>
9932 </attribute>
9933
9934 <attribute name="height" type="unsigned long" readonly="yes">
9935 <desc>Frame buffer height, in pixels.</desc>
9936 </attribute>
9937
9938 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
9939 <desc>
9940 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
9941 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, valid values
9942 are: 8, 15, 16, 24 and 32.
9943 </desc>
9944 </attribute>
9945
9946 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
9947 <desc>
9948 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
9949 to="FramebufferPixelFormat_FOURCC_RGB">FOURCC_RGB</link>, the
9950 size of the scan line must be aligned to 32 bits.
9951 </desc>
9952 </attribute>
9953
9954 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
9955 <desc>
9956 Frame buffer pixel format. It's either one of the values defined by <link
9957 to="FramebufferPixelFormat"/> or a raw FOURCC code.
9958 <note>
9959 This attribute must never return <link
9960 to="FramebufferPixelFormat_Opaque"/> -- the format of the buffer
9961 <link to="#address"/> points to must be always known.
9962 </note>
9963 </desc>
9964 </attribute>
9965
9966 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
9967 <desc>
9968 Defines whether this frame buffer uses the virtual video card's memory
9969 buffer (guest VRAM) directly or not. See <link
9970 to="IFramebuffer::requestResize"/> for more information.
9971 </desc>
9972 </attribute>
9973
9974 <attribute name="heightReduction" type="unsigned long" readonly="yes">
9975 <desc>
9976 Hint from the frame buffer about how much of the standard
9977 screen height it wants to use for itself. This information is
9978 exposed to the guest through the VESA BIOS and VMMDev interface
9979 so that it can use it for determining its video mode table. It
9980 is not guaranteed that the guest respects the value.
9981 </desc>
9982 </attribute>
9983
9984 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
9985 <desc>
9986 An alpha-blended overlay which is superposed over the frame buffer.
9987 The initial purpose is to allow the display of icons providing
9988 information about the VM state, including disk activity, in front
9989 ends which do not have other means of doing that. The overlay is
9990 designed to controlled exclusively by IDisplay. It has no locking
9991 of its own, and any changes made to it are not guaranteed to be
9992 visible until the affected portion of IFramebuffer is updated. The
9993 overlay can be created lazily the first time it is requested. This
9994 attribute can also return NULL to signal that the overlay is not
9995 implemented.
9996 </desc>
9997 </attribute>
9998
9999 <attribute name="winId" type="unsigned long long" readonly="yes">
10000 <desc>
10001 Platform-dependent identifier of the window where context of this
10002 frame buffer is drawn, or zero if there's no such window.
10003 </desc>
10004 </attribute>
10005
10006 <method name="lock">
10007 <desc>
10008 Locks the frame buffer.
10009 Gets called by the IDisplay object where this frame buffer is
10010 bound to.
10011 </desc>
10012 </method>
10013
10014 <method name="unlock">
10015 <desc>
10016 Unlocks the frame buffer.
10017 Gets called by the IDisplay object where this frame buffer is
10018 bound to.
10019 </desc>
10020 </method>
10021
10022 <method name="notifyUpdate">
10023 <desc>
10024 Informs about an update.
10025 Gets called by the display object where this buffer is
10026 registered.
10027 </desc>
10028 <param name="x" type="unsigned long" dir="in"/>
10029 <param name="y" type="unsigned long" dir="in"/>
10030 <param name="width" type="unsigned long" dir="in"/>
10031 <param name="height" type="unsigned long" dir="in"/>
10032 <param name="finished" type="boolean" dir="return"/>
10033 </method>
10034
10035 <method name="requestResize">
10036 <desc>
10037 Requests a size and pixel format change.
10038
10039 There are two modes of working with the video buffer of the virtual
10040 machine. The <i>indirect</i> mode implies that the IFramebuffer
10041 implementation allocates a memory buffer for the requested display mode
10042 and provides it to the virtual machine. In <i>direct</i> mode, the
10043 IFramebuffer implementation uses the memory buffer allocated and owned
10044 by the virtual machine. This buffer represents the video memory of the
10045 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
10046 usually faster because the implementation gets a raw pointer to the
10047 guest VRAM buffer which it can directly use for visualizing the contents
10048 of the virtual display, as opposed to the indirect mode where the
10049 contents of guest VRAM are copied to the memory buffer provided by
10050 the implementation every time a display update occurs.
10051
10052 It is important to note that the direct mode is really fast only when
10053 the implementation uses the given guest VRAM buffer directly, for
10054 example, by blitting it to the window representing the virtual machine's
10055 display, which saves at least one copy operation comparing to the
10056 indirect mode. However, using the guest VRAM buffer directly is not
10057 always possible: the format and the color depth of this buffer may be
10058 not supported by the target window, or it may be unknown (opaque) as in
10059 case of text or non-linear multi-plane VGA video modes. In this case,
10060 the indirect mode (that is always available) should be used as a
10061 fallback: when the guest VRAM contents are copied to the
10062 implementation-provided memory buffer, color and format conversion is
10063 done automatically by the underlying code.
10064
10065 The @a pixelFormat parameter defines whether the direct mode is
10066 available or not. If @a pixelFormat is <link
10067 to="FramebufferPixelFormat_Opaque"/> then direct access to the guest
10068 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and
10069 @a bytesPerLine parameters must be ignored and the implementation must use
10070 the indirect mode (where it provides its own buffer in one of the
10071 supported formats). In all other cases, @a pixelFormat together with
10072 @a bitsPerPixel and @a bytesPerLine define the format of the video memory
10073 buffer pointed to by the @a VRAM parameter and the implementation is
10074 free to choose which mode to use. To indicate that this frame buffer uses
10075 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
10076 attribute must return <tt>true</tt> and <link to="#address"/> must
10077 return exactly the same address that is passed in the @a VRAM parameter
10078 of this method; otherwise it is assumed that the indirect strategy is
10079 chosen.
10080
10081 The @a width and @a height parameters represent the size of the
10082 requested display mode in both modes. In case of indirect mode, the
10083 provided memory buffer should be big enough to store data of the given
10084 display mode. In case of direct mode, it is guaranteed that the given
10085 @a VRAM buffer contains enough space to represent the display mode of the
10086 given size. Note that this frame buffer's <link to="#width"/> and <link
10087 to="#height"/> attributes must return exactly the same values as
10088 passed to this method after the resize is completed (see below).
10089
10090 The @a finished output parameter determines if the implementation has
10091 finished resizing the frame buffer or not. If, for some reason, the
10092 resize cannot be finished immediately during this call, @a finished
10093 must be set to @c false, and the implementation must call
10094 <link to="IDisplay::resizeCompleted"/> after it has returned from
10095 this method as soon as possible. If @a finished is @c false, the
10096 machine will not call any frame buffer methods until
10097 <link to="IDisplay::resizeCompleted"/> is called.
10098
10099 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
10100 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
10101 this frame buffer must return exactly the same values as specified in the
10102 parameters of this method, after the resize is completed. If the
10103 indirect mode is chosen, these attributes must return values describing
10104 the format of the implementation's own memory buffer <link
10105 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
10106 value must always correlate with <link to="#pixelFormat"/>. Note that
10107 the <link to="#pixelFormat"/> attribute must never return <link
10108 to="FramebufferPixelFormat_Opaque"/> regardless of the selected mode.
10109
10110 <note>
10111 This method is called by the IDisplay object under the
10112 <link to="#lock"/> provided by this IFramebuffer
10113 implementation. If this method returns @c false in @a finished, then
10114 this lock is not released until
10115 <link to="IDisplay::resizeCompleted"/> is called.
10116 </note>
10117 </desc>
10118 <param name="screenId" type="unsigned long" dir="in">
10119 <desc>
10120 Logical screen number. Must be used in the corresponding call to
10121 <link to="IDisplay::resizeCompleted"/> if this call is made.
10122 </desc>
10123 </param>
10124 <param name="pixelFormat" type="unsigned long" dir="in">
10125 <desc>
10126 Pixel format of the memory buffer pointed to by @a VRAM.
10127 See also <link to="FramebufferPixelFormat"/>.
10128 </desc>
10129 </param>
10130 <param name="VRAM" type="octet" mod="ptr" dir="in">
10131 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
10132 </param>
10133 <param name="bitsPerPixel" type="unsigned long" dir="in">
10134 <desc>Color depth, bits per pixel.</desc>
10135 </param>
10136 <param name="bytesPerLine" type="unsigned long" dir="in">
10137 <desc>Size of one scan line, in bytes.</desc>
10138 </param>
10139 <param name="width" type="unsigned long" dir="in">
10140 <desc>Width of the guest display, in pixels.</desc>
10141 </param>
10142 <param name="height" type="unsigned long" dir="in">
10143 <desc>Height of the guest display, in pixels.</desc>
10144 </param>
10145 <param name="finished" type="boolean" dir="return">
10146 <desc>
10147 Can the VM start using the new frame buffer immediately
10148 after this method returns or it should wait for
10149 <link to="IDisplay::resizeCompleted"/>.
10150 </desc>
10151 </param>
10152 </method>
10153
10154 <method name="operationSupported">
10155 <desc>
10156 Returns whether the given acceleration operation is supported
10157 by the IFramebuffer implementation. If not, the display object
10158 will not attempt to call the corresponding IFramebuffer entry
10159 point. Even if an operation is indicated as supported, the
10160 IFramebuffer implementation always has the option to return non
10161 supported from the corresponding acceleration method in which
10162 case the operation will be performed by the display engine. This
10163 allows for reduced IFramebuffer implementation complexity where
10164 only common cases are handled.
10165 </desc>
10166 <param name="operation" type="FramebufferAccelerationOperation" dir="in"/>
10167 <param name="supported" type="boolean" dir="return"/>
10168 </method>
10169
10170 <method name="videoModeSupported">
10171 <desc>
10172 Returns whether the frame buffer implementation is willing to
10173 support a given video mode. In case it is not able to render
10174 the video mode (or for some reason not willing), it should
10175 return false. Usually this method is called when the guest
10176 asks the VMM device whether a given video mode is supported
10177 so the information returned is directly exposed to the guest.
10178 It is important that this method returns very quickly.
10179 </desc>
10180 <param name="width" type="unsigned long" dir="in"/>
10181 <param name="height" type="unsigned long" dir="in"/>
10182 <param name="bpp" type="unsigned long" dir="in"/>
10183 <param name="supported" type="boolean" dir="return"/>
10184 </method>
10185
10186 <method name="solidFill">
10187 <desc>
10188 Fills the specified rectangle on screen with a solid color.
10189 </desc>
10190 <param name="x" type="unsigned long" dir="in"/>
10191 <param name="y" type="unsigned long" dir="in"/>
10192 <param name="width" type="unsigned long" dir="in"/>
10193 <param name="height" type="unsigned long" dir="in"/>
10194 <param name="color" type="unsigned long" dir="in"/>
10195 <param name="handled" type="boolean" dir="return"/>
10196 </method>
10197
10198 <method name="copyScreenBits">
10199 <desc>
10200 Copies specified rectangle on the screen.
10201 </desc>
10202 <param name="xDst" type="unsigned long" dir="in"/>
10203 <param name="yDst" type="unsigned long" dir="in"/>
10204 <param name="xSrc" type="unsigned long" dir="in"/>
10205 <param name="ySrc" type="unsigned long" dir="in"/>
10206 <param name="width" type="unsigned long" dir="in"/>
10207 <param name="height" type="unsigned long" dir="in"/>
10208 <param name="handled" type="boolean" dir="return"/>
10209 </method>
10210
10211 <method name="getVisibleRegion">
10212 <desc>
10213 Returns the visible region of this frame buffer.
10214
10215 If the @a rectangles parameter is <tt>NULL</tt> then the value of the
10216 @a count parameter is ignored and the number of elements necessary to
10217 describe the current visible region is returned in @a countCopied.
10218
10219 If @a rectangles is not <tt>NULL</tt> but @a count is less
10220 than the required number of elements to store region data, the method
10221 will report a failure. If @a count is equal or greater than the
10222 required number of elements, then the actual number of elements copied
10223 to the provided array will be returned in @a countCopied.
10224
10225 <note>
10226 The address of the provided array must be in the process space of
10227 this IFramebuffer object.
10228 </note>
10229 <note>
10230 Method not yet implemented.
10231 </note>
10232 </desc>
10233 <param name="rectangles" type="octet" mod="ptr" dir="in">
10234 <desc>Pointer to the <tt>RTRECT</tt> array to receive region data.</desc>
10235 </param>
10236 <param name="count" type="unsigned long" dir="in">
10237 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10238 </param>
10239 <param name="countCopied" type="unsigned long" dir="return">
10240 <desc>Number of elements copied to the @a rectangles array.</desc>
10241 </param>
10242 </method>
10243
10244 <method name="setVisibleRegion">
10245 <desc>
10246 Suggests a new visible region to this frame buffer. This region
10247 represents the area of the VM display which is a union of regions of
10248 all top-level windows of the guest operating system running inside the
10249 VM (if the Guest Additions for this system support this
10250 functionality). This information may be used by the frontends to
10251 implement the seamless desktop integration feature.
10252
10253 <note>
10254 The address of the provided array must be in the process space of
10255 this IFramebuffer object.
10256 </note>
10257 <note>
10258 The IFramebuffer implementation must make a copy of the provided
10259 array of rectangles.
10260 </note>
10261 <note>
10262 Method not yet implemented.
10263 </note>
10264 </desc>
10265 <param name="rectangles" type="octet" mod="ptr" dir="in">
10266 <desc>Pointer to the <tt>RTRECT</tt> array.</desc>
10267 </param>
10268 <param name="count" type="unsigned long" dir="in">
10269 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
10270 </param>
10271 </method>
10272
10273 </interface>
10274
10275 <interface
10276 name="IFramebufferOverlay" extends="IFramebuffer"
10277 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
10278 wsmap="suppress"
10279 >
10280 <desc>
10281 The IFramebufferOverlay interface represents an alpha blended overlay
10282 for displaying status icons above an IFramebuffer. It is always created
10283 not visible, so that it must be explicitly shown. It only covers a
10284 portion of the IFramebuffer, determined by its width, height and
10285 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
10286 that order) format, and may be written to directly. Do re-read the
10287 width though, after setting it, as it may be adjusted (increased) to
10288 make it more suitable for the front end.
10289 </desc>
10290 <attribute name="x" type="unsigned long" readonly="yes">
10291 <desc>X position of the overlay, relative to the frame buffer.</desc>
10292 </attribute>
10293
10294 <attribute name="y" type="unsigned long" readonly="yes">
10295 <desc>Y position of the overlay, relative to the frame buffer.</desc>
10296 </attribute>
10297
10298 <attribute name="visible" type="boolean" readonly="no">
10299 <desc>
10300 Whether the overlay is currently visible.
10301 </desc>
10302 </attribute>
10303
10304 <attribute name="alpha" type="unsigned long" readonly="no">
10305 <desc>
10306 The global alpha value for the overlay. This may or may not be
10307 supported by a given front end.
10308 </desc>
10309 </attribute>
10310
10311 <method name="move">
10312 <desc>
10313 Changes the overlay's position relative to the IFramebuffer.
10314 </desc>
10315 <param name="x" type="unsigned long" dir="in"/>
10316 <param name="y" type="unsigned long" dir="in"/>
10317 </method>
10318
10319 </interface>
10320
10321 <interface
10322 name="IDisplay" extends="$unknown"
10323 uuid="09789f63-4525-48e5-a5e4-1080453b0eab"
10324 wsmap="suppress"
10325 >
10326 <desc>
10327 The IDisplay interface represents the virtual machine's display.
10328
10329 The object implementing this interface is contained in each
10330 <link to="IConsole::display"/> attribute and represents the visual
10331 output of the virtual machine.
10332
10333 The virtual display supports pluggable output targets represented by the
10334 IFramebuffer interface. Examples of the output target are a window on
10335 the host computer or an RDP session's display on a remote computer.
10336 </desc>
10337 <attribute name="width" type="unsigned long" readonly="yes">
10338 <desc>Current display width.</desc>
10339 </attribute>
10340
10341 <attribute name="height" type="unsigned long" readonly="yes">
10342 <desc>Current display height.</desc>
10343 </attribute>
10344
10345 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
10346 <desc>
10347 Current guest display color depth. Note that this may differ
10348 from <link to="IFramebuffer::bitsPerPixel"/>.
10349 </desc>
10350 </attribute>
10351
10352 <method name="setupInternalFramebuffer">
10353 <desc>
10354 Prepares an internally managed frame buffer.
10355 </desc>
10356 <param name="depth" type="unsigned long" dir="in"/>
10357 </method>
10358
10359 <method name="lockFramebuffer">
10360 <desc>
10361 Requests access to the internal frame buffer.
10362
10363 <result name="VBOX_E_NOT_SUPPORTED">
10364 Attempt to lock a non-internal frame buffer.
10365 </result>
10366
10367 </desc>
10368 <param name="address" type="octet" mod="ptr" dir="return"/>
10369 </method>
10370
10371 <method name="unlockFramebuffer">
10372 <desc>
10373 Releases access to the internal frame buffer.
10374
10375 <result name="VBOX_E_NOT_SUPPORTED">
10376 Attempt to unlock a non-internal frame buffer.
10377 </result>
10378
10379 </desc>
10380 </method>
10381
10382 <method name="registerExternalFramebuffer">
10383 <desc>
10384 Registers an external frame buffer.
10385 </desc>
10386 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10387 </method>
10388
10389 <method name="setFramebuffer">
10390 <desc>
10391 Sets the framebuffer for given screen.
10392 </desc>
10393 <param name="screenId" type="unsigned long" dir="in"/>
10394 <param name="framebuffer" type="IFramebuffer" dir="in"/>
10395 </method>
10396
10397 <method name="getFramebuffer">
10398 <desc>
10399 Queries the framebuffer for given screen.
10400 </desc>
10401 <param name="screenId" type="unsigned long" dir="in"/>
10402 <param name="framebuffer" type="IFramebuffer" dir="out"/>
10403 <param name="xOrigin" type="long" dir="out"/>
10404 <param name="yOrigin" type="long" dir="out"/>
10405 </method>
10406
10407 <method name="setVideoModeHint">
10408 <desc>
10409 Asks VirtualBox to request the given video mode from
10410 the guest. This is just a hint and it cannot be guaranteed
10411 that the requested resolution will be used. Guest Additions
10412 are required for the request to be seen by guests. The caller
10413 should issue the request and wait for a resolution change and
10414 after a timeout retry.
10415
10416 Specifying <tt>0</tt> for either @a width, @a height or @a bitsPerPixel
10417 parameters means that the corresponding values should be taken from the
10418 current video mode (i.e. left unchanged).
10419
10420 If the guest OS supports multi-monitor configuration then the @a display
10421 parameter specifies the number of the guest display to send the hint to:
10422 <tt>0</tt> is the primary display, <tt>1</tt> is the first secondary and
10423 so on. If the multi-monitor configuration is not supported, @a display
10424 must be <tt>0</tt>.
10425
10426 <result name="E_INVALIDARG">
10427 The @a display is not associated with any monitor.
10428 </result>
10429
10430 </desc>
10431 <param name="width" type="unsigned long" dir="in"/>
10432 <param name="height" type="unsigned long" dir="in"/>
10433 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
10434 <param name="display" type="unsigned long" dir="in"/>
10435 </method>
10436
10437 <method name="setSeamlessMode">
10438 <desc>
10439 Enables or disables seamless guest display rendering (seamless desktop
10440 integration) mode.
10441 <note>
10442 Calling this method has no effect if <link
10443 to="IGuest::supportsSeamless"/> returns <tt>false</tt>.
10444 </note>
10445 </desc>
10446 <param name="enabled" type="boolean" dir="in"/>
10447 </method>
10448
10449 <method name="takeScreenShot">
10450 <desc>
10451 Takes a screen shot of the requested size and copies it to the
10452 32-bpp buffer allocated by the caller.
10453
10454 <result name="E_NOTIMPL">
10455 Feature not implemented.
10456 </result>
10457 <result name="VBOX_E_IPRT_ERROR">
10458 Could not take a screenshot.
10459 </result>
10460
10461 </desc>
10462 <param name="address" type="octet" mod="ptr" dir="in"/>
10463 <param name="width" type="unsigned long" dir="in"/>
10464 <param name="height" type="unsigned long" dir="in"/>
10465 </method>
10466
10467 <method name="drawToScreen">
10468 <desc>
10469 Draws a 32-bpp image of the specified size from the given buffer
10470 to the given point on the VM display.
10471
10472 <result name="E_NOTIMPL">
10473 Feature not implemented.
10474 </result>
10475 <result name="VBOX_E_IPRT_ERROR">
10476 Could not draw to screen.
10477 </result>
10478
10479 </desc>
10480 <param name="address" type="octet" mod="ptr" dir="in"/>
10481 <param name="x" type="unsigned long" dir="in"/>
10482 <param name="y" type="unsigned long" dir="in"/>
10483 <param name="width" type="unsigned long" dir="in"/>
10484 <param name="height" type="unsigned long" dir="in"/>
10485 </method>
10486
10487 <method name="invalidateAndUpdate">
10488 <desc>
10489 Does a full invalidation of the VM display and instructs the VM
10490 to update it.
10491
10492 <result name="VBOX_E_IPRT_ERROR">
10493 Could not invalidate and update screen.
10494 </result>
10495
10496 </desc>
10497 </method>
10498
10499 <method name="resizeCompleted">
10500 <desc>
10501 Signals that a framebuffer has completed the resize operation.
10502
10503 <result name="VBOX_E_NOT_SUPPORTED">
10504 Operation only valid for external frame buffers.
10505 </result>
10506
10507 </desc>
10508 <param name="screenId" type="unsigned long" dir="in"/>
10509 </method>
10510
10511 <method name="updateCompleted">
10512 <desc>
10513 Signals that a framebuffer has completed the update operation.
10514
10515 <result name="VBOX_E_NOT_SUPPORTED">
10516 Operation only valid for external frame buffers.
10517 </result>
10518
10519 </desc>
10520 </method>
10521
10522 </interface>
10523
10524 <!--
10525 // INetworkAdapter
10526 /////////////////////////////////////////////////////////////////////////
10527 -->
10528
10529 <enum
10530 name="NetworkAttachmentType"
10531 uuid="44bce1ee-99f7-4e8e-89fc-80597fd9eeaf"
10532 >
10533 <desc>
10534 Network attachment type.
10535 </desc>
10536
10537 <const name="Null" value="0">
10538 <desc>Null value, also means "not attached".</desc>
10539 </const>
10540 <const name="NAT" value="1"/>
10541 <const name="Bridged" value="2"/>
10542 <const name="Internal" value="3"/>
10543 <const name="HostOnly" value="4"/>
10544 </enum>
10545
10546 <enum
10547 name="NetworkAdapterType"
10548 uuid="156b17b9-5d61-4d54-be90-62e37dda848d"
10549 >
10550 <desc>
10551 Network adapter type.
10552 </desc>
10553
10554 <const name="Null" value="0">
10555 <desc>Null value (never used by the API).</desc>
10556 </const>
10557 <const name="Am79C970A" value="1"/>
10558 <const name="Am79C973" value="2"/>
10559 <const name="I82540EM" value="3"/>
10560 <const name="I82543GC" value="4"/>
10561 </enum>
10562
10563 <interface
10564 name="INetworkAdapter" extends="$unknown"
10565 uuid="65607a27-2b73-4d43-b4cc-0ba2c817fbde"
10566 wsmap="managed"
10567 >
10568 <desc>
10569 Represents a virtual network adapter that is attached to a virtual machine.
10570 Each virtual machine has a fixed number of network adapter slots with one
10571 instance of this attached to each of them. Call
10572 <link to="IMachine::getNetworkAdapter" /> to get the network adapter that
10573 is attached to a given slot in a given machine.
10574
10575 Each network adapter can be in one of five attachment modes, which are
10576 represented by the <link to="NetworkAttachmentType" /> enumeration;
10577 see the <link to="#attachmentType" /> attribute.
10578 </desc>
10579
10580 <attribute name="adapterType" type="NetworkAdapterType">
10581 <desc>
10582 Type of the virtual network adapter. Depending on this value,
10583 VirtualBox will provide a different virtual network hardware
10584 to the guest.
10585 </desc>
10586 </attribute>
10587
10588 <attribute name="slot" type="unsigned long" readonly="yes">
10589 <desc>
10590 Slot number this adapter is plugged into. Corresponds to
10591 the value you pass to <link to="IMachine::getNetworkAdapter"/>
10592 to obtain this instance.
10593 </desc>
10594 </attribute>
10595
10596 <attribute name="enabled" type="boolean">
10597 <desc>
10598 Flag whether the network adapter is present in the
10599 guest system. If disabled, the virtual guest hardware will
10600 not contain this network adapter. Can only be changed when
10601 the VM is not running.
10602 </desc>
10603 </attribute>
10604
10605 <attribute name="MACAddress" type="wstring">
10606 <desc>
10607 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
10608 it to NULL, VirtualBox will generate a unique MAC address.
10609 </desc>
10610 </attribute>
10611
10612 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
10613
10614 <attribute name="hostInterface" type="wstring">
10615 <desc>
10616 Name of the host network interface the VM is attached to.
10617 </desc>
10618 </attribute>
10619
10620 <attribute name="internalNetwork" type="wstring">
10621 <desc>
10622 Name of the internal network the VM is attached to.
10623 </desc>
10624 </attribute>
10625
10626 <attribute name="NATNetwork" type="wstring">
10627 <desc>
10628 Name of the NAT network the VM is attached to.
10629 </desc>
10630 </attribute>
10631
10632 <attribute name="cableConnected" type="boolean">
10633 <desc>
10634 Flag whether the adapter reports the cable as connected or not.
10635 It can be used to report offline situations to a VM.
10636 </desc>
10637 </attribute>
10638
10639 <attribute name="lineSpeed" type="unsigned long">
10640 <desc>
10641 Line speed reported by custom drivers, in units of 1 kbps.
10642 </desc>
10643 </attribute>
10644
10645 <attribute name="traceEnabled" type="boolean">
10646 <desc>
10647 Flag whether network traffic from/to the network card should be traced.
10648 Can only be toggled when the VM is turned off.
10649 </desc>
10650 </attribute>
10651
10652 <attribute name="traceFile" type="wstring">
10653 <desc>
10654 Filename where a network trace will be stored. If not set, VBox-pid.pcap
10655 will be used.
10656 </desc>
10657 </attribute>
10658
10659 <method name="attachToNAT">
10660 <desc>
10661 Attach the network adapter to the Network Address Translation (NAT) interface.
10662 </desc>
10663 </method>
10664
10665 <method name="attachToBridgedInterface">
10666 <desc>
10667 Attach the network adapter to a bridged host interface.
10668 </desc>
10669 </method>
10670
10671 <method name="attachToInternalNetwork">
10672 <desc>
10673 Attach the network adapter to an internal network.
10674 </desc>
10675 </method>
10676
10677 <method name="attachToHostOnlyInterface">
10678 <desc>
10679 Attach the network adapter to the host-only network.
10680 </desc>
10681 </method>
10682
10683 <method name="detach">
10684 <desc>
10685 Detach the network adapter
10686 </desc>
10687 </method>
10688 </interface>
10689
10690
10691 <!--
10692 // ISerialPort
10693 /////////////////////////////////////////////////////////////////////////
10694 -->
10695
10696 <enum
10697 name="PortMode"
10698 uuid="b266f43c-2e93-46b3-812b-c20e600e867b"
10699 >
10700 <desc>
10701 The PortMode enumeration represents possible communication modes for
10702 the virtual serial port device.
10703 </desc>
10704
10705 <const name="Disconnected" value="0">
10706 <desc>Virtual device is not attached to any real host device.</desc>
10707 </const>
10708 <const name="HostPipe" value="1">
10709 <desc>Virtual device is attached to a host pipe.</desc>
10710 </const>
10711 <const name="HostDevice" value="2">
10712 <desc>Virtual device is attached to a host device.</desc>
10713 </const>
10714 </enum>
10715
10716 <interface
10717 name="ISerialPort" extends="$unknown"
10718 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
10719 wsmap="managed"
10720 >
10721
10722 <desc>
10723 The ISerialPort interface represents the virtual serial port device.
10724
10725 The virtual serial port device acts like an ordinary serial port
10726 inside the virtual machine. This device communicates to the real
10727 serial port hardware in one of two modes: host pipe or host device.
10728
10729 In host pipe mode, the #path attribute specifies the path to the pipe on
10730 the host computer that represents a serial port. The #server attribute
10731 determines if this pipe is created by the virtual machine process at
10732 machine startup or it must already exist before starting machine
10733 execution.
10734
10735 In host device mode, the #path attribute specifies the name of the
10736 serial port device on the host computer.
10737
10738 There is also a third communication mode: the disconnected mode. In this
10739 mode, the guest OS running inside the virtual machine will be able to
10740 detect the serial port, but all port write operations will be discarded
10741 and all port read operations will return no data.
10742
10743 <see>IMachine::getSerialPort</see>
10744 </desc>
10745
10746 <attribute name="slot" type="unsigned long" readonly="yes">
10747 <desc>
10748 Slot number this serial port is plugged into. Corresponds to
10749 the value you pass to <link to="IMachine::getSerialPort"/>
10750 to obtain this instance.
10751 </desc>
10752 </attribute>
10753
10754 <attribute name="enabled" type="boolean">
10755 <desc>
10756 Flag whether the serial port is enabled. If disabled,
10757 the serial port will not be reported to the guest OS.
10758 </desc>
10759 </attribute>
10760
10761 <attribute name="IOBase" type="unsigned long">
10762 <desc>Base I/O address of the serial port.</desc>
10763 </attribute>
10764
10765 <attribute name="IRQ" type="unsigned long">
10766 <desc>IRQ number of the serial port.</desc>
10767 </attribute>
10768
10769 <attribute name="hostMode" type="PortMode">
10770 <desc>
10771 How is this port connected to the host.
10772 <note>
10773 Changing this attribute may fail if the conditions for
10774 <link to="#path"/> are not met.
10775 </note>
10776 </desc>
10777 </attribute>
10778
10779 <attribute name="server" type="boolean">
10780 <desc>
10781 Flag whether this serial port acts as a server (creates a new pipe on
10782 the host) or as a client (uses the existing pipe). This attribute is
10783 used only when <link to="#hostMode"/> is PortMode_HostPipe.
10784 </desc>
10785 </attribute>
10786
10787 <attribute name="path" type="wstring">
10788 <desc>
10789 Path to the serial port's pipe on the host when <link to="#hostMode"/> is
10790 PortMode_HostPipe, or the host serial device name when
10791 <link to="#hostMode"/> is PortMode_HostDevice. In either of the above
10792 cases, setting a @c null or an empty string as the attribute's value
10793 will result into an error. Otherwise, the value of this property is
10794 ignored.
10795 </desc>
10796 </attribute>
10797
10798 </interface>
10799
10800 <!--
10801 // IParallelPort
10802 /////////////////////////////////////////////////////////////////////////
10803 -->
10804
10805 <interface
10806 name="IParallelPort" extends="$unknown"
10807 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
10808 wsmap="managed"
10809 >
10810
10811 <desc>
10812 The IParallelPort interface represents the virtual parallel port device.
10813
10814 The virtual parallel port device acts like an ordinary parallel port
10815 inside the virtual machine. This device communicates to the real
10816 parallel port hardware using the name of the parallel device on the host
10817 computer specified in the #path attribute.
10818
10819 Each virtual parallel port device is assigned a base I/O address and an
10820 IRQ number that will be reported to the guest operating system and used
10821 to operate the given parallel port from within the virtual machine.
10822
10823 <see>IMachine::getParallelPort</see>
10824 </desc>
10825
10826 <attribute name="slot" type="unsigned long" readonly="yes">
10827 <desc>
10828 Slot number this parallel port is plugged into. Corresponds to
10829 the value you pass to <link to="IMachine::getParallelPort"/>
10830 to obtain this instance.
10831 </desc>
10832 </attribute>
10833
10834 <attribute name="enabled" type="boolean">
10835 <desc>
10836 Flag whether the parallel port is enabled. If disabled,
10837 the parallel port will not be reported to the guest OS.
10838 </desc>
10839 </attribute>
10840
10841 <attribute name="IOBase" type="unsigned long">
10842 <desc>Base I/O address of the parallel port.</desc>
10843 </attribute>
10844
10845 <attribute name="IRQ" type="unsigned long">
10846 <desc>IRQ number of the parallel port.</desc>
10847 </attribute>
10848
10849 <attribute name="path" type="wstring">
10850 <desc>
10851 Host parallel device name. If this parallel port is enabled, setting a
10852 @c null or an empty string as this attribute's value will result into
10853 an error.
10854 </desc>
10855 </attribute>
10856
10857 </interface>
10858
10859
10860 <!--
10861 // IMachineDebugger
10862 /////////////////////////////////////////////////////////////////////////
10863 -->
10864
10865 <interface
10866 name="IMachineDebugger" extends="$unknown"
10867 uuid="b0b2a2dd-0627-4502-91c2-ddc5e77609e0"
10868 wsmap="suppress"
10869 >
10870 <method name="resetStats">
10871 <desc>
10872 Reset VM statistics.
10873 </desc>
10874 <param name="pattern" type="wstring" dir="in">
10875 <desc>The selection pattern. A bit similar to filename globbing.</desc>
10876 </param>
10877 </method>
10878
10879 <method name="dumpStats">
10880 <desc>
10881 Dumps VM statistics.
10882 </desc>
10883 <param name="pattern" type="wstring" dir="in">
10884 <desc>The selection pattern. A bit similar to filename globbing.</desc>
10885 </param>
10886 </method>
10887
10888 <method name="getStats">
10889 <desc>
10890 Get the VM statistics in a XMLish format.
10891 </desc>
10892 <param name="pattern" type="wstring" dir="in">
10893 <desc>The selection pattern. A bit similar to filename globbing.</desc>
10894 </param>
10895 <param name="withDescriptions" type="boolean" dir="in">
10896 <desc>Whether to include the descriptions.</desc>
10897 </param>
10898 <param name="stats" type="wstring" dir="out">
10899 <desc>The XML document containing the statistics.</desc>
10900 </param>
10901 </method>
10902
10903 <method name="injectNMI">
10904 <desc>
10905 Inject an NMI into a running VT-x/AMD-V VM.
10906 </desc>
10907 </method>
10908
10909 <attribute name="singlestep" type="boolean">
10910 <desc>Switch for enabling singlestepping.</desc>
10911 </attribute>
10912
10913 <attribute name="recompileUser" type="boolean">
10914 <desc>Switch for forcing code recompilation for user mode code.</desc>
10915 </attribute>
10916
10917 <attribute name="recompileSupervisor" type="boolean">
10918 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
10919 </attribute>
10920
10921 <attribute name="PATMEnabled" type="boolean">
10922 <desc>Switch for enabling and disabling the PATM component.</desc>
10923 </attribute>
10924
10925 <attribute name="CSAMEnabled" type="boolean">
10926 <desc>Switch for enabling and disabling the CSAM component.</desc>
10927 </attribute>
10928
10929 <attribute name="logEnabled" type="boolean">
10930 <desc>Switch for enabling and disabling logging.</desc>
10931 </attribute>
10932
10933 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
10934 <desc>
10935 Flag indicating whether the VM is currently making use of CPU hardware
10936 virtualization extensions.
10937 </desc>
10938 </attribute>
10939
10940 <attribute name="HWVirtExNestedPagingEnabled" type="boolean" readonly="yes">
10941 <desc>
10942 Flag indicating whether the VM is currently making use of the nested paging
10943 CPU hardware virtualization extension.
10944 </desc>
10945 </attribute>
10946
10947 <attribute name="HWVirtExVPIDEnabled" type="boolean" readonly="yes">
10948 <desc>
10949 Flag indicating whether the VM is currently making use of the VPID
10950 VT-x extension.
10951 </desc>
10952 </attribute>
10953
10954 <attribute name="PAEEnabled" type="boolean" readonly="yes">
10955 <desc>
10956 Flag indicating whether the VM is currently making use of the Physical
10957 Address Extension CPU feature.
10958 </desc>
10959 </attribute>
10960
10961 <attribute name="virtualTimeRate" type="unsigned long">
10962 <desc>
10963 The rate at which the virtual time runs expressed as a percentage.
10964 The accepted range is 2% to 20000%.
10965 </desc>
10966 </attribute>
10967
10968 <!-- @todo method for setting log flags, groups and destination! -->
10969
10970 <attribute name="VM" type="unsigned long long" readonly="yes">
10971 <desc>
10972 Gets the VM handle. This is only for internal use while
10973 we carve the details of this interface.
10974 </desc>
10975 </attribute>
10976
10977 </interface>
10978
10979 <!--
10980 // IUSBController
10981 /////////////////////////////////////////////////////////////////////////
10982 -->
10983
10984 <interface
10985 name="IUSBController" extends="$unknown"
10986 uuid="238540fa-4b73-435a-a38e-4e1d9eab5c17"
10987 wsmap="managed"
10988 >
10989 <attribute name="enabled" type="boolean">
10990 <desc>
10991 Flag whether the USB controller is present in the
10992 guest system. If disabled, the virtual guest hardware will
10993 not contain any USB controller. Can only be changed when
10994 the VM is powered off.
10995 </desc>
10996 </attribute>
10997
10998 <attribute name="enabledEhci" type="boolean">
10999 <desc>
11000 Flag whether the USB EHCI controller is present in the
11001 guest system. If disabled, the virtual guest hardware will
11002 not contain a USB EHCI controller. Can only be changed when
11003 the VM is powered off.
11004 </desc>
11005 </attribute>
11006
11007 <attribute name="USBStandard" type="unsigned short" readonly="yes">
11008 <desc>
11009 USB standard version which the controller implements.
11010 This is a BCD which means that the major version is in the
11011 high byte and minor version is in the low byte.
11012 </desc>
11013 </attribute>
11014
11015 <attribute name="deviceFilters" type="IUSBDeviceFilter" readonly="yes" safearray="yes">
11016 <desc>
11017 List of USB device filters associated with the machine.
11018
11019 If the machine is currently running, these filters are activated
11020 every time a new (supported) USB device is attached to the host
11021 computer that was not ignored by global filters
11022 (<link to="IHost::USBDeviceFilters"/>).
11023
11024 These filters are also activated when the machine is powered up.
11025 They are run against a list of all currently available USB
11026 devices (in states
11027 <link to="USBDeviceState_Available"/>,
11028 <link to="USBDeviceState_Busy"/>,
11029 <link to="USBDeviceState_Held"/>) that were not previously
11030 ignored by global filters.
11031
11032 If at least one filter matches the USB device in question, this
11033 device is automatically captured (attached to) the virtual USB
11034 controller of this machine.
11035
11036 <see>IUSBDeviceFilter, ::IUSBController</see>
11037 </desc>
11038 </attribute>
11039
11040 <method name="createDeviceFilter">
11041 <desc>
11042 Creates a new USB device filter. All attributes except
11043 the filter name are set to <tt>null</tt> (any match),
11044 <i>active</i> is <tt>false</tt> (the filter is not active).
11045
11046 The created filter can then be added to the list of filters using
11047 <link to="#insertDeviceFilter"/>.
11048
11049 <result name="VBOX_E_INVALID_VM_STATE">
11050 The virtual machine is not mutable.
11051 </result>
11052
11053 <see>#deviceFilters</see>
11054 </desc>
11055 <param name="name" type="wstring" dir="in">
11056 <desc>
11057 Filter name. See <link to="IUSBDeviceFilter::name"/>
11058 for more info.
11059 </desc>
11060 </param>
11061 <param name="filter" type="IUSBDeviceFilter" dir="return">
11062 <desc>Created filter object.</desc>
11063 </param>
11064 </method>
11065
11066 <method name="insertDeviceFilter">
11067 <desc>
11068 Inserts the given USB device to the specified position
11069 in the list of filters.
11070
11071 Positions are numbered starting from <tt>0</tt>. If the specified
11072 position is equal to or greater than the number of elements in
11073 the list, the filter is added to the end of the collection.
11074
11075 <note>
11076 Duplicates are not allowed, so an attempt to insert a
11077 filter that is already in the collection, will return an
11078 error.
11079 </note>
11080
11081 <result name="VBOX_E_INVALID_VM_STATE">
11082 Virtual machine is not mutable.
11083 </result>
11084 <result name="E_INVALIDARG">
11085 USB device filter not created within this VirtualBox instance.
11086 </result>
11087 <result name="VBOX_E_INVALID_OBJECT_STATE">
11088 USB device filter already in list.
11089 </result>
11090
11091 <see>#deviceFilters</see>
11092 </desc>
11093 <param name="position" type="unsigned long" dir="in">
11094 <desc>Position to insert the filter to.</desc>
11095 </param>
11096 <param name="filter" type="IUSBDeviceFilter" dir="in">
11097 <desc>USB device filter to insert.</desc>
11098 </param>
11099 </method>
11100
11101 <method name="removeDeviceFilter">
11102 <desc>
11103 Removes a USB device filter from the specified position in the
11104 list of filters.
11105
11106 Positions are numbered starting from <tt>0</tt>. Specifying a
11107 position equal to or greater than the number of elements in
11108 the list will produce an error.
11109
11110 <see>#deviceFilters</see>
11111
11112 <result name="VBOX_E_INVALID_VM_STATE">
11113 Virtual machine is not mutable.
11114 </result>
11115 <result name="E_INVALIDARG">
11116 USB device filter list empty or invalid @a position.
11117 </result>
11118
11119 </desc>
11120 <param name="position" type="unsigned long" dir="in">
11121 <desc>Position to remove the filter from.</desc>
11122 </param>
11123 <param name="filter" type="IUSBDeviceFilter" dir="return">
11124 <desc>Removed USB device filter.</desc>
11125 </param>
11126 </method>
11127
11128 </interface>
11129
11130
11131 <!--
11132 // IUSBDevice
11133 /////////////////////////////////////////////////////////////////////////
11134 -->
11135
11136 <interface
11137 name="IUSBDevice" extends="$unknown"
11138 uuid="850af07b-9ee8-48c2-b6b0-f6d0acbf63c3"
11139 wsmap="managed"
11140 >
11141 <desc>
11142 The IUSBDevice interface represents a virtual USB device attached to the
11143 virtual machine.
11144
11145 A collection of objects implementing this interface is stored in the
11146 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
11147 attached to a running virtual machine's USB controller.
11148 </desc>
11149
11150 <attribute name="id" type="uuid" readonly="yes">
11151 <desc>
11152 Unique USB device ID. This ID is built from #vendorId,
11153 #productId, #revision and #serialNumber.
11154 </desc>
11155 </attribute>
11156
11157 <attribute name="vendorId" type="unsigned short" readonly="yes">
11158 <desc>Vendor ID.</desc>
11159 </attribute>
11160
11161 <attribute name="productId" type="unsigned short" readonly="yes">
11162 <desc>Product ID.</desc>
11163 </attribute>
11164
11165 <attribute name="revision" type="unsigned short" readonly="yes">
11166 <desc>
11167 Product revision number. This is a packed BCD represented as
11168 unsigned short. The high byte is the integer part and the low
11169 byte is the decimal.
11170 </desc>
11171 </attribute>
11172
11173 <attribute name="manufacturer" type="wstring" readonly="yes">
11174 <desc>Manufacturer string.</desc>
11175 </attribute>
11176
11177 <attribute name="product" type="wstring" readonly="yes">
11178 <desc>Product string.</desc>
11179 </attribute>
11180
11181 <attribute name="serialNumber" type="wstring" readonly="yes">
11182 <desc>Serial number string.</desc>
11183 </attribute>
11184
11185 <attribute name="address" type="wstring" readonly="yes">
11186 <desc>Host specific address of the device.</desc>
11187 </attribute>
11188
11189 <attribute name="port" type="unsigned short" readonly="yes">
11190 <desc>
11191 Host USB port number the device is physically
11192 connected to.
11193 </desc>
11194 </attribute>
11195
11196 <attribute name="version" type="unsigned short" readonly="yes">
11197 <desc>
11198 The major USB version of the device - 1 or 2.
11199 </desc>
11200 </attribute>
11201
11202 <attribute name="portVersion" type="unsigned short" readonly="yes">
11203 <desc>
11204 The major USB version of the host USB port the device is
11205 physically connected to - 1 or 2. For devices not connected to
11206 anything this will have the same value as the version attribute.
11207 </desc>
11208 </attribute>
11209
11210 <attribute name="remote" type="boolean" readonly="yes">
11211 <desc>
11212 Whether the device is physically connected to a remote VRDP
11213 client or to a local host machine.
11214 </desc>
11215 </attribute>
11216
11217 </interface>
11218
11219
11220 <!--
11221 // IUSBDeviceFilter
11222 /////////////////////////////////////////////////////////////////////////
11223 -->
11224
11225 <interface
11226 name="IUSBDeviceFilter" extends="$unknown"
11227 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
11228 wsmap="managed"
11229 >
11230 <desc>
11231 The IUSBDeviceFilter interface represents an USB device filter used
11232 to perform actions on a group of USB devices.
11233
11234 This type of filters is used by running virtual machines to
11235 automatically capture selected USB devices once they are physically
11236 attached to the host computer.
11237
11238 A USB device is matched to the given device filter if and only if all
11239 attributes of the device match the corresponding attributes of the
11240 filter (that is, attributes are joined together using the logical AND
11241 operation). On the other hand, all together, filters in the list of
11242 filters carry the semantics of the logical OR operation. So if it is
11243 desirable to create a match like "this vendor id OR this product id",
11244 one needs to create two filters and specify "any match" (see below)
11245 for unused attributes.
11246
11247 All filter attributes used for matching are strings. Each string
11248 is an expression representing a set of values of the corresponding
11249 device attribute, that will match the given filter. Currently, the
11250 following filtering expressions are supported:
11251
11252 <ul>
11253 <li><i>Interval filters</i>. Used to specify valid intervals for
11254 integer device attributes (Vendor ID, Product ID and Revision).
11255 The format of the string is:
11256
11257 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
11258
11259 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
11260 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
11261 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
11262 is omitted before a dash (<tt>-</tt>), the minimum possible integer
11263 is assumed; if <tt>n</tt> is omitted after a dash, the maximum
11264 possible integer is assumed.
11265 </li>
11266 <li><i>Boolean filters</i>. Used to specify acceptable values for
11267 boolean device attributes. The format of the string is:
11268
11269 <tt>true|false|yes|no|0|1</tt>
11270
11271 </li>
11272 <li><i>Exact match</i>. Used to specify a single value for the given
11273 device attribute. Any string that doesn't start with <tt>int:</tt>
11274 represents the exact match. String device attributes are compared to
11275 this string including case of symbols. Integer attributes are first
11276 converted to a string (see individual filter attributes) and then
11277 compared ignoring case.
11278
11279 </li>
11280 <li><i>Any match</i>. Any value of the corresponding device attribute
11281 will match the given filter. An empty or <tt>null</tt> string is
11282 used to construct this type of filtering expressions.
11283
11284 </li>
11285 </ul>
11286
11287 <note>
11288 On the Windows host platform, interval filters are not currently
11289 available. Also all string filter attributes
11290 (<link to="#manufacturer"/>, <link to="#product"/>,
11291 <link to="#serialNumber"/>) are ignored, so they behave as
11292 <i>any match</i> no matter what string expression is specified.
11293 </note>
11294
11295 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
11296 </desc>
11297
11298 <attribute name="name" type="wstring">
11299 <desc>
11300 Visible name for this filter.
11301 This name is used to visually distinguish one filter from another,
11302 so it can neither be <tt>null</tt> nor an empty string.
11303 </desc>
11304 </attribute>
11305
11306 <attribute name="active" type="boolean">
11307 <desc>Whether this filter active or has been temporarily disabled.</desc>
11308 </attribute>
11309
11310 <attribute name="vendorId" type="wstring">
11311 <desc>
11312 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
11313 The string representation for the <i>exact matching</i>
11314 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11315 (including leading zeroes).
11316 </desc>
11317 </attribute>
11318
11319 <attribute name="productId" type="wstring">
11320 <desc>
11321 <link to="IUSBDevice::productId">Product ID</link> filter.
11322 The string representation for the <i>exact matching</i>
11323 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
11324 (including leading zeroes).
11325 </desc>
11326 </attribute>
11327
11328 <attribute name="revision" type="wstring">
11329 <desc>
11330 <link to="IUSBDevice::productId">Product revision number</link>
11331 filter. The string representation for the <i>exact matching</i>
11332 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
11333 of the integer part of the revision, and <tt>F</tt> is the
11334 decimal digit of its fractional part (including leading and
11335 trailing zeros).
11336 Note that for interval filters, it's best to use the hexadecimal
11337 form, because the revision is stored as a 16 bit packed BCD value;
11338 so the expression <tt>int:0x0100-0x0199</tt> will match any
11339 revision from <tt>1.0</tt> to <tt>1.99</tt>.
11340 </desc>
11341 </attribute>
11342
11343 <attribute name="manufacturer" type="wstring">
11344 <desc>
11345 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
11346 </desc>
11347 </attribute>
11348
11349 <attribute name="product" type="wstring">
11350 <desc>
11351 <link to="IUSBDevice::product">Product</link> filter.
11352 </desc>
11353 </attribute>
11354
11355 <attribute name="serialNumber" type="wstring">
11356 <desc>
11357 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
11358 </desc>
11359 </attribute>
11360
11361 <attribute name="port" type="wstring">
11362 <desc>
11363 <link to="IUSBDevice::port">Host USB port</link> filter.
11364 </desc>
11365 </attribute>
11366
11367 <attribute name="remote" type="wstring">
11368 <desc>
11369 <link to="IUSBDevice::remote">Remote state</link> filter.
11370 <note>
11371 This filter makes sense only for machine USB filters,
11372 i.e. it is ignored by IHostUSBDeviceFilter objects.
11373 </note>
11374 </desc>
11375 </attribute>
11376
11377 <attribute name="maskedInterfaces" type="unsigned long">
11378 <desc>
11379 This is an advanced option for hiding one or more USB interfaces
11380 from the guest. The value is a bit mask where the bits that are set
11381 means the corresponding USB interface should be hidden, masked off
11382 if you like.
11383 This feature only works on Linux hosts.
11384 </desc>
11385 </attribute>
11386
11387 </interface>
11388
11389
11390 <!--
11391 // IHostUSBDevice
11392 /////////////////////////////////////////////////////////////////////////
11393 -->
11394
11395 <enum
11396 name="USBDeviceState"
11397 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
11398 >
11399 <desc>
11400 USB device state. This enumeration represents all possible states
11401 of the USB device physically attached to the host computer regarding
11402 its state on the host computer and availability to guest computers
11403 (all currently running virtual machines).
11404
11405 Once a supported USB device is attached to the host, global USB
11406 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
11407 either ignore the device, or put it to USBDeviceState_Held state, or do
11408 nothing. Unless the device is ignored by global filters, filters of all
11409 currently running guests (<link to="IUSBController::deviceFilters"/>) are
11410 activated that can put it to USBDeviceState_Captured state.
11411
11412 If the device was ignored by global filters, or didn't match
11413 any filters at all (including guest ones), it is handled by the host
11414 in a normal way. In this case, the device state is determined by
11415 the host and can be one of USBDeviceState_Unavailable, USBDeviceState_Busy
11416 or USBDeviceState_Available, depending on the current device usage.
11417
11418 Besides auto-capturing based on filters, the device can be manually
11419 captured by guests (<link to="IConsole::attachUSBDevice"/>) if its
11420 state is USBDeviceState_Busy, USBDeviceState_Available or
11421 USBDeviceState_Held.
11422
11423 <note>
11424 Due to differences in USB stack implementations in Linux and Win32,
11425 states USBDeviceState_Busy and USBDeviceState_vailable are applicable
11426 only to the Linux version of the product. This also means that (<link
11427 to="IConsole::attachUSBDevice"/>) can only succeed on Win32 if the
11428 device state is USBDeviceState_Held.
11429 </note>
11430
11431 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
11432 </desc>
11433
11434 <const name="NotSupported" value="0">
11435 <desc>
11436 Not supported by the VirtualBox server, not available to guests.
11437 </desc>
11438 </const>
11439 <const name="Unavailable" value="1">
11440 <desc>
11441 Being used by the host computer exclusively,
11442 not available to guests.
11443 </desc>
11444 </const>
11445 <const name="Busy" value="2">
11446 <desc>
11447 Being used by the host computer, potentially available to guests.
11448 </desc>
11449 </const>
11450 <const name="Available" value="3">
11451 <desc>
11452 Not used by the host computer, available to guests (the host computer
11453 can also start using the device at any time).
11454 </desc>
11455 </const>
11456 <const name="Held" value="4">
11457 <desc>
11458 Held by the VirtualBox server (ignored by the host computer),
11459 available to guests.
11460 </desc>
11461 </const>
11462 <const name="Captured" value="5">
11463 <desc>
11464 Captured by one of the guest computers, not available
11465 to anybody else.
11466 </desc>
11467 </const>
11468 </enum>
11469
11470 <interface
11471 name="IHostUSBDevice" extends="IUSBDevice"
11472 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
11473 wsmap="managed"
11474 >
11475 <desc>
11476 The IHostUSBDevice interface represents a physical USB device attached
11477 to the host computer.
11478
11479 Besides properties inherited from IUSBDevice, this interface adds the
11480 <link to="#state"/> property that holds the current state of the USB
11481 device.
11482
11483 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
11484 </desc>
11485
11486 <attribute name="state" type="USBDeviceState" readonly="yes">
11487 <desc>
11488 Current state of the device.
11489 </desc>
11490 </attribute>
11491
11492 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
11493
11494 </interface>
11495
11496
11497 <!--
11498 // IHostUSBDeviceFilter
11499 /////////////////////////////////////////////////////////////////////////
11500 -->
11501
11502 <enum
11503 name="USBDeviceFilterAction"
11504 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
11505 >
11506 <desc>
11507 Actions for host USB device filters.
11508 <see>IHostUSBDeviceFilter, USBDeviceState</see>
11509 </desc>
11510
11511 <const name="Null" value="0">
11512 <desc>Null value (never used by the API).</desc>
11513 </const>
11514 <const name="Ignore" value="1">
11515 <desc>Ignore the matched USB device.</desc>
11516 </const>
11517 <const name="Hold" value="2">
11518 <desc>Hold the matched USB device.</desc>
11519 </const>
11520 </enum>
11521
11522 <interface
11523 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
11524 uuid="4cc70246-d74a-400f-8222-3900489c0374"
11525 wsmap="managed"
11526 >
11527 <desc>
11528 The IHostUSBDeviceFilter interface represents a global filter for a
11529 physical USB device used by the host computer. Used indirectly in
11530 <link to="IHost::USBDeviceFilters"/>.
11531
11532 Using filters of this type, the host computer determines the initial
11533 state of the USB device after it is physically attached to the
11534 host's USB controller.
11535
11536 <note>
11537 The <link to="#remote"/> attribute is ignored by this type of
11538 filters, because it makes sense only for
11539 <link to="IUSBController::deviceFilters">machine USB filters</link>.
11540 </note>
11541
11542 <see>IHost::USBDeviceFilters</see>
11543 </desc>
11544
11545 <attribute name="action" type="USBDeviceFilterAction">
11546 <desc>
11547 Action performed by the host when an attached USB device
11548 matches this filter.
11549 </desc>
11550 </attribute>
11551
11552 </interface>
11553
11554 <!--
11555 // IAudioAdapter
11556 /////////////////////////////////////////////////////////////////////////
11557 -->
11558
11559 <enum
11560 name="AudioDriverType"
11561 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
11562 >
11563 <desc>
11564 Host audio driver type.
11565 </desc>
11566
11567 <const name="Null" value="0">
11568 <desc>Null value, also means "dummy audio driver".</desc>
11569 </const>
11570 <const name="WinMM" value="1"/>
11571 <const name="OSS" value="2"/>
11572 <const name="ALSA" value="3"/>
11573 <const name="DirectSound" value="4"/>
11574 <const name="CoreAudio" value="5"/>
11575 <const name="MMPM" value="6"/>
11576 <const name="Pulse" value="7"/>
11577 <const name="SolAudio" value="8"/>
11578 </enum>
11579
11580 <enum
11581 name="AudioControllerType"
11582 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
11583 >
11584 <desc>
11585 Virtual audio controller type.
11586 </desc>
11587
11588 <const name="AC97" value="0"/>
11589 <const name="SB16" value="1"/>
11590 </enum>
11591
11592 <interface
11593 name="IAudioAdapter" extends="$unknown"
11594 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
11595 wsmap="managed"
11596 >
11597 <desc>
11598 The IAudioAdapter interface represents the virtual audio adapter of
11599 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
11600 </desc>
11601 <attribute name="enabled" type="boolean">
11602 <desc>
11603 Flag whether the audio adapter is present in the
11604 guest system. If disabled, the virtual guest hardware will
11605 not contain any audio adapter. Can only be changed when
11606 the VM is not running.
11607 </desc>
11608 </attribute>
11609 <attribute name="audioController" type="AudioControllerType">
11610 <desc>
11611 The audio hardware we emulate.
11612 </desc>
11613 </attribute>
11614 <attribute name="audioDriver" type="AudioDriverType">
11615 <desc>
11616 Audio driver the adapter is connected to. This setting
11617 can only be changed when the VM is not running.
11618 </desc>
11619 </attribute>
11620 </interface>
11621
11622 <!--
11623 // IVRDPServer
11624 /////////////////////////////////////////////////////////////////////////
11625 -->
11626
11627 <enum
11628 name="VRDPAuthType"
11629 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
11630 >
11631 <desc>
11632 VRDP authentication type.
11633 </desc>
11634
11635 <const name="Null" value="0">
11636 <desc>Null value, also means "no authentication".</desc>
11637 </const>
11638 <const name="External" value="1"/>
11639 <const name="Guest" value="2"/>
11640 </enum>
11641
11642 <interface
11643 name="IVRDPServer" extends="$unknown"
11644 uuid="f4584ae7-6bce-474b-83d6-17d235e6aa89"
11645 wsmap="managed"
11646 >
11647 <attribute name="enabled" type="boolean">
11648 <desc>VRDP server status.</desc>
11649 </attribute>
11650
11651 <attribute name="port" type="unsigned long">
11652 <desc>
11653 VRDP server port number.
11654 <note>
11655 Setting the value of this property to <tt>0</tt> will reset the port
11656 number to the default value which is
11657 currently <tt>3389</tt>. Reading this property will always return a
11658 real port number, even after it has been set to <tt>0</tt> (in which
11659 case the default port is returned).
11660 </note>
11661 </desc>
11662 </attribute>
11663
11664 <attribute name="netAddress" type="wstring">
11665 <desc>VRDP server address.</desc>
11666 </attribute>
11667
11668 <attribute name="authType" type="VRDPAuthType">
11669 <desc>VRDP authentication method.</desc>
11670 </attribute>
11671
11672 <attribute name="authTimeout" type="unsigned long">
11673 <desc>Timeout for guest authentication. Milliseconds.</desc>
11674 </attribute>
11675
11676 <attribute name="allowMultiConnection" type="boolean">
11677 <desc>
11678 Flag whether multiple simultaneous connections to the VM are permitted.
11679 Note that this will be replaced by a more powerful mechanism in the future.
11680 </desc>
11681 </attribute>
11682
11683 <attribute name="reuseSingleConnection" type="boolean">
11684 <desc>
11685 Flag whether the existing connection must be dropped and a new connection
11686 must be established by the VRDP server, when a new client connects in single
11687 connection mode.
11688 </desc>
11689 </attribute>
11690
11691 </interface>
11692
11693
11694 <!--
11695 // ISharedFolder
11696 /////////////////////////////////////////////////////////////////////////
11697 -->
11698
11699 <interface
11700 name="ISharedFolder" extends="$unknown"
11701 uuid="64637bb2-9e17-471c-b8f3-f8968dd9884e"
11702 wsmap="struct"
11703 >
11704 <desc>
11705 The ISharedFolder interface represents a folder in the host computer's
11706 file system accessible from the guest OS running inside a virtual
11707 machine using an associated logical name.
11708
11709 There are three types of shared folders:
11710 <ul>
11711 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
11712 folders available to all virtual machines.</li>
11713 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
11714 VM-specific shared folders available to the given virtual machine at
11715 startup.</li>
11716 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
11717 VM-specific shared folders created in the session context (for
11718 example, when the virtual machine is running) and automatically
11719 discarded when the session is closed (the VM is powered off).</li>
11720 </ul>
11721
11722 Logical names of shared folders must be unique within the given scope
11723 (global, permanent or transient). However, they do not need to be unique
11724 across scopes. In this case, the definition of the shared folder in a
11725 more specific scope takes precedence over definitions in all other
11726 scopes. The order of precedence is (more specific to more general):
11727 <ol>
11728 <li>Transient definitions</li>
11729 <li>Permanent definitions</li>
11730 <li>Global definitions</li>
11731 </ol>
11732
11733 For example, if MyMachine has a shared folder named
11734 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then creating a
11735 transient shared folder named <tt>C_DRIVE</tt> (that points
11736 to <tt>C:\\\\WINDOWS</tt>) will change the definition
11737 of <tt>C_DRIVE</tt> in the guest OS so
11738 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
11739 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
11740 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
11741 the previous (permanent) definition of <tt>C_DRIVE</tt> that points
11742 to <tt>C:\\</tt> if it still exists.
11743
11744 Note that permanent and transient shared folders of different machines
11745 are in different name spaces, so they don't overlap and don't need to
11746 have unique logical names.
11747
11748 <note>
11749 Global shared folders are not implemented in the current version of the
11750 product.
11751 </note>
11752 </desc>
11753
11754 <attribute name="name" type="wstring" readonly="yes">
11755 <desc>Logical name of the shared folder.</desc>
11756 </attribute>
11757
11758 <attribute name="hostPath" type="wstring" readonly="yes">
11759 <desc>Full path to the shared folder in the host file system.</desc>
11760 </attribute>
11761
11762 <attribute name="accessible" type="boolean" readonly="yes">
11763 <desc>
11764 Whether the folder defined by the host path is currently
11765 accessible or not.
11766 For example, the folder can be unaccessible if it is placed
11767 on the network share that is not available by the time
11768 this property is read.
11769 </desc>
11770 </attribute>
11771
11772 <attribute name="writable" type="boolean" readonly="yes">
11773 <desc>
11774 Whether the folder defined by the host path is writable or
11775 not.
11776 </desc>
11777 </attribute>
11778
11779 <attribute name="lastAccessError" type="wstring" readonly="yes">
11780 <desc>
11781 Text message that represents the result of the last accessibility
11782 check.
11783
11784 Accessibility checks are performed each time the <link to="#accessible"/>
11785 attribute is read. A @c null string is returned if the last
11786 accessibility check was successful. A non-null string indicates a
11787 failure and should normally describe a reason of the failure (for
11788 example, a file read error).
11789 </desc>
11790 </attribute>
11791
11792 </interface>
11793
11794 <!--
11795 // ISession
11796 /////////////////////////////////////////////////////////////////////////
11797 -->
11798
11799 <interface
11800 name="IInternalSessionControl" extends="$unknown"
11801 uuid="2581845a-5a9d-45fb-bc3b-2476552dd970"
11802 internal="yes"
11803 wsmap="suppress"
11804 >
11805 <method name="getPID">
11806 <desc>PID of the process that has created this Session object.
11807 </desc>
11808 <param name="pid" type="unsigned long" dir="return"/>
11809 </method>
11810
11811 <method name="getRemoteConsole">
11812 <desc>
11813 Returns the console object suitable for remote control.
11814
11815 <result name="VBOX_E_INVALID_VM_STATE">
11816 Session state prevents operation.
11817 </result>
11818 <result name="VBOX_E_INVALID_OBJECT_STATE">
11819 Session type prevents operation.
11820 </result>
11821
11822 </desc>
11823 <param name="console" type="IConsole" dir="return"/>
11824 </method>
11825
11826 <method name="assignMachine">
11827 <desc>
11828 Assigns the machine object associated with this direct-type
11829 session or informs the session that it will be a remote one
11830 (if @a machine == NULL).
11831
11832 <result name="VBOX_E_INVALID_VM_STATE">
11833 Session state prevents operation.
11834 </result>
11835 <result name="VBOX_E_INVALID_OBJECT_STATE">
11836 Session type prevents operation.
11837 </result>
11838
11839 </desc>
11840 <param name="machine" type="IMachine" dir="in"/>
11841 </method>
11842
11843 <method name="assignRemoteMachine">
11844 <desc>
11845 Assigns the machine and the (remote) console object associated with
11846 this remote-type session.
11847
11848 <result name="VBOX_E_INVALID_VM_STATE">
11849 Session state prevents operation.
11850 </result>
11851
11852 </desc>
11853 <param name="machine" type="IMachine" dir="in"/>
11854 <param name="console" type="IConsole" dir="in"/>
11855 </method>
11856
11857 <method name="updateMachineState">
11858 <desc>
11859 Updates the machine state in the VM process.
11860 Must be called only in certain cases
11861 (see the method implementation).
11862
11863 <result name="VBOX_E_INVALID_VM_STATE">
11864 Session state prevents operation.
11865 </result>
11866 <result name="VBOX_E_INVALID_OBJECT_STATE">
11867 Session type prevents operation.
11868 </result>
11869
11870 </desc>
11871 <param name="aMachineState" type="MachineState" dir="in"/>
11872 </method>
11873
11874 <method name="uninitialize">
11875 <desc>
11876 Uninitializes (closes) this session. Used by VirtualBox to close
11877 the corresponding remote session when the direct session dies
11878 or gets closed.
11879
11880 <result name="VBOX_E_INVALID_VM_STATE">
11881 Session state prevents operation.
11882 </result>
11883
11884 </desc>
11885 </method>
11886
11887 <method name="onDVDDriveChange">
11888 <desc>
11889 Triggered when settings of the DVD drive object of the
11890 associated virtual machine have changed.
11891
11892 <result name="VBOX_E_INVALID_VM_STATE">
11893 Session state prevents operation.
11894 </result>
11895 <result name="VBOX_E_INVALID_OBJECT_STATE">
11896 Session type prevents operation.
11897 </result>
11898
11899 </desc>
11900 </method>
11901
11902 <method name="onFloppyDriveChange">
11903 <desc>
11904 Triggered when settings of the floppy drive object of the
11905 associated virtual machine have changed.
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 </method>
11916
11917 <method name="onNetworkAdapterChange">
11918 <desc>
11919 Triggered when settings of a network adapter of the
11920 associated virtual machine have changed.
11921
11922 <result name="VBOX_E_INVALID_VM_STATE">
11923 Session state prevents operation.
11924 </result>
11925 <result name="VBOX_E_INVALID_OBJECT_STATE">
11926 Session type prevents operation.
11927 </result>
11928
11929 </desc>
11930 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
11931 </method>
11932
11933 <method name="onSerialPortChange">
11934 <desc>
11935 Triggered when settings of a serial port of the
11936 associated virtual machine have changed.
11937
11938 <result name="VBOX_E_INVALID_VM_STATE">
11939 Session state prevents operation.
11940 </result>
11941 <result name="VBOX_E_INVALID_OBJECT_STATE">
11942 Session type prevents operation.
11943 </result>
11944
11945 </desc>
11946 <param name="serialPort" type="ISerialPort" dir="in"/>
11947 </method>
11948
11949 <method name="onParallelPortChange">
11950 <desc>
11951 Triggered when settings of a parallel port of the
11952 associated virtual machine have changed.
11953
11954 <result name="VBOX_E_INVALID_VM_STATE">
11955 Session state prevents operation.
11956 </result>
11957 <result name="VBOX_E_INVALID_OBJECT_STATE">
11958 Session type prevents operation.
11959 </result>
11960
11961 </desc>
11962 <param name="parallelPort" type="IParallelPort" dir="in"/>
11963 </method>
11964
11965 <method name="onStorageControllerChange">
11966 <desc>
11967 Triggered when settings of a storage controller of the
11968 associated virtual machine have changed.
11969
11970 <result name="VBOX_E_INVALID_VM_STATE">
11971 Session state prevents operation.
11972 </result>
11973 <result name="VBOX_E_INVALID_OBJECT_STATE">
11974 Session type prevents operation.
11975 </result>
11976
11977 </desc>
11978 </method>
11979
11980 <method name="onVRDPServerChange">
11981 <desc>
11982 Triggered when settings of the VRDP server object of the
11983 associated virtual machine have changed.
11984
11985 <result name="VBOX_E_INVALID_VM_STATE">
11986 Session state prevents operation.
11987 </result>
11988 <result name="VBOX_E_INVALID_OBJECT_STATE">
11989 Session type prevents operation.
11990 </result>
11991
11992 </desc>
11993 </method>
11994
11995 <method name="onUSBControllerChange">
11996 <desc>
11997 Triggered when settings of the USB controller object of the
11998 associated virtual machine have changed.
11999
12000 <result name="VBOX_E_INVALID_VM_STATE">
12001 Session state prevents operation.
12002 </result>
12003 <result name="VBOX_E_INVALID_OBJECT_STATE">
12004 Session type prevents operation.
12005 </result>
12006
12007 </desc>
12008 </method>
12009
12010 <method name="onSharedFolderChange">
12011 <desc>
12012 Triggered when a permanent (global or machine) shared folder has been
12013 created or removed.
12014 <note>
12015 We don't pass shared folder parameters in this notification because
12016 the order in which parallel notifications are delivered is not defined,
12017 therefore it could happen that these parameters were outdated by the
12018 time of processing this notification.
12019 </note>
12020
12021 <result name="VBOX_E_INVALID_VM_STATE">
12022 Session state prevents operation.
12023 </result>
12024 <result name="VBOX_E_INVALID_OBJECT_STATE">
12025 Session type prevents operation.
12026 </result>
12027
12028 </desc>
12029 <param name="global" type="boolean" dir="in"/>
12030 </method>
12031
12032 <method name="onUSBDeviceAttach">
12033 <desc>
12034 Triggered when a request to capture a USB device (as a result
12035 of matched USB filters or direct call to
12036 <link to="IConsole::attachUSBDevice"/>) has completed.
12037 A @c null @a error object means success, otherwise it
12038 describes a failure.
12039
12040 <result name="VBOX_E_INVALID_VM_STATE">
12041 Session state prevents operation.
12042 </result>
12043 <result name="VBOX_E_INVALID_OBJECT_STATE">
12044 Session type prevents operation.
12045 </result>
12046
12047 </desc>
12048 <param name="device" type="IUSBDevice" dir="in"/>
12049 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12050 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
12051 </method>
12052
12053 <method name="onUSBDeviceDetach">
12054 <desc>
12055 Triggered when a request to release the USB device (as a result
12056 of machine termination or direct call to
12057 <link to="IConsole::detachUSBDevice"/>) has completed.
12058 A @c null @a error object means success, otherwise it
12059
12060 <result name="VBOX_E_INVALID_VM_STATE">
12061 Session state prevents operation.
12062 </result>
12063 <result name="VBOX_E_INVALID_OBJECT_STATE">
12064 Session type prevents operation.
12065 </result>
12066
12067 </desc>
12068 <param name="id" type="uuid" dir="in"/>
12069 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
12070 </method>
12071
12072 <method name="onShowWindow">
12073 <desc>
12074 Called by <link to="IMachine::canShowConsoleWindow"/> and by
12075 <link to="IMachine::showConsoleWindow"/> in order to notify
12076 console callbacks
12077 <link to="IConsoleCallback::onCanShowWindow"/>
12078 and <link to="IConsoleCallback::onShowWindow"/>.
12079
12080 <result name="VBOX_E_INVALID_OBJECT_STATE">
12081 Session type prevents operation.
12082 </result>
12083
12084 </desc>
12085 <param name="check" type="boolean" dir="in"/>
12086 <param name="canShow" type="boolean" dir="out"/>
12087 <param name="winId" type="unsigned long long" dir="out"/>
12088 </method>
12089
12090 <method name="accessGuestProperty">
12091 <desc>
12092 Called by <link to="IMachine::getGuestProperty"/> and by
12093 <link to="IMachine::setGuestProperty"/> in order to read and
12094 modify guest properties.
12095
12096 <result name="VBOX_E_INVALID_VM_STATE">
12097 Machine session is not open.
12098 </result>
12099 <result name="VBOX_E_INVALID_OBJECT_STATE">
12100 Session type is not direct.
12101 </result>
12102
12103 </desc>
12104 <param name="name" type="wstring" dir="in"/>
12105 <param name="value" type="wstring" dir="in"/>
12106 <param name="flags" type="wstring" dir="in"/>
12107 <param name="isSetter" type="boolean" dir="in"/>
12108 <param name="retValue" type="wstring" dir="out"/>
12109 <param name="retTimestamp" type="unsigned long long" dir="out"/>
12110 <param name="retFlags" type="wstring" dir="out"/>
12111 </method>
12112
12113 <method name="enumerateGuestProperties">
12114 <desc>
12115 Return a list of the guest properties matching a set of patterns along
12116 with their values, time stamps and flags.
12117
12118 <result name="VBOX_E_INVALID_VM_STATE">
12119 Machine session is not open.
12120 </result>
12121 <result name="VBOX_E_INVALID_OBJECT_STATE">
12122 Session type is not direct.
12123 </result>
12124
12125 </desc>
12126 <param name="patterns" type="wstring" dir="in">
12127 <desc>
12128 The patterns to match the properties against as a comma-separated
12129 string. If this is empty, all properties currently set will be
12130 returned.
12131 </desc>
12132 </param>
12133 <param name="key" type="wstring" dir="out" safearray="yes">
12134 <desc>
12135 The key names of the properties returned.
12136 </desc>
12137 </param>
12138 <param name="value" type="wstring" dir="out" safearray="yes">
12139 <desc>
12140 The values of the properties returned. The array entries match the
12141 corresponding entries in the @a key array.
12142 </desc>
12143 </param>
12144 <param name="timestamp" type="unsigned long long" dir="out" safearray="yes">
12145 <desc>
12146 The time stamps of the properties returned. The array entries match
12147 the corresponding entries in the @a key array.
12148 </desc>
12149 </param>
12150 <param name="flags" type="wstring" dir="out" safearray="yes">
12151 <desc>
12152 The flags of the properties returned. The array entries match the
12153 corresponding entries in the @a key array.
12154 </desc>
12155 </param>
12156 </method>
12157
12158 </interface>
12159
12160 <interface
12161 name="ISession" extends="$dispatched"
12162 uuid="12F4DCDB-12B2-4ec1-B7CD-DDD9F6C5BF4D"
12163 wsmap="managed"
12164 >
12165 <desc>
12166 The ISession interface represents a serialization primitive for virtual
12167 machines.
12168
12169 With VirtualBox, every time one wishes to manipulate a virtual machine
12170 (e.g. change its settings or start execution), a session object is
12171 required. Such an object must be passed to one of the session methods
12172 that open the given session, which then initiates the machine manipulation.
12173
12174 A session serves several purposes: it identifies to the inter-process VirtualBox
12175 code which process is currently working with the virtual machine, and it ensures
12176 that there are no incompatible requests from several processes for the
12177 same virtual machine. Session objects can therefore be thought of as mutex
12178 semaphores that lock virtual machines to prevent conflicting accesses from
12179 several processes.
12180
12181 How sessions objects are used depends on whether you use the Main API
12182 via COM or via the webservice:
12183
12184 <ul>
12185 <li>When using the COM API directly, an object of the Session class from the
12186 VirtualBox type library needs to be created. In regular COM C++ client code,
12187 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
12188 This object will then act as a local session object in further calls to open
12189 a session.
12190 </li>
12191
12192 <li>In the webservice, the session manager (IWebsessionManager) instead creates
12193 one session object automatically when <link to="IWebsessionManager::logon" />
12194 is called. A managed object reference to that session object can be retrieved by
12195 calling <link to="IWebsessionManager::getSessionObject" />. This session object
12196 reference can then be used to open sessions.
12197 </li>
12198 </ul>
12199
12200 Sessions are mainly used in two variations:
12201
12202 <ul>
12203 <li>
12204 To start a virtual machine in a separate process, one would call
12205 <link to="IVirtualBox::openRemoteSession"/>, which requires a session
12206 object as its first parameter. This session then identifies the caller
12207 and lets him control the started machine (for example, pause machine
12208 execution or power it down) as well as be notified about machine
12209 execution state changes.
12210 </li>
12211
12212 <li>To alter machine settings, or to start machine execution within the
12213 current process, one needs to open a direct session for the machine first by
12214 calling <link to="IVirtualBox::openSession"/>. While a direct session
12215 is open within one process, no any other process may open another direct
12216 session for the same machine. This prevents the machine from being changed
12217 by other processes while it is running or while the machine is being configured.
12218 </li>
12219 </ul>
12220
12221 One also can attach to an existing direct session already opened by
12222 another process (for example, in order to send a control request to the
12223 virtual machine such as the pause or the reset request). This is done by
12224 calling <link to="IVirtualBox::openExistingSession"/>.
12225
12226 <note>
12227 Unless you are trying to write a new VirtualBox front-end that
12228 performs direct machine execution (like the VirtualBox or VBoxSDL
12229 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
12230 session opened by <link to="IVirtualBox::openSession"/> and use this
12231 session only to change virtual machine settings. If you simply want to
12232 start virtual machine execution using one of the existing front-ends
12233 (for example the VirtualBox GUI or headless server), simply use
12234 <link to="IVirtualBox::openRemoteSession"/>; these front-ends
12235 will power up the machine automatically for you.
12236 </note>
12237 </desc>
12238
12239 <attribute name="state" type="SessionState" readonly="yes">
12240 <desc>Current state of this session.</desc>
12241 </attribute>
12242
12243 <attribute name="type" type="SessionType" readonly="yes">
12244 <desc>
12245 Type of this session. The value of this attribute is valid only
12246 if the session is currently open (i.e. its #state is
12247 SessionType_SessionOpen), otherwise an error will be returned.
12248 </desc>
12249 </attribute>
12250
12251 <attribute name="machine" type="IMachine" readonly="yes">
12252 <desc>Machine object associated with this session.</desc>
12253 </attribute>
12254
12255 <attribute name="console" type="IConsole" readonly="yes">
12256 <desc>Console object associated with this session.</desc>
12257 </attribute>
12258
12259 <method name="close">
12260 <desc>
12261 Closes a session that was previously opened.
12262
12263 It is recommended that every time an "open session" method (such as
12264 <link to="IVirtualBox::openRemoteSession" /> or
12265 <link to="IVirtualBox::openSession" />) has been called to
12266 manipulate a virtual machine, the caller invoke
12267 ISession::close() when it's done doing so. Since sessions are
12268 serialization primitives much like ordinary mutexes, they are
12269 best used the same way: for each "open" call, there should be
12270 a matching "close" call, even when errors occur.
12271
12272 Otherwise, if a direct session for a machine opened with
12273 <link to="IVirtualBox::openSession"/> is not explicitly closed
12274 when the application terminates, the state of the machine will
12275 be set to <link to="MachineState_Aborted" /> on the server.
12276
12277 Generally, it is recommended to close all open sessions explicitly
12278 before terminating the application (regardless of the reason for
12279 the termination).
12280
12281 <note>
12282 Do not expect the session state (<link to="ISession::state" />
12283 to return to "Closed" immediately after you invoke
12284 ISession::close(), particularly if you have started a remote
12285 session to execute the VM in a new process. The session state will
12286 automatically return to "Closed" once the VM is no longer executing,
12287 which can of course take a very long time.
12288 </note>
12289
12290 <result name="E_UNEXPECTED">
12291 Session is not open.
12292 </result>
12293
12294 </desc>
12295 </method>
12296
12297 </interface>
12298
12299 <!--
12300 // IStorageController
12301 /////////////////////////////////////////////////////////////////////////
12302 -->
12303
12304 <enum
12305 name="StorageBus"
12306 uuid="f381fdca-5953-41d0-b2bd-0542b012698d"
12307 >
12308 <desc>
12309 The connection type of the storage controller.
12310 </desc>
12311 <const name="Null" value="0">
12312 <desc><tt>null</tt> value. Never used by the API.</desc>
12313 </const>
12314 <const name="IDE" value="1"/>
12315 <const name="SATA" value="2"/>
12316 <const name="SCSI" value="3"/>
12317 </enum>
12318
12319 <enum
12320 name="StorageControllerType"
12321 uuid="685387db-a837-4320-a258-08f46a22f62a"
12322 >
12323 <desc>
12324 Storage controller type.
12325 </desc>
12326
12327 <const name="Null" value="0">
12328 <desc><tt>null</tt> value. Never used by the API.</desc>
12329 </const>
12330 <const name="LsiLogic" value="1"/>
12331 <const name="BusLogic" value="2"/>
12332 <const name="IntelAhci" value="3"/>
12333 <const name="PIIX3" value="4"/>
12334 <const name="PIIX4" value="5"/>
12335 <const name="ICH6" value="6"/>
12336 </enum>
12337
12338 <interface
12339 name="IStorageController" extends="$unknown"
12340 uuid="6bf8335b-d14a-44a5-9b45-ddc49ce7d5b2"
12341 wsmap="managed"
12342 >
12343
12344 <attribute name="name" type="wstring" readonly="yes">
12345 <desc>
12346 Name of the storage controller. Acts also as a unique
12347 identifier.
12348 </desc>
12349 </attribute>
12350
12351 <attribute name="maxDevicesPerPortCount" type="unsigned long" readonly="yes">
12352 <desc>
12353 Maximum number of devices which can be attached to one port.
12354 </desc>
12355 </attribute>
12356
12357 <attribute name="minPortCount" type="unsigned long" readonly="yes">
12358 <desc>
12359 Minimum number of ports which can be set with
12360 <link to="IStorageController::SetPortCount"/>.
12361 </desc>
12362 </attribute>
12363
12364 <attribute name="maxPortCount" type="unsigned long" readonly="yes">
12365 <desc>
12366 Maximum number of ports which can be set with
12367 <link to="IStorageController::SetPortCount"/>.
12368 </desc>
12369 </attribute>
12370
12371 <attribute name="instance" type="unsigned long">
12372 <desc>
12373 The instance number of the device in the running VM.
12374 </desc>
12375 </attribute>
12376
12377 <attribute name="portCount" type="unsigned long">
12378 <desc>
12379 The number of currently usable ports on the controller.
12380 The minimum and maximum number of ports for one controller type can
12381 be determined with <link to="IStorageController::GetMinPortCount"/>
12382 and <link to="IStorageController::GetMaxPortCount"/>..
12383 </desc>
12384 </attribute>
12385
12386 <attribute name="bus" type="StorageBus" readonly="yes">
12387 <desc>
12388 The connection type of the storage controller.
12389 </desc>
12390 </attribute>
12391
12392 <attribute name="controllerType" type="StorageControllerType">
12393 <desc>
12394 Type of the virtual storage controller. Depending on this value,
12395 VirtualBox will provide a different virtual storage controller hardware
12396 to the guest.
12397 </desc>
12398 </attribute>
12399
12400 <method name="GetIDEEmulationPort">
12401 <desc>
12402 Gets the corresponding port number which is emulated as an IDE device.
12403
12404 <result name="E_INVALIDARG">
12405 The @a devicePosition is not in the range 0 to 3.
12406 </result>
12407 <result name="E_NOTIMPL">
12408 The storage controller type is not SATAIntelAhci.
12409 </result>
12410
12411 </desc>
12412 <param name="devicePosition" type="long" dir="in"/>
12413 <param name="portNumber" type="long" dir="return"/>
12414 </method>
12415
12416 <method name="SetIDEEmulationPort">
12417 <desc>
12418 Sets the port number which is emulated as an IDE device.
12419
12420 <result name="E_INVALIDARG">
12421 The @a devicePosition is not in the range 0 to 3 or the
12422 @a portNumber is not in the range 0 to 29.
12423 </result>
12424 <result name="E_NOTIMPL">
12425 The storage controller type is not SATAIntelAhci.
12426 </result>
12427
12428 </desc>
12429 <param name="devicePosition" type="long" dir="in"/>
12430 <param name="portNumber" type="long" dir="in"/>
12431 </method>
12432
12433 </interface>
12434
12435<if target="wsdl">
12436
12437 <!--
12438 // IManagedObjectRef
12439 /////////////////////////////////////////////////////////////////////////
12440 -->
12441
12442 <interface
12443 name="IManagedObjectRef" extends="$unknown"
12444 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
12445 internal="yes"
12446 wsmap="managed"
12447 wscpp="hardcoded"
12448 >
12449 <desc>
12450 Managed object reference.
12451
12452 Only within the webservice, a managed object reference (which is really
12453 an opaque number) allows a webservice client to address an object
12454 that lives in the address space of the webservice server.
12455
12456 Behind each managed object reference, there is a COM object that lives
12457 in the webservice server's address space. The COM object is not freed
12458 until the managed object reference is released, either by an explicit
12459 call to <link to="IManagedObjectRef::release" /> or by logging off from
12460 the webservice (<link to="IWebsessionManager::logoff" />), which releases
12461 all objects created during the webservice session.
12462
12463 Whenever a method call of the VirtualBox API returns a COM object, the
12464 webservice representation of that method will instead return a
12465 managed object reference, which can then be used to invoke methods
12466 on that object.
12467 </desc>
12468
12469 <method name="getInterfaceName">
12470 <desc>
12471 Returns the name of the interface that this managed object represents,
12472 for example, "IMachine", as a string.
12473 </desc>
12474 <param name="return" type="wstring" dir="return"/>
12475 </method>
12476
12477 <method name="release">
12478 <desc>
12479 Releases this managed object reference and frees the resources that
12480 were allocated for it in the webservice server process. After calling
12481 this method, the identifier of the reference can no longer be used.
12482 </desc>
12483 </method>
12484
12485 </interface>
12486
12487 <!--
12488 // IWebsessionManager
12489 /////////////////////////////////////////////////////////////////////////
12490 -->
12491
12492 <interface
12493 name="IWebsessionManager" extends="$unknown"
12494 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
12495 internal="yes"
12496 wsmap="global"
12497 wscpp="hardcoded"
12498 >
12499 <desc>
12500 Websession manager. This provides essential services
12501 to webservice clients.
12502 </desc>
12503 <method name="logon">
12504 <desc>
12505 Logs a new client onto the webservice and returns a managed object reference to
12506 the IVirtualBox instance, which the client can then use as a basis to further
12507 queries, since all calls to the VirtualBox API are based on the IVirtualBox
12508 interface, in one way or the other.
12509 </desc>
12510 <param name="username" type="wstring" dir="in"/>
12511 <param name="password" type="wstring" dir="in"/>
12512 <param name="return" type="IVirtualBox" dir="return"/>
12513 </method>
12514
12515 <method name="getSessionObject">
12516 <desc>
12517 Returns a managed object reference to the internal ISession object that was created
12518 for this web service session when the client logged on.
12519
12520 <see>ISession</see>
12521 </desc>
12522 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
12523 <param name="return" type="ISession" dir="return"/>
12524 </method>
12525
12526 <method name="logoff">
12527 <desc>
12528 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
12529 and destroys all resources associated with the session (most importantly, all
12530 managed objects created in the server while the session was active).
12531 </desc>
12532 <param name="refIVirtualBox" type="IVirtualBox" dir="in"/>
12533 </method>
12534
12535 </interface>
12536
12537</if>
12538
12539 <!--
12540 // IPerformanceCollector & friends
12541 /////////////////////////////////////////////////////////////////////////
12542 -->
12543
12544 <interface
12545 name="IPerformanceMetric" extends="$unknown"
12546 uuid="2a1a60ae-9345-4019-ad53-d34ba41cbfe9" wsmap="managed"
12547 >
12548 <desc>
12549 The IPerformanceMetric interface represents parameters of the given
12550 performance metric.
12551 </desc>
12552
12553 <attribute name="metricName" type="wstring" readonly="yes">
12554 <desc>
12555 Name of the metric.
12556 </desc>
12557 </attribute>
12558
12559 <attribute name="object" type="$unknown" readonly="yes">
12560 <desc>
12561 Object this metric belongs to.
12562 </desc>
12563 </attribute>
12564
12565 <attribute name="description" type="wstring" readonly="yes">
12566 <desc>
12567 Textual description of the metric.
12568 </desc>
12569 </attribute>
12570
12571 <attribute name="period" type="unsigned long" readonly="yes">
12572 <desc>
12573 Time interval between samples, measured in seconds.
12574 </desc>
12575 </attribute>
12576
12577 <attribute name="count" type="unsigned long" readonly="yes">
12578 <desc>
12579 Number of recent samples retained by the performance collector for this
12580 metric.
12581
12582 When the collected sample count exceeds this number, older samples
12583 are discarded.
12584 </desc>
12585 </attribute>
12586
12587 <attribute name="unit" type="wstring" readonly="yes">
12588 <desc>
12589 Unit of measurement.
12590 </desc>
12591 </attribute>
12592
12593 <attribute name="minimumValue" type="long" readonly="yes">
12594 <desc>
12595 Minimum possible value of this metric.
12596 </desc>
12597 </attribute>
12598
12599 <attribute name="maximumValue" type="long" readonly="yes">
12600 <desc>
12601 Maximum possible value of this metric.
12602 </desc>
12603 </attribute>
12604 </interface>
12605
12606 <interface
12607 name="IPerformanceCollector" extends="$unknown"
12608 uuid="e22e1acb-ac4a-43bb-a31c-17321659b0c6"
12609 wsmap="managed"
12610 >
12611 <desc>
12612 The IPerformanceCollector interface represents a service that collects and
12613 stores performance metrics data.
12614
12615 Performance metrics are associated with objects like IHost and
12616 IMachine. Each object has a distinct set of performance metrics.
12617 The set can be obtained with <link to="IPerformanceCollector::getMetrics"/>.
12618
12619 Metric data are collected at the specified intervals and are retained
12620 internally. The interval and the number of samples retained can be set
12621 with <link to="IPerformanceCollector::setupMetrics" />.
12622
12623 Metrics are organized hierarchically, each level separated by slash (/).
12624 General scheme for metric name is
12625 "Category/Metric[/SubMetric][:aggregation]". For example CPU/Load/User:avg
12626 metric name stands for: CPU category, Load metric, User submetric, average
12627 aggregate. An aggregate function is computed over all retained data. Valid
12628 aggregate functions are:
12629
12630 <ul>
12631 <li>avg -- average</li>
12632 <li>min -- minimum</li>
12633 <li>max -- maximum</li>
12634 </ul>
12635
12636 "Category/Metric" together form base metric name. A base metric is the
12637 smallest unit for which a sampling interval and the number of retained
12638 samples can be set. Only base metrics can be enabled and disabled. All
12639 sub-metrics are collected when their base metric is collected.
12640 Collected values for any set of sub-metrics can be queried with
12641 <link to="IPerformanceCollector::queryMetricsData" />. When setting up
12642 metric parameters, querying metric data, enabling or disabling metrics
12643 wildcards can be used in metric names to specify a subset of metrics. For
12644 example, to select all CPU-related metrics use <tt>CPU/*</tt>, all
12645 averages can be queried using <tt>*:avg</tt> and so on. To query metric
12646 values without aggregates <tt>*:</tt> can be used.
12647
12648 The valid names for base metrics are:
12649
12650 <ul>
12651 <li>CPU/Load</li>
12652 <li>CPU/MHz</li>
12653 <li>RAM/Usage</li>
12654 </ul>
12655
12656 The general sequence for collecting and retrieving the metrics is:
12657 <ul>
12658 <li>
12659 Obtain an instance of IPerformanceCollector with
12660 <link to="IVirtualBox::performanceCollector" />
12661 </li>
12662 <li>
12663 Allocate and populate an array with references to objects the metrics
12664 will be collected for. Use references to IHost and IMachine objects.
12665 </li>
12666 <li>
12667 Allocate and populate an array with base metric names the data will be
12668 collected for.
12669 </li>
12670 <li>
12671 Call <link to="IPerformanceCollector::setupMetrics" />. From now on the
12672 metric data will be collected and stored.
12673 </li>
12674 <li>
12675 Wait for the data to get collected.
12676 </li>
12677 <li>
12678 Allocate and populate an array with references to objects the metric
12679 values will be queried for. You can re-use the object array used for
12680 setting base metrics.
12681 </li>
12682 <li>
12683 Allocate and populate an array with metric names the data will be
12684 collected for. Note that metric names differ from base metric names.
12685 </li>
12686 <li>
12687 Call <link to="IPerformanceCollector::queryMetricsData" />. The data that
12688 have been collected so far are returned. Note that the values are still
12689 retained internally and data collection continues.
12690 </li>
12691 </ul>
12692
12693 For an example of usage refer to the following files in VirtualBox SDK:
12694 <ul>
12695 <li>
12696 Java: <tt>bindings/webservice/java/jax-ws/samples/metrictest.java</tt>
12697 </li>
12698 <li>
12699 Python: <tt>bindings/xpcom/python/sample/shellcommon.py</tt>
12700 </li>
12701 </ul>
12702 </desc>
12703
12704 <attribute name="metricNames" type="wstring" readonly="yes" safearray="yes">
12705 <desc>
12706 Array of unique names of metrics.
12707
12708 This array represents all metrics supported by the performance
12709 collector. Individual objects do not necessarily support all of them.
12710 <link to="IPerformanceCollector::getMetrics"/> can be used to get the
12711 list of supported metrics for a particular object.
12712 </desc>
12713 </attribute>
12714
12715 <method name="getMetrics">
12716 <desc>
12717 Returns parameters of specified metrics for a set of objects.
12718 <note>
12719 @c Null metrics array means all metrics. @c Null object array means
12720 all existing objects.
12721 </note>
12722 </desc>
12723 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12724 <desc>
12725 Metric name filter. Currently, only a comma-separated list of metrics
12726 is supported.
12727 </desc>
12728 </param>
12729 <param name="objects" type="$unknown" dir="in" safearray="yes">
12730 <desc>
12731 Set of objects to return metric parameters for.
12732 </desc>
12733 </param>
12734 <param name="metrics" type="IPerformanceMetric" dir="return" safearray="yes">
12735 <desc>
12736 Array of returned metric parameters.
12737 </desc>
12738 </param>
12739 </method>
12740
12741 <method name="setupMetrics">
12742 <desc>
12743 Sets parameters of specified base metrics for a set of objects. Returns
12744 an array of <link to="IPerformanceMetric" /> describing the metrics have
12745 been affected.
12746 <note>
12747 @c Null or empty metric name array means all metrics. @c Null or empty
12748 object array means all existing objects. If metric name array contains
12749 a single element and object array contains many, the single metric
12750 name array element is applied to each object array element to form
12751 metric/object pairs.
12752 </note>
12753 </desc>
12754 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12755 <desc>
12756 Metric name filter. Comma-separated list of metrics with wildcard
12757 support.
12758 </desc>
12759 </param>
12760 <param name="objects" type="$unknown" dir="in" safearray="yes">
12761 <desc>
12762 Set of objects to setup metric parameters for.
12763 </desc>
12764 </param>
12765 <param name="period" type="unsigned long" dir="in">
12766 <desc>
12767 Time interval in seconds between two consecutive samples of performance
12768 data.
12769 </desc>
12770 </param>
12771 <param name="count" type="unsigned long" dir="in">
12772 <desc>
12773 Number of samples to retain in performance data history. Older samples
12774 get discarded.
12775 </desc>
12776 </param>
12777 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
12778 <desc>
12779 Array of metrics that have been modified by the call to this method.
12780 </desc>
12781 </param>
12782 </method>
12783
12784 <method name="enableMetrics">
12785 <desc>
12786 Turns on collecting specified base metrics. Returns an array of
12787 <link to="IPerformanceMetric" /> describing the metrics have been
12788 affected.
12789 <note>
12790 @c Null or empty metric name array means all metrics. @c Null or empty
12791 object array means all existing objects. If metric name array contains
12792 a single element and object array contains many, the single metric
12793 name array element is applied to each object array element to form
12794 metric/object pairs.
12795 </note>
12796 </desc>
12797 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12798 <desc>
12799 Metric name filter. Comma-separated list of metrics with wildcard
12800 support.
12801 </desc>
12802 </param>
12803 <param name="objects" type="$unknown" dir="in" safearray="yes">
12804 <desc>
12805 Set of objects to enable metrics for.
12806 </desc>
12807 </param>
12808 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
12809 <desc>
12810 Array of metrics that have been modified by the call to this method.
12811 </desc>
12812 </param>
12813 </method>
12814
12815 <method name="disableMetrics">
12816 <desc>
12817 Turns off collecting specified base metrics. Returns an array of
12818 <link to="IPerformanceMetric" /> describing the metrics have been
12819 affected.
12820 <note>
12821 @c Null or empty metric name array means all metrics. @c Null or empty
12822 object array means all existing objects. If metric name array contains
12823 a single element and object array contains many, the single metric
12824 name array element is applied to each object array element to form
12825 metric/object pairs.
12826 </note>
12827 </desc>
12828 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12829 <desc>
12830 Metric name filter. Comma-separated list of metrics with wildcard
12831 support.
12832 </desc>
12833 </param>
12834 <param name="objects" type="$unknown" dir="in" safearray="yes">
12835 <desc>
12836 Set of objects to disable metrics for.
12837 </desc>
12838 </param>
12839 <param name="affectedMetrics" type="IPerformanceMetric" dir="return" safearray="yes">
12840 <desc>
12841 Array of metrics that have been modified by the call to this method.
12842 </desc>
12843 </param>
12844 </method>
12845
12846 <method name="queryMetricsData">
12847 <desc>
12848 Queries collected metrics data for a set of objects.
12849
12850 The data itself and related metric information are returned in seven
12851 parallel and one flattened array of arrays. Elements of
12852 <tt>returnMetricNames, returnObjects, returnUnits, returnScales,
12853 returnSequenceNumbers, returnDataIndices and returnDataLengths</tt> with
12854 the same index describe one set of values corresponding to a single
12855 metric.
12856
12857 The <tt>returnData</tt> parameter is a flattened array of arrays. Each
12858 start and length of a sub-array is indicated by
12859 <tt>returnDataIndices</tt> and <tt>returnDataLengths</tt>. The first
12860 value for metric <tt>metricNames[i]</tt> is at
12861 <tt>returnData[returnIndices[i]]</tt>.
12862
12863 <note>
12864 @c Null or empty metric name array means all metrics. @c Null or empty
12865 object array means all existing objects. If metric name array contains
12866 a single element and object array contains many, the single metric
12867 name array element is applied to each object array element to form
12868 metric/object pairs.
12869 </note>
12870 <note>
12871 Data collection continues behind the scenes after call to
12872 @c queryMetricsData. The return data can be seen as the snapshot of
12873 the current state at the time of @c queryMetricsData call. The
12874 internally kept metric values are not cleared by the call. This makes
12875 possible querying different subsets of metrics or aggregates with
12876 subsequent calls. If periodic querying is needed it is highly
12877 suggested to query the values with @c interval*count period to avoid
12878 confusion. This way a completely new set of data values will be
12879 provided by each query.
12880 </note>
12881 </desc>
12882 <param name="metricNames" type="wstring" dir="in" safearray="yes">
12883 <desc>
12884 Metric name filter. Comma-separated list of metrics with wildcard
12885 support.
12886 </desc>
12887 </param>
12888 <param name="objects" type="$unknown" dir="in" safearray="yes">
12889 <desc>
12890 Set of objects to query metrics for.
12891 </desc>
12892 </param>
12893 <param name="returnMetricNames" type="wstring" dir="out" safearray="yes">
12894 <desc>
12895 Names of metrics returned in @c returnData.
12896 </desc>
12897 </param>
12898 <param name="returnObjects" type="$unknown" dir="out" safearray="yes">
12899 <desc>
12900 Objects associated with metrics returned in @c returnData.
12901 </desc>
12902 </param>
12903 <param name="returnUnits" type="wstring" dir="out" safearray="yes">
12904 <desc>
12905 Units of measurement for each returned metric.
12906 </desc>
12907 </param>
12908 <param name="returnScales" type="unsigned long" dir="out" safearray="yes">
12909 <desc>
12910 Divisor that should be applied to return values in order to get
12911 floating point values. For example:
12912 <tt>(double)returnData[returnDataIndices[0]+i] / returnScales[0]</tt>
12913 will retrieve the floating point value of i-th sample of the first
12914 metric.
12915 </desc>
12916 </param>
12917 <param name="returnSequenceNumbers" type="unsigned long" dir="out" safearray="yes">
12918 <desc>
12919 Sequence numbers of the first elements of value sequences of particular metrics
12920 returned in @c returnData. For aggregate metrics it is the sequence number of
12921 the sample the aggregate started calculation from.
12922 </desc>
12923 </param>
12924 <param name="returnDataIndices" type="unsigned long" dir="out" safearray="yes">
12925 <desc>
12926 Indices of the first elements of value sequences of particular metrics
12927 returned in @c returnData.
12928 </desc>
12929 </param>
12930 <param name="returnDataLengths" type="unsigned long" dir="out" safearray="yes">
12931 <desc>
12932 Lengths of value sequences of particular metrics.
12933 </desc>
12934 </param>
12935 <param name="returnData" type="long" dir="return" safearray="yes">
12936 <desc>
12937 Flattened array of all metric data containing sequences of values for
12938 each metric.
12939 </desc>
12940 </param>
12941 </method>
12942
12943 </interface>
12944
12945 <module name="VBoxSVC" context="LocalServer">
12946 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
12947 namespace="virtualbox.org">
12948 <interface name="IVirtualBox" default="yes"/>
12949 </class>
12950 </module>
12951
12952 <module name="VBoxC" context="InprocServer" threadingModel="Free">
12953 <class name="Session" uuid="3C02F46D-C9D2-4f11-A384-53F0CF917214"
12954 namespace="virtualbox.org">
12955 <interface name="ISession" default="yes"/>
12956 </class>
12957 </module>
12958
12959</library>
12960
12961</idl>
12962
12963<!-- 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