Simple question about JAVA path

Advertisement
October 11

Hi. I have a simple question , but I spent several hours trying to find an answer.
How do I know the location of the java executable which is used by Concurrent Manager.
I already know that running which java under application user will not give me the correct answer

Advertisement

Replay

Maybe you can try like this:
     public String getPath(){
          Class cls=getClass();
          String className=cls.getName();
          String packageName=cls.getPackage().getName();
          System.out.println(className);
          System.out.println(packageName);
          String newClassName=className.replaceAll("\\.", "/");
          String resouceName=newClassName+".class";
          System.out.println(resouceName);
          URL url;
          url=cls.getClassLoader().getResource(resouceName);
          String path="";
          path=url.getFile();
          return path;
     }

View 4 Replies

Tags:

  1. my ipod wont turn on
  2. vidioplays.song
  3. apple tv hulu no signal
  4. itunes error code 13014 mac os 10.5.8
  5. sap note 1113277
  6. download BSP application
  7. centers2k
  8. expression58a
  9. manyi8a
  10. pigrn8
Copyrights 2019 Fcffair BigData Resource, All rights reserved