Logo Search packages:      
Sourcecode: virtualbox-ose version File versions

MediumBase Class Reference

#include <MediumImpl.h>

Inheritance diagram for MediumBase:

VirtualBoxBaseProto com::SupportErrorInfoBase VirtualBoxSupportTranslation< MediumBase > util::Lockable VirtualBoxSupportTranslationBase ImageMediumBase com::SupportErrorInfoDerived< MediumBase, HardDisk, IHardDisk > com::SupportErrorInfoDerived< ImageMediumBase, DVDImage, IDVDImage > com::SupportErrorInfoDerived< ImageMediumBase, FloppyImage, IFloppyImage > HardDisk DVDImage FloppyImage

List of all members.


Detailed Description

Base component class for all media types.

Provides the basic implementation of the IMedium interface.

Note:
Subclasses must initialize the mVirtualBox data member in their init() implementations with the valid VirtualBox instance because some MediaBase methods call its methods.

Definition at line 46 of file MediumImpl.h.


Public Types

typedef AutoCallerBase< false > AutoCaller
typedef AutoCallerBase< true > AutoLimitedCaller
typedef std::list< BackRefBackRefList
enum  State {
  NotReady, Ready, InInit, InUninit,
  InitFailed, Limited, MayUninit, WillUninit
}

Public Member Functions

virtual HRESULT addCaller (State *aState=NULL, bool aLimited=false)
HRESULT addLimitedCaller (State *aState=NULL)
HRESULT attachTo (const Guid &aMachineId, const Guid &aSnapshotId=Guid::Empty)
const BackRefList & backRefs () const
STDMETHOD() Close ()
HRESULT detachFrom (const Guid &aMachineId, const Guid &aSnapshotId=Guid::Empty)
STDMETHOD() GetSnapshotIds (IN_BSTR aMachineId, ComSafeArrayOut(BSTR, aSnapshotIds))
const Guidid () const
bool isAttachedTo (const Guid &aMachineId)
bool isWriteLockOnCurrentThread ()
const Bstrlocation () const
const BstrlocationFull () const
virtual RWLockHandlelockHandle () const
STDMETHOD() LockRead (MediaState_T *aState)
STDMETHOD() LockWrite (MediaState_T *aState)
virtual void releaseCaller ()
LockOps * rlock ()
MediaState_T state () const
 STDMETHOD (COMGETTER(MachineIds))(ComSafeArrayOut(BSTR
 STDMETHOD (COMGETTER(LastAccessError))(BSTR *aLastAccessError)
 STDMETHOD (COMGETTER(Size))(ULONG64 *aSize)
 STDMETHOD (COMGETTER(Name))(BSTR *aName)
 STDMETHOD (COMSETTER(Location))(IN_BSTR aLocation)
 STDMETHOD (COMGETTER(Location))(BSTR *aLocation)
 STDMETHOD (COMGETTER(State))(MediaState_T *aState)
 STDMETHOD (COMSETTER(Description))(IN_BSTR aDescription)
 STDMETHOD (COMGETTER(Description))(BSTR *aDescription)
 STDMETHOD (COMGETTER(Id))(BSTR *aId)
virtual void uninit ()
STDMETHOD() UnlockRead (MediaState_T *aState)
STDMETHOD() UnlockWrite (MediaState_T *aState)
HRESULT updatePath (const char *aOldPath, const char *aNewPath)
LockOps * wlock ()

Static Public Member Functions

static const char * tr (const char *aSourceText, const char *aComment=NULL)

Public Attributes

 aMachineIds

Protected Member Functions

virtual HRESULT canAttach (const Guid &, const Guid &)
virtual HRESULT canClose ()
virtual const char * componentName () const =0
virtual const GUID & mainInterfaceID () const =0
virtual Utf8Str name ()
virtual HRESULT queryInfo ()
HRESULT setError (HRESULT aResultCode, const GUID &aIID, const char *aText,...)
HRESULT setError (HRESULT aResultCode, const char *aText,...)
HRESULT setErrorV (HRESULT aResultCode, const char *aText, va_list aArgs)
virtual HRESULT setLocation (CBSTR aLocation)
HRESULT setStateError ()
HRESULT setWarning (HRESULT aResultCode, const GUID &aIID, const char *aText,...)
HRESULT setWarning (HRESULT aResultCode, const char *aText,...)
HRESULT setWarningV (HRESULT aResultCode, const char *aText, va_list aArgs)
WriteLockHandlestateLockHandle ()
virtual HRESULT unregisterWithVirtualBox ()=0

Static Protected Member Functions

static const char * className ()
static bool cutClassNameFrom__PRETTY_FUNCTION__ (char *aPrettyFunctionName)
static HRESULT setError (HRESULT aResultCode, const GUID &aIID, const char *aComponent, const char *aText,...)
static HRESULT setError (HRESULT aResultCode, const GUID &aIID, const char *aComponent, const char *aText)
static HRESULT setErrorInfo (IVirtualBoxErrorInfo *aInfo)
static HRESULT setErrorV (HRESULT aResultCode, const GUID &aIID, const char *aComponent, const char *aText, va_list aArgs)
static HRESULT setWarning (HRESULT aResultCode, const GUID &aIID, const char *aComponent, const char *aText,...)
static HRESULT setWarning (HRESULT aResultCode, const GUID &aIID, const char *aComponent, const char *aText)
static HRESULT setWarningV (HRESULT aResultCode, const GUID &aIID, const char *aComponent, const char *aText, va_list aArgs)

Protected Attributes

Data m
const ComObjPtr< VirtualBox,
ComWeakRef
mVirtualBox

Classes

struct  BackRef
struct  Data

The documentation for this class was generated from the following files:

Generated by  Doxygen 1.6.0   Back to index