Conditional Breakpoints in JDeveloper
By Shay Shmeltzer-Oracle on Dec 22, 2006
Setting breakpoints in JDeveloper is very simple, you just click on the left margin next to the line where you want to stop and mark a break there.
I'm quite sure that many people just do that and live happily ever after, but for those who are looking for a bit more control there are actually properties you can set on the breakpoint.
For example, suppose you have a loop in your code that seem to break after the 100th time you go through the loop. You want to set a break point on a line inside the loop but you don't want to break for the first 100 times this line is reached.
In such a case you can define a conditional break point.
Just right click on the break point and choose "Edit Breakpoint".
Then go to the conditions tab and set the condition that will actually break the code.
For example a.equals("hello1234") if you want to stop when the string a has the value hello1234 and you reach that line.
(pressing the help button in this window will show you some other possible conditions).
By the way you can also set a conditional based breakpoint not on a specific row. Just pop-up the debugger's breakpoints window and right click to create a new breakpoint which won't be associated with a specific line but rather with a specific condition.