IDebugBoundBreakpoint2::Delete
중단점을 삭제합니다.
HRESULT Delete(
void
);
int Delete();
반환 값
성공 하면 반환 S_OK. 그렇지 않으면 오류 코드를 반환 합니다. 반환 E_BP_DELETED 바인딩된 중단점 개체의 상태를 설정는 경우 BPS_DELETED (일부는 BP_STATE 열거형).
예제
다음 예제에서는 단순에이 메서드를 구현 하는 방법을 보여 줍니다. CBoundBreakpoint 를 노출 하는 개체는 IDebugBoundBreakpoint2 인터페이스입니다.
HRESULT CBoundBreakpoint::Delete(void)
{
HRESULT hr;
// Verify that the bound breakpoint has not been
// deleted. If deleted, then return hr = E_BP_DELETED.
if (m_state != BPS_DELETED)
{
m_pInterp->RemoveBreakpoint(m_sbstrDoc, this);
// Change the state of the breakpoint to BPS_DELETED.
m_state = BPS_DELETED;
hr = S_OK;
}
else
{
hr = E_BP_DELETED;
}
return hr;
}