Re: [netcdf-java] ThreddsDatasetChooser

There is some initialization code for various libraries that needs to be
called before you can use the ThreddsDatasetChooser. Here's what I have:

    thredds.ui.UrlAuthenticatorDialog authenticator = new 
    ucar.nc2.dataset.HttpClientManager.init(authenticator, "Your Application 
    thredds.util.URLStreamHandlerFactory.register("adde", new 

In your case I think it was the HttpClientManager that failed because it
wasn't initialized.

Also, I may be missing some initialization code, because I got the above
by copy-and-pasting from ToolsUI.


At 10:31 AM -0400 9/5/07, Christopher Mueller wrote:
>Hello All,
>I was hoping someone out there had some experience implementing the
>ThreddsDatasetChooser component and would be willing to help me out a bit.
>I've made a very simple test class to get the ThreddsDatasetChooser up and
>running.  The class is at the end of this email.  I'm able to display the
>dialog without much trouble, but I am unable to make it connect to a
>catalog.  When I enter a catalog URL into the combobox and click
>"Connect", a progress dialog comes up after a few seconds and tells me
>that it's "opening the catalog"?but after about 20 seconds or so, the
>dialog goes away and nothing else happens.  I also get the following
>exception in the output pane of my IDE:
>Exception in thread "Thread-2" java.lang.NullPointerException
>        at
>        at
>Can anyone help me out and let me know what I'm not doing or doing wrong??
>Thanks in advance,
>import javax.swing.*;
>import thredds.catalog.ui.ThreddsDatasetChooser;
>import ucar.util.prefs.PreferencesExt;
>import ucar.util.prefs.XMLStore;
> *
> * @author asamac
> */
>public class Browse {

Eric Russell

  • 2007 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdf-java archives: