How to do step by step debugging of a program written in java, if I am writing in notepad ++?
4 answers
Notepad does not support such things, because it is just an editor for text (including code). Use IDE for tighter integration with java, you can search for plugins or tools, but it’s all out of the box in a good IDE (Eclipse, IDEA), or, as mentioned above, log, output the necessary data to a file.
In general, if you have chosen an editor for your needs, then choose a java-editor, such as jEdit, for which the plug-ins are dark specialized.
Sir knows a lot about perversion. (c) anecdote. Use this ( Eclipse ) notepad ++ and don’t bother people.
No Use logging. Or analytically look for a problem. The ability to read code (even your own) is a key skill. The debugger, although it saves a lot of time, alienates you from this skill.
The thing is that the debugger built into the JVM is controlled via the JDWP protocol. This protocol is simple, but binary. All decent IDEs have long since implemented it and support step-by-step debugging. Theoretically, it would be possible to write something like gdb for Java (and maybe this even exists, but I do not know about it), but this is not necessary.
To debug java code without an IDE, use jdb - The Java Debugger . But in general, it is very inconvenient and time consuming, so it is better to spend time and get used to Eclipse or NetBeans.
Can I connect jdb to Notepad ++, I do not know. I think it is impossible.