How does a Java program know if it was run by eclipse `debug` and not` run`?

Possible duplicate:
Determine if the Java application is running in debug mode in Eclipse

I can run java program in eclipse on run asor debug as.

Is there any way in java code to check if it was launched with runor debug? I want to do something (e.g. reload a resource) only in debug mode.

+3
source share
1 answer

eclipse, , jvm , tcp , , , , , , , , , , .

+1