Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Setting a breakpoint for when a Java class is loaded in IntelliJ IDEA

Is there a way to set a breakpoint for when a particular Java class is loaded in IntelliJ IDEA?

like image 878
Paul Reiners Avatar asked Sep 01 '25 03:09

Paul Reiners


1 Answers

In 2016 version it works by setting the breakpoint to the class definition line (public class YourClass ...). You don't have to use explicit constructor, it stops when ... new YourClass(); is called.

like image 134
Tony Avatar answered Sep 02 '25 20:09

Tony