congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
NCNameResourceCodec.getCoverage
Code IndexAdd Tabnine to your IDE (free)

How to use
getCoverage
method
in
org.geoserver.wcs2_0.util.NCNameResourceCodec

Best Java code snippets using org.geoserver.wcs2_0.util.NCNameResourceCodec.getCoverage (Showing top 8 results out of 315)

origin: org.geoserver.extension/gs-wcs2_0-eo-core

/**
 * Returns the coverage backed by the provided datasetId
 *
 * @param datasetId
 * @return the coverage, or null if not found, or if not a coverage
 */
public CoverageInfo getDatasetCoverage(String datasetId) {
  if (!datasetId.endsWith(DATASET_SUFFIX)) {
    LOGGER.fine(
        "Invalid dataset id " + datasetId + " it does not end with " + DATASET_SUFFIX);
    return null;
  }
  String coverageName = datasetId.substring(0, datasetId.length() - DATASET_SUFFIX.length());
  LayerInfo layer = NCNameResourceCodec.getCoverage(catalog, coverageName);
  if (layer == null) {
    LOGGER.fine(
        "Invalid dataset id " + datasetId + " does not match any published dataset");
    return null;
  }
  CoverageInfo ci = (CoverageInfo) layer.getResource();
  if (!isValidDataset(ci)) {
    LOGGER.fine(
        "Invalid dataset id " + datasetId + " does not match any published dataset");
    return null;
  }
  return ci;
}
origin: org.geoserver.extension/gs-wcs2_0-eo-core

/**
 * Returns the coverage containing the specified coverage, or null if the syntax is incorrect,
 * the coverage does not exist, or it's not a dataset
 */
public CoverageInfo getGranuleCoverage(String granuleId) {
  // does it have the expected lexical structure?
  if (!granuleId.contains(GRANULE_SEPARATOR)) {
    return null;
  }
  String[] splitted = granuleId.split(GRANULE_SEPARATOR);
  if (splitted.length != 2) {
    return null;
  }
  // do we have the coverage?
  LayerInfo li = NCNameResourceCodec.getCoverage(catalog, splitted[0]);
  if (li == null) {
    return null;
  }
  // is it a EO dataset?
  CoverageInfo ci = (CoverageInfo) li.getResource();
  if (isValidDataset(ci)) {
    return ci;
  } else {
    return null;
  }
}
origin: org.geoserver.extension/gs-netcdf-out

if (geoserver != null) {
  Catalog gsCatalog = geoserver.getCatalog();
  LayerInfo info = NCNameResourceCodec.getCoverage(gsCatalog, coverageId);
  if (info != null) {
    map = info.getResource().getMetadata();
origin: org.geoserver/gs-wcs2_0

LayerInfo layer = NCNameResourceCodec.getCoverage(catalog, newCoverageID);
if (layer != null) {
  coverages.add((CoverageInfo) layer.getResource());
origin: org.geoserver.community/gs-netcdf-out

if (geoserver != null) {
  Catalog gsCatalog = geoserver.getCatalog();
  LayerInfo info = NCNameResourceCodec.getCoverage(gsCatalog, coverageId);
  if (info != null) {
    map = info.getResource().getMetadata();
origin: org.geoserver/gs-wcs2_0

LayerInfo layer = NCNameResourceCodec.getCoverage(catalog, newCoverageID);
if (layer == null) {
  badCoverageIds.add(encodedCoverageId);
origin: org.geoserver.extension/gs-netcdf-out

  /**
   * Extracts the NetCDF encoding settings from the coverage identifier
   *
   * @param coverageId
   * @return
   */
  static NetCDFLayerSettingsContainer getSettings(String coverageId) {
    GeoServer geoserver = GeoServerExtensions.bean(GeoServer.class);
    MetadataMap map = null;
    if (geoserver != null) {
      Catalog gsCatalog = geoserver.getCatalog();
      LayerInfo info = NCNameResourceCodec.getCoverage(gsCatalog, coverageId);
      if (info != null) {
        map = info.getResource().getMetadata();
      }
    }
    if (map != null
        && !map.isEmpty()
        && map.containsKey(NetCDFSettingsContainer.NETCDFOUT_KEY)) {
      NetCDFLayerSettingsContainer settings =
          (NetCDFLayerSettingsContainer)
              map.get(
                  NetCDFSettingsContainer.NETCDFOUT_KEY,
                  NetCDFLayerSettingsContainer.class);
      return settings;
    }

    return null;
  }
}
origin: org.geoserver/gs-wcs2_0

final LayerInfo linfo = NCNameResourceCodec.getCoverage(catalog, request.getCoverageId());
if (linfo == null) {
  throw new WCS20Exception(
org.geoserver.wcs2_0.utilNCNameResourceCodecgetCoverage

Popular methods of NCNameResourceCodec

  • encode
  • decode
  • getLayers
    Search in the catalog the Layers matching the encoded id.

Popular in Java

  • Creating JSON documents from java classes using gson
  • putExtra (Intent)
  • requestLocationUpdates (LocationManager)
  • notifyDataSetChanged (ArrayAdapter)
  • InputStreamReader (java.io)
    A class for turning a byte stream into a character stream. Data read from the source input stream is
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • TreeMap (java.util)
    Walk the nodes of the tree left-to-right or right-to-left. Note that in descending iterations, next
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • Top PhpStorm 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