Class MCRXMLFunctions

java.lang.Object
org.mycore.solr.MCRXMLFunctions

public class MCRXMLFunctions extends Object
Author:
shermann
  • Constructor Details

    • MCRXMLFunctions

      public MCRXMLFunctions()
  • Method Details

    • getNumFound

      public static long getNumFound(String q) throws org.apache.solr.client.solrj.SolrServerException, IOException
      Convenience method for retrieving the result count for a given solr query.
      Parameters:
      q - the query to execute (in solr syntax)
      Returns:
      the amount of documents matching the given query
      Throws:
      org.apache.solr.client.solrj.SolrServerException
      IOException
    • getIdentifierOfFirst

      public static String getIdentifierOfFirst(String q) throws org.apache.solr.client.solrj.SolrServerException, IOException
      Parameters:
      q - the query to execute (in solr syntax)
      Returns:
      the identifier of the first document matching the query
      Throws:
      org.apache.solr.client.solrj.SolrServerException
      IOException