VirtualBox

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

Last change on this file since 10306 was 10306, checked in by vboxsync, 17 years ago

Main: Docs fixes.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 361.2 KB
Line 
1<?xml version="1.0" ?>
2
3<!--
4 * :tabSize=2:indentSize=2:noTabs=true:
5 * :folding=explicit:collapseFolds=1:
6 *
7 * Master declaration for VirtualBox's Main API, represented
8 * by COM/XPCOM and web service interfaces.
9 *
10 * From this document, the build system generates several files
11 * via XSLT that are then used during the build process.
12 *
13 * Below is the list of XSL templates that operate on this file and
14 * output files they generate. These XSL templates must be updated
15 * whenever the schema of this file changes:
16 *
17 * 1. src/VBox/Main/idl/midl.xsl =>
18 * out/<platform>/bin/sdk/idl/VirtualBox.idl
19 * (MS COM interface definition file for Main API)
20 *
21 * 2. src/VBox/Main/idl/xpidl.xsl =>
22 * out/<platform>/bin/sdk/idl/VirtualBox_XPCOM.idl
23 * (XPCOM interface definition file for Main API)
24 *
25 * 3. src/VBox/Main/idl/doxygen.xsl =>
26 * out/<platform>/obj/src/VBox/Main/VirtualBox.idl
27 * (pseudo-IDL for Doxygen to generate the official Main API
28 * documentation)
29 *
30 * 4. src/VBox/Main/webservice/*.xsl =>
31 * a bunch of WSDL and C++ files
32 * (VirtualBox web service sources and SOAP mappers;
33 * see src/VBox/Main/webservice/Makefile.kmk for details)
34 *
35 * 5. src/VBox/Frontends/VirtualBox/include/COMWrappers.xsl =>
36 * out/<platform>/obj/src/VBox/Frontends/VirtualBox/VirtualBox/include/COMWrappers.h
37 * (smart Qt-based C++ wrapper classes for COM interfaces
38 * of the Main API)
39 *
40 * 6. src/VBox/Frontends/VirtualBox4/include/COMWrappers.xsl =>
41 * out/<platform>/obj/src/VBox/Frontends/VirtualBox4/VirtualBox/include/COMWrappers.h
42 * (smart Qt-based C++ wrapper classes for COM interfaces
43 * of the Main API)
44 *
45 * 7. src/VBox/Installer/win32/VirtualBox_TypeLib.xsl =>
46 * out/<platform>/obj/src/VBox/Installer/win32/VirtualBox_TypeLib.wxi
47 * (Main API TypeLib block for the WiX installer)
48 *
49 Copyright (C) 2006-2007 Sun Microsystems, Inc.
50
51 This file is part of VirtualBox Open Source Edition (OSE), as
52 available from http://www.virtualbox.org. This file is free software;
53 you can redistribute it and/or modify it under the terms of the GNU
54 General Public License (GPL) as published by the Free Software
55 Foundation, in version 2 as it comes in the "COPYING" file of the
56 VirtualBox OSE distribution. VirtualBox OSE is distributed in the
57 hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
58
59 Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
60 Clara, CA 95054 USA or visit http://www.sun.com if you need
61 additional information or have any questions.
62-->
63
64<idl>
65
66<if target="midl">
67 <cpp line="enum {"/>
68 <cpp line=" kTypeLibraryMajorVersion = 1,"/>
69 <cpp line=" kTypeLibraryMinorVersion = 0"/>
70 <cpp line="};"/>
71</if>
72
73<if target="xpidl">
74 <!-- NS_IMPL_THREADSAFE_ISUPPORTSxx_CI macros are placed here, for convenience -->
75 <cpp>
76// currenty, nsISupportsImpl.h lacks the below-like macros
77#ifndef NS_IMPL_THREADSAFE_ISUPPORTS1_CI
78#define NS_IMPL_THREADSAFE_ISUPPORTS1_CI(_class, _interface) \
79 NS_IMPL_THREADSAFE_ADDREF(_class) \
80 NS_IMPL_THREADSAFE_RELEASE(_class) \
81 NS_IMPL_QUERY_INTERFACE1_CI(_class, _interface) \
82 NS_IMPL_CI_INTERFACE_GETTER1(_class, _interface)
83#endif
84#ifndef NS_IMPL_THREADSAFE_ISUPPORTS2_CI
85#define NS_IMPL_THREADSAFE_ISUPPORTS2_CI(_class, _i1, _i2) \
86 NS_IMPL_THREADSAFE_ADDREF(_class) \
87 NS_IMPL_THREADSAFE_RELEASE(_class) \
88 NS_IMPL_QUERY_INTERFACE2_CI(_class, _i1, _i2) \
89 NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
90#endif
91 </cpp>
92</if>
93
94<library
95 name="VirtualBox"
96 uuid="46137EEC-703B-4fe5-AFD4-7C9BBBBA0259"
97 version="1.3"
98 desc="VirtualBox Type Library"
99 appUuid="819B4D85-9CEE-493C-B6FC-64FFE759B3C9"
100 supportsErrorInfo="yes"
101>
102
103 <!--
104 // all common enums
105 /////////////////////////////////////////////////////////////////////////
106 -->
107
108 <enum
109 name="TSBool"
110 uuid="523ff64d-842a-4b1a-80e7-c311b028cb3a"
111 >
112 <desc>
113 Boolean variable having a third state, default.
114 </desc>
115
116 <const name="False" value="0"/>
117 <const name="True" value="1"/>
118 <const name="Default" value="2"/>
119 </enum>
120
121 <enum
122 name="MachineState"
123 uuid="73bf04d0-7c4f-4684-9abf-d65a9ad74343"
124 >
125 <desc>
126 Virtual machine execution state. This enumeration represents possible
127 values of the <link to="IMachine::state"/> attribute.
128 </desc>
129
130 <const name="Null" value="0">
131 <desc><tt>null</tt> value. Never used by the API.</desc>
132 </const>
133 <const name="PoweredOff" value="1">
134 <desc>
135 The machine is not running.
136 </desc>
137 </const>
138 <const name="Saved" value="2">
139 <desc>
140 The machine is not currently running, but the execution state
141 of the machine has been saved to an external file when it
142 was running.
143 <note>
144 No any machine settings can be altered when the machine
145 is in this state.
146 </note>
147 </desc>
148 </const>
149 <const name="Aborted" value="3">
150 <desc>
151 A process that run the machine has abnormally terminated.
152 Other than that, this value is equivalent to #PoweredOff.
153 </desc>
154 </const>
155 <const name="Running" value="4">
156 <desc>
157 The machine is currently being executed.
158 <note>
159 This value can be used in comparison expressions:
160 all state values below it describe a virtual machine that is
161 not currently being executed (i.e., it is completely out of
162 action).
163 </note>
164 <note>
165 For whoever decides to touch this enum: In order to keep the
166 aforementioned comparisons valid, this state must immediately
167 preceed the Paused state.
168 </note>
169 </desc>
170 </const>
171 <const name="Paused" value="5">
172 <desc>
173 The execution of the machine has been paused.
174 <note>
175 This value can be used in comparison expressions: all state values
176 above it represent unstable states of the running virtual
177 machine. Unless explicitly stated otherwise, no machine settings can
178 be altered when it is in one of the unstable sates.
179 </note>
180 <note>
181 For whoever decides to touch this enum: In order to keep the
182 aforementioned comparisons valid, this state must immediately
183 follow the Running state.
184 </note>
185 </desc>
186 </const>
187 <const name="Stuck" value="6">
188 <desc>
189 The execution of the machine has reached the Guru Meditaion
190 condition. This condition indicates an internal VMM failure which may
191 happen as a result of either an unhandled low-level virtual hardware
192 exception or one of the recompiler exceptions (such as
193 the <i>too-many-traps</i> condition).
194 </desc>
195 </const>
196 <const name="Starting" value="7">
197 <desc>
198 The machine is being started after
199 <link to="IConsole::powerUp">powering it on</link> from a
200 zero execution state.
201 </desc>
202 </const>
203 <const name="Stopping" value="8">
204 <desc>
205 The machine is being normally stopped
206 (after explicitly <link to="IConsole::powerDown">powering it off</link>,
207 or after the guest OS has initiated a shutdown sequence).
208 </desc>
209 </const>
210 <const name="Saving" value="9">
211 <desc>
212 The machine is saving its execution state to a file as a
213 result of calling <link to="IConsole::saveState"/> or an online
214 snapshot of the machine is being taken using
215 <link to="IConsole::takeSnapshot"/>.
216 </desc>
217 </const>
218 <const name="Restoring" value="10">
219 <desc>
220 The execution state of the machine is being restored from a file
221 after <link to="IConsole::powerUp">powering it on</link> from
222 a saved execution state.
223 </desc>
224 </const>
225 <const name="Discarding" value="11">
226 <desc>
227 A snapshot of the machine is being discarded after calling
228 <link to="IConsole::discardSnapshot"/> or its current state is
229 being discarded after <link to="IConsole::discardCurrentState"/>.
230 </desc>
231 </const>
232 </enum>
233
234 <enum
235 name="SessionState"
236 uuid="CF2700C0-EA4B-47ae-9725-7810114B94D8"
237 >
238 <desc>
239 Session state. This enumeration represents possible values of
240 <link to="IMachine::sessionState"/> and <link to="ISession::state"/>
241 attributes. Idividual value descriptions contain the appropriate
242 meaning for every case.
243 </desc>
244
245 <const name="Null" value="0">
246 <desc><tt>null</tt> value. Never used by the API.</desc>
247 </const>
248 <const name="Closed" value="1">
249 <desc>
250 The machine has no open sessions (<link to="IMachine::sessionState"/>);
251 the session is closed (<link to="ISession::state"/>)
252 </desc>
253 </const>
254 <const name="Open" value="2">
255 <desc>
256 The machine has an open direct session (<link to="IMachine::sessionState"/>);
257 the session is open (<link to="ISession::state"/>)
258 </desc>
259 </const>
260 <const name="Spawning" value="3">
261 <desc>
262 A new (direct) session is being opened for the machine
263 as a result of <link to="IVirtualBox::openRemoteSession()"/>
264 call (<link to="IMachine::sessionState"/>);
265 the session is currently being opened
266 as a result of <link to="IVirtualBox::openRemoteSession()"/>
267 call (<link to="ISession::state"/>)
268 </desc>
269 </const>
270 <const name="Closing" value="4">
271 <desc>
272 The direct session is being closed (<link to="IMachine::sessionState"/>);
273 the session is being closed (<link to="ISession::state"/>)
274 </desc>
275 </const>
276 </enum>
277
278 <enum
279 name="SessionType"
280 uuid="A13C02CB-0C2C-421E-8317-AC0E8AAA153A"
281 >
282 <desc>
283 Session type. This enumeration represents possible values of the
284 <link to="ISession::type"/> attribute.
285 </desc>
286
287 <const name="Null" value="0">
288 <desc><tt>null</tt> value. Never used by the API.</desc>
289 </const>
290 <const name="Direct" value="1">
291 <desc>
292 Direct session
293 (opened by <link to="IVirtualBox::openSession()"/>)
294 </desc>
295 </const>
296 <const name="Remote" value="2">
297 <desc>
298 Remote session
299 (opened by <link to="IVirtualBox::openRemoteSession()"/>)
300 </desc>
301 </const>
302 <const name="Existing" value="3">
303 <desc>
304 Existing session
305 (opened by <link to="IVirtualBox::openExistingSession()"/>)
306 </desc>
307 </const>
308 </enum>
309
310 <enum
311 name="DeviceType"
312 uuid="6d9420f7-0b56-4636-99f9-7346f1b01e57"
313 >
314 <desc>
315 Device type.
316 </desc>
317 <const name="Null" value="0">
318 <desc>
319 <tt>null</tt> value which may also mean "no device".
320 <note>
321 This value is not allowed for
322 <link to="IConsole::getDeviceActivity"/>
323 </note>
324 </desc>
325 </const>
326 <const name="Floppy" value="1">
327 <desc>Floppy device.</desc>
328 </const>
329 <const name="DVD" value="2">
330 <desc>CD/DVD-ROM device.</desc>
331 </const>
332 <const name="HardDisk" value="3">
333 <desc>Hard disk device.</desc>
334 </const>
335 <const name="Network" value="4">
336 <desc>Network device.</desc>
337 </const>
338 <const name="USB" value="5">
339 <desc>USB device.</desc>
340 </const>
341 <const name="SharedFolder" value="6">
342 <desc>Shared folder device.</desc>
343 </const>
344 </enum>
345
346 <enum
347 name="DeviceActivity"
348 uuid="6FC8AEAA-130A-4eb5-8954-3F921422D707"
349 >
350 <desc>
351 Device activity for <link to="IConsole::getDeviceActivity"/>.
352 </desc>
353
354 <const name="Null" value="0"/>
355 <const name="Idle" value="1"/>
356 <const name="Reading" value="2"/>
357 <const name="Writing" value="3"/>
358 </enum>
359
360 <enum
361 name="ResourceUsage"
362 uuid="FC56E4B6-B195-48e2-A5E1-A667B0D9F809"
363 >
364 <desc>
365 Usage type constants for
366 <link to="IVirtualBox::getDVDImageUsage"/> and
367 <link to="IVirtualBox::getFloppyImageUsage"/>.
368 </desc>
369
370 <const name="Null" value="0">
371 <desc><tt>null</tt> value. Never used by the API.</desc>
372 </const>
373 <const name="Permanent" value="1">
374 <desc>
375 Scopes the VMs that use the resource permanently
376 (the information about this usage is stored in the VM
377 settings file).
378 </desc>
379 </const>
380 <const name="Temporary" value="2">
381 <desc>
382 Scopes the VMs that are temporarily using the resource
383 (the information about the usage is not yet saved in the VM
384 settings file). Temporary usage can take place only in the
385 context of an open session.
386 </desc>
387 </const>
388 <const name="All" value="3">
389 <desc>
390 Combines Permanent and Temporary.
391 </desc>
392 </const>
393 </enum>
394
395 <enum
396 name="StorageBus"
397 uuid="715984a5-093c-43bb-aa42-a16ed16828dd"
398 >
399 <desc>Interface bus type for storage devices.</desc>
400
401 <const name="Null" value="0">
402 <desc><tt>null</tt> value. Never used by the API.</desc>
403 </const>
404
405 <const name="IDE" value="1"/>
406 <const name="SATA" value="2"/>
407 </enum>
408
409 <enum
410 name="ClipboardMode"
411 uuid="33364716-4008-4701-8f14-be0fa3d62950"
412 >
413 <desc>
414 Host-Guest clipboard interchange mode.
415 </desc>
416
417 <const name="Disabled" value="0"/>
418 <const name="HostToGuest" value="1"/>
419 <const name="GuestToHost" value="2"/>
420 <const name="Bidirectional" value="3"/>
421 </enum>
422
423 <enum
424 name="Scope"
425 uuid="7c91096e-499e-4eca-9f9b-9001438d7855"
426 >
427 <desc>
428 Scope of the operation.
429
430 A generic enumeration used in various methods to define the action or
431 argument scope.
432 </desc>
433
434 <const name="Global" value="0"/>
435 <const name="Machine" value="1"/>
436 <const name="Session" value="2"/>
437 </enum>
438
439 <enum
440 name="GuestStatisticType"
441 uuid="aa7c1d71-aafe-47a8-9608-27d2d337cf55"
442 >
443 <desc>
444 Statistics type for <link to="IGuest::getStatistic"/>.
445 </desc>
446
447 <const name="CPULoad_Idle" value="0">
448 <desc>
449 Idle CPU load (0-100%) for last interval.
450 </desc>
451 </const>
452 <const name="CPULoad_Kernel" value="1">
453 <desc>
454 Kernel CPU load (0-100%) for last interval.
455 </desc>
456 </const>
457 <const name="CPULoad_User" value="2">
458 <desc>
459 User CPU load (0-100%) for last interval.
460 </desc>
461 </const>
462 <const name="Threads" value="3">
463 <desc>
464 Total number of threads in the system.
465 </desc>
466 </const>
467 <const name="Processes" value="4">
468 <desc>
469 Total number of processes in the system.
470 </desc>
471 </const>
472 <const name="Handles" value="5">
473 <desc>
474 Total number of handles in the system.
475 </desc>
476 </const>
477 <const name="MemoryLoad" value="6">
478 <desc>
479 Memory load (0-100%).
480 </desc>
481 </const>
482 <const name="PhysMemTotal" value="7">
483 <desc>
484 Total physical memory in megabytes.
485 </desc>
486 </const>
487 <const name="PhysMemAvailable" value="8">
488 <desc>
489 Free physical memory in megabytes.
490 </desc>
491 </const>
492 <const name="PhysMemBalloon" value="9">
493 <desc>
494 Ballooned physical memory in megabytes.
495 </desc>
496 </const>
497 <const name="MemCommitTotal" value="10">
498 <desc>
499 Total amount of memory in the committed state in megabytes.
500 </desc>
501 </const>
502 <const name="MemKernelTotal" value="11">
503 <desc>
504 Total amount of memory used by the guest OS's kernel in megabytes.
505 </desc>
506 </const>
507 <const name="MemKernelPaged" value="12">
508 <desc>
509 Total amount of paged memory used by the guest OS's kernel in megabytes.
510 </desc>
511 </const>
512 <const name="MemKernelNonpaged" value="13">
513 <desc>
514 Total amount of nonpaged memory used by the guest OS's kernel in megabytes.
515 </desc>
516 </const>
517 <const name="MemSystemCache" value="14">
518 <desc>
519 Total amount of memory used by the guest OS's system cache in megabytes.
520 </desc>
521 </const>
522 <const name="PageFileSize" value="15">
523 <desc>
524 Pagefile size in megabytes.
525 </desc>
526 </const>
527 <const name="SampleNumber" value="16">
528 <desc>
529 Statistics sample number
530 </desc>
531 </const>
532 <const name="MaxVal" value="17"/>
533 </enum>
534
535 <enum
536 name="BIOSBootMenuMode"
537 uuid="ae4fb9f7-29d2-45b4-b2c7-d579603135d5"
538 >
539 <desc>
540 BIOS boot menu mode.
541 </desc>
542
543 <const name="Disabled" value="0"/>
544 <const name="MenuOnly" value="1"/>
545 <const name="MessageAndMenu" value="2"/>
546 </enum>
547
548 <enum
549 name="IDEControllerType"
550 uuid="445330e3-202a-4dab-854f-ce22e6cb9715"
551 >
552 <desc>
553 IDE controller type.
554 </desc>
555
556 <const name="Null" value="0">
557 <desc><tt>null</tt> value. Never used by the API.</desc>
558 </const>
559 <const name="PIIX3" value="1"/>
560 <const name="PIIX4" value="2"/>
561 </enum>
562
563 <enum
564 name="DriveState"
565 uuid="cb7233b7-c519-42a5-8310-1830953cacbc"
566 >
567 <const name="Null" value="0">
568 <desc><tt>null</tt> value. Never used by the API.</desc>
569 </const>
570 <const name="NotMounted" value="1"/>
571 <const name="ImageMounted" value="2"/>
572 <const name="HostDriveCaptured" value="3"/>
573 </enum>
574
575 <!--
576 // IVirtualBoxErrorInfo
577 /////////////////////////////////////////////////////////////////////////
578 -->
579
580 <interface
581 name="IVirtualBoxErrorInfo" extends="$errorinfo"
582 uuid="e98b5376-8eb4-4eea-812a-3964bf3bb26f"
583 supportsErrorInfo="no"
584 wsmap="suppress"
585 >
586 <desc>
587 The IVirtualBoxErrorInfo interface represents extended error information.
588
589 Extended error information can be set by VirtualBox components after
590 unsuccessful or partially successful method invocation. This information
591 can be retrievefd by the calling party as an IVirtualBoxErrorInfo object
592 and then shown to the client in addition to the plain 32-bit result code.
593
594 In MS COM, this interface extends the IErrorInfo interface,
595 in XPCOM, it extends the nsIException interface. In both cases,
596 it provides a set of common attributes to retrieve error
597 information.
598
599 Sometimes invocation of some component's method may involve methods of
600 other components that may also fail (independently of this method's
601 failure), or a series of non-fatal errors may precede a fatal error that
602 causes method failure. In cases like that, it may be desirable to preserve
603 information about all errors happened during method invocation and deliver
604 it to the caller. The <link to="#next"/> attribute is intended
605 specifically for this purpose and allows to represent a chain of errors
606 through a single IVirtualBoxErrorInfo object set after method invocation.
607
608 Note that errors are stored to a chain in the reverse order, i.e. the
609 initial error object you query right after method invocation is the last
610 error set by the callee, the object it points to in the @a next attribute
611 is the previous error and so on, up to the first error (which is the last
612 in the chain).
613 </desc>
614
615 <attribute name="resultCode" type="result" readonly="yes">
616 <desc>
617 Result code of the error.
618 Usually, it will be the same as the result code returned
619 by the method that provided this error information, but not
620 always. For example, on Win32, CoCreateInstance() will most
621 likely return E_NOINTERFACE upon unsuccessful component
622 instantiation attempt, but not the value the component factory
623 returned.
624 <note>
625 In MS COM, there is no equivalent.
626 In XPCOM, it is the same as nsIException::result.
627 </note>
628 </desc>
629 </attribute>
630
631 <attribute name="interfaceID" type="uuid" readonly="yes">
632 <desc>
633 UUID of the interface that defined the error.
634 <note>
635 In MS COM, it is the same as IErrorInfo::GetGUID.
636 In XPCOM, there is no equivalent.
637 </note>
638 </desc>
639 </attribute>
640
641 <attribute name="component" type="wstring" readonly="yes">
642 <desc>
643 Name of the component that generated the error.
644 <note>
645 In MS COM, it is the same as IErrorInfo::GetSource.
646 In XPCOM, there is no equivalent.
647 </note>
648 </desc>
649 </attribute>
650
651 <attribute name="text" type="wstring" readonly="yes">
652 <desc>
653 Text description of the error.
654 <note>
655 In MS COM, it is the same as IErrorInfo::GetDescription.
656 In XPCOM, it is the same as nsIException::message.
657 </note>
658 </desc>
659 </attribute>
660
661 <attribute name="next" type="IVirtualBoxErrorInfo" readonly="yes">
662 <desc>
663 Next error object if there is any, or @c null otherwise.
664 <note>
665 In MS COM, there is no equivalent.
666 In XPCOM, it is the same as nsIException::inner.
667 </note>
668 </desc>
669 </attribute>
670
671 </interface>
672
673
674 <!--
675 // IVirtualBox
676 /////////////////////////////////////////////////////////////////////////
677 -->
678
679 <interface
680 name="IVirtualBoxCallback" extends="$unknown"
681 uuid="ee95ffc2-b6c6-4ce8-9e9e-ceadbb5019fe"
682 wsmap="suppress"
683 >
684 <method name="onMachineStateChange">
685 <desc>
686 The execution state of the given machine has changed.
687 <see>IMachine::state</see>
688 </desc>
689 <param name="machineId" type="uuid" dir="in">
690 <desc>ID of the machine this event relates to.</desc>
691 </param>
692 <param name="state" type="MachineState" dir="in">
693 <desc>New execution state.</desc>
694 </param>
695 </method>
696
697 <method name="onMachineDataChange">
698 <desc>
699 Any of the settings of the given machine has changed.
700 </desc>
701 <param name="machineId" type="uuid" dir="in">
702 <desc>ID of the machine this event relates to.</desc>
703 </param>
704 </method>
705
706 <method name="onExtraDataCanChange">
707 <desc>
708 Notification when someone tries to change extra data for
709 either the given machine or (if null) global extra data.
710 This gives the chance to veto against changes.
711 </desc>
712 <param name="machineId" type="uuid" dir="in">
713 <desc>
714 ID of the machine this event relates to
715 (null ID for global extra data change requests).
716 </desc>
717 </param>
718 <param name="key" type="wstring" dir="in">
719 <desc>
720 Extra data key for the attempted write.
721 </desc>
722 </param>
723 <param name="value" type="wstring" dir="in">
724 <desc>
725 Extra data value for the given key.
726 </desc>
727 </param>
728 <param name="error" type="wstring" dir="out">
729 <desc>
730 Optional error message describing the reason of the
731 veto (ignored if this notification returns @c true).
732 </desc>
733 </param>
734 <param name="allowChange" type="boolean" dir="return">
735 <desc>
736 Flag to indicate whether the callee agrees (@ true)
737 or vetoes against the change (@ false).
738 </desc>
739 </param>
740 </method>
741
742 <method name="onExtraDataChange">
743 <desc>
744 Notification when machine specific or global extra data
745 has changed.
746 </desc>
747 <param name="machineId" type="uuid" dir="in">
748 <desc>
749 ID of the machine this event relates to.
750 Null for global extra data changes.
751 </desc>
752 </param>
753 <param name="key" type="wstring" dir="in">
754 <desc>
755 Extra data key that has changed.
756 </desc>
757 </param>
758 <param name="value" type="wstring" dir="in">
759 <desc>
760 Extra data value for the given key.
761 </desc>
762 </param>
763 </method>
764
765 <method name="onMediaRegistered">
766 <desc>
767 The given media was registered or unregistered
768 within this VirtualBox installation.
769
770 The @a mediaType parameter describes what type of
771 media the specified @a mediaId refers to. Possible
772 values are:
773
774 - <link to="DeviceType::HardDisk"/>: the media is a hard disk
775 that, if registered, can be obtained using the
776 <link to="IVirtualBox::getHardDisk"/> call.
777 - <link to="DeviceType::DVD"/>: the media is a CD/DVD image
778 that, if registered, can be obtained using the
779 <link to="IVirtualBox::getDVDImage"/> call.
780 - <link to="DeviceType::Floppy"/>: the media is a Floppy image
781 that, if registered, can be obtained using the
782 <link to="IVirtualBox::getFloppyImage"/> call.
783
784 Note that if this is a deregistration notification,
785 there is no way to access the object representing the
786 unregistered media. It is supposed that the
787 application will do required cleanup based on the @a
788 mediaId value.
789 </desc>
790 <param name="mediaId" type="uuid" dir="in">
791 <desc>ID of the media this event relates to.</desc>
792 </param>
793 <param name="mediaType" type="DeviceType" dir="in">
794 <desc>Type of the media this event relates to.</desc>
795 </param>
796 <param name="registered" type="boolean" dir="in">
797 <desc>
798 If true, the media was registered, otherwise it was
799 unregistered.
800 </desc>
801 </param>
802 </method>
803
804 <method name="onMachineRegistered">
805 <desc>
806 The given machine was registered or unregistered
807 within this VirtualBox installation.
808 </desc>
809 <param name="machineId" type="uuid" dir="in">
810 <desc>ID of the machine this event relates to.</desc>
811 </param>
812 <param name="registered" type="boolean" dir="in">
813 <desc>
814 If true, the machine was registered, otherwise it was
815 unregistered.
816 </desc>
817 </param>
818 </method>
819
820 <method name="onSessionStateChange">
821 <desc>
822 The state of the session for the given machine was changed.
823 <see>IMachine::sessionState</see>
824 </desc>
825 <param name="machineId" type="uuid" dir="in">
826 <desc>ID of the machine this event relates to.</desc>
827 </param>
828 <param name="state" type="SessionState" dir="in">
829 <desc>New session state.</desc>
830 </param>
831 </method>
832
833 <method name="onSnapshotTaken">
834 <desc>
835 A new snapshot of the machine has been taken.
836 <see>ISnapshot</see>
837 </desc>
838 <param name="machineId" type="uuid" dir="in">
839 <desc>ID of the machine this event relates to.</desc>
840 </param>
841 <param name="snapshotId" type="uuid" dir="in">
842 <desc>ID of the new snapshot.</desc>
843 </param>
844 </method>
845
846 <method name="onSnapshotDiscarded">
847 <desc>
848 Snapshot of the given machine has been discarded.
849
850 <note>
851 This notification is delivered <b>after</b> the snapshot
852 object has been uninitialized on the server (so that any
853 attempt to call its methods will return an error).
854 </note>
855
856 <see>ISnapshot</see>
857 </desc>
858 <param name="machineId" type="uuid" dir="in">
859 <desc>ID of the machine this event relates to.</desc>
860 </param>
861 <param name="snapshotId" type="uuid" dir="in">
862 <desc>
863 ID of the discarded snapshot. <tt>null</tt> means the
864 current machine state has been discarded (restored from
865 the current snapshot).
866 </desc>
867 </param>
868 </method>
869
870 <method name="onSnapshotChange">
871 <desc>
872 Snapshot properties (name and/or description) have been changed.
873 <see>ISnapshot</see>
874 </desc>
875 <param name="machineId" type="uuid" dir="in">
876 <desc>ID of the machine this event relates to.</desc>
877 </param>
878 <param name="snapshotId" type="uuid" dir="in">
879 <desc>ID of the changed snapshot.</desc>
880 </param>
881 </method>
882
883 </interface>
884
885 <interface
886 name="IVirtualBox" extends="$dispatched"
887 uuid="2d3b9ea7-25f5-4f07-a8e1-7dd7e0dcf667"
888 wsmap="managed"
889 >
890 <desc>
891 The IVirtualBox interface represents the main interface exposed by the
892 product that provides virtual machine management.
893
894 An instance of IVirtualBox is required for the product to do anything
895 useful. Even though the interface does not expose this, internally,
896 IVirtualBox is implemented as a singleton and actually lives in the
897 process of the VirtualBox server (VBoxSVC.exe). This makes sure that
898 IVirtualBox can track the state of all virtual machines on a particular
899 host, regardless of which frontend started them.
900
901 To enumerate all the virtual machines on the host, use the
902 <link to="IVirtualBox::machines"/> attribute.
903 </desc>
904
905 <attribute name="version" type="wstring" readonly="yes">
906 <desc>
907 A string representing the version number of the product. The
908 format is 3 integer numbers divided by dots (e.g. 1.0.1). The
909 last number represents the build number and will frequently change.
910 </desc>
911 </attribute>
912
913 <attribute name="homeFolder" type="wstring" readonly="yes">
914 <desc>
915 Full path to the directory where the global settings file,
916 <tt>VirtualBox.xml</tt>, is stored.
917
918 In this version of VirtualBox, the value of this property is
919 always <tt>&lt;user_dir&gt;/.VirtualBox</tt> (where
920 <tt>&lt;user_dir&gt;</tt> is the path to the user directory,
921 as determined by the host OS), and cannot be changed.
922
923 This path is also used as the base to resolve relative paths in
924 places where relative paths are allowed (unless otherwise
925 expressly indicated).
926 </desc>
927 </attribute>
928
929 <attribute name="settingsFilePath" type="wstring" readonly="yes">
930 <desc>
931 Full name of the global settings file.
932 The value of this property corresponds to the value of
933 <link to="#homeFolder"/> plus <tt>/VirtualBox.xml</tt>.
934 </desc>
935 </attribute>
936
937 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
938 <desc>
939 Current version of the format of the global VirtualBox settings file
940 (<tt>VirtualBox.xml</tt>).
941
942 The version string has the following format:
943 <pre>
944 x.y-platform
945 </pre>
946 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
947 versions, and <tt>platform</tt> is the platform identifier.
948
949 The current version usually matches the value of the
950 <link to="#settingsFormatVersion"/> attribute unless the
951 settings file was created by an older version of VirtualBox and there
952 was a change of the settings file format since then.
953
954 Note that VirtualBox automatically converts settings files from older
955 versions to the most recent version when reading them (usually at
956 VirtualBox startup) but it doesn't save the changes back until
957 you call a method that implicitly saves settings (such as
958 <link to="#setExtraData()"/>) or call <link to="#saveSettings()"/>
959 explicitly. Therefore, if the value of this attribute differs from the
960 value of <link to="#settingsFormatVersion"/>, then it
961 means that the settings file was converted but the result of the
962 conversion is not yet saved to disk.
963
964 The above feature may be used by interactive front-ends to inform users
965 about the settings file format change and offer them to explicitly save
966 all converted settings files (the global and VM-specific ones),
967 optionally create bacup copies of the old settings files before saving,
968 etc.
969
970 <see>settingsFormatVersion, saveSettingsWithBackup()</see>
971 </desc>
972 </attribute>
973
974 <attribute name="settingsFormatVersion" type="wstring" readonly="yes">
975 <desc>
976 Most recent version of the settings file format.
977
978 The version string has the following format:
979 <pre>
980 x.y-platform
981 </pre>
982 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
983 versions, and <tt>platform</tt> is the platform identifier.
984
985 VirtualBox uses this version of the format when saving settings files
986 (either as a result of method calls that require to save settings or as
987 a result of an explicit call to <link to="#saveSettings()"/>).
988
989 <see>settingsFileVersion</see>
990 </desc>
991 </attribute>
992
993 <attribute name="host" type="IHost" readonly="yes">
994 <desc>Associated host object.</desc>
995 </attribute>
996
997 <attribute name="systemProperties" type="ISystemProperties" readonly="yes">
998 <desc>Associated system information object.</desc>
999 </attribute>
1000
1001 <attribute name="machines" type="IMachineCollection" readonly="yes">
1002 <desc>
1003 Collection of machine objects registered within this VirtualBox
1004 instance.
1005 </desc>
1006 </attribute>
1007
1008 <attribute name="machines2" type="IMachine" readonly="yes" safearray="yes">
1009 <desc>
1010 Array of machine objects registered within this VirtualBox instance.
1011 </desc>
1012 </attribute>
1013
1014 <attribute name="hardDisks" type="IHardDiskCollection" readonly="yes">
1015 <desc>
1016 Collection of hard disk objects registered within this VirtualBox
1017 instance.
1018
1019 This collection contains only "top-level" (basic or independent) hard
1020 disk images, but not differencing ones. All differencing images of the
1021 given top-level image (i.e. all its children) can be enumerated using
1022 <link to="IHardDisk::children"/>.
1023 </desc>
1024 </attribute>
1025
1026 <attribute name="DVDImages" type="IDVDImageCollection" readonly="yes"/>
1027
1028 <attribute name="FloppyImages" type="IFloppyImageCollection" readonly="yes"/>
1029
1030 <attribute name="progressOperations" type="IProgressCollection" readonly="yes"/>
1031
1032 <attribute name="guestOSTypes" type="IGuestOSTypeCollection" readonly="yes"/>
1033
1034 <attribute name="sharedFolders" type="ISharedFolderCollection" readonly="yes">
1035 <desc>
1036 Collection of global shared folders. Global shared folders are
1037 available to all virtual machines.
1038
1039 New shared folders are added to the collection using
1040 <link to="#createSharedFolder"/>. Existing shared folders can be
1041 removed using <link to="#removeSharedFolder"/>.
1042
1043 <note>
1044 In the current version of the product, global shared folders are not
1045 implemented and therefore this collection is always empty.
1046 </note>
1047 </desc>
1048 </attribute>
1049
1050 <method name="createMachine">
1051 <desc>
1052 Creates a new virtual machine.
1053
1054 The new machine will have "empty" default settings and will not
1055 yet be registered. The typical sequence to create a virtual machine
1056 is therefore something like this:
1057
1058 <ol>
1059 <li>Call this method (IVirtualBox::createMachine) to have a new
1060 machine created. The machine object returned is "mutable", i.e.
1061 automatically locked for the current session, as if
1062 <link to="#openSession" /> had been called on it.</li>
1063
1064 <li>Assign meaningful settings to the new machine by calling the
1065 respective methods.</li>
1066
1067 <li>Call <link to="IMachine::saveSettings" /> to have the settings written
1068 to the machine's XML settings file. The configuration of the newly
1069 created machine will not be saved to disk (and the settings subfolder
1070 and file, as described below, will not be created) until this method
1071 is called.</li>
1072
1073 <li>Call <link to="#registerMachine" /> to have the
1074 machine show up in the list of machines registered with VirtualBox.</li>
1075 </ol>
1076
1077 Every machine has a <i>settings file</i> that is used to store
1078 the machine configuration. This file is stored in the directory
1079 called <i>machine settings subfolder</i>. Unless specified otherwise,
1080 both the subfolder and the settings file will have a name that
1081 corresponds to the name of the virtual machine. You can specify
1082 where to create the machine settings subfolder using the @a
1083 baseFolder argument. The base folder can be absolute (full path)
1084 or relative to the <link to="IVirtualBox::homeFolder">
1085 VirtualBox home directory</link>.
1086
1087 If a null or empty string is given as the base folder (which is
1088 recommended), the <link to="ISystemProperties::defaultMachineFolder">
1089 default machine settings folder</link> will be used as the base
1090 folder to create the machine settings subfolder and file. In
1091 any case, the full path to the settings file will look like:
1092 <pre>
1093 &lt;base_folder&gt;/&lt;machine_name&gt;/&lt;machine_name&gt;.xml
1094 </pre>
1095
1096 Optionally the UUID of the machine can be predefined. If this is
1097 not desired (i.e. a new UUID should be generated), pass just an
1098 empty or null UUID.
1099
1100 You should also specify a valid name for the machine.
1101 See the <link to="IMachine::name"/> property
1102 description for more details about the machine name.
1103
1104 The created machine remains
1105 unregistered until you call <link to="#registerMachine()"/>.
1106
1107 <note>
1108 There is no way to change the name of the settings file or
1109 subfolder of the created machine directly.
1110 </note>
1111 </desc>
1112 <param name="baseFolder" type="wstring" dir="in">
1113 <desc>
1114 Name of the folder where to create the machine settings
1115 subfolder containing the settings file.
1116 </desc>
1117 </param>
1118 <param name="name" type="wstring" dir="in">
1119 <desc>Machine name.</desc>
1120 </param>
1121 <param name="id" type="uuid" dir="in">
1122 <desc>
1123 UUID of the newly created VM, when non-null or non-empty.
1124 Otherwise a UUID is automatically generated.
1125 </desc>
1126 </param>
1127 <param name="machine" type="IMachine" dir="return">
1128 <desc>Created machine object.</desc>
1129 </param>
1130 </method>
1131
1132 <method name="createLegacyMachine">
1133 <desc>
1134 Creates a new virtual machine in "legacy" mode, using the
1135 specified settings file to store machine settings.
1136
1137 As opposed to machines created by <link to="#createMachine()"/>,
1138 the settings file of the machine created in "legacy" mode
1139 is not automatically renamed when the machine name is
1140 changed -- it will always remain the same as specified in this
1141 method call.
1142
1143 The specified settings file name can be absolute
1144 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1145 VirtualBox home directory</link>. If the file name doesn't
1146 contain an extension, the default extension (.xml) will be
1147 appended.
1148
1149 Optionally the UUID of the machine can be predefined. If this is
1150 not desired (i.e. a new UUID should be generated), pass just an
1151 empty or null UUID.
1152
1153 Note that the configuration of the newly created machine is not
1154 saved to disk (and therefore no settings file is created)
1155 until <link to="IMachine::saveSettings()"/> is called. If the
1156 specified settings file already exists,
1157 <link to="IMachine::saveSettings()"/> will return an error.
1158
1159 You should also specify a valid name for the machine.
1160 See the <link to="IMachine::name"/> property
1161 description for more details about the machine name.
1162
1163 The created machine remains
1164 unregistered until you call <link to="#registerMachine()"/>.
1165
1166 @deprecated This method may be removed later. It is better
1167 to use <link to="IVirtualBox::createMachine()"/>.
1168
1169 <note>
1170 There is no way to change the name of the settings file
1171 of the created machine.
1172 </note>
1173 </desc>
1174 <param name="settingsFile" type="wstring" dir="in">
1175 <desc>
1176 Name of the file where to store machine settings.
1177 </desc>
1178 </param>
1179 <param name="name" type="wstring" dir="in">
1180 <desc>Machine name.</desc>
1181 </param>
1182 <param name="id" type="uuid" dir="in">
1183 <desc>
1184 UUID of the newly created VM, when non-null or non-empty.
1185 Otherwise a UUID is automatically generated.
1186 </desc>
1187 </param>
1188 <param name="machine" type="IMachine" dir="return">
1189 <desc>Created machine object.</desc>
1190 </param>
1191 </method>
1192
1193 <method name="openMachine">
1194 <desc>
1195 Opens a virtual machine from the existing settings file.
1196 The opened machine remains unregistered until you call
1197 <link to="#registerMachine()"/>.
1198
1199 The specified settings file name can be absolute
1200 (full path) or relative to the <link to="IVirtualBox::homeFolder">
1201 VirtualBox home directory</link>. This file must exist
1202 and must be a valid machine settings file whose contents
1203 will be used to construct the machine object.
1204
1205 @deprecated Will be removed soon.
1206 </desc>
1207 <param name="settingsFile" type="wstring" dir="in">
1208 <desc>
1209 Name of the machine settings file.
1210 </desc>
1211 </param>
1212 <param name="machine" type="IMachine" dir="return">
1213 <desc>Opened machine object.</desc>
1214 </param>
1215 <note>
1216 <link to="IMachine::settingsModified"/> will return
1217 false for the created machine, until any of machine settigs
1218 are changed.
1219 </note>
1220 </method>
1221
1222 <method name="registerMachine">
1223 <desc>
1224
1225 Registers the machine previously created using
1226 <link to="#createMachine()"/> or opened using
1227 <link to="#openMachine()"/> within this VirtualBox installation. After
1228 successful method invocation, the
1229 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1230 to all registered callbacks.
1231
1232 <note>
1233 This method implicitly calls <link to="IMachine::saveSettings"/>
1234 to save all current machine settings before registering it.
1235 </note>
1236
1237 </desc>
1238 <param name="machine" type="IMachine" dir="in"/>
1239 </method>
1240
1241 <method name="getMachine">
1242 <desc>
1243 Attempts to find a virtual machine given its UUID.
1244 To look up a machine by name, use <link to="IVirtualBox::findMachine" /> instead.
1245 </desc>
1246 <param name="id" type="uuid" dir="in"/>
1247 <param name="machine" type="IMachine" dir="return"/>
1248 </method>
1249
1250 <method name="findMachine">
1251 <desc>
1252 Attempts to find a virtual machine given its name.
1253 To look up a machine by UUID, use <link to="IVirtualBox::getMachine" /> instead.
1254 </desc>
1255 <param name="name" type="wstring" dir="in"/>
1256 <param name="machine" type="IMachine" dir="return"/>
1257 </method>
1258
1259 <method name="unregisterMachine">
1260 <desc>
1261
1262 Unregisters the machine previously registered using
1263 <link to="#registerMachine"/>. After successful method invocation, the
1264 <link to="IVirtualBoxCallback::onMachineRegistered"/> signal is sent
1265 to all registered callbacks.
1266
1267 <note>
1268 The specified machine must not be in the Saved state, have an open
1269 (or a spawning) direct session associated with it, have snapshots or
1270 have hard disks attached.
1271 </note>
1272
1273 <note>
1274 This method implicitly calls <link to="IMachine::saveSettings"/> to
1275 save all current machine settings before unregistering it.
1276 </note>
1277
1278 <note>
1279 If the given machine is inaccessible (see
1280 <link to="IMachine::accessible"/>), it will be unregistered and
1281 fully uninitialized right afterwards. As a result, the returned
1282 machine object will be unusable and an attempt to call
1283 <b>any</b> method will return the "Object not ready" error.
1284 </note>
1285
1286 </desc>
1287 <param name="id" type="uuid" dir="in">
1288 <desc>UUID of the machine to unregister.</desc>
1289 </param>
1290 <param name="machine" type="IMachine" dir="return">
1291 <desc>Unregistered machine object.</desc>
1292 </param>
1293 </method>
1294
1295 <method name="createHardDisk">
1296 <desc>
1297
1298 Creates a new unregistered hard disk that will use the given
1299 storage type.
1300
1301 Most properties of the created hard disk object are
1302 uninitialized. Valid values must be assigned to them (and probalby
1303 some actions performed) to make the actual usage of this hard disk
1304 (<link to="#registerHardDisk()">register</link>, attach to a virtual
1305 machine, etc.). See the description of <link to="IHardDisk"/> and
1306 descriptions of storage type specific interfaces for more information.
1307
1308 <note>
1309 For hard disks using
1310 the <link
1311 to="HardDiskStorageType::VirtualDiskImage">VirtualDiskImage</link>
1312 storage type, an image file is not actually created until you call
1313 <link to="IVirtualDiskImage::createDynamicImage()"/> or
1314 <link to="IVirtualDiskImage::createFixedImage()"/>.
1315 </note>
1316
1317 </desc>
1318
1319 <param name="storageType" type="HardDiskStorageType" dir="in">
1320 <desc>Storage type of the hard disk image to create.</desc>
1321 </param>
1322 <param name="hardDisk" type="IHardDisk" dir="return">
1323 <desc>Created hard disk object of the given storage type.</desc>
1324 </param>
1325
1326 </method>
1327
1328 <method name="openHardDisk">
1329 <desc>
1330
1331 Opens a hard disk from an existing location.
1332
1333 This method tries to guess the
1334 <link to="HardDiskStorageType">hard disk storage type</link> from the
1335 format of the location string and from the contents of the resource the
1336 location points to. Currently, a <i>file path</i> is the only
1337 supported format for the location string which must point to either a
1338 VDI file or to a VMDK file. On success, an IHardDisk object will be
1339 returned that also implements the corresponding interface
1340 (IVirtualDiskImage or IVMDKImage, respectively). The
1341 <link to="IHardDisk::storageType"/> property may also be used to
1342 determine the storage type of the returned object (instead of trying
1343 to query one of these interfaces).
1344
1345 <note>
1346 The specified file path can be absolute (full path) or relative to
1347 the <link to="IVirtualBox::homeFolder">VirtualBox home
1348 directory</link>. If only a file name without any path is given,
1349 the <link to="ISystemProperties::defaultVDIFolder"> default VDI
1350 folder</link> will be used as a path to the image file.
1351 </note>
1352
1353 The opened hard disk remains unregistered
1354 until <link to="#registerHardDisk()"/> is called.
1355
1356 </desc>
1357
1358 <param name="location" type="wstring" dir="in">
1359 <desc>
1360 Location of the resource that contains a valid hard disk.
1361 </desc>
1362 </param>
1363 <param name="hardDisk" type="IHardDisk" dir="return">
1364 <desc>Opened hard disk object.</desc>
1365 </param>
1366 </method>
1367
1368 <method name="openVirtualDiskImage">
1369 <desc>
1370
1371 Opens a hard disk from an existing Virtual Disk Image file.
1372 The opened hard disk remains unregistered
1373 until <link to="#registerHardDisk()"/> is called.
1374
1375 @deprecated Use <link to="IVirtualBox::openHardDisk()"/> instead.
1376
1377 <note>Opening differencing images is not supported.</note>
1378
1379 <note>The specified file path can be absolute (full path) or
1380 relative to the <link to="IVirtualBox::homeFolder"> VirtualBox
1381 home directory</link>. If only a file name without any path is
1382 given, the <link to="ISystemProperties::defaultVDIFolder">
1383 default VDI folder</link> will be used as a path to the image
1384 file.</note>
1385
1386 </desc>
1387
1388 <param name="filePath" type="wstring" dir="in">
1389 <desc>
1390 Name of the file that contains a valid Virtual Disk Image.
1391 </desc>
1392 </param>
1393 <param name="image" type="IVirtualDiskImage" dir="return">
1394 <desc>Opened hard disk object.</desc>
1395 </param>
1396 </method>
1397
1398 <method name="registerHardDisk">
1399 <desc>
1400
1401 Registers the given hard disk within this VirtualBox
1402 installation. The hard disk must not be registered, must be
1403 <link to="IHardDisk::accessible"/> and must not be a
1404 differencing hard disk, otherwise the registration will fail.
1405
1406 </desc>
1407 <param name="hardDisk" type="IHardDisk" dir="in">
1408 <desc>Hard disk object to register.</desc>
1409 </param>
1410 </method>
1411
1412 <method name="getHardDisk" const="yes">
1413 <desc>
1414 Returns the registered hard disk with the given UUID.
1415 </desc>
1416 <param name="id" type="uuid" dir="in">
1417 <desc>UUID of the hard disk to look for.</desc>
1418 </param>
1419 <param name="hardDisk" type="IHardDisk" dir="return">
1420 <desc>Found hard disk object.</desc>
1421 </param>
1422 </method>
1423
1424 <method name="findHardDisk">
1425 <desc>
1426
1427 Returns a registered hard disk that uses the given location to
1428 store data. The search is done by comparing the
1429 value of the @a location argument to the
1430 <link to="IHardDisk::location"/> attribute of each registered
1431 hard disk.
1432
1433 For locations repesented by file paths (such as VDI and VMDK
1434 images), the specified location can be either an absolute file
1435 path or a path relative to
1436 the <link to="IVirtualBox::homeFolder"> VirtualBox home
1437 directory</link>. If only a file name without any path is
1438 given, the <link to="ISystemProperties::defaultVDIFolder">
1439 default VDI folder</link> will be used as a path to construct
1440 the absolute image file name to search for. Note that on host
1441 systems with case sensitive filesystems, a case sensitive
1442 comparison is performed, otherwise the case of symbols in the
1443 file path is ignored.
1444
1445 </desc>
1446 <param name="location" type="wstring" dir="in">
1447 <desc>Hard disk location specification to search for.</desc>
1448 </param>
1449 <param name="hardDisk" type="IHardDisk" dir="return">
1450 <desc>Found hard disk object.</desc>
1451 </param>
1452 </method>
1453
1454 <method name="findVirtualDiskImage">
1455 <desc>
1456
1457 Returns a registered hard disk that uses the given image file.
1458
1459 @deprecated Use <link to="IVirtualBox::findHardDisk()"/> instead.
1460
1461 <note>The specified file path can be absolute (full path) or
1462 relative to the <link to="IVirtualBox::homeFolder"> VirtualBox
1463 home directory</link>. If only a file name without any path is
1464 given, the <link to="ISystemProperties::defaultVDIFolder">
1465 default VDI folder</link> will be used as a path to the image
1466 file.</note>
1467
1468 <note>On host systems with case sensitive filesystems, a case
1469 sensitive comparison is performed, otherwise the case of symbols
1470 in the file path is ignored.</note>
1471
1472 </desc>
1473 <param name="filePath" type="wstring" dir="in">
1474 <desc>Virtual Disk Image file path to look for.</desc>
1475 </param>
1476 <param name="image" type="IVirtualDiskImage" dir="return">
1477 <desc>Found hard disk object.</desc>
1478 </param>
1479 </method>
1480
1481 <method name="unregisterHardDisk">
1482 <desc>
1483 Unregisters a hard disk previously registered using
1484 <link to="#registerHardDisk()"/>.
1485 <note>
1486 The specified hard disk must not be attached to any of
1487 the existing virtual machines and must not have children
1488 (differencing) hard disks.
1489 </note>
1490 </desc>
1491 <param name="id" type="uuid" dir="in">
1492 <desc>UUID of the hard disk to unregister.</desc>
1493 </param>
1494 <param name="hardDisk" type="IHardDisk" dir="return">
1495 <desc>Unregistered hard disk object.</desc>
1496 </param>
1497 </method>
1498
1499 <method name="openDVDImage">
1500 <desc>
1501 Opens the CD/DVD image contained in the specified file of
1502 the supported format and assigns it the given UUID. The opened
1503 image remains unregistered
1504 until <link to="#registerDVDImage()"/> is called.
1505 </desc>
1506 <param name="filePath" type="wstring" dir="in">
1507 <desc>
1508 Full name of the file that contains a valid
1509 CD/DVD image. Currently, only ISO images are supported.
1510 <note>
1511 The specified file name can be absolute or relative
1512 to the <link to="IVirtualBox::homeFolder">
1513 VirtualBox home directory</link>.
1514 </note>
1515 </desc>
1516 </param>
1517 <param name="id" type="uuid" dir="in">
1518 <desc>
1519 UUID to assign to the given image file within this
1520 VirtualBox installation. If an empty (null) UUID is
1521 specified, the system will randomly generate an UUID.
1522 </desc>
1523 </param>
1524 <param name="image" type="IDVDImage" dir="return">
1525 <desc>Opened CD/DVD image object.</desc>
1526 </param>
1527 </method>
1528
1529 <method name="registerDVDImage">
1530 <desc>
1531 Registers a CD/DVD image within this VirtualBox
1532 installation. The image must not be registered and must not
1533 be associated with the same image file as any of the already
1534 registered images, otherwise the registration will fail.
1535 </desc>
1536 <param name="image" type="IDVDImage" dir="in">
1537 <desc>CD/DVD image object to register.</desc>
1538 </param>
1539 </method>
1540
1541 <method name="getDVDImage">
1542 <desc>
1543 Returns a registered CD/DVD image with the given UUID.
1544 </desc>
1545 <param name="id" type="uuid" dir="in">
1546 <desc>UUID of the image to look for.</desc>
1547 </param>
1548 <param name="image" type="IDVDImage" dir="return">
1549 <desc>Found CD/DVD image object.</desc>
1550 </param>
1551 </method>
1552
1553 <method name="findDVDImage">
1554 <desc>
1555 Returns a registered CD/DVD image with the given image file.
1556 <note>
1557 On host systems with case sensitive filesystems, a case
1558 sensitive comparison is performed, otherwise the case of
1559 symbols in the file path is ignored.
1560 </note>
1561 </desc>
1562 <param name="filePath" type="wstring" dir="in">
1563 <desc>CD/DVD image file path to look for.</desc>
1564 </param>
1565 <param name="image" type="IDVDImage" dir="return">
1566 <desc>Found CD/DVD image object.</desc>
1567 </param>
1568 </method>
1569
1570 <method name="getDVDImageUsage">
1571 <desc>
1572 Returns the list of of UUIDs of all virtual machines that use
1573 the given CD/DVD image.
1574 </desc>
1575 <param name="id" type="uuid" dir="in">
1576 <desc>UUID of the image to get the usage information for.</desc>
1577 </param>
1578 <param name="usage" type="ResourceUsage" dir="in">
1579 <desc>Type of the usage (permanent, temporary or all).</desc>
1580 </param>
1581 <param name="machineIDs" type="wstring" dir="return">
1582 <desc>
1583 List of UUIDs of all machines that use the given image
1584 in the way specified by the usage parameter.
1585 The list is returned as a string containing UUIDs separated
1586 by spaces. A null string means that the image is not used.
1587 <note>
1588 When the usage type is <link to="ResourceUsage::All"/> and the image
1589 is used by the VM both permanently and temporarily, the VM's UUID
1590 will be present only once in the list.
1591 </note>
1592 </desc>
1593 </param>
1594 </method>
1595
1596 <method name="unregisterDVDImage">
1597 <desc>
1598 Unregisters the CD/DVD image previously registered using
1599 <link to="#registerDVDImage()"/>.
1600 <note>
1601 The specified image must not be mounted to any of
1602 the existing virtual machines.
1603 </note>
1604 </desc>
1605 <param name="id" type="uuid" dir="in">
1606 <desc>UUID of the CD/DVD image to unregister.</desc>
1607 </param>
1608 <param name="image" type="IDVDImage" dir="return">
1609 <desc>Unregistered image object.</desc>
1610 </param>
1611 </method>
1612
1613 <method name="openFloppyImage">
1614 <desc>
1615 Opens a floppy image contained in the specified file of
1616 the supported format and assigns it the given UUID. The opened
1617 image remains unregistered
1618 until <link to="#registerFloppyImage()"/> is called.
1619 </desc>
1620 <param name="filePath" type="wstring" dir="in">
1621 <desc>
1622 Full name of the file that contains a valid
1623 floppy image.
1624 <note>
1625 The specified file name can be absolute or relative
1626 to the <link to="IVirtualBox::homeFolder">
1627 VirtualBox home directory</link>.
1628 </note>
1629 </desc>
1630 </param>
1631 <param name="id" type="uuid" dir="in">
1632 <desc>
1633 UUID to assign to the given image file within this
1634 VirtualBox installation. If an empty (null) UUID is
1635 specified, the system will randomly generate an UUID.
1636 </desc>
1637 </param>
1638 <param name="image" type="IFloppyImage" dir="return">
1639 <desc>Opened CD/DVD image object.</desc>
1640 </param>
1641 </method>
1642
1643 <method name="registerFloppyImage">
1644 <desc>
1645 Registers a floppy image within this VirtualBox
1646 installation. The image must not be registered and must not
1647 be associated with the same image file as any of the already
1648 registered images, otherwise the registration will fail.
1649 </desc>
1650 <param name="image" type="IFloppyImage" dir="in">
1651 <desc>Floppy image object to register.</desc>
1652 </param>
1653 </method>
1654
1655 <method name="getFloppyImage">
1656 <desc>
1657 Returns a registered floppy image with the given UUID.
1658 </desc>
1659 <param name="id" type="uuid" dir="in">
1660 <desc>UUID of the image to look for.</desc>
1661 </param>
1662 <param name="image" type="IFloppyImage" dir="return">
1663 <desc>Found floppy image object.</desc>
1664 </param>
1665 </method>
1666
1667 <method name="findFloppyImage">
1668 <desc>
1669 Returns a registered floppy image with the given image file.
1670 <note>
1671 On host systems with case sensitive filesystems, a case
1672 sensitive comparison is performed, otherwise the case of
1673 symbols in the file path is ignored.
1674 </note>
1675 </desc>
1676 <param name="filePath" type="wstring" dir="in">
1677 <desc>Floppy image file path to look for.</desc>
1678 </param>
1679 <param name="image" type="IFloppyImage" dir="return">
1680 <desc>Found floppy image object.</desc>
1681 </param>
1682 </method>
1683
1684 <method name="getFloppyImageUsage">
1685 <desc>
1686 Returns the list of of UUIDs of all virtual machines that use
1687 the given floppy image.
1688 </desc>
1689 <param name="id" type="uuid" dir="in">
1690 <desc>UUID of the image to get the usage information for.</desc>
1691 </param>
1692 <param name="usage" type="ResourceUsage" dir="in">
1693 <desc>Type of the usage (permanent, temporary or all).</desc>
1694 </param>
1695 <param name="machineIDs" type="wstring" dir="return">
1696 <desc>
1697 List of UUIDs of all machines that use the given image
1698 in the way specified by the usage parameter.
1699 The list is returned as a string containing UUIDs separated
1700 by spaces. A null string means that the image is not used.
1701 <note>
1702 When the usage type is <link to="ResourceUsage::All"/> and the image
1703 is used by the VM both permanently and temporarily, the VM's UUID
1704 will be present only once in the list.
1705 </note>
1706 </desc>
1707 </param>
1708 </method>
1709
1710 <method name="unregisterFloppyImage">
1711 <desc>
1712 Unregisters the floppy image previously registered using
1713 <link to="#registerFloppyImage()"/>.
1714 <note>
1715 The specified image must not be mounted to any of
1716 the existing virtual machines.
1717 </note>
1718 </desc>
1719 <param name="id" type="uuid" dir="in">
1720 <desc>UUID of the floppy image to unregister.</desc>
1721 </param>
1722 <param name="image" type="IFloppyImage" dir="return">
1723 <desc>Unregistered image object.</desc>
1724 </param>
1725 </method>
1726
1727 <method name="getGuestOSType">
1728 <param name="id" type="wstring" dir="in"/>
1729 <param name="type" type="IGuestOSType" dir="return"/>
1730 </method>
1731
1732 <method name="createSharedFolder">
1733 <desc>
1734 Creates a new global shared folder by associating the given logical
1735 name with the given host path, adds it to the collection of shared
1736 folders and starts sharing it. Refer to the description of
1737 <link to="ISharedFolder"/> to read more about logical names.
1738 </desc>
1739 <param name="name" type="wstring" dir="in">
1740 <desc>Unique logical name of the shared folder.</desc>
1741 </param>
1742 <param name="hostPath" type="wstring" dir="in">
1743 <desc>Full path to the shared folder in the host file system.</desc>
1744 </param>
1745 <param name="writable" type="boolean" dir="in">
1746 <desc>Whether the share is writable or readonly</desc>
1747 </param>
1748 </method>
1749
1750 <method name="removeSharedFolder">
1751 <desc>
1752 Removes the global shared folder with the given name previously
1753 created by <link to="#createSharedFolder"/> from the collection of
1754 shared folders and stops sharing it.
1755 </desc>
1756 <param name="name" type="wstring" dir="in">
1757 <desc>Logical name of the shared folder to remove.</desc>
1758 </param>
1759 </method>
1760
1761 <method name="getNextExtraDataKey">
1762 <desc>
1763 Returns the global extra data key name following the supplied key.
1764
1765 An error is returned if the supplied @a key does not exist. @c NULL is
1766 returned in @a nextKey if the supplied key is the last key. When
1767 supplying @c NULL for the @a key, the first key item is returned in @a
1768 nextKey (if there is any). @a nextValue is an optional parameter and
1769 if supplied, the next key's value is returned in it.
1770 </desc>
1771 <param name="key" type="wstring" dir="in">
1772 <desc>Name of the data key to follow.</desc>
1773 </param>
1774 <param name="nextKey" type="wstring" dir="out">
1775 <desc>Name of the next data key.</desc>
1776 </param>
1777 <param name="nextValue" type="wstring" dir="out">
1778 <desc>Value of the next data key.</desc>
1779 </param>
1780 </method>
1781
1782 <method name="getExtraData">
1783 <desc>
1784 Returns associated global extra data.
1785
1786 If the requested data @a key does not exist, this function will
1787 succeed and return @c NULL in the @a value argument.
1788 </desc>
1789 <param name="key" type="wstring" dir="in">
1790 <desc>Name of the data key to get.</desc>
1791 </param>
1792 <param name="value" type="wstring" dir="return">
1793 <desc>Value of the requested data key.</desc>
1794 </param>
1795 </method>
1796
1797 <method name="setExtraData">
1798 <desc>
1799 Sets associated global extra data.
1800
1801 If you pass @c NULL as a key @a value, the given @a key will be
1802 deleted.
1803
1804 <note>
1805 Before performing the actual data change, this method will ask all
1806 registered callbacks using the
1807 <link to="IVirtualBoxCallback::onExtraDataCanChange()"/>
1808 notification for a permission. If one of the callbacks refuses the
1809 new value, the change will not be performed.
1810 </note>
1811 <note>
1812 On success, the
1813 <link to="IVirtualBoxCallback::onExtraDataChange()"/> notification
1814 is called to inform all registered callbacks about a successful data
1815 change.
1816 </note>
1817 </desc>
1818 <param name="key" type="wstring" dir="in">
1819 <desc>Name of the data key to set.</desc>
1820 </param>
1821 <param name="value" type="wstring" dir="in">
1822 <desc>Value to assign to the key.</desc>
1823 </param>
1824 </method>
1825
1826 <method name="openSession">
1827 <desc>
1828 Opens a new direct session with the given virtual machine.
1829
1830 Within the direct session context, it is possible to change
1831 all VM settings, as well as to execute the VM in the process
1832 space of the session object. There can be only one direct
1833 session open at a time for every virtual machine. In VirtualBox
1834 terminology, the machine becomes "mutable" after a session has
1835 been opened.
1836
1837 Upon successful return, the session object can be used to
1838 get access to the machine and to the VM console.
1839
1840 Note that the "mutable" machine object, on which you may want
1841 to invoke IMachine methods to change its settings, will be a
1842 different object from the immutable IMachine objects returned
1843 by various IVirtualBox methods. To obtain a mutable
1844 IMachine object, upon which you can invoke settings methods,
1845 use the "machine" attribute of the ISession object which represents
1846 your open session.
1847
1848 In other words, to change settings on a machine, the following
1849 sequence is typically performed:
1850
1851 <ol>
1852 <li>Call this method (openSession) to have a machine locked for
1853 the current session.</li>
1854
1855 <li>Obtain a mutable IMachine object from ISession::machine.</li>
1856
1857 <li>Change the settings of the machine.</li>
1858
1859 <li>Call IMachine::saveSettings.</li>
1860
1861 <li>Close the session by calling <link to="#close" />.</li>
1862 </ol>
1863 </desc>
1864 <param name="session" type="ISession" dir="in">
1865 <desc>
1866 Session object that will represent the opened session after
1867 successful method invocation. This object must not represent
1868 the already open session.
1869 <note>
1870 This session will be automatically closed if the
1871 VirtualBox server is terminated for some reason.
1872 </note>
1873 </desc>
1874 </param>
1875 <param name="machineId" type="uuid" dir="in">
1876 <desc>ID of the virtual machine to open a session with.</desc>
1877 </param>
1878 </method>
1879
1880 <method name="openRemoteSession">
1881 <desc>
1882 Opens a new remote session with the given virtual machine.
1883
1884 Opening a remote session causes the VirtualBox server to start a new
1885 process that opens a direct session with the given VM. The remote
1886 session provides some level of control over the VM execution to the
1887 caller (using the IConsole interface); however, within the remote
1888 session context, not all VM settings are available for modification.
1889
1890 This operation can take some time (a new VM is started in a new process,
1891 for which memory and other resources need to be set up, which can take
1892 a few seconds). Because of this, a progress object is returned to allow the
1893 caller to wait for this asynchronous operation to be completed. Until then,
1894 the remote session object remains in the closed state and accessing the
1895 machine or its console through it is invalid. It is recommended to use
1896 <link to="IProgress::waitForCompletion" /> or similar calls to wait for
1897 completion.
1898
1899 Currently supported session types (values of the @a type
1900 argument) are:
1901 <ul>
1902 <li><tt>gui</tt>: VirtualBox Qt GUI session</li>
1903 <li><tt>vrdp</tt>: VirtualBox VRDP Server session</li>
1904 </ul>
1905
1906 The @a environment argument is a string containing definitions of
1907 environment variables in the following format:
1908 @code
1909 NAME[=VALUE]\n
1910 NAME[=VALUE]\n
1911 ...
1912 @endcode
1913 where <tt>\\n</tt> is the new line character. These environment
1914 variables will be appended to the environment of the VirtualBox server
1915 process. If an environment variable exists both in the server process
1916 and in this list, the value from this list takes precedence over the
1917 server's variable. If the value of the environment variable is
1918 omitted, this variable will be removed from the resulting environment.
1919 If the environment string is @c null, the server environment is
1920 inherited by the started process as is.
1921
1922 <note>
1923 It is an error to open a remote session with the machine
1924 that already has an open direct session or waits until the
1925 previous request to open the remote session is completed
1926 (see <link to="IMachine::sessionState"/>).
1927 </note>
1928
1929 <note>
1930 The opened @a session will be automatically closed when
1931 the corresponding direct session dies or gets closed.
1932 </note>
1933
1934 <see>openExistingSession</see>
1935 </desc>
1936 <param name="session" type="ISession" dir="in">
1937 <desc>
1938 Session object that will represent the opened remote session
1939 after successful method invocation (this object must not
1940 represent an already open session).
1941 </desc>
1942 </param>
1943 <param name="machineId" type="uuid" dir="in">
1944 <desc>ID of the virtual machine to open a session with.</desc>
1945 </param>
1946 <param name="type" type="wstring" dir="in">
1947 <desc>
1948 Type of the remote session (case sensitive).
1949 </desc>
1950 </param>
1951 <param name="environment" type="wstring" dir="in">
1952 <desc>
1953 Environment to pass to the opened session (may be @c null).
1954 </desc>
1955 </param>
1956 <param name="progress" type="IProgress" dir="return">
1957 <desc>Progress object to track the operation completion.</desc>
1958 </param>
1959 </method>
1960
1961 <method name="openExistingSession">
1962 <desc>
1963 Opens a new remote session with the virtual machine for
1964 which a direct session is already open.
1965
1966 The remote session provides some level of control over the VM
1967 execution (using the IConsole interface) to the caller; however,
1968 within the remote session context, not all VM settings are available
1969 for modification.
1970
1971 As opposed to <link to="#openRemoteSession()"/>, the number of
1972 remote sessions opened this way is not limited by the API
1973
1974 <note>
1975 It is an error to open a remote session with the machine that
1976 doesn't have an open direct session.
1977 </note>
1978
1979 <see>openRemoteSession</see>
1980 </desc>
1981 <param name="session" type="ISession" dir="in">
1982 <desc>
1983 Session object that will represent the open remote session
1984 after successful method invocation. This object must not
1985 represent an already open session.
1986 <note>
1987 This session will be automatically closed when the peer
1988 (direct) session dies or gets closed.
1989 </note>
1990 </desc>
1991 </param>
1992 <param name="machineId" type="uuid" dir="in">
1993 <desc>ID of the virtual machine to open a session with.</desc>
1994 </param>
1995 </method>
1996
1997 <method name="registerCallback">
1998 <desc>
1999 Registers a new global VirtualBox callback. The methods of the given
2000 callback object will be called by VirtualBox when an appropriate
2001 event occurs.
2002 </desc>
2003 <param name="callback" type="IVirtualBoxCallback" dir="in">
2004 <desc>Callback object to register.</desc>
2005 </param>
2006 </method>
2007
2008 <method name="unregisterCallback">
2009 <desc>
2010 Unregisters the previously registered global VirtualBox callback.
2011 </desc>
2012 <param name="callback" type="IVirtualBoxCallback" dir="in">
2013 <desc>Callback object to unregister.</desc>
2014 </param>
2015 </method>
2016
2017 <method name="waitForPropertyChange">
2018 <desc>
2019 Blocks the caller until any of the properties represented by the @a
2020 what argument changes the value or until the given timeout interval
2021 expires.
2022
2023 The @a what argument is a comma separated list of propertiy masks that
2024 describe properties the caller is interested in. The property mask is
2025 a string in the following format:
2026
2027 @code
2028 [[group.]subgroup.]name
2029 @endcode
2030
2031 where @c name is the property name and @c group, @c subgroup are zero
2032 or or more property group specifiers. Each element (group or name) in
2033 the property mask may be either a latin string or an asterisk symbol
2034 (@c "*") which is used to match any string for the given element. A
2035 property mask that doesn't contain asterisk symbols represents a
2036 single fully qualified property name.
2037
2038 Groups in the fully qualified property name go from more generic (the
2039 left-most part) to more specific (the right-most part). The first
2040 element is usually a name of the object the property belongs to. The
2041 second element may be either a property name, or a child object name,
2042 or an index if the preceeding element names an object which is one of
2043 many objects of the same type. This way, property names form a
2044 hierarchy of properties. Here are some examples of property names:
2045
2046 <table>
2047 <tr>
2048 <td><tt>VirtualBox.version</tt></td>
2049 <td><link to="IVirtualBox::version"/> property</td>
2050 </tr>
2051 <tr>
2052 <td><tt>Machine.&lt;UUID&gt;.name</tt></td>
2053 <td><link to="IMachine::name"/> property of the machine with the
2054 given UUID</td>
2055 </tr>
2056 </table>
2057
2058 Most property names directly correspond to the properties of objects
2059 (components) provided by the VirtualBox library and may be used to
2060 track changes to these properties. However, there may be
2061 pseudo-property names that don't correspond to any existing object's
2062 property directly, as well as there may be object properties that
2063 don't have a corresponding property name that is understood by this
2064 method, and therefore changes to such properties cannot be
2065 tracked. See individual object's property descrcriptions to get a
2066 fully qualified property name that can be used with this method (if
2067 any).
2068
2069 There is a special property mask @c "*" (i.e. a string consisting of a
2070 single asterisk symbol) that can be used to match all properties.
2071 Below are more examples of property masks:
2072
2073 <table>
2074 <tr>
2075 <td><tt>VirtualBox.*</tt></td>
2076 <td>Track all properties of the VirtualBox object</td>
2077 </tr>
2078 <tr>
2079 <td><tt>Machine.*.name</tt></td>
2080 <td>Track changes to the <link to="IMachine::name"/> property of
2081 all registered virtual machines</td>
2082 </tr>
2083 </table>
2084
2085 </desc>
2086 <param name="what" type="wstring" dir="in">
2087 <desc>Comma separated list of property masks.</desc>
2088 </param>
2089 <param name="timeout" type="unsigned long" dir="in">
2090 <desc>
2091 Wait timeout in milliseconds.
2092 Specify -1 for an indefinite wait.
2093 </desc>
2094 </param>
2095 <param name="changed" type="wstring" dir="out">
2096 <desc>
2097 Comma separated list of properties that have been changed and caused
2098 this method to return to the caller.
2099 </desc>
2100 </param>
2101 <param name="values" type="wstring" dir="out">
2102 <desc>Reserved, not currently used.</desc>
2103 </param>
2104 </method>
2105
2106 <method name="saveSettings">
2107 <desc>
2108 Saves the global settings to the global settings file
2109 (<link to="#settingsFilePath"/>).
2110
2111 This method is only useful for explicitly saving the global settings
2112 file after it has been auto-converted from the old format to the most
2113 recent format (see <link to="#settingsFileVersion"/> for details).
2114 Normally, the global settings file is implicitly saved when a global
2115 setting is changed.
2116 </desc>
2117 </method>
2118
2119 <method name="saveSettingsWithBackup">
2120 <desc>
2121 Creates a backup copy of the global settings file
2122 (<link to="#settingsFilePath"/>) in case of auto-conversion, and then
2123 calls <link to="#saveSettings()"/>.
2124
2125 Note that the backup copy is created <b>only</b> if the settings file
2126 auto-conversion took place (see <link to="#settingsFileVersion"/> for
2127 details). Otherwise, this call is fully equivalent to
2128 <link to="#saveSettings()"/> and no backup copying is done.
2129
2130 The backup copy is created in the same directory where the original
2131 settings file is located. It is given the following file name:
2132 <pre>
2133 original.xml.x.y-platform.bak
2134 </pre>
2135 where <tt>original.xml</tt> is the original settings file name
2136 (excluding path), and <tt>x.y-platform</tt> is the version of the old
2137 format of the settings file (before auto-conversion).
2138
2139 If the given backup file already exists, this method will try to add the
2140 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
2141 0 to 9) and copy it again until it succeeds. If all suffixes are
2142 occupied, or if any other copy error occurs, this method will return a
2143 failure.
2144
2145 If the copy operation succeeds, the @a bakFileName return argument will
2146 receive a full path to the created backup file (for informational
2147 purposes). Note that this will happen even if the subsequent
2148 <link to="#saveSettings()"/> call performed by this method after the
2149 copy operation, fails.
2150
2151 <note>
2152 The VirtualBox API never calls this method. It is intended purely for
2153 the purposes of creating backup copies of the settings files by
2154 front-ends before saving the results of the automatically performed
2155 settings conversion to disk.
2156 </note>
2157
2158 <see>settingsFileVersion</see>
2159 </desc>
2160 <param name="bakFileName" type="wstring" dir="return">
2161 <desc>Full path to the created backup copy.</desc>
2162 </param>
2163 </method>
2164
2165 </interface>
2166
2167 <!--
2168 // IMachine
2169 /////////////////////////////////////////////////////////////////////////
2170 -->
2171
2172 <enumerator
2173 name="IMachineEnumerator" type="IMachine"
2174 uuid="1b554149-be0a-4465-9252-9ff8f420af55"
2175 />
2176
2177 <collection
2178 name="IMachineCollection" type="IMachine" enumerator="IMachineEnumerator"
2179 uuid="FD443EC1-3007-4F5B-9282-D72760A66916"
2180 readonly="yes"
2181 />
2182
2183 <interface
2184 name="IInternalMachineControl" extends="$unknown"
2185 uuid="1063893c-4c38-4304-aee9-73e072c181cc"
2186 internal="yes"
2187 wsmap="suppress"
2188 >
2189 <method name="updateState">
2190 <desc>
2191 Updates the VM state.
2192 <note>
2193 This operation will also update the settings file with
2194 the correct information about the saved state file
2195 and delete this file from disk when appropriate.
2196 </note>
2197 </desc>
2198 <param name="state" type="MachineState" dir="in"/>
2199 </method>
2200
2201 <method name="getIPCId">
2202 <param name="id" type="wstring" dir="return"/>
2203 </method>
2204
2205 <method name="runUSBDeviceFilters">
2206 <desc>
2207 Asks the server to run USB devices filters of the associated
2208 machine against the given USB device and tell if there is
2209 a match.
2210 <note>
2211 Intended to be used only for remote USB devices. Local
2212 ones don't require to call this method (this is done
2213 implicitly by the Host and USBProxyService).
2214 </note>
2215 </desc>
2216 <param name="device" type="IUSBDevice" dir="in"/>
2217 <param name="matched" type="boolean" dir="out"/>
2218 <param name="maskedInterfaces" type="unsigned long" dir="out"/>
2219 </method>
2220
2221 <method name="captureUSBDevice">
2222 <desc>
2223 Requests a capture of the given host USB device.
2224 When the request is completed, the VM process will
2225 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
2226 notification.
2227 </desc>
2228 <param name="id" type="uuid" dir="in"/>
2229 </method>
2230
2231 <method name="detachUSBDevice">
2232 <desc>
2233 Notification that a VM is going to detach (done = false) or has
2234 already detached (done = true) the given USB device.
2235 When the done = true request is completed, the VM process will
2236 get a <link to="IInternalSessionControl::onUSBDeviceDetach"/>
2237 notification.
2238 <note>
2239 In the done = true case, the server must run its own filters
2240 and filters of all VMs but this one on the detached device
2241 as if it were just attached to the host computer.
2242 </note>
2243 </desc>
2244 <param name="id" type="uuid" dir="in"/>
2245 <param name="done" type="boolean" dir="in"/>
2246 </method>
2247
2248 <method name="autoCaptureUSBDevices">
2249 <desc>
2250 Requests a capture all matching USB devices attached to the host.
2251 When the request is completed, the VM process will
2252 get a <link to="IInternalSessionControl::onUSBDeviceAttach"/>
2253 notification per every captured device.
2254 </desc>
2255 </method>
2256
2257 <method name="detachAllUSBDevices">
2258 <desc>
2259 Notification that a VM that is being powered down. The done
2260 parameter indicates whether which stage of the power down
2261 we're at. When done = false the VM is announcing its
2262 intentions, while when done = true the VM is reporting
2263 what it has done.
2264 <note>
2265 In the done = true case, the server must run its own filters
2266 and filters of all VMs but this one on all detach devices as
2267 if they were just attached to the host computer.
2268 </note>
2269 </desc>
2270 <param name="done" type="boolean" dir="in"/>
2271 </method>
2272
2273 <method name="onSessionEnd">
2274 <desc>
2275 Triggered by the given session object when the session is about
2276 to close normally.
2277 </desc>
2278 <param name="session" type="ISession" dir="in">
2279 <desc>Session that is being closed</desc>
2280 </param>
2281 <param name="progress" type="IProgress" dir="return">
2282 <desc>
2283 Used to wait until the corresponding machine is actually
2284 deassociated from the given session on the server.
2285 Returned only when this session is a direct one.
2286 </desc>
2287 </param>
2288 </method>
2289
2290 <method name="beginSavingState">
2291 <desc>
2292 Called by the VM process to inform the server it wants to
2293 save the current state and stop the VM execution.
2294 </desc>
2295 <param name="progress" type="IProgress" dir="in">
2296 <desc>
2297 Progress object created by the VM process to wait until
2298 the state is saved.
2299 </desc>
2300 </param>
2301 <param name="stateFilePath" type="wstring" dir="out">
2302 <desc>
2303 File path the VM process must save the execution state to.
2304 </desc>
2305 </param>
2306 </method>
2307
2308 <method name="endSavingState">
2309 <desc>
2310 Called by the VM process to inform the server that saving
2311 the state previously requested by #beginSavingState is either
2312 successfully finished or there was a failure.
2313 </desc>
2314
2315 <param name="success" type="boolean" dir="in">
2316 <desc><tt>true</tt> to indicate success and <tt>false</tt> otherwise</desc>
2317 </param>
2318 </method>
2319
2320 <method name="adoptSavedState">
2321 <desc>
2322 Gets called by IConsole::adoptSavedState.
2323 </desc>
2324 <param name="savedStateFile" type="wstring" dir="in">
2325 <desc>Path to the saved state file to adopt.</desc>
2326 </param>
2327 </method>
2328
2329 <method name="beginTakingSnapshot">
2330 <desc>
2331 Called by the VM process to inform the server it wants to
2332 take a snapshot.
2333 </desc>
2334 <param name="initiator" type="IConsole" dir="in">
2335 <desc>The console object that initiated this call.</desc>
2336 </param>
2337 <param name="name" type="wstring" dir="in">
2338 <desc>Snapshot name</desc>
2339 </param>
2340 <param name="description" type="wstring" dir="in">
2341 <desc>Snapshot description</desc>
2342 </param>
2343 <param name="progress" type="IProgress" dir="in">
2344 <desc>
2345 Progress object created by the VM process to wait until
2346 the state is saved (only for online snapshots).
2347 </desc>
2348 </param>
2349 <param name="stateFilePath" type="wstring" dir="out">
2350 <desc>
2351 File path the VM process must save the execution state to.
2352 </desc>
2353 </param>
2354 <param name="serverProgress" type="IProgress" dir="out">
2355 <desc>
2356 Progress object created by the server process to wait until
2357 the snapshot is taken (VDI diff creation, etc.).
2358 </desc>
2359 </param>
2360 </method>
2361
2362 <method name="endTakingSnapshot">
2363 <desc>
2364 Called by the VM process to inform the server that the snapshot
2365 previously requested by #beginTakingSnapshot is either
2366 successfully taken or there was a failure.
2367 </desc>
2368
2369 <param name="success" type="boolean" dir="in">
2370 <desc><tt>true</tt> to indicate success and <tt>false</tt> otherwise</desc>
2371 </param>
2372 </method>
2373
2374 <method name="discardSnapshot">
2375 <desc>
2376 Gets called by IConsole::discardSnapshot.
2377 </desc>
2378 <param name="initiator" type="IConsole" dir="in">
2379 <desc>The console object that initiated this call.</desc>
2380 </param>
2381 <param name="id" type="uuid" dir="in">
2382 <desc>UUID of the snapshot to discard.</desc>
2383 </param>
2384 <param name="machineState" type="MachineState" dir="out">
2385 <desc>New machine state after this operation is started.</desc>
2386 </param>
2387 <param name="progress" type="IProgress" dir="return">
2388 <desc>Progress object to track the operation completion.</desc>
2389 </param>
2390 </method>
2391
2392 <method name="discardCurrentState">
2393 <desc>
2394 Gets called by IConsole::discardCurrentState.
2395 </desc>
2396 <param name="initiator" type="IConsole" dir="in">
2397 <desc>The console object that initiated this call.</desc>
2398 </param>
2399 <param name="machineState" type="MachineState" dir="out">
2400 <desc>New machine state after this operation is started.</desc>
2401 </param>
2402 <param name="progress" type="IProgress" dir="return">
2403 <desc>Progress object to track the operation completion.</desc>
2404 </param>
2405 </method>
2406
2407 <method name="discardCurrentSnapshotAndState">
2408 <desc>
2409 Gets called by IConsole::discardCurrentSnapshotAndState.
2410 </desc>
2411 <param name="initiator" type="IConsole" dir="in">
2412 <desc>The console object that initiated this call.</desc>
2413 </param>
2414 <param name="machineState" type="MachineState" dir="out">
2415 <desc>New machine state after this operation is started.</desc>
2416 </param>
2417 <param name="progress" type="IProgress" dir="return">
2418 <desc>Progress object to track the operation completion.</desc>
2419 </param>
2420 </method>
2421
2422 </interface>
2423
2424 <interface
2425 name="IBIOSSettings" extends="$unknown"
2426 uuid="38b54279-dc35-4f5e-a431-835b867c6b5e"
2427 wsmap="struct"
2428 >
2429 <desc>
2430 The IBIOSSettings interface represents BIOS settings of the virtual
2431 machine. This is used only in the <link to="IMachine::BIOSSettings" /> attribute.
2432
2433 <note>With the COM API, this is an interface like all the others. With the webservice,
2434 this is mapped to a structure, so querying the attribute will not return an object,
2435 but a complete structure.</note>
2436 </desc>
2437 <attribute name="logoFadeIn" type="boolean">
2438 <desc>Fade in flag for BIOS logo animation.</desc>
2439 </attribute>
2440
2441 <attribute name="logoFadeOut" type="boolean">
2442 <desc>Fade out flag for BIOS logo animation.</desc>
2443 </attribute>
2444
2445 <attribute name="logoDisplayTime" type="unsigned long">
2446 <desc>BIOS logo display time in milliseconds (0 = default).</desc>
2447 </attribute>
2448
2449 <attribute name="logoImagePath" type="wstring">
2450 <desc>Local file system path for external BIOS image.</desc>
2451 </attribute>
2452
2453 <attribute name="bootMenuMode" type="BIOSBootMenuMode">
2454 <desc>Mode of the BIOS boot device menu.</desc>
2455 </attribute>
2456
2457 <attribute name="ACPIEnabled" type="boolean">
2458 <desc>ACPI support flag.</desc>
2459 </attribute>
2460
2461 <attribute name="IOAPICEnabled" type="boolean">
2462 <desc>
2463 IO APIC support flag. If set, VirtualBox will provide an IO APIC
2464 and support IRQs above 15.
2465 </desc>
2466 </attribute>
2467
2468 <attribute name="timeOffset" type="long long">
2469 <desc>
2470 Offset in milliseconds from the host system time. This allows for
2471 guests running with a different system date/time than the host.
2472 It is equivalent to setting the system date/time in the BIOS other
2473 than it's not an absolute value but a relative one. Guest Additions
2474 time synchronization also honors this offset.
2475 </desc>
2476 </attribute>
2477
2478 <attribute name="PXEDebugEnabled" type="boolean">
2479 <desc>
2480 PXE debug logging flag. If set, VirtualBox will write extensive
2481 PXE trace information to the release log.
2482 </desc>
2483 </attribute>
2484
2485 <attribute name="IDEControllerType" type="IDEControllerType">
2486 <desc>
2487 Type of the virtual IDE controller. Depending on this value,
2488 VirtualBox will provide different virtual IDE hardware
2489 devices to the guest.
2490 </desc>
2491 </attribute>
2492
2493 </interface>
2494
2495 <interface
2496 name="IMachine" extends="$unknown"
2497 uuid="d6181581-e7c7-418a-b3b6-2da10b11a763"
2498 wsmap="managed"
2499 >
2500 <desc>
2501 The IMachine interface represents a virtual machine, or guest, created
2502 in VirtualBox.
2503
2504 This interface is used in two contexts. First of all, a collection of
2505 objects implementing this interface is stored in the
2506 <link to="IVirtualBox::machines"/> attribute which lists all the virtual
2507 machines that are currently registered with this VirtualBox
2508 installation. Also, once a session has been opened for the given virtual
2509 machine (e.g. the virtual machine is running), the machine object
2510 associated with the open session can be queried from the session object;
2511 see <link to="ISession"/> for details.
2512
2513 The main role of this interface is to expose the settings of the virtual
2514 machine and provide methods to change various aspects of the virtual
2515 machine's configuration. For machine objects stored in the
2516 <link to="IVirtualBox::machines"/> collection, all attributes are
2517 read-only unless explicitely stated otherwise in individual attribute
2518 and method descriptions. In order to change a machine setting, a session
2519 for this machine must be opened using one of
2520 <link to="IVirtualBox::openSession"/>,
2521 <link to="IVirtualBox::openRemoteSession"/> or
2522 <link to="IVirtualBox::openExistingSession"/> methdods. After the
2523 session has been successfully opened, a mutable machine object needs to
2524 be queried from the session object and then the desired settings changes
2525 can be applied to the returned object using IMachine attributes and
2526 methods. See the ISession interface description for more information
2527 about sessions.
2528
2529 Note that the IMachine interface does not provide methods to control
2530 virtual machine execution (such as start the machine, or power it
2531 down) -- these methods are grouped in a separate IConsole
2532 interface. Refer to the IConsole interface description to get more
2533 information about this topic.
2534
2535 <see>ISession, IConsole</see>
2536 </desc>
2537
2538 <attribute name="parent" type="IVirtualBox" readonly="yes">
2539 <desc>Associated parent obect.</desc>
2540 </attribute>
2541
2542 <attribute name="accessible" type="boolean" readonly="yes">
2543 <desc>
2544 Whether this virtual machine is currently accessible or not.
2545
2546 The machine is considered to be inaccessible when:
2547 <ul>
2548 <li>It is a registered virtual machine, and
2549 </li>
2550 <li>Its settings file is inaccessible (for example, it is
2551 located on a network share that is not accessible during
2552 VirtualBox startup, or becomes inaccessible later, or if
2553 the settings file can be read but is invalid).
2554 </li>
2555 </ul>
2556
2557 Otherwise, the value of this property is always <tt>true</tt>.
2558
2559 Every time this property is read, the accessibility state of
2560 this machine is re-evaluated. If the returned value is |false|,
2561 the <link to="#accessError"/> property may be used to get the
2562 detailed error information describing the reason of
2563 inaccessibility.
2564
2565 When the machine is inaccessible, only the following properties
2566 can be used on it:
2567 <ul>
2568 <li><link to="#parent"/></li>
2569 <li><link to="#id"/></li>
2570 <li><link to="#settingsFilePath"/></li>
2571 <li><link to="#accessible"/></li>
2572 <li><link to="#accessError"/></li>
2573 </ul>
2574
2575 An attempt to access any other property or method will return
2576 an error.
2577
2578 The only possible action you can perform on an inaccessible
2579 machine is to unregister it using the
2580 <link to="IVirtualBox::unregisterMachine"/> call (or, to check
2581 for the accessibility state once more by querying this
2582 property).
2583
2584 <note>
2585 In the current implementation, once this property returns
2586 <tt>true</tt>, the machine will never become inaccessible
2587 later, even if its settings file cannot be successfully
2588 read/written any more (at least, until the VirtualBox
2589 server is restarted). This limitation may be removed in
2590 future releases.
2591 </note>
2592 </desc>
2593 </attribute>
2594
2595 <attribute name="accessError" type="IVirtualBoxErrorInfo" readonly="yes">
2596 <desc>
2597 Error information describing the reason of machine
2598 inaccessibility.
2599
2600 Reading this property is only valid after the last call to
2601 <link to="#accessible"/> returned <tt>false</tt> (i.e. the
2602 machine is currently unaccessible). Otherwise, a null
2603 IVirtualBoxErrorInfo object will be returned.
2604 </desc>
2605 </attribute>
2606
2607 <attribute name="name" type="wstring">
2608 <desc>
2609 Name of the virtual machine.
2610
2611 Besides being used for human-readable identification purposes
2612 everywhere in VirtualBox, the virtual machine name is also used
2613 as a name of the machine's settings file and as a name of the
2614 subdirectory this settings file resides in. Thus, every time you
2615 change the value of this property, the settings file will be
2616 renamed once you call <link to="#saveSettings()"/> to confirm the
2617 change. The containing subdirectory will be also renamed, but
2618 only if it has exactly the same name as the settings file
2619 itself prior to changing this property (for backward compatibility
2620 with previous API releases). The above implies the following
2621 limitations:
2622 <ul>
2623 <li>The machine name cannot be empty.</li>
2624 <li>The machine name can contain only characters that are valid
2625 file name characters according to the rules of the file
2626 system used to store VirtualBox configuration.</li>
2627 <li>You cannot have two or more machines with the same name
2628 if they use the same subdirectory for storing the machine
2629 settings files.</li>
2630 <li>You cannot change the name of the machine if it is running,
2631 or if any file in the directory containing the settings file
2632 is being used by another running machine or by any other
2633 process in the host operating system at a time when
2634 <link to="#saveSettings()"/> is called.
2635 </li>
2636 </ul>
2637 If any of the above limitations are hit, <link to="#saveSettings()"/>
2638 will return an appropriate error message explaining the exact
2639 reason and the changes you made to this machine will not be
2640 saved.
2641 <note>
2642 For "legacy" machines created using the
2643 <link to="IVirtualBox::createLegacyMachine()"/> call,
2644 the above naming limitations do not apply because the
2645 machine name does not affect the settings file name.
2646 The settings file name remains the same as it was specified
2647 during machine creation and never changes.
2648 </note>
2649 </desc>
2650 </attribute>
2651
2652 <attribute name="description" type="wstring">
2653 <desc>
2654 Description of the virtual machine.
2655
2656 The description attribute can contain any text and is
2657 typically used to describe the hardware and software
2658 configuration of the virtual machine in detail (i.e. network
2659 settings, versions of the installed software and so on).
2660 </desc>
2661 </attribute>
2662
2663 <attribute name="id" type="uuid" readonly="yes">
2664 <desc>UUID of the virtual machine.</desc>
2665 </attribute>
2666
2667 <attribute name="OSTypeId" type="wstring">
2668 <desc>
2669 User-defined identifier of the Guest OS type.
2670 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
2671 an IGuestOSType object representing details about the given
2672 Guest OS type.
2673 <note>
2674 This value may differ from the value returned by
2675 <link to="IGuest::OSTypeId"/> if Guest Additions are
2676 installed to the guest OS.
2677 </note>
2678 </desc>
2679 </attribute>
2680
2681 <attribute name="memorySize" type="unsigned long">
2682 <desc>System memory size in megabytes.</desc>
2683 </attribute>
2684
2685 <attribute name="memoryBalloonSize" type="unsigned long">
2686 <desc>Initial memory balloon size in megabytes.</desc>
2687 </attribute>
2688
2689 <attribute name="statisticsUpdateInterval" type="unsigned long">
2690 <desc>Initial interval to update guest statistics in seconds.</desc>
2691 </attribute>
2692
2693 <attribute name="VRAMSize" type="unsigned long">
2694 <desc>Video memory size in megabytes.</desc>
2695 </attribute>
2696
2697 <attribute name="MonitorCount" type="unsigned long">
2698 <desc>
2699 Number of virtual monitors.
2700 <note>
2701 Only effective on Windows XP and later guests with
2702 Guest Additions installed.
2703 </note>
2704 </desc>
2705 </attribute>
2706
2707 <attribute name="BIOSSettings" type="IBIOSSettings" readonly="yes">
2708 <desc>Object containing all BIOS settings.</desc>
2709 </attribute>
2710
2711 <attribute name="HWVirtExEnabled" type="TSBool">
2712 <desc>
2713 This setting determines whether VirtualBox will try to make use of
2714 the host CPU's hardware virtualization extensions such as Intel VT-x
2715 and AMD-V. Note that in case such extensions are not available,
2716 they will not be used.
2717 </desc>
2718 </attribute>
2719
2720 <attribute name="PAEEnabled" type="boolean" default="false">
2721 <desc>
2722 This setting determines whether VirtualBox will expose the Physical Address
2723 Extension (PAE) feature of the host CPU to the guest. Note that in case PAE
2724 is not available, it will not be reported.
2725 </desc>
2726 </attribute>
2727
2728 <attribute name="snapshotFolder" type="wstring">
2729 <desc>
2730 Full path to the directory used to store snapshot data
2731 (difrerencing hard disks and saved state files) of this machine.
2732
2733 The initial value of this property is
2734 <tt>&lt;</tt><link to="#settingsFilePath">
2735 path_to_settings_file</link><tt>&gt;/&lt;</tt>
2736 <link to="#id">machine_uuid</link>
2737 <tt>&gt;</tt>.
2738
2739 Currently, it is an error to try to change this property on
2740 a machine that has snapshots (because this would require to
2741 move possibly large files to a different location).
2742 A separate method will be available for this purpose later.
2743
2744 <note>
2745 Setting this property to <tt>null</tt> will restore the
2746 initial value.
2747 </note>
2748 <note>
2749 When setting this property, the specified path can be
2750 absolute (full path) or relative to the directory where the
2751 <link to="#settingsFilePath">machine settings file</link>
2752 is located. When reading this property, a full path is
2753 always returned.
2754 </note>
2755 <note>
2756 The specified path may not exist, it will be created
2757 when necessary.
2758 </note>
2759 </desc>
2760 </attribute>
2761
2762 <attribute name="VRDPServer" type="IVRDPServer" readonly="yes">
2763 <desc>VRDP server object.</desc>
2764 </attribute>
2765
2766 <attribute name="hardDiskAttachments" type="IHardDiskAttachmentCollection" readonly="yes">
2767 <desc>Collection of hard disks attached to the machine.</desc>
2768 </attribute>
2769
2770 <attribute name="DVDDrive" type="IDVDDrive" readonly="yes">
2771 <desc>Associated DVD drive object.</desc>
2772 </attribute>
2773
2774 <attribute name="FloppyDrive" type="IFloppyDrive" readonly="yes">
2775 <desc>Associated floppy drive object.</desc>
2776 </attribute>
2777
2778 <attribute name="USBController" type="IUSBController" readonly="yes">
2779 <desc>
2780 Associated USB controller object.
2781
2782 <note>
2783 This method may set a @ref com_warnings "warning result code".
2784 </note>
2785 <note>
2786 If USB functionality is not avaliable in the given edition of
2787 VirtualBox, this method will set the result code to @c E_NOTIMPL.
2788 </note>
2789 </desc>
2790 </attribute>
2791
2792 <attribute name="audioAdapter" type="IAudioAdapter" readonly="yes">
2793 <desc>Associated audio adapter, always present.</desc>
2794 </attribute>
2795
2796 <attribute name="SATAController" type="ISATAController" readonly="yes">
2797 <desc>
2798 Associated SATA controller object.
2799 </desc>
2800 </attribute>
2801
2802 <attribute name="settingsFilePath" type="wstring" readonly="yes">
2803 <desc>
2804 Full name of the file containing machine settings data.
2805 </desc>
2806 </attribute>
2807
2808 <attribute name="settingsFileVersion" type="wstring" readonly="yes">
2809 <desc>
2810 Current version of the format of the settings file of this machine
2811 (<link to="#settingsFilePath"/>).
2812
2813 The version string has the following format:
2814 <pre>
2815 x.y-platform
2816 </pre>
2817 where <tt>x</tt> and <tt>y</tt> are the major and the minor format
2818 versions, and <tt>platform</tt> is the platform identifier.
2819
2820 The current version usually matches the value of the
2821 <link to="IVirtualBox::settingsFormatVersion"/> attribute unless the
2822 settings file was created by an older version of VirtualBox and there
2823 was a change of the settings file format since then.
2824
2825 Note that VirtualBox automatically converts settings files from older
2826 versions to the most recent version when reading them (usually at
2827 VirtualBox startup) but it doesn't save the changes back until
2828 you call a method that implicitly saves settings (such as
2829 <link to="#setExtraData()"/>) or call <link to="#saveSettings()"/>
2830 explicitly. Therefore, if the value of this attribute differs from the
2831 value of <link to="IVirtualBox::settingsFormatVersion"/>, then it
2832 means that the settings file was converted but the result of the
2833 conversion is not yet saved to disk.
2834
2835 The above feature may be used by interactive front-ends to inform users
2836 about the settings file format change and offer them to explicitly save
2837 all converted settings files (the global and VM-specific ones),
2838 optionally create bacup copies of the old settings files before saving,
2839 etc.
2840
2841 <see>IVirtualBox::settingsFormatVersion, saveSettingsWithBackup()</see>
2842 </desc>
2843 </attribute>
2844
2845 <attribute name="settingsModified" type="boolean" readonly="yes">
2846 <desc>
2847 Whether the settings of this machine have been modified
2848 (but neither yet saved nor discarded).
2849 <note>
2850 Reading this property is only valid on instances returned
2851 by <link to="ISession::machine"/> and on new machines
2852 created by <link to="IVirtualBox::createMachine"/> or opened
2853 by <link to="IVirtualBox::openMachine"/> but not
2854 yet registered, or on unregistered machines after calling
2855 <link to="IVirtualBox::unregisterMachine"/>. For all other
2856 cases, the settigs can never be modified.
2857 </note>
2858 <note>
2859 For newly created unregistered machines, the value of this
2860 property is always TRUE until <link to="#saveSettings()"/>
2861 is called (no matter if any machine settings have been
2862 changed after the creation or not). For opened machines
2863 the value is set to FALSE (and then follows to normal rules).
2864 </note>
2865 </desc>
2866 </attribute>
2867
2868 <attribute name="sessionState" type="SessionState" readonly="yes">
2869 <desc>Current session state for this machine.</desc>
2870 </attribute>
2871
2872 <attribute name="sessionType" type="wstring" readonly="yes">
2873 <desc>
2874 Type of the session. If <link to="#sessionState"/> is
2875 SessionSpawning or SessionOpen, this attribute contains the
2876 same value as passed to the
2877 <link to="IVirtualBox::openRemoteSession()"/> method in the @a
2878 type parameter. If the session was opened directly using
2879 <link to="IVirtualBox::openSession()"/>, or if
2880 <link to="#sessionState"/> is SessionClosed, the value of this
2881 attribute is @c null.
2882 </desc>
2883 </attribute>
2884
2885 <attribute name="sessionPid" type="unsigned long" readonly="yes">
2886 <desc>
2887 Identifier of the session process. This attribute contains the
2888 platform-dependent identifier of the process that has opened a
2889 direct session for this machine using the
2890 <link to="IVirtualBox::openSession()"/> call. The returned value
2891 is only valid if <link to="#sessionState"/> is SessionOpen or
2892 SessionClosing (i.e. a session is currently open or being
2893 closed) by the time this property is read.
2894 </desc>
2895 </attribute>
2896
2897 <attribute name="state" type="MachineState" readonly="yes">
2898 <desc>Current execution state of this machine.</desc>
2899 </attribute>
2900
2901 <attribute name="lastStateChange" type="long long" readonly="yes">
2902 <desc>
2903 Time stamp of the last execution state change,
2904 in milliseconds since 1970-01-01 UTC.
2905 </desc>
2906 </attribute>
2907
2908 <attribute name="stateFilePath" type="wstring" readonly="yes">
2909 <desc>
2910 Full path to the file that stores the execution state of
2911 the machine when it is in the <link to="MachineState::Saved"/>
2912 state.
2913 <note>
2914 When the machine is not in the Saved state, this attribute
2915 <tt>null</tt>.
2916 </note>
2917 </desc>
2918 </attribute>
2919
2920 <attribute name="logFolder" type="wstring" readonly="yes">
2921 <desc>
2922 Full path to the folder that stores a set of rotated log files
2923 recorded during machine execution. The most recent log file is
2924 named <tt>VBox.log</tt>, the previous log file is
2925 named <tt>VBox.log.1</tt> and so on (upto <tt>VBox.log.3</tt>
2926 in the current version).
2927 </desc>
2928 </attribute>
2929
2930 <attribute name="currentSnapshot" type="ISnapshot" readonly="yes">
2931 <desc>
2932 Current snapshot of this machine.
2933 <note>
2934 A <tt>null</tt> object is returned if the machine doesn't
2935 have snapshots.
2936 </note>
2937 <see><link to="ISnapshot"/></see>
2938 </desc>
2939 </attribute>
2940
2941 <attribute name="snapshotCount" type="unsigned long" readonly="yes">
2942 <desc>
2943 Number of snapshots taken on this machine. Zero means the
2944 machine doesn't have any snapshots.
2945 </desc>
2946 </attribute>
2947
2948 <attribute name="currentStateModified" type="boolean" readonly="yes">
2949 <desc>
2950 Returns <tt>true</tt> if the current state of the machine is not
2951 identical to the state stored in the current snapshot.
2952
2953 The current state is identical to the current snapshot right
2954 after one of the following calls are made:
2955 <ul>
2956 <li><link to="IConsole::discardCurrentState"/> or
2957 <link to="IConsole::discardCurrentSnapshotAndState"/>
2958 </li>
2959 <li><link to="IConsole::takeSnapshot"/> (issued on a
2960 powered off or saved machine, for which
2961 <link to="#settingsModified"/> returns <tt>false</tt>)
2962 </li>
2963 <li><link to="IMachine::setCurrentSnapshot"/>
2964 </li>
2965 </ul>
2966
2967 The current state remains identical until one of the following
2968 happens:
2969 <ul>
2970 <li>settings of the machine are changed</li>
2971 <li>the saved state is discarded</li>
2972 <li>the current snapshot is discarded</li>
2973 <li>an attempt to execute the machine is made</li>
2974 </ul>
2975
2976 <note>
2977 For machines that don't have snapshots, this property is
2978 always <tt>false</tt>.
2979 </note>
2980 </desc>
2981 </attribute>
2982
2983 <attribute name="sharedFolders" type="ISharedFolderCollection" readonly="yes">
2984 <desc>
2985 Collection of shared folders for this machine (permanent shared
2986 folders). These folders are shared automatically at machine startup
2987 and available only to the guest OS installed within this machine.
2988
2989 New shared folders are added to the collection using
2990 <link to="#createSharedFolder"/>. Existing shared folders can be
2991 removed using <link to="#removeSharedFolder"/>.
2992 </desc>
2993 </attribute>
2994
2995 <attribute name="clipboardMode" type="ClipboardMode">
2996 <desc>
2997 Synchronization mode between the host OS clipboard
2998 and the guest OS clipboard.
2999 </desc>
3000 </attribute>
3001
3002 <method name="setBootOrder">
3003 <desc>
3004 Puts the given device to the specified position in
3005 the boot order.
3006
3007 To indicate that no device is associated with the given position,
3008 <link to="DeviceType::Null"/> should be used.
3009
3010 @todo setHardDiskBootOrder(), setNetworkBootOrder()
3011 </desc>
3012 <param name="position" type="unsigned long" dir="in">
3013 <desc>
3014 Position in the boot order (<tt>1</tt> to the total number of
3015 devices the machine can boot from, as returned by
3016 <link to="ISystemProperties::maxBootPosition"/>).
3017 </desc>
3018 </param>
3019 <param name="device" type="DeviceType" dir="in">
3020 <desc>
3021 The type of the device used to boot at the given position.
3022 </desc>
3023 </param>
3024 </method>
3025
3026 <method name="getBootOrder" const="yes">
3027 <desc>
3028 Returns the device type that occupies the specified
3029 position in the boot order.
3030
3031 @todo [remove?]
3032 If the machine can have more than one device of the returned type
3033 (such as hard disks), then a separate method should be used to
3034 retrieve the individual device that occupies the given position.
3035
3036 If here are no devices at the given position, then
3037 <link to="DeviceType::Null"/> is returned.
3038
3039 @todo getHardDiskBootOrder(), getNetworkBootOrder()
3040 </desc>
3041 <param name="order" type="unsigned long" dir="in">
3042 <desc>
3043 Position in the boot order (<tt>1</tt> to the total number of
3044 devices the machine can boot from, as returned by
3045 <link to="ISystemProperties::maxBootPosition"/>).
3046 </desc>
3047 </param>
3048 <param name="device" type="DeviceType" dir="return">
3049 <desc>
3050 Device at the given position.
3051 </desc>
3052 </param>
3053 </method>
3054
3055 <method name="attachHardDisk">
3056 <desc>
3057
3058 Attaches a virtual hard disk identified by the given UUID to the
3059 given device slot of the given channel on the given bus. The
3060 specified device slot must not have another disk attached and the
3061 given hard disk must not be already attached to this machine.
3062
3063 See <link to="IHardDisk"/> for detailed information about
3064 attaching hard disks.
3065
3066 <note>You cannot attach a hard disk to a running machine. Also,
3067 you cannot attach a hard disk to a newly created machine until
3068 it is registered.</note>
3069
3070 <note>Attaching a hard disk to a machine creates a <i>lazy</i>
3071 attachment. In particular, no differeincing images are
3072 actually created until <link to="#saveSettings()"/> is called to
3073 commit all changed settings.</note>
3074
3075 </desc>
3076 <param name="id" type="uuid" dir="in">
3077 <desc>UUID of the hard disk to attach.</desc>
3078 </param>
3079 <param name="bus" type="StorageBus" dir="in">
3080 <desc>Type of storage bus to use (IDE or SATA).</desc>
3081 </param>
3082 <param name="channel" type="long" dir="in">
3083 <desc>Channel to attach the hard disk to. For IDE controllers,
3084 this can either be 0 or 1, for the primary or secondary controller,
3085 respectively.</desc>
3086 </param>
3087 <param name="device" type="long" dir="in">
3088 <desc>Device slot in the given channel to attach the hard disk to.
3089 For IDE devices, within each channel (0 or 1), this can again be
3090 0 or 1, for master or slave, respectively.</desc>
3091 </param>
3092 </method>
3093
3094 <method name="getHardDisk" const="yes">
3095 <desc>
3096 Returns the hard disk attached to the
3097 given controller under the specified device number.
3098 </desc>
3099 <param name="bus" type="StorageBus" dir="in"/>
3100 <param name="channel" type="long" dir="in"/>
3101 <param name="device" type="long" dir="in"/>
3102 <param name="hardDisk" type="IHardDisk" dir="return"/>
3103 </method>
3104
3105 <method name="detachHardDisk">
3106 <desc>
3107
3108 Detaches the hard disk drive attached to the given device slot
3109 of the given controller.
3110
3111 See <link to="IHardDisk"/> for detailed information about
3112 attaching hard disks.
3113
3114 <note>You cannot detach a hard disk from a running
3115 machine.</note>
3116
3117 <note>
3118 Detaching a hard disk from a machine creates a <i>lazy</i>
3119 detachment. In particular, if the detached hard disk is a
3120 differencing hard disk, it is not actually deleted until
3121 <link to="#saveSettings()"/> is called to commit all changed settings.
3122 Keep in mind, that doing <link to="#saveSettings()"/> will
3123 <b>physically delete</b> all detached differencing hard disks,
3124 so be careful.
3125 </note>
3126
3127 </desc>
3128 <param name="bus" type="StorageBus" dir="in">
3129 <desc>Bus to dettach the hard disk from.</desc>
3130 </param>
3131 <param name="channel" type="long" dir="in">
3132 <desc>Channel number to dettach the hard disk from.</desc>
3133 </param>
3134 <param name="device" type="long" dir="in">
3135 <desc>Device slot number to dettach the hard disk from.</desc>
3136 </param>
3137 </method>
3138
3139 <method name="getNetworkAdapter" const="yes">
3140 <desc>
3141 Returns the network adapter associated with the given slot.
3142 Slots are numbered sequentially, starting with zero. The total
3143 number of adapters per every machine is defined by the
3144 <link to="ISystemProperties::networkAdapterCount"/> property,
3145 so the maximum slot number is one less than that property's value.
3146 </desc>
3147 <param name="slot" type="unsigned long" dir="in"/>
3148 <param name="adapter" type="INetworkAdapter" dir="return"/>
3149 </method>
3150
3151 <method name="getSerialPort" const="yes">
3152 <desc>
3153 Returns the serial port associated with the given slot.
3154 Slots are numbered sequentially, starting with zero. The total
3155 number of serial ports per every machine is defined by the
3156 <link to="ISystemProperties::serialPortCount"/> property,
3157 so the maximum slot number is one less than that property's value.
3158 </desc>
3159 <param name="slot" type="unsigned long" dir="in"/>
3160 <param name="port" type="ISerialPort" dir="return"/>
3161 </method>
3162
3163 <method name="getParallelPort" const="yes">
3164 <desc>
3165 Returns the parallel port associated with the given slot.
3166 Slots are numbered sequentially, starting with zero. The total
3167 number of parallel ports per every machine is defined by the
3168 <link to="ISystemProperties::parallelPortCount"/> property,
3169 so the maximum slot number is one less than that property's value.
3170 </desc>
3171 <param name="slot" type="unsigned long" dir="in"/>
3172 <param name="port" type="IParallelPort" dir="return"/>
3173 </method>
3174
3175 <method name="getNextExtraDataKey">
3176 <desc>
3177 Returns the machine-specific extra data key name following the
3178 supplied key.
3179
3180 An error is returned if the supplied @a key does not exist. @c NULL is
3181 returned in @a nextKey if the supplied key is the last key. When
3182 supplying @c NULL for the @a key, the first key item is returned in @a
3183 nextKey (if there is any). @a nextValue is an optional parameter and
3184 if supplied, the next key's value is returned in it.
3185 </desc>
3186 <param name="key" type="wstring" dir="in">
3187 <desc>Name of the data key to follow.</desc>
3188 </param>
3189 <param name="nextKey" type="wstring" dir="out">
3190 <desc>Name of the next data key.</desc>
3191 </param>
3192 <param name="nextValue" type="wstring" dir="out">
3193 <desc>Value of the next data key.</desc>
3194 </param>
3195 </method>
3196
3197 <method name="getExtraData">
3198 <desc>
3199 Returns associated machine-specific extra data.
3200
3201 If the reuqested data @a key does not exist, this function will
3202 succeed and return @c NULL in the @a value argument.
3203 </desc>
3204 <param name="key" type="wstring" dir="in">
3205 <desc>Name of the data key to get.</desc>
3206 </param>
3207 <param name="value" type="wstring" dir="return">
3208 <desc>Value of the requested data key.</desc>
3209 </param>
3210 </method>
3211
3212 <method name="setExtraData">
3213 <desc>
3214 Sets associated machine-specific extra data.
3215
3216 If you pass @c NULL as a key @a vaule, the given @a key will be
3217 deleted.
3218
3219 <note>
3220 Before performing the actual data change, this method will ask all
3221 registered callbacks using the
3222 <link to="IVirtualBoxCallback::onExtraDataCanChange()"/>
3223 notification for a permission. If one of the callbacks refuses the
3224 new value, the change will not be performed.
3225 </note>
3226 <note>
3227 On success, the
3228 <link to="IVirtualBoxCallback::onExtraDataChange()"/> notification
3229 is called to inform all registered callbacks about a successful data
3230 change.
3231 </note>
3232 <note>
3233 This method can be called outside the machine session and therefore
3234 it's a caller's responsibility to handle possible race conditions
3235 when several clients change the same key at the same time.
3236 </note>
3237 </desc>
3238 <param name="key" type="wstring" dir="in">
3239 <desc>Name of the data key to set.</desc>
3240 </param>
3241 <param name="value" type="wstring" dir="in">
3242 <desc>Value to assign to the key.</desc>
3243 </param>
3244 </method>
3245
3246 <method name="saveSettings">
3247 <desc>
3248 Saves any changes to machine settings made since the session
3249 has been opened or a new machine has been created, or since the
3250 last call to <link to="#saveSettings()"/> or <link to="#discardSettings()"/>.
3251 For registered machines, new settings become visible to all
3252 other VirtualBox clients after successful invocation of this
3253 method.
3254 <note>
3255 The method sends <link to="IVirtualBoxCallback::onMachineDataChange()"/>
3256 notification event after the configuration has been successfully
3257 saved (only for registered machines).
3258 </note>
3259 <note>
3260 Calling this method is only valid on instances returned
3261 by <link to="ISession::machine"/> and on new machines
3262 created by <link to="IVirtualBox::createMachine"/> but not
3263 yet registered, or on unregistered machines after calling
3264 <link to="IVirtualBox::unregisterMachine"/>.
3265 </note>
3266 </desc>
3267 </method>
3268
3269 <method name="saveSettingsWithBackup">
3270 <desc>
3271 Creates a backup copy of the machine settings file (<link
3272 to="#settingsFilePath"/>) in case of auto-conversion, and then calls
3273 <link to="#saveSettings()"/>.
3274
3275 Note that the backup copy is created <b>only</b> if the settings file
3276 auto-conversion took place (see <link to="#settingsFileVersion"/> for
3277 details). Otherwise, this call is fully equivalent to
3278 <link to="#saveSettings()"/> and no backup copying is done.
3279
3280 The backup copy is created in the same directory where the original
3281 settings file is located. It is given the following file name:
3282 <pre>
3283 original.xml.x.y-platform.bak
3284 </pre>
3285 where <tt>original.xml</tt> is the original settings file name
3286 (excluding path), and <tt>x.y-platform</tt> is the version of the old
3287 format of the settings file (before auto-conversion).
3288
3289 If the given backup file already exists, this method will try to add the
3290 <tt>.N</tt> suffix to the backup file name (where <tt>N</tt> counts from
3291 0 to 9) and copy it again until it succeeds. If all suffixes are
3292 occupied, or if any other copy error occurs, this method will return a
3293 failure.
3294
3295 If the copy operation succeeds, the @a bakFileName return argument will
3296 receive a full path to the created backup file (for informational
3297 purposes). Note that this will happen even if the subsequent
3298 <link to="#saveSettings()"/> call performed by this method after the
3299 copy operation, fails.
3300
3301 <note>
3302 The VirtualBox API never calls this method. It is intended purely for
3303 the purposes of creating backup copies of the settings files by
3304 front-ends before saving the results of the automatically performed
3305 settings conversion to disk.
3306 </note>
3307
3308 <see>settingsFileVersion</see>
3309 </desc>
3310 <param name="bakFileName" type="wstring" dir="return">
3311 <desc>Full path to the created backup copy.</desc>
3312 </param>
3313 </method>
3314
3315 <method name="discardSettings">
3316 <desc>
3317 Discards any changes to the machine settings made since the session
3318 has been opened or since the last call to <link to="#saveSettings()"/>
3319 or <link to="#discardSettings"/>.
3320 <note>
3321 Calling this method is only valid on instances returned
3322 by <link to="ISession::machine"/> and on new machines
3323 created by <link to="IVirtualBox::createMachine"/> or
3324 opened by <link to="IVirtualBox::openMachine"/> but not
3325 yet registered, or on unregistered machines after calling
3326 <link to="IVirtualBox::unregisterMachine"/>.
3327 </note>
3328 </desc>
3329 </method>
3330
3331 <method name="deleteSettings">
3332 <desc>
3333 Deletes the settings file of this machine from disk.
3334 The machine must not be registered in order for this operation
3335 to succeed.
3336 <note>
3337 <link to="#settingsModified"/> will return TRUE after this
3338 method successfully returns.
3339 </note>
3340 <note>
3341 Calling this method is only valid on instances returned
3342 by <link to="ISession::machine"/> and on new machines
3343 created by <link to="IVirtualBox::createMachine"/> or
3344 opened by <link to="IVirtualBox::openMachine"/> but not
3345 yet registered, or on unregistered machines after calling
3346 <link to="IVirtualBox::unregisterMachine"/>.
3347 </note>
3348 <note>
3349 The deleted machine settings file can be restored (saved again)
3350 by calling <link to="#saveSettings()"/>.
3351 </note>
3352 </desc>
3353 </method>
3354
3355 <method name="getSnapshot">
3356 <desc>
3357 Returns a snapshot of this machine with the given UUID.
3358 A <tt>null</tt> UUID can be used to obtain the first snapshot
3359 taken on this machine. This is useful if you want to traverse
3360 the whole tree of snapshots starting from the root.
3361 </desc>
3362 <param name="id" type="uuid" dir="in">
3363 <desc>UUID of the snapshot to get</desc>
3364 </param>
3365 <param name="snapshot" type="ISnapshot" dir="return">
3366 <desc>Snapshot object with the given UUID.</desc>
3367 </param>
3368 </method>
3369
3370 <method name="findSnapshot">
3371 <desc>
3372 Returns a snapshot of this machine with the given name.
3373 </desc>
3374 <param name="name" type="wstring" dir="in">
3375 <desc>Name of the snapshot to find</desc>
3376 </param>
3377 <param name="snapshot" type="ISnapshot" dir="return">
3378 <desc>Snapshot object with the given name.</desc>
3379 </param>
3380 </method>
3381
3382 <method name="setCurrentSnapshot">
3383 <desc>
3384 Sets the current snapshot of this machine.
3385 <note>
3386 In the current implementation, this operation is not
3387 implemented.
3388 </note>
3389 </desc>
3390 <param name="id" type="uuid" dir="in">
3391 <desc>UUID of the snapshot to set as the current snapshot.</desc>
3392 </param>
3393 </method>
3394
3395 <method name="createSharedFolder">
3396 <desc>
3397 Creates a new permanent shared folder by associating the given logical
3398 name with the given host path, adds it to the collection of shared
3399 folders and starts sharing it. Refer to the description of
3400 <link to="ISharedFolder"/> to read more about logical names.
3401 </desc>
3402 <param name="name" type="wstring" dir="in">
3403 <desc>Unique logical name of the shared folder.</desc>
3404 </param>
3405 <param name="hostPath" type="wstring" dir="in">
3406 <desc>Full path to the shared folder in the host file system.</desc>
3407 </param>
3408 <param name="writable" type="boolean" dir="in">
3409 <desc>Whether the share is writable or readonly</desc>
3410 </param>
3411 </method>
3412
3413 <method name="removeSharedFolder">
3414 <desc>
3415 Removes the permanent shared folder with the given name previously
3416 created by <link to="#createSharedFolder"/> from the collection of
3417 shared folders and stops sharing it.
3418 </desc>
3419 <param name="name" type="wstring" dir="in">
3420 <desc>Logical name of the shared folder to remove.</desc>
3421 </param>
3422 </method>
3423
3424 <method name="canShowConsoleWindow">
3425 <desc>
3426 Returns @c true if the VM console process can activate the
3427 console window and bring it to foreground on the desktop of
3428 the host PC.
3429 <note>
3430 This method will fail if a session for this machine is not
3431 currently open.
3432 </note>
3433 </desc>
3434 <param name="canShow" type="boolean" dir="return">
3435 <desc>
3436 @c true if the console window can be shown and @c
3437 false otherwise.
3438 </desc>
3439 </param>
3440 </method>
3441
3442 <method name="showConsoleWindow">
3443 <desc>
3444 Activates the console window and brings it to foreground on
3445 the desktop of the host PC. Many modern window managers on
3446 many platforms implement some sort of focus stealing
3447 prevention logic, so that it may be impossible to activate
3448 a window without the help of the currently active
3449 application. In this case, this method will return a non-zero
3450 identifier that represents the top-level window of the VM
3451 console process. The caller, if it represents a currently
3452 active process, is responsible to use this identifier (in a
3453 platform-dependent manner) to perform actual window
3454 activation.
3455 <note>
3456 This method will fail if a session for this machine is not
3457 currently open.
3458 </note>
3459 </desc>
3460 <param name="winId" type="unsigned long long" dir="return">
3461 <desc>
3462 Platform-dependent identifier of the top-level VM console
3463 window, or zero if this method has performed all actions
3464 necessary to implement the <i>show window</i> semantics for
3465 the given platform and/or VirtualBox front-end.
3466 </desc>
3467 </param>
3468 </method>
3469
3470 <method name="getGuestProperty">
3471 <desc>
3472 Reads a value from the machine's host/guest property store.
3473
3474 If a session for this virtual machine is currently open then queries the
3475 session object for the value, since the current values of the property
3476 store will be held in RAM in the session. Otherwise reads the value from
3477 machine extra data, where it is stored between sessions.
3478
3479 This method will fail if we are currently transitioning between session
3480 states.
3481 </desc>
3482 <param name="key" type="wstring" dir="in">
3483 <desc>
3484 The name of the key to read.
3485 </desc>
3486 </param>
3487 <param name="value" type="wstring" dir="return">
3488 <desc>
3489 The value of the key. If the key does not exist then this will be
3490 empty.
3491 </desc>
3492 </param>
3493 </method>
3494
3495 <method name="setGuestProperty">
3496 <desc>
3497 Sets, changes or deletes a value in the machine's host/guest
3498 property store.
3499
3500 If a session for this virtual machine is currently open then changes the
3501 value on the session object, since the current values of the property
3502 store will be held in RAM in the session. Otherwise changes the value
3503 in machine extra data, where it is stored between sessions.
3504
3505 This method will fail if we are currently transitioning between session
3506 states.
3507 </desc>
3508 <param name="key" type="wstring" dir="in">
3509 <desc>
3510 The name of the key to set, change or delete.
3511 </desc>
3512 </param>
3513 <param name="value" type="wstring" dir="in">
3514 <desc>
3515 The new value of the key to set, change or delete. If the key does
3516 not yet exist and @a value is non-empty, it will be created. If
3517 @a value is empty, the key will be deleted if it exists.
3518 </desc>
3519 </param>
3520 </method>
3521
3522 <method name="getProcessorUsage">
3523 <desc>
3524 Returns the current processor usage by this virtual machine measured
3525 over all cores of all processors in the host system.
3526
3527 The values returned for each parameter are in range from <tt>0</tt> (the
3528 machine is powered off or does not load the CPUs at all) to
3529 <tt>1 000 000 000</tt> (all cores of all CPUs are fully in use by this
3530 machine).
3531 </desc>
3532 <param name="user" type="unsigned long" dir="out">
3533 <desc>
3534 Pecentage of processor time spent executing in user mode.
3535 </desc>
3536 </param>
3537 <param name="system" type="unsigned long" dir="out">
3538 <desc>
3539 Pecentage of processor time spent executing in kernel mode.
3540 </desc>
3541 </param>
3542 </method>
3543
3544 </interface>
3545
3546 <!--
3547 // IConsole
3548 /////////////////////////////////////////////////////////////////////////
3549 -->
3550
3551 <interface
3552 name="IConsoleCallback" extends="$unknown"
3553 uuid="13dfbef3-b74d-487d-bada-2304529aefa6"
3554 wsmap="suppress"
3555 >
3556
3557 <method name="onMousePointerShapeChange">
3558 <desc>
3559 Notification when the guest mouse pointer shape has
3560 changed. The new shape data is given.
3561 </desc>
3562 <param name="visible" type="boolean" dir="in">
3563 <desc>
3564 Flag whether the pointer is visible.
3565 </desc>
3566 </param>
3567 <param name="alpha" type="boolean" dir="in">
3568 <desc>
3569 Flag whether the pointer has an alpha channel.
3570 </desc>
3571 </param>
3572 <param name="xHot" type="unsigned long" dir="in">
3573 <desc>
3574 The pointer hot spot x coordinate.
3575 </desc>
3576 </param>
3577 <param name="yHot" type="unsigned long" dir="in">
3578 <desc>
3579 The pointer hot spot y coordinate.
3580 </desc>
3581 </param>
3582 <param name="width" type="unsigned long" dir="in">
3583 <desc>
3584 Width of the pointer shape in pixels.
3585 </desc>
3586 </param>
3587 <param name="height" type="unsigned long" dir="in">
3588 <desc>
3589 Height of the pointer shape in pixels.
3590 </desc>
3591 </param>
3592 <param name="shape" type="octet" mod="ptr" dir="in">
3593 <desc>
3594 Address of the shape buffer.
3595
3596 The buffer contains 1 bpp (bits per pixel) AND mask followed by 32 bpp XOR (color) mask.
3597
3598 For pointers without alpha channel the XOR mask pixels are 32 bit values: (lsb)BGR0(msb).
3599 For pointers with alpha channel the XOR mask consists of (lsb)BGRA(msb) 32 bit values.
3600
3601 AND mask presents for pointers with alpha channel, so if the callback does not
3602 support alpha, the pointer could be displayed as a normal color pointer.
3603
3604 The AND mask is 1 bpp bitmap with byte aligned scanlines. Size of AND mask,
3605 therefore, is <tt>cbAnd = (width + 7) / 8 * height</tt>. The padding bits at the
3606 end of any scanline are undefined.
3607
3608 The XOR mask follows the AND mask on the next 4 bytes aligned offset:
3609 <tt>uint8_t *pXor = pAnd + (cbAnd + 3) &amp; ~3</tt>
3610 Bytes in the gap between the AND and the XOR mask are undefined.
3611 XOR mask scanlines have no gap between them and size of XOR mask is:
3612 <tt>cXor = width * 4 * height</tt>.
3613
3614 <note>
3615 If 'shape' is equal to 0, only pointer visibility is being changed.
3616 </note>
3617 </desc>
3618 </param>
3619 </method>
3620
3621 <method name="onMouseCapabilityChange">
3622 <desc>
3623 Notification when the mouse capabilities reported by the
3624 guest have changed. The new capabilities are passed.
3625 </desc>
3626 <param name="supportsAbsolute" type="boolean" dir="in"/>
3627 <param name="needsHostCursor" type="boolean" dir="in"/>
3628 </method>
3629
3630 <method name="onKeyboardLedsChange">
3631 <desc>
3632 Notification when the guest OS executes the KBD_CMD_SET_LEDS command
3633 to alter the state of the keyboard LEDs.
3634 </desc>
3635 <param name="numLock" type="boolean" dir="in"/>
3636 <param name="capsLock" type="boolean" dir="in"/>
3637 <param name="scrollLock" type="boolean" dir="in"/>
3638 </method>
3639
3640 <method name="onStateChange">
3641 <desc>
3642 Notification when the execution state of the machine has changed.
3643 The new state will be given.
3644 </desc>
3645 <param name="state" type="MachineState" dir="in"/>
3646 </method>
3647
3648 <method name="onAdditionsStateChange">
3649 <desc>
3650 Notification when a Guest Additions property changes.
3651 Interested callees should query IGuest attributes to
3652 find out what has changed.
3653 </desc>
3654 </method>
3655
3656 <method name="onDVDDriveChange">
3657 <desc>
3658 Notification when a property of the
3659 virtual <link to="IMachine::DVDDrive">DVD drive</link> changes.
3660 Interested callees should use IDVDDrive methods to find out what has
3661 changed.
3662 </desc>
3663 </method>
3664
3665 <method name="onFloppyDriveChange">
3666 <desc>
3667 Notification when a property of the
3668 virtual <link to="IMachine::FloppyDrive">floppy drive</link> changes.
3669 Interested callees should use IFloppyDrive methods to find out what
3670 has changed.
3671 </desc>
3672 </method>
3673
3674 <method name="onNetworkAdapterChange">
3675 <desc>
3676 Notification when a property of one of the
3677 virtual <link to="IMachine::getNetworkAdapter">network adapters</link>
3678 changes. Interested callees should use INetworkAdapter methods and
3679 attributes to find out what has changed.
3680 </desc>
3681 <param name="networkAdapter" type="INetworkAdapter" dir="in">
3682 <desc>Network adapter that is subject to change.</desc>
3683 </param>
3684 </method>
3685
3686 <method name="onSerialPortChange">
3687 <desc>
3688 Notification when a property of one of the
3689 virtual <link to="IMachine::getSerialPort">serial ports</link> changes.
3690 Interested callees should use ISerialPort methods and attributes
3691 to find out what has changed.
3692 </desc>
3693 <param name="serialPort" type="ISerialPort" dir="in">
3694 <desc>Serial port that is subject to change.</desc>
3695 </param>
3696 </method>
3697
3698 <method name="onParallelPortChange">
3699 <desc>
3700 Notification when a property of one of the
3701 virtual <link to="IMachine::getParallelPort">parallel ports</link>
3702 changes. Interested callees should use ISerialPort methods and
3703 attributes to find out what has changed.
3704 </desc>
3705 <param name="parallelPort" type="IParallelPort" dir="in">
3706 <desc>Parallel port that is subject to change.</desc>
3707 </param>
3708 </method>
3709
3710 <method name="onVRDPServerChange">
3711 <desc>
3712 Notification when a property of the
3713 <link to="IMachine::VRDPServer">VRDP server</link> changes.
3714 Interested callees should use IVRDPServer methods and attributes to
3715 find out what has changed.
3716 </desc>
3717 </method>
3718
3719 <method name="onUSBControllerChange">
3720 <desc>
3721 Notification when a property of the virtual
3722 <link to="IMachine::USBController">USB controller</link> changes.
3723 Interested callees should use IUSBController methods and attributes to
3724 find out what has changed.
3725 </desc>
3726 </method>
3727
3728 <method name="onUSBDeviceStateChange">
3729 <desc>
3730 Notification when a USB device is attached to or detached from
3731 the virtual USB controller.
3732
3733 This notification is sent as a result of the indirect
3734 request to attach the device because it matches one of the
3735 machine USB filters, or as a result of the direct request
3736 issued by <link to="IConsole::attachUSBDevice"/> or
3737 <link to="IConsole::detachUSBDevice"/>.
3738
3739 This notification is sent in case of both a succeeded and a
3740 failed request completion. When the request succeeds, the @a
3741 error parameter is @c null, and the given device has been
3742 already added to (when @a attached is @c true) or removed from
3743 (when @a attached is @c false) the collection represented by
3744 <link to="IConsole::USBDevices"/>. On failure, the collection
3745 doesn't change and the @a error perameter represents the error
3746 message describing the failure.
3747
3748 </desc>
3749 <param name="device" type="IUSBDevice" dir="in">
3750 <desc>Device that is subject to state change.</desc>
3751 </param>
3752 <param name="attached" type="boolean" dir="in">
3753 <desc>
3754 <tt>true</tt> if the device was attached
3755 and <tt>false</tt> otherwise.
3756 </desc>
3757 </param>
3758 <param name="error" type="IVirtualBoxErrorInfo" dir="in">
3759 <desc>
3760 <tt>null</tt> on success or an error message object on
3761 failure.
3762 </desc>
3763 </param>
3764 </method>
3765
3766 <method name="onSharedFolderChange">
3767 <desc>
3768 Notification when a shared folder is added or removed.
3769 The @a scope argument defines one of three scopes:
3770 <link to="IVirtualBox::sharedFolders">global shared folders</link>
3771 (<link to="Scope::Global">Global</link>),
3772 <link to="IMachine::sharedFolders">permanent shared folders</link> of
3773 the machine (<link to="Scope::Machine">Machine</link>) or <link
3774 to="IConsole::sharedFolders">transient shared folders</link> of the
3775 machine (<link to="Scope::Session">Session</link>). Interested callees
3776 should use query the corresponding collections to find out what has
3777 changed.
3778 </desc>
3779 <param name="scope" type="Scope" dir="in">
3780 <desc>Sope of the notification.</desc>
3781 </param>
3782 </method>
3783
3784 <method name="onRuntimeError">
3785 <desc>
3786 Notification when an error happens during the virtual
3787 machine execution.
3788
3789 There are three kinds of runtime errors:
3790 <ul>
3791 <li><i>fatal</i></li>
3792 <li><i>non-fatal with retry</i></li>
3793 <li><i>non-fatal warnings</i></li>
3794 </ul>
3795
3796 <b>Fatal</b> errors are indicated by the @a fatal parameter set
3797 to <tt>true</tt>. In case of fatal errors, the virtual machine
3798 execution is always paused before calling this notification, and
3799 the notification handler is supposed either to immediately save
3800 the virtual machine state using <link to="IConsole::saveState()"/>
3801 or power it off using <link to="IConsole::powerDown()"/>.
3802 Resuming the execution can lead to unpredictable results.
3803
3804 <b>Non-fatal</b> errors and warnings are indicated by the
3805 @a fatal parameter set to <tt>false</tt>. If the virtual machine
3806 is in the Paused state by the time the error notification is
3807 received, it means that the user can <i>try to resume</i> the machine
3808 execution after attempting to solve the probem that caused the
3809 error. In this case, the notification handler is supposed
3810 to show an appropriate message to the user (depending on the
3811 value of the @a id parameter) that offers several actions such
3812 as <i>Retry</i>, <i>Save</i> or <i>Power Off</i>. If the user
3813 wants to retry, the notification handler should continue
3814 the machine execution using the <link to="IConsole::resume()"/>
3815 call. If the machine execution is not Paused during this
3816 notification, then it means this notification is a <i>warning</i>
3817 (for example, about a fatal condition that can happen very soon);
3818 no immediate action is required from the user, the machine
3819 continues its normal execution.
3820
3821 Note that in either case the notification handler
3822 <b>must not</b> perform any action directly on a thread
3823 where this notification is called. Everything it is allowed to
3824 do is to post a message to another thread that will then talk
3825 to the user and take the corresponding action.
3826
3827 Currently, the following error identificators are known:
3828 <ul>
3829 <li><tt>"HostMemoryLow"</tt></li>
3830 <li><tt>"HostAudioNotResponding"</tt></li>
3831 <li><tt>"VDIStorageFull"</tt></li>
3832 </ul>
3833
3834 <note>
3835 This notification is not designed to be implemented by
3836 more than one callback at a time. If you have multiple
3837 IConsoleCallback instances registered on the given
3838 IConsole object, make sure you simply do nothing but
3839 return @c S_OK from all but one of them that does actual
3840 user notification and performs necessary actions.
3841 </note>
3842
3843 </desc>
3844 <param name="fatal" type="boolean" dir="in">
3845 <desc>Whether the error is fatal or not</desc>
3846 </param>
3847 <param name="id" type="wstring" dir="in">
3848 <desc>Error identificator</desc>
3849 </param>
3850 <param name="message" type="wstring" dir="in">
3851 <desc>Optional error message</desc>
3852 </param>
3853 </method>
3854
3855 <method name="onCanShowWindow">
3856 <desc>
3857 Notification when a call to
3858 <link to="IMachine::canShowConsoleWindow()"/> is made by a
3859 front-end to check if a subsequent call to
3860 <link to="IMachine::showConsoleWindow()"/> can succeed.
3861
3862 The callee should give an answer appropriate to the current
3863 machine state in the @a canShow argument. This answer must
3864 remain valid at least until the next
3865 <link to="IConsole::state">machine state</link> change.
3866
3867 <note>
3868 This notification is not designed to be implemented by
3869 more than one callback at a time. If you have multiple
3870 IConsoleCallback instances registered on the given
3871 IConsole object, make sure you simply do nothing but
3872 return @c true and @c S_OK from all but one of them that
3873 actually manages console window activation.
3874 </note>
3875 </desc>
3876 <param name="canShow" type="boolean" dir="return">
3877 <desc>
3878 @c true if the console window can be shown and @c
3879 false otherwise.
3880 </desc>
3881 </param>
3882 </method>
3883
3884 <method name="onShowWindow">
3885 <desc>
3886 Notification when a call to
3887 <link to="IMachine::showConsoleWindow()"/>
3888 requests the console window to be activated and brought to
3889 foreground on the desktop of the host PC.
3890
3891 This notification should cause the VM console process to
3892 perform the requested action as described above. If it is
3893 impossible to do it at a time of this notification, this
3894 method should return a failure.
3895
3896 Note that many modern window managers on many platforms
3897 implement some sort of focus stealing prevention logic, so
3898 that it may be impossible to activate a window without the
3899 help of the currently active application (which is supposedly
3900 an initiator of this notification). In this case, this method
3901 must return a non-zero identifier that represents the
3902 top-level window of the VM console process. The caller, if it
3903 represents a currently active process, is responsible to use
3904 this identifier (in a platform-dependent manner) to perform
3905 actual window activation.
3906
3907 This method must set @a winId to zero if it has performed all
3908 actions necessary to complete the request and the console
3909 window is now active and in foreground, to indicate that no
3910 further action is required on the caller's side.
3911
3912 <note>
3913 This notification is not designed to be implemented by
3914 more than one callback at a time. If you have multiple
3915 IConsoleCallback instances registered on the given
3916 IConsole object, make sure you simply do nothing but
3917 return@c S_OK from all but one of them that actually
3918 manages console window activation.
3919 </note>
3920 </desc>
3921 <param name="winId" type="unsigned long long" dir="return">
3922 <desc>
3923 Platform-dependent identifier of the top-level VM console
3924 window, or zero if this method has performed all actions
3925 necessary to implement the <i>show window</i> semantics for
3926 the given platform and/or this VirtualBox front-end.
3927 </desc>
3928 </param>
3929 </method>
3930
3931 </interface>
3932
3933 <interface
3934 name="IRemoteDisplayInfo" extends="$unknown"
3935 uuid="550104cd-2dfd-4a6c-857d-f6f8e088e62c"
3936 wsmap="struct"
3937 >
3938 <desc>
3939 Contains information about the remote display (VRDP) capabilities and status.
3940 This is used in the <link to="IConsole::remoteDisplayInfo" /> attribute.
3941
3942 <note>With the COM API, this is an interface like all the others. With the webservice,
3943 this is mapped to a structure, so querying the attribute will not return an object,
3944 but a complete structure.</note>
3945 </desc>
3946
3947 <attribute name="active" type="boolean" readonly="yes">
3948 <desc>
3949 Whether the remote display connection is active.
3950 </desc>
3951 </attribute>
3952
3953 <attribute name="numberOfClients" type="unsigned long" readonly="yes">
3954 <desc>
3955 How many times a client connected.
3956 </desc>
3957 </attribute>
3958
3959 <attribute name="beginTime" type="long long" readonly="yes">
3960 <desc>
3961 When the last connection was established, in milliseconds since 1970-01-01 UTC.
3962 </desc>
3963 </attribute>
3964
3965 <attribute name="endTime" type="long long" readonly="yes">
3966 <desc>
3967 When the last connection was terminated or the current time, if
3968 connection is still active, in milliseconds since 1970-01-01 UTC.
3969 </desc>
3970 </attribute>
3971
3972 <attribute name="bytesSent" type="unsigned long long" readonly="yes">
3973 <desc>
3974 How many bytes were sent in last or current, if still active, connection.
3975 </desc>
3976 </attribute>
3977
3978 <attribute name="bytesSentTotal" type="unsigned long long" readonly="yes">
3979 <desc>
3980 How many bytes were sent in all connections.
3981 </desc>
3982 </attribute>
3983
3984 <attribute name="bytesReceived" type="unsigned long long" readonly="yes">
3985 <desc>
3986 How many bytes were received in last or current, if still active, connection.
3987 </desc>
3988 </attribute>
3989
3990 <attribute name="bytesReceivedTotal" type="unsigned long long" readonly="yes">
3991 <desc>
3992 How many bytes were received in all connections.
3993 </desc>
3994 </attribute>
3995
3996 <attribute name="user" type="wstring" readonly="yes">
3997 <desc>
3998 Login user name supplied by the client.
3999 </desc>
4000 </attribute>
4001
4002 <attribute name="domain" type="wstring" readonly="yes">
4003 <desc>
4004 Login domain name supplied by the client.
4005 </desc>
4006 </attribute>
4007
4008 <attribute name="clientName" type="wstring" readonly="yes">
4009 <desc>
4010 The client name supplied by the client.
4011 </desc>
4012 </attribute>
4013
4014 <attribute name="clientIP" type="wstring" readonly="yes">
4015 <desc>
4016 The IP address of the client.
4017 </desc>
4018 </attribute>
4019
4020 <attribute name="clientVersion" type="unsigned long" readonly="yes">
4021 <desc>
4022 The client software version number.
4023 </desc>
4024 </attribute>
4025
4026 <attribute name="encryptionStyle" type="unsigned long" readonly="yes">
4027 <desc>
4028 Public key exchange method used when connection was established.
4029 Values: 0 - RDP4 public key exchange scheme.
4030 1 - X509 sertificates were sent to client.
4031 </desc>
4032 </attribute>
4033
4034 </interface>
4035
4036 <interface
4037 name="IConsole" extends="$unknown"
4038 uuid="d5a1cbda-f5d7-4824-9afe-d640c94c7dcf"
4039 wsmap="managed"
4040 >
4041 <desc>
4042 The IConsole interface represents an interface to control virtual
4043 machine execution.
4044
4045 The console object that implements the IConsole interface is obtained
4046 from a session object after the session for the given machine has been
4047 opened using one of <link to="IVirtualBox::openSession"/>,
4048 <link to="IVirtualBox::openRemoteSession"/> or
4049 <link to="IVirtualBox::openExistingSession"/> methdods.
4050
4051 Methods of the IConsole interface allow the caller to query the current
4052 virtual machine execution state, pause the machine or power it down, save
4053 the machine state or take a snapshot, attach and detach removable media
4054 and so on.
4055
4056 <see>ISession</see>
4057 </desc>
4058
4059 <attribute name="machine" type="IMachine" readonly="yes">
4060 <desc>
4061 Machine object this console is sessioned with.
4062 <note>
4063 This is a convenience property, it has the same value as
4064 <link to="ISession::machine"/> of the corresponding session
4065 object.
4066 </note>
4067 </desc>
4068 </attribute>
4069
4070 <attribute name="state" type="MachineState" readonly="yes">
4071 <desc>
4072 Current execution state of the machine.
4073 <note>
4074 This property always returns the same value as the corresponding
4075 property of the IMachine object this console is sessioned with.
4076 For the process that owns (executes) the VM, this is the
4077 preferable way of querying the VM state, because no IPC
4078 calls are made.
4079 </note>
4080 </desc>
4081 </attribute>
4082
4083 <attribute name="guest" type="IGuest" readonly="yes">
4084 <desc>Guest object.</desc>
4085 </attribute>
4086
4087 <attribute name="keyboard" type="IKeyboard" readonly="yes">
4088 <desc>
4089 Virtual keyboard object.
4090 <note>
4091 If the machine is not running, any attempt to use
4092 the returned object will result in an error.
4093 </note>
4094 </desc>
4095 </attribute>
4096
4097 <attribute name="mouse" type="IMouse" readonly="yes">
4098 <desc>
4099 Virtual mouse object.
4100 <note>
4101 If the machine is not running, any attempt to use
4102 the returned object will result in an error.
4103 </note>
4104 </desc>
4105 </attribute>
4106
4107 <attribute name="display" type="IDisplay" readonly="yes">
4108 <desc>Virtual display object.
4109 <note>
4110 If the machine is not running, any attempt to use
4111 the returned object will result in an error.
4112 </note>
4113 </desc>
4114 </attribute>
4115
4116 <attribute name="debugger" type="IMachineDebugger" readonly="yes">
4117 <desc>Debugging interface.</desc>
4118 </attribute>
4119
4120 <attribute name="USBDevices" type="IUSBDeviceCollection" readonly="yes">
4121 <desc>
4122 Collection of USB devices currently attached to the virtual
4123 USB controller.
4124 <note>
4125 The collection is empty if the machine is not running.
4126 </note>
4127 </desc>
4128 </attribute>
4129
4130 <attribute name="remoteUSBDevices" type="IHostUSBDeviceCollection" readonly="yes">
4131 <desc>
4132 List of USB devices currently attached to the remote VRDP client.
4133 Once a new device is physically attached to the remote host computer,
4134 it appears in this list and remains there until detached.
4135 </desc>
4136 </attribute>
4137
4138 <attribute name="sharedFolders" type="ISharedFolderCollection" readonly="yes">
4139 <desc>
4140 Collection of shared folders for the current session. These folders
4141 are called transient shared folders because they are available to the
4142 guest OS running inside the associated virtual machine only for the
4143 duration of the session (as opposed to
4144 <link to="IMachine::sharedFolders"/> which represent permanent shared
4145 folders). When the session is closed (e.g. the machine is powered down),
4146 these folders are automatically discarded.
4147
4148 New shared folders are added to the collection using
4149 <link to="#createSharedFolder"/>. Existing shared folders can be
4150 removed using <link to="#removeSharedFolder"/>.
4151 </desc>
4152 </attribute>
4153
4154 <attribute name="remoteDisplayInfo" type="IRemoteDisplayInfo" readonly="yes">
4155 <desc>
4156 Interface that provides information on Remote Display (VRDP) connection.
4157 </desc>
4158 </attribute>
4159
4160 <method name="powerUp">
4161 <desc>
4162 Starts the virtual machine execution using the current machine
4163 state (i.e. its current execution state, current settings and
4164 current hard disks).
4165
4166 If the machine is powered off or aborted, the execution will
4167 start from the beginning (as if the real hardware were just
4168 powered on).
4169
4170 If the machine is in the <link to="MachineState::Saved"/> state,
4171 it will continue its execution the point where the state has
4172 been saved.
4173
4174 <note>
4175 Unless you are trying to write a new VirtualBox front-end that
4176 performs direct machine execution (like the VirtualBox or VBoxSDL
4177 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
4178 session opened by <link to="IVirtualBox::openSession"/> and use this
4179 session only to change virtual machine settings. If you simply want to
4180 start virtual machine execution using one of the existing front-ends
4181 (for example the VirtualBox GUI or headless server), simply use
4182 <link to="IVirtualBox::openRemoteSession"/>; these front-ends
4183 will power up the machine automatically for you.
4184 </note>
4185
4186 <see>#saveState</see>
4187 </desc>
4188 <param name="progress" type="IProgress" dir="return">
4189 <desc>Progress object to track the operation completion.</desc>
4190 </param>
4191 </method>
4192
4193 <method name="powerDown">
4194 <desc>
4195 Stops the virtual machine execution.
4196 After this operation completes, the machine will go to the
4197 PoweredOff state.
4198 </desc>
4199 </method>
4200
4201 <method name="reset">
4202 <desc>Resets the virtual machine.</desc>
4203 </method>
4204
4205 <method name="pause">
4206 <desc>Pauses the virtual machine execution.</desc>
4207 </method>
4208
4209 <method name="resume">
4210 <desc>Resumes the virtual machine execution.</desc>
4211 </method>
4212
4213 <method name="powerButton">
4214 <desc>Send the ACPI power button event to the guest.</desc>
4215 </method>
4216
4217 <method name="sleepButton">
4218 <desc>Send the ACPI sleep button event to the guest.</desc>
4219 </method>
4220
4221 <method name="getPowerButtonHandled">
4222 <desc>Check if the last power button event was handled by guest.</desc>
4223 <param name="handled" type="boolean" dir="return"/>
4224 </method>
4225
4226 <method name="saveState">
4227 <desc>
4228 Saves the current execution state of a running virtual machine
4229 and stops its execution.
4230
4231 After this operation completes, the machine will go to the
4232 Saved state. Next time it is powered up, this state will
4233 be restored and the machine will continue its execution from
4234 the place where it was saved.
4235
4236 This operation differs from taking a snapshot to the effect
4237 that it doesn't create new differencing hard disks. Also, once
4238 the machine is powered up from the state saved using this method,
4239 the saved state is deleted, so it will be impossible to return
4240 to this state later.
4241
4242 <note>
4243 On success, this method implicitly calls
4244 <link to="IMachine::saveSettings()"/> to save all current machine
4245 settings (including runtime changes to the DVD drive, etc.).
4246 Together with the impossibility to change any VM settings when it is
4247 in the Saved state, this guarantees the adequate hardware
4248 configuration of the machine when it is restored from the saved
4249 state file.
4250 </note>
4251
4252 <note>
4253 The machine must be in the Running or Paused state, otherwise
4254 the operation will fail.
4255 </note>
4256
4257 <see><link to="#takeSnapshot"/></see>
4258 </desc>
4259 <param name="progress" type="IProgress" dir="return">
4260 <desc>Progress object to track the operation completion.</desc>
4261 </param>
4262 </method>
4263
4264 <method name="adoptSavedState">
4265 <desc>
4266 Associates the given saved state file to the virtual machine.
4267
4268 On success, the machine will go to the Saved state. Next time it is
4269 powered up, it will be restored from the adopted saved state and
4270 continue execution from the place where the saved state file was
4271 created.
4272
4273 The specified saved state file path may be full or relative to the
4274 folder the VM normally saves the state to (usually,
4275 <link to="IMachine::snapshotFolder"/>).
4276
4277 <note>
4278 It's a caller's responsibility to make sure the given saved state
4279 file is compatible with the settings of this virtual machine that
4280 represent its virtual hardware (memory size, hard disk configuration
4281 etc.). If there is a mismatch, the behavior of the virtual machine
4282 is undefined.
4283 </note>
4284 </desc>
4285 <param name="savedStateFile" type="wstring" dir="in">
4286 <desc>Path to the saved state file to adopt.</desc>
4287 </param>
4288 </method>
4289
4290 <method name="discardSavedState">
4291 <desc>
4292 Discards (deletes) the saved state of the virtual machine
4293 previously created by <link to="#saveState"/>. Next time the
4294 machine is powered up, a clean boot will occur.
4295 <note>
4296 This operation is equivalent to resetting or powering off
4297 the machine without doing a proper shutdown in the guest OS.
4298 </note>
4299 </desc>
4300 </method>
4301
4302 <method name="getDeviceActivity">
4303 <desc>
4304 Gets the current activity type of a given device or device group.
4305 </desc>
4306 <param name="type" type="DeviceType" dir="in"/>
4307 <param name="activity" type="DeviceActivity" dir="return"/>
4308 </method>
4309
4310 <method name="attachUSBDevice">
4311 <desc>
4312 Attaches a host USB device with the given UUID to the
4313 USB controller of the virtual machine.
4314
4315 The device needs to be in one of the following states:
4316 <link to="USBDeviceState::Busy">Busy</link>,
4317 <link to="USBDeviceState::Available">Available</link> or
4318 <link to="USBDeviceState::Held">Held</link>,
4319 otherwise an error is immediately returned.
4320
4321 When the device state is
4322 <link to="USBDeviceState::Busy">Busy</link>, an error may also
4323 be returned if the host computer refuses to release it for some reason.
4324
4325 <see>IUSBController::deviceFilters, USBDeviceState</see>
4326 </desc>
4327 <param name="id" type="uuid" dir="in">
4328 <desc>UUID of the host USB device to attach.</desc>
4329 </param>
4330 </method>
4331
4332 <method name="detachUSBDevice">
4333 <desc>
4334 Detaches an USB device with the given UUID from the USB controller
4335 oif the virtual machine.
4336
4337 After this method succeeds, the VirtualBox server reinitiates
4338 all USB filters as if the device were just physically attached
4339 to the host, but filters of this machine are ignored to avoid
4340 a possible automatic reattachment.
4341
4342 <see>IUSBController::deviceFilters, USBDeviceState</see>
4343 </desc>
4344 <param name="id" type="uuid" dir="in">
4345 <desc>UUID of the USB device to detach.</desc>
4346 </param>
4347 <param name="device" type="IUSBDevice" dir="return">
4348 <desc>Detached USB device.</desc>
4349 </param>
4350 </method>
4351
4352 <method name="createSharedFolder">
4353 <desc>
4354 Creates a transient new shared folder by associating the given logical
4355 name with the given host path, adds it to the collection of shared
4356 folders and starts sharing it. Refer to the description of
4357 <link to="ISharedFolder"/> to read more about logical names.
4358 </desc>
4359 <param name="name" type="wstring" dir="in">
4360 <desc>Unique logical name of the shared folder.</desc>
4361 </param>
4362 <param name="hostPath" type="wstring" dir="in">
4363 <desc>Full path to the shared folder in the host file system.</desc>
4364 </param>
4365 <param name="writable" type="boolean" dir="in">
4366 <desc>Whether the share is writable or readonly</desc>
4367 </param>
4368 </method>
4369
4370 <method name="removeSharedFolder">
4371 <desc>
4372 Removes a transient shared folder with the given name previously
4373 created by <link to="#createSharedFolder"/> from the collection of
4374 shared folders and stops sharing it.
4375 </desc>
4376 <param name="name" type="wstring" dir="in">
4377 <desc>Logical name of the shared folder to remove.</desc>
4378 </param>
4379 </method>
4380
4381 <method name="takeSnapshot">
4382 <desc>
4383 Saves the current execution state and all settings of the
4384 machine and creates differencing images for all
4385 normal (non-independent) hard disks.
4386
4387 This method can be called for a PoweredOff, Saved, Running or
4388 Paused virtual machine. When the machine is PoweredOff, an
4389 offline <link to="ISnapshot">snapshot</link> is created,
4390 in all other cases -- an online snapshot.
4391
4392 The taken snapshot is always based on the
4393 <link to="IMachine::currentSnapshot">current
4394 snapshot</link> of the associated virtual machine and becomes
4395 a new current snapshot.
4396
4397 <note>
4398 This method implicitly calls <link to="IMachine::saveSettings()"/> to
4399 save all current machine settings before taking an offline snapshot.
4400 </note>
4401
4402 <see>ISnapshot, <link to="#saveState"/></see>
4403 </desc>
4404 <param name="name" type="wstring" dir="in">
4405 <desc>Short name for the snapshot.</desc>
4406 </param>
4407 <param name="description" type="wstring" dir="in">
4408 <desc>Optional description of the snapshot.</desc>
4409 </param>
4410 <param name="progress" type="IProgress" dir="return">
4411 <desc>Progress object to track the operation completion.</desc>
4412 </param>
4413 </method>
4414
4415 <method name="discardSnapshot">
4416 <desc>
4417
4418 Starts discarding the specified snapshot. The execution state
4419 and settings of the associated machine stored in the snapshot
4420 will be deleted. The contents of all differencing hard disks of
4421 this snapshot will be merged with the contents of their
4422 dependent child hard disks to keep the, disks valid (in other
4423 words, all changes represented by hard disks being discarded
4424 will be propagated to their child hard disks). After that, this
4425 snapshot's differencing hard disks will be deleted. The parent
4426 of this snapshot will become a new parent for all its child
4427 snapshots.
4428
4429 If the discarded snapshot is the current one, its parent
4430 snapshot will become a new current snapshot. The current machine
4431 state is not directly affected in this case, except that
4432 currently attached differencing hard disks based on hard disks
4433 of the discarded snapshot will be also merged as described
4434 above.
4435
4436 If the discarded snapshot is the first one (the root snapshot)
4437 and it has exactly one child snapshot, this child snapshot will
4438 become the first snapshot after discarding. If there are no
4439 children at all (i.e. the first snapshot is the only snapshot of
4440 the machine), both the current and the first snapshot of the
4441 machine will be set to null. In all other cases, the first
4442 snapshot cannot be discarded.
4443
4444 You cannot discard the snapshot if it
4445 stores <link to="HardDiskType::Normal">normal</link> (non-differencing)
4446 hard disks that have differencing hard disks based on them. Snapshots of
4447 such kind can be discarded only when every normal hard disk has either
4448 no children at all or exactly one child. In the former case, the normal
4449 hard disk simply becomes unused (i.e. not attached to any VM). In the
4450 latter case, it receives all the changes strored in the child hard disk,
4451 and then it replaces the child hard disk in the configuration of the
4452 corresponding snapshot or machine.
4453
4454 Also, you cannot discard the snapshot if it stores hard disks
4455 (of any type) having differencing child hard disks that belong
4456 to other machines. Such snapshots can be only discarded after
4457 you discard all snapshots of other machines containing "foreign"
4458 child disks, or detach these "foreign" child disks from machines
4459 they are attached to.
4460
4461 One particular example of the snapshot storing normal hard disks
4462 is the first snapshot of a virtual machine that had normal hard
4463 disks attached when taking the snapshot. Be careful when
4464 discarding such snapshots because this implicitly commits
4465 changes (made since the snapshot being discarded has been taken)
4466 to normal hard disks (as described above), which may be not what
4467 you want.
4468
4469 The virtual machine is put to
4470 the <link to="MachineState::Discarding">Discarding</link> state until
4471 the discard operation is completed.
4472
4473 <note>
4474 The machine must not be running, otherwise the operation
4475 will fail.
4476 </note>
4477
4478 <note>
4479 Child hard disks of all normal hard disks of the discarded snapshot
4480 must be <link to="IHardDisk::accessible">accessible</link> for this
4481 operation to succeed. In particular, this means that all virtual
4482 machines, whose hard disks are directly or indirectly based on the
4483 hard disks of discarded snapshot, must be powered off.
4484 </note>
4485 <note>
4486 Merging hard disk contents can be very time and disk space
4487 consuming, if these disks are big in size and have many
4488 children. However, if the snapshot being discarded is the last
4489 (head) snapshot on the branch, the operation will be rather
4490 quick.
4491 </note>
4492 <note>
4493 Note that discarding the current snapshot
4494 will imlicitly call <link to="IMachine::saveSettings()"/> to
4495 make all current machine settings permanent.
4496 </note>
4497 </desc>
4498 <param name="id" type="uuid" dir="in">
4499 <desc>UUID of the snapshot to discard.</desc>
4500 </param>
4501 <param name="progress" type="IProgress" dir="return">
4502 <desc>Progress object to track the operation completion.</desc>
4503 </param>
4504 </method>
4505
4506 <method name="discardCurrentState">
4507 <desc>
4508 This operation is similar to <link to="#discardSnapshot()"/> but
4509 affects the current machine state. This means that the state stored in
4510 the current snapshot will become a new current state, and all current
4511 settings of the machine and changes stored in differencing hard disks
4512 will be lost.
4513
4514 After this operation is successfully completed, new empty differencing
4515 hard disks are created for all normal hard disks of the machine.
4516
4517 If the current snapshot of the machine is an online snapshot, the
4518 machine will go to the <link to="MachineState::Saved"> saved
4519 state</link>, so that the next time it is powered on, the execution
4520 state will be restored from the current snapshot.
4521
4522 <note>
4523 The machine must not be running, otherwise the operation will fail.
4524 </note>
4525
4526 <note>
4527 If the machine state is <link to="MachineState::Saved">Saved</link>
4528 prior to this operation, the saved state file will be implicitly
4529 discarded (as if <link to="IConsole::discardSavedState()"/> were
4530 called).
4531 </note>
4532
4533 </desc>
4534 <param name="progress" type="IProgress" dir="return">
4535 <desc>Progress object to track the operation completion.</desc>
4536 </param>
4537 </method>
4538
4539 <method name="discardCurrentSnapshotAndState">
4540 <desc>
4541
4542 This method is equivalent to
4543 doing <link to="#discardSnapshot">discardSnapshot</link>
4544 (<link
4545 to="IMachine::currentSnapshot">currentSnapshot</link>.<link
4546 to="ISnapshot::id">id()</link>, ...) followed by
4547 <link to="#discardCurrentState()"/>.
4548
4549 As a result, the machine will be fully restored from the
4550 snapshot preceeding the current snapshot, while both the current
4551 snapshot and the current machine state will be discarded.
4552
4553 If the current snapshot is the first snapshot of the machine (i.e. it
4554 has the only snapshot), the current machine state will be
4555 discarded <b>before</b> discarding the snapshot. In other words, the
4556 machine will be restored from its last snapshot, before discarding
4557 it. This differs from performing a single
4558 <link to="#discardSnapshot()"/> call (note that no
4559 <link to="#discardCurrentState()"/> will be possible after it) to the
4560 effect that the latter will preserve the current state instead of
4561 discarding it.
4562
4563 Unless explicitly mentioned otherwise, all remarks and
4564 limitations of the above two methods also apply to this method.
4565
4566 <note>
4567 The machine must not be running, otherwise the operation
4568 will fail.
4569 </note>
4570
4571 <note>
4572 If the machine state is <link to="MachineState::Saved">Saved</link>
4573 prior to this operation, the saved state file will be implicitly
4574 discarded (as if <link to="IConsole::discardSavedState()"/> were
4575 called).</note>
4576
4577 <note>
4578 This method is more efficient than calling two above
4579 methods separately: it requires less IPC calls and provides
4580 a single progress object.
4581 </note>
4582
4583 </desc>
4584 <param name="progress" type="IProgress" dir="return">
4585 <desc>Progress object to track the operation completion.</desc>
4586 </param>
4587 </method>
4588
4589 <method name="registerCallback">
4590 <desc>
4591 Registers a new console callback on this instance. The methods of the
4592 callback interface will be called by this instance when the appropriate
4593 event occurs.
4594 </desc>
4595 <param name="callback" type="IConsoleCallback" dir="in"/>
4596 </method>
4597
4598 <method name="unregisterCallback">
4599 <desc>
4600 Unregisters the console callback previously registered using
4601 <link to="#registerCallback"/>.
4602 </desc>
4603 <param name="callback" type="IConsoleCallback" dir="in"/>
4604 </method>
4605 </interface>
4606
4607 <!--
4608 // IHost
4609 /////////////////////////////////////////////////////////////////////////
4610 -->
4611
4612 <interface
4613 name="IHostDVDDrive" extends="$unknown"
4614 uuid="21f86694-202d-4ce4-8b05-a63ff82dbf4c"
4615 wsmap="managed"
4616 >
4617 <desc>
4618 The IHostDVDDrive interface represents the physical CD/DVD drive
4619 hardware on the host. Used indirectly in <link to="IHost::DVDDrives"/>.
4620 </desc>
4621
4622 <attribute name="name" type="wstring" readonly="yes">
4623 <desc>
4624 Returns the platform-specific device identifier.
4625 On DOS-like platforms, it is a drive name (e.g. R:).
4626 On Unix-like platforms, it is a device name (e.g. /dev/hdc).
4627 </desc>
4628 </attribute>
4629 <attribute name="description" type="wstring" readonly="yes">
4630 <desc>
4631 Returns a human readable description for the drive. This
4632 description usually contains the product and vendor name. A
4633 @c null string is returned if the description is not available.
4634 </desc>
4635 </attribute>
4636 <attribute name="udi" type="wstring" readonly="yes">
4637 <desc>
4638 Returns the unique device identifier for the drive. This
4639 attribute is reserved for future use instead of
4640 <link to="#name"/>. Currently it is not used and may return
4641 @c null on some platforms.
4642 </desc>
4643 </attribute>
4644
4645 </interface>
4646
4647 <enumerator
4648 name="IHostDVDDriveEnumerator" type="IHostDVDDrive"
4649 uuid="1ed7cfaf-c363-40df-aa4e-89c1afb7d96b"
4650 />
4651
4652 <collection
4653 name="IHostDVDDriveCollection" type="IHostDVDDrive"
4654 enumerator="IHostDVDDriveEnumerator"
4655 uuid="1909c533-1a1e-445f-a4e1-a267cffc30ed"
4656 readonly="yes"
4657 >
4658 <method name="findByName">
4659 <desc>
4660 Searches this collection for a host drive with the given name.
4661 <note>
4662 The method returns an error if the given name does not
4663 correspond to any host drive in the collection.
4664 </note>
4665 </desc>
4666 <param name="name" type="wstring" dir="in">
4667 <desc>Name of the host drive to search for</desc>
4668 </param>
4669 <param name="drive" type="IHostDVDDrive" dir="return">
4670 <desc>Found host drive object</desc>
4671 </param>
4672 </method>
4673 </collection>
4674
4675 <interface
4676 name="IHostFloppyDrive" extends="$unknown"
4677 uuid="b6a4d1a9-4221-43c3-bd52-021a5daa9ed2"
4678 wsmap="managed"
4679 >
4680 <desc>
4681 The IHostFloppyDrive interface represents the physical floppy drive
4682 hardware on the host. Used indirectly in <link to="IHost::floppyDrives"/>.
4683 </desc>
4684 <attribute name="name" type="wstring" readonly="yes">
4685 <desc>
4686 Returns the platform-specific device identifier.
4687 On DOS-like platforms, it is a drive name (e.g. A:).
4688 On Unix-like platforms, it is a device name (e.g. /dev/fd0).
4689 </desc>
4690 </attribute>
4691 <attribute name="description" type="wstring" readonly="yes">
4692 <desc>
4693 Returns a human readable description for the drive. This
4694 description usually contains the product and vendor name. A
4695 @c null string is returned if the description is not available.
4696 </desc>
4697 </attribute>
4698 <attribute name="udi" type="wstring" readonly="yes">
4699 <desc>
4700 Returns the unique device identifier for the drive. This
4701 attribute is reserved for future use instead of
4702 <link to="#name"/>. Currently it is not used and may return
4703 @c null on some platforms.
4704 </desc>
4705 </attribute>
4706 </interface>
4707
4708 <enumerator
4709 name="IHostFloppyDriveEnumerator" type="IHostFloppyDrive"
4710 uuid="ce04c924-4f54-432a-9dec-11fddc3ea875"
4711 />
4712
4713 <collection
4714 name="IHostFloppyDriveCollection" type="IHostFloppyDrive"
4715 enumerator="IHostFloppyDriveEnumerator"
4716 uuid="fd84bb86-c59a-4037-a557-755ff263a460"
4717 readonly="yes"
4718 >
4719 <method name="findByName">
4720 <desc>
4721 Searches this collection for a host drive with the given name.
4722 <note>
4723 The method returns an error if the given name does not
4724 correspond to any host drive in the collection.
4725 </note>
4726 </desc>
4727 <param name="name" type="wstring" dir="in">
4728 <desc>Name of the host drive to search for</desc>
4729 </param>
4730 <param name="drive" type="IHostFloppyDrive" dir="return">
4731 <desc>Found host drive object</desc>
4732 </param>
4733 </method>
4734 </collection>
4735
4736<if target="midl">
4737 <interface
4738 name="IHostNetworkInterface" extends="$unknown"
4739 uuid="F4512D7C-B074-4e97-99B8-6D2BD27C3F5A"
4740 wsmap="managed"
4741 >
4742 <attribute name="name" type="wstring" readonly="yes">
4743 <desc>Returns the host network interface name.</desc>
4744 </attribute>
4745
4746 <attribute name="id" type="uuid" readonly="yes">
4747 <desc>Returns the interface UUID.</desc>
4748 </attribute>
4749 </interface>
4750
4751 <enumerator
4752 name="IHostNetworkInterfaceEnumerator" type="IHostNetworkInterface"
4753 uuid="7B52FEF7-56E8-4aec-92F5-15E6D11EC630"
4754 />
4755
4756 <collection
4757 name="IHostNetworkInterfaceCollection" type="IHostNetworkInterface"
4758 enumerator="IHostNetworkInterfaceEnumerator"
4759 uuid="BF1D41F2-B97B-4314-A0FB-D4823AF42FB5"
4760 readonly="yes"
4761 >
4762 <method name="findByName">
4763 <desc>
4764 Searches this collection for a host network interface with the given name.
4765 <note>
4766 The method returns an error if the given name does not
4767 correspond to any host network interface in the collection.
4768 </note>
4769 </desc>
4770 <param name="name" type="wstring" dir="in">
4771 <desc>Name of the host network interface to search for.</desc>
4772 </param>
4773 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
4774 <desc>Found host network interface object.</desc>
4775 </param>
4776 </method>
4777 <method name="findById">
4778 <desc>
4779 Searches this collection for a host network interface with the given GUID.
4780 <note>
4781 The method returns an error if the given GUID does not
4782 correspond to any host network interface in the collection.
4783 </note>
4784 </desc>
4785 <param name="id" type="uuid" dir="in">
4786 <desc>GUID of the host network interface to search for.</desc>
4787 </param>
4788 <param name="networkInterface" type="IHostNetworkInterface" dir="return">
4789 <desc>Found host network interface object.</desc>
4790 </param>
4791 </method>
4792 </collection>
4793</if>
4794
4795 <interface
4796 name="IHost" extends="$unknown"
4797 uuid="a42a480f-d554-4be0-b11c-6c2e54dd1274"
4798 wsmap="managed"
4799 >
4800 <desc>
4801 The IHost interface represents the physical machine that this VirtualBox
4802 installation runs on.
4803
4804 An object implementing this interface is returned by the
4805 <link to="IVirtualBox::host" /> attribute. This interface contains
4806 read-only information about the host's physical hardware (such as what
4807 processors, and disks are available, what the host operating system is,
4808 and so on) and also allows for manipulating some of the host's hardware,
4809 such as global USB device filters and host interface networking.
4810
4811 </desc>
4812 <attribute name="DVDDrives" type="IHostDVDDriveCollection" readonly="yes">
4813 <desc>List of DVD drives available on the host.</desc>
4814 </attribute>
4815
4816 <attribute name="floppyDrives" type="IHostFloppyDriveCollection" readonly="yes">
4817 <desc>List of floppy drives available on the host.</desc>
4818 </attribute>
4819
4820 <attribute name="USBDevices" type="IHostUSBDeviceCollection" readonly="yes">
4821 <desc>
4822 List of USB devices currently attached to the host.
4823 Once a new device is physically attached to the host computer,
4824 it appears in this list and remains there until detached.
4825
4826 <note>
4827 This method may set a @ref com_warnings "warning result code".
4828 </note>
4829 <note>
4830 If USB functionality is not avaliable in the given edition of
4831 VirtualBox, this method will set the result code to @c E_NOTIMPL.
4832 </note>
4833 </desc>
4834 </attribute>
4835
4836 <attribute name="USBDeviceFilters" type="IHostUSBDeviceFilterCollection" readonly="yes">
4837 <desc>
4838 List of USB device filters in action.
4839 When a new device is physically attached to the host computer,
4840 filters from this list are applied to it (in order they are stored
4841 in the list). The first matched filter will determine the
4842 <link to="IHostUSBDeviceFilter::action">action</link>
4843 performed on the device.
4844
4845 Unless the device is ignored by these filters, filters of all
4846 currently running virtual machines
4847 (<link to="IUSBController::deviceFilters"/>) are applied to it.
4848
4849 <note>
4850 This method may set a @ref com_warnings "warning result code".
4851 </note>
4852 <note>
4853 If USB functionality is not avaliable in the given edition of
4854 VirtualBox, this method will set the result code to @c E_NOTIMPL.
4855 </note>
4856
4857 <see>IHostUSBDeviceFilter, USBDeviceState</see>
4858 </desc>
4859 </attribute>
4860
4861<if target="midl">
4862 <attribute name="networkInterfaces" type="IHostNetworkInterfaceCollection" readonly="yes">
4863 <desc>List of host network interfaces currently defined on the host.</desc>
4864 </attribute>
4865</if>
4866
4867 <attribute name="processorCount" type="unsigned long" readonly="yes">
4868 <desc>Number of (logical) CPUs installed in the host system.</desc>
4869 </attribute>
4870
4871 <attribute name="processorSpeed" type="unsigned long" readonly="yes">
4872 <desc>(Approximate) speed of the host CPU in Megahertz.</desc>
4873 </attribute>
4874
4875 <attribute name="processorDescription" type="wstring" readonly="yes">
4876 <desc>Description string of the host CPU.</desc>
4877 </attribute>
4878
4879 <attribute name="memorySize" type="unsigned long" readonly="yes">
4880 <desc>Amount of system memory in megabytes installed in the host system.</desc>
4881 </attribute>
4882
4883 <attribute name="memoryAvailable" type="unsigned long" readonly="yes">
4884 <desc>Available system memory in the host system.</desc>
4885 </attribute>
4886
4887 <attribute name="operatingSystem" type="wstring" readonly="yes">
4888 <desc>Name of the host system's operating system.</desc>
4889 </attribute>
4890
4891 <attribute name="OSVersion" type="wstring" readonly="yes">
4892 <desc>Host operating system's version string.</desc>
4893 </attribute>
4894
4895 <attribute name="UTCTime" type="long long" readonly="yes">
4896 <desc>Returns the current host time in milliseconds since 1970-01-01 UTC.</desc>
4897 </attribute>
4898
4899<if target="midl">
4900 <method name="createHostNetworkInterface">
4901 <desc>
4902 Creates a new adapter for Host Interface Networking.
4903 </desc>
4904 <param name="name" type="wstring" dir="in">
4905 <desc>
4906 Adapter name.
4907 </desc>
4908 </param>
4909 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
4910 <desc>
4911 Created host interface object.
4912 </desc>
4913 </param>
4914 <param name="progress" type="IProgress" dir="return">
4915 <desc>
4916 Progress object to track the operation completion.
4917 </desc>
4918 </param>
4919 </method>
4920 <method name="removeHostNetworkInterface">
4921 <desc>
4922 Removes the given host network interface.
4923 </desc>
4924 <param name="id" type="uuid" dir="in">
4925 <desc>
4926 Adapter GUID.
4927 </desc>
4928 </param>
4929 <param name="hostInterface" type="IHostNetworkInterface" dir="out">
4930 <desc>
4931 Removed host interface object.
4932 </desc>
4933 </param>
4934 <param name="progress" type="IProgress" dir="return">
4935 <desc>
4936 Progress object to track the operation completion.
4937 </desc>
4938 </param>
4939 </method>
4940</if>
4941
4942 <method name="createUSBDeviceFilter">
4943 <desc>
4944 Creates a new USB device filter. All attributes except
4945 the filter name are set to <tt>null</tt> (any match),
4946 <i>active</i> is <tt>false</tt> (the filter is not active).
4947
4948 The created filter can be added to the list of filters using
4949 <link to="#insertUSBDeviceFilter()"/>.
4950
4951 <see>#USBDeviceFilters</see>
4952 </desc>
4953 <param name="name" type="wstring" dir="in">
4954 <desc>
4955 Filter name. See <link to="IHostUSBDeviceFilter::name"/>
4956 for more info.
4957 </desc>
4958 </param>
4959 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
4960 <desc>Created filter object.</desc>
4961 </param>
4962 </method>
4963
4964 <method name="insertUSBDeviceFilter">
4965 <desc>
4966 Inserts the given USB device to the specified position
4967 in the list of filters.
4968
4969 Positions are numbered starting from <tt>0</tt>. If the specified
4970 position is equal to or greater than the number of elements in
4971 the list, the filter is added to the end of the collection.
4972
4973 <note>
4974 Duplicates are not allowed, so an attempt to insert a
4975 filter that is already in the list, will return an
4976 error.
4977 </note>
4978 <note>
4979 This method may set a @ref com_warnings "warning result code".
4980 </note>
4981 <note>
4982 If USB functionality is not avaliable in the given edition of
4983 VirtualBox, this method will set the result code to @c E_NOTIMPL.
4984 </note>
4985
4986 <see>#USBDeviceFilters</see>
4987 </desc>
4988 <param name="position" type="unsigned long" dir="in">
4989 <desc>Position to insert the filter to.</desc>
4990 </param>
4991 <param name="filter" type="IHostUSBDeviceFilter" dir="in">
4992 <desc>USB device filter to insert.</desc>
4993 </param>
4994 </method>
4995
4996 <method name="removeUSBDeviceFilter">
4997 <desc>
4998 Removes a USB device filter from the specified position in the
4999 list of filters.
5000
5001 Positions are numbered starting from <tt>0</tt>. Specifying a
5002 position equal to or greater than the number of elements in
5003 the list will produce an error.
5004
5005 <note>
5006 This method may set a @ref com_warnings "warning result code".
5007 </note>
5008 <note>
5009 If USB functionality is not avaliable in the given edition of
5010 VirtualBox, this method will set the result code to @c E_NOTIMPL.
5011 </note>
5012
5013 <see>#USBDeviceFilters</see>
5014 </desc>
5015 <param name="position" type="unsigned long" dir="in">
5016 <desc>Position to remove the filter from.</desc>
5017 </param>
5018 <param name="filter" type="IHostUSBDeviceFilter" dir="return">
5019 <desc>Removed USB device filter.</desc>
5020 </param>
5021 </method>
5022
5023 <method name="getProcessorUsage">
5024 <desc>
5025 Returns the processor usage by the whole host system measured over all
5026 cores of all processors of the host machine.
5027
5028 The values returned for each parameter are in range from <tt>0</tt> (the
5029 machine is powered off or doesn't load the CPUs at all) to
5030 <tt>1 000 000 000</tt> (all cores of all CPUs are fully loaded by this
5031 machine).
5032
5033 <note>
5034 The maximum value is 1000000000 which means that all cores of all CPUs
5035 are completely used.
5036 </note>
5037 </desc>
5038 <param name="user" type="unsigned long" dir="out">
5039 <desc>
5040 Pecentage of processor time spent executing in user mode.
5041 </desc>
5042 </param>
5043 <param name="system" type="unsigned long" dir="out">
5044 <desc>
5045 Pecentage of processor time spent executing in kernel mode.
5046 </desc>
5047 </param>
5048 <param name="idle" type="unsigned long" dir="out">
5049 <desc>
5050 Pecentage of processor time spent doing nothing.
5051 </desc>
5052 </param>
5053 </method>
5054 </interface>
5055
5056 <!--
5057 // ISystemProperties
5058 /////////////////////////////////////////////////////////////////////////
5059 -->
5060
5061 <interface
5062 name="ISystemProperties"
5063 extends="$unknown"
5064 uuid="12c2e31e-247f-4d51-82e5-5b9d4a6c7d5b"
5065 wsmap="managed"
5066 >
5067 <desc>
5068 The ISystemProperties interface represents global properties
5069 of the given VirtualBox installation.
5070
5071 These properties define limits and default values for various
5072 attributes and parameters. Most of the properties are read-only, but some can be
5073 changed by a user.
5074 </desc>
5075
5076 <attribute name="minGuestRAM" type="unsigned long" readonly="yes">
5077 <desc>Minium guest system memory in Megabytes.</desc>
5078 </attribute>
5079
5080 <attribute name="maxGuestRAM" type="unsigned long" readonly="yes">
5081 <desc>Maximum guest system memory in Megabytes.</desc>
5082 </attribute>
5083
5084 <attribute name="minGuestVRAM" type="unsigned long" readonly="yes">
5085 <desc>Minimum guest video memory in Megabytes.</desc>
5086 </attribute>
5087
5088 <attribute name="maxGuestVRAM" type="unsigned long" readonly="yes">
5089 <desc>Maximum guest video memory in Megabytes.</desc>
5090 </attribute>
5091
5092 <attribute name="maxVDISize" type="unsigned long long" readonly="yes">
5093 <desc>Maximum size of a virtual disk image in Megabytes.</desc>
5094 </attribute>
5095
5096 <attribute name="networkAdapterCount" type="unsigned long" readonly="yes">
5097 <desc>
5098 Number of network adapters associated with every
5099 <link to="IMachine"/> instance.
5100 </desc>
5101 </attribute>
5102
5103 <attribute name="serialPortCount" type="unsigned long" readonly="yes">
5104 <desc>
5105 Number of serial ports associated with every
5106 <link to="IMachine"/> instance.
5107 </desc>
5108 </attribute>
5109
5110 <attribute name="parallelPortCount" type="unsigned long" readonly="yes">
5111 <desc>
5112 Number of parallel ports associated with every
5113 <link to="IMachine"/> instance.
5114 </desc>
5115 </attribute>
5116
5117 <attribute name="maxBootPosition" type="unsigned long" readonly="yes">
5118 <desc>
5119 Maximum device position in the boot order. This value corresponds
5120 to the total number of devices a machine can boot from, to make it
5121 possible to include all possible devices to the boot list.
5122 <see><link to="IMachine::setBootOrder()"/></see>
5123 </desc>
5124 </attribute>
5125
5126 <attribute name="defaultVDIFolder" type="wstring">
5127 <desc>
5128 Full path to the default directory used to create new or open
5129 existing virtual disk images when an image file name contains no
5130 path.
5131
5132 The initial value of this property is
5133 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
5134 VirtualBox_home</link><tt>&gt;/VDI</tt>.
5135
5136 <note>
5137 Setting this property to <tt>null</tt> will restore the
5138 initial value.
5139 </note>
5140 <note>
5141 When settings this property, the specified path can be
5142 absolute (full path) or relative
5143 to the <link to="IVirtualBox::homeFolder">
5144 VirtualBox home directory</link>.
5145 When reading this property, a full path is
5146 always returned.
5147 </note>
5148 <note>
5149 The specified path may not exist, it will be created
5150 when necessary.
5151 </note>
5152
5153 <see>
5154 <link to="IVirtualBox::createHardDisk()"/>,
5155 <link to="IVirtualBox::openVirtualDiskImage()"/>
5156 </see>
5157 </desc>
5158 </attribute>
5159
5160 <attribute name="defaultMachineFolder" type="wstring">
5161 <desc>
5162 Full path to the default directory used to create new or open
5163 existing machines when a settings file name contains no
5164 path.
5165
5166 The initial value of this property is
5167 <tt>&lt;</tt><link to="IVirtualBox::homeFolder">
5168 VirtualBox_home</link><tt>&gt;/Machines</tt>.
5169
5170 <note>
5171 Setting this property to <tt>null</tt> will restore the
5172 initial value.
5173 </note>
5174 <note>
5175 When settings this property, the specified path can be
5176 absolute (full path) or relative
5177 to the <link to="IVirtualBox::homeFolder">
5178 VirtualBox home directory</link>.
5179 When reading this property, a full path is
5180 always returned.
5181 </note>
5182 <note>
5183 The specified path may not exist, it will be created
5184 when necessary.
5185 </note>
5186
5187 <see>
5188 <link to="IVirtualBox::createMachine()"/>,
5189 <link to="IVirtualBox::openMachine()"/>
5190 </see>
5191 </desc>
5192 </attribute>
5193
5194 <attribute name="remoteDisplayAuthLibrary" type="wstring">
5195 <desc>
5196 Library that provides authentication for VRDP clients. The library
5197 is used if a virtual machine's authentication type is set to "external"
5198 in the VM RemoteDisplay configuration.
5199
5200 The system library extension (".DLL" or ".so") must be omitted.
5201 A full path can be specified; if not, then the library must reside on the
5202 system's default library path.
5203
5204 The default value of this property is <tt>VRDPAuth</tt>. There is a library
5205 of that name in one of the default VirtualBox library directories.
5206
5207 For details about VirtualBox authentication libraries and how to implement
5208 them, please refer to the VirtualBox manual.
5209
5210 <note>
5211 Setting this property to <tt>null</tt> will restore the
5212 initial value.
5213 </note>
5214 </desc>
5215 </attribute>
5216
5217 <attribute name="webServiceAuthLibrary" type="wstring">
5218 <desc>
5219 Library that provides authentication for webservice clients. The library
5220 is used if a virtual machine's authentication type is set to "external"
5221 in the VM RemoteDisplay configuration and will be called from
5222 within the <link to="IWebsessionManager::logon" /> implementation.
5223
5224 As opposed to <link to="ISystemProperties::remoteDisplayAuthLibrary" />,
5225 there is no per-VM setting for this, as the webservice is a global
5226 resource (if it is running). Only for this setting (for the webservice),
5227 setting this value to a literal "null" string disables authentication,
5228 meaning that <link to="IWebsessionManager::logon" /> will always succeed,
5229 no matter what user name and password are supplied.
5230
5231 The initial value of this property is <tt>VRDPAuth</tt>,
5232 meaning that the webservice will use the same authentication
5233 library that is used by default for VBoxVRDP (again, see
5234 <link to="ISystemProperties::remoteDisplayAuthLibrary" />).
5235 The format and calling convetion of authentication libraries
5236 is the same for the webservice as it is for VBoxVRDP.
5237
5238 </desc>
5239 </attribute>
5240
5241 <attribute name="HWVirtExEnabled" type="boolean">
5242 <desc>
5243 This specifies the default value for hardware virtualization
5244 extensions. If enabled, virtual machines will make use of
5245 hardware virtualization extensions such as Intel VT-x and
5246 AMD-V by default. This value can be overridden by each VM
5247 using their <link to="IMachine::HWVirtExEnabled" /> property.
5248 </desc>
5249 </attribute>
5250
5251 <attribute name="LogHistoryCount" type="unsigned long">
5252 <desc>
5253 This value specifies how many old release log files are kept.
5254 </desc>
5255 </attribute>
5256 </interface>
5257
5258 <!--
5259 // IGuest
5260 /////////////////////////////////////////////////////////////////////////
5261 -->
5262
5263 <interface
5264 name="IGuestOSType" extends="$unknown"
5265 uuid="da94f478-1f37-4726-b750-2235950dc2fe"
5266 wsmap="struct"
5267 >
5268 <desc>
5269 <note>With the COM API, this is an interface like all the others. With the webservice,
5270 this is mapped to a structure, so querying the attribute will not return an object,
5271 but a complete structure.</note>
5272 </desc>
5273
5274 <attribute name="id" type="wstring" readonly="yes">
5275 <desc>Guest OS identifier string.</desc>
5276 </attribute>
5277
5278 <attribute name="description" type="wstring" readonly="yes">
5279 <desc>Human readable description of the guest OS.</desc>
5280 </attribute>
5281
5282 <attribute name="recommendedRAM" type="unsigned long" readonly="yes">
5283 <desc>Recommended RAM size in Megabytes.</desc>
5284 </attribute>
5285
5286 <attribute name="recommendedVRAM" type="unsigned long" readonly="yes">
5287 <desc>Recommended video RAM size in Megabytes.</desc>
5288 </attribute>
5289
5290 <attribute name="recommendedHDD" type="unsigned long" readonly="yes">
5291 <desc>Recommended hard disk size in Megabytes.</desc>
5292 </attribute>
5293 </interface>
5294
5295
5296 <enumerator
5297 name="IGuestOSTypeEnumerator" type="IGuestOSType"
5298 uuid="a3335e02-4669-4e3c-80c7-c4dc7056a07c"
5299 />
5300
5301 <collection
5302 name="IGuestOSTypeCollection" type="IGuestOSType" enumerator="IGuestOSTypeEnumerator"
5303 uuid="a5e36749-a610-498b-9f29-2e36c1042d65"
5304 readonly="yes"
5305 />
5306
5307 <interface
5308 name="IGuest" extends="$unknown"
5309 uuid="d8556fca-81bc-12af-fca3-365528fa38ca"
5310
5311 wsmap="suppress"
5312 >
5313 <desc>
5314 The IGuest interface represents information about the operating system
5315 running inside the virtual machine. Used in
5316 <link to="IConsole::guest"/>.
5317
5318 IGuest provides information about the guest operating system, whether
5319 Guest Additions are installed and other OS-specific virtual machine
5320 properties.
5321 </desc>
5322
5323 <attribute name="OSTypeId" type="wstring" readonly="yes">
5324 <desc>
5325 Identifier of the Guest OS type as reported by the Guest
5326 Additions.
5327 You may use <link to="IVirtualBox::getGuestOSType"/> to obtain
5328 an IGuestOSType object representing details about the given
5329 Guest OS type.
5330 <note>
5331 If Guest Additions are not installed, this value will be
5332 the same as <link to="IMachine::OSTypeId"/>.
5333 </note>
5334 </desc>
5335 </attribute>
5336
5337 <attribute name="additionsActive" type="boolean" readonly="yes">
5338 <desc>
5339 Flag whether the Guest Additions are installed and active
5340 in which case their version will be returned by the
5341 <link to="#additionsVersion"/> property.
5342 </desc>
5343 </attribute>
5344
5345 <attribute name="additionsVersion" type="wstring" readonly="yes">
5346 <desc>
5347 Version of the Guest Additions (3 decimal numbers separated
5348 by dots) or empty when the Additions are not installed. The
5349 Additions may also report a version but yet not be active as
5350 the version might be refused by VirtualBox (incompatible) or
5351 other failures occured.
5352 </desc>
5353 </attribute>
5354
5355 <attribute name="supportsSeamless" type="boolean" readonly="yes">
5356 <desc>
5357 Flag whether seamless guest display rendering (seamless desktop
5358 integration) is supported.
5359 </desc>
5360 </attribute>
5361
5362 <attribute name="supportsGraphics" type="boolean" readonly="yes">
5363 <desc>
5364 Flag whether the guest is in graphics mode. If it is not, then
5365 seamless rendering will not work, resize hints are not immediately
5366 acted on and guest display resizes are probably not initiated by
5367 the guest additions.
5368 </desc>
5369 </attribute>
5370
5371 <attribute name="memoryBalloonSize" type="unsigned long">
5372 <desc>Guest system memory balloon size in megabytes.</desc>
5373 </attribute>
5374
5375 <attribute name="statisticsUpdateInterval" type="unsigned long">
5376 <desc>Interval to update guest statistics in seconds.</desc>
5377 </attribute>
5378
5379 <method name="setCredentials">
5380 <desc>
5381 Store login credentials that can be queried by guest operating
5382 systems with Additions installed. The credentials are transient
5383 to the session and the guest may also choose to erase them. Note
5384 that the caller cannot determine whether the guest operating system
5385 has queried or made use of the credentials.
5386 </desc>
5387 <param name="userName" type="wstring" dir="in">
5388 <desc>User name string, can be empty</desc>
5389 </param>
5390 <param name="password" type="wstring" dir="in">
5391 <desc>Password string, can be empty</desc>
5392 </param>
5393 <param name="domain" type="wstring" dir="in">
5394 <desc>Domain name (guest logon scheme specific), can be emtpy</desc>
5395 </param>
5396 <param name="allowInteractiveLogon" type="boolean" dir="in">
5397 <desc>
5398 Flag whether the guest should alternatively allow the user to
5399 interactively specify different credentials. This flag might
5400 not be supported by all versions of the Additions.
5401 </desc>
5402 </param>
5403 </method>
5404
5405 <method name="getStatistic">
5406 <desc>
5407 Query specified guest statistics as reported by the VirtualBox Additions.
5408 </desc>
5409 <param name="cpuId" type="unsigned long" dir="in">
5410 <desc>Virtual CPU id; not relevant for all statistic types</desc>
5411 </param>
5412 <param name="statistic" type="GuestStatisticType" dir="in">
5413 <desc>Statistic type.</desc>
5414 </param>
5415 <param name="statVal" type="unsigned long" dir="out">
5416 <desc>Statistics value</desc>
5417 </param>
5418 </method>
5419
5420 </interface>
5421
5422
5423 <!--
5424 // IProgress
5425 /////////////////////////////////////////////////////////////////////////
5426 -->
5427
5428 <enumerator
5429 name="IProgressEnumerator" type="IProgress"
5430 uuid="e0380522-4ef1-48f4-856c-e455177ccb2d"
5431 />
5432
5433 <collection
5434 name="IProgressCollection" type="IProgress" enumerator="IProgressEnumerator"
5435 uuid="78B76A7C-F0F2-467c-9F0E-F089A54EE957"
5436 readonly="yes"
5437 />
5438
5439 <interface
5440 name="IProgress" extends="$unknown"
5441 uuid="10CC03A1-717E-429b-992D-C67B56175A51"
5442 wsmap="managed"
5443 >
5444 <desc>
5445 The IProgress interface represents a task progress object that allows
5446 to wait for the completion of some asynchronous task.
5447
5448 The task consists of one or more operations that run sequentially,
5449 one after one. There is an individual percent of completion of the
5450 current operation and the percent of completion of the task as a
5451 whole. Similarly, you can wait for the completion of a particular
5452 operation or for the completion of the whole task.
5453
5454 Every operation is identified by a number (starting from 0)
5455 and has a separate description.
5456 </desc>
5457
5458 <attribute name="id" type="uuid" readonly="yes">
5459 <desc>ID of the task.</desc>
5460 </attribute>
5461
5462 <attribute name="description" type="wstring" readonly="yes">
5463 <desc>Description of the task.</desc>
5464 </attribute>
5465
5466 <attribute name="initiator" type="$unknown" readonly="yes">
5467 <desc>Initiator of the task.</desc>
5468 </attribute>
5469
5470 <attribute name="cancelable" type="boolean" readonly="yes">
5471 <desc>Whether the task can be interrupted.</desc>
5472 </attribute>
5473
5474 <attribute name="percent" type="long" readonly="yes">
5475 <desc>
5476 Current task progress value in percent.
5477 This value depends on how many operations are already complete.
5478 </desc>
5479 </attribute>
5480
5481 <attribute name="completed" type="boolean" readonly="yes">
5482 <desc>Whether the task has been completed.</desc>
5483 </attribute>
5484
5485 <attribute name="canceled" type="boolean" readonly="yes">
5486 <desc>Whether the task has been canceled.</desc>
5487 </attribute>
5488
5489 <attribute name="resultCode" type="result" readonly="yes">
5490 <desc>
5491 Result code of the progress task.
5492 Valid only if <link to="#completed"/> is true.
5493 </desc>
5494 </attribute>
5495
5496 <attribute name="errorInfo" type="IVirtualBoxErrorInfo" readonly="yes">
5497 <desc>
5498 Extended information about the unsuccessful result of the
5499 progress operation. May be NULL when no extended information
5500 is available.
5501 Valid only if <link to="#completed"/> is true and
5502 <link to="#resultCode"/> indicates a failure.
5503 </desc>
5504 </attribute>
5505
5506 <attribute name="operationCount" type="unsigned long" readonly="yes">
5507 <desc>
5508 Number of operations this task is divided into.
5509 Every task consists of at least one operation.
5510 </desc>
5511 </attribute>
5512
5513 <attribute name="operation" type="unsigned long" readonly="yes">
5514 <desc>Number of the operation being currently executed.</desc>
5515 </attribute>
5516
5517 <attribute name="operationDescription" type="wstring" readonly="yes">
5518 <desc>
5519 Description of the operation being currently executed.
5520 </desc>
5521 </attribute>
5522
5523 <attribute name="operationPercent" type="long" readonly="yes">
5524 <desc>Current operation progress value in percent.</desc>
5525 </attribute>
5526
5527 <method name="waitForCompletion">
5528 <desc>
5529 Waits until the task is done (including all operations) with a
5530 given timeout.
5531 </desc>
5532 <param name="timeout" type="long" dir="in">
5533 <desc>
5534 Timeout value in milliseconds.
5535 Specify -1 for an indefinite wait.
5536 </desc>
5537 </param>
5538 </method>
5539
5540 <method name="waitForOperationCompletion">
5541 <desc>
5542 Waits until the given operation is done with a given timeout.
5543 </desc>
5544 <param name="operation" type="unsigned long" dir="in">
5545 <desc>
5546 Number of the operation to wait for.
5547 Must be less than <link to="#operationCount"/>.
5548 </desc>
5549 </param>
5550 <param name="timeout" type="long" dir="in">
5551 <desc>
5552 Timeout value in milliseconds.
5553 Specify -1 for an indefinite wait.
5554 </desc>
5555 </param>
5556 </method>
5557
5558 <method name="cancel">
5559 <desc>
5560 Cancels the task.
5561 <note>
5562 If <link to="#cancelable"/> is <tt>false</tt>, then
5563 this method will fail.
5564 </note>
5565 </desc>
5566 </method>
5567
5568 </interface>
5569
5570
5571 <!--
5572 // ISnapshot
5573 /////////////////////////////////////////////////////////////////////////
5574 -->
5575
5576 <enumerator
5577 name="ISnapshotEnumerator" type="ISnapshot"
5578 uuid="25cfa2a4-1f1d-4f05-9658-b7a5894ef1a3"
5579 />
5580
5581 <collection
5582 name="ISnapshotCollection" type="ISnapshot"
5583 enumerator="ISnapshotEnumerator"
5584 uuid="23852e3c-94cd-4801-ab05-ed35675b3894"
5585 readonly="yes"
5586 />
5587
5588 <interface
5589 name="ISnapshot" extends="$unknown"
5590 uuid="9f1bbf79-13b0-4da2-abba-4a992c65c083"
5591 wsmap="managed"
5592 >
5593 <desc>
5594 The ISnapshot interface represents a snapshot of the virtual
5595 machine.
5596
5597 The <i>snapshot</i> stores all the information about a virtual
5598 machine necessary to bring it to exactly the same state as it was at
5599 the time of taking the snapshot. The snapshot includes:
5600
5601 <ul>
5602 <li>all settings of the virtual machine (i.e. its hardware
5603 configuration: RAM size, attached hard disks, etc.)
5604 </li>
5605 <li>the execution state of the virtual machine (memory contents,
5606 CPU state, etc.).
5607 </li>
5608 </ul>
5609
5610 Snapshots can be <i>offline</i> (taken when the VM is powered off)
5611 or <i>online</i> (taken when the VM is running). The execution
5612 state of the offline snapshot is called a <i>zero execution state</i>
5613 (it doesn't actually contain any information about memory contents
5614 or the CPU state, assuming that all hardware is just powered off).
5615
5616 <h3>Snapshot branches</h3>
5617
5618 Snapshots can be chained. Chained snapshots form a branch where
5619 every next snapshot is based on the previous one. This chaining is
5620 mostly related to hard disk branching (see <link to="IHardDisk"/>
5621 description). This means that every time a new snapshot is created,
5622 a new differencing hard disk is implicitly created for all normal
5623 hard disks attached to the given virtual machine. This allows to
5624 fully restore hard disk contents when the machine is later reverted
5625 to a particular snapshot.
5626
5627 In the current implelemtation, multiple snapshot branches within one
5628 virtual machine are not allowed. Every machine has a signle branch,
5629 and <link to="IConsole::takeSnapshot()"/> operation adds a new
5630 snapshot to the top of that branch.
5631
5632 Existings snapshots can be discarded using
5633 <link to="IConsole::discardSnapshot()"/>.
5634
5635 <h3>Current snapshot</h3>
5636
5637 Every virtual machine has a current snapshot, identified by
5638 <link to="IMachine::currentSnapshot"/>. This snapshot is used as
5639 a base for the <i>current machine state</i> (see below), to the effect
5640 that all normal hard disks of the machine and its execution
5641 state are based on this snapshot.
5642
5643 In the current implementation, the current snapshot is always the
5644 last taken snapshot (i.e. the head snapshot on the branch) and it
5645 cannot be changed.
5646
5647 The current snapshot is <tt>null</tt> if the machine doesn't have
5648 snapshots at all; in this case the current machine state is just
5649 current settings of this machine plus its current execution state.
5650
5651 <h3>Current machine state</h3>
5652
5653 The current machine state is what represened by IMachine instances got
5654 directly from IVirtualBox
5655 using <link
5656 to="IVirtualBox::getMachine()">getMachine()</link>, <link
5657 to="IVirtualBox::findMachine()">findMachine()</link>, etc. (as opposed
5658 to instances returned by <link to="ISnapshot::machine"/>). This state
5659 is always used when the machine is <link to="IConsole::powerUp"> powered
5660 on</link>.
5661
5662 The current machine state also includes the current execution state.
5663 If the machine is being currently executed
5664 (<link to="IMachine::state"/> is <link to="MachineState::Running"/>
5665 and above), its execution state is just what's happening now.
5666 If it is powered off (<link to="MachineState::PoweredOff"/> or
5667 <link to="MachineState::Aborted"/>), it has a zero execution state.
5668 If the machine is saved (<link to="MachineState::Saved"/>), its
5669 execution state is what saved in the execution state file
5670 (<link to="IMachine::stateFilePath"/>).
5671
5672 If the machine is in the saved state, then, next time it is powered
5673 on, its execution state will be fully restored from the saved state
5674 file and the execution will continue from the point where the state
5675 was saved.
5676
5677 Similarly to snapshots, the current machine state can be discarded
5678 using <link to="IConsole::discardCurrentState()"/>.
5679
5680 <h3>Taking and discarding snapshots</h3>
5681
5682 The table below briefly explains the meaning of every snapshot
5683 operation:
5684
5685 <table>
5686 <tr><th>Operation</th><th>Meaning</th><th>Remarks</th></tr>
5687
5688 <tr><td><link to="IConsole::takeSnapshot()"/></td>
5689
5690 <td>Save the current state of the virtual machine, including all
5691 settings, contents of normal hard disks and the current modifications
5692 to immutable hard disks (for online snapshots)</td>
5693
5694 <td>The current state is not changed (the machine will continue
5695 execution if it is being executed when the snapshot is
5696 taken)</td></tr>
5697
5698 <tr><td><link to="IConsole::discardSnapshot()"/></td>
5699
5700 <td>Forget the state of the virtual machine stored in the snapshot:
5701 dismiss all saved settings and delete the saved execution state (for
5702 online snapshots)</td>
5703
5704 <td>Other snapshots (including child snapshots, if any) and the
5705 current state are not directly affected</td></tr>
5706
5707 <tr><td><link to="IConsole::discardCurrentState()"/></td>
5708
5709 <td>Restore the current state of the virtual machine from the state
5710 stored in the current snapshot, including all settings and hard disk
5711 contents</td>
5712
5713 <td>The current state of the machine existed prior to this operation
5714 is lost</td></tr>
5715
5716 <tr><td><link to="IConsole::discardCurrentSnapshotAndState()"/></td>
5717
5718 <td>Completely revert the virtual machine to the state it was in
5719 before the current snapshot has been taken</td>
5720
5721 <td>The current state, as well as the current snapshot, are
5722 lost</td></tr>
5723
5724 </table>
5725
5726 </desc>
5727
5728 <attribute name="id" type="uuid" readonly="yes">
5729 <desc>UUID of the snapshot.</desc>
5730 </attribute>
5731
5732 <attribute name="name" type="wstring">
5733 <desc>Short name of the snapshot.</desc>
5734 </attribute>
5735
5736 <attribute name="description" type="wstring">
5737 <desc>Optional description of the snapshot.</desc>
5738 </attribute>
5739
5740 <attribute name="timeStamp" type="long long" readonly="yes">
5741 <desc>
5742 Time stamp of the snapshot, in milliseconds since 1970-01-01 UTC.
5743 </desc>
5744 </attribute>
5745
5746 <attribute name="online" type="boolean" readonly="yes">
5747 <desc>
5748 <tt>true</tt> if this snapshot is an online snapshot and
5749 <tt>false</tt> otherwise.
5750
5751 <note>
5752 When this attribute is <tt>true</tt>, the
5753 <link to="IMachine::stateFilePath"/> attribute of the
5754 <link to="#machine"/> object associated with this snapshot
5755 will point to the saved state file. Otherwise, it will be
5756 <tt>null</tt>.
5757 </note>
5758 </desc>
5759 </attribute>
5760
5761 <attribute name="machine" type="IMachine" readonly="yes">
5762 <desc>
5763 Virtual machine this snapshot is taken on. This object
5764 stores all settings the machine had when taking this snapshot.
5765 <note>
5766 The returned machine object is immutable, i.e. no
5767 any settings can be changed.
5768 </note>
5769 </desc>
5770 </attribute>
5771
5772 <attribute name="parent" type="ISnapshot" readonly="yes">
5773 <desc>
5774 Parent snapshot (a snapshot this one is based on).
5775 <note>
5776 It's not an error to read this attribute on a snapshot
5777 that doesn't have a parent -- a null object will be
5778 returned to indicate this.
5779 </note>
5780 </desc>
5781 </attribute>
5782
5783 <attribute name="children" type="ISnapshotCollection" readonly="yes">
5784 <desc>
5785 Child snapshots (all snapshots having this one as a parent).
5786 <note>
5787 In the current implementation, there can be only one
5788 child snapshot, or no children at all, meaning this is the
5789 last (head) snapshot.
5790 </note>
5791 </desc>
5792 </attribute>
5793
5794 </interface>
5795
5796 <!--
5797 // IHardDisk
5798 /////////////////////////////////////////////////////////////////////////
5799 -->
5800
5801 <enum
5802 name="HardDiskStorageType"
5803 uuid="48138584-ad99-479d-a36f-eb82a7663685"
5804 >
5805 <desc>
5806 Virtual hard disk storage type.
5807 <see>IHardDisk</see>
5808 </desc>
5809
5810 <const name="VirtualDiskImage" value="0">
5811 <desc>
5812 Virtual Disk Image, VDI (a regular file in the file
5813 system of the host OS, see <link to="IVirtualDiskImage"/>)
5814 </desc>
5815 </const>
5816 <const name="ISCSIHardDisk" value="1">
5817 <desc>
5818 iSCSI Remote Disk (a disk accessed via the Internet
5819 SCSI protocol over a TCP/IP network, see
5820 <link to="IISCSIHardDisk"/>)
5821 </desc>
5822 </const>
5823 <const name="VMDKImage" value="2">
5824 <desc>
5825 VMware Virtual Machine Disk image (a regular file in the file
5826 system of the host OS, see <link to="IVMDKImage"/>)
5827 </desc>
5828 </const>
5829 <const name="CustomHardDisk" value="3">
5830 <desc>
5831 Disk formats supported through plugins (see
5832 <link to="ICustomHardDisk"/>)
5833 </desc>
5834 </const>
5835 <const name="VHDImage" value="4">
5836 <desc>
5837 Virtual PC Virtual Machine Disk image (a regular file in the file
5838 system of the host OS, see <link to="IVHDImage"/>)
5839 </desc>
5840 </const>
5841 </enum>
5842
5843 <enum
5844 name="HardDiskType"
5845 uuid="a348fafd-a64e-4643-ba65-eb3896bd7e0a"
5846 >
5847 <desc>
5848 Virtual hard disk type.
5849 <see>IHardDisk</see>
5850 </desc>
5851
5852 <const name="Normal" value="0">
5853 <desc>
5854 Normal hard disk (attached directly or indirectly, preserved
5855 when taking snapshots).
5856 </desc>
5857 </const>
5858 <const name="Immutable" value="1">
5859 <desc>
5860 Immutable hard disk (attached indirectly, changes are wiped out
5861 after powering off the virtual machine).
5862 </desc>
5863 </const>
5864 <const name="Writethrough" value="2">
5865 <desc>
5866 Write through hard disk (attached directly, ignored when
5867 taking snapshots).
5868 </desc>
5869 </const>
5870 </enum>
5871
5872 <interface
5873 name="IHardDiskAttachment" extends="$unknown"
5874 uuid="c0ffe596-21c6-4797-8d8a-b47b66881e7a"
5875 wsmap="struct"
5876 >
5877 <desc>
5878 <note>With the COM API, this is an interface like all the others. With the webservice,
5879 this is mapped to a structure, so querying the attribute will not return an object,
5880 but a complete structure.</note>
5881 </desc>
5882 <attribute name="hardDisk" type="IHardDisk" readonly="yes">
5883 <desc>Harddisk object this attachment is about.</desc>
5884 </attribute>
5885
5886 <attribute name="bus" type="StorageBus" readonly="yes">
5887 <desc>Disk controller ID of this attachment.</desc>
5888 </attribute>
5889
5890 <attribute name="channel" type="long" readonly="yes">
5891 <desc>Channel number of the attachment.</desc>
5892 </attribute>
5893
5894 <attribute name="device" type="long" readonly="yes">
5895 <desc>Device slot number of the attachment.</desc>
5896 </attribute>
5897
5898 </interface>
5899
5900 <enumerator
5901 name="IHardDiskAttachmentEnumerator" type="IHardDiskAttachment"
5902 uuid="9955e486-2f0b-432a-99e4-0ebbd338875e"
5903 />
5904
5905 <collection
5906 name="IHardDiskAttachmentCollection" type="IHardDiskAttachment"
5907 enumerator="IHardDiskAttachmentEnumerator"
5908 uuid="8f727842-bb77-45d4-92de-4ec14bf613c9"
5909 readonly="yes"
5910 />
5911
5912 <enumerator
5913 name="IHardDiskEnumerator" type="IHardDisk"
5914 uuid="b976f97b-cdb8-47e3-9860-084031cbd533"
5915 />
5916
5917 <collection
5918 name="IHardDiskCollection" type="IHardDisk"
5919 enumerator="IHardDiskEnumerator"
5920 uuid="43EAC2BC-5C61-40fa-BC38-46DE2C7DB6BB"
5921 readonly="yes"
5922 />
5923
5924 <interface
5925 name="IHardDisk" extends="$unknown"
5926 uuid="FD443EC1-000F-4F5B-9282-D72760A66916"
5927 wsmap="managed"
5928 >
5929 <desc>
5930 The IHardDisk interface represents a virtual hard disk drive
5931 used by virtual machines.
5932
5933 The virtual hard disk drive virtualizes the hard disk hardware and
5934 looks like a regular hard disk inside the virtual machine and
5935 the guest OS.
5936
5937 <h3>Storage Types</h3>
5938
5939 The <link to="HardDiskStorageType">storage type</link> of the
5940 virtual hard disk determines where and how it stores its data
5941 (sectors). Currently, the following storage types are supported:
5942
5943 <ul>
5944
5945 <li>
5946 <i>Virtual Disk Image (VDI)</i>, a regular file in the file system
5947 of the host OS (represented by the <link to="IVirtualDiskImage"/>
5948 interface). This file has a special format optimized so that unused
5949 sectors of data occupy much less space than on a physical hard disk.
5950 </li>
5951
5952 <li>
5953 <i>iSCSI Remote Disk</i>, a disk accessed via the Internet SCSI
5954 protocol over a TCP/IP network link (represented by the
5955 <link to="IISCSIHardDisk"/> interface).
5956 </li>
5957
5958 <li>
5959 <i>VMware VMDK image</i>, a regular file in the file system of the
5960 host OS (represented by the <link to="IVMDKImage"/> interface).
5961 Note that the regular file may be just a descriptor referring to
5962 further files, so don't make assumptions about the OS representation
5963 of a VMDK image.
5964 </li>
5965
5966 <li>
5967 <i>Custom HardDisk</i>, a disk accessed via a plugin which is loaded
5968 when the disk is accessed (represented by the
5969 <link to="ICustomHardDisk"/> interface).
5970 </li>
5971
5972 <li>
5973 <i>Virtual PC VHD Image</i>, a regular file in the file system of the
5974 host OS (represented by the <link to="IVHDImage"/> interface).
5975 </li>
5976
5977 </ul>
5978
5979 The storage type of the particular hard disk object is indicated by
5980 the <link to="#storageType"/> property.
5981
5982 Each storage type is represented by its own interface (as shown
5983 above), that allows to query and set properties and perform
5984 operations specific to that storage type. When an IHardDisk object
5985 reports it uses some particular storage type, it also guaranteed to
5986 support the corresponding interface which you can query. And vice
5987 versa, every object that supports a storage-specific interface, also
5988 supports IHardDisk.
5989
5990 <h3>Virtual Hard Disk Types</h3>
5991
5992 The <link to="HardDiskType">type</link> of the virtual hard disk
5993 determines how it is attached to the virtual machine when you call
5994 <link to="IMachine::attachHardDisk()"/> and what happens to it when
5995 a <link to="ISnapshot">snapshot</link> of the virtual machine is
5996 taken.
5997
5998 There are three types of virtual hard disks:
5999
6000 <ul>
6001 <li><i>Normal</i></li>
6002 <li><i>Immutable</i></li>
6003 <li><i>Writethrough</i></li>
6004 </ul>
6005
6006 The virtual disk type is indicated by the <link to="#type"/>
6007 property. Each of the above types is described in detail further
6008 down.
6009
6010 There is also a forth, "hidden" virtual disk type:
6011 <i>Differencing</i>. It is "hidden" because you cannot directly
6012 create hard disks of this type -- they are automatically created by
6013 VirtualBox when necessary.
6014
6015 <b>Differencing Hard Disks</b>
6016
6017 Unlike disks of other types (that are similar to real hard disks),
6018 the differencing hard disk does not store the full range of data
6019 sectors. Instead, it stores only a subset of sectors of some other
6020 disk that were changed since the differencing hard disk has been
6021 created. Thus, every differencing hard disk has a parent hard disk
6022 it is linked to, and represents the difference between the initial
6023 and the current hard disk state. A differencing hard disk can be
6024 linked to another differencing hard disk -- this way, differencing
6025 hard disks can form a branch of changes. More over, a given virtual
6026 hard disk can have more than one differencing hard disk linked to
6027 it.
6028
6029 A disk the differencing hard disk is linked to (or, in other words,
6030 based on) is called a <i>parent</i> hard disk and is accessible through
6031 the <link to="#parent"/> property. Similarly, all existing differencing
6032 hard disks for a given parent hard disk are called its <i>child</i> hard
6033 disks (and accessible through the <link to="#children"/> property).
6034
6035 All differencing hard disks use Virtual Disk Image files to store
6036 changed sectors. They have the <link to="#type"/> property set to
6037 Normal, but can be easily distinguished from normal hard disks using
6038 the <link to="#parent"/> property: all differencing hard disks have
6039 a parent, while all normal hard disks don't.
6040
6041 When the virtual machine makes an attempt to read a sector that is
6042 missing in a differencing hard disk, its parent is accessed to
6043 resolve the sector in question. This process continues until the
6044 sector is found, or until the root hard disk is encountered, which
6045 always contains all sectors. As a consequence,
6046
6047 <ul>
6048
6049 <li>
6050 The virtual hard disk geometry seen by the guest OS is
6051 always defined by the root hard disk.
6052 </li>
6053
6054 <li>
6055 All hard disks on a branch, up to the root, must be
6056 <link to="#accessible"/> for a given differencing hard disk in order
6057 to let it function properly when the virtual machine is
6058 running.
6059 </li>
6060
6061 </ul>
6062
6063 Differencing hard disks can be implicitly created by VirtualBox in
6064 the following cases:
6065
6066 <ul>
6067
6068 <li>
6069 When a hard disk is <i>indirectly</i> attached to the virtual
6070 machine using <link to="IMachine::attachHardDisk()"/>. In this
6071 case, all disk writes performed by the guest OS will go to the
6072 created diffferencing hard disk, as opposed to the
6073 <i>direct</i> attachment, where all changes are written to the
6074 attached hard disk itself.
6075 </li>
6076
6077 <li>
6078 When a <link to="ISnapshot">snapshot</link> of the virtual machine
6079 is taken. After that, disk writes to hard disks the differencing
6080 ones have been created for, will be directed to those differencing
6081 hard disks, to preserve the contents of the original disks.
6082 </li>
6083
6084 </ul>
6085
6086 Whether to create a differencing hard disk or not depends on the
6087 type of the hard disk attached to the virtual machine. This is
6088 explained below.
6089
6090 Note that in the current implementation, only the
6091 <link to="VirtualDiskImage"/> storage type is used to
6092 represent differencing hard disks. In other words, all
6093 differencing hard disks are <link to="IVirtualDiskImage"/>
6094 objects.
6095
6096 <b>Normal Hard Disks</b>
6097
6098 Normal hard disks are the most commonly used virtual hard disk. A
6099 normal hard disk is attached to the machine directly if it is not
6100 already attached to some other machine. Otherwise, an attempt to
6101 make an indirect attachment through a differencing hard disk will be
6102 made. This attempt will fail if the hard disk is attached to a
6103 virtual machine without snapshots (because it's impossible to create
6104 a differencing hard disk based on a hard disk that is subject to
6105 change).
6106
6107 When an indirect attachment takes place, in the simplest case, where
6108 the machine the hard disk is being attached to doesn't have
6109 snapshots, the differencing hard disk will be based on the normal
6110 hard disk being attached. Otherwise, the first (i.e. the most
6111 recent) descendant of the given normal hard disk found in the
6112 current snapshot branch (starting from the current snapshot and
6113 going up to the root) will be actually used as a base.
6114
6115 Note that when you detach an indirectly attached hard disk from the
6116 machine, the created differencing hard disk image is simply
6117 <b>deleted</b>, so <b>all changes are lost</b>. If you attach the
6118 same disk again, a clean differencing disk will be created based on
6119 the most recent child, as described above.
6120
6121 When taking a snapshot, the contents of all normal hard disks (and
6122 all differencing disks whose roots are normal hard disks) currently
6123 attached to the virtual machine is preserved by creating
6124 differencing hard disks based on them.
6125
6126 <b>Immutable Hard Disks</b>
6127
6128 Immutable hard disks can be used to provide a sort of read-only
6129 access. An immutable hard disk is always attached indirectly. The
6130 created differencing hard disk is automatically wiped out (recreated
6131 from scratch) every time you power off the virtual machine. Thus,
6132 the contents of the immutable disk remains unchanged between runs.
6133
6134 Detaching an immutable hard disk deletes the differencing disk
6135 created for it, with the same effect as in case with normal hard
6136 disks.
6137
6138 When taking a snapshot, the differencing part of the immutable
6139 hard disk is cloned (i.e. copied to a separate Virtual Disk Image
6140 file) without any changes. This is necessary to preserve the exact
6141 virtual machine state when you create an online snapshot.
6142
6143 <b>Writethrough Hard Disks</b>
6144
6145 Hard disks of this type are always attached directly. This means
6146 that every given writethrough hard disk can be attached only to one
6147 virtual machine at a time.
6148
6149 It is impossible to take a snapshot of a virtual machine with the
6150 writethrough hard disk attached, because taking a snapshot implies
6151 saving the execution state and preserving the contents of all hard
6152 disks, but writethrough hard disks cannot be preserved. Preserving
6153 hard disk contents is necessary to ensure the guest OS stored in the
6154 snapshot will get the same hard disk state when restored, which is
6155 especially important when it has open file handles or when there are
6156 cached files and directories stored in memory.
6157
6158 <h3>Creating, Opening and Registering Hard Disks</h3>
6159
6160 Non-differencing hard disks are either created from scratch using
6161 <link to="IVirtualBox::createHardDisk()"/> or opened from a VDI file
6162 using <link to="IVirtualBox::openVirtualDiskImage()"/> (only for hard
6163 disks using the VirtualDiskImage storage type). Once a hard disk is
6164 created or opened, it needs to be registered using
6165 <link to="IVirtualBox::registerHardDisk()"/> to make it available for
6166 attaching to virtual machines. See the documentation of individual
6167 interfaces for various storage types to get more information.
6168
6169 Differencing hard disks are never created explicitly and cannot
6170 be registered or unregistered; they are automatically registered
6171 upon creation and deregistered when deleted.
6172
6173 <h3>More about Indirect Hard Disk Attachments</h3>
6174
6175 Normally, when you attach a hard disk to the virtual machine, and then
6176 query the corresponding attachment using
6177 <link to="IMachine::getHardDisk()"/> or
6178 <link to="IMachine::hardDiskAttachments"/> you will get the same hard
6179 disk object, whose UUID you passed earlier to
6180 <link to="IMachine::attachHardDisk()"/>. However, when an indirect
6181 attachment takes place, calling <link to="IMachine::getHardDisk()"/>
6182 will return a differencing hard disk object, that is either based on the
6183 attached hard disk or on another differencing hard disk, the attached
6184 hard disk is eventually a root for (as described above). In both cases
6185 the returned hard disk object is the object the virtual machine actually
6186 uses to perform disk writes to.
6187
6188 Regardless of whether the attachment is direct or indirect, the
6189 <link to="#machineId"/> property of the attached disk will contain an
6190 UUID of the machine object <link to="IMachine::attachHardDisk()"/>
6191 has been called on.
6192
6193 Note that both <link to="IMachine::attachHardDisk()"/> and
6194 <link to="IMachine::detachHardDisk()"/> are <i>lazy</i> operations. In
6195 particular, this means that when an indirect attachment is made,
6196 differencing hard disks are not created until machine settings are
6197 committed using <link to="IMachine::saveSettings()"/>. Similarly, when a
6198 differencing hard disk is detached, it is not deleted until
6199 <link to="IMachine::saveSettings()"/> is called. Calling
6200 <link to="IMachine::discardSettings()"/> cancels all lazy attachments or
6201 detachments made since the last commit and effectively restores the
6202 previous set of hard disks.
6203
6204 <h3>Hard Disk Accessibility</h3>
6205
6206 The <link to="#accessible"/> attribute of the hard disk object
6207 defines the accessibility state of the respective hard disk storage
6208 (for example, the VDI file for IVirtualDiskImage objects). If the
6209 value of this attribute is <tt>false</tt> then some hard disk
6210 attributes may contain invalid or outdated values (for example, the
6211 virtual or the actual hard disk size) until a new accessibility
6212 check is done that returns <tt>true</tt> (see the attribute
6213 description for more details).
6214
6215 <note>
6216 Because of the possible slowness of the accessibility check,
6217 it is not implicitly performed upon the VirtualBox server startup
6218 (to prevent the application freeze). In partcular, this means that
6219 if you try to read hard disk properties that depend on the
6220 accessibility state without first reading the value of the
6221 <link to="#accessible"/> attribute and ensuring it's value is
6222 <tt>true</tt>, you will get wrong (zero) values.
6223 </note>
6224
6225 </desc>
6226
6227 <attribute name="id" type="uuid" readonly="yes">
6228 <desc>
6229
6230 UUID of the hard disk. For newly created hard disk objects,
6231 this value is a randomly generated UUID.
6232
6233 </desc>
6234 </attribute>
6235
6236 <attribute name="description" type="wstring">
6237 <desc>
6238
6239 Optional description of the hard disk. For a newly created hard
6240 disk, this value is <tt>null</tt>.
6241
6242 <note>For some storage types, reading this property is
6243 meaningless when <link to="#accessible"/> is <tt>false</tt>.
6244 Also, you cannot assign it a new value in this case.</note>
6245
6246 </desc>
6247 </attribute>
6248
6249 <attribute name="storageType" type="HardDiskStorageType" readonly="yes">
6250 <desc>
6251
6252 Storage type of this hard disk.
6253
6254 Storage type is defined when you open or create a new hard disk
6255 object.
6256
6257 </desc>
6258 </attribute>
6259
6260 <attribute name="location" type="wstring" readonly="yes">
6261 <desc>
6262
6263 Storage location of this hard disk. The returned string serves
6264 for informational purposes only. To access detailed information
6265 about the storage, query the appropriate storage-specific
6266 interface.
6267
6268 </desc>
6269 </attribute>
6270
6271 <attribute name="type" type="HardDiskType">
6272 <desc>
6273
6274 Type (behavior) of this hard disk. For a newly created or opened hard
6275 disk, this value is <link to="HardDiskType::Normal"/>.
6276
6277 <note>
6278 In the current implementation, this property can be
6279 changed only on an unregistered hard disk object. This may be
6280 changed later.
6281 </note>
6282
6283 </desc>
6284 </attribute>
6285
6286 <attribute name="parent" type="IHardDisk" readonly="yes">
6287 <desc>
6288
6289 Parent of this hard disk (a hard disk this one is directly based
6290 on).
6291
6292 Only differencing hard disks have parents, so a <tt>null</tt>
6293 object is returned for a hard disk of any other type.
6294 </desc>
6295 </attribute>
6296
6297 <attribute name="children" type="IHardDiskCollection" readonly="yes">
6298 <desc>
6299
6300 Children of this hard disk (all differencing hard disks for
6301 those this one is a parent). An empty collection is returned, if
6302 this hard disk doesn't have any children.
6303
6304 </desc>
6305 </attribute>
6306
6307 <attribute name="root" type="IHardDisk" readonly="yes">
6308 <desc>
6309
6310 Root hard disk of this hard disk. If this hard disk is a
6311 differencing hard disk, its root hard disk is the first disk on
6312 the branch. For all other types of hard disks, this property
6313 returns the hard disk object itself (i.e. the same object you
6314 read this property on).
6315
6316 </desc>
6317 </attribute>
6318
6319 <attribute name="accessible" type="boolean" readonly="yes">
6320 <desc>
6321
6322 Whether the hard disk storage is currently accessible or not.
6323 The storage, for example, can be unaccessible if it doesn't exist
6324 or if it is placed on a network resource that is not available
6325 by the time this attribute is read.
6326
6327 In the current implementation, the value of this property is
6328 also <tt>false</tt> if this hard disk is attached to a running
6329 virtual machine.
6330
6331 The accessibility check is performed automatically every time
6332 this attribute is read. You should keep it in mind that this check
6333 may be slow and can block the calling thread for a long time (for
6334 example, if the network resourse where the hard disk storage is
6335 located is down).
6336
6337 The following attributes of the hard disk object are considered
6338 to be invalid when this attribute is <tt>false</tt>:
6339 <ul>
6340 <li><link to="#size"/></li>
6341 <li><link to="#actualSize"/></li>
6342 </ul>
6343 Individual hard disk storage type interfaces may define
6344 additional attributes that depend on the accessibility state.
6345 </desc>
6346 </attribute>
6347
6348 <attribute name="allAccessible" type="boolean" readonly="yes">
6349 <desc>
6350
6351 Whether the whole hard disk branch, starting from this image and
6352 going through its ancestors up to the root, is accessible or
6353 not.
6354
6355 This property makes sense only for differencing hard disks. For
6356 all other types of hard disks it returns the same value as
6357 <link to="#accessible"/>.
6358
6359 </desc>
6360 </attribute>
6361
6362 <attribute name="lastAccessError" type="wstring" readonly="yes">
6363 <desc>
6364
6365 String describing the reason of inaccessibility of this hard
6366 disk after the last call to <link to="#accessible"/> that
6367 returned <tt>false</tt>. A <tt>null</tt> value of this property
6368 means that the last accessibility check returned <tt>true</tt>.
6369
6370 </desc>
6371 </attribute>
6372
6373 <attribute name="size" type="unsigned long long" readonly="yes">
6374 <desc>
6375
6376 Logical size of this hard disk (in megabytes), as reported to the
6377 guest OS running inside the vurtual machine this disk is
6378 attached to. The logical size is defined when the hard disk is
6379 created.
6380
6381 <note>Reading this property on a differencing hard disk will
6382 return the size of its root hard disk.</note>
6383
6384 <note>Reading this property is meaningless when
6385 <link to="#accessible"/> is <tt>false</tt></note>
6386
6387 </desc>
6388 </attribute>
6389
6390 <attribute name="actualSize" type="unsigned long long" readonly="yes">
6391 <desc>
6392
6393 Physical size of the storage used to store hard disk data (in
6394 bytes). This size is usually less than the logical size of the
6395 hard disk, depending on the storage type and on the size
6396 optimization method used for that storage.
6397
6398 <note>Reading this property is meaningless when
6399 <link to="#accessible"/> is <tt>false</tt></note>
6400
6401 </desc>
6402 </attribute>
6403
6404 <attribute name="machineId" type="uuid" readonly="yes">
6405 <desc>
6406
6407 UUID of the machine this hard disk is attached to (or a
6408 <tt>null</tt> UUID if it is not attached).
6409
6410 <note>Immutable hard disks are never attached directly, so this
6411 attribute is always <tt>null</tt> in this case.</note>
6412
6413 </desc>
6414 </attribute>
6415
6416 <attribute name="snapshotId" type="uuid" readonly="yes">
6417 <desc>
6418
6419 UUID of the <link to="ISnapshot">snapshot</link> this hard disk
6420 is associated with (or <tt>null</tt> UUID if it is not
6421 associated with any snapshot).
6422
6423 <note>
6424 This attribute is always <tt>null</tt> if <link to="#machineId"/>
6425 is <tt>null</tt>.
6426 </note>
6427
6428 <note>
6429 Writethrough hard disks are always attached directly and cannot be
6430 involved when taking snapshots, so this attribute is meaningless and
6431 therefore always <tt>null</tt>.
6432 </note>
6433
6434 </desc>
6435 </attribute>
6436
6437 <method name="cloneToImage">
6438
6439 <desc>
6440
6441 Starts creating a clone of this hard disk. The cloned hard disk
6442 will use the specified Virtual Disk Image file as a storage and
6443 will contain exactly the same sector data as the hard disk being
6444 cloned, except that a new UUID for the clone will be randomly
6445 generated.
6446
6447 The specified image file path can be absolute (full path) or
6448 relative to the <link to="IVirtualBox::homeFolder"> VirtualBox
6449 home directory</link>. If only a file name without any path is
6450 given, the <link to="ISystemProperties::defaultVDIFolder">
6451 default VDI folder</link> will be used as a path to the image
6452 file.
6453
6454 It is an error to use the object returned in the @a image
6455 parameter until the returned @a progress object reports success.
6456
6457 <note>In the current implementation, only non-differencing hard
6458 disks can be cloned.</note>
6459
6460 </desc>
6461
6462 <param name="filePath" type="wstring" dir="in">
6463 <desc>Path to a file where to store the cloned hard disk.</desc>
6464 </param>
6465 <param name="image" type="IVirtualDiskImage" dir="out">
6466 <desc>Cloned hard disk object.</desc>
6467 </param>
6468 <param name="progress" type="IProgress" dir="return">
6469 <desc>Progress object to track the operation completion.</desc>
6470 </param>
6471
6472 </method>
6473
6474 </interface>
6475
6476 <!--
6477 // IVirtualDiskImage
6478 /////////////////////////////////////////////////////////////////////////
6479 -->
6480
6481 <interface
6482 name="IVirtualDiskImage" extends="$unknown"
6483 uuid="a8265b5a-0d20-4a46-a02f-65693a4e8239"
6484 wsmap="managed"
6485 >
6486
6487 <desc>
6488 The IVirtualDiskImage interface represent a specific type of
6489 <link to="IHardDisk" /> that uses VDI image files.
6490
6491 The Virtual Disk Image (VDI) format is VirtualBox's native format for
6492 hard disk containers.
6493
6494 Objects that support this interface also support the
6495 <link to="IHardDisk"/> interface.
6496
6497 Hard disks using virtual disk images can be either opened using
6498 <link to="IVirtualBox::openHardDisk()"/> or created from
6499 scratch using <link to="IVirtualBox::createHardDisk()"/>.
6500
6501 When a new hard disk object is created from scratch, an image file for it
6502 is not automatically created. To do it, you need to specify a
6503 valid <link to="#filePath">file path</link>, and call
6504 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>.
6505 When it is done, the hard disk object can be registered by calling
6506 <link to="IVirtualBox::registerHardDisk()"/> and then
6507 <link to="IMachine::attachHardDisk()">attached</link> to
6508 virtual machines.
6509
6510 The <link to="IHardDisk::description">description</link> of the
6511 Virtual Disk Image is stored in the image file. For this reason,
6512 changing the value of this property requires the hard disk to be
6513 <link to="IHardDisk::accessible">accessible</link>. The description
6514 of a registered hard disk can be changed only if a virtual machine
6515 using it is not running.
6516
6517 </desc>
6518
6519 <attribute name="filePath" type="wstring">
6520 <desc>
6521
6522 Full file name of the virtual disk image of this hard disk. For
6523 newly created hard disk objects, this value is <tt>null</tt>.
6524
6525 When assigning a new path, it can be absolute (full path) or relative
6526 to the <link to="IVirtualBox::homeFolder"> VirtualBox home
6527 directory</link>. If only a file name without any path is given,
6528 the <link to="ISystemProperties::defaultVDIFolder"> default VDI
6529 folder</link> will be used as a path to the image file.
6530
6531 When reading this propery, a full path is always returned.
6532
6533 <note>
6534 This property cannot be changed when <link to="#created"/>
6535 returns <tt>true</tt>.
6536 </note>
6537
6538 </desc>
6539 </attribute>
6540
6541 <attribute name="created" type="boolean" readonly="yes">
6542 <desc>
6543
6544 Whether the virual disk image is created or not. For newly
6545 created hard disk objects or after a successful invocation of
6546 <link to="#deleteImage()"/>, this value is <tt>false</tt> until
6547 <link to="#createFixedImage()"/> or <link
6548 to="#createDynamicImage()"/> is called.
6549
6550 </desc>
6551 </attribute>
6552
6553 <method name="createDynamicImage">
6554
6555 <desc>
6556
6557 Starts creating a dymically expanding hard disk image in the
6558 background. The previous image associated with this object, if
6559 any, must be deleted using <link to="#deleteImage"/>, otherwise
6560 the operation will fail.
6561
6562 <note>After the returned progress object reports that the
6563 operation is complete, this hard disk object can be
6564 <link to="IVirtualBox::registerHardDisk()">registered</link>
6565 within this VirtualBox installation.</note>
6566
6567 </desc>
6568
6569 <param name="size" type="unsigned long long" dir="in">
6570 <desc>Maximum logical size of the hard disk in megabytes.</desc>
6571 </param>
6572 <param name="progress" type="IProgress" dir="return">
6573 <desc>Progress object to track the operation completion.</desc>
6574 </param>
6575
6576 </method>
6577
6578 <method name="createFixedImage">
6579 <desc>
6580
6581 Starts creating a fixed-size hard disk image in the background. The
6582 previous image, if any, must be deleted using
6583 <link to="#deleteImage"/>, otherwise the operation will fail.
6584
6585 <note>
6586 After the returned progress object reports that the
6587 operation is complete, this hard disk object can be
6588 <link to="IVirtualBox::registerHardDisk()">registered</link>
6589 within this VirtualBox installation.
6590 </note>
6591
6592 </desc>
6593
6594 <param name="size" type="unsigned long long" dir="in">
6595 <desc>Logical size of the hard disk in megabytes.</desc>
6596 </param>
6597 <param name="progress" type="IProgress" dir="return">
6598 <desc>Progress object to track the operation completion.</desc>
6599 </param>
6600
6601 </method>
6602
6603 <method name="deleteImage">
6604 <desc>
6605
6606 Deletes the existing hard disk image. The hard disk must not be
6607 registered within this VirtualBox installation, otherwise the
6608 operation will fail.
6609
6610 <note>
6611 After this operation succeeds, it will be impossible to
6612 register the hard disk until the image file is created
6613 again.
6614 </note>
6615
6616 <note>
6617 This operation is valid only for non-differencing hard disks, after
6618 they are unregistered using
6619 <link to="IVirtualBox::unregisterHardDisk()"/>.
6620 </note>
6621
6622 </desc>
6623 </method>
6624
6625 </interface>
6626
6627 <!--
6628 // IISCSIHardDisk
6629 /////////////////////////////////////////////////////////////////////////
6630 -->
6631
6632 <interface
6633 name="IISCSIHardDisk" extends="$unknown"
6634 uuid="003f6ca9-3257-4ef9-99c9-c66ce44576cb"
6635 wsmap="managed"
6636 >
6637
6638 <desc>
6639 THe IISCSIHardDisk interface represents a specific type of
6640 <link to="IHardDisk"/> that uses iSCSI.
6641
6642 The IISCSIHardDisk interface represents <link to="IHardDisk">virtual
6643 hard disks</link> that use the Internet SCSI (iSCSI) protocol to store
6644 hard disk data on remote machines.
6645
6646 Objects that support this interface also support the
6647 <link to="IHardDisk"/> interface.
6648
6649 iSCSI hard disks can be created using
6650 <link to="IVirtualBox::createHardDisk()"/>. When a new hard disk object
6651 is created, all its properties are uninitialized. After you assign some
6652 meaningful values to them, the hard disk object can be registered by
6653 calling <link to="IVirtualBox::registerHardDisk()"/> and
6654 then <link to="IMachine::attachHardDisk()">attached</link> to virtual
6655 machines.
6656
6657 The <link to="IHardDisk::description">description</link>
6658 of the iSCSI hard disk is stored in the VirtualBox
6659 configuration file, so it can be changed (at appropriate
6660 times) even when
6661 <link to="IHardDisk::accessible">accessible</link> returns
6662 <tt>false</tt>. However, the hard disk must not be
6663 attached to a running virtual machine.
6664
6665 <note>
6666 In the current imlementation, the type of all iSCSI hard disks
6667 is <link to="HardDiskType::Writethrough">Writethrough</link>
6668 and cannot be changed.
6669 </note>
6670
6671 </desc>
6672
6673 <attribute name="server" type="wstring">
6674 <desc>
6675
6676 iSCSI Server name (either a host name or an IP address). For
6677 newly created hard disk objects, this value is <tt>null</tt>.
6678
6679 </desc>
6680 </attribute>
6681
6682 <attribute name="port" type="unsigned short">
6683 <desc>
6684
6685 iSCSI Server port. For newly created hard disk objects, this
6686 value is <tt>0</tt>, which means the default port.
6687
6688 </desc>
6689 </attribute>
6690
6691 <attribute name="target" type="wstring">
6692 <desc>
6693
6694 iSCSI target name. For newly created hard disk objects, this
6695 value is <tt>null</tt>.
6696
6697 </desc>
6698 </attribute>
6699
6700 <attribute name="lun" type="unsigned long long">
6701 <desc>
6702
6703 Logical unit number for this iSCSI disk. For newly created hard
6704 disk objects, this value is <tt>0</tt>.
6705
6706 </desc>
6707 </attribute>
6708
6709 <attribute name="userName" type="wstring">
6710 <desc>
6711
6712 User name for accessing this iSCSI disk. For newly created hard
6713 disk objects, this value is <tt>null</tt>.
6714
6715 </desc>
6716 </attribute>
6717
6718 <attribute name="password" type="wstring">
6719 <desc>
6720
6721 User password for accessing this iSCSI disk. For newly created
6722 hard disk objects, this value is <tt>null</tt>.
6723
6724 </desc>
6725 </attribute>
6726
6727 </interface>
6728
6729 <!--
6730 // IVMDKImage
6731 /////////////////////////////////////////////////////////////////////////
6732 -->
6733
6734 <interface
6735 name="IVMDKImage" extends="$unknown"
6736 uuid="178398f5-8559-4fee-979e-420af5b53eef"
6737 wsmap="managed"
6738 >
6739 <desc>
6740 The IVMDKImage interface represents a specific type of
6741 <link to="IHardDisk"/> that uses VMDK image files.
6742
6743 The Virtual Machine Disk (VMDK) format is the industry standard format
6744 for virtual hard disk image files, which VirtualBox supports besides its
6745 own native VDI format.
6746
6747 Objects that support this interface also support the
6748 <link to="IHardDisk"/> interface.
6749
6750 Hard disks using VMDK images can be either opened using
6751 <link to="IVirtualBox::openHardDisk()"/> or created from
6752 scratch using <link to="IVirtualBox::createHardDisk()"/>.
6753
6754 When a new hard disk object is created from scratch, an image file for it
6755 is not automatically created. To do it, you need to specify a
6756 valid <link to="#filePath">file path</link>, and call
6757 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>.
6758 When it is done, the hard disk object can be registered by calling
6759 <link to="IVirtualBox::registerHardDisk()"/> and then
6760 <link to="IMachine::attachHardDisk()">attached</link> to
6761 virtual machines.
6762
6763 The <link to="IHardDisk::description">description</link>
6764 of the VMDK hard disk is stored in the VirtualBox
6765 configuration file, so it can be changed (at appropriate
6766 times) even when
6767 <link to="IHardDisk::accessible">accessible</link> returns
6768 <tt>false</tt>. However, the hard disk must not be
6769 attached to a running virtual machine.
6770
6771 <note>
6772 In the current imlementation, the type of all VMDK hard disks
6773 is <link to="HardDiskType::Writethrough">Writethrough</link> and cannot
6774 be changed.
6775 </note>
6776
6777 </desc>
6778
6779 <attribute name="filePath" type="wstring">
6780 <desc>
6781
6782 Full file name of the VMDK image of this hard disk. For
6783 newly created hard disk objects, this value is <tt>null</tt>.
6784
6785 When assigning a new path, it can be absolute (full path) or relative
6786 to the <link to="IVirtualBox::homeFolder"> VirtualBox home
6787 directory</link>. If only a file name without any path is given,
6788 the <link to="ISystemProperties::defaultVDIFolder"> default VDI
6789 folder</link> will be used as a path to the image file.
6790
6791 When reading this propery, a full path is always returned.
6792
6793 <note>
6794 This property cannot be changed when <link to="#created"/>
6795 returns <tt>true</tt>.
6796 </note>
6797
6798 </desc>
6799 </attribute>
6800
6801 <attribute name="created" type="boolean" readonly="yes">
6802 <desc>
6803
6804 Whether the virual disk image is created or not. For newly created
6805 hard disk objects or after a successful invocation of
6806 <link to="#deleteImage()"/>, this value is <tt>false</tt> until
6807 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>
6808 is called.
6809
6810 </desc>
6811 </attribute>
6812
6813 <method name="createDynamicImage">
6814
6815 <desc>
6816
6817 Starts creating a dymically expanding hard disk image in the
6818 background. The previous image associated with this object, if
6819 any, must be deleted using <link to="#deleteImage"/>, otherwise
6820 the operation will fail.
6821
6822 <note>
6823 After the returned progress object reports that the
6824 operation is complete, this hard disk object can be
6825 <link to="IVirtualBox::registerHardDisk()">registered</link> within
6826 this VirtualBox installation.
6827 </note>
6828
6829 </desc>
6830
6831 <param name="size" type="unsigned long long" dir="in">
6832 <desc>Maximum logical size of the hard disk in megabytes.</desc>
6833 </param>
6834 <param name="progress" type="IProgress" dir="return">
6835 <desc>Progress object to track the operation completion.</desc>
6836 </param>
6837
6838 </method>
6839
6840 <method name="createFixedImage">
6841 <desc>
6842
6843 Starts creating a fixed-size hard disk image in the background. The
6844 previous image, if any, must be deleted using
6845 <link to="#deleteImage"/>, otherwise the operation will fail.
6846
6847 <note>
6848 After the returned progress object reports that the
6849 operation is complete, this hard disk object can be
6850 <link to="IVirtualBox::registerHardDisk()">registered</link> within
6851 this VirtualBox installation.
6852 </note>
6853
6854 </desc>
6855
6856 <param name="size" type="unsigned long long" dir="in">
6857 <desc>Logical size of the hard disk in megabytes.</desc>
6858 </param>
6859 <param name="progress" type="IProgress" dir="return">
6860 <desc>Progress object to track the operation completion.</desc>
6861 </param>
6862
6863 </method>
6864
6865 <method name="deleteImage">
6866 <desc>
6867
6868 Deletes the existing hard disk image. The hard disk must not be
6869 registered within this VirtualBox installation, otherwise the
6870 operation will fail.
6871
6872 <note>
6873 After this operation succeeds, it will be impossible to register the
6874 hard disk until the image file is created again.
6875 </note>
6876
6877 <note>
6878 This operation is valid only for non-differencing hard disks, after
6879 they are unregistered using
6880 <link to="IVirtualBox::unregisterHardDisk()"/>.
6881 </note>
6882
6883 </desc>
6884 </method>
6885
6886 </interface>
6887
6888 <!--
6889 // ICustomHardDisk
6890 /////////////////////////////////////////////////////////////////////////
6891 -->
6892
6893 <interface
6894 name="ICustomHardDisk" extends="$unknown"
6895 uuid="a7b0236d-3ff4-47c0-a4aa-ddc4ddc1141a"
6896 wsmap="managed"
6897 >
6898 <desc>
6899 The ICustomHardDisk interface represents a specific type of
6900 <link to="IHardDisk" /> that is supported through a third-party plugin.
6901
6902 This interface allows to add support for custom hard disk formats to
6903 VirtualBox.
6904
6905 Objects that support this interface also support the
6906 <link to="IHardDisk"/> interface.
6907
6908 Hard disks using custom hard disk formats can be either opened using
6909 <link to="IVirtualBox::openHardDisk()"/> or created from scratch using
6910 <link to="IVirtualBox::createHardDisk()"/>.
6911
6912 When a new hard disk object is created from scratch, an image file for
6913 it is not automatically created. To do it, you need to specify a
6914 valid <link to="#location">location</link>, and call
6915 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>.
6916 When it is done, the hard disk object can be registered by calling
6917 <link to="IVirtualBox::registerHardDisk()"/> and then
6918 <link to="IMachine::attachHardDisk()">attached</link> to
6919 virtual machines.
6920
6921 The <link to="IHardDisk::description">description</link>
6922 of the hard disk is stored in the VirtualBox
6923 configuration file, so it can be changed (at appropriate
6924 times) even when
6925 <link to="IHardDisk::accessible">accessible</link> returns
6926 <tt>false</tt>. However, the hard disk must not be
6927 attached to a running virtual machine.
6928
6929 </desc>
6930
6931 <attribute name="location" type="wstring">
6932 <desc>
6933
6934 Location of this custom hard disk. For
6935 newly created hard disk objects, this value is <tt>null</tt>.
6936
6937 The format of the location string is plugin-dependent. In case if the
6938 plugin uses a regular file in the local file system to store hard disk
6939 data, then the location is a file path and the following rules apply:
6940 <ul>
6941 <li>
6942 when assigning a new path, it must be absolute (full path) or
6943 relative to the <link to="IVirtualBox::homeFolder"> VirtualBox
6944 home directory</link>. If only a file name without any path is
6945 given, the <link to="ISystemProperties::defaultVDIFolder"> default
6946 VDI folder</link> will be used as a path to the image file.
6947 </li>
6948 <li>
6949 When reading this propery, a full path is always returned.
6950 </li>
6951 </ul>
6952
6953 <note>
6954 This property cannot be changed when <link to="#created"/>
6955 returns <tt>true</tt>.
6956 </note>
6957
6958 </desc>
6959 </attribute>
6960
6961 <attribute name="format" type="wstring" readonly="yes">
6962 <desc>
6963
6964 The plugin name of the image file.
6965
6966 </desc>
6967 </attribute>
6968
6969 <attribute name="created" type="boolean" readonly="yes">
6970 <desc>
6971
6972 Whether the virual disk image is created or not. For newly created
6973 hard disk objects or after a successful invocation of
6974 <link to="#deleteImage()"/>, this value is <tt>false</tt> until
6975 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>
6976 is called.
6977
6978 </desc>
6979 </attribute>
6980
6981 <method name="createDynamicImage">
6982
6983 <desc>
6984
6985 Starts creating a dymically expanding hard disk image in the
6986 background. The previous image associated with this object, if
6987 any, must be deleted using <link to="#deleteImage"/>, otherwise
6988 the operation will fail.
6989
6990 <note>
6991 After the returned progress object reports that the
6992 operation is complete, this hard disk object can be
6993 <link to="IVirtualBox::registerHardDisk()">registered</link> within
6994 this VirtualBox installation.
6995 </note>
6996
6997 </desc>
6998
6999 <param name="size" type="unsigned long long" dir="in">
7000 <desc>Maximum logical size of the hard disk in megabytes.</desc>
7001 </param>
7002 <param name="progress" type="IProgress" dir="return">
7003 <desc>Progress object to track the operation completion.</desc>
7004 </param>
7005
7006 </method>
7007
7008 <method name="createFixedImage">
7009 <desc>
7010
7011 Starts creating a fixed-size hard disk image in the background. The
7012 previous image, if any, must be deleted using
7013 <link to="#deleteImage"/>, otherwise the operation will fail.
7014
7015 <note>
7016 After the returned progress object reports that the
7017 operation is complete, this hard disk object can be
7018 <link to="IVirtualBox::registerHardDisk()">registered</link> within
7019 this VirtualBox installation.
7020 </note>
7021
7022 </desc>
7023
7024 <param name="size" type="unsigned long long" dir="in">
7025 <desc>Logical size of the hard disk in megabytes.</desc>
7026 </param>
7027 <param name="progress" type="IProgress" dir="return">
7028 <desc>Progress object to track the operation completion.</desc>
7029 </param>
7030
7031 </method>
7032
7033 <method name="deleteImage">
7034 <desc>
7035
7036 Deletes the existing hard disk image. The hard disk must not be
7037 registered within this VirtualBox installation, otherwise the
7038 operation will fail.
7039
7040 <note>
7041 After this operation succeeds, it will be impossible to register the
7042 hard disk until the image file is created again.
7043 </note>
7044
7045 <note>
7046 This operation is valid only for non-differencing hard disks, after
7047 they are unregistered using
7048 <link to="IVirtualBox::unregisterHardDisk()"/>.
7049 </note>
7050
7051 </desc>
7052 </method>
7053
7054 </interface>
7055
7056 <!--
7057 // IVHDImage
7058 /////////////////////////////////////////////////////////////////////////
7059 -->
7060
7061 <interface
7062 name="IVHDImage" extends="$unknown"
7063 uuid="163b88c3-7552-424a-8205-daf17a004747"
7064 wsmap="managed"
7065 >
7066 <desc>
7067
7068 The IVHDImage interface represents <link to="IHardDisk">virtual hard
7069 disks</link> that use Virtual PC Virtual Machine Disk image files to store
7070 hard disk data.
7071
7072 Hard disks using VHD images can be either opened using
7073 <link to="IVirtualBox::openHardDisk()"/> or created from
7074 scratch using <link to="IVirtualBox::createHardDisk()"/>.
7075
7076 Objects that support this interface also support the
7077 <link to="IHardDisk"/> interface.
7078
7079 When a new hard disk object is created from scatch, an image file for it
7080 is not automatically created. To do it, you need to specify a
7081 valid <link to="#filePath">file path</link>, and call
7082 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>.
7083 When it is done, the hard disk object can be registered by calling
7084 <link to="IVirtualBox::registerHardDisk()"/> and then
7085 <link to="IMachine::attachHardDisk()">attached</link> to
7086 virtual machines.
7087
7088 The <link to="IHardDisk::description">description</link>
7089 of the VHD hard disk is stored in the VirtualBox
7090 configuration file, so it can be changed (at appropriate
7091 times) even when
7092 <link to="IHardDisk::accessible">accessible</link> returns
7093 <tt>false</tt>. However, the hard disk must not be
7094 attached to a running virtual machine.
7095
7096 <note>
7097 In the current imlementation, the type of all VHD hard disks
7098 is <link to="HardDiskType::Writethrough">Writethrough</link> and cannot
7099 be changed.
7100 </note>
7101
7102 </desc>
7103
7104 <attribute name="filePath" type="wstring">
7105 <desc>
7106
7107 Full file name of the VHD image of this hard disk. For
7108 newly created hard disk objects, this value is <tt>null</tt>.
7109
7110 When assigning a new path, it can be absolute (full path) or relative
7111 to the <link to="IVirtualBox::homeFolder"> VirtualBox home
7112 directory</link>. If only a file name without any path is given,
7113 the <link to="ISystemProperties::defaultVDIFolder"> default VDI
7114 folder</link> will be used as a path to the image file.
7115
7116 When reading this propery, a full path is always returned.
7117
7118 <note>
7119 This property cannot be changed when <link to="#created"/>
7120 returns <tt>true</tt>. In this case, the specified file name can be
7121 absolute (full path) or relative to
7122 the <link to="IVirtualBox::homeFolder"> VirtualBox home
7123 directory</link>. If only a file name without any path is given,
7124 the <link to="ISystemProperties::defaultVDIFolder"> default VDI
7125 folder</link> will be used as a path to the image file.
7126 </note>
7127
7128 </desc>
7129 </attribute>
7130
7131 <attribute name="created" type="boolean" readonly="yes">
7132 <desc>
7133
7134 Whether the virual disk image is created or not. For newly created
7135 hard disk objects or after a successful invocation of
7136 <link to="#deleteImage()"/>, this value is <tt>false</tt> until
7137 <link to="#createFixedImage()"/> or <link to="#createDynamicImage()"/>
7138 is called.
7139
7140 </desc>
7141 </attribute>
7142
7143 <method name="createDynamicImage">
7144
7145 <desc>
7146
7147 Starts creating a dymically expanding hard disk image in the
7148 background. The previous image associated with this object, if
7149 any, must be deleted using <link to="#deleteImage"/>, otherwise
7150 the operation will fail.
7151
7152 <note>
7153 After the returned progress object reports that the
7154 operation is complete, this hard disk object can be
7155 <link to="IVirtualBox::registerHardDisk()">registered</link> within
7156 this VirtualBox installation.
7157 </note>
7158
7159 </desc>
7160
7161 <param name="size" type="unsigned long long" dir="in">
7162 <desc>Maximum logical size of the hard disk in megabytes.</desc>
7163 </param>
7164 <param name="progress" type="IProgress" dir="return">
7165 <desc>Progress object to track the operation completion.</desc>
7166 </param>
7167
7168 </method>
7169
7170 <method name="createFixedImage">
7171 <desc>
7172
7173 Starts creating a fixed-size hard disk image in the background. The
7174 previous image, if any, must be deleted using
7175 <link to="#deleteImage"/>, otherwise the operation will fail.
7176
7177 <note>
7178 After the returned progress object reports that the
7179 operation is complete, this hard disk object can be
7180 <link to="IVirtualBox::registerHardDisk()">registered</link> within
7181 this VirtualBox installation.
7182 </note>
7183
7184 </desc>
7185
7186 <param name="size" type="unsigned long long" dir="in">
7187 <desc>Logical size of the hard disk in megabytes.</desc>
7188 </param>
7189 <param name="progress" type="IProgress" dir="return">
7190 <desc>Progress object to track the operation completion.</desc>
7191 </param>
7192
7193 </method>
7194
7195 <method name="deleteImage">
7196 <desc>
7197
7198 Deletes the existing hard disk image. The hard disk must not be
7199 registered within this VirtualBox installation, otherwise the
7200 operation will fail.
7201
7202 <note>
7203 After this operation succeeds, it will be impossible to register the
7204 hard disk until the image file is created again.
7205 </note>
7206
7207 <note>
7208 This operation is valid only for non-differencing hard disks, after
7209 they are unregistered using
7210 <link to="IVirtualBox::unregisterHardDisk()"/>.
7211 </note>
7212
7213 </desc>
7214 </method>
7215
7216 </interface>
7217
7218 <!--
7219 // IDVDImage
7220 /////////////////////////////////////////////////////////////////////////
7221 -->
7222
7223 <enumerator
7224 name="IDVDImageEnumerator" type="IDVDImage"
7225 uuid="9BE77C8D-E1BE-4bf2-A67B-B4DD3D2B0F28"
7226 />
7227
7228 <collection
7229 name="IDVDImageCollection" type="IDVDImage"
7230 enumerator="IDVDImageEnumerator"
7231 uuid="AE7053FA-ADD2-4ea4-AFCF-24D5F8DDED64"
7232 readonly="yes"
7233 >
7234 <method name="findByPath">
7235 <desc>
7236 Searches this collection for a DVD image with the given disk path.
7237 <note>
7238 The method returns an error if the given name does not
7239 correspond to any DVD image in the collection.
7240 </note>
7241 </desc>
7242 <param name="path" type="wstring" dir="in">
7243 <desc>Name of the DVD image's file system location.</desc>
7244 </param>
7245 <param name="image" type="IDVDImage" dir="return">
7246 <desc>Found DVD image object</desc>
7247 </param>
7248 </method>
7249 </collection>
7250
7251 <interface
7252 name="IDVDImage" extends="$unknown"
7253 uuid="140FFF03-E479-4194-8562-ABC4F8171009"
7254 wsmap="managed"
7255 >
7256 <desc>
7257
7258 The IDVDImage interface represents a file containing the image
7259 of the DVD or CD disk.
7260
7261 <h3>Image Accessibility</h3>
7262
7263 The <link to="#accessible"/> attribute of the image object
7264 defines the accessibility state of the image file. If the
7265 value of this attribute is <tt>false</tt> then some image
7266 attributes may contain invalid or outdated values (for example, the
7267 the image file size) until a new accessibility
7268 check is done that returns <tt>true</tt>.
7269
7270 <note>
7271 Because of the possible slowness of the accessibility check,
7272 it is not implicitly performed upon the VirtualBox server startup
7273 (to prevent the application freeze). In partcular, this means that
7274 if you try to read image properties that depend on the
7275 accessibility state without first reading the value of the
7276 <link to="#accessible"/> attribute and ensuring it's value is
7277 <tt>true</tt>, you will get wrong (zero) values.
7278 </note>
7279
7280 </desc>
7281 <attribute name="id" type="uuid" readonly="yes">
7282 <desc>UUID of the CD/DVD image.</desc>
7283 </attribute>
7284
7285 <attribute name="filePath" type="wstring" readonly="yes">
7286 <desc>Full file name of the CD/DVD image.</desc>
7287 </attribute>
7288
7289 <attribute name="accessible" type="boolean" readonly="yes">
7290 <desc>
7291
7292 Whether the CD/DVD image is currently accessible or not.
7293 The image, for example, can be unaccessible if it is placed
7294 on a network share that is not available by the time
7295 this property is read.
7296
7297 The accessibility check is performed automatically every time
7298 this attribute is read. You should keep it in mind that this check
7299 may be slow and can block the calling thread for a long time (for
7300 example, if the network share where the image is located is down).
7301
7302 The following attributes of the image object are considered
7303 to be invalid when this attribute is <tt>false</tt>:
7304 <ul>
7305 <li><link to="#size"/></li>
7306 </ul>
7307
7308 </desc>
7309 </attribute>
7310
7311 <attribute name="size" type="unsigned long long" readonly="yes">
7312 <desc>Size of the ISO image in bytes.</desc>
7313 </attribute>
7314
7315 </interface>
7316
7317
7318 <!--
7319 // IDVDDrive
7320 /////////////////////////////////////////////////////////////////////////
7321 -->
7322
7323 <interface
7324 name="IDVDDrive" extends="$unknown"
7325 uuid="d9bd101a-8079-4fb9-bad1-31bf32482b75"
7326 wsmap="managed"
7327 >
7328 <desc>
7329 The IDVDDrive interface represents the virtual CD/DVD drive of the
7330 virtual machine. Used in <link to="IMachine::DVDDrive"/>.
7331 </desc>
7332 <attribute name="state" type="DriveState" readonly="yes">
7333 <desc>Current drive state.</desc>
7334 </attribute>
7335
7336 <attribute name="passthrough" type="boolean">
7337 <desc>
7338 When a host drive is mounted and passthrough is enabled
7339 the guest will be able to directly send SCSI commands to
7340 the host drive. This enables the guest to use CD/DVD writers
7341 but is potentially dangerous.
7342 </desc>
7343 </attribute>
7344
7345 <method name="mountImage">
7346 <desc>Mounts the specified image.</desc>
7347 <param name="imageId" type="uuid" dir="in"/>
7348 </method>
7349
7350 <method name="captureHostDrive">
7351 <desc>Captures the specified host drive.</desc>
7352 <param name="drive" type="IHostDVDDrive" dir="in"/>
7353 </method>
7354
7355 <method name="unmount">
7356 <desc>Unmounts the currently mounted image/device.</desc>
7357 </method>
7358
7359 <method name="getImage">
7360 <desc>Gets the currently mounted image ID.</desc>
7361 <param name="image" type="IDVDImage" dir="return"/>
7362 </method>
7363
7364 <method name="getHostDrive">
7365 <desc>Gets the currently mounted image ID.</desc>
7366 <param name="drive" type="IHostDVDDrive" dir="return"/>
7367 </method>
7368
7369 </interface>
7370
7371 <!--
7372 // IFloppyImage
7373 /////////////////////////////////////////////////////////////////////////
7374 -->
7375
7376 <enumerator
7377 name="IFloppyImageEnumerator" type="IFloppyImage"
7378 uuid="902C4089-76B7-41f1-91E8-49A261A28A2C"
7379 />
7380
7381 <collection
7382 name="IFloppyImageCollection" type="IFloppyImage"
7383 enumerator="IFloppyImageEnumerator"
7384 uuid="327A8928-8572-446e-AD9A-18FE30E81F3F"
7385 readonly="yes">
7386 <method name="findByPath">
7387 <desc>
7388 Searches this collection for a floppy image with the given disk path.
7389 <note>
7390 The method returns an error if the given name does not
7391 correspond to any floppy image in the collection.
7392 </note>
7393 </desc>
7394 <param name="path" type="wstring" dir="in">
7395 <desc>Name of the floppy image's file system location.</desc>
7396 </param>
7397 <param name="image" type="IFloppyImage" dir="return">
7398 <desc>Found Floppy image object</desc>
7399 </param>
7400 </method>
7401 </collection>
7402
7403 <interface
7404 name="IFloppyImage" extends="$unknown"
7405 uuid="CC696755-EA98-4ffe-9DC5-C003047034AB"
7406 wsmap="managed"
7407 >
7408 <desc>
7409
7410 The IFloppyImage interface represents a file containing the image
7411 of a floppy disk.
7412
7413 <h3>Image Accessibility</h3>
7414
7415 The <link to="#accessible"/> attribute of the image object
7416 defines the accessibility state of the image file. If the
7417 value of this attribute is <tt>false</tt> then some image
7418 attributes may contain invalid or outdated values (for example, the
7419 the image file size) until a new accessibility
7420 check is done that returns <tt>true</tt>.
7421
7422 <note>
7423 Because of the possible slowness of the accessibility check,
7424 it is not implicitly performed upon the VirtualBox server startup
7425 (to prevent the application freeze). In partcular, this means that
7426 if you try to read image properties that depend on the
7427 accessibility state without first reading the value of the
7428 <link to="#accessible"/> attribute and ensuring it's value is
7429 <tt>true</tt>, you will get wrong (zero) values.
7430 </note>
7431
7432 </desc>
7433 <attribute name="id" type="uuid" readonly="yes">
7434 <desc>UUID of the floppy image.</desc>
7435 </attribute>
7436
7437 <attribute name="filePath" type="wstring" readonly="yes">
7438 <desc>Full file name of the floppy image.</desc>
7439 </attribute>
7440
7441 <attribute name="accessible" type="boolean" readonly="yes">
7442 <desc>
7443
7444 Whether the floppy image is currently accessible or not.
7445 The image, for example, can be unaccessible if it is placed
7446 on a network share that is not available by the time
7447 this property is read.
7448
7449 The accessibility check is performed automatically every time
7450 this attribute is read. You should keep it in mind that this check
7451 may be slow and can block the calling thread for a long time (for
7452 example, if the network share where the image is located is down).
7453
7454 The following attributes of the image object are considered
7455 to be invalid when this attribute is <tt>false</tt>:
7456 <ul>
7457 <li><link to="#size"/></li>
7458 </ul>
7459
7460 </desc>
7461 </attribute>
7462
7463 <attribute name="size" type="unsigned long" readonly="yes">
7464 <desc>Size of the floppy image in bytes.</desc>
7465 </attribute>
7466
7467 </interface>
7468
7469
7470 <!--
7471 // IFloppyDrive
7472 /////////////////////////////////////////////////////////////////////////
7473 -->
7474
7475 <interface
7476 name="IFloppyDrive" extends="$unknown"
7477 uuid="E9318F71-78D2-4b00-863C-B7CB0030A2D9"
7478 wsmap="managed"
7479 >
7480 <desc>
7481 The IFloppyDrive interface represents the virtual floppy drive of the
7482 virtual machine. Used in <link to="IMachine::FloppyDrive" />.
7483 </desc>
7484
7485 <attribute name="enabled" type="boolean">
7486 <desc>
7487 Flag whether the floppy drive is enabled. If it is disabled,
7488 the floppy drive will not be reported to the guest.
7489 </desc>
7490 </attribute>
7491
7492 <attribute name="state" type="DriveState" readonly="yes">
7493 <desc>Current drive state.</desc>
7494 </attribute>
7495
7496 <method name="mountImage">
7497 <desc>Mounts the specified image.</desc>
7498 <param name="imageId" type="uuid" dir="in"/>
7499 </method>
7500
7501 <method name="captureHostDrive">
7502 <desc>Captures the specified host drive.</desc>
7503 <param name="drive" type="IHostFloppyDrive" dir="in"/>
7504 </method>
7505
7506 <method name="unmount">
7507 <desc>Unmounts the currently mounted image/device.</desc>
7508 </method>
7509
7510 <method name="getImage">
7511 <desc>Gets the currently mounted image ID.</desc>
7512 <param name="image" type="IFloppyImage" dir="return"/>
7513 </method>
7514
7515 <method name="getHostDrive">
7516 <desc>Gets the currently mounted image ID.</desc>
7517 <param name="drive" type="IHostFloppyDrive" dir="return"/>
7518 </method>
7519
7520 </interface>
7521
7522
7523 <!--
7524 // IKeyboard
7525 /////////////////////////////////////////////////////////////////////////
7526 -->
7527
7528 <interface
7529 name="IKeyboard" extends="$unknown"
7530 uuid="FD443EC1-000A-4F5B-9282-D72760A66916"
7531 wsmap="managed"
7532 >
7533 <desc>
7534 The IKeyboard interface represents the virtual machine's keyboard. Used
7535 in <link to="IConsole::keyboard"/>.
7536
7537 Through this interface, the virtual machine's virtual keyboard can be controlled. One
7538 can send keystrokes to the virtual machine and send the Ctrl-Alt-Del sequence to it.
7539 </desc>
7540 <method name="putScancode">
7541 <desc>Sends a scancode to the keyboard.</desc>
7542 <param name="scancode" type="long" dir="in"/>
7543 </method>
7544
7545 <method name="putScancodes">
7546 <desc>Sends an array of scancode to the keyboard.</desc>
7547 <param name="scancodes" type="long" dir="in" array="count"/>
7548 <param name="count" type="unsigned long" dir="in"/>
7549 <param name="codesStored" type="unsigned long" dir="return"/>
7550 </method>
7551
7552 <method name="putCAD">
7553 <desc>Sends the Ctrl-Alt-Del sequence to the keyboard.</desc>
7554 </method>
7555
7556 </interface>
7557
7558
7559 <!--
7560 // IMouse
7561 /////////////////////////////////////////////////////////////////////////
7562 -->
7563
7564 <enum
7565 name="MouseButtonState"
7566 uuid="03131722-2EC5-4173-9794-0DACA46673EF"
7567 >
7568 <desc>
7569 Mouse button state.
7570 </desc>
7571
7572 <const name="LeftButton" value="0x01"/>
7573 <const name="RightButton" value="0x02"/>
7574 <const name="MiddleButton" value="0x04"/>
7575 <const name="WheelUp" value="0x08"/>
7576 <const name="WheelDown" value="0x10"/>
7577 <const name="MouseStateMask" value="0x1F"/>
7578 </enum>
7579
7580 <interface
7581 name="IMouse" extends="$unknown"
7582 uuid="FD443EC1-0006-4F5B-9282-D72760A66916"
7583 wsmap="managed"
7584 >
7585 <desc>
7586 The IMouse interface represents the virtual machine's mouse. Used in
7587 <link to="IConsole::mouse"/>.
7588
7589 Through this interface, the virtual machine's virtual mouse can be
7590 controlled.
7591 </desc>
7592
7593 <attribute name="absoluteSupported" type="boolean" readonly="yes">
7594 <desc>
7595 Whether the guest OS supports absolute mouse pointer positioning
7596 or not.
7597 <note>
7598 VirtualBox Guest Tools need to be installed to the guest OS
7599 in order to enable absolute mouse positioning support.
7600 You can use the <link to="IConsoleCallback::onMouseCapabilityChange"/>
7601 callback to be instantly informed about changes of this attribute
7602 during virtual machine execution.
7603 </note>
7604 <see><link to="#putMouseEventAbsolute"/></see>
7605 </desc>
7606 </attribute>
7607
7608 <method name="putMouseEvent">
7609 <desc>
7610 Initiates a mouse event using relative pointer movements
7611 along x and y axis.
7612 </desc>
7613
7614 <param name="dx" type="long" dir="in">
7615 <desc>
7616 Amout of pixels the mouse should move to the right.
7617 Negative values move the mouse to the left.
7618 </desc>
7619 </param>
7620 <param name="dy" type="long" dir="in">
7621 <desc>
7622 Amout of pixels the mouse should move downwards.
7623 Negative values move the mouse upwards.
7624 </desc>
7625 </param>
7626 <param name="dz" type="long" dir="in">
7627 <desc>
7628 Amount of mouse wheel moves.
7629 Positive values describe clockwize wheel rotations,
7630 negative values describe counterclockwise rotations.
7631 </desc>
7632 </param>
7633 <param name="buttonState" type="long" dir="in">
7634 <desc>
7635 The current state of mouse buttons. Every bit represents
7636 a mouse button as follows:
7637 <table>
7638 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
7639 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
7640 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
7641 </table>
7642 A value of <tt>1</tt> means the corresponding button is pressed.
7643 otherwise it is released.
7644 </desc>
7645 </param>
7646 </method>
7647
7648 <method name="putMouseEventAbsolute">
7649 <desc>
7650 Positions the mouse pointer using absolute x and y coordinates.
7651 These coordinates are expressed in pixels and
7652 start from <tt>[1,1]</tt> which corresponds to the top left
7653 corner of the virtual display.
7654
7655 <note>
7656 This method will have effect only if absolute mouse
7657 positioning is supported by the guest OS.
7658 </note>
7659
7660 <see><link to="#absoluteSupported"/></see>
7661 </desc>
7662
7663 <param name="x" type="long" dir="in">
7664 <desc>
7665 X coordinate of the pointer in pixels, starting from <tt>1</tt>.
7666 </desc>
7667 </param>
7668 <param name="y" type="long" dir="in">
7669 <desc>
7670 Y coordinate of the pointer in pixels, starting from <tt>1</tt>.
7671 </desc>
7672 </param>
7673 <param name="dz" type="long" dir="in">
7674 <desc>
7675 Amout of mouse wheel moves.
7676 Positive values describe clockwize wheel rotations,
7677 negative values describe counterclockwise rotations.
7678 </desc>
7679 </param>
7680 <param name="buttonState" type="long" dir="in">
7681 <desc>
7682 The current state of mouse buttons. Every bit represents
7683 a mouse button as follows:
7684 <table>
7685 <tr><td>Bit 0 (<tt>0x01</tt>)</td><td>left mouse button</td></tr>
7686 <tr><td>Bit 1 (<tt>0x02</tt>)</td><td>right mouse button</td></tr>
7687 <tr><td>Bit 2 (<tt>0x04</tt>)</td><td>middle mouse button</td></tr>
7688 </table>
7689 A value of <tt>1</tt> means the corresponding button is pressed.
7690 otherwise it is released.
7691 </desc>
7692 </param>
7693 </method>
7694
7695 </interface>
7696
7697 <!--
7698 // IDisplay
7699 /////////////////////////////////////////////////////////////////////////
7700 -->
7701
7702 <enum
7703 name="FramebufferAccelerationOperation"
7704 uuid="f0e5ebbe-dc8e-4e2d-916e-53baa3844df8"
7705 >
7706 <desc>
7707 Framebuffer acceleration operation.
7708 </desc>
7709
7710 <const name="SolidFillAcceleration" value="1"/>
7711 <const name="ScreenCopyAcceleration" value="2"/>
7712 </enum>
7713
7714 <enum
7715 name="FramebufferPixelFormat"
7716 uuid="6b27d1fc-4f2c-4e9c-a166-01d06540305d"
7717 >
7718 <desc>
7719 Format of the video memory buffer. Constants represented by this enum can
7720 be used to test for particular values of <link
7721 to="IFramebuffer::pixelFormat"/>. See also <link
7722 to="IFramebuffer::requestResize()"/>.
7723
7724 See also www.fourcc.org for more informantion about FOURCC pixel formats.
7725 </desc>
7726
7727 <const name="Opaque" value="0xFFFFFFFF">
7728 <desc>
7729 Unknown buffer format. The user may not assume any particular
7730 format of the buffer.
7731 </desc>
7732 </const>
7733 <const name="FOURCC_RGB" value="0x32424752">
7734 <desc>
7735 Basic RGB format. <link to="IFramebuffer::bitsPerPixel"/> determines
7736 the bit layout.
7737 </desc>
7738 </const>
7739 </enum>
7740
7741 <interface
7742 name="IFramebuffer" extends="$unknown"
7743 uuid="af431304-5b09-40e2-94da-3c3cb03822c1"
7744 wsmap="suppress"
7745 >
7746 <attribute name="address" type="octet" mod="ptr" readonly="yes">
7747 <desc>Address of the start byte of the framebuffer.</desc>
7748 </attribute>
7749
7750 <attribute name="width" type="unsigned long" readonly="yes">
7751 <desc>Framebuffer width, in pixels.</desc>
7752 </attribute>
7753
7754 <attribute name="height" type="unsigned long" readonly="yes">
7755 <desc>Framebuffer height, in pixels.</desc>
7756 </attribute>
7757
7758 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
7759 <desc>
7760 Color depth, in bits per pixel. When <link to="#pixelFormat"/> is <link
7761 to="FramebufferPixelFormat::FOURCC_RGB">FOURCC_RGB</link>, valid values
7762 are: 8, 15, 16, 24 and 32.
7763 </desc>
7764 </attribute>
7765
7766 <attribute name="bytesPerLine" type="unsigned long" readonly="yes">
7767 <desc>
7768 Scan line size, in bytes. When <link to="#pixelFormat"/> is <link
7769 to="FramebufferPixelFormat::FOURCC_RGB">FOURCC_RGB</link>, the
7770 size of the scan line must be aligned to 32 bits.
7771 </desc>
7772 </attribute>
7773
7774 <attribute name="pixelFormat" type="unsigned long" readonly="yes">
7775 <desc>
7776 Framebuffer pixel format. It's either one of the values defined by <link
7777 to="FramebufferPixelFormat"/> or a raw FOURCC code.
7778 <note>
7779 This attribute must never return <link
7780 to="PixelFormat::Opaque"/> -- the format of the buffer
7781 <link to="#address"/> points to must be always known.
7782 </note>
7783 </desc>
7784 </attribute>
7785
7786 <attribute name="usesGuestVRAM" type="boolean" readonly="yes">
7787 <desc>
7788 Defines whether this framebuffer uses the virtual video card's memory
7789 buffer (guest VRAM) directly or not. See <link
7790 to="IFramebuffer::requestResize()"/> for more information.
7791 </desc>
7792 </attribute>
7793
7794 <attribute name="heightReduction" type="unsigned long" readonly="yes">
7795 <desc>
7796 Hint from the framebuffer about how much of the standard
7797 screen height it wants to use for itself. This information is
7798 exposed to the guest through the VESA BIOS and VMMDev interface
7799 so that it can use it for determining its video mode table. It
7800 is not guaranteed that the guest respects the value.
7801 </desc>
7802 </attribute>
7803
7804 <attribute name="overlay" type="IFramebufferOverlay" readonly="yes">
7805 <desc>
7806 An alpha-blended overlay which is superposed over the framebuffer.
7807 The initial purpose is to allow the display of icons providing
7808 information about the VM state, including disk activity, in front
7809 ends which do not have other means of doing that. The overlay is
7810 designed to controlled exclusively by IDisplay. It has no locking
7811 of its own, and any changes made to it are not guaranteed to be
7812 visible until the affected portion of IFramebuffer is updated. The
7813 overlay can be created lazily the first time it is requested. This
7814 attribute can also return NULL to signal that the overlay is not
7815 implemented.
7816 </desc>
7817 </attribute>
7818
7819 <method name="lock">
7820 <desc>
7821 Locks the framebuffer.
7822 Gets called by the IDisplay object where this framebuffer is
7823 bound to.
7824 </desc>
7825 </method>
7826
7827 <method name="unlock">
7828 <desc>
7829 Unlocks the framebuffer.
7830 Gets called by the IDisplay object where this framebuffer is
7831 bound to.
7832 </desc>
7833 </method>
7834
7835 <method name="notifyUpdate">
7836 <desc>
7837 Informs about an update.
7838 Gets called by the display object where this buffer is
7839 registered.
7840 </desc>
7841 <param name="x" type="unsigned long" dir="in"/>
7842 <param name="y" type="unsigned long" dir="in"/>
7843 <param name="width" type="unsigned long" dir="in"/>
7844 <param name="height" type="unsigned long" dir="in"/>
7845 <param name="finished" type="boolean" dir="return"/>
7846 </method>
7847
7848 <method name="requestResize">
7849 <desc>
7850 Requests a size and pixel format change.
7851
7852 There are two modes of working with the video buffer of the virtual
7853 machine. The <i>indirect</i> mode implies that the IFramebuffer
7854 implementation allocates a memory buffer for the requested display mode
7855 and provides it to the virtual machine. In <i>direct</i> mode, the
7856 IFramebuffer implementation uses the memory buffer allocated and owned
7857 by the virtual machine. This buffer represents the video memory of the
7858 emulated video adapter (so called <i>guest VRAM</i>). The direct mode is
7859 usually faster because the implementation gets a raw pointer to the
7860 guest VRAM buffer which it can directly use for visualising the contents
7861 of the virtual display, as opposed to the indirect mode where the
7862 contents of guest VRAM are copied to the memory buffer provided by
7863 the implementation every time a display update occurs.
7864
7865 It is important to note that the direct mode is really fast only when
7866 the implementation uses the given guest VRAM buffer directly, for
7867 example, by blitting it to the window representing the virtual machine's
7868 display, which saves at least one copy operation comparing to the
7869 indirect mode. However, using the guest VRAM buffer directly is not
7870 always possible: the format and the color depth of this buffer may be
7871 not supported by the target window, or it may be unknown (opaque) as in
7872 case of text or non-linear multi-plane VGA video modes. In this case,
7873 the indirect mode (that is always available) should be used as a
7874 fallback: when the guest VRAM contents are copied to the
7875 implementation-provided memory buffer, color and format conversion is
7876 done authomatically by the underlying code.
7877
7878 The @a pixelFormat parameter defines whether the direct mode is
7879 available or not. If @a pixelFormat is <link
7880 to="PixelFormat::Opaque"/> then direct access to the guest
7881 VRAM buffer is not available -- the @a VRAM, @a bitsPerPixel and @a
7882 bytesPerLine parameters must be ignored and the implementation must use
7883 the indirect mode (where it provides its own buffer in one of the
7884 supported formats). In all other cases, @a pixelFormat together with @a
7885 bitsPerPixel and @a bytesPerLine define the format of the video memory
7886 buffer pointed to by the @a VRAM parameter and the implementation is
7887 free to choose which mode to use. To indicate that this framebuffer uses
7888 the direct mode, the implementation of the <link to="#usesGuestVRAM"/>
7889 attribute must return <tt>true</tt> and <link to="#address"/> must
7890 return exactly the same address that is passed in the @a VRAM parameter
7891 of this method; otherwise it is assumed that the indirect strategy is
7892 chosen.
7893
7894 The @a width and @a height parameters represent the size of the
7895 requested display mode in both modes. In case of indirect mode, the
7896 provided memory buffer should be big enough to store data of the given
7897 display mode. In case of direct mode, it is guaranteed that the given @a
7898 VRAM buffer contains enough space to represent the display mode of the
7899 given size. Note that this framebuffer's <link to="#width"/> and <link
7900 to="#height"/> attributes must return exactly the same values as
7901 passed to this method after the resize is completed (see below).
7902
7903 The @a finished output parameter determines if the implementation has
7904 finished resizing the framebuffer or not. If, for some reason, the
7905 resize cannot be finished immediately during this call, @a finished
7906 must be set to @c false, and the implementation must call
7907 <link to="IDisplay::resizeCompleted()"/> after it has returned from
7908 this method as soon as possible. If @a finished is @c false, the
7909 machine will not call any framebuffer methods until
7910 <link to="IDisplay::resizeCompleted()"/> is called.
7911
7912 Note that if the direct mode is chosen, the <link to="#bitsPerPixel"/>,
7913 <link to="#bytesPerLine"/> and <link to="#pixelFormat"/> attributes of
7914 this framebuffer must return exactly the same values as specified in the
7915 parameters of this method, after the resize is completed. If the
7916 indirect mode is chosen, these attributes must return values describing
7917 the format of the implementation's own memory buffer <link
7918 to="#address"/> points to. Note also that the <link to="#bitsPerPixel"/>
7919 value must always correlate with <link to="#pixelFormat"/>. Note that
7920 the <link to="#pixelFormat"/> attribute must never return <link
7921 to="PixelFormat::Opaque"/> regardless of the selected mode.
7922
7923 <note>
7924 This method is called by the IDisplay object under the
7925 <link to="#lock()"/> provided by this IFramebuffer
7926 implementation. If this method returns @c false in @a finished, then
7927 this lock is not released until
7928 <link to="IDisplay::resizeCompleted()"/> is called.
7929 </note>
7930 </desc>
7931 <param name="screenId" type="unsigned long" dir="in">
7932 <desc>
7933 Logical screen number. Must be used in the corresponding call to
7934 <link to="IDisplay::resizeCompleted()"/> if this call is made.
7935 </desc>
7936 </param>
7937 <param name="pixelFormat" type="unsigned long" dir="in">
7938 <desc>
7939 Pixel format of the memory buffer pointed to by @a VRAM.
7940 See also <link to="FramebufferPixelFormat"/>.
7941 </desc>
7942 </param>
7943 <param name="VRAM" type="octet" mod="ptr" dir="in">
7944 <desc>Pointer to the virtual video card's VRAM (may be @c null).</desc>
7945 </param>
7946 <param name="bitsPerPixel" type="unsigned long" dir="in">
7947 <desc>Color depth, bits per pixel.</desc>
7948 </param>
7949 <param name="bytesPerLine" type="unsigned long" dir="in">
7950 <desc>Size of one scan line, in bytes.</desc>
7951 </param>
7952 <param name="width" type="unsigned long" dir="in">
7953 <desc>Width of the guest display, in pixels.</desc>
7954 </param>
7955 <param name="height" type="unsigned long" dir="in">
7956 <desc>Height of the guest display, in pixels.</desc>
7957 </param>
7958 <param name="finished" type="boolean" dir="return">
7959 <desc>
7960 Can the VM start using the new framebuffer immediately
7961 after this method returns or it should wait for
7962 <link to="IDisplay::resizeCompleted()"/>.
7963 </desc>
7964 </param>
7965 </method>
7966
7967 <method name="operationSupported">
7968 <desc>
7969 Returns whether the given acceleration operation is supported
7970 by the IFramebuffer implementation. If not, the display object
7971 will not attempt to call the corresponding IFramebuffer entry
7972 point. Even if an operation is indicated to supported, the
7973 IFramebuffer implementation always has the option to return non
7974 supported from the corresponding acceleration method in which
7975 case the operation will be performed by the display engine. This
7976 allows for reduced IFramebuffer implementation complexity where
7977 only common cases are handled.
7978 </desc>
7979 <param name="operation" type="FramebufferAccelerationOperation" dir="in"/>
7980 <param name="supported" type="boolean" dir="return"/>
7981 </method>
7982
7983 <method name="videoModeSupported">
7984 <desc>
7985 Returns whether the framebuffer implementation is willing to
7986 support a given video mode. In case it is not able to render
7987 the video mode (or for some reason not willing), it should
7988 return false. Usually this method is called when the guest
7989 asks the VMM device whether a given video mode is supported
7990 so the information returned is directly exposed to the guest.
7991 It is important that this method returns very quickly.
7992 </desc>
7993 <param name="width" type="unsigned long" dir="in"/>
7994 <param name="height" type="unsigned long" dir="in"/>
7995 <param name="bpp" type="unsigned long" dir="in"/>
7996 <param name="supported" type="boolean" dir="return"/>
7997 </method>
7998
7999 <method name="solidFill">
8000 <desc>
8001 Fills the specified rectangle on screen with a solid color.
8002 </desc>
8003 <param name="x" type="unsigned long" dir="in"/>
8004 <param name="y" type="unsigned long" dir="in"/>
8005 <param name="width" type="unsigned long" dir="in"/>
8006 <param name="height" type="unsigned long" dir="in"/>
8007 <param name="color" type="unsigned long" dir="in"/>
8008 <param name="handled" type="boolean" dir="return"/>
8009 </method>
8010
8011 <method name="copyScreenBits">
8012 <desc>
8013 Copies specified rectangle on the screen.
8014 </desc>
8015 <param name="xDst" type="unsigned long" dir="in"/>
8016 <param name="yDst" type="unsigned long" dir="in"/>
8017 <param name="xSrc" type="unsigned long" dir="in"/>
8018 <param name="ySrc" type="unsigned long" dir="in"/>
8019 <param name="width" type="unsigned long" dir="in"/>
8020 <param name="height" type="unsigned long" dir="in"/>
8021 <param name="handled" type="boolean" dir="return"/>
8022 </method>
8023
8024 <method name="getVisibleRegion">
8025 <desc>
8026 Returns the visible region of this framebuffer.
8027
8028 If the @a rectangles parameter is <tt>NULL</tt> then the value of the
8029 @a count parameter is ignored and the number of elements necessary to
8030 describe the current visible region is returned in @a countCopied.
8031
8032 If @a rectangles is not <tt>NULL</tt> but @a count is less
8033 than the required number of elements to store region data, the method
8034 will report a failure. If @a count is equal or greater than the
8035 required number of elements, then the actual number of elements copied
8036 to the provided array will be returned in @a countCopied.
8037
8038 <note>
8039 The address of the provided array must be in the process space of
8040 this IFramebuffer object.
8041 </note>
8042 </desc>
8043 <param name="rectangles" type="octet" mod="ptr" dir="in">
8044 <desc>Pointer to the <tt>RTRECT</tt> array to receive region data.</desc>
8045 </param>
8046 <param name="count" type="unsigned long" dir="in">
8047 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
8048 </param>
8049 <param name="countCopied" type="unsigned long" dir="return">
8050 <desc>Number of elements copied to the @a rectangles array.</desc>
8051 </param>
8052 </method>
8053
8054 <method name="setVisibleRegion">
8055 <desc>
8056 Suggests a new visible region to this framebuffer. This region
8057 represents the area of the VM display which is a union of regions of
8058 all top-level windows of the guest operating system running inside the
8059 VM (if the Guest Additions for this system support this
8060 functionality). This information may be used by the frontends to
8061 implement the seamless desktop integration feature.
8062
8063 <note>
8064 The address of the provided array must be in the process space of
8065 this IFramebuffer object.
8066 </note>
8067 <note>
8068 The IFramebuffer implementation must make a copy of the provided
8069 array of rectangles.
8070 </note>
8071 </desc>
8072 <param name="rectangles" type="octet" mod="ptr" dir="in">
8073 <desc>Pointer to the <tt>RTRECT</tt> array.</desc>
8074 </param>
8075 <param name="count" type="unsigned long" dir="in">
8076 <desc>Number of <tt>RTRECT</tt> elements in the @a rectangles array.</desc>
8077 </param>
8078 </method>
8079
8080 </interface>
8081
8082 <interface
8083 name="IFramebufferOverlay" extends="IFrameBuffer"
8084 uuid="0bcc1c7e-e415-47d2-bfdb-e4c705fb0f47"
8085 wsmap="suppress"
8086 >
8087 <desc>
8088 The IFramebufferOverlay interface represents an alpha blended overlay
8089 for displaying status icons above an IFramebuffer. It is always created
8090 not visible, so that it must be explicitly shown. It only covers a
8091 portion of the IFramebuffer, determined by its width, height and
8092 co-ordinates. It is always in packed pixel little-endian 32bit ARGB (in
8093 that order) format, and may be written to directly. Do re-read the
8094 width though, after setting it, as it may be adjusted (increased) to
8095 make it more suitable for the front end.
8096 </desc>
8097 <attribute name="x" type="unsigned long" readonly="yes">
8098 <desc>X position of the overlay, relative to the framebuffer.</desc>
8099 </attribute>
8100
8101 <attribute name="y" type="unsigned long" readonly="yes">
8102 <desc>Y position of the overlay, relative to the framebuffer.</desc>
8103 </attribute>
8104
8105 <attribute name="visible" type="boolean" readonly="no">
8106 <desc>
8107 Whether the overlay is currently visible.
8108 </desc>
8109 </attribute>
8110
8111 <attribute name="alpha" type="unsigned long" readonly="no">
8112 <desc>
8113 The global alpha value for the overlay. This may or may not be
8114 supported by a given front end.
8115 </desc>
8116 </attribute>
8117
8118 <method name="move">
8119 <desc>
8120 Changes the overlay's position relative to the IFramebuffer.
8121 </desc>
8122 <param name="x" type="unsigned long" dir="in"/>
8123 <param name="y" type="unsigned long" dir="in"/>
8124 </method>
8125
8126 </interface>
8127
8128 <interface
8129 name="IDisplay" extends="$unknown"
8130 uuid="09789f63-4525-48e5-a5e4-1080453b0eab"
8131 wsmap="suppress"
8132 >
8133 <desc>
8134 The IDisplay interface represents the virtual machine's display.
8135
8136 The object implementing this interface is contained in each
8137 <link to="IConsole::display"/> attribute and represents the visual
8138 output of the virtual machine.
8139
8140 The virtual display supports pluggable output targets represented by the
8141 IFramebuffer interface. Examples of the output target are a window on
8142 the host computer or an RDP sessoin's display on a remote computer.
8143 </desc>
8144 <attribute name="width" type="unsigned long" readonly="yes">
8145 <desc>Current display width.</desc>
8146 </attribute>
8147
8148 <attribute name="height" type="unsigned long" readonly="yes">
8149 <desc>Current display height.</desc>
8150 </attribute>
8151
8152 <attribute name="bitsPerPixel" type="unsigned long" readonly="yes">
8153 <desc>
8154 Current guest display color depth. Note that this may differ
8155 from <link to="IFramebuffer::bitsPerPixel"/>.
8156 </desc>
8157 </attribute>
8158
8159 <method name="setupInternalFramebuffer">
8160 <desc>
8161 Prepares an internally managed framebuffer.
8162 </desc>
8163 <param name="depth" type="unsigned long" dir="in"/>
8164 </method>
8165
8166 <method name="lockFramebuffer">
8167 <desc>
8168 Requests access to the internal framebuffer.
8169 </desc>
8170 <param name="address" type="octet" mod="ptr" dir="return"/>
8171 </method>
8172
8173 <method name="unlockFramebuffer">
8174 <desc>
8175 Releases access to the internal framebuffer.
8176 </desc>
8177 </method>
8178
8179 <method name="registerExternalFramebuffer">
8180 <desc>
8181 Registers an external framebuffer.
8182 </desc>
8183 <param name="framebuffer" type="IFramebuffer" dir="in"/>
8184 </method>
8185
8186 <method name="setFramebuffer">
8187 <desc>
8188 Sets the framebuffer for given screen.
8189 </desc>
8190 <param name="screenId" type="unsigned long" dir="in"/>
8191 <param name="framebuffer" type="IFramebuffer" dir="in"/>
8192 </method>
8193
8194 <method name="getFramebuffer">
8195 <desc>
8196 Queries the framebuffer for given screen.
8197 </desc>
8198 <param name="screenId" type="unsigned long" dir="in"/>
8199 <param name="framebuffer" type="IFramebuffer" dir="out"/>
8200 <param name="xOrigin" type="long" dir="out"/>
8201 <param name="yOrigin" type="long" dir="out"/>
8202 </method>
8203
8204 <method name="setVideoModeHint">
8205 <desc>
8206 Asks VirtualBox to request the given video mode from
8207 the guest. This is just a hint and it cannot be guaranteed
8208 that the requested resolution will be used. Guest Additions
8209 are required for the request to be seen by guests. The caller
8210 should issue the request and wait for a resolution change and
8211 after a timeout retry.
8212
8213 Specifying <tt>0</tt> for either @a width, @a height or @a bitsPerPixel
8214 parameters means that the corresponding values should be taken from the
8215 current video mode (i.e. left unchanged).
8216
8217 If the guest OS supports multi-monitor configuration then the @a display
8218 parameter specifies the number of the guest display to send the hint to:
8219 <tt>0</tt> is the primary display, <tt>1</tt> is the first secondary and
8220 so on. If the multi-monitor configuration is not supported, @a display
8221 must be <tt>0</tt>.
8222
8223 </desc>
8224 <param name="width" type="unsigned long" dir="in"/>
8225 <param name="height" type="unsigned long" dir="in"/>
8226 <param name="bitsPerPixel" type="unsigned long" dir="in"/>
8227 <param name="display" type="unsigned long" dir="in"/>
8228 </method>
8229
8230 <method name="setSeamlessMode">
8231 <desc>
8232 Enables or disables seamless guest display rendering (seamless desktop
8233 integration) mode.
8234 <note>
8235 Calling this method has no effect if <link
8236 to="IGuest::supportsSeamless"/> returns <tt>false</tt>.
8237 </note>
8238 </desc>
8239 <param name="enabled" type="boolean" dir="in"/>
8240 </method>
8241
8242 <method name="takeScreenShot">
8243 <desc>
8244 Takes a screen shot of the requested size and copies it to the
8245 32-bpp buffer allocated by the caller.
8246 </desc>
8247 <param name="address" type="octet" mod="ptr" dir="in"/>
8248 <param name="width" type="unsigned long" dir="in"/>
8249 <param name="height" type="unsigned long" dir="in"/>
8250 </method>
8251
8252 <method name="drawToScreen">
8253 <desc>
8254 Draws a 32-bpp image of the specified size from the given buffer
8255 to the given point on the VM display.
8256 </desc>
8257 <param name="address" type="octet" mod="ptr" dir="in"/>
8258 <param name="x" type="unsigned long" dir="in"/>
8259 <param name="y" type="unsigned long" dir="in"/>
8260 <param name="width" type="unsigned long" dir="in"/>
8261 <param name="height" type="unsigned long" dir="in"/>
8262 </method>
8263
8264 <method name="invalidateAndUpdate">
8265 <desc>
8266 Does a full invalidation of the VM display and instructs the VM
8267 to update it.
8268 </desc>
8269 </method>
8270
8271 <method name="resizeCompleted">
8272 <desc>
8273 Signals that a framebuffer has completed the resize operation.
8274 </desc>
8275 <param name="screenId" type="unsigned long" dir="in"/>
8276 </method>
8277
8278 <method name="updateCompleted">
8279 <desc>
8280 Signals that a framebuffer has completed the update operation.
8281 </desc>
8282 </method>
8283
8284 </interface>
8285
8286 <!--
8287 // INetworkAdapter
8288 /////////////////////////////////////////////////////////////////////////
8289 -->
8290
8291 <enum
8292 name="NetworkAttachmentType"
8293 uuid="8730d899-d036-4925-bc63-e58f3486f4bf"
8294 >
8295 <desc>
8296 Network attachment type.
8297 </desc>
8298
8299 <const name="Null" value="0">
8300 <desc><tt>null</tt> value. Also means "not attached".</desc>
8301 </const>
8302 <const name="NAT" value="1"/>
8303 <const name="HostInterface" value="2"/>
8304 <const name="Internal" value="3"/>
8305 </enum>
8306
8307 <enum
8308 name="NetworkAdapterType"
8309 uuid="156b17b9-5d61-4d54-be90-62e37dda848d"
8310 >
8311 <desc>
8312 Network adapter type.
8313 </desc>
8314
8315 <const name="Null" value="0">
8316 <desc><tt>null</tt> value. Never used by the API.</desc>
8317 </const>
8318 <const name="Am79C970A" value="1"/>
8319 <const name="Am79C973" value="2"/>
8320 <const name="I82540EM" value="3"/>
8321 <const name="I82543GC" value="4"/>
8322 </enum>
8323
8324 <interface
8325 name="INetworkAdapter" extends="$unknown"
8326 uuid="a876d9b1-68d9-43b1-9c68-ddea0a473663"
8327 wsmap="managed"
8328 >
8329 <attribute name="adapterType" type="NetworkAdapterType">
8330 <desc>
8331 Type of the virtual network adapter. Depending on this value,
8332 VirtualBox will provide a different virtual network hardware
8333 to the guest.
8334 </desc>
8335 </attribute>
8336
8337 <attribute name="slot" type="unsigned long" readonly="yes">
8338 <desc>
8339 Slot number this adapter is plugged into. Corresponds to
8340 the value you pass to <link to="IMachine::getNetworkAdapter"/>
8341 to obtain this instance.
8342 </desc>
8343 </attribute>
8344
8345 <attribute name="enabled" type="boolean">
8346 <desc>
8347 Flag whether the network adapter is present in the
8348 guest system. If disabled, the virtual guest hardware will
8349 not contain this network adapter. Can only be changed when
8350 the VM is not running.
8351 </desc>
8352 </attribute>
8353
8354 <attribute name="MACAddress" type="wstring">
8355 <desc>
8356 Ethernet MAC address of the adapter, 12 hexadecimal characters. When setting
8357 it to NULL, VirtualBox will generate a unique MAC address.
8358 </desc>
8359 </attribute>
8360
8361 <attribute name="attachmentType" type="NetworkAttachmentType" readonly="yes"/>
8362
8363 <attribute name="hostInterface" type="wstring">
8364 <desc>
8365 Name of the Host Network Interface that is currently in use. NULL will be returned
8366 if no device has been allocated. On Linux, setting this refers to a permanent TAP
8367 device. However, a file descriptor has precedence over the interface name on Linux.
8368 Note that when VBox allocates a TAP device, this property will not be set, i.e. the
8369 interface name would have to be determined using the file descriptor and /proc/self/fd.
8370 </desc>
8371 </attribute>
8372
8373<if target="xpidl">
8374 <attribute name="TAPFileDescriptor" type="long">
8375 <desc>
8376 File descriptor of the TAP device. It can either be setup by the caller
8377 which has to supply an existing valid file handle allocated in the parent
8378 process of the VM process or allocated by VirtualBox. The value is -1 if it
8379 has not been defined. This property is non persistent, i.e. it will not be
8380 stored in the VM's configuration data and thus has to be set at each startup.
8381 </desc>
8382 </attribute>
8383 <attribute name="TAPSetupApplication" type="wstring">
8384 <desc>
8385 Application to start to configure the TAP device.
8386 It is being passed two parameters, 1) the file handle (as ascii),
8387 2) the TAP device name if it is available.
8388 </desc>
8389 </attribute>
8390 <attribute name="TAPTerminateApplication" type="wstring">
8391 <desc>
8392 Application to start before closing a TAP device.
8393 It is being passed two parameters, 1) the file handle (as ascii),
8394 2) the TAP device name if it is available.
8395 </desc>
8396 </attribute>
8397</if>
8398
8399 <attribute name="internalNetwork" type="wstring">
8400 <desc>
8401 Name of the internal network the VM is attached to.
8402 </desc>
8403 </attribute>
8404
8405 <attribute name="NATNetwork" type="wstring">
8406 <desc>
8407 Name of the NAT network the VM is attached to.
8408 </desc>
8409 </attribute>
8410
8411 <attribute name="cableConnected" type="boolean">
8412 <desc>
8413 Flag whether the adapter reports the cable as connected or not.
8414 It can be used to report offline situations to a VM.
8415 </desc>
8416 </attribute>
8417
8418 <attribute name="lineSpeed" type="unsigned long">
8419 <desc>
8420 Line speed reported by custom drivers, in units of 1 kbps.
8421 </desc>
8422 </attribute>
8423
8424 <attribute name="traceEnabled" type="boolean">
8425 <desc>
8426 Flag whether network traffic from/to the network card should be traced.
8427 Can only be toggled when the VM is turned off.
8428 </desc>
8429 </attribute>
8430
8431 <attribute name="traceFile" type="wstring">
8432 <desc>
8433 Filename where a network trace will be stored. If not set, VBox-pid.pcap
8434 will be used.
8435 </desc>
8436 </attribute>
8437
8438 <method name="attachToNAT">
8439 <desc>
8440 Attach the network adapter to the Network Address Translation (NAT) interface.
8441 </desc>
8442 </method>
8443
8444 <method name="attachToHostInterface">
8445 <desc>
8446 Attach the network adapter to a host interface. On Linux, the TAP
8447 setup application will be executed if configured and unless a device
8448 name and/or file descriptor has been set, a new TAP interface will be
8449 created.
8450 </desc>
8451 </method>
8452
8453 <method name="attachToInternalNetwork">
8454 <desc>
8455 Attach the network adapter to an internal network.
8456 </desc>
8457 </method>
8458
8459 <method name="detach">
8460 <desc>
8461 Detach the network adapter
8462 </desc>
8463 </method>
8464 </interface>
8465
8466
8467 <!--
8468 // ISerialPort
8469 /////////////////////////////////////////////////////////////////////////
8470 -->
8471
8472 <enum
8473 name="PortMode"
8474 uuid="b266f43c-2e93-46b3-812b-c20e600e867b"
8475 >
8476 <desc>
8477 The PortMode enumeration represents possible communicaton modes for
8478 the virtual serial port device.
8479 </desc>
8480
8481 <const name="Disconnected" value="0">
8482 <desc>Virtual device is not attached to any real host device.</desc>
8483 </const>
8484 <const name="HostPipe" value="1">
8485 <desc>Virtual device is attached to a host pipe.</desc>
8486 </const>
8487 <const name="HostDevice" value="2">
8488 <desc>Virtual device is attached to a host device.</desc>
8489 </const>
8490 </enum>
8491
8492 <interface
8493 name="ISerialPort" extends="$unknown"
8494 uuid="937f6970-5103-4745-b78e-d28dcf1479a8"
8495 wsmap="managed"
8496 >
8497
8498 <desc>
8499 The ISerialPort interface represents the virtual serial port device.
8500
8501 The virtual serial port device acts like an ordinary serial port
8502 inside the virtual machine. This device communicates to the real
8503 serial port hardware in one of two modes: host pipe or host device.
8504
8505 In host pipe mode, the #path attribute specifies the path to the pipe on
8506 the host computer that represents a serial port. The #server attribute
8507 determines if this pipe is created by the virtual machine process at
8508 machine startup or it must already exist before starting machine
8509 execution.
8510
8511 In host device mode, the #path attribute specifies the name of the
8512 serial port device on the host computer.
8513
8514 There is also a third communication mode: the disconnected mode. In this
8515 mode, the guest OS running inside the virtual machine will be able to
8516 detect the serial port, but all port write operations will be discarded
8517 and all port read operations will return no data.
8518
8519 <see>IMachine::getSerialPort</see>
8520 </desc>
8521
8522 <attribute name="slot" type="unsigned long" readonly="yes">
8523 <desc>
8524 Slot number this serial port is plugged into. Corresponds to
8525 the value you pass to <link to="IMachine::getSerialPort"/>
8526 to obtain this instance.
8527 </desc>
8528 </attribute>
8529
8530 <attribute name="enabled" type="boolean">
8531 <desc>
8532 Flag whether the serial port is enabled. If disabled,
8533 the serial port will not be reported to the guest OS.
8534 </desc>
8535 </attribute>
8536
8537 <attribute name="IOBase" type="unsigned long">
8538 <desc>Base I/O address of the serial port.</desc>
8539 </attribute>
8540
8541 <attribute name="IRQ" type="unsigned long">
8542 <desc>IRQ number of the serial port.</desc>
8543 </attribute>
8544
8545 <attribute name="hostMode" type="PortMode">
8546 <desc>How is this port connected to the host.</desc>
8547 </attribute>
8548
8549 <attribute name="server" type="boolean">
8550 <desc>
8551 Flag whether this serial port acts as a server (creates a new pipe on
8552 the host) or as a client (uses the existing pipe). This attribute is
8553 used only when #hostMode is PortMode::HostPipePort.
8554 </desc>
8555 </attribute>
8556
8557 <attribute name="path" type="wstring">
8558 <desc>
8559 Path to the serial port's pipe on the host when #hostMode is
8560 PortMode::HostPipePort, or the host serial device name when #hostMode
8561 is PortMode::HostDevicePort. In either of the above cases, setting a
8562 @c null or an empty string as the attribute's value will result into
8563 an error. Otherwise, the value of this property is ignored.
8564 </desc>
8565 </attribute>
8566
8567 </interface>
8568
8569 <!--
8570 // IParallelPort
8571 /////////////////////////////////////////////////////////////////////////
8572 -->
8573
8574 <interface
8575 name="IParallelPort" extends="$unknown"
8576 uuid="0c925f06-dd10-4b77-8de8-294d738c3214"
8577 wsmap="managed"
8578 >
8579
8580 <desc>
8581 The IParallelPort interface represents the virtual parallel port device.
8582
8583 The virtual parallel port device acts like an ordinary parallel port
8584 inside the virtual machine. This device communicates to the real
8585 parallel port hardware using the name of the parallel device on the host
8586 computer specified in the #path attribute.
8587
8588 Each virtual parallel port device is assigned a base I/O address and an
8589 IRQ number that will be reported to the guest operating system and used
8590 to operate the given parallel port from within the virtual machine.
8591
8592 <see>IMachine::getParallelPort</see>
8593 </desc>
8594
8595 <attribute name="slot" type="unsigned long" readonly="yes">
8596 <desc>
8597 Slot number this parallel port is plugged into. Corresponds to
8598 the value you pass to <link to="IMachine::getParallelPort"/>
8599 to obtain this instance.
8600 </desc>
8601 </attribute>
8602
8603 <attribute name="enabled" type="boolean">
8604 <desc>
8605 Flag whether the parallel port is enabled. If disabled,
8606 the parallel port will not be reported to the guest OS.
8607 </desc>
8608 </attribute>
8609
8610 <attribute name="IOBase" type="unsigned long">
8611 <desc>Base I/O address of the parallel port.</desc>
8612 </attribute>
8613
8614 <attribute name="IRQ" type="unsigned long">
8615 <desc>IRQ number of the parallel port.</desc>
8616 </attribute>
8617
8618 <attribute name="path" type="wstring">
8619 <desc>
8620 Host parallel device name. If this parallel port is enabled, setting a
8621 @c null or an empty string as this attribute's value will result into
8622 an error.
8623 </desc>
8624 </attribute>
8625
8626 </interface>
8627
8628
8629 <!--
8630 // IMachineDebugger
8631 /////////////////////////////////////////////////////////////////////////
8632 -->
8633
8634 <interface
8635 name="IMachineDebugger" extends="$unknown"
8636 uuid="b3a02721-556a-4481-9d47-052a3f8cff90"
8637 wsmap="suppress"
8638 >
8639 <method name="resetStats">
8640 <desc>
8641 Reset VM statistics.
8642 </desc>
8643 <param name="pattern" type="wstring" dir="in">
8644 <desc>The selection pattern. A bit similar to filename globbing.</desc>
8645 </param>
8646 </method>
8647
8648 <method name="dumpStats">
8649 <desc>
8650 Dumps VM statistics.
8651 </desc>
8652 <param name="pattern" type="wstring" dir="in">
8653 <desc>The selection pattern. A bit similar to filename globbing.</desc>
8654 </param>
8655 </method>
8656
8657 <method name="getStats">
8658 <desc>
8659 Get the VM statistics in a XMLish format.
8660 </desc>
8661 <param name="pattern" type="wstring" dir="in">
8662 <desc>The selection pattern. A bit similar to filename globbing.</desc>
8663 </param>
8664 <param name="withDescriptions" type="boolean" dir="in">
8665 <desc>Whether to include the descriptions.</desc>
8666 </param>
8667 <param name="stats" type="wstring" dir="out">
8668 <desc>The XML document containing the statistics.</desc>
8669 </param>
8670 </method>
8671
8672 <attribute name="singlestep" type="boolean">
8673 <desc>Switch for enabling singlestepping.</desc>
8674 </attribute>
8675
8676 <attribute name="recompileUser" type="boolean">
8677 <desc>Switch for forcing code recompilation for user mode code.</desc>
8678 </attribute>
8679
8680 <attribute name="recompileSupervisor" type="boolean">
8681 <desc>Switch for forcing code recompilation for supervisor mode code.</desc>
8682 </attribute>
8683
8684 <attribute name="PATMEnabled" type="boolean">
8685 <desc>Switch for enabling and disabling the PATM component.</desc>
8686 </attribute>
8687
8688 <attribute name="CSAMEnabled" type="boolean">
8689 <desc>Switch for enabling and disabling the CSAM component.</desc>
8690 </attribute>
8691
8692 <attribute name="logEnabled" type="boolean">
8693 <desc>Switch for enabling and disabling logging.</desc>
8694 </attribute>
8695
8696 <attribute name="HWVirtExEnabled" type="boolean" readonly="yes">
8697 <desc>
8698 Flag indicating whether the VM is currently making use of CPU hardware
8699 virtualization extensions
8700 </desc>
8701 </attribute>
8702
8703 <attribute name="PAEEnabled" type="boolean" readonly="yes">
8704 <desc>
8705 Flag indicating whether the VM is currently making use of the Physical
8706 Address Extension CPU feature.
8707 </desc>
8708 </attribute>
8709
8710 <attribute name="virtualTimeRate" type="unsigned long">
8711 <desc>
8712 The rate at which the virtual time runs expressed as a percentage.
8713 The accepted range is 2% to 20000%.
8714 </desc>
8715 </attribute>
8716
8717 <!-- @todo method for setting log flags, groups and destination! -->
8718
8719 <attribute name="VM" type="unsigned long long" readonly="yes">
8720 <desc>
8721 Gets the VM handle. This is only for internal use while
8722 we carve the details of this interface.
8723 </desc>
8724 </attribute>
8725
8726 </interface>
8727
8728 <!--
8729 // IUSBController
8730 /////////////////////////////////////////////////////////////////////////
8731 -->
8732
8733 <interface
8734 name="IUSBController" extends="$unknown"
8735 uuid="f4c2d3dc-f109-4da7-93b1-ec28973ac89f"
8736 wsmap="managed"
8737 >
8738 <attribute name="enabled" type="boolean">
8739 <desc>
8740 Flag whether the USB controller is present in the
8741 guest system. If disabled, the virtual guest hardware will
8742 not contain any USB controller. Can only be changed when
8743 the VM is powered off.
8744 </desc>
8745 </attribute>
8746
8747 <attribute name="enabledEhci" type="boolean">
8748 <desc>
8749 Flag whether the USB EHCI controller is present in the
8750 guest system. If disabled, the virtual guest hardware will
8751 not contain a USB EHCI controller. Can only be changed when
8752 the VM is powered off.
8753 </desc>
8754 </attribute>
8755
8756 <attribute name="USBStandard" type="unsigned short" readonly="yes">
8757 <desc>
8758 USB standard version which the controller implements.
8759 This is a BCD which means that the major version is in the
8760 high byte and minor version is in the low byte.
8761 </desc>
8762 </attribute>
8763
8764 <attribute name="deviceFilters" type="IUSBDeviceFilterCollection" readonly="yes">
8765 <desc>
8766 List of USB device filters associated with the machine.
8767
8768 If the machine is currently running, these filters are activated
8769 every time a new (supported) USB device is attached to the host
8770 computer that was not ignored by global filters
8771 (<link to="IHost::USBDeviceFilters"/>).
8772
8773 These filters are also activated when the machine is powered up.
8774 They are run against a list of all currently available USB
8775 devices (in states
8776 <link to="USBDeviceState::Available">Available</link>,
8777 <link to="USBDeviceState::Busy">Busy</link>,
8778 <link to="USBDeviceState::Held">Held</link>) that were not previously
8779 ignored by global filters.
8780
8781 If at least one filter matches the USB device in question, this
8782 device is automatically captured (attached to) the virtual USB
8783 controller of this machine.
8784
8785 <see>IUSBDeviceFilter, ::IUSBController</see>
8786 </desc>
8787 </attribute>
8788
8789 <method name="createDeviceFilter">
8790 <desc>
8791 Creates a new USB device filter. All attributes except
8792 the filter name are set to <tt>null</tt> (any match),
8793 <i>active</i> is <tt>false</tt> (the filter is not active).
8794
8795 The created filter can then be added to the list of filters using
8796 <link to="#insertDeviceFilter()"/>.
8797
8798 <see>#deviceFilters</see>
8799 </desc>
8800 <param name="name" type="wstring" dir="in">
8801 <desc>
8802 Filter name. See <link to="IUSBDeviceFilter::name"/>
8803 for more info.
8804 </desc>
8805 </param>
8806 <param name="filter" type="IUSBDeviceFilter" dir="return">
8807 <desc>Created filter object.</desc>
8808 </param>
8809 </method>
8810
8811 <method name="insertDeviceFilter">
8812 <desc>
8813 Inserts the given USB device to the specified position
8814 in the list of filters.
8815
8816 Positions are numbered starting from <tt>0</tt>. If the specified
8817 position is equal to or greater than the number of elements in
8818 the list, the filter is added to the end of the collection.
8819
8820 <note>
8821 Duplicates are not allowed, so an attempt to inster a
8822 filter that is already in the collection, will return an
8823 error.
8824 </note>
8825
8826 <see>#deviceFilters</see>
8827 </desc>
8828 <param name="position" type="unsigned long" dir="in">
8829 <desc>Position to insert the filter to.</desc>
8830 </param>
8831 <param name="filter" type="IUSBDeviceFilter" dir="in">
8832 <desc>USB device filter to insert.</desc>
8833 </param>
8834 </method>
8835
8836 <method name="removeDeviceFilter">
8837 <desc>
8838 Removes a USB device filter from the specified position in the
8839 list of filters.
8840
8841 Positions are numbered starting from <tt>0</tt>. Specifying a
8842 position equal to or greater than the number of elements in
8843 the list will produce an error.
8844
8845 <see>#deviceFilters</see>
8846 </desc>
8847 <param name="position" type="unsigned long" dir="in">
8848 <desc>Position to remove the filter from.</desc>
8849 </param>
8850 <param name="filter" type="IUSBDeviceFilter" dir="return">
8851 <desc>Removed USB device filter.</desc>
8852 </param>
8853 </method>
8854
8855 </interface>
8856
8857
8858 <!--
8859 // IUSBDevice
8860 /////////////////////////////////////////////////////////////////////////
8861 -->
8862
8863 <enumerator
8864 name="IUSBDeviceEnumerator" type="IUSBDevice"
8865 uuid="aefe00f7-eb8a-454b-9ea4-fd5ad93c0e99"
8866 />
8867
8868 <collection
8869 name="IUSBDeviceCollection" type="IUSBDevice"
8870 enumerator="IUSBDeviceEnumerator"
8871 uuid="e31f3248-90dd-4ca2-95f0-6b36042d96a2"
8872 readonly="yes"
8873 >
8874 <method name="findById">
8875 <desc>
8876 Searches this collection for a USB device with the given UUID.
8877 <note>
8878 The method returns an error if the given UUID does not
8879 correspond to any USB device in the collection.
8880 </note>
8881 <see>IUSBDevice::id</see>
8882 </desc>
8883 <param name="id" type="uuid" dir="in">
8884 <desc>UUID of the USB device to search for.</desc>
8885 </param>
8886 <param name="device" type="IUSBDevice" dir="return">
8887 <desc>Found USB device object.</desc>
8888 </param>
8889 </method>
8890
8891 <method name="findByAddress">
8892 <desc>
8893 Searches this collection for a USB device with the given
8894 host address.
8895 <note>
8896 The method returns an error if the given address does not
8897 correspond to any USB device in the collection.
8898 </note>
8899 <see>IUSBDevice::address</see>
8900 </desc>
8901 <param name="name" type="wstring" dir="in">
8902 <desc>
8903 Address of the USB device (as assigned by the host) to
8904 search for.
8905 </desc>
8906 </param>
8907 <param name="device" type="IUSBDevice" dir="return">
8908 <desc>Found USB device object.</desc>
8909 </param>
8910 </method>
8911
8912 </collection>
8913
8914 <interface
8915 name="IUSBDevice" extends="$unknown"
8916 uuid="850af07b-9ee8-48c2-b6b0-f6d0acbf63c3"
8917 wsmap="managed"
8918 >
8919 <desc>
8920 The IUSBDevice interface represents a virtual USB device attached to the
8921 virtual machine.
8922
8923 A collection of objects implementing this interface is stored in the
8924 <link to="IConsole::USBDevices"/> attribute which lists all USB devices
8925 attached to a running virtual machine's USB controller.
8926 </desc>
8927
8928 <attribute name="id" type="uuid" readonly="yes">
8929 <desc>
8930 Unique USB device ID. This ID is built from #vendorId,
8931 #productId, #revision and #serialNumber.
8932 </desc>
8933 </attribute>
8934
8935 <attribute name="vendorId" type="unsigned short" readonly="yes">
8936 <desc>Vendor ID.</desc>
8937 </attribute>
8938
8939 <attribute name="productId" type="unsigned short" readonly="yes">
8940 <desc>Product ID.</desc>
8941 </attribute>
8942
8943 <attribute name="revision" type="unsigned short" readonly="yes">
8944 <desc>
8945 Product revision number. This is a packed BCD represented as
8946 unsigned short. The high byte is the integer part and the low
8947 byte is the decimal.
8948 </desc>
8949 </attribute>
8950
8951 <attribute name="manufacturer" type="wstring" readonly="yes">
8952 <desc>Manufacturer string.</desc>
8953 </attribute>
8954
8955 <attribute name="product" type="wstring" readonly="yes">
8956 <desc>Product string.</desc>
8957 </attribute>
8958
8959 <attribute name="serialNumber" type="wstring" readonly="yes">
8960 <desc>Serial number string.</desc>
8961 </attribute>
8962
8963 <attribute name="address" type="wstring" readonly="yes">
8964 <desc>Host specific address of the device.</desc>
8965 </attribute>
8966
8967 <attribute name="port" type="unsigned short" readonly="yes">
8968 <desc>
8969 Host USB port number the device is physically
8970 coonected to.
8971 </desc>
8972 </attribute>
8973
8974 <attribute name="version" type="unsigned short" readonly="yes">
8975 <desc>
8976 The major USB version of the device - 1 or 2.
8977 </desc>
8978 </attribute>
8979
8980 <attribute name="portVersion" type="unsigned short" readonly="yes">
8981 <desc>
8982 The major USB version of the host USB port the device is
8983 physically coonected to - 1 or 2. For devices not connected to
8984 anything this will have the same value as the version attribute.
8985 </desc>
8986 </attribute>
8987
8988 <attribute name="remote" type="boolean" readonly="yes">
8989 <desc>
8990 Whether the device is physically connected to a remote VRDP
8991 client or to a local host machine.
8992 </desc>
8993 </attribute>
8994
8995 </interface>
8996
8997
8998 <!--
8999 // IUSBDeviceFilter
9000 /////////////////////////////////////////////////////////////////////////
9001 -->
9002
9003 <enumerator
9004 name="IUSBDeviceFilterEnumerator" type="IUSBDeviceFilter"
9005 uuid="d5109c61-93e7-4726-926b-0dee1020da56"
9006 />
9007
9008 <collection
9009 name="IUSBDeviceFilterCollection" type="IUSBDeviceFilter"
9010 enumerator="IUSBDeviceFilterEnumerator"
9011 uuid="4fa3fc99-ceb1-4bf5-a9cb-e962d825c1ef"
9012 readonly="yes"
9013 />
9014
9015 <interface
9016 name="IUSBDeviceFilter" extends="$unknown"
9017 uuid="d6831fb4-1a94-4c2c-96ef-8d0d6192066d"
9018 wsmap="managed"
9019 >
9020 <desc>
9021 The IUSBDeviceFilter interface represents an USB device filter used
9022 to perform actions on a group of USB devices.
9023
9024 This type of filters is used by running virtual machines to
9025 automatically capture selected USB devices once they are physically
9026 attached to the host computer.
9027
9028 A USB device is matched to the given device filter if and only if all
9029 attributes of the device match the corresponding attributes of the
9030 filter (that is, attributes are joined together using the logical AND
9031 operation). On the other hand, all together, filters in the list of
9032 filters carry the semantics of the logical OR operation. So if it is
9033 desirable to create a match like "this vendor id OR this product id",
9034 one needs to create two filters and specify "any match" (see below)
9035 for unused attributes.
9036
9037 All filter attributes used for matching are strings. Each string
9038 is an expression representing a set of values of the corresponding
9039 device attribute, that will match the given filter. Currently, the
9040 following filtering expressions are supported:
9041
9042 <ul>
9043 <li><i>Interval filters</i>. Used to specify valid intervals for
9044 integer device attributes (Vendor ID, Product ID and Revision).
9045 The format of the string is:
9046
9047 <tt>int:((m)|([m]-[n]))(,(m)|([m]-[n]))*</tt>
9048
9049 where <tt>m</tt> and <tt>n</tt> are integer numbers, either in octal
9050 (starting from <tt>0</tt>), hexadecimal (starting from <tt>0x</tt>)
9051 or decimal (otherwise) form, so that <tt>m &lt; n</tt>. If <tt>m</tt>
9052 is ommitted before a dash (<tt>-</tt>), the minimum possible integer
9053 is assumed; if <tt>n</tt> is ommitted after a dash, the maximum
9054 possible integer is assummed.
9055 </li>
9056 <li><i>Boolean filters</i>. Used to specify acceptable values for
9057 boolean device attributes. The format of the string is:
9058
9059 <tt>true|false|yes|no|0|1</tt>
9060
9061 </li>
9062 <li><i>Exact match</i>. Used to specify a single value for the given
9063 device attribute. Any string that does't start with <tt>int:</tt>
9064 represents the exact match. String device attributes are compared to
9065 this string including case of symbols. Integer attributes are first
9066 converted to a string (see individual filter attributes) and then
9067 compared ignoring case.
9068
9069 </li>
9070 <li><i>Any match</i>. Any value of the corresponding device attribute
9071 will match the given filter. An empty or <tt>null</tt> string is
9072 used to construct this type of filtering expressions.
9073
9074 </li>
9075 </ul>
9076
9077 <note>
9078 On the Windows host platform, interval filters are not currently
9079 available. Also all string filter attributes
9080 (<link to="#manufacturer"/>, <link to="#product"/>,
9081 <link to="#serialNumber"/>) are ignored, so they behave as
9082 <i>any match</i> no matter what string expression is specified.
9083 </note>
9084
9085 <see>IUSBController::deviceFilters, IHostUSBDeviceFilter</see>
9086 </desc>
9087
9088 <attribute name="name" type="wstring">
9089 <desc>
9090 Visible name for this filter.
9091 This name is used to visually distungish one filter from another,
9092 so it can neither be <tt>null</tt> nor an empty string.
9093 </desc>
9094 </attribute>
9095
9096 <attribute name="active" type="boolean">
9097 <desc>Whether this filter active or has been temporarily disabled.</desc>
9098 </attribute>
9099
9100 <attribute name="vendorId" type="wstring">
9101 <desc>
9102 <link to="IUSBDevice::vendorId">Vendor ID</link> filter.
9103 The string representation for the <i>exact matching</i>
9104 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
9105 (including leading zeroes).
9106 </desc>
9107 </attribute>
9108
9109 <attribute name="productId" type="wstring">
9110 <desc>
9111 <link to="IUSBDevice::productId">Product ID</link> filter.
9112 The string representation for the <i>exact matching</i>
9113 has the form <tt>XXXX</tt>, where <tt>X</tt> is the hex digit
9114 (including leading zeroes).
9115 </desc>
9116 </attribute>
9117
9118 <attribute name="revision" type="wstring">
9119 <desc>
9120 <link to="IUSBDevice::productId">Product revision number</link>
9121 filter. The string representation for the <i>exact matching</i>
9122 has the form <tt>IIFF</tt>, where <tt>I</tt> is the decimal digit
9123 of the integer part of the revision, and <tt>F</tt> is the
9124 decimal digit of its fractional part (including leading and
9125 trailing zeroes).
9126 Note that for interval filters, it's best to use the hexadecimal
9127 form, because the revision is stored as a 16 bit packed BCD value;
9128 so the expression <tt>int:0x0100-0x0199</tt> will match any
9129 revision from <tt>1.0</tt> to <tt>1.99</tt>.
9130 </desc>
9131 </attribute>
9132
9133 <attribute name="manufacturer" type="wstring">
9134 <desc>
9135 <link to="IUSBDevice::manufacturer">Manufacturer</link> filter.
9136 </desc>
9137 </attribute>
9138
9139 <attribute name="product" type="wstring">
9140 <desc>
9141 <link to="IUSBDevice::product">Product</link> filter.
9142 </desc>
9143 </attribute>
9144
9145 <attribute name="serialNumber" type="wstring">
9146 <desc>
9147 <link to="IUSBDevice::serialNumber">Serial number</link> filter.
9148 </desc>
9149 </attribute>
9150
9151 <attribute name="port" type="wstring">
9152 <desc>
9153 <link to="IUSBDevice::port">Host USB port</link> filter.
9154 </desc>
9155 </attribute>
9156
9157 <attribute name="remote" type="wstring">
9158 <desc>
9159 <link to="IUSBDevice::remote">Remote state</link> filter.
9160 <note>
9161 This filter makes sense only for machine USB filters,
9162 i.e. it is ignored by IHostUSBDeviceFilter objects.
9163 </note>
9164 </desc>
9165 </attribute>
9166
9167 <attribute name="maskedInterfaces" type="unsigned long">
9168 <desc>
9169 This is an advanced option for hiding one or more USB interfaces
9170 from the guest. The value is a bitmask where the bits that are set
9171 means the corresponding USB interface should be hidden, masked off
9172 if you like.
9173 This feature only works on Linux hosts.
9174 </desc>
9175 </attribute>
9176
9177 </interface>
9178
9179
9180 <!--
9181 // IHostUSBDevice
9182 /////////////////////////////////////////////////////////////////////////
9183 -->
9184
9185 <enum
9186 name="USBDeviceState"
9187 uuid="b99a2e65-67fb-4882-82fd-f3e5e8193ab4"
9188 >
9189 <desc>
9190 USB device state. This enumeration represents all possible states
9191 of the USB device physically attached to the host computer regarding
9192 its state on the host computer and availability to guest computers
9193 (all currently running virtual machines).
9194
9195 Once a supported USB device is attached to the host, global USB
9196 filters (<link to="IHost::USBDeviceFilters"/>) are activated. They can
9197 either ignore the device, or put ot to #Held state, or do nothing. Unless
9198 the device is ignored by global filters, filters of all currently running
9199 guests (<link to="IUSBController::deviceFilters"/>) are activated that can
9200 put it to #Captured state.
9201
9202 If the device was ignored by global filters, or didn't match
9203 any filters at all (including guest ones), it is handled by the host
9204 in a normal way. In this case, the device state is determined by
9205 the host and can be one of #Unavailable, #Busy or #Available, depending on
9206 the current device usage.
9207
9208 Besides auto-capturing based on filters, the device can be manually
9209 captured by guests (<link to="IConsole::attachUSBDevice()"/>) if its
9210 state is #Busy, #Available or #Held.
9211
9212 <note>
9213 Due to differences in USB stack implementations in Linux and Win32,
9214 states #Busy and #Available are applicable only to the Linux version of
9215 the product. This also means that (<link
9216 to="IConsole::attachUSBDevice()"/>) can only succeed on Win32 if
9217 the device state is #USBDeviceHeld.
9218 </note>
9219
9220 <see>IHostUSBDevice, IHostUSBDeviceFilter</see>
9221 </desc>
9222
9223 <const name="NotSupported" value="0">
9224 <desc>
9225 Not supported by the VirtualBox server, not available to guests.
9226 </desc>
9227 </const>
9228 <const name="Unavailable" value="1">
9229 <desc>
9230 Being used by the host computer exclusively,
9231 not available to guests.
9232 </desc>
9233 </const>
9234 <const name="Busy" value="2">
9235 <desc>
9236 Being used by the host computer, potentially available to guests.
9237 </desc>
9238 </const>
9239 <const name="Available" value="3">
9240 <desc>
9241 Not used by the host computer, available to guests.
9242 The host computer can also start using the device at any time.
9243 </desc>
9244 </const>
9245 <const name="Held" value="4">
9246 <desc>
9247 Held by the VirtualBox server (ignored by the host computer),
9248 available to guests.
9249 </desc>
9250 </const>
9251 <const name="Captured" value="5">
9252 <desc>
9253 Captured by one of the guest computers, not available
9254 to anybody else.
9255 </desc>
9256 </const>
9257 </enum>
9258
9259 <enumerator
9260 name="IHostUSBDeviceEnumerator" type="IHostUSBDevice"
9261 uuid="a0c55136-939f-4d20-b9d3-4d406f08bfa5"
9262 />
9263
9264 <collection
9265 name="IHostUSBDeviceCollection" type="IHostUSBDevice"
9266 enumerator="IHostUSBDeviceEnumerator"
9267 uuid="f9d3f96d-b027-4994-b589-70bb9ee0d364"
9268 readonly="yes"
9269 >
9270 <method name="findById">
9271 <desc>
9272 Searches this collection for a USB device with the given UUID.
9273 <note>
9274 The method returns an error if the given UUID does not
9275 correspond to any USB device in the collection.
9276 </note>
9277 <see>IHostUSBDevice::id</see>
9278 </desc>
9279 <param name="id" type="uuid" dir="in">
9280 <desc>UUID of the USB device to search for.</desc>
9281 </param>
9282 <param name="device" type="IHostUSBDevice" dir="return">
9283 <desc>Found USB device object.</desc>
9284 </param>
9285 </method>
9286
9287 <method name="findByAddress">
9288 <desc>
9289 Searches this collection for a USB device with the given
9290 host address.
9291 <note>
9292 The method returns an error if the given address does not
9293 correspond to any USB device in the collection.
9294 </note>
9295 <see>IHostUSBDevice::address</see>
9296 </desc>
9297 <param name="name" type="wstring" dir="in">
9298 <desc>
9299 Address of the USB device (as assigned by the host) to
9300 search for.
9301 </desc>
9302 </param>
9303 <param name="device" type="IHostUSBDevice" dir="return">
9304 <desc>Found USB device object.</desc>
9305 </param>
9306 </method>
9307
9308 </collection>
9309
9310 <interface
9311 name="IHostUSBDevice" extends="IUSBDevice"
9312 uuid="173b4b44-d268-4334-a00d-b6521c9a740a"
9313 wsmap="managed"
9314 >
9315 <desc>
9316 The IHostUSBDevice interface represents a physical USB device attached
9317 to the host computer.
9318
9319 Besides properties inherited from IUSBDevice, this interface adds the
9320 <link to="#state"/> property that holds the courrent state of the USB
9321 device.
9322
9323 <see>IHost::USBDevices, IHost::USBDeviceFilters</see>
9324 </desc>
9325
9326 <attribute name="state" type="USBDeviceState" readonly="yes">
9327 <desc>
9328 Current state of the device.
9329 </desc>
9330 </attribute>
9331
9332 <!-- @todo add class, subclass, bandwidth, configs, interfaces endpoints and such later. -->
9333
9334 </interface>
9335
9336
9337 <!--
9338 // IHostUSBDeviceFilter
9339 /////////////////////////////////////////////////////////////////////////
9340 -->
9341
9342 <enum
9343 name="USBDeviceFilterAction"
9344 uuid="cbc30a49-2f4e-43b5-9da6-121320475933"
9345 >
9346 <desc>
9347 Actions for host USB device filters.
9348 <see>IHostUSBDeviceFilter, USBDeviceState</see>
9349 </desc>
9350
9351 <const name="Null" value="0">
9352 <desc><tt>null</tt> value. Never used by the API.</desc>
9353 </const>
9354 <const name="Ignore" value="1">
9355 <desc>Ignore the matched USB device.</desc>
9356 </const>
9357 <const name="Hold" value="2">
9358 <desc>Hold the matched USB device.</desc>
9359 </const>
9360 </enum>
9361
9362 <enumerator
9363 name="IHostUSBDeviceFilterEnumerator" type="IHostUSBDeviceFilter"
9364 uuid="ff735211-903e-4642-9c37-189eb44579fe"
9365 />
9366
9367 <collection
9368 name="IHostUSBDeviceFilterCollection" type="IHostUSBDeviceFilter"
9369 enumerator="IHostUSBDeviceFilterEnumerator"
9370 uuid="1a80458b-87f1-4a74-995d-04e2330119e0"
9371 readonly="yes"
9372 />
9373
9374 <interface
9375 name="IHostUSBDeviceFilter" extends="IUSBDeviceFilter"
9376 uuid="4cc70246-d74a-400f-8222-3900489c0374"
9377 wsmap="managed"
9378 >
9379 <desc>
9380 The IHostUSBDeviceFilter interface represents a global filter for a
9381 physical USB device used by the host computer. Used indirectly in
9382 <link to="IHost::USBDeviceFilters"/>.
9383
9384 Using filters of this type, the host computer determines the initial
9385 state of the USB device after it is physically attached to the
9386 host's USB controller.
9387
9388 <note>
9389 The <link to="#remote"/> attribute is ignored by this type of
9390 filters, because it makes sense only for
9391 <link to="IUSBController::deviceFilters">machine USB filters</link>.
9392 </note>
9393
9394 <see>IHost::USBDeviceFilters</see>
9395 </desc>
9396
9397 <attribute name="action" type="USBDeviceFilterAction">
9398 <desc>
9399 Action performed by the host when an attached USB device
9400 matches this filter.
9401 </desc>
9402 </attribute>
9403
9404 </interface>
9405
9406 <!--
9407 // IAudioAdapter
9408 /////////////////////////////////////////////////////////////////////////
9409 -->
9410
9411 <enum
9412 name="AudioDriverType"
9413 uuid="4bcc3d73-c2fe-40db-b72f-0c2ca9d68496"
9414 >
9415 <desc>
9416 Host audio driver type.
9417 </desc>
9418
9419 <const name="Null" value="0">
9420 <desc><tt>null</tt> value. Also means "dummy audio driver".</desc>
9421 </const>
9422 <const name="WinMM" value="1"/>
9423 <const name="OSS" value="2"/>
9424 <const name="ALSA" value="3"/>
9425 <const name="DirectSound" value="4"/>
9426 <const name="CoreAudio" value="5"/>
9427 <const name="MMPM" value="6"/>
9428 <const name="Pulse" value="7"/>
9429 <const name="SolAudio" value="8"/>
9430 </enum>
9431
9432 <enum
9433 name="AudioControllerType"
9434 uuid="7afd395c-42c3-444e-8788-3ce80292f36c"
9435 >
9436 <desc>
9437 Virtual audio controller type.
9438 </desc>
9439
9440 <const name="AC97" value="0"/>
9441 <const name="SB16" value="1"/>
9442 </enum>
9443
9444 <interface
9445 name="IAudioAdapter" extends="$unknown"
9446 uuid="921873db-5f3f-4b69-91f9-7be9e535a2cb"
9447 wsmap="managed"
9448 >
9449 <desc>
9450 The IAudioAdapter interface represents the virtual audio adapter of
9451 the virtual machine. Used in <link to="IMachine::audioAdapter"/>.
9452 </desc>
9453 <attribute name="enabled" type="boolean">
9454 <desc>
9455 Flag whether the audio adapter is present in the
9456 guest system. If disabled, the virtual guest hardware will
9457 not contain any audio adapter. Can only be changed when
9458 the VM is not running.
9459 </desc>
9460 </attribute>
9461 <attribute name="audioController" type="AudioControllerType">
9462 <desc>
9463 The audio hardware we emulate.
9464 </desc>
9465 </attribute>
9466 <attribute name="audioDriver" type="AudioDriverType">
9467 <desc>
9468 Audio driver the adapter is connected to. This setting
9469 can only be changed when the VM is not running.
9470 </desc>
9471 </attribute>
9472 </interface>
9473
9474 <!--
9475 // IVRDPServer
9476 /////////////////////////////////////////////////////////////////////////
9477 -->
9478
9479 <enum
9480 name="VRDPAuthType"
9481 uuid="3d91887a-b67f-4b33-85bf-2da7ab1ea83a"
9482 >
9483 <desc>
9484 VRDP authentication type.
9485 </desc>
9486
9487 <const name="Null" value="0">
9488 <desc><tt>null</tt> value. Also means "no authentication".</desc>
9489 </const>
9490 <const name="External" value="1"/>
9491 <const name="Guest" value="2"/>
9492 </enum>
9493
9494 <interface
9495 name="IVRDPServer" extends="$unknown"
9496 uuid="ed9d31ae-867f-45fc-b727-6740084d1883"
9497 wsmap="managed"
9498 >
9499 <attribute name="enabled" type="boolean">
9500 <desc>VRDP server status.</desc>
9501 </attribute>
9502
9503 <attribute name="port" type="unsigned long">
9504 <desc>
9505 VRDP server port number.
9506 <note>
9507 Setting the value of this property to <tt>0</tt> will reset the port
9508 number to the default value which is
9509 currently <tt>3389</tt>. Reading this property will always return a
9510 real port number, even after it has been set to <tt>0</tt> (in which
9511 case the default port is returned).
9512 </note>
9513 </desc>
9514 </attribute>
9515
9516 <attribute name="netAddress" type="wstring">
9517 <desc>VRDP server address.</desc>
9518 </attribute>
9519
9520 <attribute name="authType" type="VRDPAuthType">
9521 <desc>VRDP authentication method.</desc>
9522 </attribute>
9523
9524 <attribute name="authTimeout" type="unsigned long">
9525 <desc>Timeout for guest authentication. Milliseconds.</desc>
9526 </attribute>
9527
9528 <attribute name="allowMultiConnection" type="boolean">
9529 <desc>
9530 Flag whether multiple simultaneous connections to the VM are permitted.
9531 Note that this will be replaced by a more powerful mechanism in the future.
9532 </desc>
9533 </attribute>
9534
9535 </interface>
9536
9537
9538 <!--
9539 // ISharedFolder
9540 /////////////////////////////////////////////////////////////////////////
9541 -->
9542
9543 <enumerator
9544 name="ISharedFolderEnumerator" type="ISharedFolder"
9545 uuid="1d420fd8-e7c1-4511-abf4-a504dc6d0cbf"
9546 />
9547
9548 <collection
9549 name="ISharedFolderCollection" type="ISharedFolder"
9550 enumerator="ISharedFolderEnumerator"
9551 uuid="9c7e2282-bb16-4fa7-9138-f383c5e02353"
9552 readonly="yes">
9553
9554 <method name="findByName">
9555 <desc>
9556 Searches this collection for a shared folder with the given logical
9557 name.
9558 <note>
9559 The method returns an error if the given name does not correspond to
9560 any shared folder in the collection.
9561 </note>
9562 </desc>
9563 <param name="name" type="wstring" dir="in">
9564 <desc>Logical name of the shared folder to search for</desc>
9565 </param>
9566 <param name="sharedFolder" type="ISharedFolder" dir="return">
9567 <desc>Found shared folder object</desc>
9568 </param>
9569 </method>
9570
9571 </collection>
9572
9573 <interface
9574 name="ISharedFolder" extends="$unknown"
9575 uuid="8b0c5f70-9139-4f97-a421-64d5e9c335d5"
9576 wsmap="struct"
9577 >
9578 <desc>
9579 The ISharedFolder interface represents a folder in the host computer's
9580 file system accessible from the guest OS running inside a virtual
9581 machine using an associated logical name.
9582
9583 There are three types of shared folders:
9584 <ul>
9585 <li><i>Global</i> (<link to="IVirtualBox::sharedFolders"/>), shared
9586 folders available to all virtual machines.</li>
9587 <li><i>Permanent</i> (<link to="IMachine::sharedFolders"/>),
9588 VM-specific shared folders available to the given virtual machine at
9589 startup.</li>
9590 <li><i>Transient</i> (<link to="IConsole::sharedFolders"/>),
9591 VM-specific shared folders created in the session context (for
9592 example, when the virtual machine is running) and automatically
9593 discarded when the session is closed (the VM is powered off).</li>
9594 </ul>
9595
9596 Logical names of shared folders must be unique within the given scope
9597 (global, permanent or transient). However, they do not need to be unique
9598 across scopes. In this case, the definitioin of the shared folder in a
9599 more specific scope takes precedence over definitions in all other
9600 scopes. The order of precedence is (more specific to more general):
9601 <ol>
9602 <li>Transient definitions</li>
9603 <li>Permanent definitions</li>
9604 <li>Global definitions</li>
9605 </ol>
9606
9607 For example, if MyMachine has a shared folder named
9608 <tt>C_DRIVE</tt> (that points to <tt>C:\\</tt>), then cretaing a
9609 transient shared folder named <tt>C_DRIVE</tt> (that points
9610 to <tt>C:\\\\WINDOWS</tt>) will change the definition
9611 of <tt>C_DRIVE</tt> in the guest OS so
9612 that <tt>\\\\VBOXSVR\\C_DRIVE</tt> will give access
9613 to <tt>C:\\WINDOWS</tt> instead of <tt>C:\\</tt> on the host
9614 PC. Removing the transient shared folder <tt>C_DRIVE</tt> will restore
9615 the prevoious (permanent) definition of <tt>C_DRIVE</tt> that points
9616 to <tt>C:\\</tt> if it still exists.
9617
9618 Note that permanent and transient shared folders of different machines
9619 are in different name spaces, so they don't overlap and don't need to
9620 have unique logical names.
9621
9622 <note>With the COM API, this is an interface like all the others. With the webservice,
9623 this is mapped to a structure, so querying the attribute will not return an object,
9624 but a complete structure.</note>
9625
9626 <note>
9627 Global shared folders are not implemented in the current vesion of the
9628 product.
9629 </note>
9630 </desc>
9631
9632 <attribute name="name" type="wstring" readonly="yes">
9633 <desc>Logical name of the shared folder.</desc>
9634 </attribute>
9635
9636 <attribute name="hostPath" type="wstring" readonly="yes">
9637 <desc>Full path to the shared folder in the host file system.</desc>
9638 </attribute>
9639
9640 <attribute name="accessible" type="boolean" readonly="yes">
9641 <desc>
9642 Whether the folder defined by the host path is currently
9643 accessible or not.
9644 For example, the folder can be unaccessible if it is placed
9645 on the network share that is not available by the time
9646 this property is read.
9647 </desc>
9648 </attribute>
9649
9650 <attribute name="writable" type="boolean" readonly="yes">
9651 <desc>
9652 Whether the folder defined by the host path is writable or
9653 not.
9654 </desc>
9655 </attribute>
9656
9657 </interface>
9658
9659 <!--
9660 // ISession
9661 /////////////////////////////////////////////////////////////////////////
9662 -->
9663
9664 <interface
9665 name="IInternalSessionControl" extends="$unknown"
9666 uuid="ee0bec44-ffec-4994-8f15-c3dea54bbbb6"
9667 internal="yes"
9668 wsmap="suppress"
9669 >
9670 <method name="getPID">
9671 <desc>PID of the process that has created this Session object.
9672 </desc>
9673 <param name="pid" type="unsigned long" dir="return"/>
9674 </method>
9675
9676 <method name="getRemoteConsole">
9677 <desc>Returns the console object suitable for remote control.</desc>
9678 <param name="console" type="IConsole" dir="return"/>
9679 </method>
9680
9681 <method name="assignMachine">
9682 <desc>
9683 Assigns the machine object associated with this direct-type
9684 session or informs the session that it will be a remote one
9685 (if machine = NULL).
9686 </desc>
9687 <param name="machine" type="IMachine" dir="in"/>
9688 </method>
9689
9690 <method name="assignRemoteMachine">
9691 <desc>
9692 Assigns the machine and the (remote) console object associated with
9693 this remote-type session.
9694 </desc>
9695 <param name="machine" type="IMachine" dir="in"/>
9696 <param name="console" type="IConsole" dir="in"/>
9697 </method>
9698
9699 <method name="updateMachineState">
9700 <desc>
9701 Updates the machine state in the VM process.
9702 Must be called only in certain cases
9703 (see the method implementation).
9704 </desc>
9705 <param name="aMachineState" type="MachineState" dir="in"/>
9706 </method>
9707
9708 <method name="uninitialize">
9709 <desc>
9710 Uninitializes (closes) this session. Used by VirtualBox to close
9711 the corresponding remote session when the direct session dies
9712 or gets closed.
9713 </desc>
9714 </method>
9715
9716 <method name="onDVDDriveChange">
9717 <desc>
9718 Triggered when settings of the DVD drive object of the
9719 associated virtual machine have changed.
9720 </desc>
9721 </method>
9722
9723 <method name="onFloppyDriveChange">
9724 <desc>
9725 Triggered when settings of the floppy drive object of the
9726 associated virtual machine have changed.
9727 </desc>
9728 </method>
9729
9730 <method name="onNetworkAdapterChange">
9731 <desc>
9732 Triggered when settions of a network adapter of the
9733 associated virtual machine have changed.
9734 </desc>
9735 <param name="networkAdapter" type="INetworkAdapter" dir="in"/>
9736 </method>
9737
9738 <method name="onSerialPortChange">
9739 <desc>
9740 Triggered when settions of a serial port of the
9741 associated virtual machine have changed.
9742 </desc>
9743 <param name="serialPort" type="ISerialPort" dir="in"/>
9744 </method>
9745
9746 <method name="onParallelPortChange">
9747 <desc>
9748 Triggered when settings of a parallel port of the
9749 associated virtual machine have changed.
9750 </desc>
9751 <param name="parallelPort" type="IParallelPort" dir="in"/>
9752 </method>
9753
9754 <method name="onVRDPServerChange">
9755 <desc>
9756 Triggered when settings of the VRDP server object of the
9757 associated virtual machine have changed.
9758 </desc>
9759 </method>
9760
9761 <method name="onUSBControllerChange">
9762 <desc>
9763 Triggered when settings of the USB controller object of the
9764 associated virtual machine have changed.
9765 </desc>
9766 </method>
9767
9768 <method name="onSharedFolderChange">
9769 <desc>
9770 Triggered when a permanent (global or machine) shared folder has been
9771 created or removed.
9772 <note>
9773 We don't pass shared folder parameters in this notification because
9774 the order in which parallel notifications are delivered is not defined,
9775 therefore it could happen that these parameters were outdated by the
9776 time of processing this notification.
9777 </note>
9778 </desc>
9779 <param name="global" type="boolean" dir="in"/>
9780 </method>
9781
9782 <method name="onUSBDeviceAttach">
9783 <desc>
9784 Triggered when a request to capture a USB device (as a result
9785 of matched USB filters or direct call to
9786 <link to="IConsole::attachUSBDevice"/>) has completed.
9787 A @c null @a error object means success, otherwise it
9788 describes a failure.
9789 </desc>
9790 <param name="device" type="IUSBDevice" dir="in"/>
9791 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
9792 <param name="maskedInterfaces" type="unsigned long" dir="in"/>
9793 </method>
9794
9795 <method name="onUSBDeviceDetach">
9796 <desc>
9797 Triggered when a request to release the USB device (as a result
9798 of machine termination or direct call to
9799 <link to="IConsole::detachUSBDevice"/>) has completed.
9800 A @c null @a error object means success, otherwise it
9801 </desc>
9802 <param name="id" type="uuid" dir="in"/>
9803 <param name="error" type="IVirtualBoxErrorInfo" dir="in"/>
9804 </method>
9805
9806 <method name="onShowWindow">
9807 <desc>
9808 Called by <link to="IMachine::canShowConsoleWindow()"/> and by
9809 <link to="IMachine::showConsoleWindow()"/> in order to notify
9810 console callbacks
9811 <link to="IConsoleCallback::onCanShowWindow()"/>
9812 and <link to="IConsoleCallback::onShowWindow()"/>.
9813 </desc>
9814 <param name="check" type="boolean" dir="in"/>
9815 <param name="canShow" type="boolean" dir="out"/>
9816 <param name="winId" type="unsigned long long" dir="out"/>
9817 </method>
9818
9819 <method name="accessGuestProperty">
9820 <desc>
9821 Called by <link to="IMachine::getGuestProperty()"/> and by
9822 <link to="IMachine::setGuestProperty()"/> in order to read and
9823 modify guest properties.
9824 </desc>
9825 <param name="key" type="wstring" dir="in"/>
9826 <param name="value" type="wstring" dir="in"/>
9827 <param name="isSetter" type="boolean" dir="in"/>
9828 <param name="retValue" type="wstring" dir="return"/>
9829 </method>
9830
9831 </interface>
9832
9833 <interface
9834 name="ISession" extends="$dispatched"
9835 uuid="12F4DCDB-12B2-4ec1-B7CD-DDD9F6C5BF4D"
9836 wsmap="managed"
9837 >
9838 <desc>
9839 The ISession interface represents a serialization primitive for virtual
9840 machines.
9841
9842 Within VirtualBox, every time one wishes to manipulate a virtual machine
9843 (for example, change its settings or start execution), an instance of
9844 the ISession interface is required. One first creates a local session
9845 object that implements the ISession interface and then passes the
9846 created object with the method call that opens the given session and
9847 thus initiates the machine manipulation. The session serves several
9848 purposes: it identifies to the inter-process VirtualBox code which
9849 process is currently working with the virtual machine, and it ensures
9850 that there are no incompatible requests from several processes for the
9851 same virtual machine.
9852
9853 How sessions objects are used depends on whether you use the Main API
9854 via COM or via the web service:
9855
9856 <ul>
9857 <li>When using the COM API directly, an object of the Session class from the
9858 VirtualBox type library needs to be created. In regular COM C++ client code,
9859 this can be done by calling <tt>createLocalObject()</tt>, a standard COM API.
9860 This object will then act as a local session object in further calls to open
9861 a session.
9862 </li>
9863
9864 <li>In the webservice, the session manager (IWebsessionManager) instead creates
9865 one session object automatically when <link to="IWebsessionManager::logon" />
9866 is called. A managed object reference to that session object can be retrieved by
9867 calling <link to="IWebsessionManager::getSessionObject" />. This session object
9868 reference can then be used to open sessions.
9869 </li>
9870 </ul>
9871
9872 Sessions are mainly used in two variations:
9873
9874 <ul>
9875 <li>
9876 To start a virtual machine in a separate process, one would call
9877 <link to="IVirtualBox::openRemoteSession"/>, which requires a session
9878 object as its first parameter. This session then identifies the caller
9879 and lets him control the started machine (for example, pause machine
9880 execution or power it down) as well as be notified about machine
9881 execution state changes.
9882 </li>
9883
9884 <li>To alter machine settings, or to start machine execution within the
9885 current process, one needs to open a direct session for the machine first by
9886 calling <link to="IVirtualBox::openSession"/>. While a direct session
9887 is open within one process, no any other process may open another direct
9888 session for the same machine. This prevents the machine from being changed
9889 by other processes while it is running or while the machine is being configured.
9890 </li>
9891 </ul>
9892
9893 One also can attach to an existing direct session alreay opened by
9894 another process (for example, in order to send a control request to the
9895 virtual machine such as the pause or the reset request). This is done by
9896 calling <link to="IVirtualBox::openExistingSession"/>.
9897
9898 <note>
9899 Unless you are trying to write a new VirtualBox front-end that
9900 performs direct machine execution (like the VirtualBox or VBoxSDL
9901 front-ends), don't call <link to="IConsole::powerUp"/> in a direct
9902 session opened by <link to="IVirtualBox::openSession"/> and use this
9903 session only to change virtual machine settings. If you simply want to
9904 start virtual machine execution using one of the existing front-ends
9905 (for example the VirtualBox GUI or headless server), simply use
9906 <link to="IVirtualBox::openRemoteSession"/>; these front-ends
9907 will power up the machine automatically for you.
9908 </note>
9909 </desc>
9910
9911 <attribute name="state" type="SessionState" readonly="yes">
9912 <desc>Current state of this session.</desc>
9913 </attribute>
9914
9915 <attribute name="type" type="SessionType" readonly="yes">
9916 <desc>
9917 Type of this session. The value of this attribute is valid only
9918 if the session is currently open (i.e. its #state is SessionType::SessionOpen),
9919 otherwise an error will be returned.
9920 </desc>
9921 </attribute>
9922
9923 <attribute name="machine" type="IMachine" readonly="yes">
9924 <desc>Machine object associated with this session.</desc>
9925 </attribute>
9926
9927 <attribute name="console" type="IConsole" readonly="yes">
9928 <desc>Console object associated with this session.</desc>
9929 </attribute>
9930
9931 <method name="close">
9932 <desc>
9933 Closes this session.
9934 <note>
9935 If a direct session for a machine opened with
9936 <link to="IVirtualBox::openSession()"/> is not explicitly
9937 closed when the application terminates, the state of the
9938 machine will be set to <link to="MachineState::Aborted"/>
9939 on the server. Generally, it is recommended to close all
9940 open sessions explicitly before terminating the application
9941 (no matter what is the reason of the termination).
9942 </note>
9943 </desc>
9944 </method>
9945
9946 </interface>
9947
9948 <!--
9949 // ISATAController
9950 /////////////////////////////////////////////////////////////////////////
9951 -->
9952
9953 <interface
9954 name="ISATAController" extends="$unknown"
9955 uuid="9a4b868b-1376-4533-8ef5-065b8e8cedff"
9956 wsmap="managed"
9957 >
9958 <attribute name="enabled" type="boolean">
9959 <desc>
9960 Flag whether the SATA controller is present in the
9961 guest system. If disabled, the virtual guest hardware will
9962 not contain any SATA controller. Can only be changed when
9963 the VM is powered off.
9964 </desc>
9965 </attribute>
9966
9967 <attribute name="portCount" type="unsigned long">
9968 <desc>
9969 The number of usable ports on the sata controller.
9970 It ranges from 1 to 30.
9971 </desc>
9972 </attribute>
9973
9974 <method name="GetIDEEmulationPort">
9975 <desc>Gets the corresponding port number which is emulated as an IDE device.</desc>
9976 <param name="devicePosition" type="long" dir="in"/>
9977 <param name="portNumber" type="long" dir="return"/>
9978 </method>
9979
9980 <method name="SetIDEEmulationPort">
9981 <desc>Sets the port number which is emulated as an IDE device.</desc>
9982 <param name="devicePosition" type="long" dir="in"/>
9983 <param name="portNumber" type="long" dir="in"/>
9984 </method>
9985
9986 </interface>
9987
9988<if target="wsdl">
9989
9990 <!--
9991 // IManagedObjectRef
9992 /////////////////////////////////////////////////////////////////////////
9993 -->
9994
9995 <interface
9996 name="IManagedObjectRef" extends="$unknown"
9997 uuid="9474d09d-2313-46de-b568-a42b8718e8ed"
9998 internal="yes"
9999 wsmap="managed"
10000 wscpp="hardcoded"
10001 >
10002 <desc>
10003 Webservice only: Managed object reference.
10004
10005 Only within the webservice, a managed object reference (which is really
10006 an opaque number) allows a webservice client to address an object
10007 that lives in the address space of the webservice server.
10008
10009 Behind each managed object reference, there is a COM object that lives
10010 in the webservice server's address space. The COM object is not freed
10011 until the managed object reference is released, either by an explicit
10012 call to <link to="IManagedObjectRef::release" /> or by logging off from
10013 the webservice (<link to="IWebsessionManager::logoff" />), which releases
10014 all objects created during the webservice session.
10015
10016 Whenever a method call of the VirtualBox API returns a COM object, the
10017 webservice representation of that method will instead return a
10018 managed object reference, which can then be used to invoke methods
10019 on that object.
10020 </desc>
10021
10022 <method name="getInterfaceName">
10023 <desc>
10024 Returns the name of the interface that this managed object represents,
10025 for example, "IMachine", as a string.
10026 </desc>
10027 <param name="return" type="wstring" dir="return"/>
10028 </method>
10029
10030 <method name="release">
10031 <desc>
10032 Releases this managed object reference and frees the resources that
10033 were allocated for it in the webservice server process. After calling
10034 this method, the identifier of the reference can no longer be used.
10035 </desc>
10036 </method>
10037
10038 </interface>
10039
10040 <!--
10041 // IWebsessionManager
10042 /////////////////////////////////////////////////////////////////////////
10043 -->
10044
10045 <interface
10046 name="IWebsessionManager" extends="$unknown"
10047 uuid="dea1b4c7-2de3-418a-850d-7868617f7733"
10048 internal="yes"
10049 wsmap="global"
10050 wscpp="hardcoded"
10051 >
10052 <desc>
10053 Webservice only: Websession manager. This provides essential services
10054 to webservice clients.
10055 </desc>
10056 <method name="logon">
10057 <desc>
10058 Logs a new client onto the webservice and returns a managed object reference to
10059 the IVirtualBox instance, which the client can then use as a basis to further
10060 queries, since all calls to the VirtualBox API are based on the IVirtualBox
10061 interface, in one way or the other.
10062 </desc>
10063 <param name="username" type="wstring" dir="in"/>
10064 <param name="password" type="wstring" dir="in"/>
10065 <param name="return" type="wstring" dir="return"/>
10066 </method>
10067
10068 <method name="getSessionObject">
10069 <desc>
10070 Returns a managed object reference to the internal ISession object that was created
10071 for this web service session when the client logged on.
10072
10073 <see>ISession</see>
10074 </desc>
10075 <param name="refIVirtualBox" type="wstring" dir="in"/>
10076 <param name="return" type="wstring" dir="return"/>
10077 </method>
10078
10079 <method name="logoff">
10080 <desc>
10081 Logs off the client who has previously logged on with <link to="IWebsessionManager::logoff" />
10082 and destroys all resources associated with the session (most importantly, all
10083 managed objects created in the server while the session was active).
10084 </desc>
10085 <param name="refIVirtualBox" type="wstring" dir="in"/>
10086 </method>
10087
10088 </interface>
10089
10090</if>
10091
10092 <module name="VBoxSVC" context="LocalServer">
10093 <class name="VirtualBox" uuid="B1A7A4F2-47B9-4A1E-82B2-07CCD5323C3F"
10094 namespace="virtualbox.org">
10095 <interface name="IVirtualBox" default="yes"/>
10096 </class>
10097 </module>
10098
10099 <module name="VBoxC" context="InprocServer" threadingModel="Free">
10100 <class name="Session" uuid="3C02F46D-C9D2-4f11-A384-53F0CF917214"
10101 namespace="virtualbox.org">
10102 <interface name="ISession" default="yes"/>
10103 </class>
10104 </module>
10105
10106</library>
10107
10108</idl>
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