blob: a3073538e676643bc0b34c0a481bd4125ca49900 [file] [log] [blame]
Johnny Chen5de6a792011-07-18 21:30:21 +00001//===-- SWIG Interface for SBBreakpointLocation -----------------*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10namespace lldb {
11
12%feature("docstring",
13"Represents one unique instance (by address) of a logical breakpoint.
14
15A breakpoint location is defined by the breakpoint that produces it,
16and the address that resulted in this particular instantiation.
17Each breakpoint location has its settable options.
18
19SBBreakpoint contains SBBreakpointLocation(s). See docstring of SBBreakpoint
20for retrieval of an SBBreakpointLocation from an SBBreakpoint."
21) SBBreakpointLocation;
22class SBBreakpointLocation
23{
24public:
25
26 SBBreakpointLocation ();
27
28 SBBreakpointLocation (const lldb::SBBreakpointLocation &rhs);
29
30 ~SBBreakpointLocation ();
31
Jim Ingham6904a932012-05-16 17:15:08 +000032 break_id_t
33 GetID ();
34
Johnny Chen5de6a792011-07-18 21:30:21 +000035 bool
36 IsValid() const;
37
Jim Ingham1b040c12011-10-07 22:27:25 +000038 lldb::SBAddress
39 GetAddress();
40
Johnny Chen5de6a792011-07-18 21:30:21 +000041 lldb::addr_t
42 GetLoadAddress ();
43
44 void
45 SetEnabled(bool enabled);
46
47 bool
48 IsEnabled ();
49
50 uint32_t
51 GetIgnoreCount ();
52
53 void
54 SetIgnoreCount (uint32_t n);
55
Johnny Chen85ced802011-10-18 19:13:06 +000056 %feature("docstring", "
57 //--------------------------------------------------------------------------
58 /// The breakpoint location stops only if the condition expression evaluates
59 /// to true.
60 //--------------------------------------------------------------------------
61 ") SetCondition;
Johnny Chen5de6a792011-07-18 21:30:21 +000062 void
63 SetCondition (const char *condition);
64
Johnny Chen85ced802011-10-18 19:13:06 +000065 %feature("docstring", "
66 //------------------------------------------------------------------
67 /// Get the condition expression for the breakpoint location.
68 //------------------------------------------------------------------
69 ") GetCondition;
Johnny Chen5de6a792011-07-18 21:30:21 +000070 const char *
71 GetCondition ();
72
Jim Inghamd80102e2014-04-02 01:04:55 +000073 %feature("docstring", "
74 //------------------------------------------------------------------
75 /// Set the callback to the given Python function name.
76 //------------------------------------------------------------------
77 ") SetScriptCallbackFunction;
78 void
79 SetScriptCallbackFunction (const char *callback_function_name);
80
81 %feature("docstring", "
82 //------------------------------------------------------------------
83 /// Provide the body for the script function to be called when the breakpoint location is hit.
84 /// The body will be wrapped in a function, which be passed two arguments:
85 /// 'frame' - which holds the bottom-most SBFrame of the thread that hit the breakpoint
86 /// 'bpno' - which is the SBBreakpointLocation to which the callback was attached.
87 ///
88 /// The error parameter is currently ignored, but will at some point hold the Python
89 /// compilation diagnostics.
90 /// Returns true if the body compiles successfully, false if not.
91 //------------------------------------------------------------------
92 ") SetScriptCallbackBody;
93 SBError
94 SetScriptCallbackBody (const char *script_body_text);
95
Johnny Chen5de6a792011-07-18 21:30:21 +000096 void
97 SetThreadID (lldb::tid_t sb_thread_id);
98
99 lldb::tid_t
100 GetThreadID ();
101
102 void
103 SetThreadIndex (uint32_t index);
104
105 uint32_t
106 GetThreadIndex() const;
107
108 void
109 SetThreadName (const char *thread_name);
110
111 const char *
112 GetThreadName () const;
113
114 void
115 SetQueueName (const char *queue_name);
116
117 const char *
118 GetQueueName () const;
119
120 bool
121 IsResolved ();
122
123 bool
124 GetDescription (lldb::SBStream &description, DescriptionLevel level);
125
126 SBBreakpoint
127 GetBreakpoint ();
128};
129
130} // namespace lldb