Translate

Tuesday, July 02, 2013

Class Viewer troubleshooting advice

Update July 3 2014: There was a change to how javadocs are accessed in Java 8. The latest version of Class Viewer dated July 3, 2014 addresses this change with backward compatibility for earlier versions. If you are not getting javadocs to the method please upgrade to this latest version.

-----------------------

A great thing about writing applications in Java is how well they can move around the world, across platforms. And for the most part my Class Viewer application can be used on any platform with Java, but it does do some things that are platform dependent like call your web browser.

Configuring for your system is all in ClassViewerConfig.xml which is where the app goes to see how to do such things. And I just edit it with a text editor.

If you run into problems with my Class Viewer, my guess is you likely need to make a change there.

For the browser and text editor everything is conveniently at the top with the BrowserLoc and Editor sections.


<browserloc>C:\\Program Files\\Mozilla Firefox\\firefox.exe</browserloc> <editor>C:\\Program Files\\gedit\\bin\\gedit.exe</editor> <acceptslinenumber>Yes</acceptslinenumber> <parameter>+</parameter>
Which is what I have as default for systems with Microsoft's Windows.

And if what's there doesn't work then change it to something that does.

If you have a different browser you just change BrowserLoc, and same for your text editor.

If what you try doesn't work the app will put up an error message telling you what it tried.

I ran into a problem recently out of the blue where Windows wanted quotes before it would call gedit, and I have no clue why and don't care. I just added the quotes and it worked. So I had:


<editor>"C:\\Program Files\\gedit\\bin\\gedit.exe"</editor>The default for Linux users is:
<browserloc>firefox</browserloc> <editor>gedit</editor> <acceptslinenumber>Yes</acceptslinenumber> <parameter>+</parameter>
Where it's simpler, and thus easier to change to your own preferences.

But I'm just helping people with those operating systems use Class Viewer while anyone who can run Java just needs to put in what will run on theirs.

Most troubleshooting issues I've found go back to what is in your ClassViewerConfig.xml, or your classpath.

As usual with Java make sure you have the classpath you need to get to programs you want.

You can check your classpath in Class Viewer to know where it is looking.

Any others having problems not covered here? If so, please comment, and I'll try to address any other issues.


James Harris

Updated: Changed packagedirectory.xml to ClassViewerConfig.xml--June 28 2014  __JSH
Post a Comment