congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
NcMLReader.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
ucar.nc2.ncml.NcMLReader
constructor

Best Java code snippets using ucar.nc2.ncml.NcMLReader.<init> (Showing top 20 results out of 315)

origin: Unidata/thredds

/**
 * Read NcML from a JDOM Document, and pass in the name of the dataset. Used to augment datasetScan with NcML
 *
 * @param ncmlLocation the URL location string of the NcML document, used as a unique name for caching purposes.
 * @param netcdfElem   the JDOM Document's root (netcdf) element
 * @param referencedDatasetUri the URL location string of the underlying dataset, which overrides anything in netcdfElem.
 *                             prepend with "file:" to eliminate reletive resolving against ncmlLocation
 * @param cancelTask   allow user to cancel the task; may be null
 * @return the resulting NetcdfDataset
 * @throws IOException on read error, or bad referencedDatasetUri URI
 */
static public NetcdfDataset readNcML(String ncmlLocation, Element netcdfElem, String referencedDatasetUri, CancelTask cancelTask) throws IOException {
 NcMLReader reader = new NcMLReader();
 return reader._readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
}
origin: edu.ucar/cdm

/**
 * Read NcML from a JDOM Document, and pass in the name of the dataset. Used to augment datasetScan with NcML
 *
 * @param ncmlLocation the URL location string of the NcML document, used as a unique name for caching purposes.
 * @param netcdfElem   the JDOM Document's root (netcdf) element
 * @param referencedDatasetUri the URL location string of the underlying dataset, which overrides anything in netcdfElem.
 *                             prepend with "file:" to eliminate reletive resolving against ncmlLocation
 * @param cancelTask   allow user to cancel the task; may be null
 * @return the resulting NetcdfDataset
 * @throws IOException on read error, or bad referencedDatasetUri URI
 */
static public NetcdfDataset readNcML(String ncmlLocation, Element netcdfElem, String referencedDatasetUri, CancelTask cancelTask) throws IOException {
 NcMLReader reader = new NcMLReader();
 return reader._readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
}
origin: edu.ucar/netcdf

/**
 * Use NCML to directly modify the dataset
 *
 * @param targetDS   referenced dataset
 * @param parentElem parent element - usually the aggregation element of the ncml
 * @return new dataset with the merged info
 * @throws IOException on read error
 */
static public NetcdfDataset mergeNcMLdirect(NetcdfDataset targetDS, Element parentElem) throws IOException {
 NcMLReader reader = new NcMLReader();
 reader.readGroup(targetDS, targetDS, null, null, parentElem);
 targetDS.finish();
 return targetDS;
}
origin: Unidata/thredds

/**
 * Use NCML to directly modify the dataset
 *
 * @param targetDS   referenced dataset
 * @param parentElem parent element - usually the aggregation element of the ncml
 * @return new dataset with the merged info
 * @throws IOException on read error
 */
static public NetcdfDataset mergeNcMLdirect(NetcdfDataset targetDS, Element parentElem) throws IOException {
 NcMLReader reader = new NcMLReader();
 reader.readGroup(targetDS, targetDS, null, null, parentElem);
 targetDS.finish();
 return targetDS;
}
origin: edu.ucar/cdm

/**
 * Use NCML to directly modify the dataset
 *
 * @param targetDS   referenced dataset
 * @param parentElem parent element - usually the aggregation element of the ncml
 * @return new dataset with the merged info
 * @throws IOException on read error
 */
static public NetcdfDataset mergeNcMLdirect(NetcdfDataset targetDS, Element parentElem) throws IOException {
 NcMLReader reader = new NcMLReader();
 reader.readGroup(targetDS, targetDS, null, null, parentElem);
 targetDS.finish();
 return targetDS;
}
origin: edu.ucar/cdm

/**
 * Use NCML to modify the referenced dataset, create a new dataset with the merged info
 * Used to wrap each dataset of an aggregation before its aggregated
 *
 * @param ref        referenced dataset
 * @param parentElem parent element - usually the aggregation element of the ncml
 * @return new dataset with the merged info
 * @throws IOException on read error
 */
static public NetcdfDataset mergeNcML(NetcdfFile ref, Element parentElem) throws IOException {
 NetcdfDataset targetDS = new NetcdfDataset(ref, null); // no enhance
 NcMLReader reader = new NcMLReader();
 reader.readGroup(targetDS, targetDS, null, null, parentElem);
 targetDS.finish();
 return targetDS;
}
origin: edu.ucar/cdm

NcMLReader reader = new NcMLReader();
NetcdfDataset ncd = reader._readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
if (debugOpen) System.out.println("***NcMLReader.readNcML result= \n" + ncd);
origin: edu.ucar/netcdf

NcMLReader reader = new NcMLReader();
NetcdfDataset ncd = reader.readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
if (debugOpen) System.out.println("***NcMLReader.readNcML result= \n" + ncd);
origin: edu.ucar/netcdf

/**
 * Use NCML to modify the referenced dataset, create a new dataset with the merged info
 * Used to wrap each dataset of an aggregation before its aggregated
 *
 * @param ref        referenced dataset
 * @param parentElem parent element - usually the aggregation element of the ncml
 * @return new dataset with the merged info
 * @throws IOException on read error
 */
static public NetcdfDataset mergeNcML(NetcdfFile ref, Element parentElem) throws IOException {
 NetcdfDataset targetDS = new NetcdfDataset(ref, null); // no enhance
 NcMLReader reader = new NcMLReader();
 reader.readGroup(targetDS, targetDS, null, null, parentElem);
 targetDS.finish();
 return targetDS;
}
origin: Unidata/thredds

 referencedDatasetUri = AliasTranslator.translateAlias(referencedDatasetUri);
NcMLReader reader = new NcMLReader();
NetcdfDataset ncd = reader._readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
if (debugOpen) System.out.println("***NcMLReader.readNcML result= \n" + ncd);
origin: edu.ucar/netcdf

/**
 * Read NcML from a JDOM Document, and construct a NetcdfDataset.
 *
 * @param ncmlLocation the URL location string of the NcML document, used to resolve reletive path of the referenced dataset,
 *                     or may be just a unique name for caching purposes.
 * @param netcdfElem   the JDOM Document's root (netcdf) element
 * @param cancelTask   allow user to cancel the task; may be null
 * @return the resulting NetcdfDataset
 * @throws IOException on read error, or bad referencedDatasetUri URI
 */
static public NetcdfDataset readNcML(String ncmlLocation, Element netcdfElem, CancelTask cancelTask) throws IOException {
 // the ncml probably refers to another dataset, but doesnt have to
 String referencedDatasetUri = netcdfElem.getAttributeValue("location");
 if (referencedDatasetUri == null)
  referencedDatasetUri = netcdfElem.getAttributeValue("url");
 NcMLReader reader = new NcMLReader();
 return reader.readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
}
origin: Unidata/thredds

/**
 * Use NCML to modify the referenced dataset, create a new dataset with the merged info
 * Used to wrap each dataset of an aggregation before its aggregated
 *
 * @param ref        referenced dataset
 * @param parentElem parent element - usually the aggregation element of the ncml
 * @return new dataset with the merged info
 * @throws IOException on read error
 */
static public NetcdfDataset mergeNcML(NetcdfFile ref, Element parentElem) throws IOException {
 NetcdfDataset targetDS = new NetcdfDataset(ref, null); // no enhance
 NcMLReader reader = new NcMLReader();
 reader.readGroup(targetDS, targetDS, null, null, parentElem);
 targetDS.finish();
 return targetDS;
}
origin: edu.ucar/cdm

/**
 * Read NcML from a JDOM Document, and construct a NetcdfDataset.
 *
 * @param ncmlLocation the URL location string of the NcML document, used to resolve reletive path of the referenced dataset,
 *                     or may be just a unique name for caching purposes.
 * @param netcdfElem   the JDOM Document's root (netcdf) element
 * @param cancelTask   allow user to cancel the task; may be null
 * @return the resulting NetcdfDataset
 * @throws IOException on read error, or bad referencedDatasetUri URI
 */
static public NetcdfDataset readNcML(String ncmlLocation, Element netcdfElem, CancelTask cancelTask) throws IOException {
 // the ncml probably refers to another dataset, but doesnt have to
 String referencedDatasetUri = netcdfElem.getAttributeValue("location");
 if (referencedDatasetUri == null)
  referencedDatasetUri = netcdfElem.getAttributeValue("url");
 NcMLReader reader = new NcMLReader();
 return reader._readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
}
origin: edu.ucar/cdm

NcMLReader reader = new NcMLReader();
reader.readNetcdf(ncDataset.getLocation(), ncDataset, ncDataset, netcdfElem, cancelTask);
if (debugOpen) System.out.println("***NcMLReader.wrapNcML result= \n" + ncDataset);
origin: Unidata/thredds

NcMLReader reader = new NcMLReader();
reader.readNetcdf(ncDataset.getLocation(), ncDataset, ncDataset, netcdfElem, cancelTask);
if (debugOpen) System.out.println("***NcMLReader.wrapNcML result= \n" + ncDataset);
origin: edu.ucar/netcdf

NcMLReader reader = new NcMLReader();
reader.readNetcdf(ncDataset.getLocation(), ncDataset, ncDataset, netcdfElem, cancelTask);
if (debugOpen) System.out.println("***NcMLReader.wrapNcML result= \n" + ncDataset);
origin: edu.ucar/cdm

/**
 * Use NCML to modify the dataset, getting NcML from a URL
 *
 * @param ncDataset    modify this dataset
 * @param ncmlLocation URL location of NcML
 * @param cancelTask   allow user to cancel task; may be null
 * @throws IOException on read error
 */
static public void wrapNcML(NetcdfDataset ncDataset, String ncmlLocation, CancelTask cancelTask) throws IOException {
 org.jdom2.Document doc;
 try {
  SAXBuilder builder = new SAXBuilder();
  if (debugURL) System.out.println(" NetcdfDataset URL = <" + ncmlLocation + ">");
  doc = builder.build(ncmlLocation);
 } catch (JDOMException e) {
  throw new IOException(e.getMessage());
 }
 if (debugXML) System.out.println(" SAXBuilder done");
 if (showParsedXML) {
  XMLOutputter xmlOut = new XMLOutputter();
  System.out.println("*** NetcdfDataset/showParsedXML = \n" + xmlOut.outputString(doc) + "\n*******");
 }
 Element netcdfElem = doc.getRootElement();
 NcMLReader reader = new NcMLReader();
 reader.readNetcdf(ncmlLocation, ncDataset, ncDataset, netcdfElem, cancelTask);
 if (debugOpen) System.out.println("***NcMLReader.wrapNcML result= \n" + ncDataset);
}
origin: edu.ucar/netcdf

/**
 * Use NCML to modify the dataset, getting NcML from a URL
 *
 * @param ncDataset    modify this dataset
 * @param ncmlLocation URL location of NcML
 * @param cancelTask   allow user to cancel task; may be null
 * @throws IOException on read error
 */
static public void wrapNcML(NetcdfDataset ncDataset, String ncmlLocation, CancelTask cancelTask) throws IOException {
 org.jdom2.Document doc;
 try {
  SAXBuilder builder = new SAXBuilder();
  if (debugURL) System.out.println(" NetcdfDataset URL = <" + ncmlLocation + ">");
  doc = builder.build(ncmlLocation);
 } catch (JDOMException e) {
  throw new IOException(e.getMessage());
 }
 if (debugXML) System.out.println(" SAXBuilder done");
 if (showParsedXML) {
  XMLOutputter xmlOut = new XMLOutputter();
  System.out.println("*** NetcdfDataset/showParsedXML = \n" + xmlOut.outputString(doc) + "\n*******");
 }
 Element netcdfElem = doc.getRootElement();
 NcMLReader reader = new NcMLReader();
 reader.readNetcdf(ncmlLocation, ncDataset, ncDataset, netcdfElem, cancelTask);
 if (debugOpen) System.out.println("***NcMLReader.wrapNcML result= \n" + ncDataset);
}
origin: Unidata/thredds

/**
 * Use NCML to modify the dataset, getting NcML from a URL
 *
 * @param ncDataset    modify this dataset
 * @param ncmlLocation URL location of NcML
 * @param cancelTask   allow user to cancel task; may be null
 * @throws IOException on read error
 */
static public void wrapNcML(NetcdfDataset ncDataset, String ncmlLocation, CancelTask cancelTask) throws IOException {
 org.jdom2.Document doc;
 try {
  SAXBuilder builder = new SAXBuilder();
  if (debugURL) System.out.println(" NetcdfDataset URL = <" + ncmlLocation + ">");
  doc = builder.build(ncmlLocation);
 } catch (JDOMException e) {
  throw new IOException(e.getMessage());
 }
 if (debugXML) System.out.println(" SAXBuilder done");
 if (showParsedXML) {
  XMLOutputter xmlOut = new XMLOutputter();
  System.out.println("*** NetcdfDataset/showParsedXML = \n" + xmlOut.outputString(doc) + "\n*******");
 }
 Element netcdfElem = doc.getRootElement();
 NcMLReader reader = new NcMLReader();
 reader.readNetcdf(ncmlLocation, ncDataset, ncDataset, netcdfElem, cancelTask);
 if (debugOpen) System.out.println("***NcMLReader.wrapNcML result= \n" + ncDataset);
}
origin: Unidata/thredds

/**
 * Read NcML from a JDOM Document, and construct a NetcdfDataset.
 *
 * @param ncmlLocation the URL location string of the NcML document, used to resolve reletive path of the referenced dataset,
 *                     or may be just a unique name for caching purposes.
 * @param netcdfElem   the JDOM Document's root (netcdf) element
 * @param cancelTask   allow user to cancel the task; may be null
 * @return the resulting NetcdfDataset
 * @throws IOException on read error, or bad referencedDatasetUri URI
 */
static public NetcdfDataset readNcML(String ncmlLocation, Element netcdfElem, CancelTask cancelTask) throws IOException {
 // the ncml probably refers to another dataset, but doesnt have to
 String referencedDatasetUri = netcdfElem.getAttributeValue("location");
 if (referencedDatasetUri == null)
  referencedDatasetUri = netcdfElem.getAttributeValue("url");
 if (referencedDatasetUri != null)
  referencedDatasetUri = AliasTranslator.translateAlias(referencedDatasetUri);
 NcMLReader reader = new NcMLReader();
 return reader._readNcML(ncmlLocation, referencedDatasetUri, netcdfElem, cancelTask);
}
ucar.nc2.ncmlNcMLReader<init>

Popular methods of NcMLReader

  • readNcML
    Read an NcML file from a URL location, and construct a NetcdfDataset.
  • wrapNcML
    Use NCML to modify the dataset, getting NcML from a URL
  • wrapNcMLresource
    Use NCML to modify a dataset, getting the NcML document as a resource stream. Uses ClassLoader.getRe
  • addAttribute
  • cmdRemove
  • findAttribute
  • mergeNcML
    Use NCML to modify the referenced dataset, create a new dataset with the merged info Used to wrap ea
  • mergeNcMLdirect
    Use NCML to directly modify the dataset
  • readAgg
  • readAtt
    Read an NcML attribute element.
  • readAttributeValues
    Parse the values element
  • readDim
    Read an NcML dimension element.
  • readAttributeValues,
  • readDim,
  • readGroup,
  • readNetcdf,
  • readValues,
  • readVariable,
  • readVariableNested,
  • readVariableNew,
  • removeAttribute

Popular in Java

  • Parsing JSON documents to java classes using gson
  • scheduleAtFixedRate (ScheduledExecutorService)
  • onCreateOptionsMenu (Activity)
  • getApplicationContext (Context)
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • ResourceBundle (java.util)
    ResourceBundle is an abstract class which is the superclass of classes which provide Locale-specifi
  • Executor (java.util.concurrent)
    An object that executes submitted Runnable tasks. This interface provides a way of decoupling task s
  • Top Sublime Text plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now