Class ServiceForSearches

java.lang.Object
it.uniroma2.art.semanticturkey.search.ServiceForSearches

public class ServiceForSearches extends Object
  • Constructor Details

    • ServiceForSearches

      public ServiceForSearches()
  • Method Details

    • isClassWanted

      public boolean isClassWanted()
    • isConceptWanted

      public boolean isConceptWanted()
    • isConceptSchemeWanted

      public boolean isConceptSchemeWanted()
    • isInstanceWanted

      public boolean isInstanceWanted()
    • isPropertyWanted

      public boolean isPropertyWanted()
    • isCollectionWanted

      public boolean isCollectionWanted()
    • isDataRagenWanted

      public boolean isDataRagenWanted()
    • isLexiconWanted

      public boolean isLexiconWanted()
    • isLexicalEntryWanted

      public boolean isLexicalEntryWanted()
    • filterResourceTypeAndSchemeAndLexicons

      public String filterResourceTypeAndSchemeAndLexicons(String varResource, String varType, List<org.eclipse.rdf4j.model.IRI> schemes, String schemeFilter, org.eclipse.rdf4j.model.IRI cls, List<org.eclipse.rdf4j.model.IRI> lexicons)
    • getFirstLetterForLiteral

      public static String getFirstLetterForLiteral(String varInput, String varOutput)
    • filterWithOrValues

      public static String filterWithOrValues(List<org.eclipse.rdf4j.model.IRI> iriList, String variable)
    • filterWithOrOfAndValues

      public static <T extends org.eclipse.rdf4j.model.Value> String filterWithOrOfAndValues(String variable, org.eclipse.rdf4j.model.IRI pred, List<List<T>> iriListList)
    • filterWithOrOfAndValues

      public static <T extends org.eclipse.rdf4j.model.Value> String filterWithOrOfAndValues(String variable, String predInNTForm, List<List<T>> valueListList)
    • filterWithOrOfAndPairValues

      public static String filterWithOrOfAndPairValues(List<Pair<org.eclipse.rdf4j.model.IRI,List<org.eclipse.rdf4j.model.Value>>> valueListPairList, String variable, String suffix, boolean reverse)
    • isSpecialCaseXLabel

      public static boolean isSpecialCaseXLabel(List<List<org.eclipse.rdf4j.model.IRI>> clsListList)
    • getResourceshavingTypes

      public static String getResourceshavingTypes(List<List<org.eclipse.rdf4j.model.IRI>> typesListOfList, String varToUse, boolean searchInSubTypes, boolean includeNonDirect)
    • getPrefixes

      public static String getPrefixes()
    • checksPreQuery

      public void checksPreQuery(String searchString, String[] rolesArray, SearchMode searchMode, boolean searchStringCanBeNull) throws IllegalStateException
      Throws:
      IllegalStateException
    • prepareQueryWithStatusOutgoingIngoing

      public static String prepareQueryWithStatusOutgoingIngoing(SearchStrategy.StatusFilter statusFilter, List<Pair<org.eclipse.rdf4j.model.IRI,List<org.eclipse.rdf4j.model.Value>>> outgoingLinks, List<TripleForSearch<org.eclipse.rdf4j.model.IRI,String,SearchMode>> outgoingSearch, List<Pair<org.eclipse.rdf4j.model.IRI,List<org.eclipse.rdf4j.model.Value>>> ingoingLinks, SearchStrategy searchStrategy, String baseURI, boolean includeLocales)
    • wordsForFuzzySearch

      public static List<String> wordsForFuzzySearch(String text, String replaceChar, boolean escapeForRegex, boolean escapeForLucene, SearchMode searchMode)
    • normalizeStringForLuceneIndex

      public static String normalizeStringForLuceneIndex(String inputString, SearchMode searchMode)
    • listToStringForQuery

      public static String listToStringForQuery(List<String> wordsList, String startSymbol, String endSymbol)
    • escapeStringForRegexInSPARQL

      public static String escapeStringForRegexInSPARQL(String input)
    • executeGenericSearchQueryForStringList

      public Collection<String> executeGenericSearchQueryForStringList(String query, org.eclipse.rdf4j.model.Resource[] namedGraphs, org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection)
    • executeInstancesSearchQuery

      public Collection<AnnotatedValue<org.eclipse.rdf4j.model.Resource>> executeInstancesSearchQuery(String query, org.eclipse.rdf4j.model.Resource[] namedGraphs, org.eclipse.rdf4j.repository.RepositoryConnection repositoryConnection)
    • getUriStartFromQname

      public static String getUriStartFromQname(String qnameToCheck, Map<String,String> prefixToNamespaceMap)
    • prepareLangFilter

      public static String prepareLangFilter(List<String> langs, String variable, boolean includeLocales)