DebugClients/Python/BreakpointWatch.py

changeset 5815
223fa32b3a32
parent 5535
3296c56acdbf
child 6048
82ad8ec9548c
equal deleted inserted replaced
5814:50b299f6eb98 5815:223fa32b3a32
81 self.enabled = False 81 self.enabled = False
82 82
83 @staticmethod 83 @staticmethod
84 def clear_break(filename, lineno): 84 def clear_break(filename, lineno):
85 """ 85 """
86 Public method reimplemented from bdb.py to clear a breakpoint. 86 Static method reimplemented from bdb.py to clear a breakpoint.
87 87
88 @param filename file name of the bp to retrieve 88 @param filename file name of the bp to retrieve
89 @type str 89 @type str
90 @param lineno line number of the bp to retrieve 90 @param lineno line number of the bp to retrieve
91 @type int 91 @type int
96 Breakpoint.breakInFrameCache.clear() 96 Breakpoint.breakInFrameCache.clear()
97 97
98 @staticmethod 98 @staticmethod
99 def clear_all_breaks(): 99 def clear_all_breaks():
100 """ 100 """
101 Public method to clear all breakpoints. 101 Static method to clear all breakpoints.
102 """ 102 """
103 Breakpoint.breaks.clear() 103 Breakpoint.breaks.clear()
104 Breakpoint.breakInFile.clear() 104 Breakpoint.breakInFile.clear()
105 Breakpoint.breakInFrameCache.clear() 105 Breakpoint.breakInFrameCache.clear()
106 106
107 @staticmethod 107 @staticmethod
108 def get_break(filename, lineno): 108 def get_break(filename, lineno):
109 """ 109 """
110 Public method to get the breakpoint of a particular line. 110 Static method to get the breakpoint of a particular line.
111 111
112 Because eric6 supports only one breakpoint per line, this 112 Because eric6 supports only one breakpoint per line, this
113 method will return only one breakpoint. 113 method will return only one breakpoint.
114 114
115 @param filename file name of the bp to retrieve 115 @param filename file name of the bp to retrieve
122 return Breakpoint.breaks.get((filename, lineno)) 122 return Breakpoint.breaks.get((filename, lineno))
123 123
124 @staticmethod 124 @staticmethod
125 def effectiveBreak(filename, lineno, frame): 125 def effectiveBreak(filename, lineno, frame):
126 """ 126 """
127 Public method to determine which breakpoint for this filename:lineno 127 Static method to determine which breakpoint for this filename:lineno
128 is to be acted upon. 128 is to be acted upon.
129 129
130 Called only if we know there is a bpt at this 130 Called only if we know there is a bpt at this
131 location. Returns breakpoint that was triggered and a flag 131 location. Returns breakpoint that was triggered and a flag
132 that indicates if it is ok to delete a temporary bp. 132 that indicates if it is ok to delete a temporary bp.
246 self.enabled = False 246 self.enabled = False
247 247
248 @staticmethod 248 @staticmethod
249 def clear_watch(cond): 249 def clear_watch(cond):
250 """ 250 """
251 Public method to clear a watch expression. 251 Static method to clear a watch expression.
252 252
253 @param cond expression of the watch expression to be cleared 253 @param cond expression of the watch expression to be cleared
254 @type str 254 @type str
255 """ 255 """
256 try: 256 try:
259 pass 259 pass
260 260
261 @staticmethod 261 @staticmethod
262 def clear_all_watches(): 262 def clear_all_watches():
263 """ 263 """
264 Public method to clear all watch expressions. 264 Static method to clear all watch expressions.
265 """ 265 """
266 del Watch.watches[:] 266 del Watch.watches[:]
267 267
268 @staticmethod 268 @staticmethod
269 def get_watch(cond): 269 def get_watch(cond):
270 """ 270 """
271 Public method to get a watch expression. 271 Static method to get a watch expression.
272 272
273 @param cond expression of the watch expression to be cleared 273 @param cond expression of the watch expression to be cleared
274 @type str 274 @type str
275 @return reference to the watch point 275 @return reference to the watch point
276 @rtype Watch or None 276 @rtype Watch or None
280 return b 280 return b
281 281
282 @staticmethod 282 @staticmethod
283 def effectiveWatch(frame): 283 def effectiveWatch(frame):
284 """ 284 """
285 Public method to determine, if a watch expression is effective. 285 Static method to determine, if a watch expression is effective.
286 286
287 @param frame the current execution frame 287 @param frame the current execution frame
288 @type frame object 288 @type frame object
289 @return tuple of watch expression and a flag to indicate, that a 289 @return tuple of watch expression and a flag to indicate, that a
290 temporary watch expression may be deleted 290 temporary watch expression may be deleted

eric ide

mercurial