Class DatasetInfo

java.lang.Object
org.opengis.cite.cat30.util.DatasetInfo

public class DatasetInfo extends Object
Provides information about the data held by the IUT.
  • Constructor Details

    • DatasetInfo

      public DatasetInfo(File dataFile)

      Constructor for DatasetInfo.

      Parameters:
      dataFile - a File object
  • Method Details

    • getDataFile

      public File getDataFile()
      Returns the file containing the sample data.
      Returns:
      A File object representing a normal file.
    • getGeographicExtent

      public org.opengis.geometry.Envelope getGeographicExtent()
      Returns an Envelope representing the total geographic extent of the sample data. The bounding boxes (ows:BoundingBox or ows:WGS84BoundingBox) for each record are coalesced to determine the overall extent.
      Returns:
      An Envelope in some supported CRS.
    • getRecordIdentifiers

      public List<String> getRecordIdentifiers()
      Returns a sequence of record identifiers (dc:identifier) found in the sample data.
      Returns:
      A List containing all element values.
    • getRecordTitles

      public List<String> getRecordTitles()
      Returns a sequence of record titles (dc:title) found in the sample data. At least one such element must appear in every record representation.
      Returns:
      A List containing all element values.
    • getRecordTopics

      public List<String> getRecordTopics()
      Returns a sequence of topic (dc:subject) values found in the sample data. A record may contain zero or more subject elements that convey a set of topics (e.g. keywords, key phrases, classification codes) that apply to it.
      Returns:
      A List containing all topic values.
    • findItems

      public net.sf.saxon.s9api.XdmValue findItems(String xpath, Map<String,String> nsBindings) throws net.sf.saxon.s9api.SaxonApiException
      Finds the (infoset) items in the sample data that satisfy the given XPath (2.0) expression.
      Parameters:
      xpath - The XPath expression to be evaluated.
      nsBindings - A collection of namespace bindings required to evaluate the XPath expression, where each entry maps a namespace URI (key) to a prefix (value); bindings for the standard namespaces are not required.
      Returns:
      A sequence of zero or more items, where each item is either an atomic value or a node.
      Throws:
      net.sf.saxon.s9api.SaxonApiException - If the expression cannot be evaluated (this always wraps some other underlying exception).
    • calculateTotalExtent

      org.opengis.geometry.Envelope calculateTotalExtent(File file)
      Calculates the total extent of the records in the sample data. Each csw:Record element may contain at least one ows:BoundingBox (or ows:WGS84BoundingBox) element that describes the spatial coverage of a catalogued resource.
      Parameters:
      file - A File containing catalog data (csw:GetRecordsResponse).
      Returns:
      An Envelope representing the total geographic extent of the sample data, or null if no bounding boxes exist in the data.