Is there any way to conditionally debug in android studio

Is there a way to have a conditional debugger in android studio? for example, I want to go into debug mode when the value of a particular variable. eg:

for(MyClass myclass: ClassList){
String title = myclass.gettitle(); // this is where break point is
}

Prior to this, I do not need debug mode. I just want to test the application for this exact value. for example, when title="KickBoxing"in this case I have to check the value of the variable, and if it is not my required value, I have to press F9 to go to the next value. It may take 50 times to get to my desired value.

+4
source share
2 answers

. , , . . Java-.

. "kickBoxing".equals(title)

, .

enter image description here

( http://javafortesters.com/)

+10

Android Studio:

  • .

, myclass.gettitle().equals("KickBoxing")

+4

Source: https://habr.com/ru/post/1659398/


All Articles