001package org.kuali.ole.docstore.discovery.service; 002 003import org.kuali.ole.docstore.model.bo.OleDocument; 004 005import java.util.List; 006import java.util.Map; 007 008/** 009 * Created with IntelliJ IDEA. 010 * User: ? 011 * Date: 8/6/12 012 * Time: 11:42 AM 013 * To change this template use File | Settings | File Templates. 014 */ 015public interface SRUCQLQueryService { 016 017 //SRU request parameter index 018 019 public static final String SRU_QUERY_TITLE = "title"; 020 public static final String SRU_QUERY_AUTHOR = "author"; 021 public static final String SRU_QUERY_CREATOR = "creator"; 022 public static final String SRU_QUERY_PUBLICATION_DATE = "publicationDate"; 023 public static final String SRU_QUERY_DATE = "date"; 024 public static final String SRU_QUERY_ISBN = "isbn"; 025 public static final String SRU_QUERY_PUBLISHER = "publisher"; 026 public static final String SRU_QUERY_ISSN = "issn"; 027 public static final String SRU_QUERY_LOCAL_ID = "localId"; 028 public static final String SRU_QUERY_OCLC = "oclc"; 029 public static final String SRU_QUERY_SUBJECT="subject"; 030 public static final String SRU_QUERY_SERVER_CHOICE="cql.serverChoice"; 031 public static final String SRU_QUERY_CQL_KEYWORDS = "cql.keywords"; 032 033 // SRU request parameter relations 034 035 //public static final String SRU_QUERY_SRC_RELATION = "scr"; //Support for scr is removed as part upgradation of CQL 1.2 036 public static final String SRU_QUERY_ANY_RELATION = "any"; 037 public static final String SRU_QUERY_ALL_RELATION = "all"; 038 public static final String SRU_QUERY_EXACT_RELATION = "=="; 039 public static final String SRU_QUERY_LESSERTHAN_RELATION = "<"; 040 public static final String SRU_QUERY_LESSERTHAN_EQUAL_RELATION = "<="; 041 public static final String SRU_QUERY_GREATERTHAN_RELATION = ">"; 042 public static final String SRU_QUERY_GREATERTHAN_EQUAL_RELATION = ">="; 043 public static final String SRU_QUERY_ADJ_RELATION = "adj"; 044 public static final String SRU_QUERY_WITHIN_RELATION = "within"; 045 public static final String SRU_QUERY_EQUALS_RELATION = "="; 046 047 // SRU request parameter names 048 049 public static final String START_RECORD = "startRecord"; 050 public static final String MAXIMUM_RECORDS = "maximumRecords"; 051 public static final String RECORD_SCHEMA = "recordSchema"; 052 public static final String SORTKEYS = "sortKeys"; 053 054 public static final String LOCAL_Id ="localId"; 055 public static final String REC_ID = "rec.id"; 056 public static final String DC_ID="dc.id"; 057 public static final String OLE_ID="ole.id"; 058 public static final String BATH_ID="bath.id"; 059 public static final String DC="dc."; 060 public static final String OLE="ole."; 061 public static final String BATH="bath."; 062 public static final String REC="rec."; 063 064 065 066 public String getQuery(String term, String relation, String index, boolean solrQueryFlag) throws Exception; 067 068 public List<OleDocument> queryForBibDocs(Map reqParamMap, String solrQuery) throws Exception; 069}