IInterfaceInfo.IsDispatchable Propriedade
Definição
Importante
Algumas informações se referem a produtos de pré-lançamento que podem ser substancialmente modificados antes do lançamento. A Microsoft não oferece garantias, expressas ou implícitas, das informações aqui fornecidas.
Obtém um valor que indica se a interface é derivada de IDispatch.
public:
property bool IsDispatchable { bool get(); };
public:
property bool IsDispatchable { bool get(); };
[System.Runtime.InteropServices.DispId(1610743818)]
public bool IsDispatchable { [System.Runtime.InteropServices.DispId(1610743818)] get; }
[<System.Runtime.InteropServices.DispId(1610743818)>]
[<get: System.Runtime.InteropServices.DispId(1610743818)>]
member this.IsDispatchable : bool
Public ReadOnly Property IsDispatchable As Boolean
Valor da propriedade
true se a interface for derivada de IDispatch; caso contrário, false .
- Atributos
Exemplos
// From the Visual C++ Implement Interface wizard
function IsCustomInterface(nSource, oInterface)
{
if (nSource == g_nSourceCodeModel)
{
var oBases = oInterface.Bases;
var cBases = oBases.Count;
if (!cBases)
{
return false;
}
else
{
oBase = oBases.Item(1);
if (oBase.Name == "IDispatch")
{
return false;
}
else
{
var oBaseInterface = oBase.Class;
if (oBaseInterface)
{
return IsCustomInterface(nSource, oBaseInterface);
}
}
}
}
else
{
return oInterface.Type == einterfaceCustom && oInterface.IsDispatchable == false;
}
}