/*
* DO NOT EDIT! This is a generated file.
*
* XPCOM IDL (XPIDL) definition for VirtualBox Main API (COM interfaces)
* generated from XIDL (XML interface definition).
*
* Source : src/VBox/Main/idl/VirtualBox.xidl
* Generator : src/VBox/Main/idl/xpcidl.xsl
*/
#ifndef ___VirtualBox_CXPCOM_h
#define ___VirtualBox_CXPCOM_h
#ifdef __cplusplus
# include "VirtualBox_XPCOM.h"
#else /* !__cplusplus */
#include <stddef.h>
#include "wchar.h"
#if defined(WIN32)
#define PR_EXPORT(__type) extern __declspec(dllexport) __type
#define PR_EXPORT_DATA(__type) extern __declspec(dllexport) __type
#define PR_IMPORT(__type) __declspec(dllimport) __type
#define PR_IMPORT_DATA(__type) __declspec(dllimport) __type
#define PR_EXTERN(__type) extern __declspec(dllexport) __type
#define PR_IMPLEMENT(__type) __declspec(dllexport) __type
#define PR_EXTERN_DATA(__type) extern __declspec(dllexport) __type
#define PR_IMPLEMENT_DATA(__type) __declspec(dllexport) __type
#define PR_CALLBACK
#define PR_CALLBACK_DECL
#define PR_STATIC_CALLBACK(__x) static __x
#elif defined(XP_BEOS)
#define PR_EXPORT(__type) extern __declspec(dllexport) __type
#define PR_EXPORT_DATA(__type) extern __declspec(dllexport) __type
#define PR_IMPORT(__type) extern __declspec(dllexport) __type
#define PR_IMPORT_DATA(__type) extern __declspec(dllexport) __type
#define PR_EXTERN(__type) extern __declspec(dllexport) __type
#define PR_IMPLEMENT(__type) __declspec(dllexport) __type
#define PR_EXTERN_DATA(__type) extern __declspec(dllexport) __type
#define PR_IMPLEMENT_DATA(__type) __declspec(dllexport) __type
#define PR_CALLBACK
#define PR_CALLBACK_DECL
#define PR_STATIC_CALLBACK(__x) static __x
#elif defined(WIN16)
#define PR_CALLBACK_DECL __cdecl
#if defined(_WINDLL)
#define PR_EXPORT(__type) extern __type _cdecl _export _loadds
#define PR_IMPORT(__type) extern __type _cdecl _export _loadds
#define PR_EXPORT_DATA(__type) extern __type _export
#define PR_IMPORT_DATA(__type) extern __type _export
#define PR_EXTERN(__type) extern __type _cdecl _export _loadds
#define PR_IMPLEMENT(__type) __type _cdecl _export _loadds
#define PR_EXTERN_DATA(__type) extern __type _export
#define PR_IMPLEMENT_DATA(__type) __type _export
#define PR_CALLBACK __cdecl __loadds
#define PR_STATIC_CALLBACK(__x) static __x PR_CALLBACK
#else /* this must be .EXE */
#define PR_EXPORT(__type) extern __type _cdecl _export
#define PR_IMPORT(__type) extern __type _cdecl _export
#define PR_EXPORT_DATA(__type) extern __type _export
#define PR_IMPORT_DATA(__type) extern __type _export
#define PR_EXTERN(__type) extern __type _cdecl _export
#define PR_IMPLEMENT(__type) __type _cdecl _export
#define PR_EXTERN_DATA(__type) extern __type _export
#define PR_IMPLEMENT_DATA(__type) __type _export
#define PR_CALLBACK __cdecl __loadds
#define PR_STATIC_CALLBACK(__x) __x PR_CALLBACK
#endif /* _WINDLL */
#elif defined(XP_MAC)
#define PR_EXPORT(__type) extern __declspec(export) __type
#define PR_EXPORT_DATA(__type) extern __declspec(export) __type
#define PR_IMPORT(__type) extern __declspec(export) __type
#define PR_IMPORT_DATA(__type) extern __declspec(export) __type
#define PR_EXTERN(__type) extern __declspec(export) __type
#define PR_IMPLEMENT(__type) __declspec(export) __type
#define PR_EXTERN_DATA(__type) extern __declspec(export) __type
#define PR_IMPLEMENT_DATA(__type) __declspec(export) __type
#define PR_CALLBACK
#define PR_CALLBACK_DECL
#define PR_STATIC_CALLBACK(__x) static __x
#elif defined(XP_OS2) && defined(__declspec)
#define PR_EXPORT(__type) extern __declspec(dllexport) __type
#define PR_EXPORT_DATA(__type) extern __declspec(dllexport) __type
#define PR_IMPORT(__type) __declspec(dllimport) __type
#define PR_IMPORT_DATA(__type) __declspec(dllimport) __type
#define PR_EXTERN(__type) extern __declspec(dllexport) __type
#define PR_IMPLEMENT(__type) __declspec(dllexport) __type
#define PR_EXTERN_DATA(__type) extern __declspec(dllexport) __type
#define PR_IMPLEMENT_DATA(__type) __declspec(dllexport) __type
#define PR_CALLBACK
#define PR_CALLBACK_DECL
#define PR_STATIC_CALLBACK(__x) static __x
#elif defined(XP_OS2_VACPP)
#define PR_EXPORT(__type) extern __type
#define PR_EXPORT_DATA(__type) extern __type
#define PR_IMPORT(__type) extern __type
#define PR_IMPORT_DATA(__type) extern __type
#define PR_EXTERN(__type) extern __type
#define PR_IMPLEMENT(__type) __type
#define PR_EXTERN_DATA(__type) extern __type
#define PR_IMPLEMENT_DATA(__type) __type
#define PR_CALLBACK _Optlink
#define PR_CALLBACK_DECL
#define PR_STATIC_CALLBACK(__x) static __x PR_CALLBACK
#else /* Unix */
# ifdef VBOX_HAVE_VISIBILITY_HIDDEN
# define PR_EXPORT(__type) __attribute__((visibility("default"))) extern __type
# define PR_EXPORT_DATA(__type) __attribute__((visibility("default"))) extern __type
# define PR_IMPORT(__type) extern __type
# define PR_IMPORT_DATA(__type) extern __type
# define PR_EXTERN(__type) __attribute__((visibility("default"))) extern __type
# define PR_IMPLEMENT(__type) __attribute__((visibility("default"))) __type
# define PR_EXTERN_DATA(__type) __attribute__((visibility("default"))) extern __type
# define PR_IMPLEMENT_DATA(__type) __attribute__((visibility("default"))) __type
# define PR_CALLBACK
# define PR_CALLBACK_DECL
# define PR_STATIC_CALLBACK(__x) static __x
# else
# define PR_EXPORT(__type) extern __type
# define PR_EXPORT_DATA(__type) extern __type
# define PR_IMPORT(__type) extern __type
# define PR_IMPORT_DATA(__type) extern __type
# define PR_EXTERN(__type) extern __type
# define PR_IMPLEMENT(__type) __type
# define PR_EXTERN_DATA(__type) extern __type
# define PR_IMPLEMENT_DATA(__type) __type
# define PR_CALLBACK
# define PR_CALLBACK_DECL
# define PR_STATIC_CALLBACK(__x) static __x
# endif
#endif
#if defined(_NSPR_BUILD_)
#define NSPR_API(__type) PR_EXPORT(__type)
#define NSPR_DATA_API(__type) PR_EXPORT_DATA(__type)
#else
#define NSPR_API(__type) PR_IMPORT(__type)
#define NSPR_DATA_API(__type) PR_IMPORT_DATA(__type)
#endif
typedef unsigned char PRUint8;
#if (defined(HPUX) && defined(__cplusplus) \
&& !defined(__GNUC__) && __cplusplus < 199707L) \
|| (defined(SCO) && defined(__cplusplus) \
&& !defined(__GNUC__) && __cplusplus == 1L)
typedef char PRInt8;
#else
typedef signed char PRInt8;
#endif
#define PR_INT8_MAX 127
#define PR_INT8_MIN (-128)
#define PR_UINT8_MAX 255U
typedef unsigned short PRUint16;
typedef short PRInt16;
#define PR_INT16_MAX 32767
#define PR_INT16_MIN (-32768)
#define PR_UINT16_MAX 65535U
typedef unsigned int PRUint32;
typedef int PRInt32;
#define PR_INT32(x) x
#define PR_UINT32(x) x ## U
#define PR_INT32_MAX PR_INT32(2147483647)
#define PR_INT32_MIN (-PR_INT32_MAX - 1)
#define PR_UINT32_MAX PR_UINT32(4294967295)
typedef long PRInt64;
typedef unsigned long PRUint64;
typedef int PRIntn;
typedef unsigned int PRUintn;
typedef double PRFloat64;
typedef size_t PRSize;
typedef ptrdiff_t PRPtrdiff;
typedef unsigned long PRUptrdiff;
typedef PRIntn PRBool;
#define PR_TRUE 1
#define PR_FALSE 0
typedef PRUint8 PRPackedBool;
/*
** Status code used by some routines that have a single point of failure or
** special status return.
*/
typedef enum { PR_FAILURE = -1, PR_SUCCESS = 0 } PRStatus;
#ifndef __PRUNICHAR__
#define __PRUNICHAR__
#if defined(WIN32) || defined(XP_MAC)
typedef wchar_t PRUnichar;
#else
typedef PRUint16 PRUnichar;
#endif
#endif
typedef long PRWord;
typedef unsigned long PRUword;
#define nsnull 0
typedef PRUint32 nsresult;
#if defined(__GNUC__) && (__GNUC__ > 2)
#define NS_LIKELY(x) (__builtin_expect((x), 1))
#define NS_UNLIKELY(x) (__builtin_expect((x), 0))
#else
#define NS_LIKELY(x) (x)
#define NS_UNLIKELY(x) (x)
#endif
#define NS_FAILED(_nsresult) (NS_UNLIKELY((_nsresult) & 0x80000000))
#define NS_SUCCEEDED(_nsresult) (NS_LIKELY(!((_nsresult) & 0x80000000)))
/**
* An "interface id" which can be used to uniquely identify a given
* interface.
* A "unique identifier". This is modeled after OSF DCE UUIDs.
*/
struct nsID {
PRUint32 m0;
PRUint16 m1;
PRUint16 m2;
PRUint8 m3[8];
};
typedef struct nsID nsID;
typedef nsID nsIID;
struct nsISupports; /* forward declaration */
struct nsIStackFrame; /* forward declaration */
struct nsIException; /* forward declaration */
typedef struct nsISupports nsISupports; /* forward declaration */
typedef struct nsIStackFrame nsIStackFrame; /* forward declaration */
typedef struct nsIException nsIException; /* forward declaration */
/**
* IID for the nsISupports interface
* {00000000-0000-0000-c000-000000000046}
*
* To maintain binary compatibility with COM's IUnknown, we define the IID
* of nsISupports to be the same as that of COM's IUnknown.
*/
#define NS_ISUPPORTS_IID \
{ 0x00000000, 0x0000, 0x0000, \
{0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46} }
/**
* Reference count values
*
* This is the return type for AddRef() and Release() in nsISupports.
* IUnknown of COM returns an unsigned long from equivalent functions.
* The following ifdef exists to maintain binary compatibility with
* IUnknown.
*/
/**
* Basic component object model interface. Objects which implement
* this interface support runtime interface discovery (QueryInterface)
* and a reference counted memory model (AddRef/Release). This is
* modelled after the win32 IUnknown API.
*/
struct nsISupports_vtbl {
/**
* @name Methods
*/
/**
* A run time mechanism for interface discovery.
* @param aIID [in] A requested interface IID
* @param aInstancePtr [out] A pointer to an interface pointer to
* receive the result.
* @return NS_OK if the interface is supported by the associated
* instance, NS_NOINTERFACE if it is not.
* NS_ERROR_INVALID_POINTER if aInstancePtr is NULL.
*/
nsresult (*QueryInterface)(nsISupports *this_, const nsID *iid, void **resultp);
/**
* Increases the reference count for this interface.
* The associated instance will not be deleted unless
* the reference count is returned to zero.
*
* @return The resulting reference count.
*/
nsresult (*AddRef)(nsISupports *this_);
/**
* Decreases the reference count for this interface.
* Generally, if the reference count returns to zero,
* the associated instance is deleted.
*
* @return The resulting reference count.
*/
nsresult (*Release)(nsISupports *this_);
};
struct nsISupports {
struct nsISupports_vtbl *vtbl;
};
/* starting interface: nsIException */
#define NS_IEXCEPTION_IID_STR "f3a8d3b4-c424-4edc-8bf6-8974c983ba78"
#define NS_IEXCEPTION_IID \
{0xf3a8d3b4, 0xc424, 0x4edc, \
{ 0x8b, 0xf6, 0x89, 0x74, 0xc9, 0x83, 0xba, 0x78 }}
struct nsIException_vtbl {
/* Methods from the Class nsISupports */
struct nsISupports_vtbl nsisupports;
/* readonly attribute string message; */
nsresult (*GetMessage)(nsIException *this_, PRUnichar * *aMessage);
/* readonly attribute nsresult (*result; */
nsresult (*GetResult)(nsIException *this_, nsresult *aResult);
/* readonly attribute string name; */
nsresult (*GetName)(nsIException *this_, PRUnichar * *aName);
/* readonly attribute string filename; */
nsresult (*GetFilename)(nsIException *this_, PRUnichar * *aFilename);
/* readonly attribute PRUint32 lineNumber; */
nsresult (*GetLineNumber)(nsIException *this_, PRUint32 *aLineNumber);
/* readonly attribute PRUint32 columnNumber; */
nsresult (*GetColumnNumber)(nsIException *this_, PRUint32 *aColumnNumber);
/* readonly attribute nsIStackFrame location; */
nsresult (*GetLocation)(nsIException *this_, nsIStackFrame * *aLocation);
/* readonly attribute nsIException inner; */
nsresult (*GetInner)(nsIException *this_, nsIException * *aInner);
/* readonly attribute nsISupports data; */
nsresult (*GetData)(nsIException *this_, nsISupports * *aData);
/* string toString (); */
nsresult (*ToString)(nsIException *this_, PRUnichar **_retval);
};
struct nsIException {
struct nsIException_vtbl *vtbl;
};
/* starting interface: nsIStackFrame */
#define NS_ISTACKFRAME_IID_STR "91d82105-7c62-4f8b-9779-154277c0ee90"
#define NS_ISTACKFRAME_IID \
{0x91d82105, 0x7c62, 0x4f8b, \
{ 0x97, 0x79, 0x15, 0x42, 0x77, 0xc0, 0xee, 0x90 }}
struct nsIStackFrame_vtbl {
/* Methods from the Class nsISupports */
struct nsISupports_vtbl nsisupports;
/* readonly attribute PRUint32 language; */
nsresult (*GetLanguage)(nsIStackFrame *this_, PRUint32 *aLanguage);
/* readonly attribute string languageName; */
nsresult (*GetLanguageName)(nsIStackFrame *this_, PRUnichar * *aLanguageName);
/* readonly attribute string filename; */
nsresult (*GetFilename)(nsIStackFrame *this_, PRUnichar * *aFilename);
/* readonly attribute string name; */
nsresult (*GetName)(nsIStackFrame *this_, PRUnichar * *aName);
/* readonly attribute PRInt32 lineNumber; */
nsresult (*GetLineNumber)(nsIStackFrame *this_, PRInt32 *aLineNumber);
/* readonly attribute string sourceLine; */
nsresult (*GetSourceLine)(nsIStackFrame *this_, PRUnichar * *aSourceLine);
/* readonly attribute nsIStackFrame caller; */
nsresult (*GetCaller)(nsIStackFrame *this_, nsIStackFrame * *aCaller);
/* string toString (); */
nsresult (*ToString)(nsIStackFrame *this_, PRUnichar **_retval);
};
struct nsIStackFrame {
struct nsIStackFrame_vtbl *vtbl;
};
#endif /* !__cplusplus */
#ifdef IN_VBOXXPCOMC
# define VBOXXPCOMC_DECL(type) PR_EXPORT(type)
#else
# define VBOXXPCOMC_DECL(type) PR_IMPORT(type)
#endif
#ifdef __cplusplus
extern "C" {
#endif
/* Initialize/Uninitialize XPCOM. */
VBOXXPCOMC_DECL(void) VBoxComInitialize(IVirtualBox **virtualBox, ISession **session);
VBOXXPCOMC_DECL(void) VBoxComUninitialize(void);
/* Deallocation functions. */
VBOXXPCOMC_DECL(void) VBoxComUnallocMem(void *ptr);
VBOXXPCOMC_DECL(void) VBoxUtf16Free(PRUnichar *pwszString);
VBOXXPCOMC_DECL(void) VBoxUtf8Free(char *pszString);
/* Converting to and from UTF-8 and UTF-16. */
VBOXXPCOMC_DECL(int) VBoxUtf16ToUtf8(const PRUnichar *pwszString, char **ppszString);
VBOXXPCOMC_DECL(int) VBoxUtf8ToUtf16(const char *pszString, PRUnichar **ppwszString);
/* Getting and setting the environment variables. */
VBOXXPCOMC_DECL(const char *) VBoxGetEnv(const char *pszVar);
VBOXXPCOMC_DECL(int) VBoxSetEnv(const char *pszVar, const char *pszValue);
/**
* Function table for dynamic linking.
* Use VBoxGetFunctions() to obtain the pointer to it.
*/
typedef struct VBOXXPCOMC
{
/** The size of the structure. */
unsigned cb;
/** The structure version. */
unsigned uVersion;
void (*pfnComInitialize)(IVirtualBox **virtualBox, ISession **session);
void (*pfnComUninitialize)(void);
void (*pfnComUnallocMem)(void *pv);
void (*pfnUtf16Free)(PRUnichar *pwszString);
void (*pfnUtf8Free)(char *pszString);
int (*pfnUtf16ToUtf8)(const PRUnichar *pwszString, char **ppszString);
int (*pfnUtf8ToUtf16)(const char *pszString, PRUnichar **ppwszString);
const char * (*pfnGetEnv)(const char *pszVar);
int (*pfnSetEnv)(const char *pszVar, const char *pszValue);
/** Tail version, same as uVersion. */
unsigned uEndVersion;
} VBOXXPCOMC;
/** Pointer to a const VBoxXPCOMC function table. */
typedef VBOXXPCOMC const *PCVBOXXPCOM;
/** The current interface version.
* For use with VBoxGetXPCOMCFunctions and to be found in
* VBOXXPCOMC::uVersion. */
#define VBOX_XPCOMC_VERSION 0x00010000U
VBOXXPCOMC_DECL(PCVBOXXPCOM) VBoxGetXPCOMCFunctions(unsigned uVersion);
/** Typedef for VBoxGetXPCOMCFunctions. */
typedef PCVBOXXPCOM (*PFNVBOXGETXPCOMCFUNCTIONS)(unsigned uVersion);
/** The symbol name of VBoxGetXPCOMCFunctions. */
#if defined(__APPLE__) || defined(__OS2__)
# define VBOX_GET_XPCOMC_FUNCTIONS_SYMBOL_NAME "_VBoxGetXPCOMCFunctions"
#else
# define VBOX_GET_XPCOMC_FUNCTIONS_SYMBOL_NAME "VBoxGetXPCOMCFunctions"
#endif
#ifdef __cplusplus
}
#endif
#endif /* !___VirtualBox_CXPCOM_h */
@if attributes are not currently allowed because xpidl lacks
support for #ifdef and stuff.
#if
#endif
struct
;
typedef struct
;
/* Start of struct
Declaration */
#define
#define
_IID { \
0x
, 0x
, 0x
, \
{ 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
} \
}
struct
_vtbl
{
struct nsISupports_vtbl nsisupports;
struct nsISupports_vtbl nsisupports;
struct nsIException_vtbl nsiexception;
struct
_vtbl
;
};
struct
{
struct
_vtbl *vtbl;
};
/* End of struct
Declaration */
'array' attributes are not supported, use 'safearray="yes"' instead.
nsresult (*Get
)(
*this_,
PRUint32 *
Size,
**
);
nsresult set
(
in unsigned long
Size,
[array, size_is(
Size)] in
);
nsresult (*Get
)(
*this_,
*
);
nsresult (*Get
)(
*this_,
*
);
nsresult (*Set
)(
*this_,
);
#define COM_FORWARD_
_GETTER_
_TO(smth) NS_IMETHOD Get
(
PRUint32 * a
Size,
*
* a
) { return smth Get
(
a
Size,
a
); }
#define COM_FORWARD_
_GETTER_
_TO_OBJ(obj) COM_FORWARD_
_GETTER_
_TO ((obj)->)
#define COM_FORWARD_
_GETTER_
_TO_BASE(base) COM_FORWARD_
_GETTER_
_TO (base::)
#define COM_FORWARD_
_SETTER_
_TO(smth) NS_IMETHOD Set
(
PRUint32 a
Size,
const
*
a
) { return smth Set
(a
); }
#define COM_FORWARD_
_SETTER_
_TO_OBJ(obj) COM_FORWARD_
_SETTER_
_TO ((obj)->)
#define COM_FORWARD_
_SETTER_
_TO_BASE(base) COM_FORWARD_
_SETTER_
_TO (base::)
nsresult (*
)(
*this_,
,
);
)(
*this_ );
#define COM_FORWARD_
_
_TO(smth) NS_IMETHOD
(
,
) { return smth
(
a
Size+++,
a
,
a
Size,
a
); }
() { return smth
(); }
#define COM_FORWARD_
_
_TO_OBJ(obj) COM_FORWARD_
_
_TO ((obj)->)
#define COM_FORWARD_
_
_TO_BASE(base) COM_FORWARD_
_
_TO (base::)
#define NS_
_CID { \
0x
, 0x
, 0x
, \
{ 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
} \
}
#define NS_
_CONTRACTID "@
/
;1"
/* for compatibility with Win32 */
#define CLSID_
(nsCID) NS_
_CID
/* Start of struct
Declaration */
#define
#define
_IID { \
0x
, 0x
, 0x
, \
{ 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
} \
}
struct
_vtbl
{
struct nsISupports_vtbl nsisupports;
nsresult (*HasMore)(
*this_, PRBool *more);
nsresult (*GetNext)(
*this_,
*next);
};
struct
{
struct
_vtbl *vtbl;
};
/* End of struct
Declaration */
non-readonly collections are not currently supported
/* Start of struct
Declaration */
#define
#define
_IID { \
0x
, 0x
, 0x
, \
{ 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
} \
}
struct
_vtbl
{
struct nsISupports_vtbl nsisupports;
nsresult (*GetCount)(
*this_, PRUint32 *aCount);
nsresult (*GetItemAt)(
*this_, PRUint32 index,
**item);
nsresult (*Enumerate)(
*this_,
**enumerator);
};
struct
{
struct
_vtbl *vtbl;
};
/* End of struct
Declaration */
/* Start of enum
Declaration */
#define
#define
_IID { \
0x
, 0x
, 0x
, \
{ 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
, 0x
} \
}
enum
{
_
=
,
};
/* End of enum
Declaration */
PRUint32
Size,
PRUint32 *
Size,
PRUint32 *
Size,
PRUint32
Size,
*
*
*
**
*
return 'array' parameters are not supported, use 'safearray="yes"' instead.
[array,
must have the same direction
size_is(
)
array attribute refers to non-existent param:
]
*
*
PRUint32
*
a
Size,
*
*
a
either 'array' or 'safearray="yes"' attribute is allowed, but not both!
booleanPtr
octetPtr
shortPtr
ushortPtr
longPtr
llongPtr
ulongPtr
ullongPtr
charPtr
wcharPtr
attribute 'mod=
' cannot be used with type
of attribute 'mod' is invalid!
nsresult
boolean
octet
short
unsigned short
long
long long
unsigned long
unsigned long long
char
wchar
string
wstring
nsIDPtr
: Non-readonly uuid attributes are not supported!
nsIDRef
nsIDPtr
nsISupports
PRUint32
Unknown parameter type:
PRBool *
PRUint8 *
PRInt16 *
PRUint16 *
PRInt32 *
PRInt64 *
PRUint32 *
PRUint64 *
char *
PRUnichar *
nsresult
PRBool
PRUint8
PRInt16
PRUint16
PRInt32
PRInt64
PRUint32
PRUint64
char
PRUnichar
char *
PRUnichar *
nsID *
const nsID *
nsID *
nsISupports *
PRUint32
*