1 //===-- SBBreakpoint.h ------------------------------------------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef LLDB_SBBreakpoint_h_
11 #define LLDB_SBBreakpoint_h_
13 #include "lldb/API/SBDefines.h"
21 typedef bool (*BreakpointHitCallback) (void *baton,
24 lldb::SBBreakpointLocation &location);
28 SBBreakpoint (const lldb::SBBreakpoint& rhs);
32 const lldb::SBBreakpoint &
33 operator = (const lldb::SBBreakpoint& rhs);
35 // Tests to see if the opaque breakpoint object in this object matches the
36 // opaque breakpoint object in "rhs".
38 operator == (const lldb::SBBreakpoint& rhs);
41 operator != (const lldb::SBBreakpoint& rhs);
50 ClearAllBreakpointSites ();
52 lldb::SBBreakpointLocation
53 FindLocationByAddress (lldb::addr_t vm_addr);
56 FindLocationIDByAddress (lldb::addr_t vm_addr);
58 lldb::SBBreakpointLocation
59 FindLocationByID (lldb::break_id_t bp_loc_id);
61 lldb::SBBreakpointLocation
62 GetLocationAtIndex (uint32_t index);
65 SetEnabled (bool enable);
71 SetOneShot (bool one_shot);
83 SetIgnoreCount (uint32_t count);
86 GetIgnoreCount () const;
89 SetCondition (const char *condition);
95 SetThreadID (lldb::tid_t sb_thread_id);
101 SetThreadIndex (uint32_t index);
104 GetThreadIndex() const;
107 SetThreadName (const char *thread_name);
110 GetThreadName () const;
113 SetQueueName (const char *queue_name);
116 GetQueueName () const;
119 SetCallback (BreakpointHitCallback callback, void *baton);
122 SetScriptCallbackFunction (const char *callback_function_name);
125 SetScriptCallbackBody (const char *script_body_text);
128 GetNumResolvedLocations() const;
131 GetNumLocations() const;
134 GetDescription (lldb::SBStream &description);
137 EventIsBreakpointEvent (const lldb::SBEvent &event);
139 static lldb::BreakpointEventType
140 GetBreakpointEventTypeFromEvent (const lldb::SBEvent& event);
142 static lldb::SBBreakpoint
143 GetBreakpointFromEvent (const lldb::SBEvent& event);
145 static lldb::SBBreakpointLocation
146 GetBreakpointLocationAtIndexFromEvent (const lldb::SBEvent& event, uint32_t loc_idx);
149 GetNumBreakpointLocationsFromEvent (const lldb::SBEvent &event_sp);
153 friend class SBBreakpointLocation;
154 friend class SBTarget;
156 SBBreakpoint (const lldb::BreakpointSP &bp_sp);
158 lldb_private::Breakpoint *
161 lldb_private::Breakpoint *
167 const lldb::BreakpointSP &
171 PrivateBreakpointHitCallback (void *baton,
172 lldb_private::StoppointCallbackContext *context,
173 lldb::user_id_t break_id,
174 lldb::user_id_t break_loc_id);
176 lldb::BreakpointSP m_opaque_sp;
181 #endif // LLDB_SBBreakpoint_h_