IDebugBreakpointBoundEvent2::GetPendingBreakpoint

Obtiene el punto de interrupción pendiente que se está enlazando.

Sintaxis

HRESULT GetPendingBreakpoint(
    IDebugPendingBreakpoint2** ppPendingBP
);
int GetPendingBreakpoint(
    out IDebugPendingBreakpoint2 ppPendingBP
);

Parámetros

ppPendingBP
[out] Devuelve el objeto IDebugPendingBreakpoint2 que representa el punto de interrupción pendiente enlazado.

Valor devuelto

Si la operación se realiza correctamente, devuelve S_OK; de lo contrario, devuelve un código de error.

Ejemplo

En el ejemplo siguiente se muestra cómo implementar este método para un objeto CBreakpointSetDebugEventBase que expone la interfaz IDebugBreakpointBoundEvent2 .

STDMETHODIMP CBreakpointSetDebugEventBase::GetPendingBreakpoint(
    IDebugPendingBreakpoint2 **ppPendingBP)
{
    HRESULT hRes = E_FAIL;

    if ( ppPendingBP )
    {
        if ( m_pPendingBP )
        {
            *ppPendingBP = m_pPendingBP;

            m_pPendingBP->AddRef();

            hRes = S_OK;
        }
        else
            hRes = E_FAIL;
    }
    else
        hRes = E_INVALIDARG;

    return ( hRes );
}

Consulte también