I am debugging a Java package and I need to search for some d开发者_开发问答ebug statements being spitted out in the cmd to find out where in the code the program got stuck at. What type of search programs would you use to search for a debug message being printed onto screen in a large Java package? I tried using the ordinary Windows search using the "A word or phrase in the file" but I don't think it is doing it's job. Any recommendations?
Thanks.
To search for a string within a JAR (and include meaningful context) you can use the search (not find, which only works with a single class) function in Java Decompiler. How useful its output is will depend on whether the JAR has been run through an obfuscation tool.
In Eclipse, you can search your entire project or packages with Search -> File
but you should reconsider your debugging techniques, since there are better Methods than Printing to the CMD
精彩评论