[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[netCDFJava #IEX-641190]: NoClassDefFoundError using GridDataset
- Subject: [netCDFJava #IEX-641190]: NoClassDefFoundError using GridDataset
- Date: Mon, 24 Mar 2014 15:15:29 -0600
Tobias,
You have a simple classpath problem, hard to debug from afar. what mobile
platform are you on, android? what does your startup script look like?
John
> John,
>
> thanks for your fast response.
> Unfortunately I can't include netcdfAll-4.3.jar into my project.
> I'm developing for a mobile platform and get out of memory exceptions
> while compiling with the netcdfAll-4.3.jar.
> I did include all the jars stated in the dependencies section of your
> online support:
> http://www.unidata.ucar.edu/software/thredds/current/netcdf-java/reference/JarDependencies.html#v43
> Could you please point me to the jars I would have to include to make
> this work?
>
> Thanks,
> Tobias
>
> ------ Originalnachricht ------
> Von: "Unidata netCDF Java Support"
> <address@hidden>
> An: address@hidden
> Cc: address@hidden
> Gesendet: 24.03.2014 16:32:15
> Betreff: [netCDFJava #IEX-641190]: NoClassDefFoundError using
> GridDataset
>
> >Tobias:
> >
> >You have a simple classpath problem.
> >Try putting netcdfAll-4.3.jar on your classpath.
> >
> >John
> >
> >
> >> Full Name: Tobias Schug
> >> Email Address: address@hidden
> >> Organization: private
> >> Package Version:
> >> Operating System:
> >> Hardware:
> >> Description of problem:
> >>
> >> I'm trying, to extract data from a GRIB2 File downloaded from the
> >>NOMADS
> >> ftp server using netCDF 4.3.
> >>
> >> When I do open the file with toolsUI 4.3 the data is beeing displayed
> >> nicely. So the file is OK.
> >>
> >> While trying to open the same file in my code with:
> >>
> >> GridDataset gridDataset = GridDataset.open(filename);
> >>
> >> I get a NoClassDefFoundError for ucar.unidata.geoloc.ProjectionRect.
> >> This is confusing since I can see the ProjectionRect class within the
> >> imported netcdf-4.3.jar...
> >>
> >> What do I have to do, in order to make this work. I couldn't find any
> >> solution in the web which is why I'm hoping that you can help me out
> >> with that.
> >>
> >> I did included the following jars in my project:
> >>
> >> netcdf-4.3.jar
> >> grib-4.3.jar
> >> jdom-1.1.2.jar
> >> joda-time-2.0.jar
> >> protobuf-java-2.4.1.jar
> >> slf4j-api-1.6.4.jar
> >> slf4j-log4j12-1.6.4.jar
> >>
> >> and imported the following class files:
> >>
> >> import ucar.grib.GribNumbers;
> >> import ucar.grib.grib1.Grib1Tables;
> >> import ucar.grib.grib2.Grib2Data;
> >> import ucar.grib.grib2.Grib2GDSVariables;
> >> import ucar.grib.grib2.Grib2GridDefinitionSection;
> >> import ucar.grib.grib2.Grib2IdentificationSection;
> >> import ucar.grib.grib2.Grib2IndicatorSection;
> >> import ucar.grib.grib2.Grib2Input;
> >> import ucar.grib.grib2.Grib2Record;
> >> import ucar.grib.grib2.Grib2Tables;
> >> import ucar.nc2.dt.grid.GridDataset;
> >> import ucar.unidata.io.RandomAccessFile;
> >>
> >> Some of those I'm successfully using while dumping grib2 data to text
> >> which works just fine:
> >>
> >> SimpleDateFormat dateFormat = new
> >>SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'");
> >> dateFormat.setTimeZone(java.util.TimeZone.getTimeZone("GMT"));
> >> RandomAccessFile gribfile = new
> >>ucar.unidata.io.RandomAccessFile(filename, "r");
> >> gribfile.order(RandomAccessFile.BIG_ENDIAN);
> >> Grib2Input gribInput = new Grib2Input(gribfile);
> >> gribInput.scan(false, false);
> >> ...
> >>
> >>
> >
> >
> >Ticket Details
> >===================
> >Ticket ID: IEX-641190
> >Department: Support netCDF Java
> >Priority: Normal
> >Status: Open
> >
>
>
Ticket Details
===================
Ticket ID: IEX-641190
Department: Support netCDF Java
Priority: Normal
Status: Open