HostUSBDeviceImpl.h revision e64031e20c39650a7bc902a3e1aba613b9415dee
/** @file
*
* VBox frontends: Basic Frontend (BFE):
* Declaration of HostUSBDevice
*/
/*
* Copyright (C) 2006-2007 Oracle Corporation
*
* This file is part of VirtualBox Open Source Edition (OSE), as
* available from http://www.virtualbox.org. This file is free software;
* General Public License (GPL) as published by the Free Software
* Foundation, in version 2 as it comes in the "COPYING" file of the
* VirtualBox OSE distribution. VirtualBox OSE is distributed in the
* hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
*/
#ifndef ____H_HOSTUSBDEVICEIMPL
#define ____H_HOSTUSBDEVICEIMPL
#ifndef VBOXBFE_WITH_USB
# error "misconfiguration VBOXBFE_WITH_USB isn't defined and HostUSBDeviceImpl.h was included."
#endif
#include <string>
#include "VirtualBoxBase.h"
// #include "USBDeviceFilterImpl.h"
/* #include "USBProxyService.h" circular on Host/HostUSBDevice, the includer must include this. */
// #include "Collection.h"
/**
* The state of a given USB device in the host and in the guest.
* Originally part of the COM interface.
*/
typedef enum {
/** Not supported by the VirtualBox server, not available to
guests. */
/** Being used by the host computer exclusively, not available
to guests. */
/** Being used by the host computer, potentially available to
guests. */
/** Not used by the host computer, available to guests. The
host computer can also start using the device at any time. */
/** Held by the VirtualBox server (ignored by the host computer),
available to guests. */
/** Captured by one of the guest computers, not available to
anybody else. */
/**
* Object class used for the Host USBDevices property.
*/
{
virtual ~HostUSBDevice();
// public initializer/uninitializer for internal purposes only
// IUSBDevice properties
// IHostUSBDevice properties
// public methods only for internal purposes
void setIgnored();
void setCaptured ();
bool isCaptured()
{ return mState == USBDeviceState_Captured; }
int setHostDriven();
int reset();
// for VirtualBoxSupportErrorInfoImpl
bool mIgnored;
/** Pointer to the USB Proxy Service instance. */
/** Pointer to the USB Device structure owned by this device.
* Only used for host devices. */
};
#endif // ____H_HOSTUSBDEVICEIMPL