The OpenD Programming Language

createComObject

Create a COM object. The passed interface should be a child of IUnknown and from core.sys.windows or have a ComGuid UDA, or be something else entirely and you get dynamic binding.

The string version can take a GUID in the form of {xxxxx-xx-xxxx-xxxxxxxx} or a name it looks up in the registry. The overload takes a GUID object (e.g. CLSID_XXXX from the Windows headers or one you write in yourself).

It will return a wrapper to the COM object that conforms to a D translation of the COM interface with automatic refcounting.

  1. auto createComObject(wstring c)
  2. auto createComObject(GUID classId)
    version(Windows)
    createComObject
    (
    T = Dynamic
    )
    (
    GUID classId
    )

Meta