/** Wraps a generic exception into a {@link IIOException}. */ protected IIOException netcdfFailure(final Exception e) throws IOException { return new IIOException( new StringBuilder("Can't read file ").append(dataset.getLocation()).toString(), e); }
+ key + "' while processing input: " + dataset.getLocation());
+ axis + " in input: " + dataset.getLocation() + " has been found");
private String makeLocation(String type, String name) { if (name != null) return ncd_2dtime.getLocation()+"/"+type+"-"+name+".ncd"; return ncd_2dtime.getLocation()+"/"+type+".ncd"; }
/** * the name of the dataset is the last part of the location * @return the name of the dataset */ public String getName() { String loc = ds.getLocation(); int pos = loc.lastIndexOf('/'); if (pos < 0) pos = loc.lastIndexOf('\\'); return (pos < 0) ? loc : loc.substring(pos+1); }
/** * the name of the dataset is the last part of the location * * @return the name of the dataset */ public String getName() { String loc = ncd.getLocation(); int pos = loc.lastIndexOf('/'); if (pos < 0) pos = loc.lastIndexOf('\\'); return (pos < 0) ? loc : loc.substring(pos + 1); }
/** * the name of the dataset is the last part of the location * @return the name of the dataset */ public String getName() { String loc = ncd.getLocation(); int pos = loc.lastIndexOf('/'); if (pos < 0) pos = loc.lastIndexOf('\\'); return (pos < 0) ? loc : loc.substring(pos+1); }
/** * Wraps a generic exception into a {@link IIOException}. */ protected IIOException netcdfFailure( final Exception e ) throws IOException { return new IIOException(new StringBuilder("Can't read file ").append(dataset.getLocation()).toString(), e); }
private String getCacheName() { String cacheName = ncDataset.getLocation(); if (cacheName == null) cacheName = ncDataset.getCacheName(); return cacheName; }
/** Wraps a generic exception into a {@link IIOException}. */ protected IIOException netcdfFailure(final Exception e) throws IOException { return new IIOException( new StringBuilder("Can't read file ").append(dataset.getLocation()).toString(), e); }
/** * Wraps a generic exception into a {@link IIOException}. */ private IIOException netcdfFailure(final Exception e) throws IOException { return new IIOException(new StringBuffer("Can't read file ").append( reader.getDataset().getLocation()).toString(), e); }
/** * Debugging * * @param out write here * @param ncd info about this */ public static void debugDump(PrintStream out, NetcdfDataset ncd) { String referencedLocation = ncd.orgFile == null ? "(null)" : ncd.orgFile.getLocation(); out.println("\nNetcdfDataset dump = " + ncd.getLocation() + " url= " + referencedLocation + "\n"); ncd.dumpClasses(ncd.getRootGroup(), out); }
/** * Debugging * * @param out write here * @param ncd info about this */ public static void debugDump(PrintWriter out, NetcdfDataset ncd) { String referencedLocation = ncd.orgFile == null ? "(null)" : ncd.orgFile.getLocation(); out.println("\nNetcdfDataset dump = " + ncd.getLocation() + " url= " + referencedLocation + "\n"); ncd.dumpClasses(ncd.getRootGroup(), out); }
/** * Debugging * * @param out write here * @param ncd info about this */ public static void debugDump(PrintWriter out, NetcdfDataset ncd) { String referencedLocation = ncd.orgFile == null ? "(null)" : ncd.orgFile.getLocation(); out.println("\nNetcdfDataset dump = " + ncd.getLocation() + " url= " + referencedLocation + "\n"); ncd.dumpClasses(ncd.getRootGroup(), out); }
/** Construtor when theres a NetcdfFile underneath * @param ncfile adapt this NetcdfDataset */ public TypedDatasetImpl(NetcdfDataset ncfile) { this.ncfile = ncfile; this.location = ncfile.getLocation(); this.title = ncfile.getTitle(); if (title == null) title = ncfile.findAttValueIgnoreCase(null, "title", null); if (desc == null) desc = ncfile.findAttValueIgnoreCase(null, "description", null); }
/** Construtor when theres a NetcdfFile underneath * @param netcdfDataset adapt this NetcdfDataset */ public TypedDatasetImpl(NetcdfDataset netcdfDataset) { this.netcdfDataset = netcdfDataset; this.location = netcdfDataset.getLocation(); this.title = netcdfDataset.getTitle(); if (title == null) title = netcdfDataset.findAttValueIgnoreCase(null, "title", null); if (desc == null) desc = netcdfDataset.findAttValueIgnoreCase(null, "description", null); }
/** Construtor when theres a NetcdfFile underneath * @param ncfile adapt this NetcdfDataset */ public TypedDatasetImpl(NetcdfDataset ncfile) { this.ncfile = ncfile; this.location = ncfile.getLocation(); this.title = ncfile.getTitle(); if (title == null) title = ncfile.findAttValueIgnoreCase(null, "title", null); if (desc == null) desc = ncfile.findAttValueIgnoreCase(null, "description", null); }
/** Constructor when theres a NetcdfFile underneath * @param ncfile adapt this NetcdfDataset */ public FeatureDatasetImpl(NetcdfDataset ncfile) { this.ncfile = ncfile; this.location = ncfile.getLocation(); this.title = ncfile.getTitle(); if (title == null) title = ncfile.findAttValueIgnoreCase(null, "title", null); if (desc == null) desc = ncfile.findAttValueIgnoreCase(null, "description", null); }
/** Constructor when theres a NetcdfFile underneath * @param ncfile adapt this NetcdfDataset */ public FeatureDatasetImpl(NetcdfDataset ncfile) { this.ncfile = ncfile; this.location = ncfile.getLocation(); this.title = ncfile.getTitle(); if (title == null) title = ncfile.findAttValueIgnoreCase(null, "title", null); if (desc == null) desc = ncfile.findAttValueIgnoreCase(null, "description", null); }
private BufrStationDataset(NetcdfDataset ncfile, BufrCdmIndex index) { super(ncfile, FeatureType.STATION); this.index = index; // create the list of data variables munger = new Munge(); obs = (SequenceDS) ncfile.findVariable(BufrIosp2.obsRecord); this.dataVariables = munger.makeDataVariables(index, obs); BufrStationCollection bufrCollection = new BufrStationCollection(ncfile.getLocation()); setPointFeatureCollection(bufrCollection); CalendarDateRange dateRange = CalendarDateRange.of(CalendarDate.of(index.start), CalendarDate.of(index.end)); setDateRange(dateRange); }